Ticket #3153: 0001-Remember-paired-game-option-SL-3253.patch

File 0001-Remember-paired-game-option-SL-3253.patch, 2.0 KB (added by godiard, 11 years ago)
  • createtoolbar.py

    From 2770db25f392afec3ef0e3dc0f86b1b4f521c1dc Mon Sep 17 00:00:00 2001
    From: Gonzalo Odiard <godiard@gmail.com>
    Date: Thu, 27 Oct 2011 17:51:04 -0300
    Subject: [PATCH] Remember paired game option - SL #3253
    
    This patch revert part of the change included
    in 0f79e94f50ffa1b1ec8491d458dea9b2fc174efe
    because broken the change in the ui needed by
    identical/different tiles in edition mode.
    
    Signed-off-by: Gonzalo Odiard <gonzalo@laptop.org>
    ---
     createtoolbar.py |   10 ++--------
     1 files changed, 2 insertions(+), 8 deletions(-)
    
    diff --git a/createtoolbar.py b/createtoolbar.py
    index 521d6a4..49feaf7 100644
    a b class CreateToolbarBuilder(gobject.GObject): 
    4444
    4545        self._equal_pairs = ToggleToolButton('pair-non-equals')
    4646        self._equal_pairs.set_tooltip(_('Match different tiles'))
    47         self.id_equal_cb = self._equal_pairs.connect('toggled',
    48                 self._emit_equal_pairs)
     47        self._equal_pairs.connect('toggled', self._emit_equal_pairs)
    4948        self.toolbar.insert(self._equal_pairs, -1)
    5049
    5150        self._grouped = ToggleToolButton('grouped_game1')
    5251        self._grouped.set_tooltip(_('Mixed tiles game'))
    53         self.id_grouped_cb = self._grouped.connect('toggled', self._grouped_cb)
     52        self._grouped.connect('toggled', self._grouped_cb)
    5453        self.toolbar.insert(self._grouped, -1)
    5554
    5655        self._clear_button = ToolButton('edit-clear')
    class CreateToolbarBuilder(gobject.GObject): 
    123122        self.activity.game.model.mark_modified()
    124123
    125124    def update_create_toolbar(self, widget, game_name, equal_pairs, grouped):
    126         self._equal_pairs.handler_block(self.id_equal_cb)
    127125        self._equal_pairs.set_active(equal_pairs == '1')
    128         self._equal_pairs.handler_unblock(self.id_equal_cb)
    129 
    130         self._grouped.handler_block(self.id_grouped_cb)
    131126        self._grouped.set_active(grouped == '1')
    132         self._grouped.handler_unblock(self.id_grouped_cb)