Coding / Programming Videos

Post your favorite coding videos and share them with others!

All posts tagged controller

GUI MVC controller – Steven Wang – Medium

Source link from tkinter as Tkfrom encrypt_view import EncryptView class EncryptControllerdef __init__(self):[tab]self.app=Encrypt(master=Tk())[tab]self.app.newButton[“command”]=self.newMethod[tab]self.app.loadButton[“command”]=self.loadMethod[tab]self.app.saveButton[“command”]=self.saveMethod[tab]self.app.encodeButton[“command”]=self.encodeMethod[tab]self.app.decodeButton[“command”]=self.decodeMethod[tab]self.app.clearButton[“command”]=self.clearMethod[tab]self.app.copyButton[“command”]=self.copyMethod[tab]self.app.mainloop() def newMethod(self): self.app.displayText[“text”]=”” def loadMethod(self): self.app.displayText[“text”]=”” def saveMethod(self): self.app.displayText[“text”]=”” def encodeMethod(self): self.app.displayText[“text”]=”” def decodeMethod(self): self.app.displayText[“text”]=”” def clearMethod(self): self.app.displayText[“text”]=”” def copyMethod(self): self.app.displayText[“text”]=”” if __name__ ==”__main__”: app=EncryptController() Source link  

 
Translate »