Title: [97336] trunk/Source
Revision
97336
Author
[email protected]
Date
2011-10-12 19:50:50 -0700 (Wed, 12 Oct 2011)

Log Message

<http://webkit.org/b/69598> Pass Parsed Accept Attribute MIME Types to WebKit Clients

Part 1 - Deprecate String version of acceptTypes

Reviewed by Kent Tamura.

Source/WebCore:

Deprecate the old String version of getting the "accept"
mime type values. Instead we will change to include a
list of MIME types.

* html/FileInputType.cpp:
(WebCore::FileInputType::handleDOMActivateEvent):
(WebCore::FileInputType::receiveDropForDirectoryUpload):
* platform/FileChooser.h:

Source/WebKit/chromium:

Chromium uses the deprecated accept string. Switching to
the new approach will require coordination with their port.

* src/ChromeClientImpl.cpp:
(WebKit::ChromeClientImpl::runOpenPanel):

Source/WebKit/efl:

EFL uses the deprecated accept string. They can switch
to an Eina_List if they want to update their API.

* src/ChromeClientImpl.cpp:
(WebKit::ChromeClientImpl::runOpenPanel):

Source/WebKit2:

Switch to deprecated for now, but the next patches will
remove the deprecated version from the WebKit2 path.

* WebProcess/WebCoreSupport/WebChromeClient.cpp:
(WebKit::WebChromeClient::runOpenPanel):

Modified Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (97335 => 97336)


--- trunk/Source/WebCore/ChangeLog	2011-10-13 02:43:25 UTC (rev 97335)
+++ trunk/Source/WebCore/ChangeLog	2011-10-13 02:50:50 UTC (rev 97336)
@@ -1,3 +1,19 @@
+2011-10-12  Joseph Pecoraro  <[email protected]>
+
+        Pass Parsed Accept Attribute MIME Types to WebKit Clients
+        https://bugs.webkit.org/show_bug.cgi?id=69598
+
+        Reviewed by Kent Tamura.
+
+        Deprecate the old String version of getting the "accept"
+        mime type values. Instead we will change to include a
+        list of MIME types.
+
+        * html/FileInputType.cpp:
+        (WebCore::FileInputType::handleDOMActivateEvent):
+        (WebCore::FileInputType::receiveDropForDirectoryUpload):
+        * platform/FileChooser.h:
+
 2011-10-12  Adam Barth  <[email protected]>
 
         Remove ENABLE(XHTMLMP) and associated code

Modified: trunk/Source/WebCore/html/FileInputType.cpp (97335 => 97336)


--- trunk/Source/WebCore/html/FileInputType.cpp	2011-10-13 02:43:25 UTC (rev 97335)
+++ trunk/Source/WebCore/html/FileInputType.cpp	2011-10-13 02:50:50 UTC (rev 97336)
@@ -153,7 +153,7 @@
 #else
         settings.allowsMultipleFiles = input->fastHasAttribute(multipleAttr);
 #endif
-        settings.acceptTypes = input->accept();
+        settings.deprecatedAcceptTypes = input->accept();
         settings.selectedFiles = m_fileList->paths();
         chrome->runOpenPanel(input->document()->frame(), newFileChooser(settings));
     }
@@ -327,7 +327,7 @@
         settings.allowsDirectoryUpload = true;
         settings.allowsMultipleFiles = true;
         settings.selectedFiles.append(paths[0]);
-        settings.acceptTypes = element()->accept();
+        settings.deprecatedAcceptTypes = element()->accept();
         chrome->enumerateChosenDirectory(newFileChooser(settings));
     }
 }

Modified: trunk/Source/WebCore/platform/FileChooser.h (97335 => 97336)


--- trunk/Source/WebCore/platform/FileChooser.h	2011-10-13 02:43:25 UTC (rev 97335)
+++ trunk/Source/WebCore/platform/FileChooser.h	2011-10-13 02:50:50 UTC (rev 97336)
@@ -42,7 +42,7 @@
 #if ENABLE(DIRECTORY_UPLOAD)
     bool allowsDirectoryUpload;
 #endif
-    String acceptTypes;
+    String deprecatedAcceptTypes;
     Vector<String> selectedFiles;
 };
 

Modified: trunk/Source/WebKit/chromium/ChangeLog (97335 => 97336)


--- trunk/Source/WebKit/chromium/ChangeLog	2011-10-13 02:43:25 UTC (rev 97335)
+++ trunk/Source/WebKit/chromium/ChangeLog	2011-10-13 02:50:50 UTC (rev 97336)
@@ -1,3 +1,16 @@
+2011-10-12  Joseph Pecoraro  <[email protected]>
+
+        Pass Parsed Accept Attribute MIME Types to WebKit Clients
+        https://bugs.webkit.org/show_bug.cgi?id=69598
+
+        Reviewed by Kent Tamura.
+
+        Chromium uses the deprecated accept string. Switching to
+        the new approach will require coordination with their port.
+
+        * src/ChromeClientImpl.cpp:
+        (WebKit::ChromeClientImpl::runOpenPanel):
+
 2011-10-12  Antoine Labour  <[email protected]>
 
         Fix CCThreadTest.startPostAndWaitOnCondition

Modified: trunk/Source/WebKit/chromium/src/ChromeClientImpl.cpp (97335 => 97336)


--- trunk/Source/WebKit/chromium/src/ChromeClientImpl.cpp	2011-10-13 02:43:25 UTC (rev 97335)
+++ trunk/Source/WebKit/chromium/src/ChromeClientImpl.cpp	2011-10-13 02:50:50 UTC (rev 97336)
@@ -668,7 +668,7 @@
 #else
     params.directory = false;
 #endif
-    params.acceptTypes = fileChooser->settings().acceptTypes;
+    params.acceptTypes = fileChooser->settings().deprecatedAcceptTypes;
     params.selectedFiles = fileChooser->settings().selectedFiles;
     if (params.selectedFiles.size() > 0)
         params.initialValue = params.selectedFiles[0];

Modified: trunk/Source/WebKit/efl/ChangeLog (97335 => 97336)


--- trunk/Source/WebKit/efl/ChangeLog	2011-10-13 02:43:25 UTC (rev 97335)
+++ trunk/Source/WebKit/efl/ChangeLog	2011-10-13 02:50:50 UTC (rev 97336)
@@ -1,3 +1,16 @@
+2011-10-12  Joseph Pecoraro  <[email protected]>
+
+        Pass Parsed Accept Attribute MIME Types to WebKit Clients
+        https://bugs.webkit.org/show_bug.cgi?id=69598
+
+        Reviewed by Kent Tamura.
+
+        EFL uses the deprecated accept string. They can switch
+        to an Eina_List if they want to update their API.
+
+        * src/ChromeClientImpl.cpp:
+        (WebKit::ChromeClientImpl::runOpenPanel):
+
 2011-10-12  Gyuyoung Kim  <[email protected]>
 
         [EFL] Change efl style parameter variables with WebKit coding Style

Modified: trunk/Source/WebKit/efl/WebCoreSupport/ChromeClientEfl.cpp (97335 => 97336)


--- trunk/Source/WebKit/efl/WebCoreSupport/ChromeClientEfl.cpp	2011-10-13 02:43:25 UTC (rev 97335)
+++ trunk/Source/WebKit/efl/WebCoreSupport/ChromeClientEfl.cpp	2011-10-13 02:50:50 UTC (rev 97336)
@@ -433,7 +433,7 @@
     void* filename;
     Vector<String> filenames;
 
-    CString accept = chooser->settings().acceptTypes.utf8();
+    CString accept = chooser->settings().deprecatedAcceptTypes.utf8();
     confirm = ewk_view_run_open_panel(m_view, kit(frame), chooser->settings().allowsMultipleFiles, accept.data(), &selectedFilenames);
 
     if (!confirm)

Modified: trunk/Source/WebKit2/ChangeLog (97335 => 97336)


--- trunk/Source/WebKit2/ChangeLog	2011-10-13 02:43:25 UTC (rev 97335)
+++ trunk/Source/WebKit2/ChangeLog	2011-10-13 02:50:50 UTC (rev 97336)
@@ -1,3 +1,16 @@
+2011-10-12  Joseph Pecoraro  <[email protected]>
+
+        Pass Parsed Accept Attribute MIME Types to WebKit Clients
+        https://bugs.webkit.org/show_bug.cgi?id=69598
+
+        Reviewed by Kent Tamura.
+
+        Switch to deprecated for now, but the next patches will
+        remove the deprecated version from the WebKit2 path.
+
+        * WebProcess/WebCoreSupport/WebChromeClient.cpp:
+        (WebKit::WebChromeClient::runOpenPanel):
+
 2011-10-12  Adam Barth  <[email protected]>
 
         Remove ENABLE(XHTMLMP) and associated code

Modified: trunk/Source/WebKit2/WebProcess/WebCoreSupport/WebChromeClient.cpp (97335 => 97336)


--- trunk/Source/WebKit2/WebProcess/WebCoreSupport/WebChromeClient.cpp	2011-10-13 02:43:25 UTC (rev 97335)
+++ trunk/Source/WebKit2/WebProcess/WebCoreSupport/WebChromeClient.cpp	2011-10-13 02:50:50 UTC (rev 97336)
@@ -622,7 +622,7 @@
 #else
     parameters.allowsDirectoryUpload = false;
 #endif
-    parameters.acceptTypes = fileChooser->settings().acceptTypes;
+    parameters.acceptTypes = fileChooser->settings().deprecatedAcceptTypes;
     parameters.filenames = fileChooser->settings().selectedFiles;
 
     m_page->send(Messages::WebPageProxy::RunOpenPanel(static_cast<WebFrameLoaderClient*>(frame->loader()->client())->webFrame()->frameID(), parameters));
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo.cgi/webkit-changes

Reply via email to