Exemplo n.º 1
0
    def showSettingsUi(self):
        initial = QtCore.QTime(0, (self.__restart / 60000) % 60, (self.__restart / 1000) % 60)
        minValue = QtCore.QTime(0, 0, 0)
        maxValue = QtCore.QTime(0, 59, 59)

        dial = QTimeInputDialog('Pause', 'Insert time before restart (0 = never)', initial, minValue, maxValue)
        dial.exec_()

        if(dial.result() == dial.Accepted):
            self.__restart = dial.time.time().minute() * 60 + dial.time.time().second()
Exemplo n.º 2
0
    def showSettingsUi(self):
        initial = QtCore.QTime(0, (self.__position / 60000) % 60, (self.__position / 1000) % 60)
        minValue = QtCore.QTime(0, 0, 0)
        maxValue = QtCore.QTime(0, (self.__media.conf['duration'] / 60000) % 60, (self.__media.conf['duration'] / 1000) % 60)

        dial = QTimeInputDialog('Seek', 'Insert time', initial, minValue, maxValue)
        dial.exec_()

        if(dial.result() == dial.Accepted):
            self.__position = dial.time.time().minute() * 60000 + dial.time.time().second() * 1000