[geany/geany-plugins] 4c6f86: TreeBrowser: keybinding to track current file (#524)
Vasiliy Faronov
git-noreply at xxxxx
Wed Feb 15 22:03:22 UTC 2017
Branch: refs/heads/master
Author: Vasiliy Faronov <vfaronov at gmail.com>
Committer: Frank Lanitz <frank at frank.uvena.de>
Date: Wed, 15 Feb 2017 22:03:22 UTC
Commit: 4c6f8607da4496135102d3874a71ccb4d73d1a37
https://github.com/geany/geany-plugins/commit/4c6f8607da4496135102d3874a71ccb4d73d1a37
Log Message:
-----------
TreeBrowser: keybinding to track current file (#524)
TreeBrowser has a "Follow current document" option, but I don't use it
because it causes the tree's root to change. Still, sometimes I have
a large tree and I want to quickly find the current document in it.
Modified Paths:
--------------
treebrowser/src/treebrowser.c
Modified: treebrowser/src/treebrowser.c
7 lines changed, 7 insertions(+), 0 deletions(-)
===================================================================
@@ -110,6 +110,7 @@ enum
KB_CREATE_FILE,
KB_CREATE_DIR,
KB_REFRESH,
+ KB_TRACK_CURRENT,
KB_COUNT
};
@@ -2107,6 +2108,10 @@ static void kb_activate(guint key_id)
case KB_REFRESH:
on_menu_refresh(NULL, NULL);
break;
+
+ case KB_TRACK_CURRENT:
+ treebrowser_track_current();
+ break;
}
}
@@ -2139,6 +2144,8 @@ plugin_init(GeanyData *data)
0, 0, "create_dir", _("Create New Directory"), NULL);
keybindings_set_item(key_group, KB_REFRESH, kb_activate,
0, 0, "rename_refresh", _("Refresh"), NULL);
+ keybindings_set_item(key_group, KB_TRACK_CURRENT, kb_activate,
+ 0, 0, "track_current", _("Track Current"), NULL);
plugin_signal_connect(geany_plugin, NULL, "document-activate", TRUE,
(GCallback)&treebrowser_track_current_cb, NULL);
--------------
This E-Mail was brought to you by github_commit_mail.py (Source: https://github.com/geany/infrastructure).
More information about the Plugins-Commits
mailing list