openlp-core team mailing list archive
-
openlp-core team
-
Mailing list archive
-
Message #20118
[Merge] lp:~googol/openlp/central-settings-place into lp:openlp
Andreas Preikschat has proposed merging lp:~googol/openlp/central-settings-place into lp:openlp.
Requested reviews:
OpenLP Core (openlp-core)
Related bugs:
Bug #1096559 in OpenLP: "Central place for default settings"
https://bugs.launchpad.net/openlp/+bug/1096559
Bug #1128376 in OpenLP: "Configure shortcuts has two items called settings"
https://bugs.launchpad.net/openlp/+bug/1128376
For more details, see:
https://code.launchpad.net/~googol/openlp/central-settings-place/+merge/156066
Hello,
The old code probably will not work and to get it to work would mean to much effort. Furthermore, this setting was used at alpha/beta time, so I think we can neglect this.
--
https://code.launchpad.net/~googol/openlp/central-settings-place/+merge/156066
Your team OpenLP Core is requested to review the proposed merge of lp:~googol/openlp/central-settings-place into lp:openlp.
=== modified file 'openlp/core/lib/settings.py'
--- openlp/core/lib/settings.py 2013-03-19 19:43:22 +0000
+++ openlp/core/lib/settings.py 2013-03-28 20:29:31 +0000
@@ -305,6 +305,7 @@
(u'bibles/bookname language', u'bibles/book name language', []),
(u'general/enable slide loop', u'advanced/slide limits', [(SlideLimits.Wrap, True), (SlideLimits.End, False)]),
(u'songs/ccli number', u'general/ccli number', []),
+ (u'media/use phonon', u'', []),
# Changed during 2.1.x development.
(u'advanced/stylesheet fix', u'', []),
(u'bibles/last directory 1', u'bibles/last directory import', []),
=== modified file 'openlp/plugins/media/mediaplugin.py'
--- openlp/plugins/media/mediaplugin.py 2013-03-19 20:05:13 +0000
+++ openlp/plugins/media/mediaplugin.py 2013-03-28 20:29:31 +0000
@@ -118,31 +118,6 @@
"""
return self.media_controller.get_media_display_html()
- def app_startup(self):
- """
- Do a couple of things when the app starts up. In this particular case
- we want to check if we have the old "Use Phonon" setting, and convert
- it to "enable Phonon" and "make it the first one in the list".
- """
- Plugin.app_startup(self)
- settings = Settings()
- settings.beginGroup(self.settings_section)
- if settings.contains(u'use phonon'):
- log.info(u'Found old Phonon setting')
- players = self.media_controller.mediaPlayers.keys()
- has_phonon = u'phonon' in players
- if settings.value(u'use phonon') and has_phonon:
- log.debug(u'Converting old setting to new setting')
- new_players = []
- if players:
- new_players = [player for player in players if player != u'phonon']
- new_players.insert(0, u'phonon')
- self.media_controller.mediaPlayers[u'phonon'].is_active = True
- settings.setValue(u'players', u','.join(new_players))
- self.settingsTab.load()
- settings.remove(u'use phonon')
- settings.endGroup()
-
def _get_media_controller(self):
"""
Adds the media controller to the class dynamically
Follow ups