annotate src/evdev-plug/ed.c @ 1395:761e17b23e0c

added Discovery plugin type
author Cristi Magherusan <majeru@atheme-project.org>
date Fri, 03 Aug 2007 07:21:36 +0300
parents 377c4c6e17a6
children 95fab0931d47
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
422
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
1 /*
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
2 *
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
3 * Author: Giacomo Lozito <james@develia.org>, (C) 2005-2007
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
4 *
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
5 * This program is free software; you can redistribute it and/or modify it
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
6 * under the terms of the GNU General Public License as published by the
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
7 * Free Software Foundation; either version 2 of the License, or (at your
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
8 * option) any later version.
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
9 *
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
10 * This program is distributed in the hope that it will be useful, but
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
11 * WITHOUT ANY WARRANTY; without even the implied warranty of
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
13 * General Public License for more details.
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
14 *
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
15 * You should have received a copy of the GNU General Public License along
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
16 * with this program; if not, write to the Free Software Foundation, Inc.,
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
17 * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
18 *
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
19 */
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
20
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
21 #include "ed.h"
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
22 #include "ed_types.h"
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
23 #include "ed_internals.h"
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
24 #include "ed_actions.h"
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
25 #include "ed_ui.h"
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
26 #include "ed_common.h"
527
d124034ebea3 [svn] - glib/gi18n.h -> audacious/i18n.h for automatic dgettext support
nenolod
parents: 457
diff changeset
27 #include <audacious/i18n.h>
1023
51d0636e6dd0 [svn] - evdev-plug: works again with auddrct
giacomo
parents: 527
diff changeset
28 #include <audacious/auddrct.h>
422
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
29
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
30
1117
377c4c6e17a6 [svn] - evdev-plug: converted to v2 plugin system
giacomo
parents: 1023
diff changeset
31 GeneralPlugin *evdevplug_gplist[] = { &ed_gp, NULL };
1395
761e17b23e0c added Discovery plugin type
Cristi Magherusan <majeru@atheme-project.org>
parents: 1117
diff changeset
32 DECLARE_PLUGIN(evdev-plug, NULL, NULL, NULL, NULL, NULL, evdevplug_gplist, NULL, NULL);
1117
377c4c6e17a6 [svn] - evdev-plug: converted to v2 plugin system
giacomo
parents: 1023
diff changeset
33
422
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
34 GList *ed_device_listening_list = NULL;
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
35 gboolean plugin_is_active = FALSE;
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
36
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
37 /* action callbacks */
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
38 void ed_action_pb_play ( gpointer );
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
39 void ed_action_pb_stop ( gpointer );
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
40 void ed_action_pb_pause ( gpointer );
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
41 void ed_action_pb_prev ( gpointer );
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
42 void ed_action_pb_next ( gpointer );
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
43 void ed_action_pb_eject ( gpointer );
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
44 void ed_action_vol_up5 ( gpointer );
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
45 void ed_action_vol_down5 ( gpointer );
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
46 void ed_action_vol_up10 ( gpointer );
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
47 void ed_action_vol_down10 ( gpointer );
457
f5ed9a6ad3f1 [svn] - evdev-plug: added volume->mute and win->jumptofile actions
giacomo
parents: 431
diff changeset
48 void ed_action_vol_mute ( gpointer );
422
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
49 void ed_action_win_main ( gpointer );
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
50 void ed_action_win_playlist ( gpointer );
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
51 void ed_action_win_equalizer ( gpointer );
457
f5ed9a6ad3f1 [svn] - evdev-plug: added volume->mute and win->jumptofile actions
giacomo
parents: 431
diff changeset
52 void ed_action_win_jtf ( gpointer );
422
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
53 void ed_action_pl_repeat ( gpointer );
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
54 void ed_action_pl_shuffle ( gpointer );
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
55
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
56 /* map action codes to ed_action_t objects */
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
57 ed_action_t player_actions[] =
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
58 {
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
59 [ED_ACTION_PB_PLAY] = { N_("Playback->Play") , ed_action_pb_play },
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
60 [ED_ACTION_PB_STOP] = { N_("Playback->Stop") , ed_action_pb_stop },
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
61 [ED_ACTION_PB_PAUSE] = { N_("Playback->Pause") , ed_action_pb_pause },
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
62 [ED_ACTION_PB_PREV] = { N_("Playback->Prev") , ed_action_pb_prev },
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
63 [ED_ACTION_PB_NEXT] = { N_("Playback->Next") , ed_action_pb_next },
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
64 [ED_ACTION_PB_EJECT] = { N_("Playback->Eject") , ed_action_pb_eject },
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
65
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
66 [ED_ACTION_PL_REPEAT] = { N_("Playlist->Repeat") , ed_action_pl_repeat },
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
67 [ED_ACTION_PL_SHUFFLE] = { N_("Playlist->Shuffle") , ed_action_pl_shuffle },
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
68
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
69 [ED_ACTION_VOL_UP5] = { N_("Volume->Up_5") , ed_action_vol_up5 },
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
70 [ED_ACTION_VOL_DOWN5] = { N_("Volume->Down_5") , ed_action_vol_down5 },
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
71 [ED_ACTION_VOL_UP10] = { N_("Volume->Up_10") , ed_action_vol_up10 },
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
72 [ED_ACTION_VOL_DOWN10] = { N_("Volume->Down_10") , ed_action_vol_down10 },
457
f5ed9a6ad3f1 [svn] - evdev-plug: added volume->mute and win->jumptofile actions
giacomo
parents: 431
diff changeset
73 [ED_ACTION_VOL_MUTE] = { N_("Volume->Mute") , ed_action_vol_mute },
422
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
74
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
75 [ED_ACTION_WIN_MAIN] = { N_("Window->Main") , ed_action_win_main },
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
76 [ED_ACTION_WIN_PLAYLIST] = { N_("Window->Playlist") , ed_action_win_playlist },
457
f5ed9a6ad3f1 [svn] - evdev-plug: added volume->mute and win->jumptofile actions
giacomo
parents: 431
diff changeset
77 [ED_ACTION_WIN_EQUALIZER] = { N_("Window->Equalizer") , ed_action_win_equalizer },
f5ed9a6ad3f1 [svn] - evdev-plug: added volume->mute and win->jumptofile actions
giacomo
parents: 431
diff changeset
78 [ED_ACTION_WIN_JTF] = { N_("Window->JumpToFile") , ed_action_win_jtf }
422
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
79 };
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
80
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
81
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
82
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
83 /* ***************** */
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
84 /* plug-in functions */
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
85
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
86 void
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
87 ed_init ( void )
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
88 {
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
89 g_log_set_handler( NULL , G_LOG_LEVEL_WARNING , g_log_default_handler , NULL );
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
90
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
91 plugin_is_active = TRUE; /* go! */
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
92
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
93 /* read event devices and bindings from user
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
94 configuration and start listening for active ones */
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
95 ed_device_start_listening_from_config();
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
96
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
97 return;
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
98 }
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
99
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
100
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
101 void
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
102 ed_cleanup ( void )
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
103 {
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
104 /* shut down all devices being listened */
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
105 ed_device_stop_listening_all( TRUE );
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
106
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
107 plugin_is_active = FALSE; /* stop! */
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
108
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
109 return;
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
110 }
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
111
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
112
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
113 void
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
114 ed_config ( void )
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
115 {
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
116 ed_ui_config_show();
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
117 }
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
118
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
119
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
120 void
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
121 ed_about ( void )
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
122 {
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
123 ed_ui_about_show();
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
124 }
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
125
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
126
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
127
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
128 /* ************** */
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
129 /* player actions */
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
130
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
131 void
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
132 ed_action_call ( gint code , gpointer param )
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
133 {
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
134 DEBUGMSG( "Calling action; code %i ( %s )\n" , code , player_actions[code].desc );
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
135
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
136 /* activate callback for requested action */
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
137 player_actions[code].callback( param );
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
138 }
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
139
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
140
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
141 void
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
142 ed_action_pb_play ( gpointer param )
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
143 {
1023
51d0636e6dd0 [svn] - evdev-plug: works again with auddrct
giacomo
parents: 527
diff changeset
144 audacious_drct_play();
422
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
145 }
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
146
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
147 void
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
148 ed_action_pb_stop ( gpointer param )
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
149 {
1023
51d0636e6dd0 [svn] - evdev-plug: works again with auddrct
giacomo
parents: 527
diff changeset
150 audacious_drct_stop();
422
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
151 }
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
152
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
153 void
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
154 ed_action_pb_pause ( gpointer param )
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
155 {
1023
51d0636e6dd0 [svn] - evdev-plug: works again with auddrct
giacomo
parents: 527
diff changeset
156 if (audacious_drct_get_playing() || audacious_drct_get_paused())
51d0636e6dd0 [svn] - evdev-plug: works again with auddrct
giacomo
parents: 527
diff changeset
157 audacious_drct_pause();
431
f757e1aa62e6 [svn] pause functionality should play if not already playing, now
kiyoshi
parents: 422
diff changeset
158 else
1023
51d0636e6dd0 [svn] - evdev-plug: works again with auddrct
giacomo
parents: 527
diff changeset
159 audacious_drct_play();
422
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
160 }
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
161
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
162 void
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
163 ed_action_pb_prev ( gpointer param )
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
164 {
1023
51d0636e6dd0 [svn] - evdev-plug: works again with auddrct
giacomo
parents: 527
diff changeset
165 audacious_drct_pl_prev();
422
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
166 }
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
167
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
168 void
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
169 ed_action_pb_next ( gpointer param )
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
170 {
1023
51d0636e6dd0 [svn] - evdev-plug: works again with auddrct
giacomo
parents: 527
diff changeset
171 audacious_drct_pl_next();
422
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
172 }
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
173
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
174 void
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
175 ed_action_pb_eject ( gpointer param )
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
176 {
1023
51d0636e6dd0 [svn] - evdev-plug: works again with auddrct
giacomo
parents: 527
diff changeset
177 audacious_drct_eject();
422
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
178 }
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
179
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
180 void
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
181 ed_action_pl_repeat ( gpointer param )
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
182 {
1023
51d0636e6dd0 [svn] - evdev-plug: works again with auddrct
giacomo
parents: 527
diff changeset
183 audacious_drct_pl_repeat_toggle();
422
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
184 }
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
185
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
186 void
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
187 ed_action_pl_shuffle ( gpointer param )
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
188 {
1023
51d0636e6dd0 [svn] - evdev-plug: works again with auddrct
giacomo
parents: 527
diff changeset
189 audacious_drct_pl_shuffle_toggle();
422
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
190 }
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
191
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
192 void
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
193 ed_action_vol_up5 ( gpointer param )
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
194 {
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
195 gint vl, vr;
1023
51d0636e6dd0 [svn] - evdev-plug: works again with auddrct
giacomo
parents: 527
diff changeset
196 audacious_drct_get_volume( &vl , &vr );
51d0636e6dd0 [svn] - evdev-plug: works again with auddrct
giacomo
parents: 527
diff changeset
197 audacious_drct_set_volume( CLAMP(vl + 5, 0, 100) , CLAMP(vr + 5, 0, 100) );
422
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
198 }
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
199
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
200 void
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
201 ed_action_vol_down5 ( gpointer param )
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
202 {
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
203 gint vl, vr;
1023
51d0636e6dd0 [svn] - evdev-plug: works again with auddrct
giacomo
parents: 527
diff changeset
204 audacious_drct_get_volume( &vl , &vr );
51d0636e6dd0 [svn] - evdev-plug: works again with auddrct
giacomo
parents: 527
diff changeset
205 audacious_drct_set_volume( CLAMP(vl - 5, 0, 100) , CLAMP(vr - 5, 0, 100) );
422
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
206 }
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
207
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
208 void
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
209 ed_action_vol_up10 ( gpointer param )
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
210 {
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
211 gint vl, vr;
1023
51d0636e6dd0 [svn] - evdev-plug: works again with auddrct
giacomo
parents: 527
diff changeset
212 audacious_drct_get_volume( &vl , &vr );
51d0636e6dd0 [svn] - evdev-plug: works again with auddrct
giacomo
parents: 527
diff changeset
213 audacious_drct_set_volume( CLAMP(vl + 10, 0, 100) , CLAMP(vr + 10, 0, 100) );
422
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
214 }
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
215
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
216 void
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
217 ed_action_vol_down10 ( gpointer param )
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
218 {
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
219 gint vl, vr;
1023
51d0636e6dd0 [svn] - evdev-plug: works again with auddrct
giacomo
parents: 527
diff changeset
220 audacious_drct_get_volume( &vl , &vr );
51d0636e6dd0 [svn] - evdev-plug: works again with auddrct
giacomo
parents: 527
diff changeset
221 audacious_drct_set_volume( CLAMP(vl - 10, 0, 100) , CLAMP(vr - 10, 0, 100) );
422
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
222 }
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
223
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
224 void
457
f5ed9a6ad3f1 [svn] - evdev-plug: added volume->mute and win->jumptofile actions
giacomo
parents: 431
diff changeset
225 ed_action_vol_mute ( gpointer param )
f5ed9a6ad3f1 [svn] - evdev-plug: added volume->mute and win->jumptofile actions
giacomo
parents: 431
diff changeset
226 {
f5ed9a6ad3f1 [svn] - evdev-plug: added volume->mute and win->jumptofile actions
giacomo
parents: 431
diff changeset
227 static gint vl = -1;
f5ed9a6ad3f1 [svn] - evdev-plug: added volume->mute and win->jumptofile actions
giacomo
parents: 431
diff changeset
228 static gint vr = -1;
f5ed9a6ad3f1 [svn] - evdev-plug: added volume->mute and win->jumptofile actions
giacomo
parents: 431
diff changeset
229
f5ed9a6ad3f1 [svn] - evdev-plug: added volume->mute and win->jumptofile actions
giacomo
parents: 431
diff changeset
230 if ( vl == -1 ) /* no previous memory of volume before mute action */
f5ed9a6ad3f1 [svn] - evdev-plug: added volume->mute and win->jumptofile actions
giacomo
parents: 431
diff changeset
231 {
1023
51d0636e6dd0 [svn] - evdev-plug: works again with auddrct
giacomo
parents: 527
diff changeset
232 audacious_drct_get_volume( &vl , &vr ); /* memorize volume before mute */
51d0636e6dd0 [svn] - evdev-plug: works again with auddrct
giacomo
parents: 527
diff changeset
233 audacious_drct_set_volume( 0 , 0 ); /* mute */
457
f5ed9a6ad3f1 [svn] - evdev-plug: added volume->mute and win->jumptofile actions
giacomo
parents: 431
diff changeset
234 }
f5ed9a6ad3f1 [svn] - evdev-plug: added volume->mute and win->jumptofile actions
giacomo
parents: 431
diff changeset
235 else /* memorized volume values exist */
f5ed9a6ad3f1 [svn] - evdev-plug: added volume->mute and win->jumptofile actions
giacomo
parents: 431
diff changeset
236 {
f5ed9a6ad3f1 [svn] - evdev-plug: added volume->mute and win->jumptofile actions
giacomo
parents: 431
diff changeset
237 gint vl_now = 0;
f5ed9a6ad3f1 [svn] - evdev-plug: added volume->mute and win->jumptofile actions
giacomo
parents: 431
diff changeset
238 gint vr_now = 0;
f5ed9a6ad3f1 [svn] - evdev-plug: added volume->mute and win->jumptofile actions
giacomo
parents: 431
diff changeset
239
1023
51d0636e6dd0 [svn] - evdev-plug: works again with auddrct
giacomo
parents: 527
diff changeset
240 audacious_drct_get_volume( &vl_now , &vr_now );
457
f5ed9a6ad3f1 [svn] - evdev-plug: added volume->mute and win->jumptofile actions
giacomo
parents: 431
diff changeset
241 if (( vl_now == 0 ) && ( vr_now == 0 ))
f5ed9a6ad3f1 [svn] - evdev-plug: added volume->mute and win->jumptofile actions
giacomo
parents: 431
diff changeset
242 {
f5ed9a6ad3f1 [svn] - evdev-plug: added volume->mute and win->jumptofile actions
giacomo
parents: 431
diff changeset
243 /* the volume is still muted, restore the old values */
1023
51d0636e6dd0 [svn] - evdev-plug: works again with auddrct
giacomo
parents: 527
diff changeset
244 audacious_drct_set_volume( vl , vr );
457
f5ed9a6ad3f1 [svn] - evdev-plug: added volume->mute and win->jumptofile actions
giacomo
parents: 431
diff changeset
245 vl = -1; vr = -1; /* reset these for next use */
f5ed9a6ad3f1 [svn] - evdev-plug: added volume->mute and win->jumptofile actions
giacomo
parents: 431
diff changeset
246 }
f5ed9a6ad3f1 [svn] - evdev-plug: added volume->mute and win->jumptofile actions
giacomo
parents: 431
diff changeset
247 else
f5ed9a6ad3f1 [svn] - evdev-plug: added volume->mute and win->jumptofile actions
giacomo
parents: 431
diff changeset
248 {
f5ed9a6ad3f1 [svn] - evdev-plug: added volume->mute and win->jumptofile actions
giacomo
parents: 431
diff changeset
249 /* the volume has been raised with other commands, act as if there wasn't a previous memory */
1023
51d0636e6dd0 [svn] - evdev-plug: works again with auddrct
giacomo
parents: 527
diff changeset
250 audacious_drct_get_volume( &vl , &vr ); /* memorize volume before mute */
51d0636e6dd0 [svn] - evdev-plug: works again with auddrct
giacomo
parents: 527
diff changeset
251 audacious_drct_set_volume( 0 , 0 ); /* mute */
457
f5ed9a6ad3f1 [svn] - evdev-plug: added volume->mute and win->jumptofile actions
giacomo
parents: 431
diff changeset
252 }
f5ed9a6ad3f1 [svn] - evdev-plug: added volume->mute and win->jumptofile actions
giacomo
parents: 431
diff changeset
253 }
f5ed9a6ad3f1 [svn] - evdev-plug: added volume->mute and win->jumptofile actions
giacomo
parents: 431
diff changeset
254 }
f5ed9a6ad3f1 [svn] - evdev-plug: added volume->mute and win->jumptofile actions
giacomo
parents: 431
diff changeset
255
f5ed9a6ad3f1 [svn] - evdev-plug: added volume->mute and win->jumptofile actions
giacomo
parents: 431
diff changeset
256 void
422
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
257 ed_action_win_main ( gpointer param )
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
258 {
1023
51d0636e6dd0 [svn] - evdev-plug: works again with auddrct
giacomo
parents: 527
diff changeset
259 audacious_drct_main_win_toggle( !audacious_drct_main_win_is_visible() );
422
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
260 }
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
261
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
262 void
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
263 ed_action_win_playlist ( gpointer param )
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
264 {
1023
51d0636e6dd0 [svn] - evdev-plug: works again with auddrct
giacomo
parents: 527
diff changeset
265 audacious_drct_pl_win_toggle( !audacious_drct_pl_win_is_visible () );
422
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
266 }
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
267
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
268 void
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
269 ed_action_win_equalizer ( gpointer param )
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
270 {
1023
51d0636e6dd0 [svn] - evdev-plug: works again with auddrct
giacomo
parents: 527
diff changeset
271 audacious_drct_eq_win_toggle( !audacious_drct_eq_win_is_visible () );
422
5e46b57d1eda [svn] - added evdev-plug, written-from-scratch plugin that allows to control the player via event devices on linux systems
giacomo
parents:
diff changeset
272 }
457
f5ed9a6ad3f1 [svn] - evdev-plug: added volume->mute and win->jumptofile actions
giacomo
parents: 431
diff changeset
273
f5ed9a6ad3f1 [svn] - evdev-plug: added volume->mute and win->jumptofile actions
giacomo
parents: 431
diff changeset
274 void
f5ed9a6ad3f1 [svn] - evdev-plug: added volume->mute and win->jumptofile actions
giacomo
parents: 431
diff changeset
275 ed_action_win_jtf ( gpointer param )
f5ed9a6ad3f1 [svn] - evdev-plug: added volume->mute and win->jumptofile actions
giacomo
parents: 431
diff changeset
276 {
1023
51d0636e6dd0 [svn] - evdev-plug: works again with auddrct
giacomo
parents: 527
diff changeset
277 audacious_drct_jtf_show();
457
f5ed9a6ad3f1 [svn] - evdev-plug: added volume->mute and win->jumptofile actions
giacomo
parents: 431
diff changeset
278 }