1 /***************************************************************************
3 * Open \______ \ ____ ____ | | _\_ |__ _______ ___
4 * Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ /
5 * Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < <
6 * Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \
10 * Copyright (C) 2005 by Kevin Ferrare
12 * All files in this archive are subject to the GNU General Public License.
13 * See the file COPYING in the source tree root for full license agreement.
15 * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY
16 * KIND, either express or implied.
18 ****************************************************************************/
22 #ifdef HAVE_QUICKSCREEN
24 #ifndef _GUI_QUICKSCREEN_H_
25 #define _GUI_QUICKSCREEN_H_
27 #include "option_select.h"
28 #include "screen_access.h"
30 struct gui_quickscreen
;
32 * Callback function called each time the quickscreen gets modified
33 * - qs : the quickscreen that did the modification
35 typedef void (quickscreen_callback
)(struct gui_quickscreen
* qs
);
37 struct gui_quickscreen
39 struct option_select
*left_option
;
40 struct option_select
*bottom_option
;
41 struct option_select
*right_option
;
42 quickscreen_callback
*callback
;
46 * Initializes a quickscreen
47 * - qs : the quickscreen
48 * - left_option, bottom_option, right_option : a list of choices
50 * - left_right_title : the 2nd line of the title
51 * on the left and on the right
52 * - callback : a callback function called each time the quickscreen
55 void gui_quickscreen_init(struct gui_quickscreen
* qs
,
56 struct option_select
*left_option
,
57 struct option_select
*bottom_option
,
58 struct option_select
*right_option
,
59 quickscreen_callback
*callback
);
63 * Runs the quickscreen on all available screens, if button_enter is released, quits
64 * - qs : the quickscreen
65 * - button_enter : button pressed at the same time the quickscreen is displayed
66 * returns : true if usb was connected, false otherwise
68 bool gui_syncquickscreen_run(struct gui_quickscreen
* qs
, int button_enter
);
70 #endif /*_GUI_QUICK_SCREEN_H_*/
71 #endif /* HAVE_QUICKSCREEN */