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

Side by Side Diff: ui/views/widget/desktop_aura/desktop_dispatcher_client.h

Issue 280483003: wm: Change the DispatcherClient interface. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: self-nit Created 6 years, 6 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 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 UI_VIEWS_WIDGET_DESKTOP_AURA_DESKTOP_DISPATCHER_CLIENT_H_ 5 #ifndef UI_VIEWS_WIDGET_DESKTOP_AURA_DESKTOP_DISPATCHER_CLIENT_H_
6 #define UI_VIEWS_WIDGET_DESKTOP_AURA_DESKTOP_DISPATCHER_CLIENT_H_ 6 #define UI_VIEWS_WIDGET_DESKTOP_AURA_DESKTOP_DISPATCHER_CLIENT_H_
7 7
8 #include "base/basictypes.h" 8 #include "base/basictypes.h"
9 #include "base/callback.h" 9 #include "base/callback.h"
10 #include "base/memory/weak_ptr.h"
11 #include "ui/views/views_export.h" 10 #include "ui/views/views_export.h"
12 #include "ui/wm/public/dispatcher_client.h" 11 #include "ui/wm/public/dispatcher_client.h"
13 12
14 namespace views { 13 namespace views {
15 14
16 // TODO(erg): I won't lie to you; I have no idea what this is or what it does. 15 // TODO(erg): I won't lie to you; I have no idea what this is or what it does.
17 class VIEWS_EXPORT DesktopDispatcherClient 16 class VIEWS_EXPORT DesktopDispatcherClient
18 : public aura::client::DispatcherClient { 17 : public aura::client::DispatcherClient {
19 public: 18 public:
20 DesktopDispatcherClient(); 19 DesktopDispatcherClient();
21 virtual ~DesktopDispatcherClient(); 20 virtual ~DesktopDispatcherClient();
22 21
23 virtual void RunWithDispatcher( 22 virtual void PrepareNestedLoopClosures(
24 base::MessagePumpDispatcher* dispatcher) OVERRIDE; 23 base::MessagePumpDispatcher* dispatcher,
25 virtual void QuitNestedMessageLoop() OVERRIDE; 24 base::Closure* run_closure,
25 base::Closure* quit_closure) OVERRIDE;
26 26
27 private: 27 private:
28 base::Closure quit_closure_;
29
30 // Used to keep track of whether the client has been destroyed while the
31 // nested loop was running.
32 base::WeakPtrFactory<DesktopDispatcherClient> weak_ptr_factory_;
33
34 DISALLOW_COPY_AND_ASSIGN(DesktopDispatcherClient); 28 DISALLOW_COPY_AND_ASSIGN(DesktopDispatcherClient);
35 }; 29 };
36 30
37 } // namespace views 31 } // namespace views
38 32
39 #endif // UI_VIEWS_WIDGET_DESKTOP_AURA_DESKTOP_DISPATCHER_CLIENT_H_ 33 #endif // UI_VIEWS_WIDGET_DESKTOP_AURA_DESKTOP_DISPATCHER_CLIENT_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698