]>
Commit | Line | Data |
---|---|---|
d8a28990 JB |
1 | diff -rupN luminance-hdr-2.5.1/CMakeLists.txt luminance-hdr-2.5.1-new/CMakeLists.txt |
2 | --- luminance-hdr-2.5.1/CMakeLists.txt 2017-05-10 21:14:06.000000000 +0200 | |
3 | +++ luminance-hdr-2.5.1-new/CMakeLists.txt 2017-05-11 00:30:33.387938670 +0200 | |
4 | @@ -38,8 +38,8 @@ find_package(Qt5Core REQUIRED) | |
5 | find_package(Qt5Concurrent REQUIRED) | |
6 | find_package(Qt5Widgets REQUIRED) | |
7 | find_package(Qt5Gui REQUIRED) | |
8 | -find_package(Qt5WebEngineCore REQUIRED) | |
9 | -find_package(Qt5WebEngineWidgets REQUIRED) | |
10 | +find_package(Qt5WebKit REQUIRED) | |
11 | +find_package(Qt5WebKitWidgets REQUIRED) | |
12 | find_package(Qt5Xml REQUIRED) | |
13 | find_package(Qt5Sql REQUIRED) | |
14 | find_package(Qt5Svg REQUIRED) | |
15 | @@ -57,7 +57,7 @@ ENDIF(WIN32) | |
16 | ||
17 | set(LIBS ${LIBS} | |
18 | ${QT_QTCORE_LIBRARIES} ${QT_QTGUI_LIBRARIES} ${QT_QTNETWORK_LIBRARIES} | |
19 | - ${QT_QTWEBENGINE_LIBRARIES} ${QT_QTXML_LIBRARIES} ${QT_QTSQL_LIBRARIES}) | |
20 | + ${QT_QTWEBKIT_LIBRARIES} ${QT_QTXML_LIBRARIES} ${QT_QTSQL_LIBRARIES}) | |
21 | ||
22 | FIND_PACKAGE(Git) | |
23 | IF(GIT_FOUND) | |
24 | diff -rupN luminance-hdr-2.5.1/src/HelpBrowser/CMakeLists.txt luminance-hdr-2.5.1-new/src/HelpBrowser/CMakeLists.txt | |
25 | --- luminance-hdr-2.5.1/src/HelpBrowser/CMakeLists.txt 2017-05-10 21:14:06.000000000 +0200 | |
26 | +++ luminance-hdr-2.5.1-new/src/HelpBrowser/CMakeLists.txt 2017-05-11 00:30:33.387938670 +0200 | |
27 | @@ -28,7 +28,7 @@ QT5_WRAP_CPP(FILES_MOC ${FILES_H}) | |
28 | QT5_WRAP_UI(FILES_UI_H ${FILES_UI}) | |
29 | ||
30 | ADD_LIBRARY(helpbrowser ${FILES_H} ${FILES_CPP} ${FILES_MOC} ${FILES_UI_H} ${FILES_HXX}) | |
31 | -qt5_use_modules(helpbrowser Core Concurrent Gui Widgets Xml WebEngineCore WebEngineWidgets PrintSupport) | |
32 | +qt5_use_modules(helpbrowser Core Concurrent Gui Widgets Xml WebKit WebKitWidgets PrintSupport) | |
33 | ||
34 | SET(FILES_TO_TRANSLATE ${FILES_TO_TRANSLATE} ${FILES_CPP} ${FILES_H} ${FILES_UI} ${FILES_HXX} PARENT_SCOPE) | |
35 | SET(LUMINANCE_MODULES_GUI ${LUMINANCE_MODULES_GUI} helpbrowser PARENT_SCOPE) | |
36 | diff -rupN luminance-hdr-2.5.1/src/HelpBrowser/helpbrowser.cpp luminance-hdr-2.5.1-new/src/HelpBrowser/helpbrowser.cpp | |
37 | --- luminance-hdr-2.5.1/src/HelpBrowser/helpbrowser.cpp 2017-05-10 21:14:06.000000000 +0200 | |
38 | +++ luminance-hdr-2.5.1-new/src/HelpBrowser/helpbrowser.cpp 2017-05-11 00:32:39.449108102 +0200 | |
39 | @@ -166,8 +166,6 @@ HelpBrowser::HelpBrowser(QWidget* parent | |
40 | HelpBrowser::HelpBrowser( QWidget* parent, const QString& /*caption*/, const QString& guiLanguage, const QString& jumpToSection, const QString& jumpToFile): | |
41 | QMainWindow( parent ), | |
42 | zoomFactor(1.0), | |
43 | - //m_textBrowser(new QTextDocument), | |
44 | - m_textBrowser(new QTextBrowser), | |
45 | m_Ui(new Ui::HelpBrowser) | |
46 | { | |
47 | m_Ui->setupUi(this); | |
48 | @@ -347,13 +345,6 @@ void HelpBrowser::languageChange() | |
49 | ||
50 | void HelpBrowser::print() | |
51 | { | |
52 | - /* TODO With this method images aren't loaded so I'm passing the html page to a QTextBrowser | |
53 | - m_Ui->htmlPage->page()->toHtml([this](const QString &result){ | |
54 | - this->m_textBrowser->setHtml(result); | |
55 | - this->printAvailable(); | |
56 | - }); | |
57 | - */ | |
58 | - m_textBrowser->setSource(m_Ui->htmlPage->page()->url()); | |
59 | this->printAvailable(); | |
60 | } | |
61 | ||
62 | @@ -365,19 +356,12 @@ void HelpBrowser::printAvailable() | |
63 | if (dialog.exec()) | |
64 | { | |
65 | ||
66 | - m_textBrowser->print(&printer); | |
67 | + m_Ui->htmlPage->print(&printer); | |
68 | } | |
69 | } | |
70 | ||
71 | void HelpBrowser::printPreview() | |
72 | { | |
73 | - /* TODO With this method images aren't loaded so I'm passing the html page to a QTextBrowser | |
74 | - m_Ui->htmlPage->page()->toHtml([this](const QString &result){ | |
75 | - this->m_textBrowser->setHtml(result); | |
76 | - this->printPreviewAvailable(); | |
77 | - }); | |
78 | - */ | |
79 | - m_textBrowser->setSource(m_Ui->htmlPage->page()->url()); | |
80 | this->printPreviewAvailable(); | |
81 | } | |
82 | ||
83 | @@ -392,7 +376,7 @@ void HelpBrowser::printPreviewAvailable( | |
84 | ||
85 | void HelpBrowser::paintRequested(QPrinter *printer) | |
86 | { | |
87 | - m_textBrowser->print(printer); | |
88 | + m_Ui->htmlPage->print(printer); | |
89 | } | |
90 | ||
91 | void HelpBrowser::searchingButton_clicked() | |
92 | @@ -789,6 +773,6 @@ void HelpBrowser::loadFinished(bool) { | |
93 | statusBar()->showMessage(""); | |
94 | } | |
95 | ||
96 | -void HelpBrowser::linkHovered (const QString &url) { | |
97 | +void HelpBrowser::linkHovered (const QString &url, const QString &, const QString &) { | |
98 | statusBar()->showMessage(url); | |
99 | } | |
100 | diff -rupN luminance-hdr-2.5.1/src/HelpBrowser/helpbrowser.h luminance-hdr-2.5.1-new/src/HelpBrowser/helpbrowser.h | |
101 | --- luminance-hdr-2.5.1/src/HelpBrowser/helpbrowser.h 2017-05-10 21:14:06.000000000 +0200 | |
102 | +++ luminance-hdr-2.5.1-new/src/HelpBrowser/helpbrowser.h 2017-05-11 00:40:22.531057038 +0200 | |
103 | @@ -64,8 +64,6 @@ | |
104 | #include <QXmlInputSource> | |
105 | #include <QEvent> | |
106 | #include <QTreeWidgetItem> | |
107 | -//#include <QTextEdit> | |
108 | -#include <QTextBrowser> | |
109 | ||
110 | class ScHelpTreeModel; | |
111 | class QPrinter; | |
112 | @@ -132,10 +130,6 @@ protected: | |
113 | QMap<QString, QString> quickHelpIndex; | |
114 | QMap<QString, QPair<QString, QString> > bookmarkIndex; | |
115 | ||
116 | - // I need to keep this around because page()->toHtml( <callback> ) is asynchronous | |
117 | - //QSharedPointer<QTextDocument> m_textDocument; | |
118 | - QSharedPointer<QTextBrowser> m_textBrowser; | |
119 | - | |
120 | protected slots: | |
121 | virtual void languageChange(); | |
122 | void histChosen(QAction* i); | |
123 | @@ -215,7 +209,7 @@ protected slots: | |
124 | ||
125 | /*! \brief Restore Default Cursor */ | |
126 | void loadFinished(bool); | |
127 | - void linkHovered (const QString &); | |
128 | + void linkHovered (const QString &, const QString &, const QString &); | |
129 | signals: | |
130 | void closed(); | |
131 | ||
132 | diff -rupN luminance-hdr-2.5.1/src/HelpBrowser/sctextbrowser.cpp luminance-hdr-2.5.1-new/src/HelpBrowser/sctextbrowser.cpp | |
133 | --- luminance-hdr-2.5.1/src/HelpBrowser/sctextbrowser.cpp 2017-05-10 21:14:06.000000000 +0200 | |
134 | +++ luminance-hdr-2.5.1-new/src/HelpBrowser/sctextbrowser.cpp 2017-05-11 00:33:42.085695414 +0200 | |
135 | @@ -57,7 +57,7 @@ for which a new license (GPL+exception) | |
136 | #include "sctextbrowser.h" | |
137 | ||
138 | ScTextBrowser::ScTextBrowser( QWidget * parent ) | |
139 | - : QWebEngineView(parent) | |
140 | + : QWebView(parent) | |
141 | { | |
142 | } | |
143 | ||
144 | diff -rupN luminance-hdr-2.5.1/src/HelpBrowser/sctextbrowser.h luminance-hdr-2.5.1-new/src/HelpBrowser/sctextbrowser.h | |
145 | --- luminance-hdr-2.5.1/src/HelpBrowser/sctextbrowser.h 2017-05-10 21:14:06.000000000 +0200 | |
146 | +++ luminance-hdr-2.5.1-new/src/HelpBrowser/sctextbrowser.h 2017-05-11 00:30:33.390938650 +0200 | |
147 | @@ -45,9 +45,9 @@ for which a new license (GPL+exception) | |
148 | #define SCTEXTBROWSER_H | |
149 | ||
150 | #include <QUrl> | |
151 | -#include <QWebEngineView> | |
152 | +#include <QWebView> | |
153 | ||
154 | -class ScTextBrowser : public QWebEngineView | |
155 | +class ScTextBrowser : public QWebView | |
156 | { | |
157 | Q_OBJECT | |
158 | QUrl m_home; | |
159 | diff -rupN luminance-hdr-2.5.1/src/UI/CMakeLists.txt luminance-hdr-2.5.1-new/src/UI/CMakeLists.txt | |
160 | --- luminance-hdr-2.5.1/src/UI/CMakeLists.txt 2017-05-10 21:14:06.000000000 +0200 | |
161 | +++ luminance-hdr-2.5.1-new/src/UI/CMakeLists.txt 2017-05-11 00:30:33.391938643 +0200 | |
162 | @@ -47,7 +47,7 @@ QT5_WRAP_CPP(FILES_MOC ${FILES_H}) | |
163 | QT5_WRAP_UI(FILES_UI_H ${FILES_UI}) | |
164 | ||
165 | ADD_LIBRARY(ui ${FILES_H} ${FILES_CPP} ${FILES_MOC} ${FILES_UI_H}) | |
166 | -qt5_use_modules(ui Core Concurrent Gui Widgets WebEngineWidgets) | |
167 | +qt5_use_modules(ui Core Concurrent Gui Widgets WebKitWidgets) | |
168 | ||
169 | SET(FILES_TO_TRANSLATE ${FILES_TO_TRANSLATE} ${FILES_CPP} ${FILES_H} ${FILES_UI} PARENT_SCOPE) | |
170 | SET(LUMINANCE_MODULES_GUI ${LUMINANCE_MODULES_GUI} ui PARENT_SCOPE) |