[SCM] WebKit Debian packaging branch, debian/experimental, updated. upstream/1.3.3-9427-gc2be6fc
joepeck at webkit.org
joepeck at webkit.org
Wed Dec 22 12:07:34 UTC 2010
The following commit has been merged in the debian/experimental branch:
commit 886b676bb4341cb98647796020926bfc253989fb
Author: joepeck at webkit.org <joepeck at webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date: Sun Aug 15 20:15:04 2010 +0000
2010-08-14 Joseph Pecoraro <joepeck at webkit.org>
Reviewed by Pavel Feldman.
Web Inspector: -[WebInspector attach] and detach should work
https://bugs.webkit.org/show_bug.cgi?id=43924
* WebKit.xcodeproj/project.pbxproj: Added WebInspectorFrontend.{h,mm}.
2010-08-14 Joseph Pecoraro <joepeck at webkit.org>
Reviewed by Pavel Feldman.
Web Inspector: -[WebInspector attach] and detach should work
https://bugs.webkit.org/show_bug.cgi?id=43924
For actions that relate only to the Web Inspector's Frontend
window (actions on the InspectorFrontendClient) the new Obj-C
wrapper class WebInspectorFrontend can be used. For now, this
is just attach and detach.
* WebCoreSupport/WebInspectorClient.mm:
(WebInspectorClient::openInspectorFrontend): setup and attach the WebInspectorFrontend to the WebInspector.
* WebInspector/WebInspector.h:
* WebInspector/WebInspector.mm:
(-[WebInspector dealloc]):
(-[WebInspector attach:]): delegate to the frontend.
(-[WebInspector detach:]): delegate to the frontend.
(-[WebInspector setFrontend:]):
* WebInspector/WebInspectorFrontend.h: Added.
* WebInspector/WebInspectorFrontend.mm: Added.
(-[WebInspectorFrontend initWithFrontendClient:]):
(-[WebInspectorFrontend attach]):
(-[WebInspectorFrontend detach]):
* WebInspector/WebInspectorPrivate.h:
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@65383 268f45cc-cd09-0410-ab3c-d52691b4dbfc
diff --git a/WebKit/ChangeLog b/WebKit/ChangeLog
index 904f2a0..200301e 100644
--- a/WebKit/ChangeLog
+++ b/WebKit/ChangeLog
@@ -1,3 +1,12 @@
+2010-08-14 Joseph Pecoraro <joepeck at webkit.org>
+
+ Reviewed by Pavel Feldman.
+
+ Web Inspector: -[WebInspector attach] and detach should work
+ https://bugs.webkit.org/show_bug.cgi?id=43924
+
+ * WebKit.xcodeproj/project.pbxproj: Added WebInspectorFrontend.{h,mm}.
+
2010-08-14 Patrick Gansterer <paroga at paroga.com>
Reviewed by Kenneth Rohde Christiansen.
diff --git a/WebKit/WebKit.xcodeproj/project.pbxproj b/WebKit/WebKit.xcodeproj/project.pbxproj
index bad03b6..2db6c86 100644
--- a/WebKit/WebKit.xcodeproj/project.pbxproj
+++ b/WebKit/WebKit.xcodeproj/project.pbxproj
@@ -329,6 +329,8 @@
ABDDF20D08EB0DDC001E1241 /* WebDownloadInternal.h in Headers */ = {isa = PBXBuildFile; fileRef = ABDDF20C08EB0DDC001E1241 /* WebDownloadInternal.h */; };
B6CE5C24100BC5CE00219936 /* WebApplicationCache.mm in Sources */ = {isa = PBXBuildFile; fileRef = B68049720FFBCEC1009F7F62 /* WebApplicationCache.mm */; };
B6CE5C25100BC5F500219936 /* WebApplicationCache.h in Headers */ = {isa = PBXBuildFile; fileRef = B68049710FFBCEC1009F7F62 /* WebApplicationCache.h */; settings = {ATTRIBUTES = (Private, ); }; };
+ B804176F1217A83100466BAE /* WebInspectorFrontend.h in Headers */ = {isa = PBXBuildFile; fileRef = B804176D1217A83100466BAE /* WebInspectorFrontend.h */; };
+ B80417701217A83100466BAE /* WebInspectorFrontend.mm in Sources */ = {isa = PBXBuildFile; fileRef = B804176E1217A83100466BAE /* WebInspectorFrontend.mm */; };
BC26C69E10B743F400B687ED /* WebSerializedJSValue.h in Headers */ = {isa = PBXBuildFile; fileRef = BC26C69D10B743F400B687ED /* WebSerializedJSValue.h */; settings = {ATTRIBUTES = (Private, ); }; };
BC26C6A510B7447A00B687ED /* WebSerializedJSValue.mm in Sources */ = {isa = PBXBuildFile; fileRef = BC26C6A410B7447A00B687ED /* WebSerializedJSValue.mm */; };
BC2E464D0FD8A96800A9D9DE /* WebViewData.h in Headers */ = {isa = PBXBuildFile; fileRef = BC2E464B0FD8A96800A9D9DE /* WebViewData.h */; };
@@ -625,6 +627,8 @@
ABDDF20C08EB0DDC001E1241 /* WebDownloadInternal.h */ = {isa = PBXFileReference; fileEncoding = 30; indentWidth = 4; lastKnownFileType = sourcecode.c.h; path = WebDownloadInternal.h; sourceTree = "<group>"; tabWidth = 8; usesTabs = 0; };
B68049710FFBCEC1009F7F62 /* WebApplicationCache.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WebApplicationCache.h; sourceTree = "<group>"; };
B68049720FFBCEC1009F7F62 /* WebApplicationCache.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = WebApplicationCache.mm; sourceTree = "<group>"; };
+ B804176D1217A83100466BAE /* WebInspectorFrontend.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WebInspectorFrontend.h; sourceTree = "<group>"; };
+ B804176E1217A83100466BAE /* WebInspectorFrontend.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = WebInspectorFrontend.mm; sourceTree = "<group>"; };
BC26C69D10B743F400B687ED /* WebSerializedJSValue.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WebSerializedJSValue.h; sourceTree = "<group>"; };
BC26C6A410B7447A00B687ED /* WebSerializedJSValue.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = WebSerializedJSValue.mm; sourceTree = "<group>"; };
BC2E464B0FD8A96800A9D9DE /* WebViewData.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WebViewData.h; sourceTree = "<group>"; };
@@ -871,6 +875,8 @@
5D7BF8120C2A1D90008CE06D /* WebInspector.h */,
5D7BF8130C2A1D90008CE06D /* WebInspector.mm */,
7A8FF0D01075024A00A80A08 /* WebInspectorPrivate.h */,
+ B804176D1217A83100466BAE /* WebInspectorFrontend.h */,
+ B804176E1217A83100466BAE /* WebInspectorFrontend.mm */,
1C68F663095B5FC100C2984E /* WebNodeHighlight.h */,
1C68F664095B5FC100C2984E /* WebNodeHighlight.mm */,
1C68F665095B5FC100C2984E /* WebNodeHighlightView.h */,
@@ -1575,6 +1581,7 @@
A5DEFC0F11D5343E00885273 /* WebDatabaseQuotaManager.h in Headers */,
A5DEFC1311D5344B00885273 /* WebApplicationCacheQuotaManager.h in Headers */,
A57E2F24120749E600048DF3 /* WebQuotaManager.h in Headers */,
+ B804176F1217A83100466BAE /* WebInspectorFrontend.h in Headers */,
);
runOnlyForDeploymentPostprocessing = 0;
};
@@ -1937,6 +1944,7 @@
A5DEFC0A11D5331C00885273 /* WebSecurityOrigin.mm in Sources */,
A5DEFC1011D5343E00885273 /* WebDatabaseQuotaManager.mm in Sources */,
A5DEFC1411D5344B00885273 /* WebApplicationCacheQuotaManager.mm in Sources */,
+ B80417701217A83100466BAE /* WebInspectorFrontend.mm in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
diff --git a/WebKit/mac/ChangeLog b/WebKit/mac/ChangeLog
index 7b6f5c5..1684748 100644
--- a/WebKit/mac/ChangeLog
+++ b/WebKit/mac/ChangeLog
@@ -1,3 +1,30 @@
+2010-08-14 Joseph Pecoraro <joepeck at webkit.org>
+
+ Reviewed by Pavel Feldman.
+
+ Web Inspector: -[WebInspector attach] and detach should work
+ https://bugs.webkit.org/show_bug.cgi?id=43924
+
+ For actions that relate only to the Web Inspector's Frontend
+ window (actions on the InspectorFrontendClient) the new Obj-C
+ wrapper class WebInspectorFrontend can be used. For now, this
+ is just attach and detach.
+
+ * WebCoreSupport/WebInspectorClient.mm:
+ (WebInspectorClient::openInspectorFrontend): setup and attach the WebInspectorFrontend to the WebInspector.
+ * WebInspector/WebInspector.h:
+ * WebInspector/WebInspector.mm:
+ (-[WebInspector dealloc]):
+ (-[WebInspector attach:]): delegate to the frontend.
+ (-[WebInspector detach:]): delegate to the frontend.
+ (-[WebInspector setFrontend:]):
+ * WebInspector/WebInspectorFrontend.h: Added.
+ * WebInspector/WebInspectorFrontend.mm: Added.
+ (-[WebInspectorFrontend initWithFrontendClient:]):
+ (-[WebInspectorFrontend attach]):
+ (-[WebInspectorFrontend detach]):
+ * WebInspector/WebInspectorPrivate.h:
+
2010-08-13 Gavin Barraclough <barraclough at apple.com>
Rubber stamped by Sam Weinig.
diff --git a/WebKit/mac/WebCoreSupport/WebInspectorClient.mm b/WebKit/mac/WebCoreSupport/WebInspectorClient.mm
index d59109e..7cae8fc 100644
--- a/WebKit/mac/WebCoreSupport/WebInspectorClient.mm
+++ b/WebKit/mac/WebCoreSupport/WebInspectorClient.mm
@@ -33,6 +33,8 @@
#import "WebFrameInternal.h"
#import "WebFrameView.h"
#import "WebInspector.h"
+#import "WebInspectorPrivate.h"
+#import "WebInspectorFrontend.h"
#import "WebLocalizableStrings.h"
#import "WebNodeHighlight.h"
#import "WebUIDelegate.h"
@@ -98,8 +100,12 @@ void WebInspectorClient::openInspectorFrontend(InspectorController* inspectorCon
{
RetainPtr<WebInspectorWindowController> windowController(AdoptNS, [[WebInspectorWindowController alloc] initWithInspectedWebView:m_webView]);
[windowController.get() setInspectorClient:this];
+
m_frontendPage = core([windowController.get() webView]);
- m_frontendPage->inspectorController()->setInspectorFrontendClient(new WebInspectorFrontendClient(m_webView, windowController.get(), inspectorController, m_frontendPage));
+ WebInspectorFrontendClient* frontendClient = new WebInspectorFrontendClient(m_webView, windowController.get(), inspectorController, m_frontendPage);
+ m_frontendPage->inspectorController()->setInspectorFrontendClient(frontendClient);
+
+ [[m_webView inspector] setFrontend:[[WebInspectorFrontend alloc] initWithFrontendClient:frontendClient]];
}
void WebInspectorClient::highlight(Node* node)
diff --git a/WebKit/mac/WebInspector/WebInspector.h b/WebKit/mac/WebInspector/WebInspector.h
index fa13c8d..ed78ed7 100644
--- a/WebKit/mac/WebInspector/WebInspector.h
+++ b/WebKit/mac/WebInspector/WebInspector.h
@@ -29,10 +29,12 @@
#import <Foundation/NSObject.h>
@class WebView;
+ at class WebInspectorFrontend;
@interface WebInspector : NSObject
{
WebView *_webView;
+ WebInspectorFrontend *_frontend;
}
- (id)initWithWebView:(WebView *)webView;
- (void)webViewClosed;
diff --git a/WebKit/mac/WebInspector/WebInspector.mm b/WebKit/mac/WebInspector/WebInspector.mm
index 9b17459..f109e15 100644
--- a/WebKit/mac/WebInspector/WebInspector.mm
+++ b/WebKit/mac/WebInspector/WebInspector.mm
@@ -30,6 +30,7 @@
#import "WebFrameInternal.h"
#import "WebInspectorPrivate.h"
+#import "WebInspectorFrontend.h"
#include <WebCore/Document.h>
#include <WebCore/Frame.h>
@@ -47,6 +48,12 @@ using namespace WebCore;
return self;
}
+- (void)dealloc
+{
+ [_frontend release];
+ [super dealloc];
+}
+
- (void)webViewClosed
{
_webView = nil;
@@ -175,10 +182,12 @@ using namespace WebCore;
- (void)attach:(id)sender
{
+ [_frontend attach];
}
- (void)detach:(id)sender
{
+ [_frontend detach];
}
- (void)evaluateInFrontend:(id)sender callId:(long)callId script:(NSString *)script
@@ -186,6 +195,12 @@ using namespace WebCore;
if (Page* page = core(_webView))
page->inspectorController()->evaluateForTestInFrontend(callId, script);
}
+
+- (void)setFrontend:(WebInspectorFrontend *)frontend
+{
+ [_frontend release];
+ _frontend = [frontend retain];
+}
@end
@implementation WebInspector (Obsolete)
diff --git a/WebKit/mac/WebInspector/WebInspectorFrontend.h b/WebKit/mac/WebInspector/WebInspectorFrontend.h
new file mode 100644
index 0000000..93bed84
--- /dev/null
+++ b/WebKit/mac/WebInspector/WebInspectorFrontend.h
@@ -0,0 +1,35 @@
+/*
+ * 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. ``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
+ * 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.
+ */
+
+class WebInspectorFrontendClient;
+
+ at interface WebInspectorFrontend : NSObject {
+ at private
+ WebInspectorFrontendClient *m_frontendClient;
+}
+- (id)initWithFrontendClient:(WebInspectorFrontendClient *)frontendClient;
+- (void)attach;
+- (void)detach;
+ at end
diff --git a/WebKit/mac/WebInspector/WebInspectorFrontend.mm b/WebKit/mac/WebInspector/WebInspectorFrontend.mm
new file mode 100644
index 0000000..91caa64
--- /dev/null
+++ b/WebKit/mac/WebInspector/WebInspectorFrontend.mm
@@ -0,0 +1,51 @@
+/*
+ * 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. ``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
+ * 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.
+ */
+
+#import "WebInspectorFrontend.h"
+
+#import "WebInspectorClient.h"
+
+ at implementation WebInspectorFrontend
+
+- (id)initWithFrontendClient:(WebInspectorFrontendClient *)frontendClient;
+{
+ if (!(self = [super init]))
+ return nil;
+
+ m_frontendClient = frontendClient;
+ return self;
+}
+
+- (void)attach
+{
+ m_frontendClient->attachWindow();
+}
+
+- (void)detach
+{
+ m_frontendClient->detachWindow();
+}
+
+ at end
diff --git a/WebKit/mac/WebInspector/WebInspectorPrivate.h b/WebKit/mac/WebInspector/WebInspectorPrivate.h
index d18f804..df1e286 100644
--- a/WebKit/mac/WebInspector/WebInspectorPrivate.h
+++ b/WebKit/mac/WebInspector/WebInspectorPrivate.h
@@ -30,6 +30,9 @@
#import <WebKit/WebInspector.h>
+ at class WebInspectorFrontend;
+
@interface WebInspector (WebPrivate)
- (void)evaluateInFrontend:(id)sender callId:(long)callId script:(NSString *)script;
+- (void)setFrontend:(WebInspectorFrontend *)frontend;
@end
--
WebKit Debian packaging
More information about the Pkg-webkit-commits
mailing list