main.py: loginscreen now gets list of profiles
This commit is contained in:
parent
23969b7e2a
commit
f11f226890
13
src/main.py
13
src/main.py
@ -1,5 +1,6 @@
|
||||
from loginscreen import LoginScreen
|
||||
from settings import Settings
|
||||
from profile import Profile
|
||||
import sys
|
||||
from PySide import QtCore, QtGui
|
||||
|
||||
@ -12,9 +13,15 @@ if __name__ == '__main__':
|
||||
ls = LoginScreen()
|
||||
win = QtGui.QMainWindow()
|
||||
ls.setupUi(win)
|
||||
|
||||
ls.update_select(['tox_save'])
|
||||
profiles = Profile.find_profiles()
|
||||
ls.update_select(map(lambda x: x[1], profiles))
|
||||
win.show()
|
||||
app.connect(app, QtCore.SIGNAL("lastWindowClosed()"), app, QtCore.SLOT("quit()"))
|
||||
app.exec_()
|
||||
# TODO: get result from loginscreen and open mainscreen
|
||||
# TODO: get result from loginscreen
|
||||
# add new default profile (if needed)
|
||||
# save selected profile to open
|
||||
# create new profile?
|
||||
else:
|
||||
path, name = settings['auto_profile']
|
||||
# TODO: open mainscreen
|
||||
|
@ -36,7 +36,7 @@ class Settings(dict):
|
||||
'auto_accept_from_friends': [],
|
||||
'friends_aliases': [],
|
||||
'typing_notifications': True,
|
||||
'auto_profile': ''
|
||||
'auto_profile': None
|
||||
}
|
||||
|
||||
def save(self):
|
||||
|
Loading…
Reference in New Issue
Block a user