解决设置网络搜索引擎不生效的问题

This commit is contained in:
iaom 2022-12-09 18:00:24 +08:00
parent 3af1582eb1
commit c749aa7b83
2 changed files with 2 additions and 2 deletions

View File

@ -127,7 +127,7 @@ GlobalSettings::GlobalSettings(QObject *parent) : QObject(parent)
setValue(FILE_INDEX_ENABLE_KEY, m_searchGsettings->get(FILE_INDEX_ENABLE_KEY).toBool()); setValue(FILE_INDEX_ENABLE_KEY, m_searchGsettings->get(FILE_INDEX_ENABLE_KEY).toBool());
} }
if(m_searchGsettings->keys().contains(WEB_ENGINE_KEY)) { if(m_searchGsettings->keys().contains(WEB_ENGINE_KEY)) {
setValue(WEB_ENGINE_KEY, m_searchGsettings->get(WEB_ENGINE_KEY).toBool()); setValue(WEB_ENGINE_KEY, m_searchGsettings->get(WEB_ENGINE_KEY).toString());
} }
if(m_searchGsettings->keys().contains(CONTENT_FUZZY_SEARCH_KEY)) { if(m_searchGsettings->keys().contains(CONTENT_FUZZY_SEARCH_KEY)) {
setValue(CONTENT_FUZZY_SEARCH_KEY, m_searchGsettings->get(CONTENT_FUZZY_SEARCH_KEY).toBool()); setValue(CONTENT_FUZZY_SEARCH_KEY, m_searchGsettings->get(CONTENT_FUZZY_SEARCH_KEY).toBool());

View File

@ -64,7 +64,7 @@ QList<UkuiSearch::SearchPluginIface::Actioninfo> UkuiSearch::WebSearchPlugin::ge
void UkuiSearch::WebSearchPlugin::openAction(int actionkey, QString key, int type) void UkuiSearch::WebSearchPlugin::openAction(int actionkey, QString key, int type)
{ {
QString address; QString address;
QString engine = GlobalSettings::getInstance()->getValue("web_engine").toString(); QString engine = GlobalSettings::getInstance()->getValue("webEngine").toString();
if(!engine.isEmpty()) { if(!engine.isEmpty()) {
if(engine == "360") { if(engine == "360") {
address = "https://so.com/s?q=" + m_keyWord; //360 address = "https://so.com/s?q=" + m_keyWord; //360