[baobab] Add Keyboard Shortcuts help window
- From: Stefano Facchini <sfacchini src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [baobab] Add Keyboard Shortcuts help window
- Date: Sun, 14 Oct 2018 13:09:15 +0000 (UTC)
commit 72e49eef45ce776260b98cdb7f17c47527fb0422
Author: Stefano Facchini <stefano facchini gmail com>
Date: Sun Oct 14 14:52:33 2018 +0200
Add Keyboard Shortcuts help window
src/baobab-main-window.ui | 4 ++++
src/baobab.gresource.xml | 1 +
src/help-overlay.ui | 54 +++++++++++++++++++++++++++++++++++++++++++++++
3 files changed, 59 insertions(+)
---
diff --git a/src/baobab-main-window.ui b/src/baobab-main-window.ui
index 41d12db..611c4d5 100644
--- a/src/baobab-main-window.ui
+++ b/src/baobab-main-window.ui
@@ -9,6 +9,10 @@
</item>
</section>
<section>
+ <item>
+ <attribute name="label" translatable="yes">Keyboard _Shortcuts</attribute>
+ <attribute name="action">win.show-help-overlay</attribute>
+ </item>
<item>
<attribute name="label" translatable="yes">_Help</attribute>
<attribute name="action">win.help</attribute>
diff --git a/src/baobab.gresource.xml b/src/baobab.gresource.xml
index 7cd35b0..889e9b1 100644
--- a/src/baobab.gresource.xml
+++ b/src/baobab.gresource.xml
@@ -6,6 +6,7 @@
<file compressed="true">baobab-main-window.ui</file>
</gresource>
<gresource prefix="/org/gnome/baobab/gtk">
+ <file compressed="true">help-overlay.ui</file>
<file compressed="true">menus.ui</file>
</gresource>
<gresource prefix="/org/gnome/baobab">
diff --git a/src/help-overlay.ui b/src/help-overlay.ui
new file mode 100644
index 0000000..0c76460
--- /dev/null
+++ b/src/help-overlay.ui
@@ -0,0 +1,54 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<interface>
+ <object class="GtkShortcutsWindow" id="help_overlay">
+ <property name="modal">true</property>
+ <child>
+ <object class="GtkShortcutsSection">
+ <property name="visible">true</property>
+ <property name="section-name">shortcuts</property>
+ <property name="max-height">10</property>
+ <child>
+ <object class="GtkShortcutsGroup">
+ <property name="visible">true</property>
+ <property name="title" translatable="yes" context="shortcut window">General</property>
+ <child>
+ <object class="GtkShortcutsShortcut">
+ <property name="visible">true</property>
+ <property name="accelerator">F10</property>
+ <property name="title" translatable="yes" context="shortcut window">Show / Hide primary
menu</property>
+ </object>
+ </child>
+ <child>
+ <object class="GtkShortcutsShortcut">
+ <property name="visible">true</property>
+ <property name="accelerator"><Primary>r</property>
+ <property name="title" translatable="yes" context="shortcut window">Rescan current
location</property>
+ </object>
+ </child>
+ <child>
+ <object class="GtkShortcutsShortcut">
+ <property name="visible">true</property>
+ <property name="accelerator"><Primary>o</property>
+ <property name="title" translatable="yes" context="shortcut window">Scan folder</property>
+ </object>
+ </child>
+ <child>
+ <object class="GtkShortcutsShortcut">
+ <property name="visible">true</property>
+ <property name="title" translatable="yes" context="shortcut window">Show Keyboard
Shortcuts</property>
+ <property name="accelerator"><ctrl><shift>question</property>
+ </object>
+ </child>
+ <child>
+ <object class="GtkShortcutsShortcut">
+ <property name="visible">true</property>
+ <property name="title" translatable="yes" context="shortcut window">Quit</property>
+ <property name="accelerator"><Primary>q</property>
+ </object>
+ </child>
+ </object>
+ </child>
+ </object>
+ </child>
+ </object>
+</interface>
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]