forked from openlp/openlp
Double click live setting
bzr-revno: 937
This commit is contained in:
commit
cfd54f331f
@ -323,9 +323,15 @@ class MediaManagerItem(QtGui.QWidget):
|
||||
translate('MediaManagerItem',
|
||||
'&Add to selected Service Item'),
|
||||
self.onAddEditClick))
|
||||
QtCore.QObject.connect(
|
||||
self.listView, QtCore.SIGNAL(u'doubleClicked(QModelIndex)'),
|
||||
self.onPreviewClick)
|
||||
if QtCore.QSettings().value(u'advanced/double click live',
|
||||
QtCore.QVariant(False)).toBool():
|
||||
QtCore.QObject.connect(self.listView,
|
||||
QtCore.SIGNAL(u'doubleClicked(QModelIndex)'),
|
||||
self.onLiveClick)
|
||||
else:
|
||||
QtCore.QObject.connect(self.listView,
|
||||
QtCore.SIGNAL(u'doubleClicked(QModelIndex)'),
|
||||
self.onPreviewClick)
|
||||
|
||||
def initialise(self):
|
||||
"""
|
||||
|
@ -55,7 +55,7 @@ class AdvancedTab(SettingsTab):
|
||||
self.leftLayout.setMargin(0)
|
||||
self.uiGroupBox = QtGui.QGroupBox(self.leftWidget)
|
||||
self.uiGroupBox.setObjectName(u'uiGroupBox')
|
||||
self.uiGroupBox.setMaximumWidth(260)
|
||||
self.uiGroupBox.setMaximumWidth(320)
|
||||
self.uiLayout = QtGui.QVBoxLayout(self.uiGroupBox)
|
||||
self.uiLayout.setSpacing(8)
|
||||
self.uiLayout.setMargin(6)
|
||||
@ -78,6 +78,9 @@ class AdvancedTab(SettingsTab):
|
||||
self.mediaPluginCheckBox = QtGui.QCheckBox(self.uiGroupBox)
|
||||
self.mediaPluginCheckBox.setObjectName(u'mediaPluginCheckBox')
|
||||
self.uiLayout.addWidget(self.mediaPluginCheckBox)
|
||||
self.doubleClickLiveCheckBox = QtGui.QCheckBox(self.uiGroupBox)
|
||||
self.doubleClickLiveCheckBox.setObjectName(u'doubleClickLiveCheckBox')
|
||||
self.uiLayout.addWidget(self.doubleClickLiveCheckBox)
|
||||
self.leftLayout.addWidget(self.uiGroupBox)
|
||||
# self.sharedDirGroupBox = QtGui.QGroupBox(self.leftWidget)
|
||||
# self.sharedDirGroupBox.setObjectName(u'sharedDirGroupBox')
|
||||
@ -133,6 +136,8 @@ class AdvancedTab(SettingsTab):
|
||||
translate('AdvancedTab', 'Number of recent files to display:'))
|
||||
self.mediaPluginCheckBox.setText(translate('AdvancedTab',
|
||||
'Save currently selected media manager plugin'))
|
||||
self.doubleClickLiveCheckBox.setText(translate('AdvancedTab',
|
||||
'Double-click to send items straight to live (requires restart)'))
|
||||
# self.sharedDirGroupBox.setTitle(
|
||||
# translate('AdvancedTab', 'Central Data Store'))
|
||||
# self.sharedCheckBox.setText(
|
||||
@ -157,6 +162,9 @@ class AdvancedTab(SettingsTab):
|
||||
self.mediaPluginCheckBox.setChecked(
|
||||
settings.value(u'save current plugin',
|
||||
QtCore.QVariant(False)).toBool())
|
||||
self.doubleClickLiveCheckBox.setChecked(
|
||||
settings.value(u'double click live',
|
||||
QtCore.QVariant(False)).toBool())
|
||||
settings.endGroup()
|
||||
|
||||
def save(self):
|
||||
@ -169,6 +177,8 @@ class AdvancedTab(SettingsTab):
|
||||
QtCore.QVariant(self.recentSpinBox.value()))
|
||||
settings.setValue(u'save current plugin',
|
||||
QtCore.QVariant(self.mediaPluginCheckBox.isChecked()))
|
||||
settings.setValue(u'double click live',
|
||||
QtCore.QVariant(self.doubleClickLiveCheckBox.isChecked()))
|
||||
settings.endGroup()
|
||||
|
||||
def onSharedCheckBoxChanged(self, checked):
|
||||
@ -178,4 +188,3 @@ class AdvancedTab(SettingsTab):
|
||||
self.sharedLabel.setEnabled(checked)
|
||||
self.sharedTextEdit.setEnabled(checked)
|
||||
self.sharedPushButton.setEnabled(checked)
|
||||
|
||||
|
@ -202,15 +202,21 @@ class SlideController(QtGui.QWidget):
|
||||
self.Toolbar.addToolbarWidget(u'Hide Menu', self.HideMenu)
|
||||
self.HideMenu.setMenu(QtGui.QMenu(
|
||||
translate('SlideController', 'Hide'), self.Toolbar))
|
||||
self.BlankScreen = QtGui.QAction(QtGui.QIcon( u':/slides/slide_blank.png'), u'Blank Screen', self.HideMenu)
|
||||
self.BlankScreen = QtGui.QAction(QtGui.QIcon(
|
||||
u':/slides/slide_blank.png'), u'Blank Screen', self.HideMenu)
|
||||
self.BlankScreen.setCheckable(True)
|
||||
QtCore.QObject.connect(self.BlankScreen, QtCore.SIGNAL("triggered(bool)"), self.onBlankDisplay)
|
||||
self.ThemeScreen = QtGui.QAction(QtGui.QIcon(u':/slides/slide_theme.png'), u'Blank to Theme', self.HideMenu)
|
||||
QtCore.QObject.connect(self.BlankScreen,
|
||||
QtCore.SIGNAL("triggered(bool)"), self.onBlankDisplay)
|
||||
self.ThemeScreen = QtGui.QAction(QtGui.QIcon(
|
||||
u':/slides/slide_theme.png'), u'Blank to Theme', self.HideMenu)
|
||||
self.ThemeScreen.setCheckable(True)
|
||||
QtCore.QObject.connect(self.ThemeScreen, QtCore.SIGNAL("triggered(bool)"), self.onThemeDisplay)
|
||||
self.DesktopScreen = QtGui.QAction(QtGui.QIcon(u':/slides/slide_desktop.png'), u'Show Desktop', self.HideMenu)
|
||||
QtCore.QObject.connect(self.ThemeScreen,
|
||||
QtCore.SIGNAL("triggered(bool)"), self.onThemeDisplay)
|
||||
self.DesktopScreen = QtGui.QAction(QtGui.QIcon(
|
||||
u':/slides/slide_desktop.png'), u'Show Desktop', self.HideMenu)
|
||||
self.DesktopScreen.setCheckable(True)
|
||||
QtCore.QObject.connect(self.DesktopScreen, QtCore.SIGNAL("triggered(bool)"), self.onHideDisplay)
|
||||
QtCore.QObject.connect(self.DesktopScreen,
|
||||
QtCore.SIGNAL("triggered(bool)"), self.onHideDisplay)
|
||||
self.HideMenu.setDefaultAction(self.BlankScreen)
|
||||
self.HideMenu.menu().addAction(self.BlankScreen)
|
||||
self.HideMenu.menu().addAction(self.ThemeScreen)
|
||||
@ -241,9 +247,8 @@ class SlideController(QtGui.QWidget):
|
||||
self.Toolbar.addToolbarWidget(
|
||||
u'Image SpinBox', self.DelaySpinBox)
|
||||
self.DelaySpinBox.setSuffix(translate('SlideController', 's'))
|
||||
self.DelaySpinBox.setToolTip(
|
||||
translate('SlideController',
|
||||
'Delay between slides in seconds'))
|
||||
self.DelaySpinBox.setToolTip(translate('SlideController',
|
||||
'Delay between slides in seconds'))
|
||||
self.ControllerLayout.addWidget(self.Toolbar)
|
||||
#Build a Media ToolBar
|
||||
self.Mediabar = OpenLPToolbar(self)
|
||||
@ -268,8 +273,7 @@ class SlideController(QtGui.QWidget):
|
||||
self.volumeSlider = Phonon.VolumeSlider()
|
||||
self.volumeSlider.setGeometry(QtCore.QRect(90, 260, 221, 24))
|
||||
self.volumeSlider.setObjectName(u'volumeSlider')
|
||||
self.Mediabar.addToolbarWidget(
|
||||
u'Audio Volume', self.volumeSlider)
|
||||
self.Mediabar.addToolbarWidget(u'Audio Volume', self.volumeSlider)
|
||||
self.ControllerLayout.addWidget(self.Mediabar)
|
||||
# Build the Song Toolbar
|
||||
if isLive:
|
||||
@ -328,6 +332,11 @@ class SlideController(QtGui.QWidget):
|
||||
# Signals
|
||||
QtCore.QObject.connect(self.PreviewListWidget,
|
||||
QtCore.SIGNAL(u'clicked(QModelIndex)'), self.onSlideSelected)
|
||||
if not self.isLive:
|
||||
if QtCore.QSettings().value(u'advanced/double click live',
|
||||
QtCore.QVariant(False)).toBool():
|
||||
QtCore.QObject.connect(self.PreviewListWidget,
|
||||
QtCore.SIGNAL(u'doubleClicked(QModelIndex)'), self.onGoLive)
|
||||
if isLive:
|
||||
QtCore.QObject.connect(Receiver.get_receiver(),
|
||||
QtCore.SIGNAL(u'slidecontroller_live_spin_delay'),
|
||||
|
Loading…
Reference in New Issue
Block a user