🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.cppbuilder.nativeapi
Article #187

Re: Assigning Icon from ExtractIconEx without leaks

#187
From: Mike Collins
Date: Tue, 01 Jul 2008 23:14
16 lines
1433 bytes
Many thanks again, you always seem to clear things up.

Can i just confirm two things:

1) Once i assign HICON to the TIcon->Handle, i can basically forget about 
it - the TIcon takes ownership and will be responcible for freeing it?

2) Assuming that this is correct, if i need to call the same code again, 
later on in the life-span, of the application, should i call DestroyIcon() 
on the TIcon->Handle before i load the new icon?

Thanks again

Mike C

"Remy 
Technical Details
Message-ID: <486aa96e@newsgroups.borland.com>
Path: arc1-ca.pugleaf.net!g2news1.google.com!news3.google.com!proxad.net!feeder1-2.proxad.net!feeder.erje.net!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail
References: <486a1911@newsgroups.borland.com> <486a5c9e$1@newsgroups.borland.com>

Show Full Headers
Complete Article Headers
X-Google-Thread: 10cc67,dea519f40adb32bd
X-Google-Attributes: gid10cc67,domainid0,public,usenet
X-Google-Language: ENGLISH,ASCII-7-bit
From: "Mike Collins" <its@TheBottomOfThePost>
Newsgroups: borland.public.cppbuilder.nativeapi
References: <486a1911@newsgroups.borland.com> <486a5c9e$1@newsgroups.borland.com>
Subject: Re: Assigning Icon from ExtractIconEx without leaks
Date: Tue, 1 Jul 2008 23:14:02 -0000
Lines: 18
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.3790.3959
X-RFC2646: Format=Flowed; Response
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.3790.4133
NNTP-Posting-Host: 89.242.18.71
Message-ID: <486aa96e@newsgroups.borland.com>
X-Trace: newsgroups.borland.com 1214949742 89.242.18.71 (1 Jul 2008 15:02:22 -0700)
Path: arc1-ca.pugleaf.net!g2news1.google.com!news3.google.com!proxad.net!feeder1-2.proxad.net!feeder.erje.net!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail