summaryrefslogtreecommitdiffstats
path: root/WebKitTools/DumpRenderTree/win
diff options
context:
space:
mode:
Diffstat (limited to 'WebKitTools/DumpRenderTree/win')
-rw-r--r--WebKitTools/DumpRenderTree/win/DumpRenderTree.cpp1
-rw-r--r--WebKitTools/DumpRenderTree/win/FrameLoadDelegate.cpp2
-rw-r--r--WebKitTools/DumpRenderTree/win/LayoutTestControllerWin.cpp17
3 files changed, 20 insertions, 0 deletions
diff --git a/WebKitTools/DumpRenderTree/win/DumpRenderTree.cpp b/WebKitTools/DumpRenderTree/win/DumpRenderTree.cpp
index dfa4de0..b22f342 100644
--- a/WebKitTools/DumpRenderTree/win/DumpRenderTree.cpp
+++ b/WebKitTools/DumpRenderTree/win/DumpRenderTree.cpp
@@ -787,6 +787,7 @@ static void resetDefaultsToConsistentValues(IWebPreferences* preferences)
preferences->setTabsToLinks(FALSE);
preferences->setShouldPrintBackgrounds(TRUE);
preferences->setLoadsImagesAutomatically(TRUE);
+ preferences->setEditingBehavior(WebKitEditingWinBehavior);
if (persistentUserStyleSheetLocation) {
Vector<wchar_t> urlCharacters(CFStringGetLength(persistentUserStyleSheetLocation.get()));
diff --git a/WebKitTools/DumpRenderTree/win/FrameLoadDelegate.cpp b/WebKitTools/DumpRenderTree/win/FrameLoadDelegate.cpp
index 9b9e3c1..a84e0f3 100644
--- a/WebKitTools/DumpRenderTree/win/FrameLoadDelegate.cpp
+++ b/WebKitTools/DumpRenderTree/win/FrameLoadDelegate.cpp
@@ -1,5 +1,6 @@
/*
* Copyright (C) 2005, 2006, 2007, 2009 Apple Inc. All rights reserved.
+ * Copyright (C) 2010 Torch Mobile (Beijing) Co. Ltd. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
@@ -146,6 +147,7 @@ HRESULT STDMETHODCALLTYPE FrameLoadDelegate::didFailProvisionalLoadWithError(
if (!done && gLayoutTestController->dumpFrameLoadCallbacks())
printf("%s - didFailProvisionalLoadWithError\n", descriptionSuitableForTestResult(frame).c_str());
+ locationChangeDone(error, frame);
return S_OK;
}
diff --git a/WebKitTools/DumpRenderTree/win/LayoutTestControllerWin.cpp b/WebKitTools/DumpRenderTree/win/LayoutTestControllerWin.cpp
index 112b355..c70b517 100644
--- a/WebKitTools/DumpRenderTree/win/LayoutTestControllerWin.cpp
+++ b/WebKitTools/DumpRenderTree/win/LayoutTestControllerWin.cpp
@@ -1267,3 +1267,20 @@ void LayoutTestController::setWebViewEditable(bool)
void LayoutTestController::authenticateSession(JSStringRef, JSStringRef, JSStringRef)
{
}
+
+void LayoutTestController::setEditingBehavior(const char* editingBehavior)
+{
+ COMPtr<IWebView> webView;
+ if (FAILED(frame->webView(&webView)))
+ return;
+
+ COMPtr<IWebPreferences> preferences;
+ if (FAILED(webView->preferences(&preferences)))
+ return;
+
+ string behaviorString(editingBehavior);
+ if (behaviorString == "mac")
+ preferences->setEditingBehavior(WebKitEditingMacBehavior);
+ if (behaviorString == "win")
+ preferences->setEditingBehavior(WebKitEditingWinBehavior);
+}