Don't show apps twice in search results
This commit is contained in:
parent
bc514d1c8c
commit
e6fdecaba4
@ -817,11 +817,19 @@ class pluginclass( object ):
|
|||||||
self.changeTab( 1 )
|
self.changeTab( 1 )
|
||||||
text = widget.get_text()
|
text = widget.get_text()
|
||||||
showns = False # Are any app shown?
|
showns = False # Are any app shown?
|
||||||
|
shownList = []
|
||||||
for i in self.applicationsBox.get_children():
|
for i in self.applicationsBox.get_children():
|
||||||
shown = i.filterText( text )
|
shown = i.filterText( text )
|
||||||
if (shown):
|
if (shown):
|
||||||
|
dupe = False
|
||||||
|
for item in shownList:
|
||||||
|
if i.desktopFile == item.desktopFile:
|
||||||
|
dupe = True
|
||||||
|
if dupe:
|
||||||
|
i.hide()
|
||||||
|
else:
|
||||||
|
shownList.append(i)
|
||||||
showns = True
|
showns = True
|
||||||
|
|
||||||
if (not showns and os.path.exists("/usr/lib/linuxmint/mintInstall/icon.svg")):
|
if (not showns and os.path.exists("/usr/lib/linuxmint/mintInstall/icon.svg")):
|
||||||
if len(text) >= 3:
|
if len(text) >= 3:
|
||||||
if self.current_suggestion is not None and self.current_suggestion in text:
|
if self.current_suggestion is not None and self.current_suggestion in text:
|
||||||
|
Loading…
Reference in New Issue
Block a user