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

Side by Side Diff: chrome/common/notification_type.h

Issue 5331008: Persist 'this device is not managed' information (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix build on Windows Created 10 years 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 | « chrome/browser/policy/proto/device_management_local.proto ('k') | 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 (c) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 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_COMMON_NOTIFICATION_TYPE_H_ 5 #ifndef CHROME_COMMON_NOTIFICATION_TYPE_H_
6 #define CHROME_COMMON_NOTIFICATION_TYPE_H_ 6 #define CHROME_COMMON_NOTIFICATION_TYPE_H_
7 #pragma once 7 #pragma once
8 8
9 // This file describes various types used to describe and filter notifications 9 // This file describes various types used to describe and filter notifications
10 // that pass through the NotificationService. 10 // that pass through the NotificationService.
(...skipping 1273 matching lines...) Expand 10 before | Expand all | Expand 10 after
1284 1284
1285 // Configuration Policy ---------------------------------------------------- 1285 // Configuration Policy ----------------------------------------------------
1286 // This notification is sent whenever the administrator changes policy. 1286 // This notification is sent whenever the administrator changes policy.
1287 // The detail of this notification is not used. 1287 // The detail of this notification is not used.
1288 POLICY_CHANGED, 1288 POLICY_CHANGED,
1289 1289
1290 // This notification is sent whenever the device token becomes available 1290 // This notification is sent whenever the device token becomes available
1291 // that the policy subsystem uses to fetch policy from the cloud. 1291 // that the policy subsystem uses to fetch policy from the cloud.
1292 DEVICE_TOKEN_AVAILABLE, 1292 DEVICE_TOKEN_AVAILABLE,
1293 1293
1294 // This notification is sent whenever cloud policies are fetched and
1295 // updated. The detail of this notification is not used.
1296 CLOUD_POLICY_UPDATE,
1297
1294 // Count (must be last) ---------------------------------------------------- 1298 // Count (must be last) ----------------------------------------------------
1295 // Used to determine the number of notification types. Not valid as 1299 // Used to determine the number of notification types. Not valid as
1296 // a type parameter when registering for or posting notifications. 1300 // a type parameter when registering for or posting notifications.
1297 NOTIFICATION_TYPE_COUNT 1301 NOTIFICATION_TYPE_COUNT
1298 }; 1302 };
1299 1303
1300 // TODO(erg): Our notification system relies on implicit conversion. 1304 // TODO(erg): Our notification system relies on implicit conversion.
1301 NotificationType(Type v) : value(v) {} // NOLINT 1305 NotificationType(Type v) : value(v) {} // NOLINT
1302 1306
1303 bool operator==(NotificationType t) const { return value == t.value; } 1307 bool operator==(NotificationType t) const { return value == t.value; }
1304 bool operator!=(NotificationType t) const { return value != t.value; } 1308 bool operator!=(NotificationType t) const { return value != t.value; }
1305 1309
1306 // Comparison to explicit enum values. 1310 // Comparison to explicit enum values.
1307 bool operator==(Type v) const { return value == v; } 1311 bool operator==(Type v) const { return value == v; }
1308 bool operator!=(Type v) const { return value != v; } 1312 bool operator!=(Type v) const { return value != v; }
1309 1313
1310 Type value; 1314 Type value;
1311 }; 1315 };
1312 1316
1313 inline bool operator==(NotificationType::Type a, NotificationType b) { 1317 inline bool operator==(NotificationType::Type a, NotificationType b) {
1314 return a == b.value; 1318 return a == b.value;
1315 } 1319 }
1316 inline bool operator!=(NotificationType::Type a, NotificationType b) { 1320 inline bool operator!=(NotificationType::Type a, NotificationType b) {
1317 return a != b.value; 1321 return a != b.value;
1318 } 1322 }
1319 1323
1320 #endif // CHROME_COMMON_NOTIFICATION_TYPE_H_ 1324 #endif // CHROME_COMMON_NOTIFICATION_TYPE_H_
OLDNEW
« no previous file with comments | « chrome/browser/policy/proto/device_management_local.proto ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698