mirror of
https://github.com/TheFunny/ArisuAutoSweeper
synced 2026-10-11 02:32:16 +00:00
feat: add stop method to Login class and implement button handling in base.py
This commit is contained in:
@@ -49,11 +49,14 @@ class AppControl(Adb, WSA, Uiautomator2):
|
||||
Returns:
|
||||
etree._Element: Select elements with `self.hierarchy.xpath('//*[@text="Hermit"]')` for example.
|
||||
"""
|
||||
method = self.config.Emulator_ControlMethod
|
||||
if method in AppControl._app_u2_family:
|
||||
self.hierarchy = self.dump_hierarchy_uiautomator2()
|
||||
else:
|
||||
self.hierarchy = self.dump_hierarchy_adb()
|
||||
# method = self.config.Emulator_ControlMethod
|
||||
# if method in AppControl._app_u2_family:
|
||||
# self.hierarchy = self.dump_hierarchy_uiautomator2()
|
||||
# else:
|
||||
# self.hierarchy = self.dump_hierarchy_adb()
|
||||
|
||||
# Using uiautomator2
|
||||
self.hierarchy = self.dump_hierarchy_uiautomator2()
|
||||
return self.hierarchy
|
||||
|
||||
def xpath_to_button(self, xpath: str) -> HierarchyButton:
|
||||
|
||||
Reference in New Issue
Block a user