1 // Copyright 2013 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.
5 #ifndef CONTENT_COMMON_INPUT_IPC_INPUT_EVENT_PAYLOAD_H_
6 #define CONTENT_COMMON_INPUT_IPC_INPUT_EVENT_PAYLOAD_H_
8 #include "base/basictypes.h"
9 #include "content/common/content_export.h"
10 #include "content/common/input/input_event.h"
11 #include "ipc/ipc_message.h"
15 // Wraps a generic IPC message of type InputMsg_*.
16 class CONTENT_EXPORT IPCInputEventPayload
: public InputEvent::Payload
{
18 static scoped_ptr
<IPCInputEventPayload
> Create();
19 static scoped_ptr
<IPCInputEventPayload
> Create(
20 scoped_ptr
<IPC::Message
> message
);
22 static const IPCInputEventPayload
* Cast(const Payload
* payload
);
24 virtual ~IPCInputEventPayload();
26 // InputEvent::Payload
27 virtual Type
GetType() const OVERRIDE
;
29 scoped_ptr
<IPC::Message
> message
;
32 IPCInputEventPayload();
35 DISALLOW_COPY_AND_ASSIGN(IPCInputEventPayload
);
38 } // namespace content
40 #endif // CONTENT_COMMON_INPUT_IPC_INPUT_EVENT_PAYLOAD_H_