[app] Only use those HarbourLib classes that we really need
This commit is contained in:
parent
ef131690bb
commit
e1f75ed04a
5 changed files with 61 additions and 43 deletions
28
app/app.pro
28
app/app.pro
|
@ -30,22 +30,22 @@ FRIBIDI_DIR = $$_PRO_FILE_PWD_/../fribidi
|
||||||
LINEBREAK_DIR = $$_PRO_FILE_PWD_/../linebreak
|
LINEBREAK_DIR = $$_PRO_FILE_PWD_/../linebreak
|
||||||
HARBOUR_LIB_DIR = $$_PRO_FILE_PWD_/../harbour-lib
|
HARBOUR_LIB_DIR = $$_PRO_FILE_PWD_/../harbour-lib
|
||||||
|
|
||||||
|
HARBOUR_INCLUDE_DIR = $$HARBOUR_LIB_DIR/include
|
||||||
|
HARBOUR_SRC_DIR = $$HARBOUR_LIB_DIR/src
|
||||||
|
|
||||||
# Libraries
|
# Libraries
|
||||||
FBREADER_LIB = $$OUT_PWD/../fbreader/libfbreader.a
|
FBREADER_LIB = $$OUT_PWD/../fbreader/libfbreader.a
|
||||||
FRIBIDI_LIB = $$OUT_PWD/../fribidi/libfribidi.a
|
FRIBIDI_LIB = $$OUT_PWD/../fribidi/libfribidi.a
|
||||||
LINEBREAK_LIB = $$OUT_PWD/../linebreak/liblinebreak.a
|
LINEBREAK_LIB = $$OUT_PWD/../linebreak/liblinebreak.a
|
||||||
HARBOUR_LIB = $$OUT_PWD/../harbour-lib/libharbour-lib.a
|
|
||||||
|
|
||||||
PRE_TARGETDEPS += \
|
PRE_TARGETDEPS += \
|
||||||
$$FBREADER_LIB \
|
$$FBREADER_LIB \
|
||||||
$$FRIBIDI_LIB \
|
$$FRIBIDI_LIB \
|
||||||
$$LINEBREAK_LIB \
|
$$LINEBREAK_LIB
|
||||||
$$HARBOUR_LIB
|
|
||||||
LIBS += \
|
LIBS += \
|
||||||
$$FBREADER_LIB \
|
$$FBREADER_LIB \
|
||||||
$$FRIBIDI_LIB \
|
$$FRIBIDI_LIB \
|
||||||
$$LINEBREAK_LIB \
|
$$LINEBREAK_LIB \
|
||||||
$$HARBOUR_LIB \
|
|
||||||
-lbz2 -lz -ldl
|
-lbz2 -lz -ldl
|
||||||
|
|
||||||
OTHER_FILES += \
|
OTHER_FILES += \
|
||||||
|
@ -86,7 +86,7 @@ INSTALLS += formats
|
||||||
|
|
||||||
INCLUDEPATH += \
|
INCLUDEPATH += \
|
||||||
src \
|
src \
|
||||||
$$HARBOUR_LIB_DIR/include \
|
$$HARBOUR_INCLUDE_DIR \
|
||||||
$$FBREADER_DIR/fbreader/fbreader/src \
|
$$FBREADER_DIR/fbreader/fbreader/src \
|
||||||
$$FBREADER_DIR/fbreader/zlibrary/text/include \
|
$$FBREADER_DIR/fbreader/zlibrary/text/include \
|
||||||
$$FBREADER_DIR/fbreader/zlibrary/core/include \
|
$$FBREADER_DIR/fbreader/zlibrary/core/include \
|
||||||
|
@ -173,6 +173,24 @@ HEADERS += \
|
||||||
src/BooksTypes.h \
|
src/BooksTypes.h \
|
||||||
src/BooksUtil.h
|
src/BooksUtil.h
|
||||||
|
|
||||||
|
# harbour-lib
|
||||||
|
|
||||||
|
HEADERS += \
|
||||||
|
$$HARBOUR_INCLUDE_DIR/HarbourDisplayBlanking.h \
|
||||||
|
$$HARBOUR_INCLUDE_DIR/HarbourJson.h \
|
||||||
|
$$HARBOUR_INCLUDE_DIR/HarbourPluginLoader.h \
|
||||||
|
$$HARBOUR_INCLUDE_DIR/HarbourTask.h
|
||||||
|
|
||||||
|
HEADERS += \
|
||||||
|
$$HARBOUR_SRC_DIR/HarbourMce.h
|
||||||
|
|
||||||
|
SOURCES += \
|
||||||
|
$$HARBOUR_SRC_DIR/HarbourDisplayBlanking.cpp \
|
||||||
|
$$HARBOUR_SRC_DIR/HarbourJson.cpp \
|
||||||
|
$$HARBOUR_SRC_DIR/HarbourMce.cpp \
|
||||||
|
$$HARBOUR_SRC_DIR/HarbourPluginLoader.cpp \
|
||||||
|
$$HARBOUR_SRC_DIR/HarbourTask.cpp
|
||||||
|
|
||||||
# Icons
|
# Icons
|
||||||
ICON_SIZES = 86 108 128 256
|
ICON_SIZES = 86 108 128 256
|
||||||
for(s, ICON_SIZES) {
|
for(s, ICON_SIZES) {
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
/*
|
/*
|
||||||
Copyright (C) 2015-2018 Jolla Ltd.
|
Copyright (C) 2015-2019 Jolla Ltd.
|
||||||
Copyright (C) 2015-2018 Slava Monich <slava.monich@jolla.com>
|
Copyright (C) 2015-2019 Slava Monich <slava.monich@jolla.com>
|
||||||
|
|
||||||
You may use this file under the terms of BSD license as follows:
|
You may use this file under the terms of BSD license as follows:
|
||||||
|
|
||||||
|
@ -8,14 +8,15 @@
|
||||||
modification, are permitted provided that the following conditions
|
modification, are permitted provided that the following conditions
|
||||||
are met:
|
are met:
|
||||||
|
|
||||||
* Redistributions of source code must retain the above copyright
|
1. Redistributions of source code must retain the above copyright
|
||||||
notice, this list of conditions and the following disclaimer.
|
notice, this list of conditions and the following disclaimer.
|
||||||
* Redistributions in binary form must reproduce the above copyright
|
2. Redistributions in binary form must reproduce the above copyright
|
||||||
notice, this list of conditions and the following disclaimer in the
|
notice, this list of conditions and the following disclaimer
|
||||||
documentation and/or other materials provided with the distribution.
|
in the documentation and/or other materials provided with the
|
||||||
* Neither the name of Jolla Ltd nor the names of its contributors may
|
distribution.
|
||||||
be used to endorse or promote products derived from this software
|
3. Neither the names of the copyright holders nor the names of its
|
||||||
without specific prior written permission.
|
contributors may be used to endorse or promote products derived
|
||||||
|
from this software without specific prior written permission.
|
||||||
|
|
||||||
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
|
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
|
||||||
AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
||||||
|
@ -53,7 +54,6 @@ ApplicationWindow {
|
||||||
|
|
||||||
BooksHints { id: globalHints }
|
BooksHints { id: globalHints }
|
||||||
BooksFeedback { id: globalFeedback }
|
BooksFeedback { id: globalFeedback }
|
||||||
SystemState { id: globalSystemState }
|
|
||||||
DisplayBlanking {
|
DisplayBlanking {
|
||||||
pauseRequested: Qt.application.active &&
|
pauseRequested: Qt.application.active &&
|
||||||
Settings.currentBook &&
|
Settings.currentBook &&
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
/*
|
/*
|
||||||
Copyright (C) 2015-2018 Jolla Ltd.
|
Copyright (C) 2015-2019 Jolla Ltd.
|
||||||
Contact: Slava Monich <slava.monich@jolla.com>
|
Copyright (C) 2015-2019 Slava Monich <slava.monich@jolla.com>
|
||||||
|
|
||||||
You may use this file under the terms of BSD license as follows:
|
You may use this file under the terms of BSD license as follows:
|
||||||
|
|
||||||
|
@ -8,14 +8,15 @@
|
||||||
modification, are permitted provided that the following conditions
|
modification, are permitted provided that the following conditions
|
||||||
are met:
|
are met:
|
||||||
|
|
||||||
* Redistributions of source code must retain the above copyright
|
1. Redistributions of source code must retain the above copyright
|
||||||
notice, this list of conditions and the following disclaimer.
|
notice, this list of conditions and the following disclaimer.
|
||||||
* Redistributions in binary form must reproduce the above copyright
|
2. Redistributions in binary form must reproduce the above copyright
|
||||||
notice, this list of conditions and the following disclaimer in the
|
notice, this list of conditions and the following disclaimer
|
||||||
documentation and/or other materials provided with the distribution.
|
in the documentation and/or other materials provided with the
|
||||||
* Neither the name of Jolla Ltd nor the names of its contributors may
|
distribution.
|
||||||
be used to endorse or promote products derived from this software
|
3. Neither the names of the copyright holders nor the names of its
|
||||||
without specific prior written permission.
|
contributors may be used to endorse or promote products derived
|
||||||
|
from this software without specific prior written permission.
|
||||||
|
|
||||||
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
|
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
|
||||||
AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
||||||
|
@ -146,8 +147,8 @@ SilicaFlickable {
|
||||||
}
|
}
|
||||||
|
|
||||||
Connections {
|
Connections {
|
||||||
target: globalSystemState
|
target: Qt.application
|
||||||
onLockModeChanged: if (target.lockMode === globalSystemState.MCE_TK_LOCKED) editMode = false
|
onActiveChanged: if (!Qt.application.active) editMode = false
|
||||||
}
|
}
|
||||||
|
|
||||||
BookStorage {
|
BookStorage {
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
/*
|
/*
|
||||||
* Copyright (C) 2015-2018 Jolla Ltd.
|
* Copyright (C) 2015-2019 Jolla Ltd.
|
||||||
* Copyright (C) 2015-2018 Slava Monich <slava.monich@jolla.com>
|
* Copyright (C) 2015-2019 Slava Monich <slava.monich@jolla.com>
|
||||||
*
|
*
|
||||||
* You may use this file under the terms of the BSD license as follows:
|
* You may use this file under the terms of the BSD license as follows:
|
||||||
*
|
*
|
||||||
|
@ -8,15 +8,15 @@
|
||||||
* modification, are permitted provided that the following conditions
|
* modification, are permitted provided that the following conditions
|
||||||
* are met:
|
* are met:
|
||||||
*
|
*
|
||||||
* * Redistributions of source code must retain the above copyright
|
* 1. Redistributions of source code must retain the above copyright
|
||||||
* notice, this list of conditions and the following disclaimer.
|
* notice, this list of conditions and the following disclaimer.
|
||||||
* * Redistributions in binary form must reproduce the above copyright
|
* 2. Redistributions in binary form must reproduce the above copyright
|
||||||
* notice, this list of conditions and the following disclaimer in
|
* notice, this list of conditions and the following disclaimer
|
||||||
* the documentation and/or other materials provided with the
|
* in the documentation and/or other materials provided with the
|
||||||
* distribution.
|
* distribution.
|
||||||
* * Neither the name of Jolla Ltd nor the names of its contributors
|
* 3. Neither the names of the copyright holders nor the names of its
|
||||||
* may be used to endorse or promote products derived from this
|
* contributors may be used to endorse or promote products derived
|
||||||
* software without specific prior written permission.
|
* from this software without specific prior written permission.
|
||||||
*
|
*
|
||||||
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
|
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
|
||||||
* "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
|
* "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
|
||||||
|
@ -49,8 +49,8 @@
|
||||||
#include "BooksFeedback.h"
|
#include "BooksFeedback.h"
|
||||||
#include "BooksHints.h"
|
#include "BooksHints.h"
|
||||||
|
|
||||||
|
#include "HarbourDisplayBlanking.h"
|
||||||
#include "HarbourDebug.h"
|
#include "HarbourDebug.h"
|
||||||
#include "HarbourLib.h"
|
|
||||||
|
|
||||||
#include "ZLibrary.h"
|
#include "ZLibrary.h"
|
||||||
|
|
||||||
|
@ -86,8 +86,7 @@ Q_DECL_EXPORT int main(int argc, char **argv)
|
||||||
BOOKS_QML_REGISTER(BooksFeedback, "BooksFeedback");
|
BOOKS_QML_REGISTER(BooksFeedback, "BooksFeedback");
|
||||||
BOOKS_QML_REGISTER(BooksHints, "BooksHints");
|
BOOKS_QML_REGISTER(BooksHints, "BooksHints");
|
||||||
BOOKS_QML_REGISTER(BooksSettings, "BooksSettings");
|
BOOKS_QML_REGISTER(BooksSettings, "BooksSettings");
|
||||||
HarbourLib::registerTypes(BOOKS_QML_PLUGIN,
|
BOOKS_QML_REGISTER(HarbourDisplayBlanking, "DisplayBlanking");
|
||||||
BOOKS_QML_PLUGIN_V1, BOOKS_QML_PLUGIN_V2);
|
|
||||||
|
|
||||||
QLocale locale;
|
QLocale locale;
|
||||||
QTranslator* translator = new QTranslator(app);
|
QTranslator* translator = new QTranslator(app);
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
TEMPLATE = subdirs
|
TEMPLATE = subdirs
|
||||||
CONFIG += ordered
|
CONFIG += ordered
|
||||||
SUBDIRS = fribidi linebreak fbreader harbour-lib app
|
SUBDIRS = fribidi linebreak fbreader app
|
||||||
|
|
||||||
OTHER_FILES += \
|
OTHER_FILES += \
|
||||||
README.md \
|
README.md \
|
||||||
|
|
Loading…
Reference in a new issue