I must be missing a really simple concept the following gives me weird errrors:
if xTrashItemCount
pl014_Image "$LSImageFolder$launch\trash_full.ico"
else
pl014_Image "$LSImageFolder$launch\trash_empty.ico"
endif
I've tried $xTrashItemCount$, [exportedevar('xTrashItemCount')], and %#xTrashItemCount%#, I always get a variable not defined, or syntax error in the if statement.
Peter
Are you loading the module before the 'include' line that the above is in?
Also, you are aware the the above will only assign the right image after litestep starts, and not during operation?
ok, I was loding the module slightly out of order, thx!
So how can one go about deciding an image for the recycle bin?
Peter
Use the events in xinterface to fire a !labelrefresh.
ok, I like the events, I didn't know it fired on startup. so did that, and it's not liking it. literally nothing happens :(. Changed the event to just do an alert and that worked fine.
Peter
;------------------------------------------------------------------------------
; pl014 button
;------------------------------------------------------------------------------
*label pl014_
pl014_AddToGroup pl0
pl014_X $pl013_X+pl0space$
pl014_Image "$LSImageFolder$launch\trash_empty.ico"
pl014_OnLeftClick !PopupRecycle
pl014_OnRightClick !alert "$xTrashItemCount$"
pl014_ToolTip "Recycle Bin"
xTrashBecomesEmpty !ParseEvars !LabelRefresh pl014_ pl014_Image "$LSImageFolder$launch\trash_empty.ico"
xTrashBecomesFilled !ParseEvars !LabelRefresh pl014_ pl014_Image "$LSImageFolder$launch\trash_full.ico"
Does the !labelrefresh work from lsxcommand?
erm...ask at ls-u if no one finds a glaring error soon?
BTW, how long are you waiting? The module docs say it defaults to 30 second cycles.
You don't need any !parseEvars statements in there - all of those evars are "static". The following works fine for me:
xTrashCheckInterval 5
xTrashBecomesEmpty !labelRefresh trash trashFontBold false
xTrashBecomesFilled !labelRefresh trash trashFontBold true
Ought to work for images, too, but perhaps you've found a bug.
ok, problem was I was loading xInterface before xLabel. So xInterface would fire the event, but xLabel would never get it.
Peter