[gnome-2048] Disable 'help'.
- From: Arnaud Bonatti <arnaudb src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-2048] Disable 'help'.
- Date: Wed, 17 Feb 2016 14:35:10 +0000 (UTC)
commit c9822170e6eedb1622c3a9b88e089d2c223e4501
Author: Arnaud Bonatti <arnaud bonatti gmail com>
Date: Wed Feb 17 15:34:47 2016 +0100
Disable 'help'.
data/menus.ui | 5 +++--
src/application.vala | 21 ++++++++++++---------
2 files changed, 15 insertions(+), 11 deletions(-)
---
diff --git a/data/menus.ui b/data/menus.ui
index 034c83c..e2ae059 100644
--- a/data/menus.ui
+++ b/data/menus.ui
@@ -18,14 +18,15 @@
</item>
</section>
<section>
- <item>
+ <!-- item>
<attribute name="label" translatable="yes">Help</attribute>
<attribute name="action">app.help</attribute>
<attribute name="accel">F1</attribute>
- </item>
+ </item -->
<item>
<attribute name="label" translatable="yes">About</attribute>
<attribute name="action">app.about</attribute>
+ <attribute name="accel"><Primary><Shift>F1</attribute>
</item>
<item>
<attribute name="label" translatable="yes">Quit</attribute>
diff --git a/src/application.vala b/src/application.vala
index 6b075e3..cf33ab7 100644
--- a/src/application.vala
+++ b/src/application.vala
@@ -50,13 +50,17 @@ public class Application : Gtk.Application
private const GLib.ActionEntry[] action_entries =
{
- { "new-game", new_game_cb },
{ "undo", undo_cb },
+
+ // app-menu
+ { "new-game", new_game_cb },
{ "scores", scores_cb },
- { "about", about_cb },
+
{ "preferences", preferences_cb },
- { "quit", quit_cb },
- { "help", help_cb }
+
+/* { "help", help_cb }, */
+ { "about", about_cb },
+ { "quit", quit_cb }
};
public Application ()
@@ -69,7 +73,6 @@ public class Application : Gtk.Application
base.startup ();
add_action_entries (action_entries, this);
- add_accelerator ("F1", "app.help", null);
_settings = new Settings ("org.gnome.2048");
@@ -230,8 +233,8 @@ public class Application : Gtk.Application
_about_dialog.logo_icon_name = "gnome-2048";
_about_dialog.comments = _("A clone of 2048 for GNOME");
- _about_dialog.authors = {"Juan R. García Blanco"};
- _about_dialog.copyright = "Copyright © 2014-2015 Juan R. García Blanco";
+ _about_dialog.authors = {"Juan R. García Blanco","Arnaud Bonatti"};
+ _about_dialog.copyright = "Copyright \xc2\xa9 2014-2015 – Juan R. García Blanco\nCopyright \xc2\xa9 2016
– Arnaud Bonatti";
_about_dialog.version = VERSION;
_about_dialog.website = "http://www.gnome.org";
_about_dialog.license_type = Gtk.License.GPL_3_0;
@@ -375,14 +378,14 @@ public class Application : Gtk.Application
_window.destroy ();
}
- private void help_cb ()
+/* private void help_cb ()
{
try {
Gtk.show_uri (_window.get_screen (), "help:gnome-2048", Gtk.get_current_event_time ());
} catch (GLib.Error e) {
warning ("Failed to show help: %s", e.message);
}
- }
+ } */
private bool key_press_event_cb (Gtk.Widget widget, Gdk.EventKey event)
{
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]