Example #1
0
 def show_popover(self):
     popover = SliderPopover(self, self.popover_position, _('Audio volume'),
                             self.volume)
     popover.slider.setMinimum(0)
     popover.slider.setMaximum(100)
     popover.slider.setPageStep(self.step)
     popover.value_changed.connect(self.on_slider_value_changed)
     popover.show()
Example #2
0
 def show_popover(self):
     slider_value = self.playback_rate * self.multiplier
     popover = SliderPopover(self, self.popover_position,
                             _('Playback speed'), slider_value)
     # In 0.1 steps from 0.5 to 1.5
     popover.slider.setMinimum(5)
     popover.slider.setMaximum(15)
     popover.slider.setSingleStep(1)
     popover.slider.setPageStep(1)
     popover.slider.setTickInterval(1)
     popover.slider.setTickPosition(QtWidgets.QSlider.TicksBelow)
     popover.value_changed.connect(self.on_slider_value_changed)
     popover.show()