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

Unified Diff: base/message_pump_aurax11.h

Issue 11593015: MessagePumpAuraX11: Make root_window_dispatchers_ an ObserverList. (Closed) Base URL: http://src.chromium.org/svn/trunk/src/
Patch Set: Created 8 years 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 | base/message_pump_aurax11.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/message_pump_aurax11.h
===================================================================
--- base/message_pump_aurax11.h (revision 173177)
+++ base/message_pump_aurax11.h (working copy)
@@ -77,7 +77,6 @@
private:
typedef std::map<unsigned long, MessagePumpDispatcher*> DispatchersMap;
- typedef std::vector<MessagePumpDispatcher*> Dispatchers;
// Initializes the glib event source for X.
void InitXSource();
@@ -106,8 +105,12 @@
scoped_ptr<GPollFD> x_poll_;
DispatchersMap dispatchers_;
- Dispatchers root_window_dispatchers_;
+ // Dispatch calls can cause addition of new dispatchers as we iterate
+ // through them. Use ObserverList to ensure the iterator remains valid across
+ // additions.
+ ObserverList<MessagePumpDispatcher> root_window_dispatchers_;
willchan no longer on Chromium 2012/12/19 17:25:42 YOu need the #include for this.
+
unsigned long x_root_window_;
DISALLOW_COPY_AND_ASSIGN(MessagePumpAuraX11);
« no previous file with comments | « no previous file | base/message_pump_aurax11.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698