`GIT_VERSION` and `BUILD_DATE` are only displayed to the user.
It was useful pre-release to identify the exact version of the build in
bug report.
Now than, we are now releasing kiwix-desktop, we don't need the
`BUILD_DATE` and we must use the exact version instead of the git version.
Fix#476
- add a delay before searching suggestions
A timer of 100ms is started each time the text is edited, if the timer
time-outs the suggestion's search is executed.
- foreach search a worker with a token is launched in another thread
Once the search is done, the worker sends the suggestions list and the corresponding urls list to the main thread.
if the token of the worker matches with the last token used, the main thread displays the suggestions.
The ContentTypeFilter Class is a custom QCheckBox.
These are stored in a QList that is sended to the ContentManager each time they are clicked.
The ContentManager sets the acceptedTags according to the state of the ContentTypeFilters
The "All" button resets the filters
We don't need to configure the (default) profile each time we create a
new web page.
Let's create a specific profile for the application and use it everywhere.
This is the profile who is responsible to :
- configure itself with the schemeHandler for "zim"
- handle the download (this probably fix a bug if a user close the page
while a download associated to the page is running)
Display the "local kiwix server" option in the menu
This option opens a Qdialog that have options to control the server (run, open
in browser, stop).
The KiwixServe::run() method use execvp to run the kiwix-serve binary.
Using Curl fct of the kiwix library is synchrone, so when the server accepts
the request but doesn't answer, the kiwix-desktop app is unresponsive.
To avoid that, this is a new architecture based on the Qt network request
management.
There is a new member in the contentmanager based on the new class
OpdsRequestManagerManager. It has two members : m_networkManager sends the
request and return a pointer stored in mp_reply which will receive the answer
of the request.
When the remote library has to be update, it calls
the doUpdate method. It checks if there already is a running request and
aborts it if yes. Then m_networkManager sends the
request and return a pointer stored in mp_reply which will receive the answer
of the request. The signal 'finished' of the mp_reply is connected to the slot
receiveContent. In this slot it checks if the signal 'finished' was emit
because of an abort, if not it reads and emit a signal bookChanged with the
content in parameter. This signal in connected in the ContentManager class
to the slot 'updateRemoteLibrary' which update the remote library member.
It appears that setting `INCLUDEPATH` in qmake break things.
Because qmake add the include path using `-isystem`.
We don't need to extract include path and define from PKGCONFIG_CFLAGS.
Updating `CFLAGS` and `CXXFLAGS` is enough. No need for complex things.
Fix#90Fixkiwix/kiwix-build#260
flatpack doesn't export files that aren't prefixed like the app (org.kiwix.desktop)
so it has to be renamed and to be precised in the mimetype.xml file because it doesn't matched to the mimetype's name anymore
This is useless. It was use to rewrite http request to zim request and
have the custumUrlShemeHandler handle the request.
However, we now want to open http request in a external browser.
And it is already the case, the http requests are never intercepted.