Problems identified when loading .xml files.
- Tried to parse a png.
dbLoad[db.c:339] INFO App Description file: /etc/launcher/Mask.png
/etc/launcher/Mask.png:1: parser error : Start tag expected, '<' not found
dbLoad[db.c:347] ERROR Failed to parse Mask.png
The init processing does find the imrest.xml and parses it.
dbLoad[db.c:339] INFO App Description file: /etc/launcher/.statusbar/imrest.xml
dbLoad[db.c:367] INFO Node name: appName
parseElement[db.c:237] INFO Key = *imrest*
dbLoad[db.c:367] INFO Node name: author
parseElement[db.c:237] INFO Key = *Michael J. Hammel*
dbLoad[db.c:367] INFO Node name: contact
parseElement[db.c:237] INFO Key = *mjhammel@graphics-muse.org*
dbLoad[db.c:367] INFO Node name: command
parseElement[db.c:237] INFO Key = */usr/bin/imrest-app*
dbLoad[db.c:367] INFO Node name: icon
parseElement[db.c:237] INFO Key = *icons/imrest.png*
dbLoad[db.c:367] INFO Node name: splash
parseElement[db.c:237] INFO Key = *icons/imrest.png*
dbLoad[db.c:367] INFO Node name: description
parseElement[db.c:237] INFO Key = *Pair management for Ironman's RESTful server.*
dbLoad[db.c:425] INFO Loaded app: imrest
dbLoad[db.c:443] INFO Found 1 application descriptions in /etc/launcher/.statusbar
The problem can be tracked to the code in launcher.c:draw_status() with the following line
if ( appEntry->active )
The app is not active until it's pressed in the status bar, so this never displays the pair icon for Ironman. If I remove this line then the pair icon shows up but the network icon goes away.
Since both network and pair icons are handled by draw_status() if DRAW_ICONS is passed to it then the wrapping conditional for each can be combined into a single conditional which then only requires a single cairo update. That should, I think, fix this problem.
This only works for status bar apps that are pressed by the user. For apps that need to show status of background events (like the network drop out) then the might not need to be shown at all unless the event happens. That would require a different processing here - possibly by setting a field in the xml that says "always show" or "show on event only". Something like that.