1 /* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
2 
3 /*
4  *  GThumb
5  *
6  *  Copyright (C) 2020 Free Software Foundation, Inc.
7  *
8  *  This program is free software; you can redistribute it and/or modify
9  *  it under the terms of the GNU General Public License as published by
10  *  the Free Software Foundation; either version 2 of the License, or
11  *  (at your option) any later version.
12  *
13  *  This program is distributed in the hope that it will be useful,
14  *  but WITHOUT ANY WARRANTY; without even the implied warranty of
15  *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
16  *  GNU General Public License for more details.
17  *
18  *  You should have received a copy of the GNU General Public License
19  *  along with this program.  If not, see <http://www.gnu.org/licenses/>.
20  */
21 
22 
23 #include <config.h>
24 #include <gtk/gtk.h>
25 #include <gthumb.h>
26 #include "callbacks.h"
27 #include "dlg-terminal-preferences.h"
28 
29 
30 G_MODULE_EXPORT void
gthumb_extension_activate(void)31 gthumb_extension_activate (void)
32 {
33 	gth_hook_add_callback ("gth-browser-construct", 10, G_CALLBACK (terminal__gth_browser_construct_cb), NULL);
34 	gth_hook_add_callback ("gth-browser-folder-tree-popup-before", 10, G_CALLBACK (terminal__gth_browser_folder_tree_popup_before_cb), NULL);
35 }
36 
37 
38 G_MODULE_EXPORT void
gthumb_extension_deactivate(void)39 gthumb_extension_deactivate (void)
40 {
41 }
42 
43 
44 G_MODULE_EXPORT gboolean
gthumb_extension_is_configurable(void)45 gthumb_extension_is_configurable (void)
46 {
47 	return TRUE;
48 }
49 
50 
51 G_MODULE_EXPORT void
gthumb_extension_configure(GtkWindow * parent)52 gthumb_extension_configure (GtkWindow *parent)
53 {
54 	dlg_terminal_preferences (parent);
55 }
56