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

Unified Diff: chrome/browser/speech/chrome_speech_recognition_manager_delegate.h

Issue 10663018: Changing tab closure handling logic in speech recognition code and cleaning bubble controller. (Spe… (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Moved TabWatcher as a private class in chrome_speech_recognition_manager_delegate.cc Created 8 years, 5 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
« no previous file with comments | « no previous file | chrome/browser/speech/chrome_speech_recognition_manager_delegate.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/speech/chrome_speech_recognition_manager_delegate.h
diff --git a/chrome/browser/speech/chrome_speech_recognition_manager_delegate.h b/chrome/browser/speech/chrome_speech_recognition_manager_delegate.h
index eb1f4d5b8cc1aa36e32e62d5e56b06f14056f711..519b152a3a2de50aa737b81d9c64912ddb9a4c08 100644
--- a/chrome/browser/speech/chrome_speech_recognition_manager_delegate.h
+++ b/chrome/browser/speech/chrome_speech_recognition_manager_delegate.h
@@ -16,7 +16,6 @@
class SpeechRecognitionTrayIconController;
namespace speech {
-
// This is Chrome's implementation of the SpeechRecognitionManagerDelegate
// interface.
class ChromeSpeechRecognitionManagerDelegate
@@ -58,6 +57,7 @@ class ChromeSpeechRecognitionManagerDelegate
private:
class OptionalRequestInfo;
+ class TabWatcher;
// Shows the recognition tray icon for a given |context_name|, eventually
// with a notification balloon. The balloon is shown only once per profile
@@ -80,6 +80,9 @@ class ChromeSpeechRecognitionManagerDelegate
// (which is copied into |last_session_config_|). Used for "try again".
void RestartLastSession();
+ // Callback called by |tab_watcher_| on the IO thread to signal tab closure.
+ void TabClosedCallback(int render_process_id, int render_view_id);
+
// Lazy initializers for bubble and tray icon controller.
SpeechRecognitionBubbleController* GetBubbleController();
SpeechRecognitionTrayIconController* GetTrayIconController();
@@ -88,9 +91,7 @@ class ChromeSpeechRecognitionManagerDelegate
scoped_refptr<SpeechRecognitionTrayIconController> tray_icon_controller_;
scoped_refptr<OptionalRequestInfo> optional_request_info_;
scoped_ptr<content::SpeechRecognitionSessionConfig> last_session_config_;
-
- // TODO(primiano) this information should be kept into the bubble_controller_.
- int active_bubble_session_id_;
+ scoped_refptr<TabWatcher> tab_watcher_;
DISALLOW_COPY_AND_ASSIGN(ChromeSpeechRecognitionManagerDelegate);
};
« no previous file with comments | « no previous file | chrome/browser/speech/chrome_speech_recognition_manager_delegate.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698