-
Notifications
You must be signed in to change notification settings - Fork 0
/
ChangeAccount.py
executable file
·36 lines (30 loc) · 1.46 KB
/
ChangeAccount.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
from Accounts import Accounts
from tkinter import *
from Encryption import Encryption
from ChangeAccount2 import ChangeAccount2
class ChangeAccount(Accounts):
def back_to_menu(self):
self.change_account_frame.pack_forget()
self.menu_frame.pack()
def changeAccount(self):
number = super().getChoiceNumber()
if number == -1:
return
self.change_account_frame.pack_forget()
change2 = ChangeAccount2(self.root, self.change_account_frame, number)
def __init__(self, root, menu_frame):
super().__init__()
self.root = root
self.menu_frame = menu_frame
self.change_account_frame = Frame(self.root)
self.change_account_frame.pack()
Label(self.change_account_frame,
text = "Select which service's \ndata you would like to change", font = "Helvetica 20 bold").grid(row = 0, column = 0, pady = 20, columnspan = 3)
number = super().printChoiceList(self.change_account_frame)
if number == -1:
self.back_to_menu()
return
btnChange = Button(self.change_account_frame, text = "Change", command = self.changeAccount, width = 14)
btnBack = Button(self.change_account_frame, text = "Back to menu", command = self.back_to_menu, width = 14)
btnBack.grid(row = len(self.servicesList) + 2, column = 0, pady = 20, sticky = 'w')
btnChange.grid(row = len(self.servicesList) + 2, column = 2, pady = 20, sticky = 'e')