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

Unified Diff: chrome/browser/profile_resetter/profile_reset_global_error.h

Issue 62193002: Integrate UI and reset logic into AutomaticProfileResetter. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Added unit tests, some other smaller changes. Created 7 years, 1 month 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
Index: chrome/browser/profile_resetter/profile_reset_global_error.h
diff --git a/chrome/browser/profile_resetter/profile_reset_global_error.h b/chrome/browser/profile_resetter/profile_reset_global_error.h
index 8b356962f817d376b8d3feabc25c5c63a9023aa1..674795ee39a16fa3a4d1232ffbc6033f9a39f9c9 100644
--- a/chrome/browser/profile_resetter/profile_reset_global_error.h
+++ b/chrome/browser/profile_resetter/profile_reset_global_error.h
@@ -9,6 +9,7 @@
#include "base/memory/weak_ptr.h"
#include "chrome/browser/ui/global_error/global_error.h"
+class AutomaticProfileResetter;
class GlobalErrorBubbleViewBase;
class Profile;
@@ -45,9 +46,12 @@ class ProfileResetGlobalError
private:
Profile* profile_;
- // The number of times we have shown the bubble so far. This can be >1 if the
- // user dismissed the bubble, then selected the menu item to show it again.
- int num_times_bubble_view_shown_;
+ // GlobalErrorServic owns us, on which AutomaticProfileResetter depends, so it
+ // can go out of scope before we are destroyed.
+ base::WeakPtr<AutomaticProfileResetter> automatic_profile_resetter_;
+
+ // Whether or not we have already shown the bubble.
+ bool has_shown_bubble_view_;
// The reset bubble, if we're currently showing one.
GlobalErrorBubbleViewBase* bubble_view_;

Powered by Google App Engine
This is Rietveld 408576698