summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMaurus Cuelenaere <mcuelenaere@gmail.com>2009-08-17 22:41:22 +0000
committerMaurus Cuelenaere <mcuelenaere@gmail.com>2009-08-17 22:41:22 +0000
commit567d83e6bef4938a4fee5a8e3e6fe7f87e62d753 (patch)
tree54219cdf6bf416b0956f27fd7996525dd6d282da
parent13c28e8cbb1e13e044cd68be879a85f1f6b75021 (diff)
downloadrockbox-567d83e6bef4938a4fee5a8e3e6fe7f87e62d753.tar.gz
rockbox-567d83e6bef4938a4fee5a8e3e6fe7f87e62d753.tar.bz2
rockbox-567d83e6bef4938a4fee5a8e3e6fe7f87e62d753.zip
FS#10534: Make scrollbar width variable through a setting (useful for touchscreen targets)
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@22387 a1c6a512-1295-4272-9138-f99709370657
-rw-r--r--apps/gui/list.h2
-rw-r--r--apps/lang/english.lang14
-rw-r--r--apps/menus/display_menu.c3
-rw-r--r--apps/settings.h1
-rw-r--r--apps/settings_list.c3
5 files changed, 21 insertions, 2 deletions
diff --git a/apps/gui/list.h b/apps/gui/list.h
index 23997e8a65..7148e340cc 100644
--- a/apps/gui/list.h
+++ b/apps/gui/list.h
@@ -26,7 +26,7 @@
#include "icon.h"
#include "screen_access.h"
-#define SCROLLBAR_WIDTH 6
+#define SCROLLBAR_WIDTH global_settings.scrollbar_width
enum list_wrap {
LIST_WRAP_ON = 0,
diff --git a/apps/lang/english.lang b/apps/lang/english.lang
index e0fb2ee3e2..ed0e06220a 100644
--- a/apps/lang/english.lang
+++ b/apps/lang/english.lang
@@ -12671,3 +12671,17 @@
*: "Skin RAM usage"
</voice>
</phrase>
+<phrase>
+ id: LANG_SCROLLBAR_WIDTH
+ desc: in Settings -> General -> Display -> Status-/Scrollbar
+ user: core
+ <source>
+ *: "Scroll Bar Width"
+ </source>
+ <dest>
+ *: "Scroll Bar Width"
+ </dest>
+ <voice>
+ *: "Scroll bar width"
+ </voice>
+</phrase>
diff --git a/apps/menus/display_menu.c b/apps/menus/display_menu.c
index 3989a6381b..ab13aac4ab 100644
--- a/apps/menus/display_menu.c
+++ b/apps/menus/display_menu.c
@@ -329,8 +329,9 @@ MENUITEM_SETTING(buttonbar, &global_settings.buttonbar, NULL);
#endif
MENUITEM_SETTING(volume_type, &global_settings.volume_type, NULL);
MENUITEM_SETTING(battery_display, &global_settings.battery_display, NULL);
+MENUITEM_SETTING(scrollbar_width, &global_settings.scrollbar_width, NULL);
MAKE_MENU(bars_menu, ID2P(LANG_BARS_MENU), 0, Icon_NOICON,
- &scrollbar_item, &statusbar,
+ &scrollbar_item, &scrollbar_width, &statusbar,
#ifdef HAVE_REMOTE_LCD
&remote_statusbar,
#endif
diff --git a/apps/settings.h b/apps/settings.h
index 998fdc1cd9..2167e48261 100644
--- a/apps/settings.h
+++ b/apps/settings.h
@@ -769,6 +769,7 @@ struct user_settings
unsigned char remote_ui_vp_config[64]; /* viewport string for the remote lists */
#endif
#endif
+ int scrollbar_width;
};
/** global variables **/
diff --git a/apps/settings_list.c b/apps/settings_list.c
index 1254f46e6c..ef496d5c53 100644
--- a/apps/settings_list.c
+++ b/apps/settings_list.c
@@ -1550,6 +1550,9 @@ const struct settings_list settings[] = {
VIEWPORT_SETTING(remote_ui_vp_config, "remote ui viewport"),
#endif
#endif
+
+ INT_SETTING(0, scrollbar_width, LANG_SCROLLBAR_WIDTH, 6, "scrollbar width",
+ UNIT_INT, 6, 20, 1, NULL, NULL, NULL),
};
const int nb_settings = sizeof(settings)/sizeof(*settings);