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

Side by Side Diff: ui/gfx/native_widget_types.h

Issue 2378423002: Mac: Fix Sierra solid color layer color-mismatch (Closed)
Patch Set: More constexpr Created 4 years, 2 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
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 UI_GFX_NATIVE_WIDGET_TYPES_H_ 5 #ifndef UI_GFX_NATIVE_WIDGET_TYPES_H_
6 #define UI_GFX_NATIVE_WIDGET_TYPES_H_ 6 #define UI_GFX_NATIVE_WIDGET_TYPES_H_
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include "base/logging.h" 10 #include "base/logging.h"
(...skipping 177 matching lines...) Expand 10 before | Expand all | Expand 10 after
188 // Note: for test_shell we're packing a pointer into the NativeViewId. So, if 188 // Note: for test_shell we're packing a pointer into the NativeViewId. So, if
189 // you make it a type which is smaller than a pointer, you have to fix 189 // you make it a type which is smaller than a pointer, you have to fix
190 // test_shell. 190 // test_shell.
191 // 191 //
192 // See comment at the top of the file for usage. 192 // See comment at the top of the file for usage.
193 typedef intptr_t NativeViewId; 193 typedef intptr_t NativeViewId;
194 194
195 // AcceleratedWidget provides a surface to compositors to paint pixels. 195 // AcceleratedWidget provides a surface to compositors to paint pixels.
196 #if defined(OS_WIN) 196 #if defined(OS_WIN)
197 typedef HWND AcceleratedWidget; 197 typedef HWND AcceleratedWidget;
198 const AcceleratedWidget kNullAcceleratedWidget = NULL; 198 constexpr AcceleratedWidget kNullAcceleratedWidget = NULL;
199 #elif defined(USE_X11) 199 #elif defined(USE_X11)
200 typedef unsigned long AcceleratedWidget; 200 typedef unsigned long AcceleratedWidget;
201 const AcceleratedWidget kNullAcceleratedWidget = 0; 201 constexpr AcceleratedWidget kNullAcceleratedWidget = 0;
202 #elif defined(OS_IOS) 202 #elif defined(OS_IOS)
203 typedef UIView* AcceleratedWidget; 203 typedef UIView* AcceleratedWidget;
204 const AcceleratedWidget kNullAcceleratedWidget = 0; 204 constexpr AcceleratedWidget kNullAcceleratedWidget = 0;
205 #elif defined(OS_MACOSX) 205 #elif defined(OS_MACOSX)
206 typedef NSView* AcceleratedWidget; 206 typedef NSView* AcceleratedWidget;
207 const AcceleratedWidget kNullAcceleratedWidget = 0; 207 constexpr AcceleratedWidget kNullAcceleratedWidget = 0;
208 #elif defined(OS_ANDROID) 208 #elif defined(OS_ANDROID)
209 typedef ANativeWindow* AcceleratedWidget; 209 typedef ANativeWindow* AcceleratedWidget;
210 const AcceleratedWidget kNullAcceleratedWidget = 0; 210 constexpr AcceleratedWidget kNullAcceleratedWidget = 0;
211 #elif defined(USE_OZONE) 211 #elif defined(USE_OZONE)
212 typedef int32_t AcceleratedWidget; 212 typedef int32_t AcceleratedWidget;
213 const AcceleratedWidget kNullAcceleratedWidget = 0; 213 constexpr AcceleratedWidget kNullAcceleratedWidget = 0;
214 #else 214 #else
215 #error unknown platform 215 #error unknown platform
216 #endif 216 #endif
217 217
218 } // namespace gfx 218 } // namespace gfx
219 219
220 #endif // UI_GFX_NATIVE_WIDGET_TYPES_H_ 220 #endif // UI_GFX_NATIVE_WIDGET_TYPES_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698