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

Side by Side Diff: content/public/common/assert_matching_enums.cc

Issue 215313002: Comment enum matching assert to allow changes in Blink. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 9 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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 // Use this file to assert that *_list.h enums that are meant to do the bridge 5 // Use this file to assert that *_list.h enums that are meant to do the bridge
6 // from Blink are valid. 6 // from Blink are valid.
7 7
8 #include "base/macros.h" 8 #include "base/macros.h"
9 #include "content/public/common/screen_orientation_values.h" 9 #include "content/public/common/screen_orientation_values.h"
10 #include "third_party/WebKit/public/platform/WebScreenOrientation.h" 10 #include "third_party/WebKit/public/platform/WebScreenOrientation.h"
11 11
12 namespace content { 12 namespace content {
13 13
14 #define COMPILE_ASSERT_MATCHING_ENUM(expected, actual) \ 14 #define COMPILE_ASSERT_MATCHING_ENUM(expected, actual) \
15 COMPILE_ASSERT(int(expected) == int(actual), mismatching_enums) 15 COMPILE_ASSERT(int(expected) == int(actual), mismatching_enums)
16 16
17 COMPILE_ASSERT_MATCHING_ENUM(blink::WebScreenOrientationPortraitPrimary, 17 // TODO(mlamouri): this is temporary to allow to change the enum in Blink.
18 PORTRAIT_PRIMARY); 18 // COMPILE_ASSERT_MATCHING_ENUM(blink::WebScreenOrientationPortraitPrimary,
19 COMPILE_ASSERT_MATCHING_ENUM(blink::WebScreenOrientationLandscapePrimary, 19 // PORTRAIT_PRIMARY);
20 LANDSCAPE_PRIMARY); 20 // COMPILE_ASSERT_MATCHING_ENUM(blink::WebScreenOrientationLandscapePrimary,
21 COMPILE_ASSERT_MATCHING_ENUM(blink::WebScreenOrientationPortraitSecondary, 21 // LANDSCAPE_PRIMARY);
22 PORTRAIT_SECONDARY); 22 // COMPILE_ASSERT_MATCHING_ENUM(blink::WebScreenOrientationPortraitSecondary,
23 COMPILE_ASSERT_MATCHING_ENUM(blink::WebScreenOrientationLandscapeSecondary, 23 // PORTRAIT_SECONDARY);
24 LANDSCAPE_SECONDARY); 24 // COMPILE_ASSERT_MATCHING_ENUM(blink::WebScreenOrientationLandscapeSecondary,
25 // LANDSCAPE_SECONDARY);
25 26
26 } // namespace content 27 } // namespace content
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