| 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 // Multiply-included message file, hence no include guard. | 5 // Multiply-included message file, hence no include guard. |
| 6 | 6 |
| 7 #include <string> | 7 #include <string> |
| 8 | 8 |
| 9 #include "content/public/common/speech_recognition_error.h" |
| 9 #include "content/public/common/speech_recognition_result.h" | 10 #include "content/public/common/speech_recognition_result.h" |
| 10 #include "ipc/ipc_message_macros.h" | 11 #include "ipc/ipc_message_macros.h" |
| 11 #include "ipc/ipc_param_traits.h" | 12 #include "ipc/ipc_param_traits.h" |
| 12 #include "ui/gfx/rect.h" | 13 #include "ui/gfx/rect.h" |
| 13 | 14 |
| 14 #define IPC_MESSAGE_START SpeechRecognitionMsgStart | 15 #define IPC_MESSAGE_START SpeechRecognitionMsgStart |
| 15 | 16 |
| 16 IPC_ENUM_TRAITS(content::SpeechRecognitionErrorCode) | 17 IPC_ENUM_TRAITS(content::SpeechRecognitionErrorCode) |
| 17 | 18 |
| 18 IPC_STRUCT_TRAITS_BEGIN(content::SpeechRecognitionHypothesis) | 19 IPC_STRUCT_TRAITS_BEGIN(content::SpeechRecognitionHypothesis) |
| 19 IPC_STRUCT_TRAITS_MEMBER(utterance) | 20 IPC_STRUCT_TRAITS_MEMBER(utterance) |
| 20 IPC_STRUCT_TRAITS_MEMBER(confidence) | 21 IPC_STRUCT_TRAITS_MEMBER(confidence) |
| 21 IPC_STRUCT_TRAITS_END() | 22 IPC_STRUCT_TRAITS_END() |
| 22 | 23 |
| 23 IPC_STRUCT_TRAITS_BEGIN(content::SpeechRecognitionResult) | 24 IPC_STRUCT_TRAITS_BEGIN(content::SpeechRecognitionResult) |
| 24 IPC_STRUCT_TRAITS_MEMBER(error) | |
| 25 IPC_STRUCT_TRAITS_MEMBER(hypotheses) | 25 IPC_STRUCT_TRAITS_MEMBER(hypotheses) |
| 26 IPC_STRUCT_TRAITS_END() | 26 IPC_STRUCT_TRAITS_END() |
| 27 | 27 |
| 28 // Used to start a speech recognition session. | 28 // Used to start a speech recognition session. |
| 29 IPC_STRUCT_BEGIN(InputTagSpeechHostMsg_StartRecognition_Params) | 29 IPC_STRUCT_BEGIN(InputTagSpeechHostMsg_StartRecognition_Params) |
| 30 // The render view requesting speech recognition. | 30 // The render view requesting speech recognition. |
| 31 IPC_STRUCT_MEMBER(int, render_view_id) | 31 IPC_STRUCT_MEMBER(int, render_view_id) |
| 32 // Request ID used within the render view. | 32 // Request ID used within the render view. |
| 33 IPC_STRUCT_MEMBER(int, request_id) | 33 IPC_STRUCT_MEMBER(int, request_id) |
| 34 // Position of the UI element in page coordinates. | 34 // Position of the UI element in page coordinates. |
| (...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 77 | 77 |
| 78 // Indicate that speech recognizer has completed recognition. This will be the | 78 // Indicate that speech recognizer has completed recognition. This will be the |
| 79 // last message sent in response to a InputTagSpeechHostMsg_StartRecognition. | 79 // last message sent in response to a InputTagSpeechHostMsg_StartRecognition. |
| 80 IPC_MESSAGE_ROUTED1(InputTagSpeechMsg_RecognitionComplete, | 80 IPC_MESSAGE_ROUTED1(InputTagSpeechMsg_RecognitionComplete, |
| 81 int /* request_id */) | 81 int /* request_id */) |
| 82 | 82 |
| 83 // Toggle speech recognition on or off on the speech input control for the | 83 // Toggle speech recognition on or off on the speech input control for the |
| 84 // current focused element. Has no effect if the current element doesn't | 84 // current focused element. Has no effect if the current element doesn't |
| 85 // support speech recognition. | 85 // support speech recognition. |
| 86 IPC_MESSAGE_ROUTED0(InputTagSpeechMsg_ToggleSpeechInput) | 86 IPC_MESSAGE_ROUTED0(InputTagSpeechMsg_ToggleSpeechInput) |
| OLD | NEW |