Rockbox

This is the bug/patch tracker for Rockbox. Click here for more information.

Quick links: Bugs · Patches · Rockbox frontpage

Tasklist

FS#11389 - Work to make the theme parser more rockbox friendly

Attached to Project: Rockbox
Opened by Jonathan Gordon (jdgordon) - Thursday, 10 June 2010, 16:54 GMT+2
Last edited by Jonathan Gordon (jdgordon) - Friday, 11 June 2010, 01:36 GMT+2
Task Type Patches
Category Utils
Status Closed
Assigned To No-one
Player Type All players
Severity Low
Priority Normal
Reported Version Release 3.4
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Private No

Details

This does some housecleaning to make it more friendly to a rockbox build..

in a rockbox build ROCKBOX is defined so use that to determine which memory management to use. Dont bother storing comments in ROCKBOX build.

Change the element->text to void*data to make elemets more usable in a ROCKBOX build
   parser_integration.0.diff (14.6 KiB)
 utils/themeeditor/parsetreenode.cpp  |   14 +--
 utils/themeeditor/skin_debug.c       |   12 +-
 utils/themeeditor/parsetreemodel.cpp |    4 
 utils/themeeditor/skin_parser.c      |  161 ++++++++++++++---------------------
 utils/themeeditor/skin_parser.h      |   18 +--
 5 files changed, 90 insertions(+), 119 deletions(-)

This task depends upon

Closed by  Jonathan Gordon (jdgordon)
Friday, 11 June 2010, 01:36 GMT+2
Reason for closing:  Accepted
Comment by Jonathan Gordon (jdgordon) - Thursday, 10 June 2010, 17:36 GMT+2
I've just re-read the conditional code and it looks like parameters and children are NOT used at the same time, could they be merged into a union (and the counter can then be shared) that drops the element size down to 7*4 bytes, if line can be removed also thats another 4 bytes saved.

(Yes I agree these savings are pretty small, but if we can dynamically size the skin buffer then every saved byte is a free byte for the playback buffer :) )

edit: or alternatively, why not put the params for the tag into the CONDITIONAL element instead of children[0]? That is what I assumed has happening anyway and seems to be clearer...

Loading...