Y'z Docklet With Od

Okay guys, yesterday I read this post at aqua xp.

It's talking about a guy that is doing a port of iCal to OD. The thing is, he is using some script to achieve this.

But this got me to the idea of writing a program that would do some kind of "docklet injection" to OD.

So I began to write a little program.

The following is for developers:

Okay, to achieve this, I need to hook the WindProc of an item. The this can't be done with SetWindowLong, because the window is in another process. So we have to write a dll that contains the new WindowProc and inject it to the process via CreateRemoteThread().

Then, we force CreateRemoteThread() to call LoadLibrary(), which loads the dll into the process memory (ie OD) and call the DllMain() function inside the Dll.

In the DllMain() we just have to do a SetWindowLong() to hook the old WindowProc.

With this we can hook some events:

- Left and right Click down/up events (WM_*BUTTON*) -> On*ButtonClick in docklets

- Paint event (WM_PAINT) -> OnPaint in docklets

But, we still to have control to the title and the icon.

To control the title, we have to find in the process memory where thoses are stored and replace them.

For the icon, I think OD operates like this:

- Load the PNG, which returns a HBITMAP

- Display the HBITMAP

So, we could change the HBITMAP in the memory, and replace with ours. But, to draw the original HBITMAP, OD must draw itself, so maybe a good WM_PAINT hooking would do the trick.

The others functions (OnCreate etc...) would be handled by the dll, or by a third party program.

And also we have to handle the real Y'z dock API.

So maybe this would require a docklet recomp, using a different lib, but this remains to be seen :)

To others:

This would make a total docklet compatibility for OD.

So I'm looking for some persons who are familiar to memory manipulation and are ready to get in the adventure :)

Regards,

siwu

#37620

:blink:

no clue what you just said, but if it gets docklets to a dock that is still in development I LOVE IT! :own:

#37623

Okay, I managed to inject the dll into OD. So now I have control to the messages received by an item. Using its HWND.

The DLL now only blocks the left and right button clicks.

The second thing will now to find an item HWND using its title. Which is not that simple....

This case you would add an "docklet" by putting "[docklet]file.dll" in the title, so the dll will find it and would load the appropriate docklet :)

The third party program would act as a loader, that loads OD and injects the dll into it ;)

#37630

Cool! I would love to have the weather docklet for OD :)

Chris

#37635

One word: WOW!

#37668

WOW!

#37676

Haha ok, let me save you some trouble... we're deciding on a plugin format for ObjectDock currently and will provide samples... it is likly that it will be built around the existing "SDPlugin" format that is compatible with ObjectBar and DesktopX, don't know at this point though.

cya ;)

-Jeff

#37710

Originally posted by JMB1984@Jul 3 2003, 11:45 PM

Haha ok, let me save you some trouble... we're deciding on a plugin format for ObjectDock currently and will provide samples... it is likly that it will be built around the existing "SDPlugin" format that is compatible with ObjectBar and DesktopX, don't know at this point though.

cya ;)

-Jeff

Lol, well, this is not so worthless, cause a full compatibility with Y'z docklet without recompilation would be really cool :)

I already managed to change an icon title and to find an icon HWND using it's name.

I am now working on a proper WM_PAINT hooking to manually change the icon :)

When it's done, the whole world is up to me :)

But if you want I can work with you on a proper Y'z docklet integration, but this time with the source code ;)

Hope to hear from you soon :)

#37713

Originally posted by siwu+Jul 3 2003, 10:01 PM-->
QUOTE(siwu @ Jul 3 2003, 10:01 PM)

#37776

Me 2, me 2!!! :)

#37808

Originally posted by Binary@Jul 4 2003, 05:36 AM

that's great news. Sure OD plugins will be cool, but allowing us to use y'z docklets in OD is even better, since there are so many great ones already available.

How long till a first release siwu? And do you need any beta testers? ;) I'd be glad to help out.

Chris

Well, I am testing some techniques to modify the icons, there is no program coded.

Now I have to find a way to manually change the icons. And also to recreate a YzDocklet.dll which has the same proc addresses as the original :)

Well, if this is not done, the docklets coders would only have to recompile using a different .lib :)

I think I'll release an alpha which support caption changing and left/right click :)

But I don't when, because I am also working on iExpose :)

#37811

In the mean time, if OD plugins reveals to be the as powerfull as the Y'z SDK, I think docklet coders will recode the docklet for OD, since Y'z dev is stopped.

#37812

Man...i mean...cool...wow...

*translation*

Our developers seem to be on fire right now!! Apps are dropping on us from every direction. I can't even keep up :)

If you get this fully working it would be awesome because i could give OD new chance. So far the lack of docklet support has held me back.

#37813

Originally posted by LoofyGun@Jul 4 2003, 10:33 AM

If you get this fully working it would be awesome because i could give OD new chance. So far the lack of docklet support has held me back.

Same here :)

OD has a great engine, and taskbar function, but no plugin support :/

#37819

Can`t wait for alpha!!!

#37858

any news siwu?

#38688