Linus Nielsen Feltzing | 7da9477 | 2005-10-28 00:00:00 +0000 | [diff] [blame] | 1 | /*************************************************************************** |
| 2 | * __________ __ ___. |
| 3 | * Open \______ \ ____ ____ | | _\_ |__ _______ ___ |
| 4 | * Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ / |
| 5 | * Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < < |
| 6 | * Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \ |
| 7 | * \/ \/ \/ \/ \/ |
| 8 | * $Id$ |
| 9 | * |
Jonathan Gordon | 6a5cc0b | 2007-04-16 09:14:36 +0000 | [diff] [blame] | 10 | * Copyright (C) 2007 Jonathan Gordon |
Linus Nielsen Feltzing | 7da9477 | 2005-10-28 00:00:00 +0000 | [diff] [blame] | 11 | * |
Daniel Stenberg | 2acc0ac | 2008-06-28 18:10:04 +0000 | [diff] [blame] | 12 | * This program is free software; you can redistribute it and/or |
| 13 | * modify it under the terms of the GNU General Public License |
| 14 | * as published by the Free Software Foundation; either version 2 |
| 15 | * of the License, or (at your option) any later version. |
Linus Nielsen Feltzing | 7da9477 | 2005-10-28 00:00:00 +0000 | [diff] [blame] | 16 | * |
| 17 | * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY |
| 18 | * KIND, either express or implied. |
| 19 | * |
| 20 | ****************************************************************************/ |
Jonathan Gordon | 6a5cc0b | 2007-04-16 09:14:36 +0000 | [diff] [blame] | 21 | #include <stdio.h> |
| 22 | #include <stdlib.h> |
| 23 | #include <string.h> |
| 24 | #include "inttypes.h" |
Linus Nielsen Feltzing | 7da9477 | 2005-10-28 00:00:00 +0000 | [diff] [blame] | 25 | #include "config.h" |
| 26 | #include "icon.h" |
| 27 | #include "screen_access.h" |
| 28 | #include "icons.h" |
Jonathan Gordon | 6a5cc0b | 2007-04-16 09:14:36 +0000 | [diff] [blame] | 29 | #include "settings.h" |
| 30 | #include "bmp.h" |
| 31 | #include "filetypes.h" |
Linus Nielsen Feltzing | 7da9477 | 2005-10-28 00:00:00 +0000 | [diff] [blame] | 32 | |
Björn Stenberg | ac488f8 | 2008-11-03 14:37:50 +0000 | [diff] [blame] | 33 | #include "bitmaps/default_icons.h" |
Magnus Holmgren | 392a4ef | 2007-04-18 17:49:32 +0000 | [diff] [blame] | 34 | #if defined(HAVE_REMOTE_LCD) && (NB_SCREENS > 1) |
Björn Stenberg | ac488f8 | 2008-11-03 14:37:50 +0000 | [diff] [blame] | 35 | #include "bitmaps/remote_default_icons.h" |
Jonathan Gordon | 6a5cc0b | 2007-04-16 09:14:36 +0000 | [diff] [blame] | 36 | #endif |
| 37 | |
Jonathan Gordon | e9610dc | 2007-04-17 08:37:01 +0000 | [diff] [blame] | 38 | /* These are just the file names, the full path is snprint'ed when used */ |
Jens Arnold | f87eaf3 | 2007-04-17 00:29:04 +0000 | [diff] [blame] | 39 | #define DEFAULT_VIEWER_BMP "viewers" |
| 40 | #define DEFAULT_REMOTE_VIEWER_BMP "remote_viewers" |
Jonathan Gordon | 6a5cc0b | 2007-04-16 09:14:36 +0000 | [diff] [blame] | 41 | |
Karl Kurbjun | f451108 | 2009-08-18 00:53:27 +0000 | [diff] [blame] | 42 | /* These can be defined in config-<target>.h, if it is not provide defaults */ |
| 43 | #if !defined(MAX_ICON_HEIGHT) |
Jonathan Gordon | 6a5cc0b | 2007-04-16 09:14:36 +0000 | [diff] [blame] | 44 | #define MAX_ICON_HEIGHT 24 |
Karl Kurbjun | f451108 | 2009-08-18 00:53:27 +0000 | [diff] [blame] | 45 | #endif |
Jonathan Gordon | 6a5cc0b | 2007-04-16 09:14:36 +0000 | [diff] [blame] | 46 | |
Karl Kurbjun | f451108 | 2009-08-18 00:53:27 +0000 | [diff] [blame] | 47 | #if !defined(MAX_ICON_WIDTH) |
| 48 | #define MAX_ICON_WIDTH 24 |
| 49 | #endif |
Jonathan Gordon | 6a5cc0b | 2007-04-16 09:14:36 +0000 | [diff] [blame] | 50 | |
| 51 | /* We dont actually do anything with these pointers, |
| 52 | but they need to be grouped like this to save code |
| 53 | so storing them as void* is ok. (stops compile warning) */ |
| 54 | static const void * inbuilt_icons[NB_SCREENS] = { |
| 55 | (void*)default_icons |
Magnus Holmgren | 392a4ef | 2007-04-18 17:49:32 +0000 | [diff] [blame] | 56 | #if defined(HAVE_REMOTE_LCD) && (NB_SCREENS > 1) |
Jonathan Gordon | 6a5cc0b | 2007-04-16 09:14:36 +0000 | [diff] [blame] | 57 | , (void*)remote_default_icons |
| 58 | #endif |
| 59 | }; |
| 60 | |
| 61 | static const int default_width[NB_SCREENS] = { |
| 62 | BMPWIDTH_default_icons |
Magnus Holmgren | 392a4ef | 2007-04-18 17:49:32 +0000 | [diff] [blame] | 63 | #if defined(HAVE_REMOTE_LCD) && (NB_SCREENS > 1) |
Jonathan Gordon | 6a5cc0b | 2007-04-16 09:14:36 +0000 | [diff] [blame] | 64 | , BMPWIDTH_remote_default_icons |
| 65 | #endif |
| 66 | }; |
| 67 | |
| 68 | /* height of whole file */ |
| 69 | static const int default_height[NB_SCREENS] = { |
| 70 | BMPHEIGHT_default_icons |
Magnus Holmgren | 392a4ef | 2007-04-18 17:49:32 +0000 | [diff] [blame] | 71 | #if defined(HAVE_REMOTE_LCD) && (NB_SCREENS > 1) |
Jonathan Gordon | 6a5cc0b | 2007-04-16 09:14:36 +0000 | [diff] [blame] | 72 | , BMPHEIGHT_remote_default_icons |
| 73 | #endif |
| 74 | }; |
| 75 | |
| 76 | #define IMG_BUFSIZE (MAX_ICON_HEIGHT * MAX_ICON_WIDTH * \ |
| 77 | Icon_Last_Themeable *LCD_DEPTH/8) |
Jonathan Gordon | a9c1df4 | 2007-04-16 14:33:29 +0000 | [diff] [blame] | 78 | static unsigned char icon_buffer[NB_SCREENS][IMG_BUFSIZE]; |
Jonathan Gordon | 6a5cc0b | 2007-04-16 09:14:36 +0000 | [diff] [blame] | 79 | static bool custom_icons_loaded[NB_SCREENS] = {false}; |
| 80 | static struct bitmap user_iconset[NB_SCREENS]; |
| 81 | |
Jonathan Gordon | a9c1df4 | 2007-04-16 14:33:29 +0000 | [diff] [blame] | 82 | static unsigned char viewer_icon_buffer[NB_SCREENS][IMG_BUFSIZE]; |
Jonathan Gordon | 6a5cc0b | 2007-04-16 09:14:36 +0000 | [diff] [blame] | 83 | static bool viewer_icons_loaded[NB_SCREENS] = {false}; |
| 84 | static struct bitmap viewer_iconset[NB_SCREENS]; |
| 85 | |
| 86 | |
| 87 | #define ICON_HEIGHT(screen) (!custom_icons_loaded[screen]? \ |
| 88 | default_height[screen] : \ |
| 89 | user_iconset[screen].height) \ |
| 90 | / Icon_Last_Themeable |
| 91 | |
| 92 | #define ICON_WIDTH(screen) (!custom_icons_loaded[screen]? \ |
| 93 | default_width[screen] : \ |
| 94 | user_iconset[screen].width) |
| 95 | |
| 96 | /* x,y in letters, not pixles */ |
| 97 | void screen_put_icon(struct screen * display, |
| 98 | int x, int y, enum themable_icons icon) |
| 99 | { |
| 100 | screen_put_icon_with_offset(display, x, y, 0, 0, icon); |
| 101 | } |
| 102 | |
| 103 | void screen_put_icon_with_offset(struct screen * display, |
| 104 | int x, int y, int off_x, int off_y, |
| 105 | enum themable_icons icon) |
| 106 | { |
| 107 | int xpos, ypos; |
| 108 | int width, height; |
| 109 | int screen = display->screen_type; |
| 110 | display->getstringsize((unsigned char *)"M", &width, &height); |
| 111 | xpos = x*ICON_WIDTH(screen) + off_x; |
Jonathan Gordon | bdbdb97 | 2008-06-23 13:20:35 +0000 | [diff] [blame] | 112 | ypos = y*height + off_y; |
Jonathan Gordon | 6a5cc0b | 2007-04-16 09:14:36 +0000 | [diff] [blame] | 113 | |
| 114 | if ( height > ICON_HEIGHT(screen) )/* center the cursor */ |
| 115 | ypos += (height - ICON_HEIGHT(screen)) / 2; |
| 116 | screen_put_iconxy(display, xpos, ypos, icon); |
| 117 | } |
| 118 | |
| 119 | /* x,y in pixels */ |
Jens Arnold | 539c513 | 2007-04-16 23:55:19 +0000 | [diff] [blame] | 120 | void screen_put_iconxy(struct screen * display, |
Jonathan Gordon | 6a5cc0b | 2007-04-16 09:14:36 +0000 | [diff] [blame] | 121 | int xpos, int ypos, enum themable_icons icon) |
| 122 | { |
Jens Arnold | 539c513 | 2007-04-16 23:55:19 +0000 | [diff] [blame] | 123 | const void *data; |
Jonathan Gordon | 6a5cc0b | 2007-04-16 09:14:36 +0000 | [diff] [blame] | 124 | int screen = display->screen_type; |
Magnus Holmgren | 62994d4 | 2007-04-16 19:17:37 +0000 | [diff] [blame] | 125 | int width = ICON_WIDTH(screen); |
| 126 | int height = ICON_HEIGHT(screen); |
Karl Kurbjun | 7bb7c5f | 2009-08-29 19:31:29 +0000 | [diff] [blame] | 127 | int stride; |
Jens Arnold | 539c513 | 2007-04-16 23:55:19 +0000 | [diff] [blame] | 128 | screen_bitmap_part_func *draw_func = NULL; |
Jonathan Gordon | 6a5cc0b | 2007-04-16 09:14:36 +0000 | [diff] [blame] | 129 | |
| 130 | if (icon == Icon_NOICON) |
| 131 | { |
Magnus Holmgren | 62994d4 | 2007-04-16 19:17:37 +0000 | [diff] [blame] | 132 | screen_clear_area(display, xpos, ypos, width, height); |
Jonathan Gordon | 6a5cc0b | 2007-04-16 09:14:36 +0000 | [diff] [blame] | 133 | return; |
| 134 | } |
| 135 | else if (icon >= Icon_Last_Themeable) |
| 136 | { |
| 137 | icon -= Icon_Last_Themeable; |
Jonathan Gordon | b6658bb | 2007-04-16 12:50:01 +0000 | [diff] [blame] | 138 | if (!viewer_icons_loaded[screen] || |
Jonathan Gordon | 9d3694c | 2007-04-22 08:50:24 +0000 | [diff] [blame] | 139 | (global_status.viewer_icon_count*height |
| 140 | > viewer_iconset[screen].height) || |
Magnus Holmgren | 62994d4 | 2007-04-16 19:17:37 +0000 | [diff] [blame] | 141 | (icon * height > viewer_iconset[screen].height)) |
Jonathan Gordon | 6a5cc0b | 2007-04-16 09:14:36 +0000 | [diff] [blame] | 142 | { |
Jonathan Gordon | 9d3694c | 2007-04-22 08:50:24 +0000 | [diff] [blame] | 143 | screen_put_iconxy(display, xpos, ypos, Icon_Questionmark); |
Jonathan Gordon | 6a5cc0b | 2007-04-16 09:14:36 +0000 | [diff] [blame] | 144 | return; |
| 145 | } |
Karl Kurbjun | 7bb7c5f | 2009-08-29 19:31:29 +0000 | [diff] [blame] | 146 | data = viewer_iconset[screen].data; |
Karl Kurbjun | 2512357 | 2009-09-04 00:46:24 +0000 | [diff] [blame] | 147 | stride = STRIDE( display->screen_type, viewer_iconset[screen].width, |
Karl Kurbjun | 7bb7c5f | 2009-08-29 19:31:29 +0000 | [diff] [blame] | 148 | viewer_iconset[screen].height); |
Jonathan Gordon | 6a5cc0b | 2007-04-16 09:14:36 +0000 | [diff] [blame] | 149 | } |
| 150 | else if (custom_icons_loaded[screen]) |
| 151 | { |
Karl Kurbjun | 7bb7c5f | 2009-08-29 19:31:29 +0000 | [diff] [blame] | 152 | data = user_iconset[screen].data; |
Karl Kurbjun | 2512357 | 2009-09-04 00:46:24 +0000 | [diff] [blame] | 153 | stride = STRIDE( display->screen_type, user_iconset[screen].width, |
Karl Kurbjun | 7bb7c5f | 2009-08-29 19:31:29 +0000 | [diff] [blame] | 154 | user_iconset[screen].height); |
Jonathan Gordon | 6a5cc0b | 2007-04-16 09:14:36 +0000 | [diff] [blame] | 155 | } |
| 156 | else |
| 157 | { |
Karl Kurbjun | 7bb7c5f | 2009-08-29 19:31:29 +0000 | [diff] [blame] | 158 | data = inbuilt_icons[screen]; |
Karl Kurbjun | 2512357 | 2009-09-04 00:46:24 +0000 | [diff] [blame] | 159 | stride = STRIDE( display->screen_type, BMPWIDTH_default_icons, |
| 160 | BMPHEIGHT_default_icons); |
Jonathan Gordon | 6a5cc0b | 2007-04-16 09:14:36 +0000 | [diff] [blame] | 161 | } |
| 162 | /* add some left padding to the icons if they are on the edge */ |
| 163 | if (xpos == 0) |
| 164 | xpos++; |
| 165 | |
Jens Arnold | ded87cf | 2007-04-17 00:08:58 +0000 | [diff] [blame] | 166 | #if (LCD_DEPTH == 16) || defined(LCD_REMOTE_DEPTH) && (LCD_REMOTE_DEPTH == 16) |
Jens Arnold | 539c513 | 2007-04-16 23:55:19 +0000 | [diff] [blame] | 167 | if (display->depth == 16) |
Karl Kurbjun | 7bb7c5f | 2009-08-29 19:31:29 +0000 | [diff] [blame] | 168 | draw_func = display->transparent_bitmap_part; |
Jonathan Gordon | 6a5cc0b | 2007-04-16 09:14:36 +0000 | [diff] [blame] | 169 | else |
| 170 | #endif |
Karl Kurbjun | 7bb7c5f | 2009-08-29 19:31:29 +0000 | [diff] [blame] | 171 | draw_func = display->bitmap_part; |
Jens Arnold | 539c513 | 2007-04-16 23:55:19 +0000 | [diff] [blame] | 172 | |
Karl Kurbjun | 7bb7c5f | 2009-08-29 19:31:29 +0000 | [diff] [blame] | 173 | draw_func(data, 0, height * icon, stride, xpos, ypos, width, height); |
Linus Nielsen Feltzing | 7da9477 | 2005-10-28 00:00:00 +0000 | [diff] [blame] | 174 | } |
| 175 | |
Kevin Ferrare | 8517ed8 | 2005-11-16 02:12:25 +0000 | [diff] [blame] | 176 | void screen_put_cursorxy(struct screen * display, int x, int y, bool on) |
Linus Nielsen Feltzing | 7da9477 | 2005-10-28 00:00:00 +0000 | [diff] [blame] | 177 | { |
| 178 | #ifdef HAVE_LCD_BITMAP |
Jonathan Gordon | 6a5cc0b | 2007-04-16 09:14:36 +0000 | [diff] [blame] | 179 | screen_put_icon(display, x, y, on?Icon_Cursor:0); |
Linus Nielsen Feltzing | 7da9477 | 2005-10-28 00:00:00 +0000 | [diff] [blame] | 180 | #else |
Jonathan Gordon | 6a5cc0b | 2007-04-16 09:14:36 +0000 | [diff] [blame] | 181 | screen_put_icon(display, x, y, on?CURSOR_CHAR:-1); |
Linus Nielsen Feltzing | 7da9477 | 2005-10-28 00:00:00 +0000 | [diff] [blame] | 182 | #endif |
Kevin Ferrare | 8517ed8 | 2005-11-16 02:12:25 +0000 | [diff] [blame] | 183 | |
Linus Nielsen Feltzing | 7da9477 | 2005-10-28 00:00:00 +0000 | [diff] [blame] | 184 | } |
Jonathan Gordon | 6a5cc0b | 2007-04-16 09:14:36 +0000 | [diff] [blame] | 185 | enum Iconset { |
| 186 | Iconset_Mainscreen, |
| 187 | Iconset_Mainscreen_viewers, |
Magnus Holmgren | 392a4ef | 2007-04-18 17:49:32 +0000 | [diff] [blame] | 188 | #if defined(HAVE_REMOTE_LCD) && (NB_SCREENS > 1) |
Jonathan Gordon | 6a5cc0b | 2007-04-16 09:14:36 +0000 | [diff] [blame] | 189 | Iconset_Remotescreen, |
| 190 | Iconset_Remotescreen_viewers, |
| 191 | #endif |
| 192 | }; |
| 193 | |
Magnus Holmgren | 62994d4 | 2007-04-16 19:17:37 +0000 | [diff] [blame] | 194 | static void load_icons(const char* filename, enum Iconset iconset, |
| 195 | bool allow_disable) |
Jonathan Gordon | 6a5cc0b | 2007-04-16 09:14:36 +0000 | [diff] [blame] | 196 | { |
| 197 | int size_read; |
| 198 | bool *loaded_ok = NULL; |
| 199 | struct bitmap *bmp = NULL; |
Jens Arnold | 79a8b41 | 2007-04-17 01:03:25 +0000 | [diff] [blame] | 200 | int bmpformat = (FORMAT_NATIVE|FORMAT_DITHER); |
Jonathan Gordon | 6a5cc0b | 2007-04-16 09:14:36 +0000 | [diff] [blame] | 201 | |
| 202 | switch (iconset) |
| 203 | { |
| 204 | case Iconset_Mainscreen: |
| 205 | loaded_ok = &custom_icons_loaded[SCREEN_MAIN]; |
| 206 | bmp = &user_iconset[SCREEN_MAIN]; |
| 207 | bmp->data = icon_buffer[SCREEN_MAIN]; |
| 208 | break; |
| 209 | case Iconset_Mainscreen_viewers: |
| 210 | loaded_ok = &viewer_icons_loaded[SCREEN_MAIN]; |
| 211 | bmp = &viewer_iconset[SCREEN_MAIN]; |
| 212 | bmp->data = viewer_icon_buffer[SCREEN_MAIN]; |
| 213 | break; |
Magnus Holmgren | 392a4ef | 2007-04-18 17:49:32 +0000 | [diff] [blame] | 214 | #if defined(HAVE_REMOTE_LCD) && (NB_SCREENS > 1) |
Jonathan Gordon | 6a5cc0b | 2007-04-16 09:14:36 +0000 | [diff] [blame] | 215 | case Iconset_Remotescreen: |
Jonathan Gordon | ccaf24a | 2007-04-16 11:01:41 +0000 | [diff] [blame] | 216 | loaded_ok = &custom_icons_loaded[SCREEN_REMOTE]; |
| 217 | bmp = &user_iconset[SCREEN_REMOTE]; |
| 218 | bmp->data = icon_buffer[SCREEN_REMOTE]; |
Jens Arnold | 79a8b41 | 2007-04-17 01:03:25 +0000 | [diff] [blame] | 219 | bmpformat |= FORMAT_REMOTE; |
Jonathan Gordon | 6a5cc0b | 2007-04-16 09:14:36 +0000 | [diff] [blame] | 220 | break; |
| 221 | case Iconset_Remotescreen_viewers: |
| 222 | loaded_ok = &viewer_icons_loaded[SCREEN_REMOTE]; |
| 223 | bmp = &viewer_iconset[SCREEN_REMOTE]; |
| 224 | bmp->data = viewer_icon_buffer[SCREEN_REMOTE]; |
Jens Arnold | 79a8b41 | 2007-04-17 01:03:25 +0000 | [diff] [blame] | 225 | bmpformat |= FORMAT_REMOTE; |
Jonathan Gordon | 6a5cc0b | 2007-04-16 09:14:36 +0000 | [diff] [blame] | 226 | break; |
| 227 | #endif |
| 228 | } |
| 229 | |
| 230 | *loaded_ok = false; |
Jonathan Gordon | 754d919 | 2007-04-17 06:37:22 +0000 | [diff] [blame] | 231 | if (!allow_disable || (filename[0] && filename[0] != '-')) |
Jonathan Gordon | 6a5cc0b | 2007-04-16 09:14:36 +0000 | [diff] [blame] | 232 | { |
Magnus Holmgren | 62994d4 | 2007-04-16 19:17:37 +0000 | [diff] [blame] | 233 | char path[MAX_PATH]; |
| 234 | |
| 235 | snprintf(path, sizeof(path), "%s/%s.bmp", ICON_DIR, filename); |
Andrew Mahone | 9058620 | 2008-12-26 07:05:13 +0000 | [diff] [blame] | 236 | size_read = read_bmp_file(path, bmp, IMG_BUFSIZE, bmpformat, NULL); |
Jonathan Gordon | 6a5cc0b | 2007-04-16 09:14:36 +0000 | [diff] [blame] | 237 | if (size_read > 0) |
| 238 | { |
| 239 | *loaded_ok = true; |
| 240 | } |
| 241 | } |
| 242 | } |
| 243 | |
| 244 | |
| 245 | void icons_init(void) |
| 246 | { |
Magnus Holmgren | 62994d4 | 2007-04-16 19:17:37 +0000 | [diff] [blame] | 247 | load_icons(global_settings.icon_file, Iconset_Mainscreen, true); |
| 248 | |
| 249 | if (*global_settings.viewers_icon_file) |
Jonathan Gordon | 6a5cc0b | 2007-04-16 09:14:36 +0000 | [diff] [blame] | 250 | { |
Magnus Holmgren | 62994d4 | 2007-04-16 19:17:37 +0000 | [diff] [blame] | 251 | load_icons(global_settings.viewers_icon_file, |
| 252 | Iconset_Mainscreen_viewers, true); |
Jonathan Gordon | 6a5cc0b | 2007-04-16 09:14:36 +0000 | [diff] [blame] | 253 | read_viewer_theme_file(); |
| 254 | } |
| 255 | else |
Jonathan Gordon | 6a5cc0b | 2007-04-16 09:14:36 +0000 | [diff] [blame] | 256 | { |
Magnus Holmgren | 62994d4 | 2007-04-16 19:17:37 +0000 | [diff] [blame] | 257 | load_icons(DEFAULT_VIEWER_BMP, Iconset_Mainscreen_viewers, false); |
Jonathan Gordon | 6a5cc0b | 2007-04-16 09:14:36 +0000 | [diff] [blame] | 258 | } |
Magnus Holmgren | 62994d4 | 2007-04-16 19:17:37 +0000 | [diff] [blame] | 259 | |
Magnus Holmgren | 392a4ef | 2007-04-18 17:49:32 +0000 | [diff] [blame] | 260 | #if defined(HAVE_REMOTE_LCD) && (NB_SCREENS > 1) |
Magnus Holmgren | 62994d4 | 2007-04-16 19:17:37 +0000 | [diff] [blame] | 261 | load_icons(global_settings.remote_icon_file, |
| 262 | Iconset_Remotescreen, true); |
| 263 | |
| 264 | if (*global_settings.remote_viewers_icon_file) |
Jonathan Gordon | 6a5cc0b | 2007-04-16 09:14:36 +0000 | [diff] [blame] | 265 | { |
Magnus Holmgren | 62994d4 | 2007-04-16 19:17:37 +0000 | [diff] [blame] | 266 | load_icons(global_settings.remote_viewers_icon_file, |
| 267 | Iconset_Remotescreen_viewers, true); |
Jonathan Gordon | 6a5cc0b | 2007-04-16 09:14:36 +0000 | [diff] [blame] | 268 | } |
| 269 | else |
Magnus Holmgren | 62994d4 | 2007-04-16 19:17:37 +0000 | [diff] [blame] | 270 | { |
| 271 | load_icons(DEFAULT_REMOTE_VIEWER_BMP, |
| 272 | Iconset_Remotescreen_viewers, false); |
| 273 | } |
Jonathan Gordon | 6a5cc0b | 2007-04-16 09:14:36 +0000 | [diff] [blame] | 274 | #endif |
| 275 | } |
| 276 | |
| 277 | int get_icon_width(enum screen_type screen_type) |
| 278 | { |
| 279 | return ICON_WIDTH(screen_type); |
| 280 | } |