def dialogok(self): '''helper to show an OK dialog with a message''' headertxt = clean_string(self.params.get("header", "")) bodytxt = clean_string(self.params.get("message", "")) dialog = xbmcgui.Dialog() dialog.ok(heading=headertxt, message=bodytxt) del dialog
def dialogyesno(self): headertxt = clean_string(self.params.get('header', '')) bodytxt = clean_string(self.params.get('message', '')) yesactions = self.params.get('yesaction', '').split('|') noactions = self.params.get('noaction', '').split('|') if xbmcgui.Dialog().yesno(heading=headertxt, message=bodytxt): for action in yesactions: xbmc.executebuiltin(action) else: for action in noactions: xbmc.executebuiltin(action)
def dialogyesno(self): '''helper to show a YES/NO dialog with a message''' headertxt = clean_string(self.params.get("header", "")) bodytxt = clean_string(self.params.get("message", "")) yesactions = self.params.get("yesaction", "").split("|") noactions = self.params.get("noaction", "").split("|") if xbmcgui.Dialog().yesno(heading=headertxt, message=bodytxt): for action in yesactions: xbmc.executebuiltin(action) else: for action in noactions: xbmc.executebuiltin(action)
def textviewer(self): '''helper to show a textviewer dialog with a message''' headertxt = clean_string(self.params.get("header", "")) bodytxt = clean_string(self.params.get("message", "")) xbmcgui.Dialog().textviewer(headertxt, bodytxt)
def textviewer(self): headertxt = clean_string(self.params.get('header', '')) bodytxt = clean_string(self.params.get('message', '')) xbmcgui.Dialog().textviewer(headertxt, bodytxt)
def dialogok(self): headertxt = clean_string(self.params.get('header', '')) bodytxt = clean_string(self.params.get('message', '')) dialog = xbmcgui.Dialog() dialog.ok(heading=headertxt, message=bodytxt) del dialog