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

Unified Diff: chrome/browser/speech/speech_input_bubble_gtk.cc

Issue 3352018: Show error messages in speech bubble allowing user to retry as well. (Closed)
Patch Set: Address joth's comments. Created 10 years, 3 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/speech/speech_input_bubble_gtk.cc
diff --git a/chrome/browser/speech/speech_input_bubble_gtk.cc b/chrome/browser/speech/speech_input_bubble_gtk.cc
index fed513c206f564b05c6dd052c5f7ddb2d2cf5acd..f77189e7a34699e870bd183a72ac4355709dbe8d 100644
--- a/chrome/browser/speech/speech_input_bubble_gtk.cc
+++ b/chrome/browser/speech/speech_input_bubble_gtk.cc
@@ -26,7 +26,7 @@ const GdkColor kLabelTextColor = gfx::kGdkBlack;
// Implementation of SpeechInputBubble for GTK. This shows a speech input
// info bubble on screen.
class SpeechInputBubbleGtk
- : public SpeechInputBubble,
+ : public SpeechInputBubbleBase,
public InfoBubbleGtkDelegate {
public:
SpeechInputBubbleGtk(TabContents* tab_contents,
@@ -40,7 +40,9 @@ class SpeechInputBubbleGtk
bool closed_by_escape);
// SpeechInputBubble methods.
- virtual void SetRecognizingMode();
+ virtual void Show();
+ virtual void Hide();
+ virtual void UpdateLayout();
CHROMEGTK_CALLBACK_0(SpeechInputBubbleGtk, void, OnCancelClicked);
@@ -111,19 +113,26 @@ SpeechInputBubbleGtk::~SpeechInputBubbleGtk() {
void SpeechInputBubbleGtk::InfoBubbleClosing(InfoBubbleGtk* info_bubble,
bool closed_by_escape) {
if (delegate_)
- delegate_->InfoBubbleClosed();
+ delegate_->InfoBubbleFocusChanged();
}
void SpeechInputBubbleGtk::OnCancelClicked(GtkWidget* widget) {
- delegate_->RecognitionCancelled();
+ delegate_->InfoBubbleButtonClicked(BUTTON_CANCEL);
}
-void SpeechInputBubbleGtk::SetRecognizingMode() {
- SkBitmap* image = ResourceBundle::GetSharedInstance().GetBitmapNamed(
- IDR_SPEECH_INPUT_PROCESSING);
- GdkPixbuf* pixbuf = gfx::GdkPixbufFromSkBitmap(image);
- gtk_image_set_from_pixbuf(GTK_IMAGE(icon_), pixbuf);
- g_object_unref(pixbuf);
+void SpeechInputBubbleGtk::Show() {
+ // TODO(satish): Implement.
+ NOTREACHED();
+}
+
+void SpeechInputBubbleGtk::Hide() {
+ // TODO(satish): Implement.
+ NOTREACHED();
+}
+
+void SpeechInputBubbleGtk::UpdateLayout() {
+ // TODO: Implement.
+ NOTREACHED();
}
} // namespace

Powered by Google App Engine
This is Rietveld 408576698