summaryrefslogtreecommitdiff
path: root/Source/WebKit/mac
diff options
context:
space:
mode:
authorSimon Hausmann <simon.hausmann@nokia.com>2012-05-18 14:03:11 +0200
committerSimon Hausmann <simon.hausmann@nokia.com>2012-05-18 14:03:11 +0200
commit8d473cf9743f1d30a16a27114e93bd5af5648d23 (patch)
treecdca40d0353886b3ca52f33a2d7b8f1c0011aafc /Source/WebKit/mac
parent1b914638db989aaa98631a1c1e02c7b2d44805d8 (diff)
downloadqtwebkit-8d473cf9743f1d30a16a27114e93bd5af5648d23.tar.gz
Imported WebKit commit 1350e72f7345ced9da2bd9980deeeb5a8d62fab4 (http://svn.webkit.org/repository/webkit/trunk@117578)
Weekly snapshot
Diffstat (limited to 'Source/WebKit/mac')
-rw-r--r--Source/WebKit/mac/ChangeLog165
-rw-r--r--Source/WebKit/mac/Configurations/FeatureDefines.xcconfig3
-rw-r--r--Source/WebKit/mac/Misc/WebCoreStatistics.h1
-rw-r--r--Source/WebKit/mac/Misc/WebCoreStatistics.mm5
-rw-r--r--Source/WebKit/mac/Misc/WebNSURLExtras.h2
-rw-r--r--Source/WebKit/mac/Misc/WebNSURLExtras.mm4
-rw-r--r--Source/WebKit/mac/Plugins/Hosted/ProxyInstance.h6
-rw-r--r--Source/WebKit/mac/Plugins/Hosted/ProxyInstance.mm24
-rw-r--r--Source/WebKit/mac/WebCoreSupport/WebEditorClient.h2
-rw-r--r--Source/WebKit/mac/WebCoreSupport/WebEditorClient.mm10
-rw-r--r--Source/WebKit/mac/WebCoreSupport/WebSystemInterface.mm5
-rw-r--r--Source/WebKit/mac/WebView/WebFrame.mm8
-rw-r--r--Source/WebKit/mac/WebView/WebHTMLView.mm16
13 files changed, 227 insertions, 24 deletions
diff --git a/Source/WebKit/mac/ChangeLog b/Source/WebKit/mac/ChangeLog
index f35e19a6e..7354d5073 100644
--- a/Source/WebKit/mac/ChangeLog
+++ b/Source/WebKit/mac/ChangeLog
@@ -1,3 +1,168 @@
+2012-05-18 MORITA Hajime <morrita@google.com>
+
+ Another unreviewed attempt to fix build breakage on r117572.
+
+ * WebCoreSupport/WebEditorClient.h:
+
+2012-05-18 MORITA Hajime <morrita@google.com>
+
+ https://bugs.webkit.org/show_bug.cgi?id=85515
+ Stale frame in WebCore::SpellChecker::didCheckSucceeded
+
+ Reviewed by Ryosuke Niwa.
+
+ * WebCoreSupport/WebEditorClient.h:
+
+2012-05-17 Andy Estes <aestes@apple.com>
+
+ Don't let -[CALayer renderInContext:] try to render WebView's root layer
+ https://bugs.webkit.org/show_bug.cgi?id=86773
+ <rdar://problem/10950075>
+
+ Reviewed by Dan Bernstein.
+
+ -[CALayer renderInContext:] doesn't correctly render our layer tree, so
+ don't let it try. Calling drawRect: with a bitmap context will already
+ do the right thing for WebViews.
+
+ * WebView/WebHTMLView.mm: Create a subclass of CALayer called WebLayerHostingLayer.
+ (-[WebLayerHostingLayer renderInContext:]): override renderInContext: to be a NOOP.
+ (-[WebHTMLView attachRootLayer:]): Create a WebLayerHostingLayer rather than a CALayer.
+
+2012-05-17 Hironori Bono <hbono@chromium.org>
+
+ [Refactoring] Move platform-specific code in Editor::respondToChangedSelection to the WebKit layer
+ https://bugs.webkit.org/show_bug.cgi?id=86591
+
+ Reviewed by Ryosuke Niwa.
+
+ This change adds a TextCheckerClient::shouldEraseMarkersAfterChangeSelection
+ function to remove platform-specific code from Editor::respondToChangedSelection
+ function.
+
+ No new tests, no change in behavior.
+
+ * WebCoreSupport/WebEditorClient.h:
+ * WebCoreSupport/WebEditorClient.mm:
+ (WebEditorClient::shouldEraseMarkersAfterChangeSelection):
+
+2012-05-17 Dan Bernstein <mitz@apple.com>
+
+ REGRESSION (r117428): WebKit API/SPI was removed
+ https://bugs.webkit.org/show_bug.cgi?id=86748
+
+ Reverted r117428.
+
+ * WebKit.order:
+ * WebView/WebView.mm:
+ (+[WebView _setDomainRelaxationForbidden:forURLScheme:]):
+ * WebView/WebViewPrivate.h:
+
+2012-05-17 Gyuyoung Kim <gyuyoung.kim@samsung.com>
+
+ Convert setDomainRelaxationForbiddenForURLScheme to use InternalSettings interface
+ https://bugs.webkit.org/show_bug.cgi?id=86704
+
+ Reviewed by Eric Seidel.
+
+ Remove setDomainRelaxationForbiddenForURLScheme functions, because it is able to work in the
+ cross-port way through the InternalSettings interface.
+
+ * WebKit.order:
+ * WebView/WebView.mm:
+ * WebView/WebViewPrivate.h:
+
+2012-05-15 Anders Carlsson <andersca@apple.com>
+
+ Use unaccelerated scrolling deltas when rubber-banding
+ https://bugs.webkit.org/show_bug.cgi?id=86503
+ <rdar://problem/11378742>
+
+ Reviewed by Sam Weinig.
+
+ * WebCoreSupport/WebSystemInterface.mm:
+ (InitWebCoreSystemInterface):
+ Init new WKSI functions.
+
+2012-05-14 Luke Macpherson <macpherson@chromium.org>
+
+ Introduce ENABLE_CSS_VARIABLES compile flag.
+ https://bugs.webkit.org/show_bug.cgi?id=86338
+
+ Reviewed by Dimitri Glazkov.
+
+ Add a configuration option for CSS Variables support, disabling it by default.
+
+ * Configurations/FeatureDefines.xcconfig:
+
+2012-05-14 Michael Saboff <msaboff@apple.com>
+
+ Enh: Add the Ability to Disable / Enable JavaScript GC Timer
+ https://bugs.webkit.org/show_bug.cgi?id=86382
+
+ Reviewed by Darin Adler.
+
+ Plumbing to set / clear JS GC activity timer enable flag.
+
+ * Misc/WebCoreStatistics.h:
+ * Misc/WebCoreStatistics.mm:
+ (+[WebCoreStatistics setJavaScriptGarbageCollectorTimerEnabled:]):
+
+2012-05-11 Gavin Barraclough <barraclough@apple.com>
+
+ Introduce PropertyName class
+ https://bugs.webkit.org/show_bug.cgi?id=86241
+
+ Reviewed by Geoff Garen.
+
+ Replace 'const Identifier&' arguments to functions accessing object properties with a new 'PropertyName' type.
+ This change paves the way to allow for properties keyed by values that are not Identifiers.
+
+ This change is largely a mechanical find & replace.
+ It also changes JSFunction's constructor to take a UString& instead of an Identifier&
+ (since in some cases we can no longer guarantee that we'lll have an Identifier), and
+ unifies Identifier's methods to obtain array indices onto PropertyName.
+
+ The new PropertyName class retains the ability to support .impl() and .ustring(), but
+ in a future patch we may need to rework this, since not all PropertyNames should be
+ equal based on their string representation.
+
+ * Plugins/Hosted/ProxyInstance.h:
+ (ProxyInstance):
+ * Plugins/Hosted/ProxyInstance.mm:
+ (ProxyClass):
+ (WebKit::ProxyClass::methodsNamed):
+ (WebKit::ProxyClass::fieldNamed):
+ (WebKit::ProxyRuntimeMethod::create):
+ (WebKit::ProxyRuntimeMethod::finishCreation):
+ (WebKit::ProxyInstance::getMethod):
+ (WebKit::ProxyInstance::methodsNamed):
+ (WebKit::ProxyInstance::fieldNamed):
+
+2012-05-11 Brady Eidson <beidson@apple.com>
+
+ <rdar://problem/11361907> and https://bugs.webkit.org/show_bug.cgi?id=86265
+ REGRESSION(r104885): Images missing from printed YummySoup! recipes
+
+ We thought clients were passing paths as URLs.
+ It turns out it was more likely they were passing file: URLs with the file: scheme removed.
+ And that jives perfectly with the behavior change caused by r104885.
+
+ Reviewed by Alexey Proskuryakov.
+
+ Rename _webkit_URLFromURLOrPath to _webkit_URLFromURLOrSchemelessFileURL, and change it
+ to create the new URL simply by appending "file:":
+ * Misc/WebNSURLExtras.h:
+ * Misc/WebNSURLExtras.mm:
+ (-[NSURL _webkit_URLFromURLOrSchemelessFileURL]):
+
+ * WebView/WebFrame.mm:
+ (-[WebFrame loadRequest:]): Create the fixed url simply by appending "file:" to the
+ existing URL string.
+ (-[WebFrame loadData:MIMEType:textEncodingName:baseURL:]):
+ (-[WebFrame loadHTMLString:baseURL:]):
+ (-[WebFrame loadAlternateHTMLString:baseURL:forUnreachableURL:]):
+
2012-05-10 Gyuyoung Kim <gyuyoung.kim@samsung.com>
Move resumeAnimations to use Internals interface
diff --git a/Source/WebKit/mac/Configurations/FeatureDefines.xcconfig b/Source/WebKit/mac/Configurations/FeatureDefines.xcconfig
index 91d688b53..84c9ee23e 100644
--- a/Source/WebKit/mac/Configurations/FeatureDefines.xcconfig
+++ b/Source/WebKit/mac/Configurations/FeatureDefines.xcconfig
@@ -38,6 +38,7 @@ ENABLE_BLOB = ENABLE_BLOB;
ENABLE_CHANNEL_MESSAGING = ENABLE_CHANNEL_MESSAGING;
ENABLE_CSS_FILTERS = ENABLE_CSS_FILTERS;
ENABLE_CSS_GRID_LAYOUT = ENABLE_CSS_GRID_LAYOUT;
+ENABLE_CSS_VARIABLES = ;
ENABLE_DASHBOARD_SUPPORT = $(ENABLE_DASHBOARD_SUPPORT_$(REAL_PLATFORM_NAME));
ENABLE_DASHBOARD_SUPPORT_macosx = ENABLE_DASHBOARD_SUPPORT;
ENABLE_DATALIST = ;
@@ -122,4 +123,4 @@ ENABLE_WEB_TIMING = ;
ENABLE_WORKERS = ENABLE_WORKERS;
ENABLE_XSLT = ENABLE_XSLT;
-FEATURE_DEFINES = $(ENABLE_3D_RENDERING) $(ENABLE_ACCELERATED_2D_CANVAS) $(ENABLE_ANIMATION_API) $(ENABLE_BLOB) $(ENABLE_CHANNEL_MESSAGING) $(ENABLE_CSS_FILTERS) $(ENABLE_CSS_GRID_LAYOUT) $(ENABLE_CSS_SHADERS) $(ENABLE_DASHBOARD_SUPPORT) $(ENABLE_DATALIST) $(ENABLE_DATA_TRANSFER_ITEMS) $(ENABLE_DETAILS) $(ENABLE_DEVICE_ORIENTATION) $(ENABLE_DIRECTORY_UPLOAD) $(ENABLE_FILE_SYSTEM) $(ENABLE_FILTERS) $(ENABLE_FULLSCREEN_API) $(ENABLE_GAMEPAD) $(ENABLE_GEOLOCATION) $(ENABLE_HIGH_DPI_CANVAS) $(ENABLE_ICONDATABASE) $(ENABLE_IFRAME_SEAMLESS) $(ENABLE_INDEXED_DATABASE) $(ENABLE_INPUT_TYPE_COLOR) $(ENABLE_INPUT_SPEECH) $(ENABLE_INPUT_TYPE_DATE) $(ENABLE_INPUT_TYPE_DATETIME) $(ENABLE_INPUT_TYPE_DATETIMELOCAL) $(ENABLE_INPUT_TYPE_MONTH) $(ENABLE_INPUT_TYPE_TIME) $(ENABLE_INPUT_TYPE_WEEK) $(ENABLE_JAVASCRIPT_DEBUGGER) $(ENABLE_LEGACY_NOTIFICATIONS) $(ENABLE_LINK_PREFETCH) $(ENABLE_LINK_PRERENDER) $(ENABLE_MATHML) $(ENABLE_MEDIA_SOURCE) $(ENABLE_MEDIA_STATISTICS) $(ENABLE_METER_TAG) $(ENABLE_MICRODATA) $(ENABLE_MUTATION_OBSERVERS) $(ENABLE_NOTIFICATIONS) $(ENABLE_PAGE_VISIBILITY_API) $(ENABLE_PROGRESS_TAG) $(ENABLE_QUOTA) $(ENABLE_REGISTER_PROTOCOL_HANDLER) $(ENABLE_REQUEST_ANIMATION_FRAME) $(ENABLE_SCRIPTED_SPEECH) $(ENABLE_SHADOW_DOM) $(ENABLE_SHARED_WORKERS) $(ENABLE_SQL_DATABASE) $(ENABLE_STYLE_SCOPED) $(ENABLE_SVG) $(ENABLE_SVG_DOM_OBJC_BINDINGS) $(ENABLE_SVG_FONTS) $(ENABLE_TEXT_NOTIFICATIONS_ONLY) $(ENABLE_TOUCH_ICON_LOADING) $(ENABLE_VIDEO) $(ENABLE_VIDEO_TRACK) $(ENABLE_WEBGL) $(ENABLE_WEB_AUDIO) $(ENABLE_WEB_SOCKETS) $(ENABLE_WEB_TIMING) $(ENABLE_WORKERS) $(ENABLE_XSLT);
+FEATURE_DEFINES = $(ENABLE_3D_RENDERING) $(ENABLE_ACCELERATED_2D_CANVAS) $(ENABLE_ANIMATION_API) $(ENABLE_BLOB) $(ENABLE_CHANNEL_MESSAGING) $(ENABLE_CSS_FILTERS) $(ENABLE_CSS_GRID_LAYOUT) $(ENABLE_CSS_SHADERS) $(ENABLE_CSS_VARIABLES) $(ENABLE_DASHBOARD_SUPPORT) $(ENABLE_DATALIST) $(ENABLE_DATA_TRANSFER_ITEMS) $(ENABLE_DETAILS) $(ENABLE_DEVICE_ORIENTATION) $(ENABLE_DIRECTORY_UPLOAD) $(ENABLE_FILE_SYSTEM) $(ENABLE_FILTERS) $(ENABLE_FULLSCREEN_API) $(ENABLE_GAMEPAD) $(ENABLE_GEOLOCATION) $(ENABLE_HIGH_DPI_CANVAS) $(ENABLE_ICONDATABASE) $(ENABLE_IFRAME_SEAMLESS) $(ENABLE_INDEXED_DATABASE) $(ENABLE_INPUT_TYPE_COLOR) $(ENABLE_INPUT_SPEECH) $(ENABLE_INPUT_TYPE_DATE) $(ENABLE_INPUT_TYPE_DATETIME) $(ENABLE_INPUT_TYPE_DATETIMELOCAL) $(ENABLE_INPUT_TYPE_MONTH) $(ENABLE_INPUT_TYPE_TIME) $(ENABLE_INPUT_TYPE_WEEK) $(ENABLE_JAVASCRIPT_DEBUGGER) $(ENABLE_LEGACY_NOTIFICATIONS) $(ENABLE_LINK_PREFETCH) $(ENABLE_LINK_PRERENDER) $(ENABLE_MATHML) $(ENABLE_MEDIA_SOURCE) $(ENABLE_MEDIA_STATISTICS) $(ENABLE_METER_TAG) $(ENABLE_MICRODATA) $(ENABLE_MUTATION_OBSERVERS) $(ENABLE_NOTIFICATIONS) $(ENABLE_PAGE_VISIBILITY_API) $(ENABLE_PROGRESS_TAG) $(ENABLE_QUOTA) $(ENABLE_REGISTER_PROTOCOL_HANDLER) $(ENABLE_REQUEST_ANIMATION_FRAME) $(ENABLE_SCRIPTED_SPEECH) $(ENABLE_SHADOW_DOM) $(ENABLE_SHARED_WORKERS) $(ENABLE_SQL_DATABASE) $(ENABLE_STYLE_SCOPED) $(ENABLE_SVG) $(ENABLE_SVG_DOM_OBJC_BINDINGS) $(ENABLE_SVG_FONTS) $(ENABLE_TEXT_NOTIFICATIONS_ONLY) $(ENABLE_TOUCH_ICON_LOADING) $(ENABLE_VIDEO) $(ENABLE_VIDEO_TRACK) $(ENABLE_WEBGL) $(ENABLE_WEB_AUDIO) $(ENABLE_WEB_SOCKETS) $(ENABLE_WEB_TIMING) $(ENABLE_WORKERS) $(ENABLE_XSLT);
diff --git a/Source/WebKit/mac/Misc/WebCoreStatistics.h b/Source/WebKit/mac/Misc/WebCoreStatistics.h
index 1565c2615..973fa77d1 100644
--- a/Source/WebKit/mac/Misc/WebCoreStatistics.h
+++ b/Source/WebKit/mac/Misc/WebCoreStatistics.h
@@ -47,6 +47,7 @@
+ (void)garbageCollectJavaScriptObjects;
+ (void)garbageCollectJavaScriptObjectsOnAlternateThreadForDebugging:(BOOL)waitUntilDone;
++ (void)setJavaScriptGarbageCollectorTimerEnabled:(BOOL)enabled;
+ (size_t)iconPageURLMappingCount;
+ (size_t)iconRetainedPageURLCount;
diff --git a/Source/WebKit/mac/Misc/WebCoreStatistics.mm b/Source/WebKit/mac/Misc/WebCoreStatistics.mm
index d593f8caf..1840451d6 100644
--- a/Source/WebKit/mac/Misc/WebCoreStatistics.mm
+++ b/Source/WebKit/mac/Misc/WebCoreStatistics.mm
@@ -120,6 +120,11 @@ using namespace WebCore;
gcController().garbageCollectOnAlternateThreadForDebugging(waitUntilDone);
}
++ (void)setJavaScriptGarbageCollectorTimerEnabled:(BOOL)enable
+{
+ gcController().setJavaScriptGarbageCollectorTimerEnabled(enable);
+}
+
+ (size_t)iconPageURLMappingCount
{
return iconDatabase().pageURLMappingCount();
diff --git a/Source/WebKit/mac/Misc/WebNSURLExtras.h b/Source/WebKit/mac/Misc/WebNSURLExtras.h
index 6b170a7bb..964db844c 100644
--- a/Source/WebKit/mac/Misc/WebNSURLExtras.h
+++ b/Source/WebKit/mac/Misc/WebNSURLExtras.h
@@ -69,7 +69,7 @@
- (NSString *)_webkit_suggestedFilenameWithMIMEType:(NSString *)MIMEType;
-- (NSURL *)_webkit_URLFromURLOrPath;
+- (NSURL *)_webkit_URLFromURLOrSchemelessFileURL;
@end
diff --git a/Source/WebKit/mac/Misc/WebNSURLExtras.mm b/Source/WebKit/mac/Misc/WebNSURLExtras.mm
index 98fff7aaa..99c35ba31 100644
--- a/Source/WebKit/mac/Misc/WebNSURLExtras.mm
+++ b/Source/WebKit/mac/Misc/WebNSURLExtras.mm
@@ -276,12 +276,12 @@ using namespace WTF;
return suggestedFilenameWithMIMEType(self, MIMEType);
}
-- (NSURL *)_webkit_URLFromURLOrPath
+- (NSURL *)_webkit_URLFromURLOrSchemelessFileURL
{
if ([self scheme])
return self;
- return [NSURL fileURLWithPath:[self absoluteString]];
+ return [NSURL URLWithString:[@"file:" stringByAppendingString:[self absoluteString]]];
}
@end
diff --git a/Source/WebKit/mac/Plugins/Hosted/ProxyInstance.h b/Source/WebKit/mac/Plugins/Hosted/ProxyInstance.h
index b999fa9e1..92a1aba47 100644
--- a/Source/WebKit/mac/Plugins/Hosted/ProxyInstance.h
+++ b/Source/WebKit/mac/Plugins/Hosted/ProxyInstance.h
@@ -46,8 +46,8 @@ public:
}
~ProxyInstance();
- JSC::Bindings::MethodList methodsNamed(const JSC::Identifier&);
- JSC::Bindings::Field* fieldNamed(const JSC::Identifier&);
+ JSC::Bindings::MethodList methodsNamed(JSC::PropertyName);
+ JSC::Bindings::Field* fieldNamed(JSC::PropertyName);
JSC::JSValue fieldValue(JSC::ExecState*, const JSC::Bindings::Field*) const;
void setFieldValue(JSC::ExecState*, const JSC::Bindings::Field*, JSC::JSValue) const;
@@ -66,7 +66,7 @@ private:
virtual JSC::Bindings::Class* getClass() const;
- virtual JSC::JSValue getMethod(JSC::ExecState* exec, const JSC::Identifier& propertyName);
+ virtual JSC::JSValue getMethod(JSC::ExecState*, JSC::PropertyName);
virtual JSC::JSValue invokeMethod(JSC::ExecState*, JSC::RuntimeMethod*);
virtual bool supportsInvokeDefaultMethod() const;
diff --git a/Source/WebKit/mac/Plugins/Hosted/ProxyInstance.mm b/Source/WebKit/mac/Plugins/Hosted/ProxyInstance.mm
index 09443dc16..cfb224095 100644
--- a/Source/WebKit/mac/Plugins/Hosted/ProxyInstance.mm
+++ b/Source/WebKit/mac/Plugins/Hosted/ProxyInstance.mm
@@ -50,16 +50,16 @@ namespace WebKit {
class ProxyClass : public JSC::Bindings::Class {
private:
- virtual MethodList methodsNamed(const Identifier&, Instance*) const;
- virtual Field* fieldNamed(const Identifier&, Instance*) const;
+ virtual MethodList methodsNamed(PropertyName, Instance*) const;
+ virtual Field* fieldNamed(PropertyName, Instance*) const;
};
-MethodList ProxyClass::methodsNamed(const Identifier& identifier, Instance* instance) const
+MethodList ProxyClass::methodsNamed(PropertyName identifier, Instance* instance) const
{
return static_cast<ProxyInstance*>(instance)->methodsNamed(identifier);
}
-Field* ProxyClass::fieldNamed(const Identifier& identifier, Instance* instance) const
+Field* ProxyClass::fieldNamed(PropertyName identifier, Instance* instance) const
{
return static_cast<ProxyInstance*>(instance)->fieldNamed(identifier);
}
@@ -181,7 +181,7 @@ class ProxyRuntimeMethod : public RuntimeMethod {
public:
typedef RuntimeMethod Base;
- static ProxyRuntimeMethod* create(ExecState* exec, JSGlobalObject* globalObject, const Identifier& name, Bindings::MethodList& list)
+ static ProxyRuntimeMethod* create(ExecState* exec, JSGlobalObject* globalObject, const UString& name, Bindings::MethodList& list)
{
// FIXME: deprecatedGetDOMStructure uses the prototype off of the wrong global object
// exec-globalData() is also likely wrong.
@@ -204,7 +204,7 @@ private:
{
}
- void finishCreation(JSGlobalData& globalData, const Identifier& name)
+ void finishCreation(JSGlobalData& globalData, const UString& name)
{
Base::finishCreation(globalData, name);
ASSERT(inherits(&s_info));
@@ -213,10 +213,10 @@ private:
const ClassInfo ProxyRuntimeMethod::s_info = { "ProxyRuntimeMethod", &RuntimeMethod::s_info, 0, 0, CREATE_METHOD_TABLE(ProxyRuntimeMethod) };
-JSValue ProxyInstance::getMethod(JSC::ExecState* exec, const JSC::Identifier& propertyName)
+JSValue ProxyInstance::getMethod(JSC::ExecState* exec, PropertyName propertyName)
{
MethodList methodList = getClass()->methodsNamed(propertyName, this);
- return ProxyRuntimeMethod::create(exec, exec->lexicalGlobalObject(), propertyName, methodList);
+ return ProxyRuntimeMethod::create(exec, exec->lexicalGlobalObject(), propertyName.impl(), methodList);
}
JSValue ProxyInstance::invokeMethod(ExecState* exec, JSC::RuntimeMethod* runtimeMethod)
@@ -346,7 +346,7 @@ void ProxyInstance::getPropertyNames(ExecState* exec, PropertyNameArray& nameArr
}
}
-MethodList ProxyInstance::methodsNamed(const Identifier& identifier)
+MethodList ProxyInstance::methodsNamed(PropertyName identifier)
{
if (!m_instanceProxy)
return MethodList();
@@ -360,7 +360,7 @@ MethodList ProxyInstance::methodsNamed(const Identifier& identifier)
return methodList;
}
- uint64_t methodName = reinterpret_cast<uint64_t>(_NPN_GetStringIdentifier(identifier.ascii().data()));
+ uint64_t methodName = reinterpret_cast<uint64_t>(_NPN_GetStringIdentifier(identifier.ustring().ascii().data()));
uint32_t requestID = m_instanceProxy->nextRequestID();
if (_WKPHNPObjectHasMethod(m_instanceProxy->hostProxy()->port(),
@@ -386,7 +386,7 @@ MethodList ProxyInstance::methodsNamed(const Identifier& identifier)
return methodList;
}
-Field* ProxyInstance::fieldNamed(const Identifier& identifier)
+Field* ProxyInstance::fieldNamed(PropertyName identifier)
{
if (!m_instanceProxy)
return 0;
@@ -396,7 +396,7 @@ Field* ProxyInstance::fieldNamed(const Identifier& identifier)
if (existingMapEntry != m_fields.end())
return existingMapEntry->second;
- uint64_t propertyName = reinterpret_cast<uint64_t>(_NPN_GetStringIdentifier(identifier.ascii().data()));
+ uint64_t propertyName = reinterpret_cast<uint64_t>(_NPN_GetStringIdentifier(identifier.ustring().ascii().data()));
uint32_t requestID = m_instanceProxy->nextRequestID();
if (_WKPHNPObjectHasProperty(m_instanceProxy->hostProxy()->port(),
diff --git a/Source/WebKit/mac/WebCoreSupport/WebEditorClient.h b/Source/WebKit/mac/WebCoreSupport/WebEditorClient.h
index c91a219e1..00b912566 100644
--- a/Source/WebKit/mac/WebCoreSupport/WebEditorClient.h
+++ b/Source/WebKit/mac/WebCoreSupport/WebEditorClient.h
@@ -41,6 +41,7 @@ public:
WebEditorClient(WebView *);
virtual ~WebEditorClient();
virtual void pageDestroyed() OVERRIDE;
+ virtual void frameWillDetachPage(WebCore::Frame*) OVERRIDE { }
virtual bool isGrammarCheckingEnabled() OVERRIDE;
virtual void toggleGrammarChecking() OVERRIDE;
@@ -121,6 +122,7 @@ public:
virtual void textWillBeDeletedInTextField(WebCore::Element*) OVERRIDE;
virtual void textDidChangeInTextArea(WebCore::Element*) OVERRIDE;
+ virtual bool shouldEraseMarkersAfterChangeSelection(WebCore::TextCheckingType) const OVERRIDE;
virtual void ignoreWordInSpellDocument(const WTF::String&) OVERRIDE;
virtual void learnWord(const WTF::String&) OVERRIDE;
virtual void checkSpellingOfString(const UChar*, int length, int* misspellingLocation, int* misspellingLength) OVERRIDE;
diff --git a/Source/WebKit/mac/WebCoreSupport/WebEditorClient.mm b/Source/WebKit/mac/WebCoreSupport/WebEditorClient.mm
index 5ea3c55ea..bb4b4398a 100644
--- a/Source/WebKit/mac/WebCoreSupport/WebEditorClient.mm
+++ b/Source/WebKit/mac/WebCoreSupport/WebEditorClient.mm
@@ -694,6 +694,16 @@ void WebEditorClient::textDidChangeInTextArea(Element* element)
CallFormDelegate(m_webView, @selector(textDidChangeInTextArea:inFrame:), textAreaElement, kit(element->document()->frame()));
}
+bool WebEditorClient::shouldEraseMarkersAfterChangeSelection(TextCheckingType type) const
+{
+ // This prevents erasing spelling markers on OS X Lion or later to match AppKit on these Mac OS X versions.
+#if !defined(BUILDING_ON_LEOPARD) && !defined(BUILDING_ON_SNOW_LEOPARD)
+ return type != TextCheckingTypeSpelling;
+#else
+ return true;
+#endif
+}
+
void WebEditorClient::ignoreWordInSpellDocument(const String& text)
{
[[NSSpellChecker sharedSpellChecker] ignoreWord:text
diff --git a/Source/WebKit/mac/WebCoreSupport/WebSystemInterface.mm b/Source/WebKit/mac/WebCoreSupport/WebSystemInterface.mm
index 00f79b546..d1f2f15ee 100644
--- a/Source/WebKit/mac/WebCoreSupport/WebSystemInterface.mm
+++ b/Source/WebKit/mac/WebCoreSupport/WebSystemInterface.mm
@@ -198,7 +198,12 @@ void InitWebCoreSystemInterface(void)
INIT(FilterWasBlocked);
INIT(FilterAddData);
INIT(FilterDataComplete);
+
+ INIT(NSElasticDeltaForTimeDelta);
+ INIT(NSElasticDeltaForReboundDelta);
+ INIT(NSReboundDeltaForElasticDelta);
#endif
+
#endif
didInit = true;
}
diff --git a/Source/WebKit/mac/WebView/WebFrame.mm b/Source/WebKit/mac/WebView/WebFrame.mm
index 416bd7dfe..e2f1df6cb 100644
--- a/Source/WebKit/mac/WebView/WebFrame.mm
+++ b/Source/WebKit/mac/WebView/WebFrame.mm
@@ -1384,7 +1384,7 @@ static bool needsMicrosoftMessengerDOMDocumentWorkaround()
// Note that other users of WebKit API use nil requests or requests with nil URLs, so we
// only implement this workaround when the request had a non-nil URL.
if (!resourceRequest.url().isValid() && [request URL])
- resourceRequest.setURL([NSURL fileURLWithPath:[[request URL] absoluteString]]);
+ resourceRequest.setURL([NSURL URLWithString:[@"file:" stringByAppendingString:[[request URL] absoluteString]]]);
coreFrame->loader()->load(resourceRequest, false);
}
@@ -1427,7 +1427,7 @@ static NSURL *createUniqueWebDataURL()
if (!MIMEType)
MIMEType = @"text/html";
- [self _loadData:data MIMEType:MIMEType textEncodingName:encodingName baseURL:[baseURL _webkit_URLFromURLOrPath] unreachableURL:nil];
+ [self _loadData:data MIMEType:MIMEType textEncodingName:encodingName baseURL:[baseURL _webkit_URLFromURLOrSchemelessFileURL] unreachableURL:nil];
}
- (void)_loadHTMLString:(NSString *)string baseURL:(NSURL *)baseURL unreachableURL:(NSURL *)unreachableURL
@@ -1440,14 +1440,14 @@ static NSURL *createUniqueWebDataURL()
{
WebCoreThreadViolationCheckRoundTwo();
- [self _loadHTMLString:string baseURL:[baseURL _webkit_URLFromURLOrPath] unreachableURL:nil];
+ [self _loadHTMLString:string baseURL:[baseURL _webkit_URLFromURLOrSchemelessFileURL] unreachableURL:nil];
}
- (void)loadAlternateHTMLString:(NSString *)string baseURL:(NSURL *)baseURL forUnreachableURL:(NSURL *)unreachableURL
{
WebCoreThreadViolationCheckRoundTwo();
- [self _loadHTMLString:string baseURL:[baseURL _webkit_URLFromURLOrPath] unreachableURL:[unreachableURL _webkit_URLFromURLOrPath]];
+ [self _loadHTMLString:string baseURL:[baseURL _webkit_URLFromURLOrSchemelessFileURL] unreachableURL:[unreachableURL _webkit_URLFromURLOrSchemelessFileURL]];
}
- (void)loadArchive:(WebArchive *)archive
diff --git a/Source/WebKit/mac/WebView/WebHTMLView.mm b/Source/WebKit/mac/WebView/WebHTMLView.mm
index 42dd10492..2a1210b4f 100644
--- a/Source/WebKit/mac/WebView/WebHTMLView.mm
+++ b/Source/WebKit/mac/WebView/WebHTMLView.mm
@@ -212,6 +212,20 @@ static WebMenuTarget* target;
}
@end
+@interface WebRootLayer : CALayer
+@end
+
+@implementation WebRootLayer
+- (void)renderInContext:(CGContextRef)ctx
+{
+ // AppKit calls -[CALayer renderInContext:] to render layer-backed views
+ // into bitmap contexts, but renderInContext: doesn't capture mask layers
+ // (<rdar://problem/9539526>), so we can't rely on it. Since our layer
+ // contents will have already been rendered by drawRect:, we can safely make
+ // this a NOOP.
+}
+@end
+
// if YES, do the standard NSView hit test (which can't give the right result when HTML overlaps a view)
static BOOL forceNSViewHitTest;
@@ -5466,7 +5480,7 @@ static CGPoint coreGraphicsScreenPointForAppKitScreenPoint(NSPoint point)
}
// Make a container layer, which will get sized/positioned by AppKit and CA.
- CALayer* viewLayer = [CALayer layer];
+ CALayer* viewLayer = [WebRootLayer layer];
#ifdef BUILDING_ON_LEOPARD
// Turn off default animations.