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

Unified Diff: Source/platform/geometry/FloatRect.h

Issue 208333020: [Mac] Rely on science, not chance, to get the proper definition of the macro (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « Source/platform/geometry/FloatPoint.h ('k') | Source/platform/geometry/FloatSize.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/platform/geometry/FloatRect.h
diff --git a/Source/platform/geometry/FloatRect.h b/Source/platform/geometry/FloatRect.h
index c7e2948096e3d49fea9c17ad94cffe1af9813768..661ca88a9ecfef63abfe8f6dcc9a1c5c4101891e 100644
--- a/Source/platform/geometry/FloatRect.h
+++ b/Source/platform/geometry/FloatRect.h
@@ -32,10 +32,9 @@
#if OS(MACOSX)
typedef struct CGRect CGRect;
-#ifdef NSGEOMETRY_TYPES_SAME_AS_CGGEOMETRY_TYPES
-typedef struct CGRect NSRect;
-#else
-typedef struct _NSRect NSRect;
+
+#ifdef __OBJC__
+#import <Foundation/Foundation.h>
#endif
#endif
@@ -167,7 +166,7 @@ public:
#if OS(MACOSX)
FloatRect(const CGRect&);
operator CGRect() const;
-#if !defined(NSGEOMETRY_TYPES_SAME_AS_CGGEOMETRY_TYPES)
+#if defined(__OBJC__) && !defined(NSGEOMETRY_TYPES_SAME_AS_CGGEOMETRY_TYPES)
FloatRect(const NSRect&);
operator NSRect() const;
#endif
« no previous file with comments | « Source/platform/geometry/FloatPoint.h ('k') | Source/platform/geometry/FloatSize.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698