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

Side by Side Diff: ash/display/resolution_notification_controller.h

Issue 22960004: Fix the crash bug of close button for the resolution change notification. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: cleanup Created 7 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | ash/display/resolution_notification_controller.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 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 ASH_DISPLAY_RESOLUTION_NOTIFICATION_CONTROLLER_H_ 5 #ifndef ASH_DISPLAY_RESOLUTION_NOTIFICATION_CONTROLLER_H_
6 #define ASH_DISPLAY_RESOLUTION_NOTIFICATION_CONTROLLER_H_ 6 #define ASH_DISPLAY_RESOLUTION_NOTIFICATION_CONTROLLER_H_
7 7
8 #include "ash/ash_export.h" 8 #include "ash/ash_export.h"
9 #include "ash/display/display_controller.h" 9 #include "ash/display/display_controller.h"
10 #include "base/callback.h" 10 #include "base/callback.h"
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
43 int64 display_id, 43 int64 display_id,
44 const gfx::Size& old_resolution, 44 const gfx::Size& old_resolution,
45 const gfx::Size& new_resolution, 45 const gfx::Size& new_resolution,
46 const base::Closure& accept_callback); 46 const base::Closure& accept_callback);
47 47
48 // Returns true if the notification is visible or scheduled to be visible and 48 // Returns true if the notification is visible or scheduled to be visible and
49 // the notification times out. 49 // the notification times out.
50 bool DoesNotificationTimeout(); 50 bool DoesNotificationTimeout();
51 51
52 // Called by the notification delegate when the user accepts the display 52 // Called by the notification delegate when the user accepts the display
53 // resolution change. 53 // resolution change. Set |close_notification| to true when the notification
54 void AcceptResolutionChange(); 54 // should be removed at the same time.
oshima 2013/08/13 01:10:03 nit s/at the same time/upon invocation/ (or just
Jun Mukai 2013/08/13 02:24:11 Done.
55 void AcceptResolutionChange(bool close_notification);
55 56
56 // Called by the notification delegate when the user wants to revert the 57 // Called by the notification delegate when the user wants to revert the
57 // display resolution change. 58 // display resolution change.
58 void RevertResolutionChange(); 59 void RevertResolutionChange();
59 60
60 private: 61 private:
61 friend class ResolutionNotificationControllerTest; 62 friend class ResolutionNotificationControllerTest;
62 FRIEND_TEST_ALL_PREFIXES(ResolutionNotificationControllerTest, Timeout); 63 FRIEND_TEST_ALL_PREFIXES(ResolutionNotificationControllerTest, Timeout);
63 FRIEND_TEST_ALL_PREFIXES(chromeos::DisplayPreferencesTest, PreventStore); 64 FRIEND_TEST_ALL_PREFIXES(chromeos::DisplayPreferencesTest, PreventStore);
64 65
(...skipping 21 matching lines...) Expand all
86 87
87 scoped_ptr<ResolutionChangeInfo> change_info_; 88 scoped_ptr<ResolutionChangeInfo> change_info_;
88 89
89 DISALLOW_COPY_AND_ASSIGN(ResolutionNotificationController); 90 DISALLOW_COPY_AND_ASSIGN(ResolutionNotificationController);
90 }; 91 };
91 92
92 } // namespace internal 93 } // namespace internal
93 } // namespace ash 94 } // namespace ash
94 95
95 #endif // ASH_DISPLAY_RESOLUTION_NOTIFICATION_CONTROLLER_H_ 96 #endif // ASH_DISPLAY_RESOLUTION_NOTIFICATION_CONTROLLER_H_
OLDNEW
« no previous file with comments | « no previous file | ash/display/resolution_notification_controller.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698