Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > Visual C++ MFC > Controls
  New Posts New Posts RSS Feed - CXTPTaskDialog and icons
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

CXTPTaskDialog and icons

 Post Reply Post Reply
Author
Message
nikb View Drop Down
Newbie
Newbie


Joined: 20 September 2008
Status: Offline
Points: 4
Post Options Post Options   Thanks (0) Thanks(0)   Quote nikb Quote  Post ReplyReply Direct Link To This Post Topic: CXTPTaskDialog and icons
    Posted: 26 October 2010 at 12:24pm
Hello,

I'll start off by saying I'm using an older version of the library; this may have already been addressed in the current code. If so, great and please disregard.

I was trying to create a modal task dialog that had a 48x48 icon. I was very surprised to see that the size of the icon is always hard-coded to be 32x32, even when forcing the use of the CodeJock task dialog implementation and not the native Windows version.

What's worse, is that the CXTPTaskDialog class, despite having a member variable that defines the size of the icons makes it almost impossible for a derived class to change it in a reliable way.

There's a few ways of implementing this, all of which are trivial. You could, for example, make CXTPTaskDialogClient::RefreshMetrics a virtual function. Or you could have an explicit SetMainIconSize function. Or you could make the existing SetMainIcon accept a CSize parameter or call GetIconInfo to retrieve the actual size of the loaded resource.

It's a small thing, but it's the small things that count sometimes.

Thanks,

Nik B.
Back to Top
znakeeye View Drop Down
Senior Member
Senior Member
Avatar

Joined: 26 July 2006
Status: Offline
Points: 1672
Post Options Post Options   Thanks (0) Thanks(0)   Quote znakeeye Quote  Post ReplyReply Direct Link To This Post Posted: 26 October 2010 at 3:43pm
+1
PokerMemento - http://www.pokermemento.com/
Back to Top
Oleg View Drop Down
Admin Group
Admin Group


Joined: 21 May 2003
Location: United States
Status: Offline
Points: 11234
Post Options Post Options   Thanks (0) Thanks(0)   Quote Oleg Quote  Post ReplyReply Direct Link To This Post Posted: 27 October 2010 at 4:08am
Hi,

We alerady wrote that main porpose of CXTPTaskDialog class is to provide interface to system Windows7/Vista builtin TaskDialog and create same Dialog for older OS.  

System TaskDialog don't have way to change Size of Icon so we can't add such method too for System version.   

experienced users can indeed override RefreshMetrics (in last release its already virtual)  and disable system task usage for all OS.
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS
Back to Top
 Post Reply Post Reply
  Share Topic   

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.04
Copyright ©2001-2021 Web Wiz Ltd.

This page was generated in 0.109 seconds.