mirror of https://github.com/Syncplay/syncplay
Show current offset in set offset dialog (#642)
This commit is contained in:
parent
20846ca78c
commit
f4fae95408
|
@ -1355,9 +1355,10 @@ class MainWindow(QtWidgets.QMainWindow):
|
||||||
|
|
||||||
@needsClient
|
@needsClient
|
||||||
def setOffset(self):
|
def setOffset(self):
|
||||||
|
oldoffset = str(self._syncplayClient.getUserOffset())
|
||||||
newoffset, ok = QtWidgets.QInputDialog.getText(
|
newoffset, ok = QtWidgets.QInputDialog.getText(
|
||||||
self, getMessage("setoffset-msgbox-label"),
|
self, getMessage("setoffset-msgbox-label"),
|
||||||
getMessage("offsetinfo-msgbox-label"), QtWidgets.QLineEdit.Normal, "")
|
getMessage("offsetinfo-msgbox-label"), QtWidgets.QLineEdit.Normal, oldoffset)
|
||||||
if ok and newoffset != '':
|
if ok and newoffset != '':
|
||||||
o = re.match(constants.UI_OFFSET_REGEX, "o " + newoffset)
|
o = re.match(constants.UI_OFFSET_REGEX, "o " + newoffset)
|
||||||
if o:
|
if o:
|
||||||
|
|
Loading…
Reference in New Issue