set alias fix

This commit is contained in:
ingvar1995 2017-07-10 18:23:20 +03:00
parent 1f4e81af35
commit 300b28bdfa

View File

@ -663,15 +663,15 @@ class Profile(basecontact.BaseContact, Singleton):
friend = self._contacts[num] friend = self._contacts[num]
name = friend.name name = friend.name
dialog = QtWidgets.QApplication.translate('MainWindow', dialog = QtWidgets.QApplication.translate('MainWindow',
"Enter new alias for friend {} or leave empty to use friend's name:") "Enter new alias for friend {} or leave empty to use friend's name:")
dialog = dialog.format(name) dialog = dialog.format(name)
title = QtWidgets.QApplication.translate('MainWindow', title = QtWidgets.QApplication.translate('MainWindow',
'Set alias') 'Set alias')
text, ok = QtGui.QInputDialog.getText(None, text, ok = QtWidgets.QInputDialog.getText(None,
title, title,
dialog, dialog,
QtWidgets.QLineEdit.Normal, QtWidgets.QLineEdit.Normal,
name) name)
if ok: if ok:
settings = Settings.get_instance() settings = Settings.get_instance()
aliases = settings['friends_aliases'] aliases = settings['friends_aliases']