Uncomment code

This commit is contained in:
Paul Ebbers 2025-02-23 15:59:52 +01:00
parent 3468e41185
commit 1859382302

View File

@ -65,40 +65,40 @@ def AddPointerBox():
return
# def SearchBoxFunction():
# import SearchBoxLight
def SearchBoxFunction():
import SearchBoxLight
# global wax, sea, tbr
# mw = Gui.getMainWindow()
global wax, sea, tbr
mw = Gui.getMainWindow()
# if mw:
# if sea is None:
# sea = SearchBoxLight.SearchBoxLight(
# getItemGroups=lambda: __import__("GetItemGroups").getItemGroups(),
# getToolTip=lambda groupId, setParent: __import__("GetItemGroups").getToolTip(groupId, setParent),
# getItemDelegate=lambda: __import__("IndentedItemDelegate").IndentedItemDelegate(),
# )
# sea.resultSelected.connect(
# lambda index, groupId: __import__("GetItemGroups").onResultSelected(index, groupId)
# )
if mw:
if sea is None:
sea = SearchBoxLight.SearchBoxLight(
getItemGroups=lambda: __import__("GetItemGroups").getItemGroups(),
getToolTip=lambda groupId, setParent: __import__("GetItemGroups").getToolTip(groupId, setParent),
getItemDelegate=lambda: __import__("IndentedItemDelegate").IndentedItemDelegate(),
)
sea.resultSelected.connect(
lambda index, groupId: __import__("GetItemGroups").onResultSelected(index, groupId)
)
# if wax is None:
# wax = QWidgetAction(None)
# wax.setWhatsThis(
# translate(
# "SearchBar",
# "Use this search bar to find tools, document objects, preferences and more",
# )
# )
if wax is None:
wax = QWidgetAction(None)
wax.setWhatsThis(
translate(
"SearchBar",
"Use this search bar to find tools, document objects, preferences and more",
)
)
# sea.setWhatsThis(
# translate(
# "SearchBar",
# "Use this search bar to find tools, document objects, preferences and more",
# )
# )
# wax.setDefaultWidget(sea)
# return wax
sea.setWhatsThis(
translate(
"SearchBar",
"Use this search bar to find tools, document objects, preferences and more",
)
)
wax.setDefaultWidget(sea)
return wax
addToolSearchBox()