Professional UI Solutions
Site Map   /  Register
 
 

Forum

Please Log In to post a new message or reply to an existing one. If you are not registered, please register.

NOTE: Some forums may be read-only if you are not currently subscribed to our technical support services.

Forums » Prof-UIS General Discussion » 2.54 - extcmdicon.h, line 1047 Collapse All
Subject Author Date
a a May 27, 2006 - 11:19 PM

//     CExtCmdIcon(
//         HICON hIcon,
//         bool bCreateCopy // if false - delete hIcon
//         );
//     CExtCmdIcon(
//         HBITMAP hBitmap,
//         COLORREF clrTransparent = RGB( 0, 0, 0 ),
//         LPCRECT pRectBitmapSrc = NULL,
//         bool bCloneBitmap = true // if false - pRectBitmapSrc must be NULL and will delete hBitmap
//         );

Why are these lines commented?
(I’m using these overloads in my projects)

Technical Support May 28, 2006 - 12:57 PM

Thank you for the good question. The CExtCmdIcon class was completely re-coded in Prof-UIS 2.53 and now implements handle-less icon support for alpha-channel based icons available on any Windows OS. We keep the AssignFrom***() methods in this class exactly the same as in previous versions and removed similar constructors. So, you can assign an icon both from an icon handle and from a bitmap handle but you cannot do this now with constructors. We noticed that constructor-based assignments bring several problems with handle leaks in Prof-UIS code and guessed the same may occur in customer applications. This is the main reason to remove the above mentioned constructors. The second reason to remove them is the completely new handle independent icon support as in Prof-UIS 2.53 or later.