| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2009 Google Inc. All rights reserved. | 2 * Copyright (C) 2009 Google Inc. All rights reserved. |
| 3 * Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). | 3 * Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). |
| 4 * | 4 * |
| 5 * Redistribution and use in source and binary forms, with or without | 5 * Redistribution and use in source and binary forms, with or without |
| 6 * modification, are permitted provided that the following conditions are | 6 * modification, are permitted provided that the following conditions are |
| 7 * met: | 7 * met: |
| 8 * | 8 * |
| 9 * * Redistributions of source code must retain the above copyright | 9 * * Redistributions of source code must retain the above copyright |
| 10 * notice, this list of conditions and the following disclaimer. | 10 * notice, this list of conditions and the following disclaimer. |
| (...skipping 611 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 622 WebFileChooserCompletionImpl* chooserCompletion = new WebFileChooserCompleti
onImpl(fileChooser); | 622 WebFileChooserCompletionImpl* chooserCompletion = new WebFileChooserCompleti
onImpl(fileChooser); |
| 623 | 623 |
| 624 ASSERT(fileChooser); | 624 ASSERT(fileChooser); |
| 625 ASSERT(fileChooser->settings().selectedFiles.size()); | 625 ASSERT(fileChooser->settings().selectedFiles.size()); |
| 626 | 626 |
| 627 // If the enumeration can't happen, call the callback with an empty list. | 627 // If the enumeration can't happen, call the callback with an empty list. |
| 628 if (!client->enumerateChosenDirectory(fileChooser->settings().selectedFiles[
0], chooserCompletion)) | 628 if (!client->enumerateChosenDirectory(fileChooser->settings().selectedFiles[
0], chooserCompletion)) |
| 629 chooserCompletion->didChooseFile(WebVector<WebString>()); | 629 chooserCompletion->didChooseFile(WebVector<WebString>()); |
| 630 } | 630 } |
| 631 | 631 |
| 632 void ChromeClientImpl::setCursorInternal(const Cursor& cursor) | 632 Cursor ChromeClientImpl::lastSetCursorForTesting() const |
| 633 { | 633 { |
| 634 return m_lastSetMouseCursorForTesting; |
| 635 } |
| 636 |
| 637 void ChromeClientImpl::setCursor(const Cursor& cursor) |
| 638 { |
| 639 m_lastSetMouseCursorForTesting = cursor; |
| 634 setCursor(WebCursorInfo(cursor)); | 640 setCursor(WebCursorInfo(cursor)); |
| 635 } | 641 } |
| 636 | 642 |
| 637 void ChromeClientImpl::setCursor(const WebCursorInfo& cursor) | 643 void ChromeClientImpl::setCursor(const WebCursorInfo& cursor) |
| 638 { | 644 { |
| 639 #if OS(MACOSX) | 645 #if OS(MACOSX) |
| 640 // On Mac the mousemove event propagates to both the popup and main window. | 646 // On Mac the mousemove event propagates to both the popup and main window. |
| 641 // If a popup is open we don't want the main window to change the cursor. | 647 // If a popup is open we don't want the main window to change the cursor. |
| 642 if (m_webView->hasOpenedPopup()) | 648 if (m_webView->hasOpenedPopup()) |
| 643 return; | 649 return; |
| (...skipping 296 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 940 } | 946 } |
| 941 | 947 |
| 942 void ChromeClientImpl::notifyPopupOpeningObservers() const | 948 void ChromeClientImpl::notifyPopupOpeningObservers() const |
| 943 { | 949 { |
| 944 const Vector<PopupOpeningObserver*> observers(m_popupOpeningObservers); | 950 const Vector<PopupOpeningObserver*> observers(m_popupOpeningObservers); |
| 945 for (const auto& observer : observers) | 951 for (const auto& observer : observers) |
| 946 observer->willOpenPopup(); | 952 observer->willOpenPopup(); |
| 947 } | 953 } |
| 948 | 954 |
| 949 } // namespace blink | 955 } // namespace blink |
| OLD | NEW |