Need hooking help Thread last updated on 2006-09-09 10:58:55

Posted by member 343162 on 2006-09-07 21:55:37

Hey guys,

I just wanted to get your help on hookers! Thats right I really need help with these bitches.

Heres what I'm trying to do:

While editing Elemental by split, I decided his nifty auto hide xlabels needed some lsxcommand. So I did my thing, got it all working, but now I need the lsxcommand box actually in the label so I can type, enter commands searches etc. I read and read, found out about hooks, but still havn't gotten it to work. Heres my code:

CommandWaitForBox
*lsxModuleHook !CommandBoxHook

*Label lsx

(general posistioning shit down here etc.)


When I try clicking the box, even without autohide, nothing happens. Even right clicking it doesn't show lsx's context menu.

Thanks

Posted by member 248213 on 2006-09-07 23:20:51 link

You need to load lsx before xlabel.

Any hooked module must be loaded before the hooker.

Posted by member 343162 on 2006-09-07 23:44:06 link

lol
I read upon that and made sure it was done...same problem:

*NetLoadModule jdesk-0.73
*NetLoadModule jkey-0.38
*NetLoadModule ckHotSpots-2.3.3
*NetLoadModule xPopup-1.1.9
*NetLoadModule xTray-1.0
*NetLoadModule rabidvwm-1.2.2
*NetLoadModule xTaskbar-1.4.1
*NetLoadModule mzscript-0.9.13
*NetLoadModule lssliderfoo-1.8
*NetLoadModule xTextEdit-0.5
*NetLoadModule dynamp-0.50
*NetLoadModule lsxcommand-1.9.4
*NetLoadModule xLabel-3.4.5

Posted by member 7223 on 2006-09-07 23:52:54 link

Hookin doesn't support AlphaMap

Posted by member 5575 on 2006-09-07 23:56:37 link

Perhaps try setting this:

CommandAlwaysOnTop true

Remember that your commandx and commandy are relative to the hooker, erm, the label in which lsxcommand is hooked. So "0" is a good value for both, unless you have some sort of margin/border/etc.

Posted by member 343162 on 2006-09-08 00:03:57 link

Did work....

I can't have 0 for a value because I need it in that specific posistion

IF lsxDisable = False

IF lsxAutoHide = True
lsxY "$ResolutionY-1050$"
*ckHotspot "$ResolutionX-191$" "$ResolutionY-1050$" 154 50 !lsx_show !lsx_hide
ENDIF

CommandAlwaysOnTop true
CommandWaitForBox
*lsxModuleHook !CommandBoxHook

*Label lsx
lsxX "$ResolutionX-191$"
lsxY 27
lsxHeight 18
lsxWidth 154
lsxImage lsx_bg.png


CommandHiddenOnStart true

CommandTextSize 15
CommandTextColor 9a9a9a
CommandTextFontFace AvantGarde LT Medium

CommandSearchEngineList "$ModulesDir$docs\lsxcommand-1.9.4\engines.list"
CommandHistoryFile "$ModulesDir$docs\lsxcommand-1.9.4\history.ini"
CommandHistoryEntries 20
CommandHistoryMenuEntries 10
CommandSelectAllOnFocus true
CommandClearHistoryOnStartup true
CommandNewestHistoryItemsOnTop true
CommandUnixHistory true
CommandAddExternalsToHistory true
CommandTabFileComplete true

CommandContextMenuStandardItems 0

CommandExplorePaths

CommandContextMenuExecute

ENDIF


Theres the whole LSX chunk while my script for autohide (even though that shouldn't be the problem):

;LSX Command--------------------------------

*Script bang !lsx_show
*Script exec !Labelmove lsx "$ResolutionX-191$" "27" 20 30
*Script ~bang

*Script bang !lsx_hide
*Script exec !Labelmove lsx "$ResolutionX-191$" "$ResolutionY-1050$" 20 30
*Script ~bang

Posted by member 5575 on 2006-09-08 00:09:35 link

Those are the settings for the hooking label, but where are the settings for lsxcommand itself? You need both, AFAIK. In my theme the label is cmdlabel, and it looks like so:

cmdBorder 2

cmdLabelX $dateTimeX$
cmdLabelY $mainbarGroupY$
cmdLabelWidth $dateTimeWidth$
cmdLabelHeight $mainbarGroupHeight$

CommandX $cmdBorder$
CommandY $cmdBorder$
CommandWidth $cmdLabelWidth-2*cmdBorder$
CommandHeight $cmdLabelHeight-2*cmdBorder$

Posted by member 343162 on 2006-09-08 00:12:31 link

Ahh so I should have the posistioning commands for lsx set exactly as the label's positions?

Posted by member 5575 on 2006-09-08 00:15:52 link

Nope, just imagine that the label is a box, and you have to specify where in the box lsxcommand should go. If you move the hooking label, lsxcommand moves with it, i.e., commandx and commandy are relative to the upper left corner of label lsx (or cmdlabel).

Posted by member 343162 on 2006-09-08 00:16:06 link

Still no go, when clicked nothing happens

*Label lsx
lsxX $ResolutionX-191$
lsxY 27
lsxHeight 18
lsxWidth 154
lsxImage lsx_bg.png


CommandHiddenOnStart true

CommandX $ResolutionX-191$
CommandY 27
CommandWidth 154
CommandHeight 18

Posted by member 5575 on 2006-09-08 00:17:25 link

Try setting commandx and commandy to 0, then change them to 1, or 2, etc., and see what happens. You'll get the idea.

Posted by member 343162 on 2006-09-08 00:20:54 link

It worked! Animations included better than before! :)

However:

now there is no skin.....meaning, letme figure this one out....

I should use lsxcommand's built in skinning instead of xlabel?

Edit:

Got it thanks Boreas! Who knew coding could be so much fun when it works! litestep ftw

Posted by member 5575 on 2006-09-08 00:26:09 link

You can hook the old lsxcommand into a label and get transparency effects and such, but it won't really "skin" lsxcommand. If you want the whole aesthetic package, you can try using xlabel's editbox functions. You might also read these forum threads:

http://www.ls-universe.info/plugins/forum/forum_viewtopic.php?652
http://www.ls-universe.info/plugins/forum/forum_viewtopic.php?838
http://www.ls-universe.info/plugins/forum/forum_viewtopic.php?7484.0#post_7498
http://www.ls-universe.info/comment.php?comment.news.105
There's probably more stuff there, too.

Posted by member 280260 on 2006-09-09 10:58:55 link

The new lsxcommand from Andymon supports xPaintClass.