Modified: trunk/Source/WebKit2/ChangeLog (122321 => 122322)
--- trunk/Source/WebKit2/ChangeLog 2012-07-11 09:49:25 UTC (rev 122321)
+++ trunk/Source/WebKit2/ChangeLog 2012-07-11 09:54:23 UTC (rev 122322)
@@ -1,3 +1,21 @@
+2012-07-11 Keunsoon Lee <[email protected]>
+
+ [EFL][Wk2] WebErrorsEfl.cpp needs to return non-empty errors
+ https://bugs.webkit.org/show_bug.cgi?id=90688
+
+ Reviewed by Hajime Morita.
+
+ Return meaningful error for each case.
+
+ * WebProcess/WebCoreSupport/efl/WebErrorsEfl.cpp:
+ (WebKit::cancelledError): create ResourceError for "request canceled".
+ (WebKit::blockedError): create ResourceError for "request blocked".
+ (WebKit::cannotShowURLError): create ResourceError for "cannot show url".
+ (WebKit::interruptedForPolicyChangeError): create ResourceError for "Frame load interrupted by policy change".
+ (WebKit::cannotShowMIMETypeError): create ResourceError for "Cannot show mimetype".
+ (WebKit::fileDoesNotExistError): create ResourceError for "File does not exist".
+ (WebKit::pluginWillHandleLoadError): create ResourceError for "Plugin will handle load".
+
2012-07-11 Andras Becsi <[email protected]>
[Qt][WK2] Fix wheel scrolling for simple pages
Modified: trunk/Source/WebKit2/WebProcess/WebCoreSupport/efl/WebErrorsEfl.cpp (122321 => 122322)
--- trunk/Source/WebKit2/WebProcess/WebCoreSupport/efl/WebErrorsEfl.cpp 2012-07-11 09:49:25 UTC (rev 122321)
+++ trunk/Source/WebKit2/WebProcess/WebCoreSupport/efl/WebErrorsEfl.cpp 2012-07-11 09:54:23 UTC (rev 122322)
@@ -26,7 +26,8 @@
#include "config.h"
#include "WebErrors.h"
-#include <WebCore/NotImplemented.h>
+#include "WKError.h"
+#include "WebError.h"
#include <WebCore/ResourceError.h>
#include <WebCore/ResourceRequest.h>
#include <WebCore/ResourceResponse.h>
@@ -35,46 +36,47 @@
namespace WebKit {
+// FIXME: Export following error codes so that application can understand.
+// We should establish Efl port's error system because application cannot understand those local define.
+// See https://bugs.webkit.org/show_bug.cgi?id=90783 for detail.
+enum {
+ kWKErrorCodeCancelled = 300,
+ kWKErrorCodeFileDoesNotExist = 301,
+};
+
ResourceError cancelledError(const ResourceRequest& request)
{
- notImplemented();
- return ResourceError();
+ return ResourceError(WebError::webKitErrorDomain(), kWKErrorCodeCancelled, request.url().string(), "Request cancelled");
}
ResourceError blockedError(const ResourceRequest& request)
{
- notImplemented();
- return ResourceError();
+ return ResourceError(WebError::webKitErrorDomain(), kWKErrorCodeCannotUseRestrictedPort, request.url().string(), "Request blocked");
}
ResourceError cannotShowURLError(const ResourceRequest& request)
{
- notImplemented();
- return ResourceError();
+ return ResourceError(WebError::webKitErrorDomain(), kWKErrorCodeCannotShowURL, request.url().string(), "Cannot show URL");
}
ResourceError interruptedForPolicyChangeError(const ResourceRequest& request)
{
- notImplemented();
- return ResourceError();
+ return ResourceError(WebError::webKitErrorDomain(), kWKErrorCodeFrameLoadInterruptedByPolicyChange, request.url().string(), "Frame load interrupted by policy change");
}
ResourceError cannotShowMIMETypeError(const ResourceResponse& response)
{
- notImplemented();
- return ResourceError();
+ return ResourceError(WebError::webKitErrorDomain(), kWKErrorCodeCannotShowMIMEType, response.url().string(), "Cannot show mimetype");
}
ResourceError fileDoesNotExistError(const ResourceResponse& response)
{
- notImplemented();
- return ResourceError();
+ return ResourceError(WebError::webKitErrorDomain(), kWKErrorCodeFileDoesNotExist, response.url().string(), "File does not exist");
}
ResourceError pluginWillHandleLoadError(const ResourceResponse& response)
{
- notImplemented();
- return ResourceError();
+ return ResourceError(WebError::webKitErrorDomain(), kWKErrorCodePlugInWillHandleLoad, response.url().string(), "Plugin will handle load");
}
} // namespace WebKit