| 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 41 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 52 | 52 |
| 53 // Handles window-level notifications from WebCore on behalf of a WebView. | 53 // Handles window-level notifications from WebCore on behalf of a WebView. |
| 54 class ChromeClientImpl final : public ChromeClient { | 54 class ChromeClientImpl final : public ChromeClient { |
| 55 public: | 55 public: |
| 56 explicit ChromeClientImpl(WebViewImpl* webView); | 56 explicit ChromeClientImpl(WebViewImpl* webView); |
| 57 virtual ~ChromeClientImpl(); | 57 virtual ~ChromeClientImpl(); |
| 58 | 58 |
| 59 virtual void* webView() const override; | 59 virtual void* webView() const override; |
| 60 | 60 |
| 61 // ChromeClient methods: | 61 // ChromeClient methods: |
| 62 virtual void chromeDestroyed() override; | |
| 63 virtual void setWindowRect(const FloatRect&) override; | 62 virtual void setWindowRect(const FloatRect&) override; |
| 64 virtual FloatRect windowRect() override; | 63 virtual FloatRect windowRect() override; |
| 65 virtual FloatRect pageRect() override; | |
| 66 virtual void focus() override; | 64 virtual void focus() override; |
| 67 virtual bool canTakeFocus(FocusType) override; | 65 virtual bool canTakeFocus(FocusType) override; |
| 68 virtual void takeFocus(FocusType) override; | 66 virtual void takeFocus(FocusType) override; |
| 69 virtual void focusedNodeChanged(Node*) override; | 67 virtual void focusedNodeChanged(Node*) override; |
| 70 virtual void focusedFrameChanged(LocalFrame*) override; | 68 virtual void focusedFrameChanged(LocalFrame*) override; |
| 71 virtual void show(NavigationPolicy) override; | 69 |
| 72 virtual bool shouldReportDetailedMessageForSource(const WTF::String&) overri
de; | 70 virtual bool shouldReportDetailedMessageForSource(const WTF::String&) overri
de; |
| 73 virtual void addMessageToConsole( | 71 virtual void addMessageToConsole( |
| 74 LocalFrame*, MessageSource, MessageLevel, | 72 LocalFrame*, MessageSource, MessageLevel, |
| 75 const WTF::String& message, unsigned lineNumber, | 73 const WTF::String& message, unsigned lineNumber, |
| 76 const WTF::String& sourceID, const WTF::String& stackTrace) override; | 74 const WTF::String& sourceID, const WTF::String& stackTrace) override; |
| 77 virtual void scheduleVisualUpdate() override; | 75 virtual void scheduleVisualUpdate() override; |
| 78 virtual IntRect rootViewToScreen(const IntRect&) const override; | 76 virtual IntRect rootViewToScreen(const IntRect&) const override; |
| 79 virtual WebScreenInfo screenInfo() const override; | 77 virtual WebScreenInfo screenInfo() const override; |
| 80 virtual void layoutUpdated(LocalFrame*) const override; | |
| 81 virtual void setCursor(const Cursor&) override; | 78 virtual void setCursor(const Cursor&) override; |
| 82 | 79 |
| 83 // ChromeClient methods: | 80 // ChromeClient methods: |
| 84 virtual String acceptLanguages() override; | 81 virtual String acceptLanguages() override; |
| 85 | 82 |
| 86 // ChromeClientImpl: | |
| 87 void setNewWindowNavigationPolicy(WebNavigationPolicy); | |
| 88 | |
| 89 virtual void willSetInputMethodState() override; | |
| 90 | |
| 91 private: | 83 private: |
| 92 virtual bool isChromeClientImpl() const override { return true; } | |
| 93 | |
| 94 WebNavigationPolicy getNavigationPolicy(); | 84 WebNavigationPolicy getNavigationPolicy(); |
| 95 void setCursor(const WebCursorInfo&); | 85 void setCursor(const WebCursorInfo&); |
| 96 | 86 |
| 97 WebViewImpl* m_webView; // weak pointer | 87 WebViewImpl* m_webView; // weak pointer |
| 98 }; | 88 }; |
| 99 | 89 |
| 100 DEFINE_TYPE_CASTS(ChromeClientImpl, ChromeClient, client, client->isChromeClient
Impl(), client.isChromeClientImpl()); | |
| 101 | |
| 102 } // namespace blink | 90 } // namespace blink |
| 103 | 91 |
| 104 #endif // SKY_ENGINE_WEB_CHROMECLIENTIMPL_H_ | 92 #endif // SKY_ENGINE_WEB_CHROMECLIENTIMPL_H_ |
| OLD | NEW |