def _show_account_info(self, account_id: str, textwidget: ba.Widget) -> None: from bastd.ui.account import viewer ba.playsound(ba.getsound('swish')) viewer.AccountViewerWindow( account_id=account_id, position=textwidget.get_screen_space_center())
def on_account_press(self, account_id: Optional[str], origin_widget: ba.Widget) -> None: """A dude was clicked so we should show his account info.""" from bastd.ui.account import viewer if account_id is None: ba.playsound(ba.getsound('error')) return viewer.AccountViewerWindow( account_id=account_id, position=origin_widget.get_screen_space_center())