Fix the label int he sidebar
[gmpc.git] / src / plugin-internal.h
blobd7f2c2bee8b390c8e12ae25559973cc59f8f9c65
2 /* Gnome Music Player Client (GMPC)
3 * Copyright (C) 2004-2012 Qball Cow <qball@gmpclient.org>
4 * Project homepage: http://gmpclient.org/
6 * This program is free software; you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License as published by
8 * the Free Software Foundation; either version 2 of the License, or
9 * (at your option) any later version.
11 * This program is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 * GNU General Public License for more details.
16 * You should have received a copy of the GNU General Public License along
17 * with this program; if not, write to the Free Software Foundation, Inc.,
18 * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
20 #include <config.h>
21 #include <gtk/gtk.h>
22 #include <libmpd/libmpd.h>
23 #include "metadata.h"
24 #include "gmpc-extras.h"
25 #include "gmpc-mpddata-model.h"
26 #include "gmpc-mpddata-treeview.h"
28 #ifndef __PLUGIN_INTERNAL_H__
29 #define __PLUGIN_INTERNAL_H__
31 /**
32 * Plugin functions
35 int gmpc_plugin_get_id(gmpcPluginParent * plug);
36 void gmpc_plugin_init(gmpcPluginParent * plug);
37 void gmpc_plugin_destroy(gmpcPluginParent * plug);
38 void gmpc_plugin_save_yourself(gmpcPluginParent * plug);
40 gboolean gmpc_plugin_get_enabled(const gmpcPluginParent * plug);
41 void gmpc_plugin_set_enabled(gmpcPluginParent * plug, gboolean enabled);
42 gboolean gmpc_plugin_has_enabled(gmpcPluginParent * plug);
44 const gchar *gmpc_plugin_get_translation_domain(gmpcPluginParent * plug);
45 const char *gmpc_plugin_get_name(gmpcPluginParent * plug);
46 void gmpc_plugin_status_changed(gmpcPluginParent * plug, MpdObj * mi,
47 ChangedStatusType what);
49 gint gmpc_plugin_tool_menu_integration(gmpcPluginParent * plug, GtkMenu * menu);
50 void gmpc_plugin_mpd_connection_changed(gmpcPluginParent * plug, MpdObj * mi,
51 int connected, gpointer data);
53 gboolean gmpc_plugin_is_browser(gmpcPluginParent * plug);
54 gboolean gmpc_plugin_is_sidebar(gmpcPluginParent *plug);
55 void gmpc_plugin_sidebar_set_state(gmpcPluginParent *plug, GmpcPluginSidebarState state);
56 void gmpc_plugin_sidebar_init(gmpcPluginParent *plug);
57 void gmpc_plugin_browser_unselected(gmpcPluginParent * plug,
58 GtkWidget * container);
59 void gmpc_plugin_browser_selected(gmpcPluginParent * plug,
60 GtkWidget * container);
61 void gmpc_plugin_browser_add(gmpcPluginParent * plug, GtkWidget * cat_tree);
62 int gmpc_plugin_browser_cat_right_mouse_menu(gmpcPluginParent * plug,
63 GtkWidget * menu, int type,
64 GtkWidget * tree,
65 GdkEventButton * event);
66 int gmpc_plugin_browser_key_press_event(gmpcPluginParent * plug, GtkWidget * mw,
67 GdkEventKey * event, int type);
68 int gmpc_plugin_browser_add_go_menu(gmpcPluginParent * plug, GtkWidget * menu);
69 int gmpc_plugin_browser_song_list_option_menu(gmpcPluginParent * plug,
70 GmpcMpdDataTreeview * tree,
71 GtkMenu * menu);
72 gboolean gmpc_plugin_browser_has_integrate_search(gmpcPluginParent * plug);
73 MpdData *gmpc_plugin_browser_integrate_search(gmpcPluginParent * plug,
74 const int search_field,
75 const gchar * query,
76 GError ** error);
77 gboolean gmpc_plugin_browser_integrate_search_field_supported(gmpcPluginParent *
78 plug,
79 const int
80 search_field);
82 gboolean gmpc_plugin_has_preferences(gmpcPluginParent * plug);
83 void gmpc_plugin_preferences_construct(gmpcPluginParent * plug,
84 GtkWidget * wid);
85 void gmpc_plugin_preferences_destroy(gmpcPluginParent * plug, GtkWidget * wid);
87 int gmpc_plugin_get_type(gmpcPluginParent * plug);
88 const int *gmpc_plugin_get_version(gmpcPluginParent * plug);
89 gboolean gmpc_plugin_is_internal(gmpcPluginParent * plug);
91 typedef struct _gmpcPluginParent
93 gmpcPlugin *old;
94 GmpcPluginBase *new;
95 } _gmpcPluginParent;
96 #endif