Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > Visual C++ MFC > Toolkit Pro
  New Posts New Posts RSS Feed - CXTPGraphicBitmapPng
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

CXTPGraphicBitmapPng

 Post Reply Post Reply
Author
Message
ABuenger View Drop Down
Newbie
Newbie
Avatar

Joined: 02 February 2006
Status: Offline
Points: 1075
Post Options Post Options   Thanks (0) Thanks(0)   Quote ABuenger Quote  Post ReplyReply Direct Link To This Post Topic: CXTPGraphicBitmapPng
    Posted: 29 November 2006 at 9:09am
Hi,

could you split CXTPGraphicBitmapPng::LoadFromResource into two methods, LoadFromResource and LoadFromBuffer?


LPBYTE lpBuffer = (LPBYTE)LockResource(hMem);
if (!lpBuffer || nBufferSize < 10)
   return FALSE;

CMemFile file(lpBuffer, nBufferSize);
return LoadFromBuffer  (...);

<--- Split function here --->

BOOL CXTPGraphicBitmapPng::LoadFromBuffer (...)
{
   CMemFile file(lpBuffer, nBufferSize)
   ....
}


That doesn't add any extra code but makes the class more flexible.

Codejock support
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: 30 November 2006 at 1:41am
ok
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.156 seconds.