OLD | NEW |
---|---|
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 #include "webkit/glue/webcursor.h" | 5 #include "webkit/glue/webcursor.h" |
6 | 6 |
7 #import <AppKit/AppKit.h> | 7 #import <AppKit/AppKit.h> |
8 #include <Carbon/Carbon.h> | 8 #include <Carbon/Carbon.h> |
9 | 9 |
10 #include "base/logging.h" | 10 #include "base/logging.h" |
11 #include "base/mac/mac_util.h" | 11 #include "base/mac/mac_util.h" |
12 #include "base/mac/scoped_cftyperef.h" | 12 #include "base/mac/scoped_cftyperef.h" |
13 #include "base/memory/scoped_nsobject.h" | 13 #include "base/memory/scoped_nsobject.h" |
14 #include "grit/webkit_chromium_resources.h" | 14 #include "grit/webkit_chromium_resources.h" |
15 #include "skia/ext/skia_utils_mac.h" | 15 #include "skia/ext/skia_utils_mac.h" |
16 #include "third_party/WebKit/Source/WebKit/chromium/public/WebCursorInfo.h" | 16 #include "third_party/WebKit/Source/WebKit/chromium/public/WebCursorInfo.h" |
17 #include "third_party/WebKit/Source/WebKit/chromium/public/platform/WebImage.h" | 17 #include "third_party/WebKit/Source/WebKit/chromium/public/platform/WebImage.h" |
18 #include "third_party/WebKit/Source/WebKit/chromium/public/platform/WebSize.h" | 18 #include "third_party/WebKit/Source/WebKit/chromium/public/platform/WebSize.h" |
19 #include "ui/base/resource/resource_bundle.h" | 19 #include "ui/base/resource/resource_bundle.h" |
20 | 20 |
21 | |
22 // The 10.7 SDK no longer has QuickDraw headers. | |
23 // http://developer.apple.com/legacy/mac/library/documentation/Carbon/reference/ QuickDraw_Ref/QuickDraw_Ref.pdf | |
24 typedef short Bits16[16]; | |
25 struct Cursor { | |
Mark Mentovai
2012/07/26 22:41:10
SDK version check for sure, or you’ll have conflic
Nico
2012/07/26 22:45:12
Done.
| |
26 Bits16 data; | |
27 Bits16 mask; | |
28 Point hotSpot; | |
29 }; | |
30 | |
21 using WebKit::WebCursorInfo; | 31 using WebKit::WebCursorInfo; |
22 using WebKit::WebImage; | 32 using WebKit::WebImage; |
23 using WebKit::WebSize; | 33 using WebKit::WebSize; |
24 | 34 |
25 // Declare symbols that are part of the 10.7 SDK. | 35 // Declare symbols that are part of the 10.7 SDK. |
26 #if !defined(MAC_OS_X_VERSION_10_7) || \ | 36 #if !defined(MAC_OS_X_VERSION_10_7) || \ |
27 MAC_OS_X_VERSION_MAX_ALLOWED < MAC_OS_X_VERSION_10_7 | 37 MAC_OS_X_VERSION_MAX_ALLOWED < MAC_OS_X_VERSION_10_7 |
28 | 38 |
29 @interface NSCursor (LionSDKDeclarations) | 39 @interface NSCursor (LionSDKDeclarations) |
30 + (NSCursor*)IBeamCursorForVerticalLayout; | 40 + (NSCursor*)IBeamCursorForVerticalLayout; |
(...skipping 503 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
534 return true; | 544 return true; |
535 } | 545 } |
536 | 546 |
537 void WebCursor::CleanupPlatformData() { | 547 void WebCursor::CleanupPlatformData() { |
538 return; | 548 return; |
539 } | 549 } |
540 | 550 |
541 void WebCursor::CopyPlatformData(const WebCursor& other) { | 551 void WebCursor::CopyPlatformData(const WebCursor& other) { |
542 return; | 552 return; |
543 } | 553 } |
OLD | NEW |