[dconf-editor] Shortcut toggles config.
- From: Arnaud B. <arnaudb src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [dconf-editor] Shortcut toggles config.
- Date: Thu, 20 Dec 2018 13:36:55 +0000 (UTC)
commit 990f56417b5fee090fc9e0597095cab7017440f5
Author: Arnaud Bonatti <arnaud bonatti gmail com>
Date: Thu Dec 20 14:25:58 2018 +0100
Shortcut toggles config.
As do both bookmarks and modifications shortcuts.
editor/browser-window.vala | 11 ++++++-----
editor/dconf-editor.vala | 2 +-
editor/help-overlay.ui | 2 +-
3 files changed, 8 insertions(+), 7 deletions(-)
---
diff --git a/editor/browser-window.vala b/editor/browser-window.vala
index 30307f9..50c7c83 100644
--- a/editor/browser-window.vala
+++ b/editor/browser-window.vala
@@ -426,7 +426,7 @@ private abstract class BrowserWindow : BaseWindow
{ "next-match", next_match }, // <P>g // usual shortcut for "next-match" in a
SearchEntry; see also "Down"
{ "previous-match", previous_match }, // <P>G // usual shortcut for "previous-match" in a
SearchEntry; see also "Up"
- { "request-config", _request_config }, // <P>i // TODO fusion with ui.open-config?
+ { "toggle-config", toggle_config }, // <P>i
{ "toggle-search", _toggle_search }, // <P>f // TODO unduplicate (at least name)
{ "edit-path-end", edit_path_end }, // <P>l
@@ -480,12 +480,13 @@ private abstract class BrowserWindow : BaseWindow
* * config
\*/
- private void _request_config (/* SimpleAction action, Variant? variant */) //
TODO unduplicate method name
+ private void toggle_config (/* SimpleAction action, Variant? variant */)
{
- if (is_in_in_window_mode ()) // TODO better
+ if (main_view.current_view == ViewType.CONFIG)
+ request_folder (current_path);
+ else if (main_view.is_in_in_window_mode ())
return;
-
- if (main_view.current_view == ViewType.FOLDER)
+ else if (main_view.current_view == ViewType.FOLDER)
request_config (current_path);
}
diff --git a/editor/dconf-editor.vala b/editor/dconf-editor.vala
index 84a8721..ffced5f 100644
--- a/editor/dconf-editor.vala
+++ b/editor/dconf-editor.vala
@@ -304,7 +304,7 @@ private class ConfigurationEditor : Gtk.Application
set_accels_for_action ("key.toggle-search", { "<Primary>f" }); // TODO
<Shift><Primary>f something?
set_accels_for_action ("key.next-match", { "<Primary>g" });
set_accels_for_action ("key.previous-match", { "<Shift><Primary>g" });
- set_accels_for_action ("key.request-config", { "<Primary>i" }); // <Shift><Primary>i is
gtk editor
+ set_accels_for_action ("key.toggle-config", { "<Primary>i" }); // <Shift><Primary>i is
gtk editor
set_accels_for_action ("kbd.modifications", { "<Alt>i" });
set_accels_for_action ("key.edit-path-end", { "<Primary>l" });
set_accels_for_action ("key.edit-path-last", { "<Shift><Primary>l" });
diff --git a/editor/help-overlay.ui b/editor/help-overlay.ui
index 72458f6..09f7022 100644
--- a/editor/help-overlay.ui
+++ b/editor/help-overlay.ui
@@ -156,7 +156,7 @@
<child>
<object class="GtkShortcutsShortcut">
<property name="visible">True</property>
- <property name="title" translatable="yes" context="shortcut window">Show folder
properties</property>
+ <property name="title" translatable="yes" context="shortcut window">Toggle folder
properties</property>
<property name="accelerator"><Primary>i</property>
</object>
</child>
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]