feat(settings): Optimize setting widget & add translations.

Description: 优化设置界面并添加翻译文件

Log: 优化设置界面并添加翻译文件
This commit is contained in:
zhangjiaping 2020-12-30 17:23:03 +08:00
parent c977d7291e
commit b8b51103f2
16 changed files with 586 additions and 603 deletions

View File

@ -95,6 +95,9 @@ QIcon FileUtils::getAppIcon(const QString &path) {
*/
QIcon FileUtils::getSettingIcon(const QString& setting, const bool& is_white) {
QString name = setting.left(setting.indexOf("/"));
if (! name.isEmpty()) {
name.replace(QString(name.at(0)), QString(name.at(0).toUpper()));
}
QString path;
if (is_white) {
path = QString("/usr/share/ukui-control-center/shell/res/secondaryleftmenu/%1White.svg").arg(name);

View File

@ -1,4 +1,5 @@
#include "gobject-template.h"
#include "glib-object.h"
std::shared_ptr<gobjecttemplate<GFile>> wrapGFile(GFile *file) {
return std::make_shared<gobjecttemplate<GFile>>(file);

View File

@ -11,7 +11,6 @@ HEADERS += \
$$PWD/inotify.h \
$$PWD/messagelist-manager.h \
$$PWD/traverse_bfs.h \
$$PWD/messagelist-manager.h \
$$PWD/text-content-indexer.h \
$$PWD/file-searcher.h

View File

@ -16,7 +16,7 @@ void SettingsMatch::xmlElement(){
QString pinyinIndex;
QString ChineseIndex;
QFile file(QString::fromLocal8Bit(":/res/search.xml"));
QFile file(QString::fromLocal8Bit("/usr/share/ukui-control-center/shell/res/search.xml"));
if (!file.open(QIODevice::ReadOnly)){
return;
}

View File

@ -2,6 +2,7 @@ INCLUDEPATH += $$PWD
HEADERS += \
$$PWD/config-file.h \
$$PWD/floder-list-item.h \
$$PWD/search-list-view.h \
$$PWD/search-detail-view.h \
$$PWD/option-view.h \
@ -9,6 +10,7 @@ HEADERS += \
SOURCES += \
$$PWD/config-file.cpp \
$$PWD/floder-list-item.cpp \
$$PWD/search-list-view.cpp \
$$PWD/search-detail-view.cpp \
$$PWD/option-view.cpp \

View File

@ -0,0 +1,82 @@
#include "floder-list-item.h"
#include <QIcon>
#include <QEvent>
FloderListItem::FloderListItem(QWidget *parent, const QString &path) : QWidget(parent)
{
m_path = path;
initUi();
}
FloderListItem::~FloderListItem()
{
}
/**
* @brief FloderListItem::initUi ui
*/
void FloderListItem::initUi() {
m_layout = new QVBoxLayout(this);
m_layout->setSpacing(0);
m_layout->setContentsMargins(0,0,0,0);
m_widget = new QWidget(this);
m_widget->setObjectName("mWidget");
this->setFixedHeight(32);
m_layout->addWidget(m_widget);
m_widgetlayout = new QHBoxLayout(m_widget);
m_widgetlayout->setContentsMargins(4, 4, 4, 4);
m_widget->setLayout(m_widgetlayout);
m_iconLabel = new QLabel(m_widget);
m_pathLabel = new QLabel(m_widget);
m_delLabel = new QLabel(m_widget);
m_iconLabel->setPixmap(QIcon::fromTheme("inode-directory").pixmap(QSize(16, 16)));
m_pathLabel->setText(m_path);
m_delLabel->setText(tr("Delete the floder out of blacklist"));
m_pathLabel->setStyleSheet("QLabel{color: palette(text); background: transparent;}");
m_delLabel->setStyleSheet("QLabel{color: #3790FA; background: transparent;}");
m_delLabel->setCursor(QCursor(Qt::PointingHandCursor));
m_delLabel->installEventFilter(this);
m_delLabel->hide();
m_widgetlayout->addWidget(m_iconLabel);
m_widgetlayout->addWidget(m_pathLabel);
m_widgetlayout->addStretch();
m_widgetlayout->addWidget(m_delLabel);
}
/**
* @brief FloderListItem::enterEvent
* @param event
*/
void FloderListItem::enterEvent(QEvent *event){
m_delLabel->show();
m_widget->setStyleSheet("QWidget#mWidget{background: rgba(0,0,0,0.1);}");
QWidget::enterEvent(event);
}
/**
* @brief FloderListItem::leaveEvent
* @param event
*/
void FloderListItem::leaveEvent(QEvent *event){
m_delLabel->hide();
m_widget->setStyleSheet("QWidget#mWidget{background: transparent;}");
QWidget::leaveEvent(event);
}
/**
* @brief FloderListItem::eventFilter
* @param watched
* @param event
* @return
*/
bool FloderListItem::eventFilter(QObject *watched, QEvent *event){
if (watched == m_delLabel) {
if (event->type() == QEvent::MouseButtonPress) {
// qDebug()<<"pressed!";
}
}
return QObject::eventFilter(watched, event);
}

View File

@ -0,0 +1,35 @@
#ifndef FLODERLISTITEM_H
#define FLODERLISTITEM_H
#include <QWidget>
#include <QHBoxLayout>
#include <QVBoxLayout>
#include <QLabel>
class FloderListItem : public QWidget
{
Q_OBJECT
public:
explicit FloderListItem(QWidget *parent = nullptr, const QString &path = 0);
~FloderListItem();
protected:
virtual void enterEvent(QEvent * event);
virtual void leaveEvent(QEvent * event);
bool eventFilter(QObject *, QEvent *);
private:
void initUi();
QString m_path;
QVBoxLayout * m_layout = nullptr;
QWidget * m_widget = nullptr;
QHBoxLayout * m_widgetlayout = nullptr;
QLabel * m_iconLabel = nullptr;
QLabel * m_pathLabel = nullptr;
QLabel * m_delLabel = nullptr;
Q_SIGNALS:
};
#endif // FLODERLISTITEM_H

View File

@ -65,6 +65,7 @@ void HomePageItem::setupUi(const int& type, const QString& path) {
m_namelabel->setText(FileUtils::getAppName(path));
break;
}
case SearchListView::ResType::Dir :
case SearchListView::ResType::File : {
icon = FileUtils::getFileIcon(QString("file://%1").arg(path));
m_namelabel->setText(FileUtils::getFileName(path));
@ -75,9 +76,6 @@ void HomePageItem::setupUi(const int& type, const QString& path) {
m_namelabel->setText(FileUtils::getSettingName(path));
break;
}
case SearchListView::ResType::Dir : {
break;
}
default :
break;
}

View File

@ -173,7 +173,7 @@ void MainWindow::initUi()
QStringList list;
list<<"/usr/share/applications/peony.desktop"<<"/usr/share/applications/ukui-control-center.desktop"<<"/usr/share/applications/ukui-clock.desktop"<<"/usr/share/applications/wps-office-pdf.desktop";
QStringList list2;
list2<<"/home/zjp/下载/搜索结果.png"<<"/home/zjp/下载/显示不全.mp4"<<"/home/zjp/下载/dmesg.log"<<"/home/zjp/下载/WiFi_AP选择.docx";
list2<<QString("%1/下载").arg(QDir::homePath())<<"/home/zjp/ukui/NM/v10/kylin-nm/README.md"<<"Theme/主题/更改壁纸"<<"/home/zjp/下载/WiFi_AP选择.docx";
QStringList list3;
list3<<"/usr/share/applications/peony.desktop"<<"/usr/share/applications/ukui-control-center.desktop"<<"Theme/主题/更改壁纸";

View File

@ -1,567 +0,0 @@
<plugins>
<plugin name="About">
<pinyinPlugin>guanyu</pinyinPlugin>
<pinyinfunc>banben</pinyinfunc>
<ChinesePlugin>关于</ChinesePlugin>
<ChineseFunc>版本</ChineseFunc>
</plugin>
<plugin name="About">
<pinyinPlugin>guanyu</pinyinPlugin>
<pinyinfunc>neihe</pinyinfunc>
<ChinesePlugin>关于</ChinesePlugin>
<ChineseFunc>内核</ChineseFunc>
</plugin>
<plugin name="About">
<ChinesePlugin>关于</ChinesePlugin>
<ChineseFunc>CPU</ChineseFunc>
</plugin>
<plugin name="About">
<pinyinPlugin>guanyu</pinyinPlugin>
<pinyinfunc>neicun</pinyinfunc>
<ChinesePlugin>关于</ChinesePlugin>
<ChineseFunc>内存</ChineseFunc>
</plugin>
<plugin name="About">
<pinyinPlugin>guanyu</pinyinPlugin>
<pinyinfunc>yingpan</pinyinfunc>
<ChinesePlugin>关于</ChinesePlugin>
<ChineseFunc>硬盘</ChineseFunc>
</plugin>
<plugin name="Area">
<pinyinPlugin>yuyanhediqu</pinyinPlugin>
<pinyinfunc>dangqianquyu</pinyinfunc>
<ChinesePlugin>语言和地区</ChinesePlugin>
<ChineseFunc>当前区域</ChineseFunc>
</plugin>
<plugin name="Area">
<pinyinPlugin>yuyanhediqu</pinyinPlugin>
<pinyinfunc>quyugeshishuju</pinyinfunc>
<ChinesePlugin>语言和地区</ChinesePlugin>
<ChineseFunc>区域格式数据</ChineseFunc>
</plugin>
<plugin name="Area">
<pinyinPlugin>yuyanhediqu</pinyinPlugin>
<pinyinfunc>shouxuanyuyan</pinyinfunc>
<ChinesePlugin>语言和地区</ChinesePlugin>
<ChineseFunc>首选语言</ChineseFunc>
</plugin>
<plugin name="Autoboot">
<pinyinPlugin>kaijiqidong</pinyinPlugin>
<pinyinfunc>morenchengxu</pinyinfunc>
<ChinesePlugin>开机启动</ChinesePlugin>
<ChineseFunc>默认程序</ChineseFunc>
</plugin>
<plugin name="Backup">
<pinyinPlugin>huifuchuchangshezhi</pinyinPlugin>
<pinyinfunc>huanyuan</pinyinfunc>
<ChinesePlugin>恢复出厂设置</ChinesePlugin>
<ChineseFunc>还原</ChineseFunc>
</plugin>
<plugin name="Datetime">
<pinyinPlugin>shijianheriqi</pinyinPlugin>
<pinyinfunc>tongbuxitongshijian</pinyinfunc>
<ChinesePlugin>时间和日期</ChinesePlugin>
<ChineseFunc>同步系统时间</ChineseFunc>
</plugin>
<plugin name="Datetime">
<pinyinPlugin>shijianheriqi</pinyinPlugin>
<pinyinfunc>shoudonggenggaishijian</pinyinfunc>
<ChinesePlugin>时间和日期</ChinesePlugin>
<ChineseFunc>手动更改时间</ChineseFunc>
</plugin>
<plugin name="Datetime">
<pinyinPlugin>shijianheriqi</pinyinPlugin>
<pinyinfunc>genggaishiqu</pinyinfunc>
<ChinesePlugin>时间和日期</ChinesePlugin>
<ChineseFunc>更改时区</ChineseFunc>
</plugin>
<plugin name="Datetime">
<pinyinPlugin>shijianheriqi</pinyinPlugin>
<pinyinfunc>xiaoshizhi</pinyinfunc>
<ChinesePlugin>时间和日期</ChinesePlugin>
<ChineseFunc>24小时制</ChineseFunc>
</plugin>
<plugin name="Defaultapp">
<pinyinPlugin>morenyingyong</pinyinPlugin>
<pinyinfunc>liulanqi</pinyinfunc>
<ChinesePlugin>默认应用</ChinesePlugin>
<ChineseFunc>浏览器</ChineseFunc>
</plugin>
<plugin name="Defaultapp">
<pinyinPlugin>morenyingyong</pinyinPlugin>
<pinyinfunc>dianziyoujian</pinyinfunc>
<ChinesePlugin>默认应用</ChinesePlugin>
<ChineseFunc>电子邮件</ChineseFunc>
</plugin>
<plugin name="Defaultapp">
<pinyinPlugin>morenyingyong</pinyinPlugin>
<pinyinfunc>tuxiangchakanqi</pinyinfunc>
<ChinesePlugin>默认应用</ChinesePlugin>
<ChineseFunc>图像查看器</ChineseFunc>
</plugin>
<plugin name="Defaultapp">
<pinyinPlugin>morenyingyong</pinyinPlugin>
<pinyinfunc>yinpinbofangqi</pinyinfunc>
<ChinesePlugin>默认应用</ChinesePlugin>
<ChineseFunc>音频播放器</ChineseFunc>
</plugin>
<plugin name="Defaultapp">
<pinyinPlugin>morenyingyong</pinyinPlugin>
<pinyinfunc>shipinbofangqi</pinyinfunc>
<ChinesePlugin>默认应用</ChinesePlugin>
<ChineseFunc>视频播放器</ChineseFunc>
</plugin>
<plugin name="Defaultapp">
<pinyinPlugin>morenyingyong</pinyinPlugin>
<pinyinfunc>wendangbianjiqi</pinyinfunc>
<ChinesePlugin>默认应用</ChinesePlugin>
<ChineseFunc>文档编辑器</ChineseFunc>
</plugin>
<plugin name="Desktop">
<pinyinPlugin>zhuomian</pinyinPlugin>
<pinyinfunc>xianshizaizhuomiandetubiao</pinyinfunc>
<ChinesePlugin>桌面</ChinesePlugin>
<ChineseFunc>显示在桌面的图标</ChineseFunc>
</plugin>
<plugin name="Desktop">
<pinyinPlugin>zhuomian</pinyinPlugin>
<pinyinfunc>xianshizaituopanshangdetubiao</pinyinfunc>
<ChinesePlugin>桌面</ChinesePlugin>
<ChineseFunc>显示在托盘上的图标</ChineseFunc>
</plugin>
<plugin name="Fonts">
<pinyinPlugin>ziti</pinyinPlugin>
<pinyinfunc>zitidaxiao</pinyinfunc>
<ChinesePlugin>字体</ChinesePlugin>
<ChineseFunc>字体大小</ChineseFunc>
</plugin>
<plugin name="Keyboard">
<pinyinPlugin>jianpan</pinyinPlugin>
<pinyinfunc>qiyonganjianzhongfushezhi</pinyinfunc>
<ChinesePlugin>键盘</ChinesePlugin>
<ChineseFunc>启用按键重复设置</ChineseFunc>
</plugin>
<plugin name="Keyboard">
<pinyinPlugin>jianpan</pinyinPlugin>
<pinyinfunc>yanchi</pinyinfunc>
<ChinesePlugin>键盘</ChinesePlugin>
<ChineseFunc>延迟</ChineseFunc>
</plugin>
<plugin name="Keyboard">
<pinyinPlugin>jianpan</pinyinPlugin>
<pinyinfunc>sudu</pinyinfunc>
<ChinesePlugin>键盘</ChinesePlugin>
<ChineseFunc>速度</ChineseFunc>
</plugin>
<plugin name="Keyboard">
<pinyinPlugin>jianpan</pinyinPlugin>
<pinyinfunc>shuruzifuceshizhongfuxiaoguo:</pinyinfunc>
<ChinesePlugin>键盘</ChinesePlugin>
<ChineseFunc>输入字符测试重复效果:</ChineseFunc>
</plugin>
<plugin name="Keyboard">
<pinyinPlugin>jianpan</pinyinPlugin>
<pinyinfunc>daxiesuodingtishi</pinyinfunc>
<ChinesePlugin>键盘</ChinesePlugin>
<ChineseFunc>大写锁定提示</ChineseFunc>
</plugin>
<plugin name="Keyboard">
<pinyinPlugin>jianpan</pinyinPlugin>
<pinyinfunc>huifumorenbuju</pinyinfunc>
<ChinesePlugin>键盘</ChinesePlugin>
<ChineseFunc>恢复默认布局</ChineseFunc>
</plugin>
<plugin name="Keyboard">
<pinyinPlugin>jianpan</pinyinPlugin>
<pinyinfunc>jianpanbuju</pinyinfunc>
<ChinesePlugin>键盘</ChinesePlugin>
<ChineseFunc>键盘布局</ChineseFunc>
</plugin>
<plugin name="Mouse">
<pinyinPlugin>shubiao</pinyinPlugin>
<pinyinfunc>guanyongshou</pinyinfunc>
<ChinesePlugin>鼠标</ChinesePlugin>
<ChineseFunc>惯用手</ChineseFunc>
</plugin>
<plugin name="Mouse">
<pinyinPlugin>shubiao</pinyinPlugin>
<pinyinfunc>sudu</pinyinfunc>
<ChinesePlugin>鼠标</ChinesePlugin>
<ChineseFunc>速度</ChineseFunc>
</plugin>
<plugin name="Mouse">
<pinyinPlugin>shubiao</pinyinPlugin>
<pinyinfunc>shubiaoshuangjijiangeshichang</pinyinfunc>
<ChinesePlugin>鼠标</ChinesePlugin>
<ChineseFunc>鼠标双击间隔时长</ChineseFunc>
</plugin>
<plugin name="Mouse">
<pinyinPlugin>shubiao</pinyinPlugin>
<pinyinfunc>mingandu</pinyinfunc>
<ChinesePlugin>鼠标</ChinesePlugin>
<ChineseFunc>敏感度</ChineseFunc>
</plugin>
<plugin name="Mouse">
<pinyinPlugin>shubiao</pinyinPlugin>
<pinyinfunc>kejianxing</pinyinfunc>
<ChinesePlugin>鼠标</ChinesePlugin>
<ChineseFunc>可见性</ChineseFunc>
</plugin>
<plugin name="Mouse">
<pinyinPlugin>shubiao</pinyinPlugin>
<pinyinfunc>zhizhendaxiao</pinyinfunc>
<ChinesePlugin>鼠标</ChinesePlugin>
<ChineseFunc>指针大小</ChineseFunc>
</plugin>
<plugin name="Mouse">
<pinyinPlugin>shubiao</pinyinPlugin>
<pinyinfunc>guangbiaosudu</pinyinfunc>
<ChinesePlugin>鼠标</ChinesePlugin>
<ChineseFunc>光标速度</ChineseFunc>
</plugin>
<plugin name="Mouse">
<pinyinPlugin>shubiao</pinyinPlugin>
<pinyinfunc>qiyongwenbenquyudeguangbiaoshanshuo</pinyinfunc>
<ChinesePlugin>鼠标</ChinesePlugin>
<ChineseFunc>启用文本区域的光标闪烁</ChineseFunc>
</plugin>
<plugin name="Netconnect">
<pinyinPlugin>wangluolianjie</pinyinPlugin>
<pinyinfunc>wangluozhuangtai</pinyinfunc>
<ChinesePlugin>网络连接</ChinesePlugin>
<ChineseFunc>网络状态</ChineseFunc>
</plugin>
<plugin name="Netconnect">
<ChinesePlugin>网络连接</ChinesePlugin>
<ChineseFunc>打开wifi</ChineseFunc>
</plugin>
<plugin name="Notice">
<pinyinPlugin>tongzhi</pinyinPlugin>
<pinyinfunc>shezhizaitongzhizhongxinxianshidetongzhixinxi</pinyinfunc>
<ChinesePlugin>通知</ChinesePlugin>
<ChineseFunc>设置在通知中心显示的通知信息</ChineseFunc>
</plugin>
<plugin name="Notice">
<pinyinPlugin>tongzhi</pinyinPlugin>
<pinyinfunc>shezhitongzhilaiyuan</pinyinfunc>
<ChinesePlugin>通知</ChinesePlugin>
<ChineseFunc>设置通知来源</ChineseFunc>
</plugin>
<plugin name="Display">
<pinyinPlugin>xianshiqi</pinyinPlugin>
<pinyinfunc>fenbianlv</pinyinfunc>
<ChinesePlugin>显示器</ChinesePlugin>
<ChineseFunc>分辨率</ChineseFunc>
</plugin>
<plugin name="Display">
<pinyinPlugin>xianshiqi</pinyinPlugin>
<pinyinfunc>suofangpingmu</pinyinfunc>
<ChinesePlugin>显示器</ChinesePlugin>
<ChineseFunc>缩放屏幕</ChineseFunc>
</plugin>
<plugin name="Power">
<pinyinPlugin>dianyuan</pinyinPlugin>
<pinyinfunc>pingheng(tuijian)</pinyinfunc>
<ChinesePlugin>电源</ChinesePlugin>
<ChineseFunc>平衡(推荐)</ChineseFunc>
</plugin>
<plugin name="Power">
<pinyinPlugin>dianyuan</pinyinPlugin>
<pinyinfunc>jieneng</pinyinfunc>
<ChinesePlugin>电源</ChinesePlugin>
<ChineseFunc>节能</ChineseFunc>
</plugin>
<plugin name="Power">
<pinyinPlugin>dianyuan</pinyinPlugin>
<pinyinfunc>zidingyi</pinyinfunc>
<ChinesePlugin>电源</ChinesePlugin>
<ChineseFunc>自定义</ChineseFunc>
</plugin>
<plugin name="Printer">
<pinyinPlugin>dayinji</pinyinPlugin>
<pinyinfunc>tianjiadayinjihesaomiaoyi</pinyinfunc>
<ChinesePlugin>打印机</ChinesePlugin>
<ChineseFunc>添加打印机和扫描仪</ChineseFunc>
</plugin>
<plugin name="Printer">
<pinyinPlugin>dayinji</pinyinPlugin>
<pinyinfunc>tianjiadayinjihesaomiaoyi</pinyinfunc>
<ChinesePlugin>打印机</ChinesePlugin>
<ChineseFunc>添加打印机和扫描仪</ChineseFunc>
</plugin>
<plugin name="Proxy">
<pinyinPlugin>daili</pinyinPlugin>
<pinyinfunc>kaiqizidongdaili</pinyinfunc>
<ChinesePlugin>代理</ChinesePlugin>
<ChineseFunc>开启自动代理</ChineseFunc>
</plugin>
<plugin name="Proxy">
<pinyinPlugin>daili</pinyinPlugin>
<pinyinfunc>kaiqishoudongdaili</pinyinfunc>
<ChinesePlugin>代理</ChinesePlugin>
<ChineseFunc>开启手动代理</ChineseFunc>
</plugin>
<plugin name="Screenlock">
<pinyinPlugin>suoping</pinyinPlugin>
<pinyinfunc>suopingshixianshiweiduxiaoxishu</pinyinfunc>
<ChinesePlugin>锁屏</ChinesePlugin>
<ChineseFunc>锁屏时显示未读消息数</ChineseFunc>
</plugin>
<plugin name="Screenlock">
<pinyinPlugin>suoping</pinyinPlugin>
<pinyinfunc>jihuopingbaoshisuodingpingmu</pinyinfunc>
<ChinesePlugin>锁屏</ChinesePlugin>
<ChineseFunc>激活屏保时锁定屏幕</ChineseFunc>
</plugin>
<plugin name="Screenlock">
<pinyinPlugin>suoping</pinyinPlugin>
<pinyinfunc>xianshisuopingbizhizaidengluyemian</pinyinfunc>
<ChinesePlugin>锁屏</ChinesePlugin>
<ChineseFunc>显示锁屏壁纸在登录页面</ChineseFunc>
</plugin>
<plugin name="Screensaver">
<pinyinPlugin>pingbao</pinyinPlugin>
<pinyinfunc>kaiqipingbao</pinyinfunc>
<ChinesePlugin>屏保</ChinesePlugin>
<ChineseFunc>开启屏保</ChineseFunc>
</plugin>
<plugin name="Screensaver">
<pinyinPlugin>pingbao</pinyinPlugin>
<pinyinfunc>pingmubaohuchengxu</pinyinfunc>
<ChinesePlugin>屏保</ChinesePlugin>
<ChineseFunc>屏幕保护程序</ChineseFunc>
</plugin>
<plugin name="Screensaver">
<pinyinPlugin>pingbao</pinyinPlugin>
<pinyinfunc>dengdaishijian</pinyinfunc>
<ChinesePlugin>屏保</ChinesePlugin>
<ChineseFunc>等待时间</ChineseFunc>
</plugin>
<plugin name="Shortcut">
<pinyinPlugin>kuaijiejian</pinyinPlugin>
<pinyinfunc>xitongkuaijiejian</pinyinfunc>
<ChinesePlugin>快捷键</ChinesePlugin>
<ChineseFunc>系统快捷键</ChineseFunc>
</plugin>
<plugin name="Shortcut">
<pinyinPlugin>kuaijiejian</pinyinPlugin>
<pinyinfunc>zidingyikuaijiejian</pinyinfunc>
<ChinesePlugin>快捷键</ChinesePlugin>
<ChineseFunc>自定义快捷键</ChineseFunc>
</plugin>
<plugin name="Shortcut">
<pinyinPlugin>kuaijiejian</pinyinPlugin>
<pinyinfunc>tianjiazidingyikuaijiejian</pinyinfunc>
<ChinesePlugin>快捷键</ChinesePlugin>
<ChineseFunc>添加自定义快捷键</ChineseFunc>
</plugin>
<plugin name="Theme">
<pinyinPlugin>zhuti</pinyinPlugin>
<pinyinfunc>zhutimoshi</pinyinfunc>
<ChinesePlugin>主题</ChinesePlugin>
<ChineseFunc>主题模式</ChineseFunc>
</plugin>
<plugin name="Theme">
<pinyinPlugin>zhuti</pinyinPlugin>
<pinyinfunc>xitong</pinyinfunc>
<ChinesePlugin>主题</ChinesePlugin>
<ChineseFunc>系统</ChineseFunc>
</plugin>
<plugin name="Theme">
<pinyinPlugin>zhuti</pinyinPlugin>
<pinyinfunc>qianse</pinyinfunc>
<ChinesePlugin>主题</ChinesePlugin>
<ChineseFunc>浅色</ChineseFunc>
</plugin>
<plugin name="Theme">
<pinyinPlugin>zhuti</pinyinPlugin>
<pinyinfunc>toumingxiaoguo</pinyinfunc>
<ChinesePlugin>主题</ChinesePlugin>
<ChineseFunc>透明效果</ChineseFunc>
</plugin>
<plugin name="Theme">
<pinyinPlugin>zhuti</pinyinPlugin>
<pinyinfunc>shense</pinyinfunc>
<ChinesePlugin>主题</ChinesePlugin>
<ChineseFunc>深色</ChineseFunc>
</plugin>
<plugin name="Theme">
<pinyinPlugin>zhuti</pinyinPlugin>
<pinyinfunc>tubiaozhuti</pinyinfunc>
<ChinesePlugin>主题</ChinesePlugin>
<ChineseFunc>图标主题</ChineseFunc>
</plugin>
<plugin name="Theme">
<pinyinPlugin>zhuti</pinyinPlugin>
<pinyinfunc>guangbiaozhuti</pinyinfunc>
<ChinesePlugin>主题</ChinesePlugin>
<ChineseFunc>光标主题</ChineseFunc>
</plugin>
<plugin name="Theme">
<pinyinPlugin>zhuti</pinyinPlugin>
<pinyinfunc>toumingdu</pinyinfunc>
<ChinesePlugin>主题</ChinesePlugin>
<ChineseFunc>透明度</ChineseFunc>
</plugin>
<plugin name="Theme">
<pinyinPlugin>zhuti</pinyinPlugin>
<pinyinfunc>di</pinyinfunc>
<ChinesePlugin>主题</ChinesePlugin>
<ChineseFunc></ChineseFunc>
</plugin>
<plugin name="Theme">
<pinyinPlugin>zhuti</pinyinPlugin>
<pinyinfunc>gao</pinyinfunc>
<ChinesePlugin>主题</ChinesePlugin>
<ChineseFunc></ChineseFunc>
</plugin>
<plugin name="Touchpad">
<pinyinPlugin>chumoban</pinyinPlugin>
<pinyinfunc>chumobanshezhi</pinyinfunc>
<ChinesePlugin>触摸板</ChinesePlugin>
<ChineseFunc>触摸板设置</ChineseFunc>
</plugin>
<plugin name="Audio">
<pinyinPlugin>shengyin</pinyinPlugin>
<pinyinfunc>xuanzeshurushebei</pinyinfunc>
<ChinesePlugin>声音</ChinesePlugin>
<ChineseFunc>选择输入设备</ChineseFunc>
</plugin>
<plugin name="Audio">
<pinyinPlugin>shengyin</pinyinPlugin>
<pinyinfunc>yinliangdaxiao</pinyinfunc>
<ChinesePlugin>声音</ChinesePlugin>
<ChineseFunc>音量大小</ChineseFunc>
</plugin>
<plugin name="Audio">
<pinyinPlugin>shengyin</pinyinPlugin>
<pinyinfunc>shurudengji</pinyinfunc>
<ChinesePlugin>声音</ChinesePlugin>
<ChineseFunc>输入等级</ChineseFunc>
</plugin>
<plugin name="Audio">
<pinyinPlugin>shengyin</pinyinPlugin>
<pinyinfunc>xuanzeshuchushebei</pinyinfunc>
<ChinesePlugin>声音</ChinesePlugin>
<ChineseFunc>选择输出设备</ChineseFunc>
</plugin>
<plugin name="Audio">
<pinyinPlugin>shengyin</pinyinPlugin>
<pinyinfunc>zhuyinliangdaxiao</pinyinfunc>
<ChinesePlugin>声音</ChinesePlugin>
<ChineseFunc>主音量大小</ChineseFunc>
</plugin>
<plugin name="Audio">
<pinyinPlugin>shengyin</pinyinPlugin>
<pinyinfunc>shengdaopingheng</pinyinfunc>
<ChinesePlugin>声音</ChinesePlugin>
<ChineseFunc>声道平衡</ChineseFunc>
</plugin>
<plugin name="Audio">
<pinyinPlugin>shengyin</pinyinPlugin>
<pinyinfunc>peizhi</pinyinfunc>
<ChinesePlugin>声音</ChinesePlugin>
<ChineseFunc>配置</ChineseFunc>
</plugin>
<plugin name="Audio">
<pinyinPlugin>shengyin</pinyinPlugin>
<pinyinfunc>shengqia</pinyinfunc>
<ChinesePlugin>声音</ChinesePlugin>
<ChineseFunc>声卡</ChineseFunc>
</plugin>
<plugin name="Audio">
<pinyinPlugin>shengyin</pinyinPlugin>
<pinyinfunc>xitongyinxiao</pinyinfunc>
<ChinesePlugin>声音</ChinesePlugin>
<ChineseFunc>系统音效</ChineseFunc>
</plugin>
<plugin name="Audio">
<pinyinPlugin>shengyin</pinyinPlugin>
<pinyinfunc>xitongyinxiaozhuti</pinyinfunc>
<ChinesePlugin>声音</ChinesePlugin>
<ChineseFunc>系统音效主题</ChineseFunc>
</plugin>
<plugin name="Audio">
<pinyinPlugin>shengyin</pinyinPlugin>
<pinyinfunc>tishiyin</pinyinfunc>
<ChinesePlugin>声音</ChinesePlugin>
<ChineseFunc>提示音</ChineseFunc>
</plugin>
<plugin name="Audio">
<pinyinPlugin>shengyin</pinyinPlugin>
<pinyinfunc>kaiguanjiyinle</pinyinfunc>
<ChinesePlugin>声音</ChinesePlugin>
<ChineseFunc>开关机音乐</ChineseFunc>
</plugin>
<plugin name="Audio">
<pinyinPlugin>shengyin</pinyinPlugin>
<pinyinfunc>tishiyinliangkaiguan</pinyinfunc>
<ChinesePlugin>声音</ChinesePlugin>
<ChineseFunc>提示音量开关</ChineseFunc>
</plugin>
<plugin name="Display">
<pinyinPlugin>xianshiqi</pinyinPlugin>
<pinyinfunc>suofangpingmu</pinyinfunc>
<ChinesePlugin>显示器</ChinesePlugin>
<ChineseFunc>缩放屏幕</ChineseFunc>
</plugin>
<plugin name="Update">
<pinyinPlugin>gengxin</pinyinPlugin>
<pinyinfunc>xitonggengxin</pinyinfunc>
<ChinesePlugin>更新</ChinesePlugin>
<ChineseFunc>系统更新</ChineseFunc>
</plugin>
<plugin name="Userinfo">
<pinyinPlugin>zhanghuxinxi</pinyinPlugin>
<pinyinfunc>mimashixiao</pinyinfunc>
<ChinesePlugin>账户信息</ChinesePlugin>
<ChineseFunc>密码时效</ChineseFunc>
</plugin>
<plugin name="Userinfo">
<pinyinPlugin>zhanghuxinxi</pinyinPlugin>
<pinyinfunc>mianmidenglu</pinyinfunc>
<ChinesePlugin>账户信息</ChinesePlugin>
<ChineseFunc>免密登录</ChineseFunc>
</plugin>
<plugin name="Userinfo">
<pinyinPlugin>zhanghuxinxi</pinyinPlugin>
<pinyinfunc>zidongdenglu</pinyinfunc>
<ChinesePlugin>账户信息</ChinesePlugin>
<ChineseFunc>自动登录</ChineseFunc>
</plugin>
<plugin name="Vpn">
<ChinesePlugin>VPN</ChinesePlugin>
<ChineseFunc>添加VPN连接</ChineseFunc>
</plugin>
<plugin name="Wallpaper">
<pinyinPlugin>beijing</pinyinPlugin>
<pinyinfunc>liulanbendibizhi</pinyinfunc>
<ChinesePlugin>背景</ChinesePlugin>
<ChineseFunc>浏览本地壁纸</ChineseFunc>
</plugin>
<plugin name="Wallpaper">
<pinyinPlugin>beijing</pinyinPlugin>
<pinyinfunc>huifumorenshezhi</pinyinfunc>
<ChinesePlugin>背景</ChinesePlugin>
<ChineseFunc>恢复默认设置</ChineseFunc>
</plugin>
<plugin name="Wallpaper">
<pinyinPlugin>beijing</pinyinPlugin>
<pinyinfunc>liulanxianshangbizhi</pinyinfunc>
<ChinesePlugin>背景</ChinesePlugin>
<ChineseFunc>浏览线上壁纸</ChineseFunc>
</plugin>
<plugin name="Display">
<pinyinPlugin>xianshiqi</pinyinPlugin>
<pinyinfunc>tongyishuchu</pinyinfunc>
<ChinesePlugin>显示器</ChinesePlugin>
<ChineseFunc>统一输出</ChineseFunc>
</plugin>
<plugin name="Display">
<pinyinPlugin>xianshiqi</pinyinPlugin>
<pinyinfunc>yejianmoshi</pinyinfunc>
<ChinesePlugin>显示器</ChinesePlugin>
<ChineseFunc>夜间模式</ChineseFunc>
</plugin>
</plugins>

View File

@ -4,35 +4,63 @@
<context>
<name>ContentWidget</name>
<message>
<location filename="../../src/content-widget.cpp" line="121"/>
<location filename="../../src/content-widget.cpp" line="80"/>
<source>Recently Opened</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/content-widget.cpp" line="99"/>
<source>Open Quickly</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/content-widget.cpp" line="104"/>
<source>Commonly Used</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/content-widget.cpp" line="212"/>
<source>Apps</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/content-widget.cpp" line="123"/>
<location filename="../../src/content-widget.cpp" line="214"/>
<source>Settings</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/content-widget.cpp" line="125"/>
<location filename="../../src/content-widget.cpp" line="216"/>
<source>Files</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/content-widget.cpp" line="127"/>
<location filename="../../src/content-widget.cpp" line="218"/>
<source>Dirs</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/content-widget.cpp" line="220"/>
<source>Best Matches</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/content-widget.cpp" line="129"/>
<location filename="../../src/content-widget.cpp" line="222"/>
<source>Unknown</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>FloderListItem</name>
<message>
<location filename="../../control/floder-list-item.cpp" line="36"/>
<source>Delete the floder out of blacklist</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>MainWindow</name>
<message>
<location filename="../../src/mainwindow.cpp" line="103"/>
<location filename="../../src/mainwindow.cpp" line="125"/>
<source>Search</source>
<translation type="unfinished"></translation>
</message>
@ -68,7 +96,7 @@
<context>
<name>QObject</name>
<message>
<location filename="../../src/main.cpp" line="58"/>
<location filename="../../src/main.cpp" line="71"/>
<source>ukui-search is already running!</source>
<translation type="unfinished"></translation>
</message>
@ -76,14 +104,113 @@
<context>
<name>SearchDetailView</name>
<message>
<location filename="../../control/search-detail-view.cpp" line="85"/>
<location filename="../../control/search-detail-view.cpp" line="97"/>
<source>Path</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../control/search-detail-view.cpp" line="106"/>
<source>Last time modified</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../control/search-detail-view.cpp" line="139"/>
<source>Application</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../control/search-detail-view.cpp" line="92"/>
<location filename="../../control/search-detail-view.cpp" line="147"/>
<source>Document</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>SettingsWidget</name>
<message>
<location filename="../../src/settings-widget.cpp" line="49"/>
<source>Search</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/settings-widget.cpp" line="66"/>
<source>Settings</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/settings-widget.cpp" line="72"/>
<source>Index State</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/settings-widget.cpp" line="75"/>
<location filename="../../src/settings-widget.cpp" line="77"/>
<source>...</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/settings-widget.cpp" line="84"/>
<source>File Index Settings</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/settings-widget.cpp" line="87"/>
<source>Following folders will not be searched. You can set it by adding and removing folders.</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/settings-widget.cpp" line="96"/>
<source>Add ignored folders</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/settings-widget.cpp" line="117"/>
<source>Search Engine Settings</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/settings-widget.cpp" line="120"/>
<source>Please select search engine you preferred.</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/settings-widget.cpp" line="133"/>
<source>baidu</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/settings-widget.cpp" line="135"/>
<source>sougou</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/settings-widget.cpp" line="137"/>
<source>360</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/settings-widget.cpp" line="160"/>
<source>Cancel</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/settings-widget.cpp" line="164"/>
<source>Confirm</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/settings-widget.cpp" line="194"/>
<source>Creating ...</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/settings-widget.cpp" line="197"/>
<source>Done</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/settings-widget.cpp" line="205"/>
<source>Index Entry: %1</source>
<translation type="unfinished"></translation>
</message>
</context>
</TS>

View File

@ -4,35 +4,63 @@
<context>
<name>ContentWidget</name>
<message>
<location filename="../../src/content-widget.cpp" line="121"/>
<location filename="../../src/content-widget.cpp" line="80"/>
<source>Recently Opened</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/content-widget.cpp" line="99"/>
<source>Open Quickly</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/content-widget.cpp" line="104"/>
<source>Commonly Used</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/content-widget.cpp" line="212"/>
<source>Apps</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/content-widget.cpp" line="123"/>
<location filename="../../src/content-widget.cpp" line="214"/>
<source>Settings</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/content-widget.cpp" line="125"/>
<location filename="../../src/content-widget.cpp" line="216"/>
<source>Files</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/content-widget.cpp" line="127"/>
<location filename="../../src/content-widget.cpp" line="218"/>
<source>Dirs</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/content-widget.cpp" line="220"/>
<source>Best Matches</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/content-widget.cpp" line="129"/>
<location filename="../../src/content-widget.cpp" line="222"/>
<source>Unknown</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>FloderListItem</name>
<message>
<location filename="../../control/floder-list-item.cpp" line="36"/>
<source>Delete the floder out of blacklist</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>MainWindow</name>
<message>
<location filename="../../src/mainwindow.cpp" line="103"/>
<location filename="../../src/mainwindow.cpp" line="125"/>
<source>Search</source>
<translation type="unfinished"></translation>
</message>
@ -68,7 +96,7 @@
<context>
<name>QObject</name>
<message>
<location filename="../../src/main.cpp" line="58"/>
<location filename="../../src/main.cpp" line="71"/>
<source>ukui-search is already running!</source>
<translation type="unfinished"></translation>
</message>
@ -76,14 +104,113 @@
<context>
<name>SearchDetailView</name>
<message>
<location filename="../../control/search-detail-view.cpp" line="85"/>
<location filename="../../control/search-detail-view.cpp" line="97"/>
<source>Path</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../control/search-detail-view.cpp" line="106"/>
<source>Last time modified</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../control/search-detail-view.cpp" line="139"/>
<source>Application</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../control/search-detail-view.cpp" line="92"/>
<location filename="../../control/search-detail-view.cpp" line="147"/>
<source>Document</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>SettingsWidget</name>
<message>
<location filename="../../src/settings-widget.cpp" line="49"/>
<source>Search</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/settings-widget.cpp" line="66"/>
<source>Settings</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/settings-widget.cpp" line="72"/>
<source>Index State</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/settings-widget.cpp" line="75"/>
<location filename="../../src/settings-widget.cpp" line="77"/>
<source>...</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/settings-widget.cpp" line="84"/>
<source>File Index Settings</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/settings-widget.cpp" line="87"/>
<source>Following folders will not be searched. You can set it by adding and removing folders.</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/settings-widget.cpp" line="96"/>
<source>Add ignored folders</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/settings-widget.cpp" line="117"/>
<source>Search Engine Settings</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/settings-widget.cpp" line="120"/>
<source>Please select search engine you preferred.</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/settings-widget.cpp" line="133"/>
<source>baidu</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/settings-widget.cpp" line="135"/>
<source>sougou</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/settings-widget.cpp" line="137"/>
<source>360</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/settings-widget.cpp" line="160"/>
<source>Cancel</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/settings-widget.cpp" line="164"/>
<source>Confirm</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/settings-widget.cpp" line="194"/>
<source>Creating ...</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/settings-widget.cpp" line="197"/>
<source>Done</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/settings-widget.cpp" line="205"/>
<source>Index Entry: %1</source>
<translation type="unfinished"></translation>
</message>
</context>
</TS>

View File

@ -4,37 +4,65 @@
<context>
<name>ContentWidget</name>
<message>
<location filename="../../src/content-widget.cpp" line="121"/>
<location filename="../../src/content-widget.cpp" line="80"/>
<source>Recently Opened</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/content-widget.cpp" line="99"/>
<source>Open Quickly</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/content-widget.cpp" line="104"/>
<source>Commonly Used</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/content-widget.cpp" line="212"/>
<source>Apps</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/content-widget.cpp" line="123"/>
<location filename="../../src/content-widget.cpp" line="214"/>
<source>Settings</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/content-widget.cpp" line="125"/>
<location filename="../../src/content-widget.cpp" line="216"/>
<source>Files</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/content-widget.cpp" line="127"/>
<location filename="../../src/content-widget.cpp" line="218"/>
<source>Dirs</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/content-widget.cpp" line="220"/>
<source>Best Matches</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/content-widget.cpp" line="129"/>
<location filename="../../src/content-widget.cpp" line="222"/>
<source>Unknown</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>FloderListItem</name>
<message>
<location filename="../../control/floder-list-item.cpp" line="36"/>
<source>Delete the floder out of blacklist</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>MainWindow</name>
<message>
<location filename="../../src/mainwindow.cpp" line="103"/>
<location filename="../../src/mainwindow.cpp" line="125"/>
<source>Search</source>
<translation type="unfinished"></translation>
<translation type="unfinished"></translation>
</message>
</context>
<context>
@ -68,7 +96,7 @@
<context>
<name>QObject</name>
<message>
<location filename="../../src/main.cpp" line="58"/>
<location filename="../../src/main.cpp" line="71"/>
<source>ukui-search is already running!</source>
<translation type="unfinished"></translation>
</message>
@ -76,14 +104,113 @@
<context>
<name>SearchDetailView</name>
<message>
<location filename="../../control/search-detail-view.cpp" line="85"/>
<location filename="../../control/search-detail-view.cpp" line="97"/>
<source>Path</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../control/search-detail-view.cpp" line="106"/>
<source>Last time modified</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../control/search-detail-view.cpp" line="139"/>
<source>Application</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../control/search-detail-view.cpp" line="92"/>
<location filename="../../control/search-detail-view.cpp" line="147"/>
<source>Document</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>SettingsWidget</name>
<message>
<location filename="../../src/settings-widget.cpp" line="49"/>
<source>Search</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/settings-widget.cpp" line="66"/>
<source>Settings</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/settings-widget.cpp" line="72"/>
<source>Index State</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/settings-widget.cpp" line="75"/>
<location filename="../../src/settings-widget.cpp" line="77"/>
<source>...</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/settings-widget.cpp" line="84"/>
<source>File Index Settings</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/settings-widget.cpp" line="87"/>
<source>Following folders will not be searched. You can set it by adding and removing folders.</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/settings-widget.cpp" line="96"/>
<source>Add ignored folders</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/settings-widget.cpp" line="117"/>
<source>Search Engine Settings</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/settings-widget.cpp" line="120"/>
<source>Please select search engine you preferred.</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/settings-widget.cpp" line="133"/>
<source>baidu</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/settings-widget.cpp" line="135"/>
<source>sougou</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/settings-widget.cpp" line="137"/>
<source>360</source>
<translation type="unfinished">360</translation>
</message>
<message>
<location filename="../../src/settings-widget.cpp" line="160"/>
<source>Cancel</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/settings-widget.cpp" line="164"/>
<source>Confirm</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/settings-widget.cpp" line="194"/>
<source>Creating ...</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/settings-widget.cpp" line="197"/>
<source>Done</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../../src/settings-widget.cpp" line="205"/>
<source>Index Entry: %1</source>
<translation type="unfinished">: %1</translation>
</message>
</context>
</TS>

View File

@ -6,7 +6,6 @@
<file>res/translations/tr.ts</file>
<file>res/translations/zh_CN.ts</file>
<file>res/icons/desktop.png</file>
<file>res/search.xml</file>
<file>res/icons/close.svg</file>
</qresource>
</RCC>

View File

@ -1,6 +1,10 @@
#include "settings-widget.h"
#include <QPainter>
#include <QPainterPath>
#include <QFileDialog>
#include <QDir>
#include <QDebug>
#include "floder-list-item.h"
extern void qt_blurImage(QImage &blurImage, qreal radius, bool quality, int transposed);
SettingsWidget::SettingsWidget(QWidget *parent) : QWidget(parent)
@ -8,6 +12,12 @@ SettingsWidget::SettingsWidget(QWidget *parent) : QWidget(parent)
this->setWindowFlags(Qt::CustomizeWindowHint | Qt::FramelessWindowHint);
this->setAttribute(Qt::WA_TranslucentBackground);
initUi();
QStringList list;
list<<"/usr/share/applications"<<"/usr/share/icons"<<
"/usr/libs"<<"/home/zjp/UKUI/SEARCH"<<
"/home/zjp/UKUI/UKCC"<<"/home/zjp/UKUI/SD/intel/ukui-settings-daemon"<<
"/home/zjp/下载"<<"/home/zjp/code";
setupBlackList(list);
}
SettingsWidget::~SettingsWidget()
@ -88,6 +98,15 @@ void SettingsWidget::initUi() {
m_indexBtnLyt->addWidget(m_addDirBtn);
m_indexBtnLyt->addStretch();
m_dirListArea = new QScrollArea(this);
m_dirListArea->setStyleSheet("QScrollArea{background:transparent;}");
m_dirListWidget = new QWidget(this);
m_dirListWidget->setStyleSheet("QWidget{background:transparent;}");
m_dirListLyt = new QVBoxLayout(m_dirListWidget);
m_dirListLyt->setContentsMargins(0, 0, 0, 0);
m_dirListLyt->setSpacing(0);
m_dirListWidget->setLayout(m_dirListLyt);
m_dirListArea->setWidget(m_dirListWidget);
m_dirListArea->setWidgetResizable(true);
m_mainLyt->addWidget(m_indexSettingLabel);
m_mainLyt->addWidget(m_indexDescLabel);
m_mainLyt->addWidget(m_indexBtnFrame);
@ -153,6 +172,19 @@ void SettingsWidget::initUi() {
m_mainLyt->addStretch();
}
/**
* @brief SettingsWidget::setupBlackList
* @param list
*/
void SettingsWidget::setupBlackList(const QStringList& list) {
Q_FOREACH(QString path, list) {
FloderListItem * item = new FloderListItem(m_dirListWidget, path);
m_dirListLyt->addWidget(item);
item->setMaximumWidth(470);
}
m_dirListLyt->addStretch();
}
/**
* @brief setIndexState
* @param isCreatingIndex
@ -191,9 +223,24 @@ void SettingsWidget::onBtnCancelClicked() {
* @brief SettingsWidget::onBtnAddClicked
*/
void SettingsWidget::onBtnAddClicked() {
QFileDialog * fileDialog = new QFileDialog(this);
// fileDialog->setFileMode(QFileDialog::Directory); //允许查看文件和文件夹,但只允许选择文件夹
fileDialog->setFileMode(QFileDialog::DirectoryOnly); //只允许查看文件夹
fileDialog->setViewMode(QFileDialog::Detail);
fileDialog->setDirectory(QDir::homePath());
if (fileDialog->exec() != QDialog::Accepted) {
fileDialog->deleteLater();
return;
}
QString selectedDir;
selectedDir = fileDialog->selectedFiles().first();
qDebug()<<selectedDir;
}
/**
* @brief SettingsWidget::paintEvent
* @param event
*/
void SettingsWidget::paintEvent(QPaintEvent *event) {
Q_UNUSED(event)

View File

@ -23,6 +23,7 @@ public:
private:
void initUi();
void setupBlackList(const QStringList&);
void paintEvent(QPaintEvent *event);
//标题栏
QVBoxLayout * m_mainLyt = nullptr;
@ -45,6 +46,8 @@ private:
QHBoxLayout * m_indexBtnLyt = nullptr;
QPushButton * m_addDirBtn = nullptr;
QScrollArea * m_dirListArea = nullptr;
QWidget * m_dirListWidget = nullptr;
QVBoxLayout * m_dirListLyt = nullptr;
//搜索引擎设置
QLabel * m_searchEngineLabel = nullptr;