mirror of
https://github.com/Rockbox/rockbox.git
synced 2025-12-07 05:35:02 -05:00
misc: Clean up a pile of -Wunused-const-variable warnings
And re-enable the warning (applies to GCC 6+) Change-Id: I7aa679ec65707db12de83c0433966b3821d07087
This commit is contained in:
parent
c7eda36341
commit
9d4632b0c3
11 changed files with 29 additions and 17 deletions
|
|
@ -82,9 +82,11 @@ static const unsigned int WINNING_TILE = 2048;
|
|||
# define BEST_SCORE_Y (2*max_numeral_height)
|
||||
#endif /* LCD_WIDTH < LCD_HEIGHT */
|
||||
|
||||
#if LCD_DEPTH > 1
|
||||
/* where to draw the background bitmap */
|
||||
static const int BACKGROUND_X = (BASE_X-MIN_SPACE);
|
||||
static const int BACKGROUND_Y = (BASE_Y-MIN_SPACE);
|
||||
#endif
|
||||
|
||||
/* key mappings */
|
||||
#define KEY_UP PLA_UP
|
||||
|
|
|
|||
|
|
@ -270,8 +270,8 @@ void xlcd_drawcircle(int cx, int cy, int radius)
|
|||
|
||||
|
||||
#if LCD_DEPTH >= 8 && LCD_DEPTH <= 16
|
||||
|
||||
#ifdef HAVE_LCD_COLOR
|
||||
#if 0 /* unused functions, enable when needed */
|
||||
#if defined(HAVE_LCD_COLOR) && (LCD_DEPTH == 16)
|
||||
static const fb_data graylut[256] = {
|
||||
#if LCD_PIXELFORMAT == RGB565
|
||||
0x0000, 0x0000, 0x0000, 0x0020, 0x0020, 0x0821, 0x0821, 0x0841,
|
||||
|
|
@ -341,10 +341,8 @@ static const fb_data graylut[256] = {
|
|||
0xbef7, 0xdef7, 0xdef7, 0xdfff, 0xdfff, 0xffff, 0xffff, 0xffff
|
||||
#endif /* LCD_PIXELFORMAT */
|
||||
};
|
||||
#endif /* HAVE_LCD_COLOR */
|
||||
#endif /* HAVE_LCD_COLOR && LCD_DEPTH == 16 */
|
||||
|
||||
/* unused functions, enable when needed */
|
||||
#if 0
|
||||
/* Draw a partial greyscale bitmap, canonical 8 bit format */
|
||||
void xlcd_gray_bitmap_part(const unsigned char *src, int src_x, int src_y,
|
||||
int stride, int x, int y, int width, int height)
|
||||
|
|
@ -412,7 +410,7 @@ void xlcd_gray_bitmap(const unsigned char *src, int x, int y, int width,
|
|||
{
|
||||
xlcd_gray_bitmap_part(src, 0, 0, width, x, y, width, height);
|
||||
}
|
||||
#endif
|
||||
#endif // unused functions
|
||||
|
||||
#ifdef HAVE_LCD_COLOR
|
||||
/* Draw a partial colour bitmap, canonical 24 bit RGB format */
|
||||
|
|
|
|||
|
|
@ -183,6 +183,7 @@ static int font_height = 0;
|
|||
|
||||
/* - - - TINYFONT - - - */
|
||||
|
||||
#if LCD_DEPTH > 1
|
||||
static const long int periodic_tinyfont_bitmaps[] = {
|
||||
0x00000000, 0x00220200, 0x00550000, 0x00575750, 0x00236200, 0x00514500, 0x00236300, 0x00220000,
|
||||
0x00244200, 0x00211200, 0x00272720, 0x00027200, 0x00000240, 0x00007000, 0x00000200, 0x00122400,
|
||||
|
|
@ -200,7 +201,6 @@ static const long int periodic_tinyfont_bitmaps[] = {
|
|||
0x00052500, 0x00055360, 0x00072700, 0x00162100, 0x00222220, 0x00432400, 0x00630000, 0x00525250
|
||||
};
|
||||
|
||||
#if LCD_DEPTH > 1
|
||||
static void periodic_tinyfont_draw_char(int x, int y, char ch)
|
||||
{
|
||||
int i,j;
|
||||
|
|
@ -234,7 +234,7 @@ static void periodic_tinyfont_draw_string(int x, int y, char * s)
|
|||
t++;
|
||||
}
|
||||
}
|
||||
#endif
|
||||
#endif /* LCD_DEPTH > 1 */
|
||||
|
||||
/*
|
||||
void periodic_tinyfont_draw_chart(int x, int y, ttk_color col)
|
||||
|
|
|
|||
|
|
@ -485,7 +485,7 @@ static const struct root_items items[] = {
|
|||
[GO_TO_SHORTCUTMENU] = { do_shortcut_menu, NULL, NULL },
|
||||
|
||||
};
|
||||
static const int nb_items = sizeof(items)/sizeof(*items);
|
||||
//static const int nb_items = sizeof(items)/sizeof(*items);
|
||||
|
||||
static int item_callback(int action,
|
||||
const struct menu_item_ex *this_item,
|
||||
|
|
|
|||
|
|
@ -224,7 +224,9 @@ static const char off_number_spell[] = "off,number,spell";
|
|||
static const int timeout_sec_common[] = {-1,0,1,2,3,4,5,6,7,8,9,10,15,20,25,30,
|
||||
45,60,90,120,180,240,300,600,900,1200,
|
||||
1500,1800,2700,3600,4500,5400,6300,7200};
|
||||
#if defined(HAVE_RECORDING)
|
||||
static const int time_recording_trigger[] = {0,1,2,5,10,15,20,25,30,60,120,300,600};
|
||||
#endif
|
||||
#if defined(HAVE_BACKLIGHT_FADING_INT_SETTING)
|
||||
static const int backlight_fade[] = {0,100,200,300,500,1000,2000,3000,5000,10000};
|
||||
#endif
|
||||
|
|
@ -1017,7 +1019,7 @@ const struct settings_list settings[] = {
|
|||
play_frequency, LANG_FREQUENCY, 0, "playback frequency", "auto",
|
||||
UNIT_KHZ, formatter_freq_unit_0_is_auto,
|
||||
getlang_freq_unit_0_is_auto,
|
||||
playback_frequency_callback,
|
||||
playback_frequency_callback,
|
||||
#if HAVE_PLAY_FREQ >= 192
|
||||
7,0,SAMPR_44,SAMPR_48,SAMPR_88,SAMPR_96,SAMPR_176,SAMPR_192),
|
||||
#elif HAVE_PLAY_FREQ >= 96
|
||||
|
|
@ -1138,7 +1140,7 @@ const struct settings_list settings[] = {
|
|||
INT_SETTING(F_BANFROMQS, max_files_in_playlist,
|
||||
LANG_MAX_FILES_IN_PLAYLIST,
|
||||
#if CONFIG_CPU == PP5002 || CONFIG_CPU == PP5020 || CONFIG_CPU == PP5022
|
||||
/** Slow CPU benefits greatly from building smaller playlists
|
||||
/** Slow CPU benefits greatly from building smaller playlists
|
||||
On the iPod Mini 2nd gen, creating a playlist of 2000 entries takes around 10 seconds */
|
||||
2000,
|
||||
#elif MEMORYSIZE > 1
|
||||
|
|
@ -1896,7 +1898,7 @@ const struct settings_list settings[] = {
|
|||
#ifdef HAVE_BACKLIGHT
|
||||
CHOICE_SETTING(0, backlight_on_button_hold,
|
||||
LANG_BACKLIGHT_ON_BUTTON_HOLD,
|
||||
#ifdef HAS_BUTTON_HOLD
|
||||
#ifdef HAS_BUTTON_HOLD
|
||||
1,
|
||||
#else
|
||||
0,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue