[gnome-mines/arnaudb/wip/gtk4: 1/36] Typos.



commit b5f55efbaff9caa2f2f750f5a233594124ef35a8
Author: Arnaud Bonatti <arnaud bonatti gmail com>
Date:   Tue Apr 14 21:52:27 2020 +0200

    Typos.

 src/gnome-mines.vala           | 17 ++++++-----------
 src/minefield-view.vala        |  6 ++----
 src/minefield.vala             | 16 ++++++++--------
 src/theme-selector-dialog.vala | 23 ++++++++++-------------
 src/tile.vala                  |  3 +--
 5 files changed, 27 insertions(+), 38 deletions(-)
---
diff --git a/src/gnome-mines.vala b/src/gnome-mines.vala
index db03f6b..b9354b5 100644
--- a/src/gnome-mines.vala
+++ b/src/gnome-mines.vala
@@ -92,7 +92,7 @@ public class Mines : Gtk.Application
         { "small",  0, 0, OptionArg.NONE, null, N_("Small game"), null },
         { "medium", 0, 0, OptionArg.NONE, null, N_("Medium game"), null },
         { "big",    0, 0, OptionArg.NONE, null, N_("Big game"), null },
-        { null }
+        {}
     };
 
     private const GLib.ActionEntry[] action_entries =
@@ -284,7 +284,7 @@ public class Mines : Gtk.Application
                 minefield_aspect.queue_resize ();
                 minefield_view.queue_draw ();
                 first_draw = true;
-               return true;
+                return true;
             };
             return false;
         });
@@ -315,7 +315,6 @@ public class Mines : Gtk.Application
         paused_box = (Gtk.Box) ui_builder.get_object ("paused_box");
         buttons_box = (Gtk.Box) ui_builder.get_object ("buttons_box");
         aspect_child = (Gtk.Box) ui_builder.get_object ("aspect_child");
-        paused_box = (Gtk.Box) ui_builder.get_object ("paused_box");
         paused_box.button_press_event.connect (view_button_press_event);
 
         minefield_overlay.add_overlay (paused_box);
@@ -837,20 +836,17 @@ public class Mines : Gtk.Application
             "",
             _("Resizing and SVG support:"),
             "Steve Chaplin",
-            "Callum McKenzie",
-            null
+            "Callum McKenzie"
         };
 
         string[] artists =
         {
-            "Richard Hoelscher",
-            null
+            "Richard Hoelscher"
         };
 
         string[] documenters =
         {
-            "Ekaterina Gerasimova",
-            null
+            "Ekaterina Gerasimova"
         };
 
         Gtk.show_about_dialog (window,
@@ -866,8 +862,7 @@ public class Mines : Gtk.Application
                                "documenters", documenters,
                                "translator-credits", _("translator-credits"),
                                "logo-icon-name", "org.gnome.Mines", "website",
-                               "https://wiki.gnome.org/Apps/Mines";,
-                               null);
+                               "https://wiki.gnome.org/Apps/Mines";);
     }
 
     private float percent_mines ()
diff --git a/src/minefield-view.vala b/src/minefield-view.vala
index 0a9c1e3..fcf7cfa 100644
--- a/src/minefield-view.vala
+++ b/src/minefield-view.vala
@@ -250,7 +250,7 @@ public class MinefieldView : Gtk.Grid
         if (event.button != 1) return;
 
         this.force_nolongpress = false;
- 
+
         /* Check for end cases and paused game */
         if (minefield.exploded || minefield.is_complete || minefield.paused)
             return;
@@ -355,9 +355,8 @@ public class MinefieldView : Gtk.Grid
                 mines[x,y].remove_class ("maybe");
                 mines[x,y].remove_class ("flag");
                 mines[x,y].add_class ("count");
-                if (n > 0) {
+                if (n > 0)
                     mines[x,y].add_class ("%umines".printf (n));
-                }
             }
         }
         else
@@ -535,5 +534,4 @@ public class MinefieldView : Gtk.Grid
 
         return false;
     }
-
 }
diff --git a/src/minefield.vala b/src/minefield.vala
index ab10015..71f6dd1 100644
--- a/src/minefield.vala
+++ b/src/minefield.vala
@@ -38,14 +38,14 @@ private struct Neighbour
 }
 private const Neighbour neighbour_map[] =
 {
-    {-1, 1},
-    {0, 1},
-    {1, 1},
-    {1, 0},
-    {1, -1},
-    {0, -1},
-    {-1, -1},
-    {-1, 0}
+    { -1,  1 },
+    {  0,  1 },
+    {  1,  1 },
+    {  1,  0 },
+    {  1, -1 },
+    {  0, -1 },
+    { -1, -1 },
+    { -1,  0 }
 };
 
 public class Minefield : Object
diff --git a/src/theme-selector-dialog.vala b/src/theme-selector-dialog.vala
index 4ae1237..ad31e9b 100644
--- a/src/theme-selector-dialog.vala
+++ b/src/theme-selector-dialog.vala
@@ -2,14 +2,14 @@ private class PreviewField : Minefield
 {
     private const Neighbour neighbour_map[] =
     {
-        {-1, 1},
-        {0, 1},
-        {1, 1},
-        {1, 0},
-        {1, -1},
-        {0, -1},
-        {-1, -1},
-        {-1, 0}
+        { -1,  1 },
+        {  0,  1 },
+        {  1,  1 },
+        {  1,  0 },
+        {  1, -1 },
+        {  0, -1 },
+        { -1, -1 },
+        { -1,  0 }
     };
 
     private const int SIZE = 7;
@@ -46,9 +46,7 @@ private class PreviewField : Minefield
                         if (is_location(nx, ny) && locations[nx, ny].has_mine)
                             locations[i, j].adjacent_mines++;
                     }
-               
     }
-
 }
 
 public class ThemeSelectorDialog : Gtk.Dialog
@@ -66,8 +64,8 @@ public class ThemeSelectorDialog : Gtk.Dialog
         try
         {
             FileEnumerator enumerator = file.enumerate_children ("standard::*",
-                                                                  FileQueryInfoFlags.NOFOLLOW_SYMLINKS,
-                                                                  null);
+                                                                 FileQueryInfoFlags.NOFOLLOW_SYMLINKS,
+                                                                 null);
 
             FileInfo info = null;
 
@@ -181,5 +179,4 @@ public class ThemeSelectorDialog : Gtk.Dialog
                 }
             }
     }
-
 }
diff --git a/src/tile.vala b/src/tile.vala
index b2c0be7..bc95986 100644
--- a/src/tile.vala
+++ b/src/tile.vala
@@ -26,7 +26,7 @@ public class Tile : Gtk.Button
         _gesture = new Gtk.GestureLongPress (this);
         _gesture.pressed.connect((x, y) =>
         {
-             tile_long_pressed (prow, pcol);
+            tile_long_pressed (prow, pcol);
         });
         button_press_event.connect ((event) =>
         {
@@ -55,4 +55,3 @@ public class Tile : Gtk.Button
         get_style_context ().remove_class (style_class);
     }
 }
-


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]