fbreader-qt5.patch 21 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511
  1. diff -r -U2 fbreader-0.99.4.orig/fbreader/Makefile fbreader-0.99.4/fbreader/Makefile
  2. --- fbreader-0.99.4.orig/fbreader/Makefile 2012-11-30 19:41:25.000000000 +0700
  3. +++ fbreader-0.99.4/fbreader/Makefile 2018-01-11 22:18:18.000208200 +0700
  4. @@ -23,5 +23,5 @@
  5. done;
  6. @echo -n 'Linking $(TARGET) ...'
  7. - @$(LD) $(LDFLAGS) -o $(TARGET) `find src -name *.o` $(TEXT_LIBS) $(CORE_LIBS) $(ZLUI_LIB) -lsqlite3
  8. + @$(LD) -fuse-ld=bfd $(LDFLAGS) -o $(TARGET) `find src -name *.o` $(TEXT_LIBS) $(CORE_LIBS) $(ZLUI_LIB) -lsqlite3
  9. @echo ' OK'
  10. diff -r -U2 fbreader-0.99.4.orig/makefiles/arch/desktop.mk fbreader-0.99.4/makefiles/arch/desktop.mk
  11. --- fbreader-0.99.4.orig/makefiles/arch/desktop.mk 2012-11-30 19:41:25.000000000 +0700
  12. +++ fbreader-0.99.4/makefiles/arch/desktop.mk 2018-01-11 22:18:40.119207269 +0700
  13. @@ -15,27 +15,9 @@
  14. CFLAGS = -pipe -fno-exceptions -Wall -Wno-ctor-dtor-privacy -W -DLIBICONV_PLUG
  15. LDFLAGS =
  16. -EXTERNAL_INCLUDE = $(shell pkg-config --cflags fribidi)
  17. +EXTERNAL_INCLUDE = $(shell pkg-config --cflags fribidi)
  18. -ifeq "$(UI_TYPE)" "qt"
  19. - MOC = moc-qt3
  20. - QTINCLUDE = -I /usr/include/qt3
  21. -else
  22. - MOC = $(shell pkg-config QtCore --variable=moc_location)
  23. - QTINCLUDE = -I $(shell pkg-config --cflags QtCore)
  24. -endif
  25. -
  26. -GTKINCLUDE = $(shell pkg-config --cflags gtk+-2.0 libpng xft)
  27. -
  28. -ifeq "$(UI_TYPE)" "qt"
  29. - UILIBS = -lqt-mt
  30. -endif
  31. -
  32. -ifeq "$(UI_TYPE)" "qt4"
  33. - UILIBS = $(shell pkg-config --libs QtCore QtGui QtNetwork)
  34. -endif
  35. -
  36. -ifeq "$(UI_TYPE)" "gtk"
  37. - UILIBS = $(shell pkg-config --libs gtk+-2.0 gio-2.0) -lpng -ljpeg
  38. -endif
  39. +MOC = "$(shell pkg-config --variable=host_bins Qt5Core)/moc"
  40. +QTINCLUDE = $(shell pkg-config --cflags Qt5Gui Qt5Widgets Qt5Network)
  41. +UILIBS = $(shell pkg-config --libs Qt5Gui Qt5Widgets Qt5Network)
  42. RM = rm -rvf
  43. diff -r -U2 fbreader-0.99.4.orig/zlibrary/ui/src/qt4/application/LineEditParameter.cpp fbreader-0.99.4/zlibrary/ui/src/qt4/application/LineEditParameter.cpp
  44. --- fbreader-0.99.4.orig/zlibrary/ui/src/qt4/application/LineEditParameter.cpp 2012-11-30 19:41:25.000000000 +0700
  45. +++ fbreader-0.99.4/zlibrary/ui/src/qt4/application/LineEditParameter.cpp 2018-01-11 22:18:40.120207269 +0700
  46. @@ -18,7 +18,7 @@
  47. */
  48. -#include <QtGui/QBoxLayout>
  49. -#include <QtGui/QLineEdit>
  50. -#include <QtGui/QToolBar>
  51. +#include <QtWidgets/QBoxLayout>
  52. +#include <QtWidgets/QLineEdit>
  53. +#include <QtWidgets/QToolBar>
  54. #include <QtGui/QKeyEvent>
  55. diff -r -U2 fbreader-0.99.4.orig/zlibrary/ui/src/qt4/application/ZLQtApplicationWindow.cpp fbreader-0.99.4/zlibrary/ui/src/qt4/application/ZLQtApplicationWindow.cpp
  56. --- fbreader-0.99.4.orig/zlibrary/ui/src/qt4/application/ZLQtApplicationWindow.cpp 2012-11-30 19:41:25.000000000 +0700
  57. +++ fbreader-0.99.4/zlibrary/ui/src/qt4/application/ZLQtApplicationWindow.cpp 2018-01-11 22:18:40.120207269 +0700
  58. @@ -18,15 +18,15 @@
  59. */
  60. -#include <QtGui/QApplication>
  61. +#include <QtWidgets/QApplication>
  62. #include <QtGui/QPixmap>
  63. #include <QtGui/QImage>
  64. #include <QtGui/QIcon>
  65. -#include <QtGui/QToolBar>
  66. -#include <QtGui/QMenuBar>
  67. -#include <QtGui/QMenu>
  68. -#include <QtGui/QToolButton>
  69. -#include <QtGui/QLayout>
  70. +#include <QtWidgets/QToolBar>
  71. +#include <QtWidgets/QMenuBar>
  72. +#include <QtWidgets/QMenu>
  73. +#include <QtWidgets/QToolButton>
  74. +#include <QtWidgets/QLayout>
  75. #include <QtGui/QWheelEvent>
  76. -#include <QtGui/QDockWidget>
  77. +#include <QtWidgets/QDockWidget>
  78. #include <QtCore/QObjectList>
  79. diff -r -U2 fbreader-0.99.4.orig/zlibrary/ui/src/qt4/application/ZLQtApplicationWindow.h fbreader-0.99.4/zlibrary/ui/src/qt4/application/ZLQtApplicationWindow.h
  80. --- fbreader-0.99.4.orig/zlibrary/ui/src/qt4/application/ZLQtApplicationWindow.h 2012-11-30 19:41:25.000000000 +0700
  81. +++ fbreader-0.99.4/zlibrary/ui/src/qt4/application/ZLQtApplicationWindow.h 2018-01-11 22:18:40.120207269 +0700
  82. @@ -23,6 +23,6 @@
  83. #include <map>
  84. -#include <QtGui/QMainWindow>
  85. -#include <QtGui/QAction>
  86. +#include <QtWidgets/QMainWindow>
  87. +#include <QtWidgets/QAction>
  88. #include <QtGui/QCursor>
  89. diff -r -U2 fbreader-0.99.4.orig/zlibrary/ui/src/qt4/dialogs/ZLQtDialog.cpp fbreader-0.99.4/zlibrary/ui/src/qt4/dialogs/ZLQtDialog.cpp
  90. --- fbreader-0.99.4.orig/zlibrary/ui/src/qt4/dialogs/ZLQtDialog.cpp 2012-11-30 19:41:25.000000000 +0700
  91. +++ fbreader-0.99.4/zlibrary/ui/src/qt4/dialogs/ZLQtDialog.cpp 2018-01-11 22:18:40.120207269 +0700
  92. @@ -18,6 +18,6 @@
  93. */
  94. -#include <QtGui/QApplication>
  95. -#include <QtGui/QPushButton>
  96. +#include <QtWidgets/QApplication>
  97. +#include <QtWidgets/QPushButton>
  98. #include <ZLDialogManager.h>
  99. diff -r -U2 fbreader-0.99.4.orig/zlibrary/ui/src/qt4/dialogs/ZLQtDialog.h fbreader-0.99.4/zlibrary/ui/src/qt4/dialogs/ZLQtDialog.h
  100. --- fbreader-0.99.4.orig/zlibrary/ui/src/qt4/dialogs/ZLQtDialog.h 2012-11-30 19:41:25.000000000 +0700
  101. +++ fbreader-0.99.4/zlibrary/ui/src/qt4/dialogs/ZLQtDialog.h 2018-01-11 22:18:40.120207269 +0700
  102. @@ -21,6 +21,6 @@
  103. #define __ZLQTDIALOG_H__
  104. -#include <QtGui/QDialog>
  105. -#include <QtGui/QLayout>
  106. +#include <QtWidgets/QDialog>
  107. +#include <QtWidgets/QLayout>
  108. #include <ZLDialog.h>
  109. diff -r -U2 fbreader-0.99.4.orig/zlibrary/ui/src/qt4/dialogs/ZLQtDialogContent.cpp fbreader-0.99.4/zlibrary/ui/src/qt4/dialogs/ZLQtDialogContent.cpp
  110. --- fbreader-0.99.4.orig/zlibrary/ui/src/qt4/dialogs/ZLQtDialogContent.cpp 2012-11-30 19:41:25.000000000 +0700
  111. +++ fbreader-0.99.4/zlibrary/ui/src/qt4/dialogs/ZLQtDialogContent.cpp 2018-01-11 22:18:40.120207269 +0700
  112. @@ -18,8 +18,8 @@
  113. */
  114. -#include <QtGui/QApplication>
  115. -#include <QtGui/QDesktopWidget>
  116. -#include <QtGui/QWidget>
  117. -#include <QtGui/QLayout>
  118. +#include <QtWidgets/QApplication>
  119. +#include <QtWidgets/QDesktopWidget>
  120. +#include <QtWidgets/QWidget>
  121. +#include <QtWidgets/QLayout>
  122. #include "ZLQtDialogContent.h"
  123. diff -r -U2 fbreader-0.99.4.orig/zlibrary/ui/src/qt4/dialogs/ZLQtDialogManager.cpp fbreader-0.99.4/zlibrary/ui/src/qt4/dialogs/ZLQtDialogManager.cpp
  124. --- fbreader-0.99.4.orig/zlibrary/ui/src/qt4/dialogs/ZLQtDialogManager.cpp 2012-11-30 19:41:25.000000000 +0700
  125. +++ fbreader-0.99.4/zlibrary/ui/src/qt4/dialogs/ZLQtDialogManager.cpp 2018-01-11 22:18:40.120207269 +0700
  126. @@ -18,9 +18,9 @@
  127. */
  128. -#include <QtGui/QApplication>
  129. -#include <QtGui/QMessageBox>
  130. -#include <QtGui/QFileDialog>
  131. +#include <QtWidgets/QApplication>
  132. +#include <QtWidgets/QMessageBox>
  133. +#include <QtWidgets/QFileDialog>
  134. #include <QtGui/QClipboard>
  135. -#include <QtGui/QDesktopWidget>
  136. +#include <QtWidgets/QDesktopWidget>
  137. #include "ZLQtDialogManager.h"
  138. diff -r -U2 fbreader-0.99.4.orig/zlibrary/ui/src/qt4/dialogs/ZLQtOpenFileDialog.cpp fbreader-0.99.4/zlibrary/ui/src/qt4/dialogs/ZLQtOpenFileDialog.cpp
  139. --- fbreader-0.99.4.orig/zlibrary/ui/src/qt4/dialogs/ZLQtOpenFileDialog.cpp 2012-11-30 19:41:25.000000000 +0700
  140. +++ fbreader-0.99.4/zlibrary/ui/src/qt4/dialogs/ZLQtOpenFileDialog.cpp 2018-01-11 22:18:40.120207269 +0700
  141. @@ -18,5 +18,5 @@
  142. */
  143. -#include <QtGui/QFileDialog>
  144. +#include <QtWidgets/QFileDialog>
  145. #include "ZLQtOpenFileDialog.h"
  146. diff -r -U2 fbreader-0.99.4.orig/zlibrary/ui/src/qt4/dialogs/ZLQtOptionView.cpp fbreader-0.99.4/zlibrary/ui/src/qt4/dialogs/ZLQtOptionView.cpp
  147. --- fbreader-0.99.4.orig/zlibrary/ui/src/qt4/dialogs/ZLQtOptionView.cpp 2012-11-30 19:41:25.000000000 +0700
  148. +++ fbreader-0.99.4/zlibrary/ui/src/qt4/dialogs/ZLQtOptionView.cpp 2018-01-11 22:18:40.121207269 +0700
  149. @@ -20,14 +20,14 @@
  150. #include <cctype>
  151. -#include <QtGui/QCheckBox>
  152. -#include <QtGui/QComboBox>
  153. -#include <QtGui/QLabel>
  154. -#include <QtGui/QGroupBox>
  155. -#include <QtGui/QRadioButton>
  156. -#include <QtGui/QPushButton>
  157. -#include <QtGui/QSpinBox>
  158. -#include <QtGui/QLineEdit>
  159. -#include <QtGui/QSlider>
  160. -#include <QtGui/QLayout>
  161. +#include <QtWidgets/QCheckBox>
  162. +#include <QtWidgets/QComboBox>
  163. +#include <QtWidgets/QLabel>
  164. +#include <QtWidgets/QGroupBox>
  165. +#include <QtWidgets/QRadioButton>
  166. +#include <QtWidgets/QPushButton>
  167. +#include <QtWidgets/QSpinBox>
  168. +#include <QtWidgets/QLineEdit>
  169. +#include <QtWidgets/QSlider>
  170. +#include <QtWidgets/QLayout>
  171. #include <ZLStringUtil.h>
  172. diff -r -U2 fbreader-0.99.4.orig/zlibrary/ui/src/qt4/dialogs/ZLQtOptionsDialog.cpp fbreader-0.99.4/zlibrary/ui/src/qt4/dialogs/ZLQtOptionsDialog.cpp
  173. --- fbreader-0.99.4.orig/zlibrary/ui/src/qt4/dialogs/ZLQtOptionsDialog.cpp 2012-11-30 19:41:25.000000000 +0700
  174. +++ fbreader-0.99.4/zlibrary/ui/src/qt4/dialogs/ZLQtOptionsDialog.cpp 2018-01-11 22:18:40.121207269 +0700
  175. @@ -18,9 +18,9 @@
  176. */
  177. -#include <QtGui/QApplication>
  178. -#include <QtGui/QDesktopWidget>
  179. -#include <QtGui/QLayout>
  180. -#include <QtGui/QPushButton>
  181. -#include <QtGui/QButtonGroup>
  182. +#include <QtWidgets/QApplication>
  183. +#include <QtWidgets/QDesktopWidget>
  184. +#include <QtWidgets/QLayout>
  185. +#include <QtWidgets/QPushButton>
  186. +#include <QtWidgets/QButtonGroup>
  187. #include <QtGui/QResizeEvent>
  188. diff -r -U2 fbreader-0.99.4.orig/zlibrary/ui/src/qt4/dialogs/ZLQtOptionsDialog.h fbreader-0.99.4/zlibrary/ui/src/qt4/dialogs/ZLQtOptionsDialog.h
  189. --- fbreader-0.99.4.orig/zlibrary/ui/src/qt4/dialogs/ZLQtOptionsDialog.h 2012-11-30 19:41:25.000000000 +0700
  190. +++ fbreader-0.99.4/zlibrary/ui/src/qt4/dialogs/ZLQtOptionsDialog.h 2018-01-11 22:18:40.121207269 +0700
  191. @@ -21,7 +21,7 @@
  192. #define __ZLQTOPTIONSDIALOG_H__
  193. -#include <QtGui/QWidget>
  194. -#include <QtGui/QTabWidget>
  195. -#include <QtGui/QDialog>
  196. +#include <QtWidgets/QWidget>
  197. +#include <QtWidgets/QTabWidget>
  198. +#include <QtWidgets/QDialog>
  199. #include "../../../../core/src/desktop/dialogs/ZLDesktopOptionsDialog.h"
  200. diff -r -U2 fbreader-0.99.4.orig/zlibrary/ui/src/qt4/dialogs/ZLQtProgressDialog.cpp fbreader-0.99.4/zlibrary/ui/src/qt4/dialogs/ZLQtProgressDialog.cpp
  201. --- fbreader-0.99.4.orig/zlibrary/ui/src/qt4/dialogs/ZLQtProgressDialog.cpp 2012-11-30 19:41:25.000000000 +0700
  202. +++ fbreader-0.99.4/zlibrary/ui/src/qt4/dialogs/ZLQtProgressDialog.cpp 2018-01-11 22:18:40.121207269 +0700
  203. @@ -20,9 +20,9 @@
  204. #include <unistd.h>
  205. -#include <QtGui/QApplication>
  206. -#include <QtGui/QDesktopWidget>
  207. -#include <QtGui/QWidget>
  208. -#include <QtGui/QLabel>
  209. -#include <QtGui/QLayout>
  210. +#include <QtWidgets/QApplication>
  211. +#include <QtWidgets/QDesktopWidget>
  212. +#include <QtWidgets/QWidget>
  213. +#include <QtWidgets/QLabel>
  214. +#include <QtWidgets/QLayout>
  215. #include <QtCore/QThreadPool>
  216. diff -r -U2 fbreader-0.99.4.orig/zlibrary/ui/src/qt4/dialogs/ZLQtProgressDialog.h fbreader-0.99.4/zlibrary/ui/src/qt4/dialogs/ZLQtProgressDialog.h
  217. --- fbreader-0.99.4.orig/zlibrary/ui/src/qt4/dialogs/ZLQtProgressDialog.h 2012-11-30 19:41:25.000000000 +0700
  218. +++ fbreader-0.99.4/zlibrary/ui/src/qt4/dialogs/ZLQtProgressDialog.h 2018-01-11 22:18:40.121207269 +0700
  219. @@ -23,9 +23,9 @@
  220. #include <string>
  221. -#include <QtGui/QWidget>
  222. +#include <QtWidgets/QWidget>
  223. #include <QtGui/QCursor>
  224. -#include <QtGui/QDialog>
  225. -#include <QtGui/QProgressBar>
  226. -#include <QtGui/QLabel>
  227. +#include <QtWidgets/QDialog>
  228. +#include <QtWidgets/QProgressBar>
  229. +#include <QtWidgets/QLabel>
  230. #include <QtCore/QRunnable>
  231. diff -r -U2 fbreader-0.99.4.orig/zlibrary/ui/src/qt4/dialogs/ZLQtTreeDialog.cpp fbreader-0.99.4/zlibrary/ui/src/qt4/dialogs/ZLQtTreeDialog.cpp
  232. --- fbreader-0.99.4.orig/zlibrary/ui/src/qt4/dialogs/ZLQtTreeDialog.cpp 2012-11-30 19:41:25.000000000 +0700
  233. +++ fbreader-0.99.4/zlibrary/ui/src/qt4/dialogs/ZLQtTreeDialog.cpp 2018-01-11 22:18:40.120207269 +0700
  234. @@ -20,10 +20,10 @@
  235. #include <algorithm>
  236. -#include <QtGui/QSplitter>
  237. -#include <QtGui/QVBoxLayout>
  238. -#include <QtGui/QHBoxLayout>
  239. -#include <QtGui/QScrollBar>
  240. #include <QtGui/QResizeEvent>
  241. #include <QtCore/QDebug>
  242. +#include <QtWidgets/QSplitter>
  243. +#include <QtWidgets/QVBoxLayout>
  244. +#include <QtWidgets/QHBoxLayout>
  245. +#include <QtWidgets/QScrollBar>
  246. #include <ZLFile.h>
  247. diff -r -U2 fbreader-0.99.4.orig/zlibrary/ui/src/qt4/dialogs/ZLQtTreeDialog.h fbreader-0.99.4/zlibrary/ui/src/qt4/dialogs/ZLQtTreeDialog.h
  248. --- fbreader-0.99.4.orig/zlibrary/ui/src/qt4/dialogs/ZLQtTreeDialog.h 2012-11-30 19:41:25.000000000 +0700
  249. +++ fbreader-0.99.4/zlibrary/ui/src/qt4/dialogs/ZLQtTreeDialog.h 2018-01-11 22:18:40.121207269 +0700
  250. @@ -25,10 +25,10 @@
  251. #include <QtCore/QMap>
  252. -#include <QtGui/QDialog>
  253. -#include <QtGui/QScrollArea>
  254. -#include <QtGui/QPushButton>
  255. -#include <QtGui/QLabel>
  256. -#include <QtGui/QLineEdit>
  257. -#include <QtGui/QWidget>
  258. +#include <QtWidgets/QDialog>
  259. +#include <QtWidgets/QScrollArea>
  260. +#include <QtWidgets/QPushButton>
  261. +#include <QtWidgets/QLabel>
  262. +#include <QtWidgets/QLineEdit>
  263. +#include <QtWidgets/QWidget>
  264. #include <ZLTreeDialog.h>
  265. diff -r -U2 fbreader-0.99.4.orig/zlibrary/ui/src/qt4/library/ZLQApplication.h fbreader-0.99.4/zlibrary/ui/src/qt4/library/ZLQApplication.h
  266. --- fbreader-0.99.4.orig/zlibrary/ui/src/qt4/library/ZLQApplication.h 2012-11-30 19:41:25.000000000 +0700
  267. +++ fbreader-0.99.4/zlibrary/ui/src/qt4/library/ZLQApplication.h 2018-01-11 22:18:40.121207269 +0700
  268. @@ -21,5 +21,5 @@
  269. #define __ZLQAPPLICATION_H__
  270. -#include <QtGui/QApplication>
  271. +#include <QtWidgets/QApplication>
  272. class ZLQApplication : public QApplication {
  273. diff -r -U2 fbreader-0.99.4.orig/zlibrary/ui/src/qt4/library/ZLibrary.cpp fbreader-0.99.4/zlibrary/ui/src/qt4/library/ZLibrary.cpp
  274. --- fbreader-0.99.4.orig/zlibrary/ui/src/qt4/library/ZLibrary.cpp 2012-11-30 19:41:25.000000000 +0700
  275. +++ fbreader-0.99.4/zlibrary/ui/src/qt4/library/ZLibrary.cpp 2018-01-11 22:18:40.121207269 +0700
  276. @@ -20,5 +20,5 @@
  277. #include <QtCore/QTextCodec>
  278. #include <QtCore/QFile>
  279. -#include <QtGui/QApplication>
  280. +#include <QtWidgets/QApplication>
  281. #include <QtGui/QFileOpenEvent>
  282. @@ -73,5 +73,5 @@
  283. new ZLQApplication(argc, argv);
  284. - QTextCodec::setCodecForCStrings(QTextCodec::codecForName("utf-8"));
  285. + QTextCodec::setCodecForLocale(QTextCodec::codecForName("utf-8"));
  286. ZLibrary::parseArguments(argc, argv);
  287. diff -r -U2 fbreader-0.99.4.orig/zlibrary/ui/src/qt4/network/ZLQtNetworkManager.cpp fbreader-0.99.4/zlibrary/ui/src/qt4/network/ZLQtNetworkManager.cpp
  288. --- fbreader-0.99.4.orig/zlibrary/ui/src/qt4/network/ZLQtNetworkManager.cpp 2012-11-30 19:41:25.000000000 +0700
  289. +++ fbreader-0.99.4/zlibrary/ui/src/qt4/network/ZLQtNetworkManager.cpp 2018-01-11 22:18:40.120207269 +0700
  290. @@ -25,5 +25,7 @@
  291. #include <QtCore/QList>
  292. #include <QtCore/QTimer>
  293. +#include <QtCore/QUrlQuery>
  294. +#include <QtNetwork/QNetworkCookie>
  295. #include <QtNetwork/QNetworkRequest>
  296. #include <QtNetwork/QNetworkReply>
  297. @@ -150,10 +152,10 @@
  298. if (!scope.request->postParameters().empty()) {
  299. QByteArray data;
  300. - QUrl tmp;
  301. + QUrlQuery tmp;
  302. typedef std::pair<std::string, std::string> string_pair;
  303. foreach (const string_pair &pair, scope.request->postParameters()) {
  304. tmp.addQueryItem(QString::fromStdString(pair.first), QString::fromStdString(pair.second));
  305. }
  306. - data = tmp.encodedQuery();
  307. + data = tmp.query(QUrl::FullyEncoded).toUtf8(); //encodedQuery();
  308. reply = const_cast<QNetworkAccessManager&>(myManager).post(networkRequest, data);
  309. } else {
  310. diff -r -U2 fbreader-0.99.4.orig/zlibrary/ui/src/qt4/tree/QtWaitingSpinner.cpp fbreader-0.99.4/zlibrary/ui/src/qt4/tree/QtWaitingSpinner.cpp
  311. --- fbreader-0.99.4.orig/zlibrary/ui/src/qt4/tree/QtWaitingSpinner.cpp 2012-11-30 19:41:25.000000000 +0700
  312. +++ fbreader-0.99.4/zlibrary/ui/src/qt4/tree/QtWaitingSpinner.cpp 2018-01-11 22:13:39.639219906 +0700
  313. @@ -87,5 +87,5 @@
  314. void QtWaitingSpinner::setRoundness(qreal roundness) {
  315. - myRoundness = std::max(0.0, std::min(100.0, roundness));
  316. + myRoundness = std::max(static_cast<qreal>(0.0), std::min(static_cast<qreal>(100.0), roundness));
  317. }
  318. @@ -149,5 +149,5 @@
  319. qreal gradation = alphaDiff / (qreal)(distanceThreshold + 1);
  320. qreal resultAlpha = color.alphaF() - gradation * distance;
  321. - resultAlpha = std::min(1.0, std::max(0.0, resultAlpha)); //if alpha is out of bound, force it to bounds
  322. + resultAlpha = std::min(static_cast<qreal>(1.0), std::max(static_cast<qreal>(0.0), resultAlpha)); //if alpha is out of bound, force it to bounds
  323. color.setAlphaF(resultAlpha);
  324. return color;
  325. diff -r -U2 fbreader-0.99.4.orig/zlibrary/ui/src/qt4/tree/QtWaitingSpinner.h fbreader-0.99.4/zlibrary/ui/src/qt4/tree/QtWaitingSpinner.h
  326. --- fbreader-0.99.4.orig/zlibrary/ui/src/qt4/tree/QtWaitingSpinner.h 2012-11-30 19:41:25.000000000 +0700
  327. +++ fbreader-0.99.4/zlibrary/ui/src/qt4/tree/QtWaitingSpinner.h 2018-01-11 22:18:40.121207269 +0700
  328. @@ -4,5 +4,5 @@
  329. #include <QtCore/QTimer>
  330. -#include <QtGui/QWidget>
  331. +#include <QtWidgets/QWidget>
  332. #include <QtGui/QColor>
  333. diff -r -U2 fbreader-0.99.4.orig/zlibrary/ui/src/qt4/tree/ZLQtItemsListWidget.cpp fbreader-0.99.4/zlibrary/ui/src/qt4/tree/ZLQtItemsListWidget.cpp
  334. --- fbreader-0.99.4.orig/zlibrary/ui/src/qt4/tree/ZLQtItemsListWidget.cpp 2012-11-30 19:41:25.000000000 +0700
  335. +++ fbreader-0.99.4/zlibrary/ui/src/qt4/tree/ZLQtItemsListWidget.cpp 2018-01-11 22:18:40.120207269 +0700
  336. @@ -18,12 +18,12 @@
  337. */
  338. -#include <QtGui/QVBoxLayout>
  339. -#include <QtGui/QHBoxLayout>
  340. #include <QtGui/QPixmap>
  341. #include <QtGui/QPalette>
  342. #include <QtGui/QPainter>
  343. #include <QtGui/QPaintEvent>
  344. -#include <QtGui/QScrollBar>
  345. #include <QtCore/QTimer>
  346. +#include <QtWidgets/QVBoxLayout>
  347. +#include <QtWidgets/QHBoxLayout>
  348. +#include <QtWidgets/QScrollBar>
  349. #include <QtCore/QDebug>
  350. diff -r -U2 fbreader-0.99.4.orig/zlibrary/ui/src/qt4/tree/ZLQtItemsListWidget.h fbreader-0.99.4/zlibrary/ui/src/qt4/tree/ZLQtItemsListWidget.h
  351. --- fbreader-0.99.4.orig/zlibrary/ui/src/qt4/tree/ZLQtItemsListWidget.h 2012-11-30 19:41:25.000000000 +0700
  352. +++ fbreader-0.99.4/zlibrary/ui/src/qt4/tree/ZLQtItemsListWidget.h 2018-01-11 22:18:40.120207269 +0700
  353. @@ -21,10 +21,10 @@
  354. #define __ZLQTITEMSLISTWIDGET_H__
  355. -#include <QtGui/QWidget>
  356. -#include <QtGui/QFrame>
  357. -#include <QtGui/QPushButton>
  358. -#include <QtGui/QLabel>
  359. -#include <QtGui/QVBoxLayout>
  360. -#include <QtGui/QScrollArea>
  361. +#include <QtWidgets/QWidget>
  362. +#include <QtWidgets/QFrame>
  363. +#include <QtWidgets/QPushButton>
  364. +#include <QtWidgets/QLabel>
  365. +#include <QtWidgets/QVBoxLayout>
  366. +#include <QtWidgets/QScrollArea>
  367. #include <ZLTreeTitledNode.h>
  368. diff -r -U2 fbreader-0.99.4.orig/zlibrary/ui/src/qt4/tree/ZLQtPreviewWidget.cpp fbreader-0.99.4/zlibrary/ui/src/qt4/tree/ZLQtPreviewWidget.cpp
  369. --- fbreader-0.99.4.orig/zlibrary/ui/src/qt4/tree/ZLQtPreviewWidget.cpp 2012-11-30 19:41:25.000000000 +0700
  370. +++ fbreader-0.99.4/zlibrary/ui/src/qt4/tree/ZLQtPreviewWidget.cpp 2018-01-11 22:18:40.120207269 +0700
  371. @@ -18,8 +18,8 @@
  372. */
  373. -#include <QtGui/QVBoxLayout>
  374. -#include <QtGui/QHBoxLayout>
  375. -#include <QtGui/QScrollBar>
  376. -#include <QtGui/QGraphicsDropShadowEffect>
  377. +#include <QtWidgets/QVBoxLayout>
  378. +#include <QtWidgets/QHBoxLayout>
  379. +#include <QtWidgets/QScrollBar>
  380. +#include <QtWidgets/QGraphicsDropShadowEffect>
  381. #include <QtCore/QDebug>
  382. diff -r -U2 fbreader-0.99.4.orig/zlibrary/ui/src/qt4/tree/ZLQtPreviewWidget.h fbreader-0.99.4/zlibrary/ui/src/qt4/tree/ZLQtPreviewWidget.h
  383. --- fbreader-0.99.4.orig/zlibrary/ui/src/qt4/tree/ZLQtPreviewWidget.h 2012-11-30 19:41:25.000000000 +0700
  384. +++ fbreader-0.99.4/zlibrary/ui/src/qt4/tree/ZLQtPreviewWidget.h 2018-01-11 22:18:40.121207269 +0700
  385. @@ -21,9 +21,9 @@
  386. #define __ZLQTPREVIEWWIDGET_H__
  387. -#include <QtGui/QWidget>
  388. -#include <QtGui/QPushButton>
  389. -#include <QtGui/QLabel>
  390. -#include <QtGui/QScrollArea>
  391. -#include <QtGui/QVBoxLayout>
  392. +#include <QtWidgets/QWidget>
  393. +#include <QtWidgets/QPushButton>
  394. +#include <QtWidgets/QLabel>
  395. +#include <QtWidgets/QScrollArea>
  396. +#include <QtWidgets/QVBoxLayout>
  397. #include <QtCore/QSet>
  398. diff -r -U2 fbreader-0.99.4.orig/zlibrary/ui/src/qt4/tree/ZLQtSearchField.cpp fbreader-0.99.4/zlibrary/ui/src/qt4/tree/ZLQtSearchField.cpp
  399. --- fbreader-0.99.4.orig/zlibrary/ui/src/qt4/tree/ZLQtSearchField.cpp 2012-11-30 19:41:25.000000000 +0700
  400. +++ fbreader-0.99.4/zlibrary/ui/src/qt4/tree/ZLQtSearchField.cpp 2018-01-11 22:18:40.120207269 +0700
  401. @@ -19,7 +19,7 @@
  402. #include <QtCore/QDebug>
  403. -#include <QtGui/QStyle>
  404. -#include <QtGui/QCompleter>
  405. -#include <QtGui/QStringListModel>
  406. +#include <QtCore/QStringListModel>
  407. +#include <QtWidgets/QStyle>
  408. +#include <QtWidgets/QCompleter>
  409. #include <ZLibrary.h>
  410. diff -r -U2 fbreader-0.99.4.orig/zlibrary/ui/src/qt4/tree/ZLQtSearchField.h fbreader-0.99.4/zlibrary/ui/src/qt4/tree/ZLQtSearchField.h
  411. --- fbreader-0.99.4.orig/zlibrary/ui/src/qt4/tree/ZLQtSearchField.h 2012-11-30 19:41:25.000000000 +0700
  412. +++ fbreader-0.99.4/zlibrary/ui/src/qt4/tree/ZLQtSearchField.h 2018-01-11 22:18:40.121207269 +0700
  413. @@ -22,6 +22,6 @@
  414. #include <QtCore/QSet>
  415. -#include <QtGui/QLabel>
  416. -#include <QtGui/QLineEdit>
  417. +#include <QtWidgets/QLabel>
  418. +#include <QtWidgets/QLineEdit>
  419. #include "QtWaitingSpinner.h"
  420. diff -r -U2 fbreader-0.99.4.orig/zlibrary/ui/src/qt4/view/ZLQtViewWidget.cpp fbreader-0.99.4/zlibrary/ui/src/qt4/view/ZLQtViewWidget.cpp
  421. --- fbreader-0.99.4.orig/zlibrary/ui/src/qt4/view/ZLQtViewWidget.cpp 2012-11-30 19:41:25.000000000 +0700
  422. +++ fbreader-0.99.4/zlibrary/ui/src/qt4/view/ZLQtViewWidget.cpp 2018-01-11 22:18:40.121207269 +0700
  423. @@ -20,6 +20,6 @@
  424. #include <algorithm>
  425. -#include <QtGui/QLayout>
  426. -#include <QtGui/QScrollBar>
  427. +#include <QtWidgets/QLayout>
  428. +#include <QtWidgets/QScrollBar>
  429. #include <QtGui/QPainter>
  430. #include <QtGui/QPixmap>
  431. @@ -186,9 +186,9 @@
  432. void ZLQtViewWidget::setScrollbarEnabled(ZLView::Direction direction, bool enabled) {
  433. if (direction == ZLView::VERTICAL) {
  434. - myRightScrollBar->setShown(enabled && myShowScrollBarAtRight);
  435. - myLeftScrollBar->setShown(enabled && !myShowScrollBarAtRight);
  436. + myRightScrollBar->setVisible(enabled && myShowScrollBarAtRight);
  437. + myLeftScrollBar->setVisible(enabled && !myShowScrollBarAtRight);
  438. } else {
  439. - myBottomScrollBar->setShown(enabled && myShowScrollBarAtBottom);
  440. - myTopScrollBar->setShown(enabled && !myShowScrollBarAtBottom);
  441. + myBottomScrollBar->setVisible(enabled && myShowScrollBarAtBottom);
  442. + myTopScrollBar->setVisible(enabled && !myShowScrollBarAtBottom);
  443. }
  444. }
  445. diff -r -U2 fbreader-0.99.4.orig/zlibrary/ui/src/qt4/view/ZLQtViewWidget.h fbreader-0.99.4/zlibrary/ui/src/qt4/view/ZLQtViewWidget.h
  446. --- fbreader-0.99.4.orig/zlibrary/ui/src/qt4/view/ZLQtViewWidget.h 2012-11-30 19:41:25.000000000 +0700
  447. +++ fbreader-0.99.4/zlibrary/ui/src/qt4/view/ZLQtViewWidget.h 2018-01-11 22:18:40.121207269 +0700
  448. @@ -21,5 +21,5 @@
  449. #define __ZLQTVIEWWIDGET_H__
  450. -#include <QtGui/QWidget>
  451. +#include <QtWidgets/QWidget>
  452. #include "../../../../core/src/view/ZLViewWidget.h"