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

Side by Side Diff: chrome/browser/ui/cocoa/speech_recognition_window_controller.h

Issue 9568002: Renamed speech input implementation from to speech_recognition_*. The namespace has been renamed fr… (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Rebased from master. 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
OLDNEW
1 // Copyright (c) 2011 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 CHROME_BROWSER_UI_COCOA_SPEECH_INPUT_WINDOW_CONTROLLER_H_ 5 #ifndef CHROME_BROWSER_UI_COCOA_SPEECH_RECOGNITION_WINDOW_CONTROLLER_H_
6 #define CHROME_BROWSER_UI_COCOA_SPEECH_INPUT_WINDOW_CONTROLLER_H_ 6 #define CHROME_BROWSER_UI_COCOA_SPEECH_RECOGNITION_WINDOW_CONTROLLER_H_
7 #pragma once 7 #pragma once
8 8
9 #import <Cocoa/Cocoa.h> 9 #import <Cocoa/Cocoa.h>
10 10
11 #include "chrome/browser/speech/speech_input_bubble.h" 11 #include "chrome/browser/speech/speech_recognition_bubble.h"
12 #include "chrome/browser/ui/cocoa/base_bubble_controller.h" 12 #include "chrome/browser/ui/cocoa/base_bubble_controller.h"
13 13
14 // Controller for the speech input bubble window. This bubble window gets 14 // Controller for the speech recognition bubble window. This bubble window gets
15 // displayed when the user starts speech input in a html input element. 15 // displayed when the user starts speech input in a html input element.
16 @interface SpeechInputWindowController : BaseBubbleController { 16 @interface SpeechRecognitionWindowController : BaseBubbleController {
17 @private 17 @private
18 SpeechInputBubble::Delegate* delegate_; // weak. 18 SpeechRecognitionBubble::Delegate* delegate_; // weak.
19 SpeechInputBubbleBase::DisplayMode displayMode_; 19 SpeechRecognitionBubbleBase::DisplayMode displayMode_;
20 20
21 // References below are weak, being obtained from the nib. 21 // References below are weak, being obtained from the nib.
22 IBOutlet NSImageView* iconImage_; 22 IBOutlet NSImageView* iconImage_;
23 IBOutlet NSTextField* instructionLabel_; 23 IBOutlet NSTextField* instructionLabel_;
24 IBOutlet NSButton* cancelButton_; 24 IBOutlet NSButton* cancelButton_;
25 IBOutlet NSButton* tryAgainButton_; 25 IBOutlet NSButton* tryAgainButton_;
26 IBOutlet NSButton* micSettingsButton_; 26 IBOutlet NSButton* micSettingsButton_;
27 } 27 }
28 28
29 // Initialize the window. |anchoredAt| is in screen coordinates. 29 // Initialize the window. |anchoredAt| is in screen coordinates.
30 - (id)initWithParentWindow:(NSWindow*)parentWindow 30 - (id)initWithParentWindow:(NSWindow*)parentWindow
31 delegate:(SpeechInputBubbleDelegate*)delegate 31 delegate:(SpeechRecognitionBubbleDelegate*)delegate
32 anchoredAt:(NSPoint)anchoredAt; 32 anchoredAt:(NSPoint)anchoredAt;
33 33
34 // Handler for the cancel button. 34 // Handler for the cancel button.
35 - (IBAction)cancel:(id)sender; 35 - (IBAction)cancel:(id)sender;
36 36
37 // Handler for the try again button. 37 // Handler for the try again button.
38 - (IBAction)tryAgain:(id)sender; 38 - (IBAction)tryAgain:(id)sender;
39 39
40 // Handler for the mic settings button. 40 // Handler for the mic settings button.
41 - (IBAction)micSettings:(id)sender; 41 - (IBAction)micSettings:(id)sender;
42 42
43 // Updates the UI with data related to the given display mode. 43 // Updates the UI with data related to the given display mode.
44 - (void)updateLayout:(SpeechInputBubbleBase::DisplayMode)mode 44 - (void)updateLayout:(SpeechRecognitionBubbleBase::DisplayMode)mode
45 messageText:(const string16&)messageText 45 messageText:(const string16&)messageText
46 iconImage:(NSImage*)iconImage; 46 iconImage:(NSImage*)iconImage;
47 47
48 // Makes the speech input bubble visible on screen. 48 // Makes the speech recognition bubble visible on screen.
49 - (void)show; 49 - (void)show;
50 50
51 // Hides the speech input bubble away from screen. This does NOT release the 51 // Hides the speech recognition bubble away from screen. This does NOT release
52 // controller and the window. 52 // the controller and the window.
53 - (void)hide; 53 - (void)hide;
54 54
55 // Sets the image to be displayed in the bubble's status ImageView. A future 55 // Sets the image to be displayed in the bubble's status ImageView. A future
56 // call to updateLayout may change the image. 56 // call to updateLayout may change the image.
57 // TODO(satish): Clean that up and move it into the platform independent 57 // TODO(satish): Clean that up and move it into the platform independent
58 // SpeechInputBubbleBase class. 58 // SpeechRecognitionBubbleBase class.
59 - (void)setImage:(NSImage*)image; 59 - (void)setImage:(NSImage*)image;
60 60
61 @end 61 @end
62 62
63 #endif // CHROME_BROWSER_UI_COCOA_SPEECH_INPUT_WINDOW_CONTROLLER_H_ 63 #endif // CHROME_BROWSER_UI_COCOA_SPEECH_RECOGNITION_WINDOW_CONTROLLER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698