forked from WebKit/WebKit-http
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[Win][MiniBrowser] Add a new BrowserWindow interface to abstract WK1 …
…and WK2 BrowserWindow https://bugs.webkit.org/show_bug.cgi?id=186421 Reviewed by Ryosuke Niwa. This is the core patch to make MiniBrowser to support WK1 and WK2 windows (Bug 184770). I will rename MiniBrowser class to WK1BrowserWindow in a follow-up patch (Bug 184770 Comment 12). * MiniBrowser/win/BrowserWindow.h: Added. * MiniBrowser/win/MainWindow.cpp: (MainWindow::WndProc): * MiniBrowser/win/MainWindow.h: (MainWindow::browserWindow const): * MiniBrowser/win/MiniBrowser.cpp: (MiniBrowser::create): (MiniBrowser::navigateForwardOrBackward): Removed the unsed first argument hWnd. (MiniBrowser::navigateToHistory): Ditto. * MiniBrowser/win/MiniBrowser.h: Inherit BrowserWindow interface. Make all other methods private and make delegates classes friends. * MiniBrowser/win/PrintWebUIDelegate.cpp: (PrintWebUIDelegate::createWebViewWithRequest): git-svn-id: http://svn.webkit.org/repository/webkit/trunk@232616 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- Loading branch information
1 parent
565db14
commit 164a080
Showing
7 changed files
with
112 additions
and
17 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,30 @@ | ||
2018-06-07 Fujii Hironori <[email protected]> | ||
|
||
[Win][MiniBrowser] Add a new BrowserWindow interface to abstract WK1 and WK2 BrowserWindow | ||
https://bugs.webkit.org/show_bug.cgi?id=186421 | ||
|
||
Reviewed by Ryosuke Niwa. | ||
|
||
This is the core patch to make MiniBrowser to support WK1 and WK2 | ||
windows (Bug 184770). | ||
|
||
I will rename MiniBrowser class to WK1BrowserWindow in a follow-up | ||
patch (Bug 184770 Comment 12). | ||
|
||
* MiniBrowser/win/BrowserWindow.h: Added. | ||
* MiniBrowser/win/MainWindow.cpp: | ||
(MainWindow::WndProc): | ||
* MiniBrowser/win/MainWindow.h: | ||
(MainWindow::browserWindow const): | ||
* MiniBrowser/win/MiniBrowser.cpp: | ||
(MiniBrowser::create): | ||
(MiniBrowser::navigateForwardOrBackward): Removed the unsed first argument hWnd. | ||
(MiniBrowser::navigateToHistory): Ditto. | ||
* MiniBrowser/win/MiniBrowser.h: Inherit BrowserWindow interface. | ||
Make all other methods private and make delegates classes friends. | ||
* MiniBrowser/win/PrintWebUIDelegate.cpp: | ||
(PrintWebUIDelegate::createWebViewWithRequest): | ||
|
||
2018-06-07 Fujii Hironori <[email protected]> | ||
|
||
[Win][MiniBrowser] MiniBrowser::updateDeviceScaleFactor should be a MainWindow's method | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,58 @@ | ||
/* | ||
* Copyright (C) 2018 Sony Interactive Entertainment Inc. | ||
* | ||
* Redistribution and use in source and binary forms, with or without | ||
* modification, are permitted provided that the following conditions | ||
* are met: | ||
* 1. Redistributions of source code must retain the above copyright | ||
* notice, this list of conditions and the following disclaimer. | ||
* 2. Redistributions in binary form must reproduce the above copyright | ||
* notice, this list of conditions and the following disclaimer in the | ||
* documentation and/or other materials provided with the distribution. | ||
* | ||
* THIS SOFTWARE IS PROVIDED BY APPLE INC. ``AS IS'' AND ANY | ||
* EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE | ||
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR | ||
* PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR | ||
* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, | ||
* EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, | ||
* PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR | ||
* PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY | ||
* OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT | ||
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE | ||
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | ||
*/ | ||
|
||
#pragma once | ||
|
||
#include <windows.h> | ||
#include <wtf/RefCounted.h> | ||
|
||
class BrowserWindow : public RefCounted<BrowserWindow> { | ||
public: | ||
virtual ~BrowserWindow() { }; | ||
|
||
virtual HRESULT init() = 0; | ||
virtual HWND hwnd() = 0; | ||
|
||
virtual HRESULT loadHTMLString(const BSTR&) = 0; | ||
virtual HRESULT loadURL(const BSTR& passedURL) = 0; | ||
virtual void navigateForwardOrBackward(UINT menuID) = 0; | ||
virtual void navigateToHistory(UINT menuID) = 0; | ||
virtual void setPreference(UINT menuID, bool enable) = 0; | ||
virtual bool usesLayeredWebView() const { return false; } | ||
|
||
virtual void print() = 0; | ||
virtual void launchInspector() = 0; | ||
|
||
virtual _bstr_t userAgent() = 0; | ||
virtual void setUserAgent(UINT menuID) = 0; | ||
virtual void setUserAgent(_bstr_t& customUAString) = 0; | ||
|
||
virtual void showLayerTree() = 0; | ||
virtual void updateStatistics(HWND dialog) = 0; | ||
|
||
virtual void resetZoom() = 0; | ||
virtual void zoomIn() = 0; | ||
virtual void zoomOut() = 0; | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters