Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / Visual Studio.NET / General / January 2005

Tip: Looking for answers? Try searching our database.

no big icon in ALT+TAB menu for modless threaded dialogs...?

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Anders Sandberg - 19 Jan 2005 14:02 GMT
Hi,

If you create a modless dialogs with CDialog::Create(...) from another
thread, the ALT+TAB active processes menu displays the default window icon
(regardless what you set with SetIcon(...)) in the ALT+TAB menu for the
first dialog and the other dialogs is not even present in the ALT+TAB menu.

If I change the Window style of the dialog to include WS_EX_APPWINDOW, the
ALT+TAB menu presents the first dlg with the def. window icon and just empty
slots for the rest... The taskbar icons are diplayed correctly in both
cases.

Any ideas on how to display the 32x32 icons in the ALT+TAB menu in this
situation?

Heres a snippet to reproduce the behaviour:

UINT DlgThreadProc( LPVOID lpV )
{
   CDlgTest nTest;
   nTest.CreateObject();
   nTest.Create(CDlgTest::IDD);
   // nTest.ModifyStyleEx(NULL, WS_EX_APPWINDOW); // --> adds empty icon
placeholders to ALT+TAB menu
   nTest.ShowWindow(SW_SHOWNORMAL);

   HANDLE hEvents[1];
   hEvents[0] = nTest.m_hEvent;
   MSG msg;

   while{true)
   {
           if( MsgWaitForMultipleObjects(1,hEvents,false,INFINITE,
QS_ALLEVENTS|QS_ALLINPUT|QS_ALLPOSTMESSAGE) == WAIT_OBJECT_0 )
               break;

           while(::PeekMessage(&msg, nTest.m_hWnd,0,0,PM_REMOVE))
           {
               if(IsDialogMessage(nTest.m_hWnd, &msg))
                   continue;

               TranslateMessage(&msg);
               DispatchMessage(&msg);
           }
   }
   return 0;
}

Any suggestions appriciated!

regards
Anders Sandberg
AliR - 19 Jan 2005 15:14 GMT
take a look at your icon in the resource editor. Make sure that it displayes
the same icon for all sizes that you have specified.

AliR.

> Hi,
>
[quoted text clipped - 48 lines]
> regards
> Anders Sandberg

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.