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

Side by Side Diff: chrome/browser/chromeos/ui/low_disk_notification.h

Issue 2115793002: Properly initialize last_notification_severity_. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 5 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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 CHROME_BROWSER_CHROMEOS_UI_LOW_DISK_NOTIFICATION_H_ 5 #ifndef CHROME_BROWSER_CHROMEOS_UI_LOW_DISK_NOTIFICATION_H_
6 #define CHROME_BROWSER_CHROMEOS_UI_LOW_DISK_NOTIFICATION_H_ 6 #define CHROME_BROWSER_CHROMEOS_UI_LOW_DISK_NOTIFICATION_H_
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include "base/macros.h" 10 #include "base/macros.h"
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after
54 Severity GetSeverity(uint64_t free_disk_bytes); 54 Severity GetSeverity(uint64_t free_disk_bytes);
55 55
56 // Sets the MessageCenter instance to use. Should only be used in tests. 56 // Sets the MessageCenter instance to use. Should only be used in tests.
57 void SetMessageCenterForTest(message_center::MessageCenter* message_center); 57 void SetMessageCenterForTest(message_center::MessageCenter* message_center);
58 58
59 // Sets the minimum time to wait between notifications of the same severity. 59 // Sets the minimum time to wait between notifications of the same severity.
60 // Should only be used in tests. 60 // Should only be used in tests.
61 void SetNotificationIntervalForTest(base::TimeDelta interval); 61 void SetNotificationIntervalForTest(base::TimeDelta interval);
62 62
63 base::Time last_notification_time_; 63 base::Time last_notification_time_;
64 Severity last_notification_severity_; 64 Severity last_notification_severity_ = NONE;
65 message_center::MessageCenter* message_center_; 65 message_center::MessageCenter* message_center_;
66 base::TimeDelta notification_interval_; 66 base::TimeDelta notification_interval_;
67 base::ThreadChecker thread_checker_; 67 base::ThreadChecker thread_checker_;
68 base::WeakPtrFactory<LowDiskNotification> weak_ptr_factory_; 68 base::WeakPtrFactory<LowDiskNotification> weak_ptr_factory_;
69 69
70 DISALLOW_COPY_AND_ASSIGN(LowDiskNotification); 70 DISALLOW_COPY_AND_ASSIGN(LowDiskNotification);
71 }; 71 };
72 72
73 } // namespace chromeos 73 } // namespace chromeos
74 74
75 #endif // CHROME_BROWSER_CHROMEOS_UI_LOW_DISK_NOTIFICATION_H_ 75 #endif // CHROME_BROWSER_CHROMEOS_UI_LOW_DISK_NOTIFICATION_H_
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698