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

Unified Diff: Source/platform/geometry/IntPoint.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/FloatSize.h ('k') | Source/platform/geometry/IntRect.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/platform/geometry/IntPoint.h
diff --git a/Source/platform/geometry/IntPoint.h b/Source/platform/geometry/IntPoint.h
index 6d4d3f9a5466b811f06aa392bfb9bf204e2b7f44..206f21098f7cbb32252419828abef32176402df0 100644
--- a/Source/platform/geometry/IntPoint.h
+++ b/Source/platform/geometry/IntPoint.h
@@ -32,10 +32,9 @@
#if OS(MACOSX)
typedef struct CGPoint CGPoint;
-#ifdef NSGEOMETRY_TYPES_SAME_AS_CGGEOMETRY_TYPES
-typedef struct CGPoint NSPoint;
-#else
-typedef struct _NSPoint NSPoint;
+
+#ifdef __OBJC__
+#import <Foundation/Foundation.h>
#endif
#endif
@@ -92,7 +91,7 @@ public:
explicit IntPoint(const CGPoint&); // don't do this implicitly since it's lossy
operator CGPoint() const;
-#if !defined(NSGEOMETRY_TYPES_SAME_AS_CGGEOMETRY_TYPES)
+#if defined(__OBJC__) && !defined(NSGEOMETRY_TYPES_SAME_AS_CGGEOMETRY_TYPES)
explicit IntPoint(const NSPoint&); // don't do this implicitly since it's lossy
operator NSPoint() const;
#endif
« no previous file with comments | « Source/platform/geometry/FloatSize.h ('k') | Source/platform/geometry/IntRect.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698