[atomix] 01/03: Add fix-incorrect-arrow-click-sensitivity.patch

Markus Koschany apo-guest at moszumanska.debian.org
Mon Apr 27 11:25:16 UTC 2015


This is an automated email from the git hooks/post-receive script.

apo-guest pushed a commit to branch master
in repository atomix.

commit 3da549406117e059a92f3d2ed6d62b06bbe07094
Author: Markus Koschany <apo at gambaru.de>
Date:   Mon Apr 27 12:45:06 2015 +0200

    Add fix-incorrect-arrow-click-sensitivity.patch
    
    Cherry-pick upstream commit f53a3905e790170b1ad5e7f9dcb0c78c7fe841f2
    to fix a bug with selecting nearby atoms.
---
 debian/changelog                                   |  3 ++
 .../fix-incorrect-arrow-click-sensitivity.patch    | 52 ++++++++++++++++++++++
 debian/patches/series                              |  1 +
 3 files changed, 56 insertions(+)

diff --git a/debian/changelog b/debian/changelog
index 3333a03..ce4165d 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -29,6 +29,9 @@ atomix (3.16.0-1) unstable; urgency=medium
   * atomix-data.install: Install /usr/share/appdata directory.
   * Update debian/copyright for new release
   * Add clean file and ensure that Atomix can be built twice in a row.
+  * Add fix-incorrect-arrow-click-sensitivity.patch
+    Cherry-pick upstream commit f53a3905e790170b1ad5e7f9dcb0c78c7fe841f2
+    to fix a bug with selecting nearby atoms.
 
  -- Markus Koschany <apo at gambaru.de>  Sun, 26 Apr 2015 21:15:24 +0200
 
diff --git a/debian/patches/fix-incorrect-arrow-click-sensitivity.patch b/debian/patches/fix-incorrect-arrow-click-sensitivity.patch
new file mode 100644
index 0000000..ec9820c
--- /dev/null
+++ b/debian/patches/fix-incorrect-arrow-click-sensitivity.patch
@@ -0,0 +1,52 @@
+From: Markus Koschany <apo at gambaru.de>
+Date: Mon, 27 Apr 2015 12:44:28 +0200
+Subject: fix incorrect arrow click sensitivity
+
+---
+ src/board-gtk.c | 16 +++++++++-------
+ 1 file changed, 9 insertions(+), 7 deletions(-)
+
+diff --git a/src/board-gtk.c b/src/board-gtk.c
+index 11d9d38..561ebe6 100644
+--- a/src/board-gtk.c
++++ b/src/board-gtk.c
+@@ -251,7 +251,6 @@ static gboolean board_handle_arrow_event (GtkWidget *item,
+   /* is currently an object moved? */
+   if (anim_data->timeout_id != -1)
+     return FALSE;
+-
+   if (event->type == GDK_BUTTON_PRESS && selector_data->selected) {
+     selector_data->mouse_steering = TRUE;
+     move_item (selector_data->sel_item, GPOINTER_TO_INT (direction));
+@@ -487,9 +486,14 @@ static void render_tile (Tile *tile, gint row, gint col) {
+   }
+ }
+ 
++static void show_sensitive (GtkWidget *widget)
++{
++  gtk_widget_set_visible (widget, gtk_widget_is_sensitive (widget));
++}
++
+ static gboolean show_arrow_group (SelectorData *data)
+ {
+-  g_slist_foreach (data->arrows, (GFunc)gtk_widget_show, NULL);
++  g_slist_foreach (data->arrows, (GFunc)show_sensitive, NULL);
+   data->arrow_show_timeout = -1;
+ 
+   return FALSE;
+@@ -872,12 +876,10 @@ static void check_for_arrow (gint r, gint c, GtkWidget *arrow) {
+ 
+   tile = playfield_get_tile (board_sce, r, c);
+ 
+-  if (tile == NULL)
+-    gtk_widget_show (arrow);
+-  else {
+-    gtk_widget_hide (arrow);
++  gtk_widget_set_sensitive (arrow, tile == NULL);
++
++  if (tile != NULL)
+     g_object_unref (tile);
+-  }
+ }
+ 
+ static void selector_arrows_show (SelectorData *data)
diff --git a/debian/patches/series b/debian/patches/series
index 8a8553b..4ca220d 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -1 +1,2 @@
 icon-path.patch
+fix-incorrect-arrow-click-sensitivity.patch

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-games/atomix.git



More information about the Pkg-games-commits mailing list