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

Side by Side Diff: remoting/host/continue_window.h

Issue 11886051: Turned UiStrings into a singleton so that the continue window does not depend on ChromotingHost. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebased Created 7 years, 11 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
« no previous file with comments | « remoting/host/chromoting_host_unittest.cc ('k') | remoting/host/continue_window_gtk.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 REMOTING_HOST_CONTINUE_WINDOW_H_ 5 #ifndef REMOTING_HOST_CONTINUE_WINDOW_H_
6 #define REMOTING_HOST_CONTINUE_WINDOW_H_ 6 #define REMOTING_HOST_CONTINUE_WINDOW_H_
7 7
8 #include "base/callback.h" 8 #include "base/callback.h"
9 9
10 namespace remoting { 10 namespace remoting {
11 11
12 class ChromotingHost; 12 struct UiStrings;
13 13
14 class ContinueWindow { 14 class ContinueWindow {
15 public: 15 public:
16 // ContinueSessionCallback is called when the user clicks on the 16 // ContinueSessionCallback is called when the user clicks on the
17 // Continue button to resume the session, or dismisses the window to 17 // Continue button to resume the session, or dismisses the window to
18 // terminate the session. This callback is provided as a parameter to the 18 // terminate the session. This callback is provided as a parameter to the
19 // Show() method, and will be triggered on the UI thread. 19 // Show() method, and will be triggered on the UI thread.
20 typedef base::Callback<void(bool)> ContinueSessionCallback; 20 typedef base::Callback<void(bool)> ContinueSessionCallback;
21 21
22 virtual ~ContinueWindow() {} 22 virtual ~ContinueWindow() {}
23 23
24 // Show the continuation window requesting that the user approve continuing 24 // Show the continuation window requesting that the user approve continuing
25 // the session. 25 // the session.
26 virtual void Show(ChromotingHost* host, 26 virtual void Show(const ContinueSessionCallback& callback) = 0;
27 const ContinueSessionCallback& callback) = 0;
28 27
29 // Hide the continuation window if it is visible. 28 // Hide the continuation window if it is visible.
30 virtual void Hide() = 0; 29 virtual void Hide() = 0;
31 30
32 static scoped_ptr<ContinueWindow> Create(); 31 static scoped_ptr<ContinueWindow> Create(const UiStrings* ui_strings);
33 }; 32 };
34 33
35 } // namespace remoting 34 } // namespace remoting
36 35
37 #endif // REMOTING_HOST_CONTINUE_WINDOW_H_ 36 #endif // REMOTING_HOST_CONTINUE_WINDOW_H_
OLDNEW
« no previous file with comments | « remoting/host/chromoting_host_unittest.cc ('k') | remoting/host/continue_window_gtk.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698