0
Files
src/content/common/text_input_client_messages.h
Daniel Bratell bcbca53217 Add include guards to ipc message headers
The solution without include guards isn't compatible with jumbo.

Bug: 746953
Cq-Include-Trybots: master.tryserver.chromium.android:android_optional_gpu_tests_rel;master.tryserver.chromium.linux:linux_optional_gpu_tests_rel;master.tryserver.chromium.mac:mac_optional_gpu_tests_rel;master.tryserver.chromium.win:win_optional_gpu_tests_rel
Change-Id: Iaaea9654fa2c38c40ab458678693518abe555d34
Reviewed-on: https://chromium-review.googlesource.com/580868
Reviewed-by: Antoine Labour <piman@chromium.org>
Reviewed-by: Tom Sepez <tsepez@chromium.org>
Reviewed-by: dsinclair <dsinclair@chromium.org>
Reviewed-by: Daniel Cheng <dcheng@chromium.org>
Commit-Queue: Daniel Bratell <bratell@opera.com>
Cr-Commit-Position: refs/heads/master@{#499162}
2017-09-01 10:00:53 +00:00

71 lines
2.7 KiB
C

// Copyright (c) 2012 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.
#ifndef CONTENT_COMMON_TEXT_INPUT_CLIENT_MESSAGES_H_
#define CONTENT_COMMON_TEXT_INPUT_CLIENT_MESSAGES_H_
#include <stddef.h>
#include "build/build_config.h"
#include "ipc/ipc_message_macros.h"
#include "ui/gfx/geometry/rect.h"
#include "ui/gfx/range/range.h"
#if defined(OS_MACOSX)
#include "content/common/mac/attributed_string_coder.h"
#endif
#define IPC_MESSAGE_START TextInputClientMsgStart
#undef IPC_MESSAGE_EXPORT
#define IPC_MESSAGE_EXPORT CONTENT_EXPORT
// Browser -> Renderer Messages ////////////////////////////////////////////////
// These messages are sent from the browser to the renderer. Each one has a
// corresponding reply message.
////////////////////////////////////////////////////////////////////////////////
// Tells the renderer to send back the character index for a point.
IPC_MESSAGE_ROUTED1(TextInputClientMsg_CharacterIndexForPoint,
gfx::Point)
// Tells the renderer to send back the rectangle for a given character range.
IPC_MESSAGE_ROUTED1(TextInputClientMsg_FirstRectForCharacterRange,
gfx::Range)
// Tells the renderer to send back the text fragment in a given range.
IPC_MESSAGE_ROUTED1(TextInputClientMsg_StringForRange,
gfx::Range)
// Tells the renderer to send back the word under the given point and its
// baseline point.
IPC_MESSAGE_ROUTED1(TextInputClientMsg_StringAtPoint, gfx::Point)
////////////////////////////////////////////////////////////////////////////////
// Renderer -> Browser Replies /////////////////////////////////////////////////
// These messages are sent in reply to the above messages.
////////////////////////////////////////////////////////////////////////////////
// Reply message for TextInputClientMsg_CharacterIndexForPoint.
IPC_MESSAGE_ROUTED1(TextInputClientReplyMsg_GotCharacterIndexForPoint,
uint32_t /* character index */)
// Reply message for TextInputClientMsg_FirstRectForCharacterRange.
IPC_MESSAGE_ROUTED1(TextInputClientReplyMsg_GotFirstRectForRange,
gfx::Rect /* frame rectangle */)
#if defined(OS_MACOSX)
// Reply message for TextInputClientMsg_StringForRange.
IPC_MESSAGE_ROUTED2(TextInputClientReplyMsg_GotStringForRange,
mac::AttributedStringCoder::EncodedString,
gfx::Point)
// Reply message for TextInputClientMsg_StringAtPoint
IPC_MESSAGE_ROUTED2(TextInputClientReplyMsg_GotStringAtPoint,
mac::AttributedStringCoder::EncodedString,
gfx::Point)
#endif // defined(OS_MACOSX)
#endif // CONTENT_COMMON_TEXT_INPUT_CLIENT_MESSAGES_H_