diff --git a/QtGui.cpp b/QtGui.cpp index 5c37494..b565b54 100644 --- a/QtGui.cpp +++ b/QtGui.cpp @@ -191,7 +191,9 @@ static int pluginStart() { plugin.plugin.message = pluginMessage_wrapper; startWidgets(); - startQuick(); + + if (!USE_WIDGETS || DBAPI->conf_get_int("qgui.show_qtquick_window", false)) + startQuick(); // GUI thread loop app->exec(); diff --git a/dbapi/actions/ActionsConfig.cpp b/dbapi/actions/ActionsConfig.cpp index 57a1ca4..0d784ff 100644 --- a/dbapi/actions/ActionsConfig.cpp +++ b/dbapi/actions/ActionsConfig.cpp @@ -243,6 +243,16 @@ ActionsConfig::ActionsConfig(QObject *parent, DBApi *Api) m_actions.append(action); } + ActionSpec quick = { + .path = QStringList{"View", "Qt Quick Window (requires restart)"}, + .id = "q_qtquick_window", + .loc = DBAction::ACTION_LOC_HOTKEY | DBAction::ACTION_LOC_MENUBAR, + .arg = DBAction::ACTION_ARG_NONE, + .props = QHash{{"config_default", QVariant(false)}, {"config", QVariant(QString("qgui.show_qtquick_window"))}} + }; + DBActionConfigBool *quick_action = new DBActionConfigBool(this, Api, quick); + m_actions.append(quick_action); + } ActionsConfig::~ActionsConfig() {