mirror of
https://invent.kde.org/network/falkon.git
synced 2024-12-20 10:46:35 +01:00
Installing also plugins into /usr/lib/qupzilla/ on Linux.
This commit is contained in:
parent
ef4fef4699
commit
48112e0576
@ -4,8 +4,11 @@ mac {
|
|||||||
|
|
||||||
bundle_target.files += $$PWD/bin/locale
|
bundle_target.files += $$PWD/bin/locale
|
||||||
bundle_target.files += $$PWD/bin/themes
|
bundle_target.files += $$PWD/bin/themes
|
||||||
|
bundle_target.files += $$PWD/bin/plugins
|
||||||
bundle_target.path = Contents/Resources
|
bundle_target.path = Contents/Resources
|
||||||
|
|
||||||
|
bundle_target2.files += $$PWD/bin/
|
||||||
|
|
||||||
QMAKE_BUNDLE_DATA += bundle_target
|
QMAKE_BUNDLE_DATA += bundle_target
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -32,6 +35,9 @@ mac {
|
|||||||
targetlib.files = $$PWD/bin/libqupzilla*
|
targetlib.files = $$PWD/bin/libqupzilla*
|
||||||
targetlib.path = $$library_folder
|
targetlib.path = $$library_folder
|
||||||
|
|
||||||
|
targetplugins.files = $$PWD/bin/plugins/*.so
|
||||||
|
targetplugins.path = "$$library_folder"/qupzilla/
|
||||||
|
|
||||||
target1.files += $$PWD/bin/locale
|
target1.files += $$PWD/bin/locale
|
||||||
target1.files += $$PWD/bin/themes
|
target1.files += $$PWD/bin/themes
|
||||||
target1.path = $$data_folder
|
target1.path = $$data_folder
|
||||||
@ -60,6 +66,6 @@ mac {
|
|||||||
ico256.files = $$PWD/linux/hicolor/256x256/apps/qupzilla.png
|
ico256.files = $$PWD/linux/hicolor/256x256/apps/qupzilla.png
|
||||||
ico256.path = $$hicolor_folder/256x256/apps
|
ico256.path = $$hicolor_folder/256x256/apps
|
||||||
|
|
||||||
INSTALLS += target targetlib target1 target2 target3
|
INSTALLS += target targetlib targetplugins target1 target2 target3
|
||||||
INSTALLS += ico16 ico32 ico48 ico64 ico128 ico256
|
INSTALLS += ico16 ico32 ico48 ico64 ico128 ico256
|
||||||
}
|
}
|
||||||
|
@ -8,6 +8,14 @@ TARGET = ExamplePlugin
|
|||||||
|
|
||||||
SOURCES += testplugin.cpp
|
SOURCES += testplugin.cpp
|
||||||
HEADERS += testplugin.h
|
HEADERS += testplugin.h
|
||||||
RESOURCES += data.qrc
|
RESOURCES += \
|
||||||
|
testplugin.qrc
|
||||||
|
|
||||||
|
TRANSLATIONS += cs_CZ.ts\
|
||||||
|
sk_SK.ts\
|
||||||
|
sr_BA.ts\
|
||||||
|
sr_RS.ts\
|
||||||
|
de_DE.ts\
|
||||||
|
el_GR.ts\
|
||||||
|
|
||||||
include(../../plugins.pri)
|
include(../../plugins.pri)
|
||||||
|
Binary file not shown.
@ -4,34 +4,27 @@
|
|||||||
<context>
|
<context>
|
||||||
<name>TestPlugin</name>
|
<name>TestPlugin</name>
|
||||||
<message>
|
<message>
|
||||||
<location filename="testplugin.h" line="24"/>
|
|
||||||
<source>Example Plugin</source>
|
|
||||||
<translation>Příkladový doplněk</translation>
|
|
||||||
</message>
|
|
||||||
<message>
|
|
||||||
<location filename="testplugin.h" line="25"/>
|
|
||||||
<source>Example minimal plugin</source>
|
|
||||||
<translation>Ukázkový minimální doplněk</translation>
|
|
||||||
</message>
|
|
||||||
<message>
|
|
||||||
<location filename="testplugin.h" line="26"/>
|
|
||||||
<source>Very simple minimal plugin example</source>
|
|
||||||
<translation>Velice jednoduchý minimální doplněk</translation>
|
|
||||||
</message>
|
|
||||||
<message>
|
|
||||||
<location filename="testplugin.cpp" line="49"/>
|
|
||||||
<location filename="testplugin.cpp" line="54"/>
|
|
||||||
<location filename="testplugin.cpp" line="59"/>
|
<location filename="testplugin.cpp" line="59"/>
|
||||||
|
<source>Close</source>
|
||||||
|
<translation>Zavřít</translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<location filename="testplugin.cpp" line="70"/>
|
||||||
|
<source>Example Plugin Settings</source>
|
||||||
|
<translation>Nastavení ukázkového doplňku</translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<location filename="testplugin.cpp" line="95"/>
|
||||||
<source>My first plugin action</source>
|
<source>My first plugin action</source>
|
||||||
<translation>Moje první akce z doplňku</translation>
|
<translation>Moje první akce z doplňku</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="testplugin.cpp" line="64"/>
|
<location filename="testplugin.cpp" line="100"/>
|
||||||
<source>Hello</source>
|
<source>Hello</source>
|
||||||
<translation>Ahoj</translation>
|
<translation>Ahoj</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="testplugin.cpp" line="64"/>
|
<location filename="testplugin.cpp" line="100"/>
|
||||||
<source>First plugin action works :-)</source>
|
<source>First plugin action works :-)</source>
|
||||||
<translation>První akce funguje :-)</translation>
|
<translation>První akce funguje :-)</translation>
|
||||||
</message>
|
</message>
|
||||||
|
@ -4,34 +4,27 @@
|
|||||||
<context>
|
<context>
|
||||||
<name>TestPlugin</name>
|
<name>TestPlugin</name>
|
||||||
<message>
|
<message>
|
||||||
<location filename="testplugin.h" line="24"/>
|
|
||||||
<source>Example Plugin</source>
|
|
||||||
<translation>Beispiel-Plugin</translation>
|
|
||||||
</message>
|
|
||||||
<message>
|
|
||||||
<location filename="testplugin.h" line="25"/>
|
|
||||||
<source>Example minimal plugin</source>
|
|
||||||
<translation>Einfaches Beispiel-Plugin</translation>
|
|
||||||
</message>
|
|
||||||
<message>
|
|
||||||
<location filename="testplugin.h" line="26"/>
|
|
||||||
<source>Very simple minimal plugin example</source>
|
|
||||||
<translation>Sehr einfaches Beispiel-Plugin</translation>
|
|
||||||
</message>
|
|
||||||
<message>
|
|
||||||
<location filename="testplugin.cpp" line="49"/>
|
|
||||||
<location filename="testplugin.cpp" line="54"/>
|
|
||||||
<location filename="testplugin.cpp" line="59"/>
|
<location filename="testplugin.cpp" line="59"/>
|
||||||
|
<source>Close</source>
|
||||||
|
<translation type="unfinished"></translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<location filename="testplugin.cpp" line="70"/>
|
||||||
|
<source>Example Plugin Settings</source>
|
||||||
|
<translation type="unfinished"></translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<location filename="testplugin.cpp" line="95"/>
|
||||||
<source>My first plugin action</source>
|
<source>My first plugin action</source>
|
||||||
<translation>Meine erste Aktion</translation>
|
<translation>Meine erste Aktion</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="testplugin.cpp" line="64"/>
|
<location filename="testplugin.cpp" line="100"/>
|
||||||
<source>Hello</source>
|
<source>Hello</source>
|
||||||
<translation>Hallo</translation>
|
<translation>Hallo</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="testplugin.cpp" line="64"/>
|
<location filename="testplugin.cpp" line="100"/>
|
||||||
<source>First plugin action works :-)</source>
|
<source>First plugin action works :-)</source>
|
||||||
<translation>Meine erste Aktion funktioniert :-)</translation>
|
<translation>Meine erste Aktion funktioniert :-)</translation>
|
||||||
</message>
|
</message>
|
||||||
|
@ -4,34 +4,27 @@
|
|||||||
<context>
|
<context>
|
||||||
<name>TestPlugin</name>
|
<name>TestPlugin</name>
|
||||||
<message>
|
<message>
|
||||||
<location filename="testplugin.h" line="24"/>
|
|
||||||
<source>Example Plugin</source>
|
|
||||||
<translation>Παράδειγμα προσθέτου</translation>
|
|
||||||
</message>
|
|
||||||
<message>
|
|
||||||
<location filename="testplugin.h" line="25"/>
|
|
||||||
<source>Example minimal plugin</source>
|
|
||||||
<translation>Παράδειγμα απλού προσθέτου</translation>
|
|
||||||
</message>
|
|
||||||
<message>
|
|
||||||
<location filename="testplugin.h" line="26"/>
|
|
||||||
<source>Very simple minimal plugin example</source>
|
|
||||||
<translation>Πολύ απλό παράδειγμα απλού προσθέτου</translation>
|
|
||||||
</message>
|
|
||||||
<message>
|
|
||||||
<location filename="testplugin.cpp" line="49"/>
|
|
||||||
<location filename="testplugin.cpp" line="54"/>
|
|
||||||
<location filename="testplugin.cpp" line="59"/>
|
<location filename="testplugin.cpp" line="59"/>
|
||||||
|
<source>Close</source>
|
||||||
|
<translation type="unfinished"></translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<location filename="testplugin.cpp" line="70"/>
|
||||||
|
<source>Example Plugin Settings</source>
|
||||||
|
<translation type="unfinished"></translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<location filename="testplugin.cpp" line="95"/>
|
||||||
<source>My first plugin action</source>
|
<source>My first plugin action</source>
|
||||||
<translation>Η ενέργεια του πρώτου μου προσθέτου</translation>
|
<translation>Η ενέργεια του πρώτου μου προσθέτου</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="testplugin.cpp" line="64"/>
|
<location filename="testplugin.cpp" line="100"/>
|
||||||
<source>Hello</source>
|
<source>Hello</source>
|
||||||
<translation>Γεια</translation>
|
<translation>Γεια</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="testplugin.cpp" line="64"/>
|
<location filename="testplugin.cpp" line="100"/>
|
||||||
<source>First plugin action works :-)</source>
|
<source>First plugin action works :-)</source>
|
||||||
<translation>Η ενέργεια του πρώτου προσθέτου δουλεύει :-)</translation>
|
<translation>Η ενέργεια του πρώτου προσθέτου δουλεύει :-)</translation>
|
||||||
</message>
|
</message>
|
||||||
|
@ -4,34 +4,27 @@
|
|||||||
<context>
|
<context>
|
||||||
<name>TestPlugin</name>
|
<name>TestPlugin</name>
|
||||||
<message>
|
<message>
|
||||||
<location filename="testplugin.h" line="24"/>
|
|
||||||
<source>Example Plugin</source>
|
|
||||||
<translation>Ukázkovy doplnek</translation>
|
|
||||||
</message>
|
|
||||||
<message>
|
|
||||||
<location filename="testplugin.h" line="25"/>
|
|
||||||
<source>Example minimal plugin</source>
|
|
||||||
<translation>Ukázkovy minimálny doplnek</translation>
|
|
||||||
</message>
|
|
||||||
<message>
|
|
||||||
<location filename="testplugin.h" line="26"/>
|
|
||||||
<source>Very simple minimal plugin example</source>
|
|
||||||
<translation>Vel'mi jednoduchy minimálny doplnek</translation>
|
|
||||||
</message>
|
|
||||||
<message>
|
|
||||||
<location filename="testplugin.cpp" line="49"/>
|
|
||||||
<location filename="testplugin.cpp" line="54"/>
|
|
||||||
<location filename="testplugin.cpp" line="59"/>
|
<location filename="testplugin.cpp" line="59"/>
|
||||||
|
<source>Close</source>
|
||||||
|
<translation type="unfinished"></translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<location filename="testplugin.cpp" line="70"/>
|
||||||
|
<source>Example Plugin Settings</source>
|
||||||
|
<translation type="unfinished"></translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<location filename="testplugin.cpp" line="95"/>
|
||||||
<source>My first plugin action</source>
|
<source>My first plugin action</source>
|
||||||
<translation>Moje první akce z doplnku</translation>
|
<translation>Moje první akce z doplnku</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="testplugin.cpp" line="64"/>
|
<location filename="testplugin.cpp" line="100"/>
|
||||||
<source>Hello</source>
|
<source>Hello</source>
|
||||||
<translation>Ahoj</translation>
|
<translation>Ahoj</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="testplugin.cpp" line="64"/>
|
<location filename="testplugin.cpp" line="100"/>
|
||||||
<source>First plugin action works :-)</source>
|
<source>First plugin action works :-)</source>
|
||||||
<translation>První doplnek funguje :-)</translation>
|
<translation>První doplnek funguje :-)</translation>
|
||||||
</message>
|
</message>
|
||||||
|
@ -4,34 +4,27 @@
|
|||||||
<context>
|
<context>
|
||||||
<name>TestPlugin</name>
|
<name>TestPlugin</name>
|
||||||
<message>
|
<message>
|
||||||
<location filename="testplugin.h" line="24"/>
|
<location filename="testplugin.cpp" line="59"/>
|
||||||
<source>Example Plugin</source>
|
<source>Close</source>
|
||||||
<translation>Примjер прикључaк</translation>
|
<translation type="unfinished"></translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="testplugin.h" line="25"/>
|
<location filename="testplugin.cpp" line="70"/>
|
||||||
<source>Example minimal plugin</source>
|
<source>Example Plugin Settings</source>
|
||||||
<translation>Примјер минималног прикључка</translation>
|
<translation type="unfinished"></translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="testplugin.h" line="26"/>
|
<location filename="testplugin.cpp" line="95"/>
|
||||||
<source>Very simple minimal plugin example</source>
|
|
||||||
<translation>Веома једноставан примјер прикључка</translation>
|
|
||||||
</message>
|
|
||||||
<message>
|
|
||||||
<location filename="testplugin.cpp" line="52"/>
|
|
||||||
<location filename="testplugin.cpp" line="57"/>
|
|
||||||
<location filename="testplugin.cpp" line="62"/>
|
|
||||||
<source>My first plugin action</source>
|
<source>My first plugin action</source>
|
||||||
<translation>Моја прва радња прикључка</translation>
|
<translation>Моја прва радња прикључка</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="testplugin.cpp" line="67"/>
|
<location filename="testplugin.cpp" line="100"/>
|
||||||
<source>Hello</source>
|
<source>Hello</source>
|
||||||
<translation>Здраво</translation>
|
<translation>Здраво</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="testplugin.cpp" line="67"/>
|
<location filename="testplugin.cpp" line="100"/>
|
||||||
<source>First plugin action works :-)</source>
|
<source>First plugin action works :-)</source>
|
||||||
<translation>Прва радња прикључка ради :-)</translation>
|
<translation>Прва радња прикључка ради :-)</translation>
|
||||||
</message>
|
</message>
|
||||||
|
@ -4,34 +4,27 @@
|
|||||||
<context>
|
<context>
|
||||||
<name>TestPlugin</name>
|
<name>TestPlugin</name>
|
||||||
<message>
|
<message>
|
||||||
<location filename="testplugin.h" line="24"/>
|
<location filename="testplugin.cpp" line="59"/>
|
||||||
<source>Example Plugin</source>
|
<source>Close</source>
|
||||||
<translation>Пример прикључaк</translation>
|
<translation type="unfinished"></translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="testplugin.h" line="25"/>
|
<location filename="testplugin.cpp" line="70"/>
|
||||||
<source>Example minimal plugin</source>
|
<source>Example Plugin Settings</source>
|
||||||
<translation>Пример минималног прикључка</translation>
|
<translation type="unfinished"></translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="testplugin.h" line="26"/>
|
<location filename="testplugin.cpp" line="95"/>
|
||||||
<source>Very simple minimal plugin example</source>
|
|
||||||
<translation>Веома једноставан пример прикључка</translation>
|
|
||||||
</message>
|
|
||||||
<message>
|
|
||||||
<location filename="testplugin.cpp" line="52"/>
|
|
||||||
<location filename="testplugin.cpp" line="57"/>
|
|
||||||
<location filename="testplugin.cpp" line="62"/>
|
|
||||||
<source>My first plugin action</source>
|
<source>My first plugin action</source>
|
||||||
<translation>Моја прва радња прикључка</translation>
|
<translation>Моја прва радња прикључка</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="testplugin.cpp" line="67"/>
|
<location filename="testplugin.cpp" line="100"/>
|
||||||
<source>Hello</source>
|
<source>Hello</source>
|
||||||
<translation>Здраво</translation>
|
<translation>Здраво</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="testplugin.cpp" line="67"/>
|
<location filename="testplugin.cpp" line="100"/>
|
||||||
<source>First plugin action works :-)</source>
|
<source>First plugin action works :-)</source>
|
||||||
<translation>Прва радња прикључка ради :-)</translation>
|
<translation>Прва радња прикључка ради :-)</translation>
|
||||||
</message>
|
</message>
|
||||||
|
@ -5,9 +5,9 @@
|
|||||||
PluginSpec TestPlugin::pluginSpec()
|
PluginSpec TestPlugin::pluginSpec()
|
||||||
{
|
{
|
||||||
PluginSpec spec;
|
PluginSpec spec;
|
||||||
spec.name = tr("Example Plugin");
|
spec.name = "Example Plugin";
|
||||||
spec.info = tr("Example minimal plugin");
|
spec.info = "Example minimal plugin";
|
||||||
spec.description = tr("Very simple minimal plugin example");
|
spec.description = "Very simple minimal plugin example";
|
||||||
spec.version = "0.0.1";
|
spec.version = "0.0.1";
|
||||||
spec.author = "David Rosca <nowrep@gmail.com>";
|
spec.author = "David Rosca <nowrep@gmail.com>";
|
||||||
spec.icon = QIcon(":qupzilla.png");
|
spec.icon = QIcon(":qupzilla.png");
|
||||||
@ -48,7 +48,7 @@ bool TestPlugin::testPlugin()
|
|||||||
QTranslator* TestPlugin::getTranslator(const QString &locale)
|
QTranslator* TestPlugin::getTranslator(const QString &locale)
|
||||||
{
|
{
|
||||||
QTranslator* translator = new QTranslator();
|
QTranslator* translator = new QTranslator();
|
||||||
translator->load(":/" + locale);
|
translator->load(":/testplugin/" + locale);
|
||||||
return translator;
|
return translator;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -56,15 +56,20 @@ void TestPlugin::showSettings(QWidget *parent)
|
|||||||
{
|
{
|
||||||
QDialog* dialog = new QDialog(parent);
|
QDialog* dialog = new QDialog(parent);
|
||||||
QPushButton* b = new QPushButton("Example Plugin v0.0.1");
|
QPushButton* b = new QPushButton("Example Plugin v0.0.1");
|
||||||
|
QPushButton* closeButton = new QPushButton(tr("Close"));
|
||||||
|
QLabel* label = new QLabel();
|
||||||
|
label->setPixmap(QPixmap(":icons/other/about.png"));
|
||||||
|
|
||||||
QHBoxLayout* l = new QHBoxLayout(dialog);
|
QVBoxLayout* l = new QVBoxLayout(dialog);
|
||||||
|
l->addWidget(label);
|
||||||
l->addWidget(b);
|
l->addWidget(b);
|
||||||
|
l->addWidget(closeButton);
|
||||||
dialog->setLayout(l);
|
dialog->setLayout(l);
|
||||||
|
|
||||||
dialog->resize(200, 200);
|
|
||||||
dialog->setAttribute(Qt::WA_DeleteOnClose);
|
dialog->setAttribute(Qt::WA_DeleteOnClose);
|
||||||
dialog->setWindowTitle("Example Plugin Settings");
|
dialog->setWindowTitle(tr("Example Plugin Settings"));
|
||||||
dialog->setWindowIcon(QIcon(":/qupzilla.png"));
|
dialog->setWindowIcon(QIcon(":qupzilla.png"));
|
||||||
|
connect(closeButton, SIGNAL(clicked()), dialog, SLOT(close()));
|
||||||
|
|
||||||
dialog->show();
|
dialog->show();
|
||||||
}
|
}
|
||||||
|
@ -13,7 +13,7 @@
|
|||||||
#include <QLabel>
|
#include <QLabel>
|
||||||
#include <QMessageBox>
|
#include <QMessageBox>
|
||||||
#include <QWebElement>
|
#include <QWebElement>
|
||||||
#include <QHBoxLayout>
|
#include <QVBoxLayout>
|
||||||
|
|
||||||
class TestPlugin : public QObject, public PluginInterface
|
class TestPlugin : public QObject, public PluginInterface
|
||||||
{
|
{
|
||||||
|
@ -1,10 +1,10 @@
|
|||||||
<RCC>
|
<RCC>
|
||||||
<qresource prefix="/">
|
<qresource prefix="/testplugin">
|
||||||
<file>cs_CZ.qm</file>
|
<file>cs_CZ.qm</file>
|
||||||
<file>sk_SK.qm</file>
|
<file>sk_SK.qm</file>
|
||||||
<file>sr_BA.qm</file>
|
<file>sr_BA.qm</file>
|
||||||
<file>sr_RS.qm</file>
|
<file>sr_RS.qm</file>
|
||||||
<file>de_DE.qm</file>
|
<file>de_DE.qm</file>
|
||||||
<file>el_GR.qm</file>
|
<file>el_GR.qm</file>
|
||||||
</qresource>
|
</qresource>
|
||||||
</RCC>
|
</RCC>
|
@ -1,8 +1,6 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
|
|
||||||
lupdate ../plugins/TestPlugin/TestPlugin.pro -no-obsolete -ts ../plugins/TestPlugin/cs_CZ.ts
|
lupdate ../plugins/TestPlugin/TestPlugin.pro -no-obsolete
|
||||||
|
|
||||||
lupdate ../plugins/TestPlugin/TestPlugin.pro -no-obsolete -ts ../plugins/TestPlugin/sk_SK.ts
|
|
||||||
|
|
||||||
read -p "Press [ENTER] to close terminal"
|
read -p "Press [ENTER] to close terminal"
|
||||||
exit
|
exit
|
||||||
|
@ -110,7 +110,6 @@ MainApplication::MainApplication(const QList<CommandLineOptions::ActionPair> &cm
|
|||||||
PROFILEDIR = QDir::homePath() + "/.qupzilla/";
|
PROFILEDIR = QDir::homePath() + "/.qupzilla/";
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
PLUGINSDIR = DATADIR + "plugins/";
|
|
||||||
TRANSLATIONSDIR = DATADIR + "locale/";
|
TRANSLATIONSDIR = DATADIR + "locale/";
|
||||||
THEMESDIR = DATADIR + "themes/";
|
THEMESDIR = DATADIR + "themes/";
|
||||||
|
|
||||||
|
@ -60,7 +60,6 @@ class MainApplication : public QtSingleApplication
|
|||||||
public:
|
public:
|
||||||
QString DATADIR;
|
QString DATADIR;
|
||||||
QString PROFILEDIR;
|
QString PROFILEDIR;
|
||||||
QString PLUGINSDIR;
|
|
||||||
QString TRANSLATIONSDIR;
|
QString TRANSLATIONSDIR;
|
||||||
QString THEMESDIR;
|
QString THEMESDIR;
|
||||||
|
|
||||||
|
@ -310,7 +310,6 @@ QString QupZillaSchemeReply::configPage()
|
|||||||
QString("<dt>%1</dt><dd>%2<dd>").arg(tr("Pinned tabs"), mApp->getActiveProfilPath() + "pinnedtabs.dat") +
|
QString("<dt>%1</dt><dd>%2<dd>").arg(tr("Pinned tabs"), mApp->getActiveProfilPath() + "pinnedtabs.dat") +
|
||||||
QString("<dt>%1</dt><dd>%2<dd>").arg(tr("Data"), mApp->DATADIR) +
|
QString("<dt>%1</dt><dd>%2<dd>").arg(tr("Data"), mApp->DATADIR) +
|
||||||
QString("<dt>%1</dt><dd>%2<dd>").arg(tr("Themes"), mApp->THEMESDIR) +
|
QString("<dt>%1</dt><dd>%2<dd>").arg(tr("Themes"), mApp->THEMESDIR) +
|
||||||
QString("<dt>%1</dt><dd>%2<dd>").arg(tr("Plugins"), mApp->PLUGINSDIR) +
|
|
||||||
QString("<dt>%1</dt><dd>%2<dd>").arg(tr("Translations"), mApp->TRANSLATIONSDIR));
|
QString("<dt>%1</dt><dd>%2<dd>").arg(tr("Translations"), mApp->TRANSLATIONSDIR));
|
||||||
|
|
||||||
cPage.replace("%USER-AGENT%", mApp->getWindow()->weView()->webPage()->userAgentForUrl(QUrl()));
|
cPage.replace("%USER-AGENT%", mApp->getWindow()->weView()->webPage()->userAgentForUrl(QUrl()));
|
||||||
|
@ -52,7 +52,7 @@ void Plugins::loadPlugin(Plugins::Plugin* plugin)
|
|||||||
refreshLoadedPlugins();
|
refreshLoadedPlugins();
|
||||||
}
|
}
|
||||||
|
|
||||||
void Plugins::unloadPlugin(Plugins::Plugin *plugin)
|
void Plugins::unloadPlugin(Plugins::Plugin* plugin)
|
||||||
{
|
{
|
||||||
if (!plugin->isLoaded()) {
|
if (!plugin->isLoaded()) {
|
||||||
return;
|
return;
|
||||||
@ -86,7 +86,7 @@ void Plugins::loadPlugins()
|
|||||||
m_pluginsLoaded = true;
|
m_pluginsLoaded = true;
|
||||||
|
|
||||||
QStringList dirs;
|
QStringList dirs;
|
||||||
dirs << mApp->PLUGINSDIR
|
dirs << mApp->DATADIR + "plugins/"
|
||||||
#ifdef Q_WS_X11
|
#ifdef Q_WS_X11
|
||||||
<< "/usr/lib/qupzilla/"
|
<< "/usr/lib/qupzilla/"
|
||||||
#endif
|
#endif
|
||||||
@ -146,7 +146,7 @@ void Plugins::refreshLoadedPlugins()
|
|||||||
{
|
{
|
||||||
m_loadedPlugins.clear();
|
m_loadedPlugins.clear();
|
||||||
|
|
||||||
foreach(const Plugin &plugin, m_availablePlugins) {
|
foreach(const Plugin & plugin, m_availablePlugins) {
|
||||||
if (plugin.isLoaded()) {
|
if (plugin.isLoaded()) {
|
||||||
m_loadedPlugins.append(plugin.instance);
|
m_loadedPlugins.append(plugin.instance);
|
||||||
}
|
}
|
||||||
|
@ -55,7 +55,7 @@ public:
|
|||||||
QList<Plugin> getAvailablePlugins() { return m_availablePlugins; }
|
QList<Plugin> getAvailablePlugins() { return m_availablePlugins; }
|
||||||
|
|
||||||
void loadPlugin(Plugin* plugin);
|
void loadPlugin(Plugin* plugin);
|
||||||
void unloadPlugin(Plugin *plugin);
|
void unloadPlugin(Plugin* plugin);
|
||||||
|
|
||||||
public slots:
|
public slots:
|
||||||
void loadSettings();
|
void loadSettings();
|
||||||
|
@ -183,7 +183,7 @@ void PluginsList::currentChanged(QListWidgetItem* item)
|
|||||||
ui->butSettings->setEnabled(showSettings);
|
ui->butSettings->setEnabled(showSettings);
|
||||||
}
|
}
|
||||||
|
|
||||||
void PluginsList::itemChanged(QListWidgetItem *item)
|
void PluginsList::itemChanged(QListWidgetItem* item)
|
||||||
{
|
{
|
||||||
if (!item) {
|
if (!item) {
|
||||||
return;
|
return;
|
||||||
|
@ -906,7 +906,7 @@ bool WebView::eventFilter(QObject* obj, QEvent* event)
|
|||||||
QTouchEvent::TouchPoint touchPoint;
|
QTouchEvent::TouchPoint touchPoint;
|
||||||
touchPoint.setState(Qt::TouchPointMoved);
|
touchPoint.setState(Qt::TouchPointMoved);
|
||||||
if ((ev->type() == QEvent::MouseButtonPress
|
if ((ev->type() == QEvent::MouseButtonPress
|
||||||
|| ev->type() == QEvent::MouseButtonDblClick)) {
|
|| ev->type() == QEvent::MouseButtonDblClick)) {
|
||||||
touchPoint.setState(Qt::TouchPointPressed);
|
touchPoint.setState(Qt::TouchPointPressed);
|
||||||
}
|
}
|
||||||
else if (ev->type() == QEvent::MouseButtonRelease) {
|
else if (ev->type() == QEvent::MouseButtonRelease) {
|
||||||
|
Loading…
Reference in New Issue
Block a user