Icone dans poptray

Seth77 Messages postés 572 Date d'inscription mardi 30 avril 2002 Statut Membre Dernière intervention 4 mai 2020 - 20 févr. 2005 à 13:27
rvblog Messages postés 792 Date d'inscription vendredi 4 mars 2005 Statut Membre Dernière intervention 12 juin 2012 - 14 mars 2006 à 11:40
Slu



J ai mis pour mon app un icone dans le tray.

Et lorsque je clix avec le bouton droit je fais apparaitre un menu.

Mais le menu disparait tres difficlement meme en cliquant sur le bureau ou sur la barre des taches.



comment faire pour resoudre ce probleme ?

Herve

6 réponses

aurelskull Messages postés 18 Date d'inscription dimanche 13 avril 2003 Statut Membre Dernière intervention 27 mai 2005
20 févr. 2005 à 13:38
Tu utilise quoi pour mettre ton programme dans le tray ? des API ?
0
Seth77 Messages postés 572 Date d'inscription mardi 30 avril 2002 Statut Membre Dernière intervention 4 mai 2020 1
20 févr. 2005 à 13:40
J utilise : Shell_NotifyIcon.

Herve
0
Seth77 Messages postés 572 Date d'inscription mardi 30 avril 2002 Statut Membre Dernière intervention 4 mai 2020 1
13 mars 2005 à 01:04
up

Herve
0
aurelskull Messages postés 18 Date d'inscription dimanche 13 avril 2003 Statut Membre Dernière intervention 27 mai 2005
13 mars 2005 à 11:29
Apparemment, la seule solution est de créer une case « Sortir » dans ton menu


J’ai pas mal cherché car moi aussi j’utilise cette API mais bon, je n’ai pas d’autre possibilité pour l’instant.


Fais moi savoir si tu trouves quelque chose.


@+
0

Vous n’avez pas trouvé la réponse que vous recherchez ?

Posez votre question
Seth77 Messages postés 572 Date d'inscription mardi 30 avril 2002 Statut Membre Dernière intervention 4 mai 2020 1
13 mars 2005 à 16:22
ok

Herve
0
rvblog Messages postés 792 Date d'inscription vendredi 4 mars 2005 Statut Membre Dernière intervention 12 juin 2012 7
14 mars 2006 à 11:40
PRB: Menus for Notification Icons Don't Work Correctly
Last reviewed: September 20, 1996
Article ID: Q135788 ,
----

The information in this article applies to:

<LI>Microsoft Win32 Application Programming Interface (API) included with:

- Microsoft Windows 95 version 4.0

</LI>

SYMPTOMS

When you display a context menu for a Notify Icon (see Shell_NotifyIcon), clicking anywhere besides the menu or the window that created the menu (if it is visible) doesn't cause the menu to disappear. When this behavior is corrected, the second time this menu is displayed, it displays and then immediately disappears.

RESOLUTION

To correct the first behavior, you need to make the current window the foreground window before calling TrackPopupMenu or TrackPopupMenuEx.
The second problem is caused by a problem with TrackPopupMenu. It is necessary to force a task switch to the application that called TrackPopupMenu at some time in the near future. This can be accomplished by posting a benign message to the window or thread.
The following code will take care of all of this:
SetForegroundWindow(hDlg);

// Display the menu
TrackPopupMenu( hSubMenu,
TPM_RIGHTBUTTON,
pt.x,
pt.y,
0,
hDlg,
NULL);

PostMessage(hDlg, WM_NULL, 0, 0);

STATUS

This behavior is by design.


<!--DOCBODY_END--><!--FOOTER_START-->
<HR width="90%">

Additional reference words: 4.00
KBCategory: kbui kbprb kbcode
KBSubcategory: UsrMisc

THE INFORMATION PROVIDED IN THE MICROSOFT KNOWLEDGE BASE IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND. MICROSOFT DISCLAIMS ALL WARRANTIES, EITHER EXPRESS OR IMPLIED, INCLUDING THE WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT SHALL MICROSOFT CORPORATION OR ITS SUPPLIERS BE LIABLE FOR ANY DAMAGES WHATSOEVER INCLUDING DIRECT, INDIRECT, INCIDENTAL, CONSEQUENTIAL, LOSS OF BUSINESS PROFITS OR SPECIAL DAMAGES, EVEN IF MICROSOFT CORPORATION OR ITS SUPPLIERS HAVE BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. SOME STATES DO NOT ALLOW THE EXCLUSION OR LIMITATION OF LIABILITY FOR CONSEQUENTIAL OR INCIDENTAL DAMAGES SO THE FOREGOING LIMITATION MAY NOT APPLY.

<CENTER>Last reviewed: September 20, 1996
© 1998 Microsoft Corporation. All rights reserved. Terms of Use.
</CENTER>
0
Rejoignez-nous