GNOME Bugzilla – Bug 734513
play/pause is activated twice when pressing spacebar and play/pause button is active/selected
Last modified: 2014-11-12 20:52:30 UTC
To reproduce, click on the play/pause button and press spacebar. The music will keep playing after a short interruption (if the music was playing before).
Created attachment 290451 [details] [review] checks to see if playbutton is focused before changing play state This is a small conditional that wont activate the shortcut if the play button already has focus.
Review of attachment 290451 [details] [review]: Good job, works for me. Some nitpicks: ::: gnomemusic/window.py @@ +336,3 @@ if not self.toolbar.searchbar.get_reveal_child(): if event.keyval == Gdk.KEY_space and self.player.actionbar.get_visible(): + if Gtk.Window.get_focus(self) != self.player._ui.get_object("play_button"): Can be simplified for better readability: 1) self.get_focus() instead of Gtk.Window.get_focus(self) 2) self.player.playBtn instead of self.player._ui.get_object
Created attachment 290551 [details] [review] adds more condensed conditional statement Ok, I've made those readability changes.
Thanks, pushed https://git.gnome.org/browse/gnome-music/commit/?id=ee66b5f to master https://git.gnome.org/browse/gnome-music/commit/?id=612d567 to gnome-3-14