Note double click to switch in file tooltip (r5)

This commit is contained in:
Et0h 2015-08-15 18:34:18 +01:00
parent 10427d27b5
commit c66ae60d43
3 changed files with 9 additions and 3 deletions

View File

@ -1,4 +1,4 @@
version = '1.3.2'
milestone = 'Chami'
release_number = '14'
release_number = '15'
projectURL = 'http://syncplay.pl/'

View File

@ -323,6 +323,7 @@ en = {
"seektime-msgbox-label" : "Jump to specified time (in seconds / min:sec). Use +/- for relative seek.",
"ready-tooltip" : "Indicates whether you are ready to watch.",
"autoplay-tooltip" : "Auto-play when all users who have readiness indicator are ready and minimum user threshold met.",
"switch-to-file-tooltip" : "Double click to switch to {}", # Filename
# In-userlist notes (GUI)
"differentsize-note" : "Different size!",
@ -684,6 +685,7 @@ ru = {
"seektime-msgbox-label" : u"Перемотать к определенному моменту времени (указывать в секундах или мин:сек). Используйте +/-, чтобы перемотать вперед/назад относительно настоящего момента.",
"ready-tooltip" : u"Показывает, готовы ли Вы к просмотру или нет.",
"autoplay-tooltip" : u"Автоматическое воспроизведение, когда все пользователи с индикаторами готовности будут готовы и присутствует достаточное число пользователей.",
"switch-to-file-tooltip" : u"Double click to switch to {}", # Filename # TODO: Translate to Russian
# In-userlist notes (GUI)
"differentsize-note" : u"Размер файла не совпадает!",
@ -1045,6 +1047,7 @@ de = {
"seektime-msgbox-label" : u"Springe zur angegebenen Zeit (in Sekunden oder min:sek). Verwende +/- zum relativen Springen.",
"ready-tooltip" : u"Zeigt an, ob du bereit zum anschauen bist",
"autoplay-tooltip" : u"Automatisch abspielen, wenn alle Nutzer bereit sind und die minimale Nutzerzahl erreicht ist.",
"switch-to-file-tooltip" : u"Double click to switch to {}", # Filename # TODO: Translate to German
# In-userlist notes (GUI)
"differentsize-note" : u"Verschiedene Größe!",

View File

@ -154,7 +154,6 @@ class MainWindow(QtGui.QMainWindow):
currentPath = self._syncplayClient.userlist.currentUser.file["path"] if self._syncplayClient.userlist.currentUser.file else None
if utils.findFilenameInDirectories(filename, self.config["mediaSearchDirectories"]):
return constants.FILEITEM_SWITCH_FILE_SWITCH
elif currentPath:
currentDirectory = os.path.dirname(currentPath)
newPath = os.path.join(currentDirectory, filename)
@ -208,8 +207,12 @@ class MainWindow(QtGui.QMainWindow):
if isURL(filename):
filename = urllib.unquote(filename)
filenameitem = QtGui.QStandardItem(filename)
filenameitem.setToolTip(filename)
fileSwitchState = self.getFileSwitchState(user.file['name']) if room == currentUser.room else None
if fileSwitchState != constants.FILEITEM_SWITCH_NO_SWITCH:
filenameTooltip = getMessage("switch-to-file-tooltip").format(filename)
else:
filenameTooltip = filename
filenameitem.setToolTip(filenameTooltip)
filenameitem.setData(fileSwitchState, Qt.UserRole + constants.FILEITEM_SWITCH_ROLE)
if currentUser.file:
sameName = sameFilename(user.file['name'], currentUser.file['name'])