Jump to content
  • Advertisement
Sign in to follow this  
gan

integrate win32 program to desktop

This topic is 4766 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

How? I'm making a small win32 program, need to integrate it into desktop without showing border and showing title in the taskbar. What is the APIcommand that Ineed to use?

Share this post


Link to post
Share on other sites
Advertisement
You should create the window without the title bar style. Something like WS_POPUPWINDOW should do the job for you. Then, make sure you show your window maximized.

Share this post


Link to post
Share on other sites
but i think what I want is a small win32 program that act like embeded in desktop(like messenger)

Share this post


Link to post
Share on other sites
In that case, I believe what you are looking for is a system tray icon. We'd need to know what language you're using to help you there.

Share this post


Link to post
Share on other sites
Guest Anonymous Poster
how the tray icon works is that the window remains closed until the tray icon is clicked on and a menu option is chosen, then the program opens the window

you have to design your program to be able to run without a window and to be able to reopen the window

just because your window closes doesn't mean your winmain can't live on forever

create a loop in winmain that does stuff and monitor your tray icon and open the window when lets say somebody clicks on the icon

as a matter of fact those tray programs where a menu opens when the icon is clicked, the menu itself is a window (a certain style)
the tray icon is registered with the shell and the shell notifies you when it has messages for it, so a part of your program will have to handle messages from the icon

the link for the how to from msdn
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/winui/winui/windowsuserinterface/windowing/windows/windowreference/windowfunctions/createwindow.asp

from your program you use Shell_NotifyIcon to place your icon down in the tray
you dont have to start your program with a window, you can just loop winmain with like a sleep timer of 100
then when the user clicks on the tray icon open your window

Share this post


Link to post
Share on other sites
Guest Anonymous Poster
wrong link ^^

this link..lol
[link]http://msdn.microsoft.com/library/en-us/shellcc/platform/shell/reference/functions/shell_notifyicon.asp?frame=true[/link]

Share this post


Link to post
Share on other sites
Quote:
Original post by Anonymous Poster
 
create a loop in winmain that does stuff and monitor your tray icon and open the window when lets say somebody clicks on the icon



but i want the icon and window both show at the same time when loading the executable file. (actually not neccessary icon, anything else but not show the window title in the start menu bar)

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!