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

Unified Diff: chrome/browser/media/media_stream_capture_indicator.h

Issue 10825313: MediaStreamCaptureIndicator: fix crash due to destruction on wrong thread (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 4 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/media/media_stream_capture_indicator.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/media/media_stream_capture_indicator.h
diff --git a/chrome/browser/media/media_stream_capture_indicator.h b/chrome/browser/media/media_stream_capture_indicator.h
index f325ade8b4d20b803f9695ff42cdbf10b15d1e46..4232ddcee8d2e7689773dcf84b4dc0794c235c9f 100644
--- a/chrome/browser/media/media_stream_capture_indicator.h
+++ b/chrome/browser/media/media_stream_capture_indicator.h
@@ -9,6 +9,7 @@
#include <vector>
#include "base/memory/ref_counted.h"
+#include "base/memory/scoped_ptr.h"
#include "chrome/browser/extensions/image_loading_tracker.h"
#include "content/public/common/media_stream_request.h"
#include "ui/base/models/simple_menu_model.h"
@@ -127,6 +128,9 @@ class MediaStreamCaptureIndicator
// UpdateStatusTrayIconContextMenu().
void UpdateStatusTrayIconDisplay(bool audio, bool video);
+ // Initializes image loading state.
+ void EnsureImageLoadingTracker();
+
// Reference to our status icon - owned by the StatusTray. If null,
// the platform doesn't support status icons.
StatusIcon* status_icon_;
@@ -141,7 +145,7 @@ class MediaStreamCaptureIndicator
CaptureDeviceTabs tabs_;
// Tracks the load of extension icons.
- ImageLoadingTracker tracker_;
+ scoped_ptr<ImageLoadingTracker> tracker_;
// The messages to display when extension images are loaded. The index
// corresponds to the index of the associated LoadImage request.
std::map<int, string16> pending_messages_;
« no previous file with comments | « no previous file | chrome/browser/media/media_stream_capture_indicator.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698