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

Unified Diff: base/mac/sdk_forward_declarations.h

Issue 15870009: mac: Move more 10.7 api stuff into sdk_forward_declarations.h (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase Created 7 years, 6 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 | « no previous file | chrome/browser/ui/cocoa/tabs/tab_view.mm » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/mac/sdk_forward_declarations.h
diff --git a/base/mac/sdk_forward_declarations.h b/base/mac/sdk_forward_declarations.h
index 4b74c36900368f91c59eb5ad5152f8a183731234..a2d4013723d2cbb5ee7a021329348984b7006560 100644
--- a/base/mac/sdk_forward_declarations.h
+++ b/base/mac/sdk_forward_declarations.h
@@ -4,10 +4,15 @@
// This file contains forward declarations for items in later SDKs than the
// default one with which Chromium is built (currently 10.6).
+// If you call any function from this header, be sure to check at runtime for
+// respondsToSelector: before calling these functions (else your code will crash
+// on older OS X versions that chrome still supports).
#ifndef BASE_MAC_SDK_FORWARD_DECLARATIONS_H_
#define BASE_MAC_SDK_FORWARD_DECLARATIONS_H_
+#import <AppKit/AppKit.h>
+
#if !defined(MAC_OS_X_VERSION_10_7) || \
MAC_OS_X_VERSION_MAX_ALLOWED < MAC_OS_X_VERSION_10_7
enum {
@@ -49,6 +54,14 @@ typedef NSUInteger NSEventSwipeTrackingOptions;
- (void)setContentsScale:(CGFloat)contentsScale;
@end
+@interface NSScreen (LionSDK)
+- (CGFloat)backingScaleFactor;
+- (NSRect)convertRectToBacking:(NSRect)aRect;
+@end
+
+@interface NSWindow (LionSDK)
+- (CGFloat)backingScaleFactor;
+@end
#endif // MAC_OS_X_VERSION_10_7
#endif // BASE_MAC_SDK_FORWARD_DECLARATIONS_H_
« no previous file with comments | « no previous file | chrome/browser/ui/cocoa/tabs/tab_view.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698