Diff
Modified: trunk/LayoutTests/ChangeLog (145011 => 145012)
--- trunk/LayoutTests/ChangeLog 2013-03-07 01:16:03 UTC (rev 145011)
+++ trunk/LayoutTests/ChangeLog 2013-03-07 01:17:41 UTC (rev 145012)
@@ -1,3 +1,13 @@
+2013-03-06 Benjamin Poulain <[email protected]>
+
+ WebKitTestRunner needs layoutTestController.elementDoesAutoCompleteForElementWithId
+ https://bugs.webkit.org/show_bug.cgi?id=42696
+
+ Reviewed by Andreas Kling.
+
+ * security/set-form-autocomplete-attribute.html: Update the test.
+ * platform/wk2/TestExpectations: Unskip it for WebKit2.
+
2013-03-06 Dean Jackson <[email protected]>
REGRESSION (r143931): set-cookie-on-redirect.html still breaking subsequent tests
Modified: trunk/LayoutTests/platform/wk2/TestExpectations (145011 => 145012)
--- trunk/LayoutTests/platform/wk2/TestExpectations 2013-03-07 01:16:03 UTC (rev 145011)
+++ trunk/LayoutTests/platform/wk2/TestExpectations 2013-03-07 01:17:41 UTC (rev 145012)
@@ -221,10 +221,6 @@
printing/simultaneous-position-float-change.html
printing/width-overflow.html
-# WebKitTestRunner needs layoutTestController.elementDoesAutoCompleteForElementWithId
-# <https://bugs.webkit.org/show_bug.cgi?id=42696>
-security/set-form-autocomplete-attribute.html
-
# WebKitTestRunner needs layoutTestController.setWillSendRequestClearHeader
# <https://bugs.webkit.org/show_bug.cgi?id=42699>
http/tests/security/no-referrer.html
Modified: trunk/LayoutTests/security/set-form-autocomplete-attribute.html (145011 => 145012)
--- trunk/LayoutTests/security/set-form-autocomplete-attribute.html 2013-03-07 01:16:03 UTC (rev 145011)
+++ trunk/LayoutTests/security/set-form-autocomplete-attribute.html 2013-03-07 01:17:41 UTC (rev 145012)
@@ -12,9 +12,9 @@
document.getElementById("logger").appendChild(document.createElement('br'));
}
-function logAutoCompleteAPIResult()
+function logAutoCompleteAPIResult(input)
{
- if (testRunner.elementDoesAutoCompleteForElementWithId("autoInput"))
+ if (internals.elementShouldAutoComplete(input))
log("Element does autocomplete");
else
log("Element does *not* autocomplete");
@@ -31,41 +31,41 @@
var input = document.getElementById("autoInput");
// Test with no autocomplete attribute on the <form>
- logAutoCompleteAPIResult();
+ logAutoCompleteAPIResult(input);
input.setAttribute("autocomplete", "cheese");
- logAutoCompleteAPIResult();
+ logAutoCompleteAPIResult(input);
input.setAttribute("autocomplete", "off");
- logAutoCompleteAPIResult();
+ logAutoCompleteAPIResult(input);
input.setAttribute("autocomplete", "on");
- logAutoCompleteAPIResult();
+ logAutoCompleteAPIResult(input);
input.setAttribute("autocomplete", "cheese");
- logAutoCompleteAPIResult();
+ logAutoCompleteAPIResult(input);
input.removeAttribute("autocomplete");
- logAutoCompleteAPIResult();
+ logAutoCompleteAPIResult(input);
// Test with autocomplete="off" on the <form>
form.setAttribute("autocomplete", "off");
- logAutoCompleteAPIResult();
+ logAutoCompleteAPIResult(input);
input.setAttribute("autocomplete", "cheese");
- logAutoCompleteAPIResult();
+ logAutoCompleteAPIResult(input);
input.setAttribute("autocomplete", "off");
- logAutoCompleteAPIResult();
+ logAutoCompleteAPIResult(input);
input.setAttribute("autocomplete", "on");
- logAutoCompleteAPIResult();
+ logAutoCompleteAPIResult(input);
input.setAttribute("autocomplete", "cheese");
- logAutoCompleteAPIResult();
+ logAutoCompleteAPIResult(input);
input.removeAttribute("autocomplete");
- logAutoCompleteAPIResult();
+ logAutoCompleteAPIResult(input);
}
</script>
Modified: trunk/Source/WebCore/ChangeLog (145011 => 145012)
--- trunk/Source/WebCore/ChangeLog 2013-03-07 01:16:03 UTC (rev 145011)
+++ trunk/Source/WebCore/ChangeLog 2013-03-07 01:17:41 UTC (rev 145012)
@@ -1,3 +1,18 @@
+2013-03-06 Benjamin Poulain <[email protected]>
+
+ WebKitTestRunner needs layoutTestController.elementDoesAutoCompleteForElementWithId
+ https://bugs.webkit.org/show_bug.cgi?id=42696
+
+ Reviewed by Andreas Kling.
+
+ Since the method acts directly on a WebCore element and strictly test
+ HTMLInputElement::shouldAutoComplete(), the test function is moved to internals.
+
+ * testing/Internals.cpp:
+ (WebCore::Internals::elementShouldAutoComplete):
+ * testing/Internals.h:
+ * testing/Internals.idl:
+
2013-03-06 Alexey Proskuryakov <[email protected]>
[Mac] Synthetic ResourceResponses cannot be sent over IPC without losing most information
Modified: trunk/Source/WebCore/testing/Internals.cpp (145011 => 145012)
--- trunk/Source/WebCore/testing/Internals.cpp 2013-03-07 01:16:03 UTC (rev 145011)
+++ trunk/Source/WebCore/testing/Internals.cpp 2013-03-07 01:17:41 UTC (rev 145012)
@@ -1105,6 +1105,20 @@
return false;
}
+bool Internals::elementShouldAutoComplete(Element* element, ExceptionCode& ec)
+{
+ if (!element) {
+ ec = INVALID_ACCESS_ERR;
+ return false;
+ }
+
+ if (HTMLInputElement* inputElement = element->toInputElement())
+ return inputElement->shouldAutocomplete();
+
+ ec = INVALID_NODE_TYPE_ERR;
+ return false;
+}
+
String Internals::suggestedValue(Element* element, ExceptionCode& ec)
{
if (!element) {
Modified: trunk/Source/WebCore/testing/Internals.h (145011 => 145012)
--- trunk/Source/WebCore/testing/Internals.h 2013-03-07 01:16:03 UTC (rev 145011)
+++ trunk/Source/WebCore/testing/Internals.h 2013-03-07 01:17:41 UTC (rev 145012)
@@ -158,6 +158,7 @@
String configurationForViewport(Document*, float devicePixelRatio, int deviceWidth, int deviceHeight, int availableWidth, int availableHeight, ExceptionCode&);
bool wasLastChangeUserEdit(Element* textField, ExceptionCode&);
+ bool elementShouldAutoComplete(Element* inputElement, ExceptionCode&);
String suggestedValue(Element* inputElement, ExceptionCode&);
void setSuggestedValue(Element* inputElement, const String&, ExceptionCode&);
void setEditingValue(Element* inputElement, const String&, ExceptionCode&);
Modified: trunk/Source/WebCore/testing/Internals.idl (145011 => 145012)
--- trunk/Source/WebCore/testing/Internals.idl 2013-03-07 01:16:03 UTC (rev 145011)
+++ trunk/Source/WebCore/testing/Internals.idl 2013-03-07 01:17:41 UTC (rev 145012)
@@ -123,6 +123,7 @@
in long availableHeight) raises(DOMException);
boolean wasLastChangeUserEdit(in Element textField) raises (DOMException);
+ boolean elementShouldAutoComplete(in Element inputElement) raises (DOMException);
DOMString suggestedValue(in Element inputElement) raises (DOMException);
void setSuggestedValue(in Element inputElement, in DOMString value) raises (DOMException);
void setEditingValue(in Element inputElement, in DOMString value) raises (DOMException);
Modified: trunk/Source/WebKit/efl/ChangeLog (145011 => 145012)
--- trunk/Source/WebKit/efl/ChangeLog 2013-03-07 01:16:03 UTC (rev 145011)
+++ trunk/Source/WebKit/efl/ChangeLog 2013-03-07 01:17:41 UTC (rev 145012)
@@ -1,3 +1,13 @@
+2013-03-06 Benjamin Poulain <[email protected]>
+
+ WebKitTestRunner needs layoutTestController.elementDoesAutoCompleteForElementWithId
+ https://bugs.webkit.org/show_bug.cgi?id=42696
+
+ Reviewed by Andreas Kling.
+
+ * WebCoreSupport/DumpRenderTreeSupportEfl.cpp:
+ * WebCoreSupport/DumpRenderTreeSupportEfl.h:
+
2013-03-05 Geoffrey Garen <[email protected]>
Removed some dead code in the page cache
Modified: trunk/Source/WebKit/efl/WebCoreSupport/DumpRenderTreeSupportEfl.cpp (145011 => 145012)
--- trunk/Source/WebKit/efl/WebCoreSupport/DumpRenderTreeSupportEfl.cpp 2013-03-07 01:16:03 UTC (rev 145011)
+++ trunk/Source/WebKit/efl/WebCoreSupport/DumpRenderTreeSupportEfl.cpp 2013-03-07 01:17:41 UTC (rev 145012)
@@ -125,21 +125,6 @@
return frame->layerTreeAsText();
}
-bool DumpRenderTreeSupportEfl::elementDoesAutoCompleteForElementWithId(const Evas_Object* ewkFrame, const String& elementId)
-{
- DRT_SUPPORT_FRAME_GET_OR_RETURN(ewkFrame, frame, false);
-
- WebCore::Document* document = frame->document();
- ASSERT(document);
-
- WebCore::HTMLInputElement* inputElement = static_cast<WebCore::HTMLInputElement*>(document->getElementById(elementId));
-
- if (!inputElement)
- return false;
-
- return inputElement->isTextField() && !inputElement->isPasswordField() && inputElement->shouldAutocomplete();
-}
-
Eina_List* DumpRenderTreeSupportEfl::frameChildren(const Evas_Object* ewkFrame)
{
DRT_SUPPORT_FRAME_GET_OR_RETURN(ewkFrame, frame, 0);
Modified: trunk/Source/WebKit/efl/WebCoreSupport/DumpRenderTreeSupportEfl.h (145011 => 145012)
--- trunk/Source/WebKit/efl/WebCoreSupport/DumpRenderTreeSupportEfl.h 2013-03-07 01:16:03 UTC (rev 145011)
+++ trunk/Source/WebKit/efl/WebCoreSupport/DumpRenderTreeSupportEfl.h 2013-03-07 01:17:41 UTC (rev 145012)
@@ -57,7 +57,6 @@
static void clearFrameName(Evas_Object* ewkFrame);
static void clearOpener(Evas_Object* ewkFrame);
static String counterValueByElementId(const Evas_Object* ewkFrame, const char* elementId);
- static bool elementDoesAutoCompleteForElementWithId(const Evas_Object* ewkFrame, const String& elementId);
static Eina_List* frameChildren(const Evas_Object* ewkFrame);
static WebCore::Frame* frameParent(const Evas_Object* ewkFrame);
static void layoutFrame(Evas_Object* ewkFrame);
Modified: trunk/Source/WebKit/gtk/ChangeLog (145011 => 145012)
--- trunk/Source/WebKit/gtk/ChangeLog 2013-03-07 01:16:03 UTC (rev 145011)
+++ trunk/Source/WebKit/gtk/ChangeLog 2013-03-07 01:17:41 UTC (rev 145012)
@@ -1,3 +1,14 @@
+2013-03-06 Benjamin Poulain <[email protected]>
+
+ WebKitTestRunner needs layoutTestController.elementDoesAutoCompleteForElementWithId
+ https://bugs.webkit.org/show_bug.cgi?id=42696
+
+ Reviewed by Andreas Kling.
+
+ * WebCoreSupport/DumpRenderTreeSupportGtk.cpp:
+ * WebCoreSupport/DumpRenderTreeSupportGtk.h:
+ (DumpRenderTreeSupportGtk):
+
2013-03-06 Sudarsana Nagineni <[email protected]>
[GTK] Return m_inspectorFilesPath if it is not null
Modified: trunk/Source/WebKit/gtk/WebCoreSupport/DumpRenderTreeSupportGtk.cpp (145011 => 145012)
--- trunk/Source/WebKit/gtk/WebCoreSupport/DumpRenderTreeSupportGtk.cpp 2013-03-07 01:16:03 UTC (rev 145011)
+++ trunk/Source/WebKit/gtk/WebCoreSupport/DumpRenderTreeSupportGtk.cpp 2013-03-07 01:17:41 UTC (rev 145012)
@@ -673,26 +673,6 @@
#endif
}
-bool DumpRenderTreeSupportGtk::elementDoesAutoCompleteForElementWithId(WebKitWebFrame* frame, JSStringRef id)
-{
- Frame* coreFrame = core(frame);
- if (!coreFrame)
- return false;
-
- Document* document = coreFrame->document();
- ASSERT(document);
-
- size_t bufferSize = JSStringGetMaximumUTF8CStringSize(id);
- GOwnPtr<gchar> idBuffer(static_cast<gchar*>(g_malloc(bufferSize)));
- JSStringGetUTF8CString(id, idBuffer.get(), bufferSize);
- Node* coreNode = document->getElementById(String::fromUTF8(idBuffer.get()));
- if (!coreNode || !coreNode->renderer())
- return false;
-
- HTMLInputElement* inputElement = static_cast<HTMLInputElement*>(coreNode);
- return inputElement->isTextField() && !inputElement->isPasswordField() && inputElement->shouldAutocomplete();
-}
-
void DumpRenderTreeSupportGtk::deliverAllMutationsIfNecessary()
{
MutationObserver::deliverAllMutations();
Modified: trunk/Source/WebKit/gtk/WebCoreSupport/DumpRenderTreeSupportGtk.h (145011 => 145012)
--- trunk/Source/WebKit/gtk/WebCoreSupport/DumpRenderTreeSupportGtk.h 2013-03-07 01:16:03 UTC (rev 145011)
+++ trunk/Source/WebKit/gtk/WebCoreSupport/DumpRenderTreeSupportGtk.h 2013-03-07 01:17:41 UTC (rev 145012)
@@ -69,7 +69,6 @@
static void layoutFrame(WebKitWebFrame*);
static void setValueForUser(JSContextRef, JSValueRef, JSStringRef);
static bool shouldClose(WebKitWebFrame*);
- static bool elementDoesAutoCompleteForElementWithId(WebKitWebFrame*, JSStringRef);
// WebKitWebView
static void executeCoreCommandByName(WebKitWebView*, const gchar* name, const gchar* value);
Modified: trunk/Source/WebKit/qt/ChangeLog (145011 => 145012)
--- trunk/Source/WebKit/qt/ChangeLog 2013-03-07 01:16:03 UTC (rev 145011)
+++ trunk/Source/WebKit/qt/ChangeLog 2013-03-07 01:17:41 UTC (rev 145012)
@@ -1,3 +1,13 @@
+2013-03-06 Benjamin Poulain <[email protected]>
+
+ WebKitTestRunner needs layoutTestController.elementDoesAutoCompleteForElementWithId
+ https://bugs.webkit.org/show_bug.cgi?id=42696
+
+ Reviewed by Andreas Kling.
+
+ * WebCoreSupport/DumpRenderTreeSupportQt.cpp:
+ * WebCoreSupport/DumpRenderTreeSupportQt.h:
+
2013-03-06 Allan Sandfeld Jensen <[email protected]>
[Qt] Illegal narrowing in tst_qwebhistory
Modified: trunk/Source/WebKit/qt/WebCoreSupport/DumpRenderTreeSupportQt.cpp (145011 => 145012)
--- trunk/Source/WebKit/qt/WebCoreSupport/DumpRenderTreeSupportQt.cpp 2013-03-07 01:16:03 UTC (rev 145011)
+++ trunk/Source/WebKit/qt/WebCoreSupport/DumpRenderTreeSupportQt.cpp 2013-03-07 01:17:41 UTC (rev 145012)
@@ -416,24 +416,6 @@
return rect;
}
-bool DumpRenderTreeSupportQt::elementDoesAutoCompleteForElementWithId(QWebFrameAdapter *adapter, const QString& elementId)
-{
- Frame* coreFrame = adapter->frame;
- if (!coreFrame)
- return false;
-
- Document* doc = coreFrame->document();
- Q_ASSERT(doc);
-
- Node* coreNode = doc->getElementById(elementId);
- if (!coreNode || !coreNode->renderer())
- return false;
-
- HTMLInputElement* inputElement = static_cast<HTMLInputElement*>(coreNode);
-
- return inputElement->isTextField() && !inputElement->isPasswordField() && inputElement->shouldAutocomplete();
-}
-
void DumpRenderTreeSupportQt::setWindowsBehaviorAsEditingBehavior(QWebPageAdapter* adapter)
{
Page* corePage = adapter->page;
Modified: trunk/Source/WebKit/qt/WebCoreSupport/DumpRenderTreeSupportQt.h (145011 => 145012)
--- trunk/Source/WebKit/qt/WebCoreSupport/DumpRenderTreeSupportQt.h 2013-03-07 01:16:03 UTC (rev 145011)
+++ trunk/Source/WebKit/qt/WebCoreSupport/DumpRenderTreeSupportQt.h 2013-03-07 01:17:41 UTC (rev 145012)
@@ -122,7 +122,6 @@
static void clearFrameName(QWebFrameAdapter*);
static void overwritePluginDirectories();
static bool hasDocumentElement(QWebFrameAdapter*);
- static bool elementDoesAutoCompleteForElementWithId(QWebFrameAdapter*, const QString& elementId);
static void setWindowsBehaviorAsEditingBehavior(QWebPageAdapter*);
static void clearAllApplicationCaches();
Modified: trunk/Source/autotools/symbols.filter (145011 => 145012)
--- trunk/Source/autotools/symbols.filter 2013-03-07 01:16:03 UTC (rev 145011)
+++ trunk/Source/autotools/symbols.filter 2013-03-07 01:17:41 UTC (rev 145012)
@@ -284,6 +284,7 @@
_ZN7WebCore9PageGroup18captionPreferencesEv;
_ZN7WebCore4Page9initGroupEv;
_ZN7WebCore21markerTextForListItemEPNS_7ElementE;
+_ZNK7WebCore16HTMLInputElement18shouldAutocompleteEv;
local:
_Z*;
Modified: trunk/Tools/ChangeLog (145011 => 145012)
--- trunk/Tools/ChangeLog 2013-03-07 01:16:03 UTC (rev 145011)
+++ trunk/Tools/ChangeLog 2013-03-07 01:17:41 UTC (rev 145012)
@@ -1,3 +1,28 @@
+2013-03-06 Benjamin Poulain <[email protected]>
+
+ WebKitTestRunner needs layoutTestController.elementDoesAutoCompleteForElementWithId
+ https://bugs.webkit.org/show_bug.cgi?id=42696
+
+ Reviewed by Andreas Kling.
+
+ * DumpRenderTree/TestRunner.cpp:
+ (TestRunner::staticFunctions):
+ * DumpRenderTree/TestRunner.h:
+ (TestRunner):
+ * DumpRenderTree/blackberry/TestRunnerBlackBerry.cpp:
+ * DumpRenderTree/chromium/TestRunner/src/TestRunner.cpp:
+ (WebTestRunner::TestRunner::TestRunner):
+ * DumpRenderTree/chromium/TestRunner/src/TestRunner.h:
+ (TestRunner):
+ * DumpRenderTree/efl/TestRunnerEfl.cpp:
+ * DumpRenderTree/gtk/TestRunnerGtk.cpp:
+ * DumpRenderTree/mac/TestRunnerMac.mm:
+ * DumpRenderTree/qt/TestRunnerQt.cpp:
+ * DumpRenderTree/qt/TestRunnerQt.h:
+ (TestRunnerQt):
+ * DumpRenderTree/win/TestRunnerWin.cpp:
+ * DumpRenderTree/wx/TestRunnerWx.cpp:
+
2013-03-06 Roger Fong <[email protected]>
Re-enable WinEWS test and decrease iterations before clean build back to 10.
Modified: trunk/Tools/DumpRenderTree/TestRunner.cpp (145011 => 145012)
--- trunk/Tools/DumpRenderTree/TestRunner.cpp 2013-03-07 01:16:03 UTC (rev 145011)
+++ trunk/Tools/DumpRenderTree/TestRunner.cpp 2013-03-07 01:17:41 UTC (rev 145012)
@@ -1603,17 +1603,6 @@
return JSValueMakeUndefined(context);
}
-static JSValueRef elementDoesAutoCompleteForElementWithIdCallback(JSContextRef context, JSObjectRef function, JSObjectRef thisObject, size_t argumentCount, const JSValueRef arguments[], JSValueRef* exception)
-{
- TestRunner* controller = static_cast<TestRunner*>(JSObjectGetPrivate(thisObject));
- JSRetainPtr<JSStringRef> elementId(Adopt, JSValueToStringCopy(context, arguments[0], exception));
- ASSERT(!*exception);
-
- bool autoCompletes = controller->elementDoesAutoCompleteForElementWithId(elementId.get());
-
- return JSValueMakeBoolean(context, autoCompletes);
-}
-
static JSValueRef waitForPolicyDelegateCallback(JSContextRef context, JSObjectRef, JSObjectRef thisObject, size_t, const JSValueRef[], JSValueRef*)
{
TestRunner* controller = static_cast<TestRunner*>(JSObjectGetPrivate(thisObject));
@@ -2084,7 +2073,6 @@
{ "dumpTitleChanges", dumpTitleChangesCallback, kJSPropertyAttributeReadOnly | kJSPropertyAttributeDontDelete },
{ "dumpIconChanges", dumpIconChangesCallback, kJSPropertyAttributeReadOnly | kJSPropertyAttributeDontDelete },
{ "dumpWillCacheResponse", dumpWillCacheResponseCallback, kJSPropertyAttributeReadOnly | kJSPropertyAttributeDontDelete },
- { "elementDoesAutoCompleteForElementWithId", elementDoesAutoCompleteForElementWithIdCallback, kJSPropertyAttributeReadOnly | kJSPropertyAttributeDontDelete },
{ "encodeHostName", encodeHostNameCallback, kJSPropertyAttributeReadOnly | kJSPropertyAttributeDontDelete },
{ "evaluateInWebInspector", evaluateInWebInspectorCallback, kJSPropertyAttributeReadOnly | kJSPropertyAttributeDontDelete },
{ "evaluateScriptInIsolatedWorldAndReturnValue", evaluateScriptInIsolatedWorldAndReturnValueCallback, kJSPropertyAttributeReadOnly | kJSPropertyAttributeDontDelete },
Modified: trunk/Tools/DumpRenderTree/TestRunner.h (145011 => 145012)
--- trunk/Tools/DumpRenderTree/TestRunner.h 2013-03-07 01:16:03 UTC (rev 145011)
+++ trunk/Tools/DumpRenderTree/TestRunner.h 2013-03-07 01:17:41 UTC (rev 145012)
@@ -135,8 +135,6 @@
void removeAllWebNotificationPermissions();
void simulateWebNotificationClick(JSValueRef notification);
- bool elementDoesAutoCompleteForElementWithId(JSStringRef id);
-
bool dumpAsAudio() const { return m_dumpAsAudio; }
void setDumpAsAudio(bool dumpAsAudio) { m_dumpAsAudio = dumpAsAudio; }
Modified: trunk/Tools/DumpRenderTree/blackberry/TestRunnerBlackBerry.cpp (145011 => 145012)
--- trunk/Tools/DumpRenderTree/blackberry/TestRunnerBlackBerry.cpp 2013-03-07 01:16:03 UTC (rev 145011)
+++ trunk/Tools/DumpRenderTree/blackberry/TestRunnerBlackBerry.cpp 2013-03-07 01:17:41 UTC (rev 145012)
@@ -317,13 +317,6 @@
return 0;
}
-bool TestRunner::elementDoesAutoCompleteForElementWithId(JSStringRef id)
-{
- UNUSED_PARAM(id);
- notImplemented();
- return false;
-}
-
void TestRunner::setWaitToDump(bool waitToDump)
{
// Change from 30s to 35s because some test cases in multipart need 30 seconds,
Modified: trunk/Tools/DumpRenderTree/chromium/TestRunner/src/TestRunner.cpp (145011 => 145012)
--- trunk/Tools/DumpRenderTree/chromium/TestRunner/src/TestRunner.cpp 2013-03-07 01:16:03 UTC (rev 145011)
+++ trunk/Tools/DumpRenderTree/chromium/TestRunner/src/TestRunner.cpp 2013-03-07 01:17:41 UTC (rev 145012)
@@ -182,7 +182,6 @@
bindMethod("setTabKeyCyclesThroughElements", &TestRunner::setTabKeyCyclesThroughElements);
bindMethod("execCommand", &TestRunner::execCommand);
bindMethod("isCommandEnabled", &TestRunner::isCommandEnabled);
- bindMethod("elementDoesAutoCompleteForElementWithId", &TestRunner::elementDoesAutoCompleteForElementWithId);
bindMethod("callShouldCloseOnWebView", &TestRunner::callShouldCloseOnWebView);
bindMethod("setDomainRelaxationForbiddenForURLScheme", &TestRunner::setDomainRelaxationForbiddenForURLScheme);
bindMethod("evaluateScriptInIsolatedWorldAndReturnValue", &TestRunner::evaluateScriptInIsolatedWorldAndReturnValue);
@@ -1143,30 +1142,6 @@
result->set(rv);
}
-bool TestRunner::elementDoesAutoCompleteForElementWithId(const WebString& elementId)
-{
- WebFrame* webFrame = m_webView->mainFrame();
- if (!webFrame)
- return false;
-
- WebElement element = webFrame->document().getElementById(elementId);
- if (element.isNull() || !element.hasTagName("input"))
- return false;
-
- WebInputElement inputElement = element.to<WebInputElement>();
- return inputElement.autoComplete();
-}
-
-void TestRunner::elementDoesAutoCompleteForElementWithId(const CppArgumentList& arguments, CppVariant* result)
-{
- if (arguments.size() != 1 || !arguments[0].isString()) {
- result->set(false);
- return;
- }
- WebString elementId = cppVariantToWebString(arguments[0]);
- result->set(elementDoesAutoCompleteForElementWithId(elementId));
-}
-
void TestRunner::callShouldCloseOnWebView(const CppArgumentList&, CppVariant* result)
{
result->set(m_webView->dispatchBeforeUnloadEvent());
Modified: trunk/Tools/DumpRenderTree/chromium/TestRunner/src/TestRunner.h (145011 => 145012)
--- trunk/Tools/DumpRenderTree/chromium/TestRunner/src/TestRunner.h 2013-03-07 01:16:03 UTC (rev 145011)
+++ trunk/Tools/DumpRenderTree/chromium/TestRunner/src/TestRunner.h 2013-03-07 01:17:41 UTC (rev 145012)
@@ -214,7 +214,6 @@
// Checks if an internal command is currently available.
void isCommandEnabled(const CppArgumentList&, CppVariant*);
- void elementDoesAutoCompleteForElementWithId(const CppArgumentList&, CppVariant*);
void callShouldCloseOnWebView(const CppArgumentList&, CppVariant*);
void setDomainRelaxationForbiddenForURLScheme(const CppArgumentList&, CppVariant*);
void evaluateScriptInIsolatedWorldAndReturnValue(const CppArgumentList&, CppVariant*);
@@ -524,7 +523,6 @@
void didNotAcquirePointerLockInternal();
void didLosePointerLockInternal();
- bool elementDoesAutoCompleteForElementWithId(const WebKit::WebString&);
bool cppVariantToBool(const CppVariant&);
int32_t cppVariantToInt32(const CppVariant&);
WebKit::WebString cppVariantToWebString(const CppVariant&);
Modified: trunk/Tools/DumpRenderTree/efl/TestRunnerEfl.cpp (145011 => 145012)
--- trunk/Tools/DumpRenderTree/efl/TestRunnerEfl.cpp 2013-03-07 01:16:03 UTC (rev 145011)
+++ trunk/Tools/DumpRenderTree/efl/TestRunnerEfl.cpp 2013-03-07 01:17:41 UTC (rev 145012)
@@ -436,13 +436,6 @@
ewk_view_setting_enable_plugins_set(browser->mainView(), flag);
}
-bool TestRunner::elementDoesAutoCompleteForElementWithId(JSStringRef id)
-{
- const String elementId(id->string());
- const Evas_Object* mainFrame = browser->mainFrame();
- return DumpRenderTreeSupportEfl::elementDoesAutoCompleteForElementWithId(mainFrame, elementId);
-}
-
void TestRunner::execCommand(JSStringRef name, JSStringRef value)
{
DumpRenderTreeSupportEfl::executeCoreCommandByName(browser->mainView(), name->string().utf8().data(), value->string().utf8().data());
Modified: trunk/Tools/DumpRenderTree/gtk/TestRunnerGtk.cpp (145011 => 145012)
--- trunk/Tools/DumpRenderTree/gtk/TestRunnerGtk.cpp 2013-03-07 01:16:03 UTC (rev 145011)
+++ trunk/Tools/DumpRenderTree/gtk/TestRunnerGtk.cpp 2013-03-07 01:17:41 UTC (rev 145012)
@@ -509,11 +509,6 @@
g_object_set(G_OBJECT(settings), "enable-plugins", flag, NULL);
}
-bool TestRunner::elementDoesAutoCompleteForElementWithId(JSStringRef id)
-{
- return DumpRenderTreeSupportGtk::elementDoesAutoCompleteForElementWithId(mainFrame, id);
-}
-
void TestRunner::execCommand(JSStringRef name, JSStringRef value)
{
WebKitWebView* view = webkit_web_frame_get_web_view(mainFrame);
Modified: trunk/Tools/DumpRenderTree/mac/TestRunnerMac.mm (145011 => 145012)
--- trunk/Tools/DumpRenderTree/mac/TestRunnerMac.mm 2013-03-07 01:16:03 UTC (rev 145011)
+++ trunk/Tools/DumpRenderTree/mac/TestRunnerMac.mm 2013-03-07 01:17:41 UTC (rev 145012)
@@ -663,20 +663,6 @@
return CFArrayGetCount(openWindowsRef);
}
-bool TestRunner::elementDoesAutoCompleteForElementWithId(JSStringRef jsString)
-{
- RetainPtr<CFStringRef> idCF(AdoptCF, JSStringCopyCFString(kCFAllocatorDefault, jsString));
- NSString *idNS = (NSString *)idCF.get();
-
- DOMElement *element = [[mainFrame DOMDocument] getElementById:idNS];
- id rep = [[mainFrame dataSource] representation];
-
- if ([rep class] == [WebHTMLRepresentation class])
- return [(WebHTMLRepresentation *)rep elementDoesAutoComplete:element];
-
- return false;
-}
-
void TestRunner::execCommand(JSStringRef name, JSStringRef value)
{
RetainPtr<CFStringRef> nameCF(AdoptCF, JSStringCopyCFString(kCFAllocatorDefault, name));
Modified: trunk/Tools/DumpRenderTree/qt/TestRunnerQt.cpp (145011 => 145012)
--- trunk/Tools/DumpRenderTree/qt/TestRunnerQt.cpp 2013-03-07 01:16:03 UTC (rev 145011)
+++ trunk/Tools/DumpRenderTree/qt/TestRunnerQt.cpp 2013-03-07 01:17:41 UTC (rev 145012)
@@ -745,11 +745,6 @@
return DumpRenderTreeSupportQt::findString(m_drt->pageAdapter(), string, optionArray);
}
-bool TestRunnerQt::elementDoesAutoCompleteForElementWithId(const QString& elementId)
-{
- return DumpRenderTreeSupportQt::elementDoesAutoCompleteForElementWithId(m_drt->mainFrameAdapter(), elementId);
-}
-
void TestRunnerQt::authenticateSession(const QString&, const QString&, const QString&)
{
// FIXME: If there is a concept per-session (per-process) credential storage, the credentials should be added to it for later use.
Modified: trunk/Tools/DumpRenderTree/qt/TestRunnerQt.h (145011 => 145012)
--- trunk/Tools/DumpRenderTree/qt/TestRunnerQt.h 2013-03-07 01:16:03 UTC (rev 145011)
+++ trunk/Tools/DumpRenderTree/qt/TestRunnerQt.h 2013-03-07 01:17:41 UTC (rev 145012)
@@ -184,8 +184,6 @@
bool isCommandEnabled(const QString& name) const;
bool findString(const QString&, const QStringList& optionArray);
- bool elementDoesAutoCompleteForElementWithId(const QString& elementId);
-
void addOriginAccessWhitelistEntry(const QString& sourceOrigin, const QString& destinationProtocol, const QString& destinationHost, bool allowDestinationSubdomains);
void removeOriginAccessWhitelistEntry(const QString& sourceOrigin, const QString& destinationProtocol, const QString& destinationHost, bool allowDestinationSubdomains);
Modified: trunk/Tools/DumpRenderTree/win/TestRunnerWin.cpp (145011 => 145012)
--- trunk/Tools/DumpRenderTree/win/TestRunnerWin.cpp 2013-03-07 01:16:03 UTC (rev 145011)
+++ trunk/Tools/DumpRenderTree/win/TestRunnerWin.cpp 2013-03-07 01:17:41 UTC (rev 145012)
@@ -768,32 +768,6 @@
return openWindows().size();
}
-bool TestRunner::elementDoesAutoCompleteForElementWithId(JSStringRef id)
-{
- COMPtr<IDOMDocument> document;
- if (FAILED(frame->DOMDocument(&document)))
- return false;
-
- wstring idWstring = jsStringRefToWString(id);
- BSTR idBSTR = SysAllocStringLen((OLECHAR*)idWstring.c_str(), idWstring.length());
- COMPtr<IDOMElement> element;
- HRESULT result = document->getElementById(idBSTR, &element);
- SysFreeString(idBSTR);
-
- if (FAILED(result))
- return false;
-
- COMPtr<IWebFramePrivate> framePrivate(Query, frame);
- if (!framePrivate)
- return false;
-
- BOOL autoCompletes;
- if (FAILED(framePrivate->elementDoesAutoComplete(element.get(), &autoCompletes)))
- return false;
-
- return autoCompletes;
-}
-
void TestRunner::execCommand(JSStringRef name, JSStringRef value)
{
wstring wName = jsStringRefToWString(name);
Modified: trunk/Tools/DumpRenderTree/wx/TestRunnerWx.cpp (145011 => 145012)
--- trunk/Tools/DumpRenderTree/wx/TestRunnerWx.cpp 2013-03-07 01:16:03 UTC (rev 145011)
+++ trunk/Tools/DumpRenderTree/wx/TestRunnerWx.cpp 2013-03-07 01:17:41 UTC (rev 145012)
@@ -209,12 +209,6 @@
// FIXME: Implement
}
-bool TestRunner::elementDoesAutoCompleteForElementWithId(JSStringRef id)
-{
- // FIXME: implement
- return false;
-}
-
void TestRunner::execCommand(JSStringRef name, JSStringRef value)
{
// FIXME: implement