| Index: content/common/wake_lock_messages.h
|
| diff --git a/content/common/wake_lock_messages.h b/content/common/wake_lock_messages.h
|
| new file mode 100644
|
| index 0000000000000000000000000000000000000000..6d26adef458fa35aecc20a1ee8535e95eff356af
|
| --- /dev/null
|
| +++ b/content/common/wake_lock_messages.h
|
| @@ -0,0 +1,41 @@
|
| +// Copyright 2014 The Chromium Authors. All rights reserved.
|
| +// Use of this source code is governed by a BSD-style license that can be
|
| +// found in the LICENSE file.
|
| +
|
| +// IPC messages for wake lock.
|
| +// Multiply-included message file, hence no include guard.
|
| +
|
| +#include "content/common/content_export.h"
|
| +#include "ipc/ipc_message_macros.h"
|
| +#include "third_party/WebKit/public/platform/WebWakeLockRequestInfo.h"
|
| +#include "url/gurl.h"
|
| +
|
| +#undef IPC_MESSAGE_EXPORT
|
| +#define IPC_MESSAGE_EXPORT CONTENT_EXPORT
|
| +
|
| +#define IPC_MESSAGE_START WakeLockMsgStart
|
| +
|
| +IPC_ENUM_TRAITS_MIN_MAX_VALUE(blink::WebWakeLockType,
|
| + blink::WebWakeLockScreen,
|
| + blink::WebWakeLockGuard)
|
| +
|
| +IPC_STRUCT_TRAITS_BEGIN(blink::WakeLockRequestInfo)
|
| + IPC_STRUCT_TRAITS_MEMBER(type)
|
| + IPC_STRUCT_TRAITS_MEMBER(requestId)
|
| + IPC_STRUCT_TRAITS_MEMBER(contextId)
|
| +IPC_STRUCT_TRAITS_END()
|
| +
|
| +// Asks the browser process to create wake lock if necessary.
|
| +IPC_MESSAGE_ROUTED2(WakeLockViewHostMsg_RequestLock,
|
| + blink::WakeLockRequestInfo /* params */,
|
| + GURL /* GURL of the frame requesting wake lock */)
|
| +IPC_MESSAGE_ROUTED1(WakeLockViewHostMsg_RequestUnlock,
|
| + blink::WakeLockRequestInfo /* params */)
|
| +
|
| +// Answer from browser to renderer about created wakeLock
|
| +IPC_MESSAGE_ROUTED1(WakeLockViewMsg_LockedSuccessful, int /* request_id */)
|
| +IPC_MESSAGE_ROUTED1(WakeLockViewMsg_LockedFailed, int /* request_id */)
|
| +
|
| +// Answer from browser to renderer about unlocked wakeLock
|
| +IPC_MESSAGE_ROUTED1(WakeLockViewMsg_UnlockedSuccessful, int /* request_id */)
|
| +IPC_MESSAGE_ROUTED1(WakeLockViewMsg_UnlockedFailed, int /* request_id */)
|
|
|