summaryrefslogtreecommitdiffstats
path: root/apps/gui/skin_engine/wps_debug.c
diff options
context:
space:
mode:
authorJonathan Gordon <rockbox@jdgordon.info>2009-08-16 18:23:00 +0000
committerJonathan Gordon <rockbox@jdgordon.info>2009-08-16 18:23:00 +0000
commit18a8e529b5d14413dce83cdb9103f3426db10708 (patch)
tree5ac9e53a987b6a48c92281b32aba9b6ca9bcab08 /apps/gui/skin_engine/wps_debug.c
parenteefe832785407c387e71aba476091e805eecc3f4 (diff)
downloadrockbox-18a8e529b5d14413dce83cdb9103f3426db10708.tar.gz
rockbox-18a8e529b5d14413dce83cdb9103f3426db10708.zip
more wps->skin engine work..
start redoing memory management in the skins to use a single larger buffer instead of lots of arrays for things like images and progressbars. This commit removes the limit on the amount of progressbars allowed on the screen, still 1 per viewport, but unlimited otherwise(!) Also a larger buffer for remote targets, same size for non-remote targets but very easy to make it bigger (technically removed the 52(?) image limit in skins, except still limited to 1 char identifiers) Unlimited "string" tokens now (limit was 1024 which was rediculously wasteful) git-svn-id: svn://svn.rockbox.org/rockbox/trunk@22350 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps/gui/skin_engine/wps_debug.c')
-rw-r--r--apps/gui/skin_engine/wps_debug.c13
1 files changed, 9 insertions, 4 deletions
diff --git a/apps/gui/skin_engine/wps_debug.c b/apps/gui/skin_engine/wps_debug.c
index 02a2cc3de9..c4a73a7cfb 100644
--- a/apps/gui/skin_engine/wps_debug.c
+++ b/apps/gui/skin_engine/wps_debug.c
@@ -23,6 +23,7 @@
#include <stdio.h>
#include <string.h>
+#include "wps.h"
#include "wps_internals.h"
#ifdef __PCTOOL__
#ifdef WPSEDITOR
@@ -548,15 +549,18 @@ static void print_line_info(struct wps_data *data)
DEBUGF("\n");
}
}
-
+#if 0
+/* NOTE: this is probaly not even needed anymore */
static void print_wps_strings(struct wps_data *data)
{
int i, len, total_len = 0, buf_used = 0;
if (wps_verbose_level > 1) DEBUGF("Strings:\n");
- for (i = 0; i < data->num_strings; i++)
+ struct skin_token_list *strings = data->strings;
+ while (strings)
{
- len = strlen(data->strings[i]);
+ char* str = (char*)strings->token->value.data;
+ len = strlen(str);
total_len += len;
buf_used += len + 1;
if (wps_verbose_level > 1)
@@ -575,6 +579,7 @@ static void print_wps_strings(struct wps_data *data)
}
}
#endif
+#endif
void print_debug_info(struct wps_data *data, enum wps_parse_error fail, int line)
{
@@ -582,7 +587,7 @@ void print_debug_info(struct wps_data *data, enum wps_parse_error fail, int line
if (debug_wps && wps_verbose_level)
{
dump_wps_tokens(data);
- print_wps_strings(data);
+ /* print_wps_strings(data); */
print_line_info(data);
}
#endif /* SIMULATOR */