21 lines
680 B
Python
21 lines
680 B
Python
from PyQt5.QtWidgets import QWidget, QFormLayout, QDoubleSpinBox, QLabel
|
|
|
|
class CutsceneWaitEditor(QWidget):
|
|
def __init__(self, parent=None):
|
|
super().__init__(parent)
|
|
layout = QFormLayout(self)
|
|
layout.setContentsMargins(0, 0, 0, 0)
|
|
layout.setSpacing(0)
|
|
self.waitTimeInput = QDoubleSpinBox()
|
|
self.waitTimeInput.setMinimum(0.0)
|
|
self.waitTimeInput.setMaximum(9999.0)
|
|
self.waitTimeInput.setDecimals(2)
|
|
self.waitTimeInput.setSingleStep(0.1)
|
|
layout.addRow(QLabel("Wait Time (seconds):"), self.waitTimeInput)
|
|
|
|
def setWaitTime(self, value):
|
|
self.waitTimeInput.setValue(value)
|
|
|
|
def getWaitTime(self):
|
|
return self.waitTimeInput.value()
|