mirror of
https://github.com/Rockbox/rockbox.git
synced 2025-10-14 02:27:39 -04:00
rename wps_[sub]line to skin_[sub]line
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@22606 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
parent
a363507a43
commit
8f76e7ff8f
4 changed files with 26 additions and 26 deletions
|
@ -506,7 +506,7 @@ struct skin_viewport* find_viewport(char label, struct wps_data *data)
|
|||
The return value indicates whether the line needs to be updated.
|
||||
*/
|
||||
static bool get_line(struct gui_wps *gwps,
|
||||
struct wps_subline *subline,
|
||||
struct skin_subline *subline,
|
||||
struct align_pos *align,
|
||||
char *linebuf,
|
||||
int linebuf_size)
|
||||
|
@ -648,7 +648,7 @@ static bool get_line(struct gui_wps *gwps,
|
|||
|
||||
return update;
|
||||
}
|
||||
static void get_subline_timeout(struct gui_wps *gwps, struct wps_subline *subline)
|
||||
static void get_subline_timeout(struct gui_wps *gwps, struct skin_subline *subline)
|
||||
{
|
||||
struct wps_data *data = gwps->data;
|
||||
int i;
|
||||
|
@ -682,7 +682,7 @@ static void get_subline_timeout(struct gui_wps *gwps, struct wps_subline *sublin
|
|||
|
||||
/* Calculates which subline should be displayed for the specified line
|
||||
Returns true iff the subline must be refreshed */
|
||||
static bool update_curr_subline(struct gui_wps *gwps, struct wps_line *line)
|
||||
static bool update_curr_subline(struct gui_wps *gwps, struct skin_line *line)
|
||||
{
|
||||
/* shortcut this whole thing if we need to reset the line completly */
|
||||
if (line->curr_subline == NULL)
|
||||
|
@ -920,7 +920,7 @@ static bool skin_redraw(struct gui_wps *gwps, unsigned refresh_mode)
|
|||
/* reset to first subline if refresh all flag is set */
|
||||
if (refresh_mode == WPS_REFRESH_ALL)
|
||||
{
|
||||
struct wps_line *line;
|
||||
struct skin_line *line;
|
||||
|
||||
display->set_viewport(&find_viewport(VP_DEFAULT_LABEL, data)->vp);
|
||||
display->clear_viewport();
|
||||
|
@ -1000,12 +1000,12 @@ static bool skin_redraw(struct gui_wps *gwps, unsigned refresh_mode)
|
|||
}
|
||||
|
||||
/* loop over the lines for this viewport */
|
||||
struct wps_line *line;
|
||||
struct skin_line *line;
|
||||
int line_count = 0;
|
||||
|
||||
for (line = skin_viewport->lines; line; line = line->next, line_count++)
|
||||
{
|
||||
struct wps_subline *subline;
|
||||
struct skin_subline *subline;
|
||||
memset(linebuf, 0, sizeof(linebuf));
|
||||
update_line = false;
|
||||
|
||||
|
|
|
@ -78,7 +78,7 @@ static int line_number;
|
|||
/* the current viewport */
|
||||
static struct skin_viewport *curr_vp;
|
||||
/* the current line, linked to the above viewport */
|
||||
static struct wps_line *curr_line;
|
||||
static struct skin_line *curr_line;
|
||||
|
||||
#ifdef HAVE_LCD_BITMAP
|
||||
|
||||
|
@ -407,9 +407,9 @@ static int skip_end_of_line(const char *wps_bufptr)
|
|||
}
|
||||
|
||||
/* Starts a new subline in the current line during parsing */
|
||||
static bool wps_start_new_subline(struct wps_line *line, int curr_token)
|
||||
static bool skin_start_new_subline(struct skin_line *line, int curr_token)
|
||||
{
|
||||
struct wps_subline *subline = skin_buffer_alloc(sizeof(struct wps_subline));
|
||||
struct skin_subline *subline = skin_buffer_alloc(sizeof(struct skin_subline));
|
||||
if (!subline)
|
||||
return false;
|
||||
|
||||
|
@ -425,10 +425,10 @@ static bool wps_start_new_subline(struct wps_line *line, int curr_token)
|
|||
return true;
|
||||
}
|
||||
|
||||
static bool wps_start_new_line(struct skin_viewport *vp, int curr_token)
|
||||
static bool skin_start_new_line(struct skin_viewport *vp, int curr_token)
|
||||
{
|
||||
struct wps_line *line = skin_buffer_alloc(sizeof(struct wps_line));
|
||||
struct wps_subline *subline = NULL;
|
||||
struct skin_line *line = skin_buffer_alloc(sizeof(struct skin_line));
|
||||
struct skin_subline *subline = NULL;
|
||||
if (!line)
|
||||
return false;
|
||||
|
||||
|
@ -670,7 +670,7 @@ static int parse_viewport(const char *wps_bufptr,
|
|||
skin_vp->lines = NULL;
|
||||
|
||||
curr_line = NULL;
|
||||
if (!wps_start_new_line(skin_vp, wps_data->num_tokens))
|
||||
if (!skin_start_new_line(skin_vp, wps_data->num_tokens))
|
||||
return WPS_ERROR_INVALID_PARAM;
|
||||
|
||||
|
||||
|
@ -873,7 +873,7 @@ static int parse_progressbar(const char *wps_bufptr,
|
|||
/* we need to know what line number (viewport relative) this pb is,
|
||||
* so count them... */
|
||||
int line_num = -1;
|
||||
struct wps_line *line = curr_vp->lines;
|
||||
struct skin_line *line = curr_vp->lines;
|
||||
while (line)
|
||||
{
|
||||
line_num++;
|
||||
|
@ -1386,7 +1386,7 @@ static bool wps_parse(struct wps_data *data, const char *wps_bufptr, bool debug)
|
|||
break;
|
||||
}
|
||||
|
||||
if (!wps_start_new_subline(curr_line, data->num_tokens))
|
||||
if (!skin_start_new_subline(curr_line, data->num_tokens))
|
||||
fail = PARSE_FAIL_LIMITS_EXCEEDED;
|
||||
|
||||
break;
|
||||
|
@ -1472,7 +1472,7 @@ static bool wps_parse(struct wps_data *data, const char *wps_bufptr, bool debug)
|
|||
data->tokens[data->num_tokens].next = false;
|
||||
data->num_tokens++;
|
||||
|
||||
if (!wps_start_new_line(curr_vp, data->num_tokens))
|
||||
if (!skin_start_new_line(curr_vp, data->num_tokens))
|
||||
{
|
||||
fail = PARSE_FAIL_LIMITS_EXCEEDED;
|
||||
break;
|
||||
|
@ -1706,7 +1706,7 @@ bool skin_data_load(struct wps_data *wps_data,
|
|||
curr_vp->lines = NULL;
|
||||
|
||||
curr_line = NULL;
|
||||
if (!wps_start_new_line(curr_vp, 0))
|
||||
if (!skin_start_new_line(curr_vp, 0))
|
||||
return false;
|
||||
|
||||
switch (statusbar_position(display->screen_type))
|
||||
|
|
|
@ -489,8 +489,8 @@ static void dump_wps_tokens(struct wps_data *data)
|
|||
|
||||
static void print_line_info(struct wps_data *data)
|
||||
{
|
||||
struct wps_line *line;
|
||||
struct wps_subline *subline;
|
||||
struct skin_line *line;
|
||||
struct skin_subline *subline;
|
||||
if (wps_verbose_level > 0)
|
||||
{
|
||||
struct skin_token_list *viewport_list;
|
||||
|
|
|
@ -154,7 +154,7 @@ enum wps_parse_error {
|
|||
|
||||
|
||||
/* Description of a subline on the WPS */
|
||||
struct wps_subline {
|
||||
struct skin_subline {
|
||||
|
||||
/* Index of the first token for this subline in the token array.
|
||||
Tokens of this subline end where tokens for the next subline
|
||||
|
@ -169,26 +169,26 @@ struct wps_subline {
|
|||
unsigned char time_mult;
|
||||
|
||||
/* pointer to the next subline in this line */
|
||||
struct wps_subline *next;
|
||||
struct skin_subline *next;
|
||||
};
|
||||
|
||||
/* Description of a line on the WPS. A line is a set of sublines.
|
||||
A subline is displayed for a certain amount of time. After that,
|
||||
the next subline of the line is displayed. And so on. */
|
||||
struct wps_line {
|
||||
struct skin_line {
|
||||
|
||||
/* Linked list of all the sublines on this line,
|
||||
* a line *must* have at least one subline so no need to add an extra pointer */
|
||||
struct wps_subline sublines;
|
||||
struct skin_subline sublines;
|
||||
/* pointer to the current subline */
|
||||
struct wps_subline *curr_subline;
|
||||
struct skin_subline *curr_subline;
|
||||
|
||||
/* When the next subline of this line should be displayed
|
||||
(absolute time value in ticks) */
|
||||
long subline_expire_time;
|
||||
|
||||
/* pointer to the next line */
|
||||
struct wps_line *next;
|
||||
struct skin_line *next;
|
||||
};
|
||||
|
||||
#define VP_DRAW_HIDEABLE 0x1
|
||||
|
@ -199,7 +199,7 @@ struct wps_line {
|
|||
struct skin_viewport {
|
||||
struct viewport vp; /* The LCD viewport struct */
|
||||
struct progressbar *pb;
|
||||
struct wps_line *lines;
|
||||
struct skin_line *lines;
|
||||
char hidden_flags;
|
||||
char label;
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue