PocketMatrix forums

A read-only archive of the PocketMatrix forums (2001–2014). Posting and accounts are closed.

SIP positioning

Andrew Braunstein · 12 Dec 2001, 16:27 UTC
I am trying to find out the 'magic' then is performed when an application
compiled for CE 2.11 is run under CE 3.0 such that the SIP panel is
integrated into the task bar instead of being integrated into an application
menu.  Our application has no menu, and we are trying to force the SIP icon
to stay in the task bar.

Can anyone be of any assistance?
On the PocketPC the SIP button is not on the TaskBar, but on the command bar at the bottom of the display. That command bar is associated with the app, but is not actually owned by the app's main window. So are you seeing the command bar at the bottom of the screen at all? If so, if the SIP button is not showing, try calling SHFullScreen:

[fixed]SHFullScreen( hMyMainWnd, SHFS_SHOWSIPBUTTON ); [/fixed]

If you are not seeing a command bar at the bottom of the display, then you need to call SHCreateMenuBar in your WM_CREATE handler for your main window. Try creating a generic Pocket PC "Hello World" app and see how it is done in the template. It's something like this:
[fixed]SHMENUBARINFO mbi;

memset( &mbi, 0, sizeof( SHMENUBARINFO ) );
mbi.cbSize     = sizeof( SHMENUBARINFO );
mbi.hwndParent = hwnd;
mbi.nToolBarId = IDM_MENU;
mbi.hInstRes   = hInst;
mbi.nBmpId     = 0;
mbi.cBmpImages = 0;
if ( !SHCreateMenuBar( &mbi ) )
 return NULL;[/fixed]

I don't know if you can get by not passing a toolbar resource ID ( IDM_MENU in this case ) or not.

Dan East
I just re-read your post. I assumed you were trying to update a CE 2.11 app to work properly on a Pocket PC, instead of just trying to get a PSPC binary to run on a Pocket PC as-is. If the latter, then I don't know. I would think the Pocket PC OS would just keep the SIP button up at all times in that case.

Dan East
when running a win ce 2.11 app on a pocket pc (with a similar proc, obviously), it works fine and just moves the taskbar to the bottom, and adds a nifty little icon to it that looks like an 'A' and that brings up the input panel.  Even works with a skin app running, like wisbar.  

In other words, if dan doesn't know what youre talking about, I have no clue.

wait no, i just got it. :)

dan, hes saying that when you run a pspc app on the ppc it has the sip in the taskbar (and it moves the taskbar down there)... he's just wondering how you would do that straight up on the ppc.  My question is, why would he just ask how to call the SIP, like put an icon on the taskbar (like in gigabar) that pops up the SIP?Last modification: Jaybot - 12/12/01 at 15:17:24
Okay. I think I understand now too. He is writing a Pocket PC app, but he doesn't want it to have a command bar. Thus there is no place for a SIP button. So he wants to trick the Pocket PC OS into moving its TaskBar to the bottom like it does with PSPC apps. I don't know how the OS determines that an app is for CE 2.11. I assume it just looks at the app's PE header and gets the OS version the app was built for.

A suggestion would be to make your app full-screen (using SHFullScreen), and draw your own pseudo-taskbar (I do this with our Pocket PC medical software). It is trivial to draw a clock, or handle mouse clicks on your "start button" (you just send a single message to show it). Then you include your own SIP button, and call SHSipPreference to show and hide the SIP. You the get the rest of that space to fill with info as you please.

Dan East
Duh. I did the same thing with Pocket Quake. In portrait mode it implements it's own Taskbar, including a clock and start menu. Take a look at the PQ source if you're interested.

Dan East
where can one find info about your medical software?
It's in beta at a local hospital. Physicians use the Windows CE portion to view the patient's medical record while doing rounds.

Dan East
oh.  i was hoping it was already released.  that could be a real (and much needed) contender with all of the palm medical software.