@@ -30,6 +30,19 @@ def __init__(self, config_path="", autostart=True):
3030 self .coverage = self .config .coverage
3131 self ._subscribe_routes ()
3232
33+ def __getattribute__ (self , name ):
34+ attr = object .__getattribute__ (self , name )
35+
36+ if callable (attr ) and not name .startswith ('_' ):
37+ preserve_methods = {'SearchBrowse' , 'SetButton' }
38+ if name not in preserve_methods :
39+ try :
40+ object .__getattribute__ (self , 'config' )._flag_is_new_browse = None
41+ except AttributeError :
42+ pass
43+
44+ return attr
45+
3346 def _subscribe_routes (self ):
3447 """Registra handlers do Router no event bus para roteamento.
3548
@@ -641,7 +654,7 @@ def SetBranch(self, branch):
641654 """
642655 self .__webapp .SetBranch (branch )
643656
644- def SetButton (self , button , sub_item = "" , position = 1 , check_error = True ):
657+ def SetButton (self , button , sub_item = "" , position = 1 , check_error = True , is_browse = False ):
645658 """
646659 Method that clicks on a button on the screen.
647660
@@ -674,7 +687,7 @@ def SetButton(self, button, sub_item="", position=1, check_error=True):
674687 >>> # Calling the method to click on a sub item in a sub item that is inside a button.
675688 >>> oHelper.SetButton("Other Actions", "Delete, Delete")
676689 """
677- self .__router .SetButton (button , sub_item , position , check_error = check_error )
690+ self .__router .SetButton (button , sub_item , position , check_error = check_error , is_browse = is_browse )
678691
679692 def SetFilePath (self , value , button = "" ):
680693 """
@@ -1703,6 +1716,19 @@ def __init__(self, config_path="", autostart=True):
17031716 self .config = ConfigLoader ()
17041717 self .coverage = self .config .coverage
17051718
1719+ def __getattribute__ (self , name ):
1720+ attr = object .__getattribute__ (self , name )
1721+
1722+ if callable (attr ) and not name .startswith ('_' ):
1723+ preserve_methods = {'SearchBrowse' , 'SetButton' }
1724+ if name not in preserve_methods :
1725+ try :
1726+ object .__getattribute__ (self , 'config' )._flag_is_new_browse = None
1727+ except AttributeError :
1728+ pass
1729+
1730+ return attr
1731+
17061732 def ClickMenu (self , menu_item ):
17071733 """
17081734 Clicks on the menu-item of the POUI component.
0 commit comments