🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

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

Re: fsStayOnTop

#9608
From: Damon Chandler TeamB
Date: Wed, 23 Jun 2004 06:33
34 lines
1788 bytes
Hi Chris,
   You can use the TApplication::RestoreTopMosts() method within a 
handler for the TApplication::OnDeactivate event for this...

// in header...
void __fastcall ApplicationDeactivate(TObject *Sender);

// in source...
__fastcall TForm1::TForm1(TComponent* Owner)
     : TForm(Owner)
{
   Application->OnDeactivate = ApplicationDeactivate;
}

void __fastcall TForm1::ApplicationDeactivate(TObject *Sender)
{
   Application->RestoreTopMosts();
}

I haven't used this in a while, so you may have to verify that it also 
works on the Win9x/Me front.

Good luck,
-- 
Damon (TeamB)
C++Builder Developer's Journal
http://bcbjournal.org
http://caq.bcbjournal.org


Chris wrote:
> What I want it to do:
> Keep the second form on top of all other applications
> Not interfere with the tray icon popup.
Technical Details
Message-ID: <40d92437@newsgroups.borland.com>
Path: arc1-ca.pugleaf.net!g2news1.google.com!news1.google.com!news.glorb.com!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail
References: <40d3e5e7$1@newsgroups.borland.com>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: 10cc67,ad72a72c8c3adc7
X-Google-Attributes: gid10cc67,public
Date: Wed, 23 Jun 2004 02:33:42 -0400
From: "Damon Chandler (TeamB)" <editor@[REMOVE_THIS_SPAM_GUARD]bcbjournal.org>
User-Agent: Mozilla Thunderbird 0.6 (Windows/20040502)
X-Accept-Language: en-us, en
MIME-Version: 1.0
Newsgroups: borland.public.cppbuilder.nativeapi
Subject: Re: fsStayOnTop
References: <40d3e5e7$1@newsgroups.borland.com>
In-Reply-To: <40d3e5e7$1@newsgroups.borland.com>
Content-Type: text/plain; charset=us-ascii; format=flowed
Content-Transfer-Encoding: 7bit
NNTP-Posting-Host: 4.249.108.116
Message-ID: <40d92437@newsgroups.borland.com>
X-Trace: newsgroups.borland.com 1087972407 4.249.108.116 (22 Jun 2004 23:33:27 -0700)
Lines: 34
Path: arc1-ca.pugleaf.net!g2news1.google.com!news1.google.com!news.glorb.com!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail