[SCM] WebKit Debian packaging branch, debian/experimental, updated. upstream/1.3.3-9427-gc2be6fc
mrowe at apple.com
mrowe at apple.com
Wed Dec 22 12:55:36 UTC 2010
The following commit has been merged in the debian/experimental branch:
commit ae7fe7500cbe9c8c1a1b5eeb46e02f6e6ade15f8
Author: mrowe at apple.com <mrowe at apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date: Thu Sep 2 02:23:06 2010 +0000
<rdar://problem/8374711> WebKit needs to compile without access to QuickDraw private headers.
Reviewed by Adam Roben.
* Carbon/HIViewAdapter.m:
* Carbon/HIWebView.mm:
* Misc/QuickDrawCompatibility.h: Added.
* Plugins/WebNetscapePluginView.mm:
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@66633 268f45cc-cd09-0410-ab3c-d52691b4dbfc
diff --git a/WebKit/mac/Carbon/HIViewAdapter.m b/WebKit/mac/Carbon/HIViewAdapter.m
index 39ff426..565be4f 100644
--- a/WebKit/mac/Carbon/HIViewAdapter.m
+++ b/WebKit/mac/Carbon/HIViewAdapter.m
@@ -30,15 +30,10 @@
#import "HIViewAdapter.h"
+#import "QuickDrawCompatibility.h"
#import "WebNSObjectExtras.h"
#import <wtf/Assertions.h>
-// FIXME: Remove this when we have a solution for <rdar://problem/8374711>.
-#if !defined(BUILDING_ON_TIGER) && !defined(BUILDING_ON_LEOPARD) && !defined(BUILDING_ON_SNOW_LEOPARD)
-#define __LP64__ 0
-#include <QD/QuickdrawPriv.h>
-#endif
-
static void SetViewNeedsDisplay(HIViewRef inView, RgnHandle inRegion, Boolean inNeedsDisplay);
#define WATCH_INVALIDATION 0
diff --git a/WebKit/mac/Carbon/HIWebView.mm b/WebKit/mac/Carbon/HIWebView.mm
index e0fbc2f..a3cdc66 100644
--- a/WebKit/mac/Carbon/HIWebView.mm
+++ b/WebKit/mac/Carbon/HIWebView.mm
@@ -32,17 +32,12 @@
#import "CarbonWindowAdapter.h"
#import "HIViewAdapter.h"
+#import "QuickDrawCompatibility.h"
#import "WebHTMLViewInternal.h"
#import "WebKit.h"
#import <WebKitSystemInterface.h>
#import <objc/objc-runtime.h>
-// FIXME: Remove this when we have a solution for <rdar://problem/8374711>.
-#if !defined(BUILDING_ON_TIGER) && !defined(BUILDING_ON_LEOPARD) && !defined(BUILDING_ON_SNOW_LEOPARD)
-#define __LP64__ 0
-#include <QD/QuickdrawPriv.h>
-#endif
-
@interface NSWindow (AppKitSecretsHIWebViewKnows)
- (void)_removeWindowRef;
@end
diff --git a/WebKit/mac/ChangeLog b/WebKit/mac/ChangeLog
index 1eb0da1..3503a70 100644
--- a/WebKit/mac/ChangeLog
+++ b/WebKit/mac/ChangeLog
@@ -1,3 +1,14 @@
+2010-09-01 Mark Rowe <mrowe at apple.com>
+
+ Reviewed by Adam Roben.
+
+ <rdar://problem/8374711> WebKit needs to compile without access to QuickDraw private headers.
+
+ * Carbon/HIViewAdapter.m:
+ * Carbon/HIWebView.mm:
+ * Misc/QuickDrawCompatibility.h: Added.
+ * Plugins/WebNetscapePluginView.mm:
+
2010-08-31 Dave Hyatt <hyatt at apple.com>
Reviewed by Sam Weinig.
diff --git a/WebKit/mac/Misc/QuickDrawCompatibility.h b/WebKit/mac/Misc/QuickDrawCompatibility.h
new file mode 100644
index 0000000..1a4ff99
--- /dev/null
+++ b/WebKit/mac/Misc/QuickDrawCompatibility.h
@@ -0,0 +1,96 @@
+/*
+ * Copyright (C) 2010 Apple Inc. All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS''
+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
+ * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+ * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS
+ * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+ * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+ * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
+ * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
+ * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
+ * THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#ifndef QuickDrawCompatibility_h
+#define QuickDrawCompatibility_h
+
+#ifndef __LP64__
+
+#import <Carbon/Carbon.h>
+
+#if defined(QD_HEADERS_ARE_PRIVATE) && QD_HEADERS_ARE_PRIVATE
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+#define MacSetRect SetRect
+#define MacSetRectRgn SetRectRgn
+#define MacUnionRgn UnionRgn
+
+extern Boolean EmptyRgn(RgnHandle);
+extern OSStatus CreateCGContextForPort(CGrafPtr, CGContextRef*);
+extern OSStatus SyncCGContextOriginWithPort(CGContextRef, CGrafPtr);
+extern PixMapHandle GetPortPixMap(CGrafPtr);
+extern QDErr NewGWorldFromPtr(GWorldPtr*, UInt32, const Rect*, CTabHandle, GDHandle, GWorldFlags, Ptr, SInt32);
+extern Rect* GetPortBounds(CGrafPtr, Rect*);
+extern Rect* GetRegionBounds(RgnHandle, Rect*);
+extern RgnHandle GetPortClipRegion(CGrafPtr, RgnHandle);
+extern RgnHandle GetPortVisibleRegion(CGrafPtr, RgnHandle);
+extern RgnHandle NewRgn();
+extern void BackColor(long);
+extern void DisposeGWorld(GWorldPtr);
+extern void DisposeRgn(RgnHandle);
+extern void ForeColor(long);
+extern void GetGWorld(CGrafPtr*, GDHandle*);
+extern void GetPort(GrafPtr*);
+extern void GlobalToLocal(Point*);
+extern void MacSetRect(Rect*, short, short, short, short);
+extern void MacSetRectRgn(RgnHandle, short, short, short, short);
+extern void MacUnionRgn(RgnHandle, RgnHandle, RgnHandle);
+extern void MovePortTo(short, short);
+extern void OffsetRect(Rect*, short, short);
+extern void OffsetRgn(RgnHandle, short, short);
+extern void PaintRect(const Rect*);
+extern void PenNormal();
+extern void PortSize(short, short);
+extern void RectRgn(RgnHandle, const Rect*);
+extern void SectRgn(RgnHandle, RgnHandle, RgnHandle);
+extern void SetGWorld(CGrafPtr, GDHandle);
+extern void SetOrigin(short, short);
+extern void SetPort(GrafPtr);
+extern void SetPortClipRegion(CGrafPtr, RgnHandle);
+extern void SetPortVisibleRegion(CGrafPtr, RgnHandle);
+
+enum {
+ k16BE555PixelFormat = 0x00000010,
+ k32ARGBPixelFormat = 0x00000020,
+ k16LE555PixelFormat = 'L555',
+ k32BGRAPixelFormat = 'BGRA',
+
+ blackColor = 33,
+ whiteColor = 30,
+ greenColor = 341,
+};
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif // defined(QD_HEADERS_ARE_PRIVATE) && QD_HEADERS_ARE_PRIVATE
+
+#endif // __LP64__
+
+#endif // QuickDrawCompatibility_h
diff --git a/WebKit/mac/Plugins/WebNetscapePluginView.mm b/WebKit/mac/Plugins/WebNetscapePluginView.mm
index 7f34d95..a4481bc 100644
--- a/WebKit/mac/Plugins/WebNetscapePluginView.mm
+++ b/WebKit/mac/Plugins/WebNetscapePluginView.mm
@@ -30,6 +30,7 @@
#import "WebNetscapePluginView.h"
+#import "QuickDrawCompatibility.h"
#import "WebDataSourceInternal.h"
#import "WebDefaultUIDelegate.h"
#import "WebFrameInternal.h"
@@ -80,14 +81,6 @@
#import <wtf/Threading.h>
#import <wtf/text/CString.h>
-// FIXME: Remove this when we have a solution for <rdar://problem/8374711>.
-#if !defined(BUILDING_ON_TIGER) && !defined(BUILDING_ON_LEOPARD) && !defined(BUILDING_ON_SNOW_LEOPARD)
-#ifndef __LP64__
-#define __LP64__ 0
-#endif
-#include <QD/QuickdrawPriv.h>
-#endif
-
#define LoginWindowDidSwitchFromUserNotification @"WebLoginWindowDidSwitchFromUserNotification"
#define LoginWindowDidSwitchToUserNotification @"WebLoginWindowDidSwitchToUserNotification"
#define WKNVSupportsCompositingCoreAnimationPluginsBool 74656 /* TRUE if the browser supports hardware compositing of Core Animation plug-ins */
--
WebKit Debian packaging
More information about the Pkg-webkit-commits
mailing list