- Replaced the QWebView with a custom widget

- Added support form Back and Forward mouse buttons to webview


FossilOrigin-Name: c2c1b42f9604c19f48e4811c4eaf44d63aee60fe
This commit is contained in:
kostas
2013-01-13 10:36:07 +00:00
parent 9e4e35a56a
commit 6f8e7a622a
6 changed files with 95 additions and 56 deletions

View File

@ -4,10 +4,10 @@
<widget class="QWidget" name="BrowserWidget">
<property name="geometry">
<rect>
<x>0</x>
<y>0</y>
<width>400</width>
<height>300</height>
<x>0</x>
<y>0</y>
<width>400</width>
<height>300</height>
</rect>
</property>
<property name="windowTitle">
@ -15,92 +15,87 @@
</property>
<layout class="QVBoxLayout" name="verticalLayout">
<property name="spacing">
<number>0</number>
<number>0</number>
</property>
<property name="margin">
<number>0</number>
<number>0</number>
</property>
<item>
<widget class="QToolBar" name="toolBar">
<property name="windowTitle">
<string/>
</property>
<property name="iconSize">
<size>
<width>24</width>
<height>24</height>
</size>
</property>
<addaction name="actionBrowserBack"/>
<addaction name="actionBrowserForward"/>
<addaction name="actionBrowserRefresh"/>
<addaction name="actionBrowserStop"/>
</widget>
<widget class="QToolBar" name="toolBar">
<property name="windowTitle">
<string/>
</property>
<property name="iconSize">
<size>
<width>24</width>
<height>24</height>
</size>
</property>
<addaction name="actionBrowserBack"/>
<addaction name="actionBrowserForward"/>
<addaction name="actionBrowserRefresh"/>
<addaction name="actionBrowserStop"/>
</widget>
</item>
<item>
<widget class="QLineEdit" name="txtUrl"/>
<widget class="QLineEdit" name="txtUrl"/>
</item>
<item>
<widget class="QWebView" name="webView">
<property name="url">
<url>
<string>about:blank</string>
</url>
</property>
</widget>
<widget class="CustomWebView" name="webView" native="true"/>
</item>
</layout>
<action name="actionBrowserBack">
<property name="icon">
<iconset resource="../rsrc/resources.qrc">
<normaloff>:/icons/icons/Button Previous-01.png</normaloff>:/icons/icons/Button Previous-01.png</iconset>
<iconset resource="../rsrc/resources.qrc">
<normaloff>:/icons/icons/Button Previous-01.png</normaloff>:/icons/icons/Button Previous-01.png</iconset>
</property>
<property name="text">
<string>Back</string>
<string>Back</string>
</property>
<property name="toolTip">
<string>Back</string>
<string>Back</string>
</property>
</action>
<action name="actionBrowserForward">
<property name="icon">
<iconset resource="../rsrc/resources.qrc">
<normaloff>:/icons/icons/Button Next-01.png</normaloff>:/icons/icons/Button Next-01.png</iconset>
<iconset resource="../rsrc/resources.qrc">
<normaloff>:/icons/icons/Button Next-01.png</normaloff>:/icons/icons/Button Next-01.png</iconset>
</property>
<property name="text">
<string>Forward</string>
<string>Forward</string>
</property>
<property name="toolTip">
<string>Forward</string>
<string>Forward</string>
</property>
</action>
<action name="actionBrowserRefresh">
<property name="icon">
<iconset resource="../rsrc/resources.qrc">
<normaloff>:/icons/icons/Button Refresh-01.png</normaloff>:/icons/icons/Button Refresh-01.png</iconset>
<iconset resource="../rsrc/resources.qrc">
<normaloff>:/icons/icons/Button Refresh-01.png</normaloff>:/icons/icons/Button Refresh-01.png</iconset>
</property>
<property name="text">
<string>Refresh</string>
<string>Refresh</string>
</property>
<property name="toolTip">
<string>Refresh</string>
<string>Refresh</string>
</property>
</action>
<action name="actionBrowserStop">
<property name="icon">
<iconset resource="../rsrc/resources.qrc">
<normaloff>:/icons/icons/Button Close-01.png</normaloff>:/icons/icons/Button Close-01.png</iconset>
<iconset resource="../rsrc/resources.qrc">
<normaloff>:/icons/icons/Button Close-01.png</normaloff>:/icons/icons/Button Close-01.png</iconset>
</property>
<property name="text">
<string>browserStop</string>
<string>browserStop</string>
</property>
</action>
</widget>
<customwidgets>
<customwidget>
<class>QWebView</class>
<class>CustomWebView</class>
<extends>QWidget</extends>
<header>QtWebKit/QWebView</header>
<header>CustomWebView.h</header>
<container>1</container>
</customwidget>
</customwidgets>
<resources>