drag_traits.h revision 868fa2fe829687343ffae624259930155e16dbd8
1// Copyright (c) 2012 The Chromium Authors. All rights reserved.
2// Use of this source code is governed by a BSD-style license that can be
3// found in the LICENSE file.
4
5#include "content/common/drag_event_source_info.h"
6#include "content/public/common/common_param_traits.h"
7#include "ipc/ipc_message_macros.h"
8#include "third_party/WebKit/Source/WebKit/chromium/public/WebDragOperation.h"
9#include "ui/gfx/point.h"
10#include "webkit/common/webdropdata.h"
11
12#define IPC_MESSAGE_START DragMsgStart
13
14IPC_ENUM_TRAITS(WebKit::WebDragOperation)
15
16IPC_STRUCT_TRAITS_BEGIN(WebDropData::FileInfo)
17  IPC_STRUCT_TRAITS_MEMBER(path)
18  IPC_STRUCT_TRAITS_MEMBER(display_name)
19IPC_STRUCT_TRAITS_END()
20
21IPC_STRUCT_TRAITS_BEGIN(WebDropData)
22  IPC_STRUCT_TRAITS_MEMBER(url)
23  IPC_STRUCT_TRAITS_MEMBER(url_title)
24  IPC_STRUCT_TRAITS_MEMBER(download_metadata)
25  IPC_STRUCT_TRAITS_MEMBER(referrer_policy)
26  IPC_STRUCT_TRAITS_MEMBER(filenames)
27  IPC_STRUCT_TRAITS_MEMBER(filesystem_id)
28  IPC_STRUCT_TRAITS_MEMBER(text)
29  IPC_STRUCT_TRAITS_MEMBER(html)
30  IPC_STRUCT_TRAITS_MEMBER(html_base_url)
31  IPC_STRUCT_TRAITS_MEMBER(file_description_filename)
32  IPC_STRUCT_TRAITS_MEMBER(file_contents)
33  IPC_STRUCT_TRAITS_MEMBER(custom_data)
34IPC_STRUCT_TRAITS_END()
35
36IPC_ENUM_TRAITS(ui::DragDropTypes::DragEventSource)
37
38IPC_STRUCT_TRAITS_BEGIN(content::DragEventSourceInfo)
39  IPC_STRUCT_TRAITS_MEMBER(event_location)
40  IPC_STRUCT_TRAITS_MEMBER(event_source)
41IPC_STRUCT_TRAITS_END()
42