This change disables presentation plugin on osx and hides it in menu and fristtimewizard to be not visible for users.

This also removes the line disabling presentation plugin.

bzr-revno: 2092
Fixes: https://launchpad.net/bugs/1002038
This commit is contained in:
Martin Zibricky 2012-10-16 16:07:07 +02:00 committed by Andreas Preikschat
commit 8e125fb604
2 changed files with 19 additions and 10 deletions

View File

@ -85,6 +85,14 @@ class PluginManager(object):
log.debug(u'finding plugins in %s at depth %d', log.debug(u'finding plugins in %s at depth %d',
unicode(plugin_dir), startdepth) unicode(plugin_dir), startdepth)
for root, dirs, files in os.walk(plugin_dir): for root, dirs, files in os.walk(plugin_dir):
# TODO Presentation plugin is not yet working on Mac OS X.
# For now just ignore it. The following code will hide it
# in settings dialog.
if sys.platform == 'darwin':
present_plugin_dir = os.path.join(plugin_dir, 'presentations')
# Ignore files from the presentation plugin directory.
if root.startswith(present_plugin_dir):
continue
for name in files: for name in files:
if name.endswith(u'.py') and not name.startswith(u'__'): if name.endswith(u'.py') and not name.startswith(u'__'):
path = os.path.abspath(os.path.join(root, name)) path = os.path.abspath(os.path.join(root, name))

View File

@ -82,13 +82,13 @@ class Ui_FirstTimeWizard(object):
self.imageCheckBox.setChecked(True) self.imageCheckBox.setChecked(True)
self.imageCheckBox.setObjectName(u'imageCheckBox') self.imageCheckBox.setObjectName(u'imageCheckBox')
self.pluginLayout.addWidget(self.imageCheckBox) self.pluginLayout.addWidget(self.imageCheckBox)
self.presentationCheckBox = QtGui.QCheckBox(self.pluginPage) # TODO Presentation plugin is not yet working on Mac OS X.
if sys.platform == "darwin": # For now just ignore it.
self.presentationCheckBox.setChecked(False) if sys.platform != 'darwin':
else: self.presentationCheckBox = QtGui.QCheckBox(self.pluginPage)
self.presentationCheckBox.setChecked(True) self.presentationCheckBox.setChecked(True)
self.presentationCheckBox.setObjectName(u'presentationCheckBox') self.presentationCheckBox.setObjectName(u'presentationCheckBox')
self.pluginLayout.addWidget(self.presentationCheckBox) self.pluginLayout.addWidget(self.presentationCheckBox)
self.mediaCheckBox = QtGui.QCheckBox(self.pluginPage) self.mediaCheckBox = QtGui.QCheckBox(self.pluginPage)
self.mediaCheckBox.setChecked(True) self.mediaCheckBox.setChecked(True)
self.mediaCheckBox.setObjectName(u'mediaCheckBox') self.mediaCheckBox.setObjectName(u'mediaCheckBox')
@ -214,10 +214,11 @@ class Ui_FirstTimeWizard(object):
self.bibleCheckBox.setText(translate('OpenLP.FirstTimeWizard', 'Bible')) self.bibleCheckBox.setText(translate('OpenLP.FirstTimeWizard', 'Bible'))
self.imageCheckBox.setText(translate('OpenLP.FirstTimeWizard', self.imageCheckBox.setText(translate('OpenLP.FirstTimeWizard',
'Images')) 'Images'))
self.presentationCheckBox.setText(translate('OpenLP.FirstTimeWizard', # TODO Presentation plugin is not yet working on Mac OS X.
'Presentations')) # For now just ignore it.
if sys.platform == "darwin": if sys.platform != 'darwin':
self.presentationCheckBox.setEnabled(False) self.presentationCheckBox.setText(translate('OpenLP.FirstTimeWizard',
'Presentations'))
self.mediaCheckBox.setText(translate('OpenLP.FirstTimeWizard', self.mediaCheckBox.setText(translate('OpenLP.FirstTimeWizard',
'Media (Audio and Video)')) 'Media (Audio and Video)'))
self.remoteCheckBox.setText(translate('OpenLP.FirstTimeWizard', self.remoteCheckBox.setText(translate('OpenLP.FirstTimeWizard',