diff options
Diffstat (limited to 'Source/WebKit/chromium/src/ChromeClientImpl.cpp')
-rw-r--r-- | Source/WebKit/chromium/src/ChromeClientImpl.cpp | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/Source/WebKit/chromium/src/ChromeClientImpl.cpp b/Source/WebKit/chromium/src/ChromeClientImpl.cpp index 99302cc..f12bf03 100644 --- a/Source/WebKit/chromium/src/ChromeClientImpl.cpp +++ b/Source/WebKit/chromium/src/ChromeClientImpl.cpp @@ -54,6 +54,7 @@ #include "Node.h" #include "NotificationPresenterImpl.h" #include "Page.h" +#include "PlatformBridge.h" #include "PopupMenuChromium.h" #include "RenderWidget.h" #include "ScriptController.h" @@ -682,6 +683,22 @@ void ChromeClientImpl::chooseIconForFiles(const Vector<String>& filenames, FileC iconCompletion->didLoadIcon(WebData()); } +#if ENABLE(DIRECTORY_UPLOAD) +void ChromeClientImpl::enumerateChosenDirectory(const String& path, FileChooser* fileChooser) +{ + WebViewClient* client = m_webView->client(); + if (!client) + return; + + WebFileChooserCompletionImpl* chooserCompletion = + new WebFileChooserCompletionImpl(fileChooser); + + // If the enumeration can't happen, call the callback with an empty list. + if (!client->enumerateChosenDirectory(path, chooserCompletion)) + chooserCompletion->didChooseFile(WebVector<WebString>()); +} +#endif + void ChromeClientImpl::popupOpened(PopupContainer* popupContainer, const IntRect& bounds, bool handleExternally) @@ -905,4 +922,9 @@ PassRefPtr<SearchPopupMenu> ChromeClientImpl::createSearchPopupMenu(PopupMenuCli return adoptRef(new SearchPopupMenuChromium(client)); } +void ChromeClientImpl::willRunModalDialogDuringPageDismissal(const DialogType& dialogType) const +{ + PlatformBridge::histogramEnumeration("Renderer.ModalDialogsDuringPageDismissal", static_cast<int>(dialogType), static_cast<int>(NumDialogTypes)); +} + } // namespace WebKit |