Add app widget plugin.
This commit is contained in:
parent
796d13252d
commit
d00912d546
|
@ -89,6 +89,12 @@ MainWindow::MainWindow(QWidget *parent) :
|
||||||
// }
|
// }
|
||||||
// });
|
// });
|
||||||
|
|
||||||
|
m_appWidgetPlugin = new AppWidgetPlugin;
|
||||||
|
|
||||||
|
connect(m_appWidgetPlugin, &AppWidgetPlugin::startSearch, this, [ & ] (QString keyword){
|
||||||
|
this->bootOptionsFilter("-s");
|
||||||
|
this->setText(keyword);
|
||||||
|
});
|
||||||
//NEW_TODO, register plugins
|
//NEW_TODO, register plugins
|
||||||
// SearchPluginManager::getInstance()->registerPlugin(\\);
|
// SearchPluginManager::getInstance()->registerPlugin(\\);
|
||||||
// m_stackedWidget->setPlugins(SearchPluginManager::getInstance()->getPluginIds());
|
// m_stackedWidget->setPlugins(SearchPluginManager::getInstance()->getPluginIds());
|
||||||
|
|
|
@ -46,6 +46,7 @@
|
||||||
#include <QSystemTrayIcon>
|
#include <QSystemTrayIcon>
|
||||||
#include <QTimer>
|
#include <QTimer>
|
||||||
|
|
||||||
|
#include "search-app-widget-plugin/search.h"
|
||||||
#include "index-generator.h"
|
#include "index-generator.h"
|
||||||
#include "libsearch.h"
|
#include "libsearch.h"
|
||||||
#include "create-index-ask-dialog.h"
|
#include "create-index-ask-dialog.h"
|
||||||
|
@ -143,6 +144,7 @@ private:
|
||||||
QTimer * m_researchTimer = nullptr; //创建索引后重新执行一次搜索的计时器
|
QTimer * m_researchTimer = nullptr; //创建索引后重新执行一次搜索的计时器
|
||||||
bool m_currentSearchAsked = false; //本次搜索是否已经询问过是否创建索引了
|
bool m_currentSearchAsked = false; //本次搜索是否已经询问过是否创建索引了
|
||||||
QGSettings * m_search_gsettings = nullptr;
|
QGSettings * m_search_gsettings = nullptr;
|
||||||
|
AppWidgetPlugin *m_appWidgetPlugin = nullptr;
|
||||||
|
|
||||||
void setSearchMethod(const bool&);
|
void setSearchMethod(const bool&);
|
||||||
double getTransparentData();
|
double getTransparentData();
|
||||||
|
|
|
@ -70,6 +70,7 @@ GlobalSettings::GlobalSettings(QObject *parent) : QObject(parent) {
|
||||||
m_cache.remove(TRANSPARENCY_KEY);
|
m_cache.remove(TRANSPARENCY_KEY);
|
||||||
m_cache.insert(TRANSPARENCY_KEY, m_trans_gsettings->get(TRANSPARENCY_KEY).toDouble());
|
m_cache.insert(TRANSPARENCY_KEY, m_trans_gsettings->get(TRANSPARENCY_KEY).toDouble());
|
||||||
qApp->paletteChanged(qApp->palette());
|
qApp->paletteChanged(qApp->palette());
|
||||||
|
Q_EMIT this->transparencyChanged(m_trans_gsettings->get(TRANSPARENCY_KEY).toDouble());
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
m_cache.remove(TRANSPARENCY_KEY);
|
m_cache.remove(TRANSPARENCY_KEY);
|
||||||
|
@ -86,6 +87,7 @@ GlobalSettings::GlobalSettings(QObject *parent) : QObject(parent) {
|
||||||
m_cache.remove(STYLE_NAME_KEY);
|
m_cache.remove(STYLE_NAME_KEY);
|
||||||
m_cache.insert(STYLE_NAME_KEY, m_theme_gsettings->get(STYLE_NAME_KEY).toString());
|
m_cache.insert(STYLE_NAME_KEY, m_theme_gsettings->get(STYLE_NAME_KEY).toString());
|
||||||
qApp->paletteChanged(qApp->palette());
|
qApp->paletteChanged(qApp->palette());
|
||||||
|
Q_EMIT this->styleChanged(m_theme_gsettings->get(STYLE_NAME_KEY).toString());
|
||||||
} else if(key == FONT_SIZE_KEY) {
|
} else if(key == FONT_SIZE_KEY) {
|
||||||
m_cache.remove(FONT_SIZE_KEY);
|
m_cache.remove(FONT_SIZE_KEY);
|
||||||
m_cache.insert(FONT_SIZE_KEY, m_theme_gsettings->get(FONT_SIZE_KEY).toDouble());
|
m_cache.insert(FONT_SIZE_KEY, m_theme_gsettings->get(FONT_SIZE_KEY).toDouble());
|
||||||
|
|
|
@ -68,6 +68,7 @@ public:
|
||||||
Q_SIGNALS:
|
Q_SIGNALS:
|
||||||
void valueChanged(const QString&);
|
void valueChanged(const QString&);
|
||||||
void transparencyChanged(const double&);
|
void transparencyChanged(const double&);
|
||||||
|
void styleChanged(const QString&);
|
||||||
|
|
||||||
public Q_SLOTS:
|
public Q_SLOTS:
|
||||||
void setValue(const QString&, const QVariant&);
|
void setValue(const QString&, const QVariant&);
|
||||||
|
|
|
@ -40,9 +40,11 @@ include(websearch/websearch.pri)
|
||||||
include(searchinterface/search-interface.pri)
|
include(searchinterface/search-interface.pri)
|
||||||
include(dirwatcher/dirwatcher.pri)
|
include(dirwatcher/dirwatcher.pri)
|
||||||
include(mailsearch/mailsearch.pri)
|
include(mailsearch/mailsearch.pri)
|
||||||
|
include(search-app-widget-plugin/search-app-widget-plugin.pri)
|
||||||
|
|
||||||
LIBS += -L$$OUT_PWD/../libchinese-segmentation/ -lchinese-segmentation
|
LIBS += -L$$OUT_PWD/../libchinese-segmentation/ -lchinese-segmentation
|
||||||
LIBS += -lxapian -luchardet -lQt5Xdg -lquazip5 -ltesseract #-L/usr/local/lib/libjemalloc -ljemalloc
|
LIBS += -lxapian -luchardet -lQt5Xdg -lquazip5 -ltesseract #-L/usr/local/lib/libjemalloc -ljemalloc
|
||||||
|
LIBS += -lukui-appwidget-manager -lukui-appwidget-provider
|
||||||
|
|
||||||
SOURCES += \
|
SOURCES += \
|
||||||
file-utils.cpp \
|
file-utils.cpp \
|
||||||
|
@ -62,6 +64,7 @@ HEADERS += \
|
||||||
|
|
||||||
RESOURCES += \
|
RESOURCES += \
|
||||||
resource1.qrc \
|
resource1.qrc \
|
||||||
|
search-app-widget-plugin/provider/src.qrc
|
||||||
|
|
||||||
TRANSLATIONS += \
|
TRANSLATIONS += \
|
||||||
../translations/libukui-search/libukui-search_zh_CN.ts \
|
../translations/libukui-search/libukui-search_zh_CN.ts \
|
||||||
|
@ -70,7 +73,22 @@ TRANSLATIONS += \
|
||||||
qm_files.path = /usr/share/ukui-search/translations/
|
qm_files.path = /usr/share/ukui-search/translations/
|
||||||
qm_files.files = $$OUT_PWD/.qm/*.qm
|
qm_files.files = $$OUT_PWD/.qm/*.qm
|
||||||
|
|
||||||
INSTALLS += qm_files
|
qml.files += search-app-widget-plugin/provider/data/search.qml
|
||||||
|
qml.path = /usr/share/appwidget/qml/
|
||||||
|
|
||||||
|
appwidgetconf.files += search-app-widget-plugin/provider/data/search.conf
|
||||||
|
appwidgetconf.path = /usr/share/appwidget/config/
|
||||||
|
|
||||||
|
service.files += search-app-widget-plugin/provider/org.ukui.appwidget.provider.search.service
|
||||||
|
service.path += /usr/share/dbus-1/services/
|
||||||
|
|
||||||
|
preview.files += search-app-widget-plugin/provider/data/search.png
|
||||||
|
preview.path = /usr/share/appwidget/search/
|
||||||
|
|
||||||
|
svg.files += search-app-widget-plugin/provider/data/ukui-search.svg
|
||||||
|
svg.path = /usr/share/appwidget/search/
|
||||||
|
|
||||||
|
INSTALLS += target qml qm_files appwidgetconf service preview svg
|
||||||
|
|
||||||
|
|
||||||
# Default rules for deployment.
|
# Default rules for deployment.
|
||||||
|
@ -88,7 +106,7 @@ unix {
|
||||||
INSTALLS += target
|
INSTALLS += target
|
||||||
|
|
||||||
header.path = /usr/include/ukui-search
|
header.path = /usr/include/ukui-search
|
||||||
header.files += *.h index/*.h appsearch/*.h settingsearch/*.h plugininterface/*.h websearch/*.h \
|
header.files += *.h index/*.h appsearch/*.h settingsearch/*.h plugininterface/*.h websearch/*.h search-app-widget-plugin/*.h \
|
||||||
searchinterface/ukui-search-task.h \
|
searchinterface/ukui-search-task.h \
|
||||||
appdata/app-info-table.h \
|
appdata/app-info-table.h \
|
||||||
searchinterface/search-controller.h \
|
searchinterface/search-controller.h \
|
||||||
|
|
|
@ -0,0 +1,12 @@
|
||||||
|
[AppWidget]
|
||||||
|
name = search
|
||||||
|
providerName = search
|
||||||
|
previewPath = /usr/share/appwidget/search/search.png
|
||||||
|
qmlFile = /usr/share/appwidget/qml/search.qml
|
||||||
|
zoom = false
|
||||||
|
rightButton = false
|
||||||
|
repeatPlacement = false
|
||||||
|
minWidget = 640
|
||||||
|
minHeight = 100
|
||||||
|
updatePeriodMillis = 0
|
||||||
|
describe = ukui-search app widget
|
Binary file not shown.
After Width: | Height: | Size: 12 KiB |
|
@ -0,0 +1,105 @@
|
||||||
|
import QtQuick 2.6
|
||||||
|
import QtQuick.Window 2.2
|
||||||
|
import QtQuick.Controls 2.5
|
||||||
|
import QtQuick.Layouts 1.3
|
||||||
|
import QtGraphicalEffects 1.0
|
||||||
|
import org.ukui.appwidget 1.0
|
||||||
|
import org.ukui.qqc2style.private 1.0 as StylePrivate
|
||||||
|
|
||||||
|
AppWidget {
|
||||||
|
width: 640
|
||||||
|
height: 100
|
||||||
|
visible: true
|
||||||
|
id: window
|
||||||
|
appname: "search"
|
||||||
|
username: parent.username
|
||||||
|
|
||||||
|
function parseJson(jsonStr) {
|
||||||
|
try {
|
||||||
|
var obj = JSON.parse(jsonStr);
|
||||||
|
return obj;
|
||||||
|
} catch(e) {
|
||||||
|
console.log("json解析失败");
|
||||||
|
}
|
||||||
|
return undefined;
|
||||||
|
}
|
||||||
|
|
||||||
|
function updateSearchBarColor() {
|
||||||
|
var data = window.parseJson(window.datevalue);
|
||||||
|
searchBar.color = Qt.rgba(data.red, data.green, data.blue, data.alpha);
|
||||||
|
placeholderText.color = data.placeHolderTextColor;
|
||||||
|
}
|
||||||
|
|
||||||
|
onDatevalueChanged: updateSearchBarColor();
|
||||||
|
|
||||||
|
Rectangle {
|
||||||
|
id:searchBar
|
||||||
|
anchors.centerIn: parent
|
||||||
|
width:448
|
||||||
|
height: 64
|
||||||
|
radius: searchBar.height / 2
|
||||||
|
|
||||||
|
Component.onCompleted: {
|
||||||
|
window.updateSearchBarColor();
|
||||||
|
}
|
||||||
|
|
||||||
|
RowLayout {
|
||||||
|
id: layout
|
||||||
|
anchors.fill: parent
|
||||||
|
spacing: 0
|
||||||
|
|
||||||
|
Image {
|
||||||
|
id: image_search
|
||||||
|
Layout.leftMargin: 16
|
||||||
|
Layout.rightMargin: 16
|
||||||
|
Layout.preferredWidth: 32;
|
||||||
|
Layout.preferredHeight: 32;
|
||||||
|
|
||||||
|
Layout.alignment: Qt.AlignVCenter
|
||||||
|
source: "file:///usr/share/appwidget/search/ukui-search.svg"
|
||||||
|
}
|
||||||
|
|
||||||
|
Item {
|
||||||
|
clip: true;
|
||||||
|
Layout.fillWidth: true
|
||||||
|
Layout.fillHeight: true;
|
||||||
|
Layout.rightMargin: 32;
|
||||||
|
|
||||||
|
TextInput {
|
||||||
|
id: searchtext
|
||||||
|
anchors.fill: parent;
|
||||||
|
|
||||||
|
Keys.enabled: true
|
||||||
|
Keys.onEnterPressed: {
|
||||||
|
window.qmldefineeventchangedsignal("enter", "search", searchtext.text);
|
||||||
|
searchtext.remove(0, searchtext.length);
|
||||||
|
}
|
||||||
|
Keys.onReturnPressed: {
|
||||||
|
window.qmldefineeventchangedsignal("return", "search", searchtext.text);
|
||||||
|
searchtext.remove(0, searchtext.length);
|
||||||
|
}
|
||||||
|
|
||||||
|
focus: true
|
||||||
|
color: StylePrivate.StyleHelper.windowtextcolorrole
|
||||||
|
maximumLength: 100
|
||||||
|
selectByMouse: true
|
||||||
|
verticalAlignment: Qt.AlignVCenter
|
||||||
|
font.pixelSize: 21
|
||||||
|
|
||||||
|
property string placeholderText: /*qsTr("search")*/"全局搜索"
|
||||||
|
|
||||||
|
Text {
|
||||||
|
id: placeholderText
|
||||||
|
text: searchtext.placeholderText
|
||||||
|
font.pixelSize: 21
|
||||||
|
|
||||||
|
visible: !searchtext.text
|
||||||
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
|
@ -0,0 +1,16 @@
|
||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<svg width="24px" height="24px" viewBox="0 0 24 24" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
|
||||||
|
<title>ukui-global search-search</title>
|
||||||
|
<g id="Edu-OS-Light" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd">
|
||||||
|
<g id="TM-桌面01" transform="translate(-136.000000, -229.000000)">
|
||||||
|
<g id="编组-4" transform="translate(112.000000, 72.000000)">
|
||||||
|
<g id="bar-搜索" transform="translate(0.000000, 129.000000)">
|
||||||
|
<g id="ukui-global-search-search" transform="translate(24.000000, 28.000000)">
|
||||||
|
<rect id="矩形" fill="#D8D8D8" opacity="0" x="0" y="0" width="24" height="24"></rect>
|
||||||
|
<path d="M20.0438748,18.9452961 C20.1903159,19.010529 20.3261068,19.1023875 20.4459222,19.2208716 L21.3871392,20.1620886 C21.9073266,20.682276 21.9073266,21.5256665 21.3871392,22.0458539 C20.8669518,22.5660413 20.0235614,22.5660413 19.503374,22.0458539 L18.562157,21.1046369 C18.4194646,20.9622814 18.3111039,20.7892687 18.2453117,20.5987494 C13.6793877,23.9173079 7.31736537,23.0972668 3.74219939,18.7293519 C0.167033407,14.361437 0.620549962,7.96283413 4.77605327,4.14284924 C8.93155659,0.32286435 15.3456416,0.408360923 19.3978496,4.33775053 C23.4500576,8.26714015 23.7328629,14.6755578 20.0425435,18.9466274 L20.0438748,18.9452961 Z M12,20 C16.418278,20 20,16.418278 20,12 C20,7.581722 16.418278,4 12,4 C7.581722,4 4,7.581722 4,12 C4,16.418278 7.581722,20 12,20 Z" id="形状" fill="#6F6F6F"></path>
|
||||||
|
</g>
|
||||||
|
</g>
|
||||||
|
</g>
|
||||||
|
</g>
|
||||||
|
</g>
|
||||||
|
</svg>
|
After Width: | Height: | Size: 1.6 KiB |
|
@ -0,0 +1,23 @@
|
||||||
|
<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
|
||||||
|
<g clip-path="url(#clip0_1579_30292)">
|
||||||
|
<path fill-rule="evenodd" clip-rule="evenodd" d="M10.5 17C14.0899 17 17 14.0899 17 10.5C17 6.91015 14.0899 4 10.5 4C6.91015 4 4 6.91015 4 10.5C4 14.0899 6.91015 17 10.5 17ZM10.5 21C16.299 21 21 16.299 21 10.5C21 4.70101 16.299 0 10.5 0C4.70101 0 0 4.70101 0 10.5C0 16.299 4.70101 21 10.5 21Z" fill="url(#paint0_radial_1579_30292)"/>
|
||||||
|
<path d="M17.7019 20.7019L20.5303 17.8735L22.6569 20C23.4379 20.781 23.4379 22.0474 22.6569 22.8284C21.8758 23.6095 20.6095 23.6095 19.8284 22.8284L17.7019 20.7019Z" fill="url(#paint1_radial_1579_30292)"/>
|
||||||
|
</g>
|
||||||
|
<defs>
|
||||||
|
<radialGradient id="paint0_radial_1579_30292" cx="0" cy="0" r="1" gradientUnits="userSpaceOnUse" gradientTransform="translate(3.98925 2.46944) rotate(47.4635) scale(27.2766 37.8883)">
|
||||||
|
<stop offset="0.000275725" stop-color="#FFC118"/>
|
||||||
|
<stop offset="0.299664" stop-color="#FF5368"/>
|
||||||
|
<stop offset="0.676441" stop-color="#CC3CCD"/>
|
||||||
|
<stop offset="1" stop-color="#732AF4"/>
|
||||||
|
</radialGradient>
|
||||||
|
<radialGradient id="paint1_radial_1579_30292" cx="0" cy="0" r="1" gradientUnits="userSpaceOnUse" gradientTransform="translate(3.98925 2.46944) rotate(47.4635) scale(27.2766 37.8883)">
|
||||||
|
<stop offset="0.000275725" stop-color="#FFC118"/>
|
||||||
|
<stop offset="0.299664" stop-color="#FF5368"/>
|
||||||
|
<stop offset="0.676441" stop-color="#CC3CCD"/>
|
||||||
|
<stop offset="1" stop-color="#732AF4"/>
|
||||||
|
</radialGradient>
|
||||||
|
<clipPath id="clip0_1579_30292">
|
||||||
|
<rect width="24" height="24" fill="white"/>
|
||||||
|
</clipPath>
|
||||||
|
</defs>
|
||||||
|
</svg>
|
After Width: | Height: | Size: 1.5 KiB |
|
@ -0,0 +1,3 @@
|
||||||
|
[D-BUS Service]
|
||||||
|
Name=org.ukui.appwidget.provider.search
|
||||||
|
Exec=/usr/bin/ukui-search
|
|
@ -0,0 +1,9 @@
|
||||||
|
<RCC>
|
||||||
|
<qresource prefix="/">
|
||||||
|
<file>org.ukui.appwidget.provider.search.service</file>
|
||||||
|
<file>data/search.conf</file>
|
||||||
|
<file>data/search.qml</file>
|
||||||
|
<file>data/search.png</file>
|
||||||
|
<file>data/ukui-search.svg</file>
|
||||||
|
</qresource>
|
||||||
|
</RCC>
|
|
@ -0,0 +1,6 @@
|
||||||
|
INCLUDEPATH += $$PWD
|
||||||
|
|
||||||
|
HEADERS += \
|
||||||
|
$$PWD/search.h
|
||||||
|
SOURCES += \
|
||||||
|
$$PWD/search.cpp
|
|
@ -0,0 +1,52 @@
|
||||||
|
QT += dbus widgets
|
||||||
|
|
||||||
|
TEMPLATE = lib
|
||||||
|
DEFINES += SEARCHAPPWIDGETPLUGIN_LIBRARY
|
||||||
|
|
||||||
|
CONFIG += c++11 link_pkgconfig
|
||||||
|
|
||||||
|
PKGCONFIG += gsettings-qt
|
||||||
|
|
||||||
|
# The following define makes your compiler emit warnings if you use
|
||||||
|
# any Qt feature that has been marked deprecated (the exact warnings
|
||||||
|
# depend on your compiler). Please consult the documentation of the
|
||||||
|
# deprecated API in order to know how to port your code away from it.
|
||||||
|
DEFINES += QT_DEPRECATED_WARNINGS
|
||||||
|
|
||||||
|
# You can also make your code fail to compile if it uses deprecated APIs.
|
||||||
|
# In order to do so, uncomment the following line.
|
||||||
|
# You can also select to disable deprecated APIs only up to a certain version of Qt.
|
||||||
|
#DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0x060000 # disables all the APIs deprecated before Qt 6.0.0
|
||||||
|
|
||||||
|
TRANSLATIONS += translations/zh_CN.ts
|
||||||
|
|
||||||
|
SOURCES += \
|
||||||
|
search.cpp
|
||||||
|
|
||||||
|
HEADERS += \
|
||||||
|
search-app-widget-plugin_global.h \
|
||||||
|
search.h
|
||||||
|
|
||||||
|
LIBS += -lukui-appwidget-manager -lukui-appwidget-provider
|
||||||
|
|
||||||
|
# Default rules for deployment.
|
||||||
|
|
||||||
|
qml.files += provider/data/search.qml
|
||||||
|
qml.path = /usr/share/appwidget/qml/
|
||||||
|
|
||||||
|
qm_files.files = translations/* $$OUT_PWD/.qm/*.qm
|
||||||
|
qm_files.path = /usr/share/appwidget/search/translations/
|
||||||
|
|
||||||
|
appwidgetconf.files += provider/data/search.conf
|
||||||
|
appwidgetconf.path = /usr/share/appwidget/config/
|
||||||
|
|
||||||
|
service.files += provider/org.ukui.appwidget.provider.search.service
|
||||||
|
service.path += /usr/share/dbus-1/services/
|
||||||
|
|
||||||
|
preview.files += provider/data/search.png
|
||||||
|
preview.path = /usr/share/appwidget/search/
|
||||||
|
|
||||||
|
svg.files += provider/data/ukui-search.svg
|
||||||
|
svg.path = /usr/share/appwidget/search/
|
||||||
|
|
||||||
|
INSTALLS += target qml qm_files appwidgetconf service preview svg
|
|
@ -0,0 +1,12 @@
|
||||||
|
#ifndef SEARCHAPPWIDGETPLUGIN_GLOBAL_H
|
||||||
|
#define SEARCHAPPWIDGETPLUGIN_GLOBAL_H
|
||||||
|
|
||||||
|
#include <QtCore/qglobal.h>
|
||||||
|
|
||||||
|
#if defined(SEARCHAPPWIDGETPLUGIN_LIBRARY)
|
||||||
|
# define SEARCHAPPWIDGETPLUGIN_EXPORT Q_DECL_EXPORT
|
||||||
|
#else
|
||||||
|
# define SEARCHAPPWIDGETPLUGIN_EXPORT Q_DECL_IMPORT
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#endif // SEARCHAPPWIDGETPLUGIN_GLOBAL_H
|
|
@ -0,0 +1,81 @@
|
||||||
|
#include "search.h"
|
||||||
|
|
||||||
|
#include <QDBusPendingCall>
|
||||||
|
#include <QDBusMetaType>
|
||||||
|
#include <QTranslator>
|
||||||
|
#include <QDebug>
|
||||||
|
#include <QJsonObject>
|
||||||
|
#include <QJsonDocument>
|
||||||
|
#include <QApplication>
|
||||||
|
|
||||||
|
#define CONTROL_CENTER_PERSONALISE_GSETTINGS_ID "org.ukui.control-center.personalise"
|
||||||
|
#define TRANSPARENCY_KEY "transparency"
|
||||||
|
#define THEME_GSETTINGS_ID "org.ukui.style"
|
||||||
|
#define STYLE_NAME_KEY "styleName"
|
||||||
|
|
||||||
|
using namespace UkuiSearch;
|
||||||
|
|
||||||
|
AppWidgetPlugin::AppWidgetPlugin(QString providername, QObject *parent) : KAppWidgetProvider(providername, parent)
|
||||||
|
{
|
||||||
|
QTranslator* translator = new QTranslator(this);
|
||||||
|
if(!translator->load("/usr/share/appwidget/search/translations/" + QLocale::system().name()+ ".qm")) {
|
||||||
|
qWarning() << "/usr/share/appwidget/search/translations/" + QLocale::system().name() << "load failed";
|
||||||
|
}
|
||||||
|
QApplication::installTranslator(translator);
|
||||||
|
|
||||||
|
m_interface = new QDBusInterface("com.ukui.search.service",
|
||||||
|
"/",
|
||||||
|
"org.ukui.search.service");
|
||||||
|
|
||||||
|
m_manager = new AppWidget::KAppWidgetManager(this);
|
||||||
|
|
||||||
|
connect(GlobalSettings::getInstance(), &GlobalSettings::transparencyChanged, [ & ] {
|
||||||
|
qDebug() << "transparency changed";
|
||||||
|
this->appWidgetUpdate();
|
||||||
|
});
|
||||||
|
|
||||||
|
connect(GlobalSettings::getInstance(), &GlobalSettings::styleChanged, [ & ] {
|
||||||
|
qDebug() << "style changed";
|
||||||
|
this->appWidgetUpdate();
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
void AppWidgetPlugin::appWidgetRecevie(const QString &eventname, const QString &widgetname, const QDBusVariant &value)
|
||||||
|
{
|
||||||
|
qDebug() << widgetname << value.variant();
|
||||||
|
if (eventname == "enter" or eventname == "return") {
|
||||||
|
QString keyword = value.variant().toString();
|
||||||
|
Q_EMIT this->startSearch(keyword);
|
||||||
|
} else {
|
||||||
|
qWarning() << "event:" << eventname << "has no trigger now.";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
void AppWidgetPlugin::appWidgetUpdate()
|
||||||
|
{
|
||||||
|
QString theme = GlobalSettings::getInstance()->getValue(STYLE_NAME_KEY).toString();
|
||||||
|
QJsonObject obj;
|
||||||
|
if (theme == "ukui-dark") {
|
||||||
|
obj.insert("red", QJsonValue(0));
|
||||||
|
obj.insert("green", QJsonValue(0));
|
||||||
|
obj.insert("blue", QJsonValue(0));
|
||||||
|
obj.insert("placeHolderTextColor", QJsonValue("#72ffffff"));
|
||||||
|
} else {
|
||||||
|
obj.insert("red", QJsonValue(255));
|
||||||
|
obj.insert("green", QJsonValue(255));
|
||||||
|
obj.insert("blue", QJsonValue(255));
|
||||||
|
obj.insert("placeHolderTextColor", QJsonValue("#72000000"));
|
||||||
|
}
|
||||||
|
|
||||||
|
obj.insert("alpha", QJsonValue(GlobalSettings::getInstance()->getValue(TRANSPARENCY_KEY).toDouble()));
|
||||||
|
QString jsonData = QString(QJsonDocument(obj).toJson());
|
||||||
|
|
||||||
|
QDBusVariant variant;
|
||||||
|
variant.setVariant(jsonData);
|
||||||
|
|
||||||
|
// variant.setVariant(QGuiApplication::palette().color(QPalette::Window).name(QColor::HexArgb));
|
||||||
|
if(m_manager) {
|
||||||
|
m_manager->updateAppWidget("search", variant);
|
||||||
|
qDebug() <<"==========update style and transparency successful.";
|
||||||
|
}
|
||||||
|
}
|
|
@ -0,0 +1,39 @@
|
||||||
|
#ifndef SEARCH_H
|
||||||
|
#define SEARCH_H
|
||||||
|
|
||||||
|
#include "libsearch_global.h"
|
||||||
|
|
||||||
|
#define signals Q_SIGNALS
|
||||||
|
#define slots Q_SLOTS
|
||||||
|
|
||||||
|
#include "ukui/kappwidgetprovider.h"
|
||||||
|
#include "ukui/kappwidgetmanager.h"
|
||||||
|
|
||||||
|
#undef signals
|
||||||
|
#undef slots
|
||||||
|
|
||||||
|
#include "global-settings.h"
|
||||||
|
#include <QDBusInterface>
|
||||||
|
|
||||||
|
namespace UkuiSearch {
|
||||||
|
class LIBSEARCH_EXPORT AppWidgetPlugin : public AppWidget::KAppWidgetProvider
|
||||||
|
|
||||||
|
{
|
||||||
|
Q_OBJECT
|
||||||
|
public:
|
||||||
|
explicit AppWidgetPlugin(QString providername = "search", QObject *parent = nullptr);
|
||||||
|
void appWidgetRecevie(const QString &eventname, const QString &widgetname, const QDBusVariant &value);
|
||||||
|
void appWidgetUpdate();
|
||||||
|
|
||||||
|
Q_SIGNALS:
|
||||||
|
void startSearch(QString);
|
||||||
|
|
||||||
|
private:
|
||||||
|
QDBusInterface* m_interface = nullptr;
|
||||||
|
AppWidget::KAppWidgetManager* m_manager = nullptr;
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
#endif // SEARCH_H
|
|
@ -53,75 +53,74 @@
|
||||||
<translation>གཤམ་གྱི་ཡིག་སྣོད་འཚོལ་བཤེར་མི་བྱེད། ཡིག་སྣོད་གསར་སྣོན་དང་གསུབ་འཕྲི་བྱས་ཚེ་ཡིག་ཆའི་དཀར་ཆག་སྒྲིག་འགོད་བྱ་ཐུབ།</translation>
|
<translation>གཤམ་གྱི་ཡིག་སྣོད་འཚོལ་བཤེར་མི་བྱེད། ཡིག་སྣོད་གསར་སྣོན་དང་གསུབ་འཕྲི་བྱས་ཚེ་ཡིག་ཆའི་དཀར་ཆག་སྒྲིག་འགོད་བྱ་ཐུབ།</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../search.cpp" line="225"/>
|
|
||||||
<source>Choose folder</source>
|
<source>Choose folder</source>
|
||||||
<translation>བསལ་འདེམས་ཀྱི་དཀར་ཆག།</translation>
|
<translation type="vanished">བསལ་འདེམས་ཀྱི་དཀར་ཆག།</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../search.cpp" line="338"/>
|
<location filename="../search.cpp" line="340"/>
|
||||||
<source>delete</source>
|
<source>delete</source>
|
||||||
<translation>བསུབ་པ།</translation>
|
<translation>བསུབ་པ།</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../search.cpp" line="393"/>
|
<location filename="../search.cpp" line="395"/>
|
||||||
<source>Directories</source>
|
<source>Directories</source>
|
||||||
<translation>དཀར་ཆག</translation>
|
<translation>དཀར་ཆག</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../search.cpp" line="394"/>
|
<location filename="../search.cpp" line="396"/>
|
||||||
<source>select blocked folder</source>
|
<source>select blocked folder</source>
|
||||||
<translation>བཀག་སྡོམ་བྱས་པའི་ཡིག་སྣོད་གདམ་གསེས</translation>
|
<translation>བཀག་སྡོམ་བྱས་པའི་ཡིག་སྣོད་གདམ་གསེས</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../search.cpp" line="395"/>
|
<location filename="../search.cpp" line="397"/>
|
||||||
<source>Select</source>
|
<source>Select</source>
|
||||||
<translation>བདམས་ཐོན་བྱུང་བ།</translation>
|
<translation>བདམས་ཐོན་བྱུང་བ།</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../search.cpp" line="396"/>
|
<location filename="../search.cpp" line="398"/>
|
||||||
<source>Position: </source>
|
<source>Position: </source>
|
||||||
<translation>གོ་གནས་ནི། </translation>
|
<translation>གོ་གནས་ནི། </translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../search.cpp" line="397"/>
|
<location filename="../search.cpp" line="399"/>
|
||||||
<source>FileName: </source>
|
<source>FileName: </source>
|
||||||
<translation>ཡིག་ཆའི་མིང་ནི། </translation>
|
<translation>ཡིག་ཆའི་མིང་ནི། </translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../search.cpp" line="398"/>
|
<location filename="../search.cpp" line="400"/>
|
||||||
<source>FileType: </source>
|
<source>FileType: </source>
|
||||||
<translation>ཡིག་ཆའི་རིགས་དབྱིབས་ནི། </translation>
|
<translation>ཡིག་ཆའི་རིགས་དབྱིབས་ནི། </translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../search.cpp" line="399"/>
|
<location filename="../search.cpp" line="401"/>
|
||||||
<source>Cancel</source>
|
<source>Cancel</source>
|
||||||
<translation>ཕྱིར་འཐེན།</translation>
|
<translation>ཕྱིར་འཐེན།</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../search.cpp" line="415"/>
|
<location filename="../search.cpp" line="417"/>
|
||||||
<location filename="../search.cpp" line="419"/>
|
<location filename="../search.cpp" line="421"/>
|
||||||
<location filename="../search.cpp" line="423"/>
|
<location filename="../search.cpp" line="425"/>
|
||||||
<location filename="../search.cpp" line="427"/>
|
<location filename="../search.cpp" line="429"/>
|
||||||
<source>Warning</source>
|
<source>Warning</source>
|
||||||
<translation>ཐ་ཚིག་སྒྲོག་པ།</translation>
|
<translation>ཐ་ཚིག་སྒྲོག་པ།</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../search.cpp" line="415"/>
|
<location filename="../search.cpp" line="417"/>
|
||||||
<source>Add blocked folder failed, choosen path is empty!</source>
|
<source>Add blocked folder failed, choosen path is empty!</source>
|
||||||
<translation>སྦྱོར་རྟ་ལྐོག་བཀོད་མིང་ཐོ་ཕམ་ཁ་བསལ་འདེམས་ཀྱི་ཐབས་ལམ་སྟོང་བ་རེད།</translation>
|
<translation>སྦྱོར་རྟ་ལྐོག་བཀོད་མིང་ཐོ་ཕམ་ཁ་བསལ་འདེམས་ཀྱི་ཐབས་ལམ་སྟོང་བ་རེད།</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../search.cpp" line="419"/>
|
<location filename="../search.cpp" line="421"/>
|
||||||
<source>Add blocked folder failed, it is not in home path!</source>
|
<source>Add blocked folder failed, it is not in home path!</source>
|
||||||
<translation>སྦྱོར་རྟ་ལྐོག་བཀོད་མིང་ཐོ་ཕམ་ཁ་བསལ་འདེམས་ཀྱི་དཀར་ཆག་མི་ཁྱིམ་དཀར་ཆག་འོག།</translation>
|
<translation>སྦྱོར་རྟ་ལྐོག་བཀོད་མིང་ཐོ་ཕམ་ཁ་བསལ་འདེམས་ཀྱི་དཀར་ཆག་མི་ཁྱིམ་དཀར་ཆག་འོག།</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../search.cpp" line="423"/>
|
<location filename="../search.cpp" line="425"/>
|
||||||
<source>Add blocked folder failed, its parent dir is exist!</source>
|
<source>Add blocked folder failed, its parent dir is exist!</source>
|
||||||
<translation>སྦྱོར་རྟ་ལྐོག་བཀོད་མིང་ཐོ་ཕམ་ཁ་བསལ་འདེམས་ཀྱི་དཀར་ཆག་ནི་ལྐོག་བཀོད་མིང་ཐོ་འི་ཁྲོད་ཀྱི་དཀར་ཆག་འོག</translation>
|
<translation>སྦྱོར་རྟ་ལྐོག་བཀོད་མིང་ཐོ་ཕམ་ཁ་བསལ་འདེམས་ཀྱི་དཀར་ཆག་ནི་ལྐོག་བཀོད་མིང་ཐོ་འི་ཁྲོད་ཀྱི་དཀར་ཆག་འོག</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../search.cpp" line="427"/>
|
<location filename="../search.cpp" line="429"/>
|
||||||
<source>Add blocked folder failed, it has been already blocked!</source>
|
<source>Add blocked folder failed, it has been already blocked!</source>
|
||||||
<translation>སྦྱོར་རྟ་ལྐོག་བཀོད་མིང་ཐོ་ཕམ་ཁ་བསལ་འདེམས་ཀྱི་དཀར་ཆག་ནི་ལྐོག་བཀོད་མིང་ཐོ་འི་ཁྲོད་ཀྱི་དཀར་ཆག་འོག</translation>
|
<translation>སྦྱོར་རྟ་ལྐོག་བཀོད་མིང་ཐོ་ཕམ་ཁ་བསལ་འདེམས་ཀྱི་དཀར་ཆག་ནི་ལྐོག་བཀོད་མིང་ཐོ་འི་ཁྲོད་ཀྱི་དཀར་ཆག་འོག</translation>
|
||||||
</message>
|
</message>
|
||||||
|
|
|
@ -53,75 +53,74 @@
|
||||||
<translation>搜索将不查看以下文件夹,通过添加和删除可以设置排除的文件夹位置</translation>
|
<translation>搜索将不查看以下文件夹,通过添加和删除可以设置排除的文件夹位置</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../search.cpp" line="225"/>
|
|
||||||
<source>Choose folder</source>
|
<source>Choose folder</source>
|
||||||
<translation>添加</translation>
|
<translation type="vanished">添加</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../search.cpp" line="338"/>
|
<location filename="../search.cpp" line="340"/>
|
||||||
<source>delete</source>
|
<source>delete</source>
|
||||||
<translation>删除</translation>
|
<translation>删除</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../search.cpp" line="393"/>
|
<location filename="../search.cpp" line="395"/>
|
||||||
<source>Directories</source>
|
<source>Directories</source>
|
||||||
<translation>文件夹</translation>
|
<translation>文件夹</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../search.cpp" line="394"/>
|
<location filename="../search.cpp" line="396"/>
|
||||||
<source>select blocked folder</source>
|
<source>select blocked folder</source>
|
||||||
<translation>选择排除的文件夹</translation>
|
<translation>选择排除的文件夹</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../search.cpp" line="395"/>
|
<location filename="../search.cpp" line="397"/>
|
||||||
<source>Select</source>
|
<source>Select</source>
|
||||||
<translation>选择</translation>
|
<translation>选择</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../search.cpp" line="396"/>
|
<location filename="../search.cpp" line="398"/>
|
||||||
<source>Position: </source>
|
<source>Position: </source>
|
||||||
<translation>位置</translation>
|
<translation>位置</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../search.cpp" line="397"/>
|
<location filename="../search.cpp" line="399"/>
|
||||||
<source>FileName: </source>
|
<source>FileName: </source>
|
||||||
<translation>文件名</translation>
|
<translation>文件名</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../search.cpp" line="398"/>
|
<location filename="../search.cpp" line="400"/>
|
||||||
<source>FileType: </source>
|
<source>FileType: </source>
|
||||||
<translation>类型</translation>
|
<translation>类型</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../search.cpp" line="399"/>
|
<location filename="../search.cpp" line="401"/>
|
||||||
<source>Cancel</source>
|
<source>Cancel</source>
|
||||||
<translation>取消</translation>
|
<translation>取消</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../search.cpp" line="415"/>
|
<location filename="../search.cpp" line="417"/>
|
||||||
<location filename="../search.cpp" line="419"/>
|
<location filename="../search.cpp" line="421"/>
|
||||||
<location filename="../search.cpp" line="423"/>
|
<location filename="../search.cpp" line="425"/>
|
||||||
<location filename="../search.cpp" line="427"/>
|
<location filename="../search.cpp" line="429"/>
|
||||||
<source>Warning</source>
|
<source>Warning</source>
|
||||||
<translation>警告</translation>
|
<translation>警告</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../search.cpp" line="415"/>
|
<location filename="../search.cpp" line="417"/>
|
||||||
<source>Add blocked folder failed, choosen path is empty!</source>
|
<source>Add blocked folder failed, choosen path is empty!</source>
|
||||||
<translation>添加失败,选择的路径为空!</translation>
|
<translation>添加失败,选择的路径为空!</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../search.cpp" line="419"/>
|
<location filename="../search.cpp" line="421"/>
|
||||||
<source>Add blocked folder failed, it is not in home path!</source>
|
<source>Add blocked folder failed, it is not in home path!</source>
|
||||||
<translation>添加失败,添加的路径不在家目录下!</translation>
|
<translation>添加失败,添加的路径不在家目录下!</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../search.cpp" line="423"/>
|
<location filename="../search.cpp" line="425"/>
|
||||||
<source>Add blocked folder failed, its parent dir is exist!</source>
|
<source>Add blocked folder failed, its parent dir is exist!</source>
|
||||||
<translation>添加失败,父目录已被添加!</translation>
|
<translation>添加失败,父目录已被添加!</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../search.cpp" line="427"/>
|
<location filename="../search.cpp" line="429"/>
|
||||||
<source>Add blocked folder failed, it has been already blocked!</source>
|
<source>Add blocked folder failed, it has been already blocked!</source>
|
||||||
<translation>添加失败,这个文件夹已经被添加过了!</translation>
|
<translation>添加失败,这个文件夹已经被添加过了!</translation>
|
||||||
</message>
|
</message>
|
||||||
|
|
|
@ -9,7 +9,7 @@
|
||||||
<translation>ནང་དོན་གྱི་སྟོན་གྲངས་ཆ་མི་ཚང་བ།</translation>
|
<translation>ནང་དོན་གྱི་སྟོན་གྲངས་ཆ་མི་ཚང་བ།</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../libsearch/searchinterface/searchtasks/file-search-task.cpp" line="96"/>
|
<location filename="../../libsearch/searchinterface/searchtasks/file-search-task.cpp" line="97"/>
|
||||||
<source>Warning, Can not find home path.</source>
|
<source>Warning, Can not find home path.</source>
|
||||||
<translation>ཁྱིམ་གྱི་དཀར་ཆག་རྙེད་ཐབས་མེད།</translation>
|
<translation>ཁྱིམ་གྱི་དཀར་ཆག་རྙེད་ཐབས་མེད།</translation>
|
||||||
</message>
|
</message>
|
||||||
|
@ -17,49 +17,66 @@
|
||||||
<context>
|
<context>
|
||||||
<name>UkuiSearch::AppMatch</name>
|
<name>UkuiSearch::AppMatch</name>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../libsearch/appsearch/app-match.cpp" line="262"/>
|
|
||||||
<source>Application Description:</source>
|
<source>Application Description:</source>
|
||||||
<translation>ཉེར་སྤྱོད་གོ་རིམ་གྱི་གསལ་བཤད།</translation>
|
<translation type="vanished">ཉེར་སྤྱོད་གོ་རིམ་གྱི་གསལ་བཤད།</translation>
|
||||||
</message>
|
</message>
|
||||||
</context>
|
</context>
|
||||||
<context>
|
<context>
|
||||||
<name>UkuiSearch::AppSearchPlugin</name>
|
<name>UkuiSearch::AppSearchPlugin</name>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../libsearch/appsearch/app-search-plugin.cpp" line="11"/>
|
<location filename="../../libsearch/appsearch/app-search-plugin.cpp" line="11"/>
|
||||||
<location filename="../../libsearch/appsearch/app-search-plugin.cpp" line="174"/>
|
<location filename="../../libsearch/appsearch/app-search-plugin.cpp" line="231"/>
|
||||||
<source>Open</source>
|
<source>Open</source>
|
||||||
<translation>སྒོ་ཕྱེ་བ།</translation>
|
<translation>སྒོ་ཕྱེ་བ།</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../libsearch/appsearch/app-search-plugin.cpp" line="12"/>
|
<location filename="../../libsearch/appsearch/app-search-plugin.cpp" line="12"/>
|
||||||
<location filename="../../libsearch/appsearch/app-search-plugin.cpp" line="175"/>
|
<location filename="../../libsearch/appsearch/app-search-plugin.cpp" line="232"/>
|
||||||
<source>Add Shortcut to Desktop</source>
|
<source>Add Shortcut to Desktop</source>
|
||||||
<translation>ཅོག་ངོས་སུ་མྱུར་འཐེབ་སྣོན་པ།</translation>
|
<translation>ཅོག་ངོས་སུ་མྱུར་འཐེབ་སྣོན་པ།</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../libsearch/appsearch/app-search-plugin.cpp" line="13"/>
|
<location filename="../../libsearch/appsearch/app-search-plugin.cpp" line="13"/>
|
||||||
<location filename="../../libsearch/appsearch/app-search-plugin.cpp" line="176"/>
|
<location filename="../../libsearch/appsearch/app-search-plugin.cpp" line="233"/>
|
||||||
<source>Add Shortcut to Panel</source>
|
<source>Add Shortcut to Panel</source>
|
||||||
<translation>ལས་འགན་གྱི་སྒྲོམ་ཐོག་མགྱོགས་མྱུར་གྱི་བྱེད་ཐབས་གསར་སྣོན་བྱ་དགོས</translation>
|
<translation>ལས་འགན་གྱི་སྒྲོམ་ཐོག་མགྱོགས་མྱུར་གྱི་བྱེད་ཐབས་གསར་སྣོན་བྱ་དགོས</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../libsearch/appsearch/app-search-plugin.cpp" line="14"/>
|
<location filename="../../libsearch/appsearch/app-search-plugin.cpp" line="14"/>
|
||||||
<location filename="../../libsearch/appsearch/app-search-plugin.cpp" line="177"/>
|
<location filename="../../libsearch/appsearch/app-search-plugin.cpp" line="234"/>
|
||||||
<source>Install</source>
|
<source>Install</source>
|
||||||
<translation>སྒྲིག་སྦྱོར་བྱེད་པ</translation>
|
<translation>སྒྲིག་སྦྱོར་བྱེད་པ</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../libsearch/appsearch/app-search-plugin.cpp" line="30"/>
|
<location filename="../../libsearch/appsearch/app-search-plugin.cpp" line="53"/>
|
||||||
<location filename="../../libsearch/appsearch/app-search-plugin.cpp" line="35"/>
|
<source>Application Description:</source>
|
||||||
|
<translation type="unfinished">ཉེར་སྤྱོད་གོ་རིམ་གྱི་གསལ་བཤད།</translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<location filename="../../libsearch/appsearch/app-search-plugin.cpp" line="73"/>
|
||||||
|
<location filename="../../libsearch/appsearch/app-search-plugin.cpp" line="78"/>
|
||||||
<source>Applications Search</source>
|
<source>Applications Search</source>
|
||||||
<translation>ཉེར་སྤྱོད་གོ་རིམ་འཚོལ་བཤེར།</translation>
|
<translation>ཉེར་སྤྱོད་གོ་རིམ་འཚོལ་བཤེར།</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../libsearch/appsearch/app-search-plugin.cpp" line="115"/>
|
<location filename="../../libsearch/appsearch/app-search-plugin.cpp" line="167"/>
|
||||||
<source>Application</source>
|
<source>Application</source>
|
||||||
<translation>ཉེར་སྤྱོད་བྱ་རིམ།</translation>
|
<translation>ཉེར་སྤྱོད་བྱ་རིམ།</translation>
|
||||||
</message>
|
</message>
|
||||||
</context>
|
</context>
|
||||||
|
<context>
|
||||||
|
<name>UkuiSearch::AppSearchTask</name>
|
||||||
|
<message>
|
||||||
|
<location filename="../../libsearch/searchinterface/searchtasks/app-search-task.cpp" line="21"/>
|
||||||
|
<source>Application</source>
|
||||||
|
<translation type="unfinished">ཉེར་སྤྱོད་བྱ་རིམ།</translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<location filename="../../libsearch/searchinterface/searchtasks/app-search-task.cpp" line="26"/>
|
||||||
|
<source>Application search.</source>
|
||||||
|
<translation type="unfinished"></translation>
|
||||||
|
</message>
|
||||||
|
</context>
|
||||||
<context>
|
<context>
|
||||||
<name>UkuiSearch::DirSearchPlugin</name>
|
<name>UkuiSearch::DirSearchPlugin</name>
|
||||||
<message>
|
<message>
|
||||||
|
@ -338,14 +355,14 @@
|
||||||
<context>
|
<context>
|
||||||
<name>UkuiSearch::SearchTaskPluginManager</name>
|
<name>UkuiSearch::SearchTaskPluginManager</name>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../libsearch/pluginmanage/search-task-plugin-manager.cpp" line="64"/>
|
<location filename="../../libsearch/pluginmanage/search-task-plugin-manager.cpp" line="68"/>
|
||||||
<location filename="../../libsearch/pluginmanage/search-task-plugin-manager.cpp" line="78"/>
|
<location filename="../../libsearch/pluginmanage/search-task-plugin-manager.cpp" line="82"/>
|
||||||
<source>plugin type: %1, is disabled!</source>
|
<source>plugin type: %1, is disabled!</source>
|
||||||
<translation>ནུས་པ་སྒོ་བརྒྱབ་ཡོད།</translation>
|
<translation>ནུས་པ་སྒོ་བརྒྱབ་ཡོད།</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../libsearch/pluginmanage/search-task-plugin-manager.cpp" line="70"/>
|
<location filename="../../libsearch/pluginmanage/search-task-plugin-manager.cpp" line="74"/>
|
||||||
<location filename="../../libsearch/pluginmanage/search-task-plugin-manager.cpp" line="83"/>
|
<location filename="../../libsearch/pluginmanage/search-task-plugin-manager.cpp" line="87"/>
|
||||||
<source>plugin type: %1, is not registered!</source>
|
<source>plugin type: %1, is not registered!</source>
|
||||||
<translation>ནུས་པ་ཐོ་འགོད་བྱས་མེད་པ།</translation>
|
<translation>ནུས་པ་ཐོ་འགོད་བྱས་མེད་པ།</translation>
|
||||||
</message>
|
</message>
|
||||||
|
@ -374,6 +391,14 @@
|
||||||
<translation>སྒྲིག་བཀོད།</translation>
|
<translation>སྒྲིག་བཀོད།</translation>
|
||||||
</message>
|
</message>
|
||||||
</context>
|
</context>
|
||||||
|
<context>
|
||||||
|
<name>UkuiSearch::UkuiSearchTaskPrivate</name>
|
||||||
|
<message>
|
||||||
|
<location filename="../../libsearch/searchinterface/ukui-search-task.cpp" line="92"/>
|
||||||
|
<source>Current task uuid error or an unregistered plugin is used!</source>
|
||||||
|
<translation type="unfinished"></translation>
|
||||||
|
</message>
|
||||||
|
</context>
|
||||||
<context>
|
<context>
|
||||||
<name>UkuiSearch::WebSearchPlugin</name>
|
<name>UkuiSearch::WebSearchPlugin</name>
|
||||||
<message>
|
<message>
|
||||||
|
@ -389,4 +414,12 @@
|
||||||
<translation>དྲ་ངོས།</translation>
|
<translation>དྲ་ངོས།</translation>
|
||||||
</message>
|
</message>
|
||||||
</context>
|
</context>
|
||||||
|
<context>
|
||||||
|
<name>search</name>
|
||||||
|
<message>
|
||||||
|
<location filename="../../libsearch/search-app-widget-plugin/provider/data/search.qml" line="89"/>
|
||||||
|
<source>search</source>
|
||||||
|
<translation type="unfinished"></translation>
|
||||||
|
</message>
|
||||||
|
</context>
|
||||||
</TS>
|
</TS>
|
||||||
|
|
|
@ -9,7 +9,7 @@
|
||||||
<translation type="unfinished"></translation>
|
<translation type="unfinished"></translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../libsearch/searchinterface/searchtasks/file-search-task.cpp" line="96"/>
|
<location filename="../../libsearch/searchinterface/searchtasks/file-search-task.cpp" line="97"/>
|
||||||
<source>Warning, Can not find home path.</source>
|
<source>Warning, Can not find home path.</source>
|
||||||
<translation type="unfinished"></translation>
|
<translation type="unfinished"></translation>
|
||||||
</message>
|
</message>
|
||||||
|
@ -17,9 +17,8 @@
|
||||||
<context>
|
<context>
|
||||||
<name>UkuiSearch::AppMatch</name>
|
<name>UkuiSearch::AppMatch</name>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../libsearch/appsearch/app-match.cpp" line="262"/>
|
|
||||||
<source>Application Description:</source>
|
<source>Application Description:</source>
|
||||||
<translation>应用描述:</translation>
|
<translation type="vanished">应用描述:</translation>
|
||||||
</message>
|
</message>
|
||||||
</context>
|
</context>
|
||||||
<context>
|
<context>
|
||||||
|
@ -33,53 +32,56 @@
|
||||||
<name>UkuiSearch::AppSearchPlugin</name>
|
<name>UkuiSearch::AppSearchPlugin</name>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../libsearch/appsearch/app-search-plugin.cpp" line="11"/>
|
<location filename="../../libsearch/appsearch/app-search-plugin.cpp" line="11"/>
|
||||||
<location filename="../../libsearch/appsearch/app-search-plugin.cpp" line="174"/>
|
<location filename="../../libsearch/appsearch/app-search-plugin.cpp" line="231"/>
|
||||||
<source>Open</source>
|
<source>Open</source>
|
||||||
<translation>打开</translation>
|
<translation>打开</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../libsearch/appsearch/app-search-plugin.cpp" line="12"/>
|
<location filename="../../libsearch/appsearch/app-search-plugin.cpp" line="12"/>
|
||||||
<location filename="../../libsearch/appsearch/app-search-plugin.cpp" line="175"/>
|
<location filename="../../libsearch/appsearch/app-search-plugin.cpp" line="232"/>
|
||||||
<source>Add Shortcut to Desktop</source>
|
<source>Add Shortcut to Desktop</source>
|
||||||
<translation>添加到桌面快捷方式</translation>
|
<translation>添加到桌面快捷方式</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../libsearch/appsearch/app-search-plugin.cpp" line="13"/>
|
<location filename="../../libsearch/appsearch/app-search-plugin.cpp" line="13"/>
|
||||||
<location filename="../../libsearch/appsearch/app-search-plugin.cpp" line="176"/>
|
<location filename="../../libsearch/appsearch/app-search-plugin.cpp" line="233"/>
|
||||||
<source>Add Shortcut to Panel</source>
|
<source>Add Shortcut to Panel</source>
|
||||||
<translation>添加到任务栏快捷方式</translation>
|
<translation>添加到任务栏快捷方式</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../libsearch/appsearch/app-search-plugin.cpp" line="14"/>
|
<location filename="../../libsearch/appsearch/app-search-plugin.cpp" line="14"/>
|
||||||
<location filename="../../libsearch/appsearch/app-search-plugin.cpp" line="177"/>
|
<location filename="../../libsearch/appsearch/app-search-plugin.cpp" line="234"/>
|
||||||
<source>Install</source>
|
<source>Install</source>
|
||||||
<translation>安装</translation>
|
<translation>安装</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../libsearch/appsearch/app-search-plugin.cpp" line="30"/>
|
<location filename="../../libsearch/appsearch/app-search-plugin.cpp" line="73"/>
|
||||||
<location filename="../../libsearch/appsearch/app-search-plugin.cpp" line="35"/>
|
<location filename="../../libsearch/appsearch/app-search-plugin.cpp" line="78"/>
|
||||||
<source>Applications Search</source>
|
<source>Applications Search</source>
|
||||||
<translation>应用</translation>
|
<translation>应用</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../libsearch/appsearch/app-search-plugin.cpp" line="115"/>
|
<location filename="../../libsearch/appsearch/app-search-plugin.cpp" line="167"/>
|
||||||
<source>Application</source>
|
<source>Application</source>
|
||||||
<translation>应用</translation>
|
<translation>应用</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
|
<location filename="../../libsearch/appsearch/app-search-plugin.cpp" line="53"/>
|
||||||
<source>Application Description:</source>
|
<source>Application Description:</source>
|
||||||
<translation type="vanished">应用描述:</translation>
|
<translation>应用描述:</translation>
|
||||||
</message>
|
</message>
|
||||||
</context>
|
</context>
|
||||||
<context>
|
<context>
|
||||||
<name>UkuiSearch::AppSearchTask</name>
|
<name>UkuiSearch::AppSearchTask</name>
|
||||||
<message>
|
<message>
|
||||||
|
<location filename="../../libsearch/searchinterface/searchtasks/app-search-task.cpp" line="21"/>
|
||||||
<source>Application</source>
|
<source>Application</source>
|
||||||
<translation type="vanished">应用</translation>
|
<translation>应用</translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
|
<location filename="../../libsearch/searchinterface/searchtasks/app-search-task.cpp" line="26"/>
|
||||||
<source>Application search.</source>
|
<source>Application search.</source>
|
||||||
<translation type="vanished">应用搜索</translation>
|
<translation>应用搜索</translation>
|
||||||
</message>
|
</message>
|
||||||
</context>
|
</context>
|
||||||
<context>
|
<context>
|
||||||
|
@ -373,14 +375,14 @@
|
||||||
<context>
|
<context>
|
||||||
<name>UkuiSearch::SearchTaskPluginManager</name>
|
<name>UkuiSearch::SearchTaskPluginManager</name>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../libsearch/pluginmanage/search-task-plugin-manager.cpp" line="64"/>
|
<location filename="../../libsearch/pluginmanage/search-task-plugin-manager.cpp" line="68"/>
|
||||||
<location filename="../../libsearch/pluginmanage/search-task-plugin-manager.cpp" line="78"/>
|
<location filename="../../libsearch/pluginmanage/search-task-plugin-manager.cpp" line="82"/>
|
||||||
<source>plugin type: %1, is disabled!</source>
|
<source>plugin type: %1, is disabled!</source>
|
||||||
<translation type="unfinished"></translation>
|
<translation type="unfinished"></translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../../libsearch/pluginmanage/search-task-plugin-manager.cpp" line="70"/>
|
<location filename="../../libsearch/pluginmanage/search-task-plugin-manager.cpp" line="74"/>
|
||||||
<location filename="../../libsearch/pluginmanage/search-task-plugin-manager.cpp" line="83"/>
|
<location filename="../../libsearch/pluginmanage/search-task-plugin-manager.cpp" line="87"/>
|
||||||
<source>plugin type: %1, is not registered!</source>
|
<source>plugin type: %1, is not registered!</source>
|
||||||
<translation type="unfinished"></translation>
|
<translation type="unfinished"></translation>
|
||||||
</message>
|
</message>
|
||||||
|
@ -409,6 +411,14 @@
|
||||||
<translation>设置项</translation>
|
<translation>设置项</translation>
|
||||||
</message>
|
</message>
|
||||||
</context>
|
</context>
|
||||||
|
<context>
|
||||||
|
<name>UkuiSearch::UkuiSearchTaskPrivate</name>
|
||||||
|
<message>
|
||||||
|
<location filename="../../libsearch/searchinterface/ukui-search-task.cpp" line="92"/>
|
||||||
|
<source>Current task uuid error or an unregistered plugin is used!</source>
|
||||||
|
<translation type="unfinished"></translation>
|
||||||
|
</message>
|
||||||
|
</context>
|
||||||
<context>
|
<context>
|
||||||
<name>UkuiSearch::WebSearchPlugin</name>
|
<name>UkuiSearch::WebSearchPlugin</name>
|
||||||
<message>
|
<message>
|
||||||
|
@ -424,4 +434,13 @@
|
||||||
<translation>网页</translation>
|
<translation>网页</translation>
|
||||||
</message>
|
</message>
|
||||||
</context>
|
</context>
|
||||||
|
<context>
|
||||||
|
<name>search</name>
|
||||||
|
<message>
|
||||||
|
<location filename="../../libsearch/search-app-widget-plugin/provider/data/search.qml" line="89"/>
|
||||||
|
<source>search</source>
|
||||||
|
<translatorcomment>全局搜索</translatorcomment>
|
||||||
|
<translation>全局搜索</translation>
|
||||||
|
</message>
|
||||||
|
</context>
|
||||||
</TS>
|
</TS>
|
||||||
|
|
Loading…
Reference in New Issue