OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 CHROME_BROWSER_SPEECH_SPEECH_INPUT_BUBBLE_H_ | 5 #ifndef CHROME_BROWSER_SPEECH_SPEECH_INPUT_BUBBLE_H_ |
6 #define CHROME_BROWSER_SPEECH_SPEECH_INPUT_BUBBLE_H_ | 6 #define CHROME_BROWSER_SPEECH_SPEECH_INPUT_BUBBLE_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
(...skipping 115 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
126 DISPLAY_MODE_WARM_UP, | 126 DISPLAY_MODE_WARM_UP, |
127 DISPLAY_MODE_RECORDING, | 127 DISPLAY_MODE_RECORDING, |
128 DISPLAY_MODE_RECOGNIZING, | 128 DISPLAY_MODE_RECOGNIZING, |
129 DISPLAY_MODE_MESSAGE | 129 DISPLAY_MODE_MESSAGE |
130 }; | 130 }; |
131 | 131 |
132 explicit SpeechInputBubbleBase(TabContents* tab_contents); | 132 explicit SpeechInputBubbleBase(TabContents* tab_contents); |
133 virtual ~SpeechInputBubbleBase(); | 133 virtual ~SpeechInputBubbleBase(); |
134 | 134 |
135 // SpeechInputBubble methods | 135 // SpeechInputBubble methods |
136 virtual void SetWarmUpMode(); | 136 virtual void SetWarmUpMode() OVERRIDE; |
137 virtual void SetRecordingMode(); | 137 virtual void SetRecordingMode() OVERRIDE; |
138 virtual void SetRecognizingMode(); | 138 virtual void SetRecognizingMode() OVERRIDE; |
139 virtual void SetMessage(const string16& text); | 139 virtual void SetMessage(const string16& text) OVERRIDE; |
140 virtual void SetInputVolume(float volume, float noise_volume); | 140 virtual void SetInputVolume(float volume, float noise_volume) OVERRIDE; |
141 virtual TabContents* tab_contents(); | 141 virtual TabContents* tab_contents() OVERRIDE; |
142 | 142 |
143 protected: | 143 protected: |
144 // Updates the platform specific UI layout for the current display mode. | 144 // Updates the platform specific UI layout for the current display mode. |
145 virtual void UpdateLayout() = 0; | 145 virtual void UpdateLayout() = 0; |
146 | 146 |
147 // Overridden by subclasses to copy |icon_image()| to the screen. | 147 // Overridden by subclasses to copy |icon_image()| to the screen. |
148 virtual void UpdateImage() = 0; | 148 virtual void UpdateImage() = 0; |
149 | 149 |
150 DisplayMode display_mode() { | 150 DisplayMode display_mode() { |
151 return display_mode_; | 151 return display_mode_; |
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
184 scoped_ptr<SkBitmap> icon_image_; | 184 scoped_ptr<SkBitmap> icon_image_; |
185 }; | 185 }; |
186 | 186 |
187 // This typedef is to workaround the issue with certain versions of | 187 // This typedef is to workaround the issue with certain versions of |
188 // Visual Studio where it gets confused between multiple Delegate | 188 // Visual Studio where it gets confused between multiple Delegate |
189 // classes and gives a C2500 error. (I saw this error on the try bots - | 189 // classes and gives a C2500 error. (I saw this error on the try bots - |
190 // the workaround was not needed for my machine). | 190 // the workaround was not needed for my machine). |
191 typedef SpeechInputBubble::Delegate SpeechInputBubbleDelegate; | 191 typedef SpeechInputBubble::Delegate SpeechInputBubbleDelegate; |
192 | 192 |
193 #endif // CHROME_BROWSER_SPEECH_SPEECH_INPUT_BUBBLE_H_ | 193 #endif // CHROME_BROWSER_SPEECH_SPEECH_INPUT_BUBBLE_H_ |
OLD | NEW |