def login(self): print("hey") password = self.blank_pass.text() realPass, job = dh.AuthPass() print("JOB="+job) if (password == realPass): print("LOGGED IN") app = QtWidgets.QApplication.instance() app.closeAllWindows() if (job == "admin"): self.Win1 = admin.Main() self.Win1.show() else: self.Win2 = home.Main() self.Win2.show() else: msg = QMessageBox() msg.setWindowTitle("ERROR!") msg.setText("Wrong Password! Try again") msg.setIcon(QMessageBox.Critical) x = msg.exec_()
def goHome(self): self.win1 = home.Main() self.win1.show()
if action is None or action == '': print "no action found: triggering default" action = 'home' xbmc.log("url: %s" % sys.argv[2]) if action == 'home': import home as plugin elif action == 'album': import album as plugin elif action == 'gallery': import gallery as plugin elif action == 'random': import random_gallery as plugin elif action == 'meme': import meme as plugin elif action == 'reddit' or action == 'reddit_add': import reddit as plugin elif action == 'view': import view_image as plugin elif action == 'play': import view_video as plugin elif action == 'settings': import settings as plugin elif action == 'slideshow': import slideshow as plugin else: import home as plugin plugin.Main()
def CloseAll(self): app = QtWidgets.QApplication.instance() app.closeAllWindows() self.dialog = home.Main() self.dialog.show()