| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 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 | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef PPAPI_CPP_DEV_IME_INPUT_EVENT_DEV_H_ | 5 #ifndef PPAPI_CPP_DEV_IME_INPUT_EVENT_DEV_H_ |
| 6 #define PPAPI_CPP_DEV_IME_INPUT_EVENT_DEV_H_ | 6 #define PPAPI_CPP_DEV_IME_INPUT_EVENT_DEV_H_ |
| 7 | 7 |
| 8 #include <utility> | 8 #include <utility> |
| 9 #include <vector> | 9 #include <vector> |
| 10 | 10 |
| (...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 46 /// @param[in] segment_offsets The array of numbers returned by | 46 /// @param[in] segment_offsets The array of numbers returned by |
| 47 /// <code>GetSegmentOffset</code>. | 47 /// <code>GetSegmentOffset</code>. |
| 48 /// | 48 /// |
| 49 /// @param[in] target_segment The number returned by | 49 /// @param[in] target_segment The number returned by |
| 50 /// <code>GetTargetSegment</code>. | 50 /// <code>GetTargetSegment</code>. |
| 51 /// | 51 /// |
| 52 /// @param[in] selection The range returned by <code>GetSelection</code>. | 52 /// @param[in] selection The range returned by <code>GetSelection</code>. |
| 53 IMEInputEvent_Dev(const InstanceHandle& instance, | 53 IMEInputEvent_Dev(const InstanceHandle& instance, |
| 54 PP_InputEvent_Type type, | 54 PP_InputEvent_Type type, |
| 55 PP_TimeTicks time_stamp, | 55 PP_TimeTicks time_stamp, |
| 56 Var text, | 56 const Var& text, |
| 57 const std::vector<uint32_t>& segment_offsets, | 57 const std::vector<uint32_t>& segment_offsets, |
| 58 int32_t target_segment, | 58 int32_t target_segment, |
| 59 const std::pair<uint32_t, uint32_t>& selection); | 59 const std::pair<uint32_t, uint32_t>& selection); |
| 60 | 60 |
| 61 /// Returns the composition text as a UTF-8 string for the given IME event. | 61 /// Returns the composition text as a UTF-8 string for the given IME event. |
| 62 /// | 62 /// |
| 63 /// @return A string var representing the composition text. For non-IME | 63 /// @return A string var representing the composition text. For non-IME |
| 64 /// input events the return value will be an undefined var. | 64 /// input events the return value will be an undefined var. |
| 65 Var GetText() const; | 65 Var GetText() const; |
| 66 | 66 |
| (...skipping 30 matching lines...) Expand all Loading... |
| 97 | 97 |
| 98 /// Returns the range selected by caret in the composition text. | 98 /// Returns the range selected by caret in the composition text. |
| 99 /// | 99 /// |
| 100 /// @return A pair of integers indicating the selection range. | 100 /// @return A pair of integers indicating the selection range. |
| 101 std::pair<uint32_t, uint32_t> GetSelection() const; | 101 std::pair<uint32_t, uint32_t> GetSelection() const; |
| 102 }; | 102 }; |
| 103 | 103 |
| 104 } // namespace pp | 104 } // namespace pp |
| 105 | 105 |
| 106 #endif // PPAPI_CPP_DEV_IME_INPUT_EVENT_DEV_H_ | 106 #endif // PPAPI_CPP_DEV_IME_INPUT_EVENT_DEV_H_ |
| OLD | NEW |