Philipp Hörist pushed to branch master at gajim / gajim
Commits: d24bed12 by Philipp Hörist at 2017-02-12T19:09:48+01:00 Dont try to select iter if there is none
- - - - - 50514393 by Philipp Hörist at 2017-02-12T19:09:48+01:00 Fix key error on removing account
- - - - - 09f54f97 by Philipp Hörist at 2017-02-12T19:09:49+01:00 Use platform identifier with better granularity
Fixes #8542
- - - - - 1b2324ca by Philipp Hörist at 2017-02-12T19:10:55+01:00 Merge branch 'small-fixes' into 'master'
Small fixes
Closes #8542
See merge request !58 - - - - -
3 changed files:
- src/common/helpers.py - src/config.py - src/roster_window.py
Changes:
===================================== src/common/helpers.py ===================================== --- a/src/common/helpers.py +++ b/src/common/helpers.py @@ -746,13 +746,13 @@ def play_sound_file(path_to_soundfile): path_to_soundfile = check_soundfile_path(path_to_soundfile) if path_to_soundfile is None: return - elif os.name == 'nt' and HAS_WINSOUND: + elif sys.platform == 'win32' and HAS_WINSOUND: try: winsound.PlaySound(path_to_soundfile, winsound.SND_FILENAME|winsound.SND_ASYNC) except Exception: log.exception('Sound Playback Error') - elif os.name == 'posix': + elif sys.platform == 'linux': if gajim.config.get('soundplayer') == '': def _oss_play(): sndfile = wave.open(path_to_soundfile, 'rb')
===================================== src/config.py ===================================== --- a/src/config.py +++ b/src/config.py @@ -3254,7 +3254,9 @@ class ManageBookmarksWindow: self.xml.connect_signals(self) self.window.show_all() # select root iter - self.selection.select_iter(self.treestore.get_iter_first()) + first_iter = self.treestore.get_iter_first() + if first_iter: + self.selection.select_iter(first_iter)
def on_key_press_event(self, widget, event): if event.keyval == Gdk.KEY_Escape:
===================================== src/roster_window.py ===================================== --- a/src/roster_window.py +++ b/src/roster_window.py @@ -1558,6 +1558,8 @@ class RosterWindow: """ if not self.tree.get_model(): return + if account not in gajim.connections: + return delimiter = gajim.connections[account].nested_group_delimiter group_splited = group.split(delimiter) i = 1
View it on GitLab: https://dev.gajim.org/gajim/gajim/compare/eec1a69efd90620686cbeac52f37decc47...