mirror of
https://invent.kde.org/network/falkon.git
synced 2024-11-11 01:22:10 +01:00
[SearchEngines] Fixed issue with default engine when more engines have same name
This commit is contained in:
parent
ffa1e0561f
commit
b2b6d198f7
|
@ -1,6 +1,7 @@
|
|||
Version 1.7.0
|
||||
* development version
|
||||
* added support for window.onload event
|
||||
* added support for external.AddSearchProvider js function
|
||||
|
||||
Version 1.6.1
|
||||
* released 26 January 2014
|
||||
|
|
|
@ -215,12 +215,12 @@ void SearchEnginesDialog::moveDown()
|
|||
void SearchEnginesDialog::reloadEngines()
|
||||
{
|
||||
ui->treeWidget->clear();
|
||||
const QString defaultEngineName = mApp->searchEnginesManager()->defaultEngine().name;
|
||||
const SearchEngine defaultEngine = mApp->searchEnginesManager()->defaultEngine();
|
||||
|
||||
foreach (const SearchEngine &en, m_manager->allEngines()) {
|
||||
QTreeWidgetItem* item = new QTreeWidgetItem();
|
||||
setEngine(item, en);
|
||||
changeItemToDefault(item, en.name == defaultEngineName);
|
||||
changeItemToDefault(item, en == defaultEngine);
|
||||
item->setIcon(0, en.icon);
|
||||
item->setText(1, en.shortcut);
|
||||
|
||||
|
|
|
@ -50,7 +50,8 @@ public:
|
|||
bool operator==(const Engine &other) const {
|
||||
return (this->name == other.name &&
|
||||
this->url == other.url &&
|
||||
this->suggestionsUrl == other.suggestionsUrl);
|
||||
this->suggestionsUrl == other.suggestionsUrl &&
|
||||
this->shortcut == other.shortcut);
|
||||
}
|
||||
};
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user