Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(27)

Side by Side Diff: chrome/browser/speech/speech_input_bubble.h

Issue 9595008: speech: Change SpeechInputBubbleBase::message_text() to return a const-ref. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 134 matching lines...) Expand 10 before | Expand all | Expand 10 after
145 virtual void SetInputVolume(float volume, float noise_volume) OVERRIDE; 145 virtual void SetInputVolume(float volume, float noise_volume) OVERRIDE;
146 virtual content::WebContents* web_contents() OVERRIDE; 146 virtual content::WebContents* web_contents() OVERRIDE;
147 147
148 protected: 148 protected:
149 // Updates the platform specific UI layout for the current display mode. 149 // Updates the platform specific UI layout for the current display mode.
150 virtual void UpdateLayout() = 0; 150 virtual void UpdateLayout() = 0;
151 151
152 // Overridden by subclasses to copy |icon_image()| to the screen. 152 // Overridden by subclasses to copy |icon_image()| to the screen.
153 virtual void UpdateImage() = 0; 153 virtual void UpdateImage() = 0;
154 154
155 DisplayMode display_mode() { 155 DisplayMode display_mode() const { return display_mode_; }
156 return display_mode_;
157 }
158 156
159 string16 message_text() { 157 const string16& message_text() const { return message_text_; }
160 return message_text_;
161 }
162 158
163 SkBitmap icon_image(); 159 SkBitmap icon_image();
164 160
165 private: 161 private:
166 void DoRecognizingAnimationStep(); 162 void DoRecognizingAnimationStep();
167 void DoWarmingUpAnimationStep(); 163 void DoWarmingUpAnimationStep();
168 void SetImage(const SkBitmap& image); 164 void SetImage(const SkBitmap& image);
169 165
170 void DrawVolumeOverlay(SkCanvas* canvas, 166 void DrawVolumeOverlay(SkCanvas* canvas,
171 const SkBitmap& bitmap, 167 const SkBitmap& bitmap,
(...skipping 17 matching lines...) Expand all
189 scoped_ptr<SkBitmap> icon_image_; 185 scoped_ptr<SkBitmap> icon_image_;
190 }; 186 };
191 187
192 // This typedef is to workaround the issue with certain versions of 188 // This typedef is to workaround the issue with certain versions of
193 // Visual Studio where it gets confused between multiple Delegate 189 // Visual Studio where it gets confused between multiple Delegate
194 // classes and gives a C2500 error. (I saw this error on the try bots - 190 // classes and gives a C2500 error. (I saw this error on the try bots -
195 // the workaround was not needed for my machine). 191 // the workaround was not needed for my machine).
196 typedef SpeechInputBubble::Delegate SpeechInputBubbleDelegate; 192 typedef SpeechInputBubble::Delegate SpeechInputBubbleDelegate;
197 193
198 #endif // CHROME_BROWSER_SPEECH_SPEECH_INPUT_BUBBLE_H_ 194 #endif // CHROME_BROWSER_SPEECH_SPEECH_INPUT_BUBBLE_H_
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698