BorlandTalk.com Forum Index BorlandTalk.com
Borland discussion newsgroups
 
Archives   FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Prevent a Object (TrackBar) from getting 'Focus'.

 
Post new topic   Reply to topic    BorlandTalk.com Forum Index -> C++ Builder (VCL Components Usage)
View previous topic :: View next topic  
Author Message
JasperP
Guest





PostPosted: Fri Sep 01, 2006 8:05 am    Post subject: Prevent a Object (TrackBar) from getting 'Focus'. Reply with quote



Example:
---------

- Form1
- TrackBar with TabStop = false;
- Form2
- TrackBar with TabStop = false;

When you click on them or change the slider it gets a rect. dotted Focus.

---------

Strangest thing; when I XPManifest the project, the TrackBar on Form1 does
NOT get focus anymore (= what I want), but the TrackBar on Form2 DOES get
focus.

How do I prevent this from happening?

Jasper
Back to top
4N
Guest





PostPosted: Fri Sep 01, 2006 9:26 pm    Post subject: Re: Prevent a Object (TrackBar) from getting 'Focus'. Reply with quote



you can use "DifferentControl"->SetFocus() to set the focus to a different
control.
If you click on a control is only natural that it gets the focus... maybe
the xp manifest doesn't show it but the focus should actually change in that
case too

"JasperP" <Spam (AT) SpamCop (DOT) net> ha scritto nel messaggio
news:44f7a37c (AT) newsgroups (DOT) borland.com...
Quote:
Example:
---------

- Form1
- TrackBar with TabStop = false;
- Form2
- TrackBar with TabStop = false;

When you click on them or change the slider it gets a rect. dotted Focus.

---------

Strangest thing; when I XPManifest the project, the TrackBar on Form1 does
NOT get focus anymore (= what I want), but the TrackBar on Form2 DOES get
focus.

How do I prevent this from happening?

Jasper
Back to top
JasperP
Guest





PostPosted: Sat Sep 02, 2006 5:44 pm    Post subject: Re: Prevent a Object (TrackBar) from getting 'Focus'. Reply with quote



4N wrote:
Quote:
you can use "DifferentControl"->SetFocus() to set the focus to a different
control.
If you click on a control is only natural that it gets the focus... maybe
the xp manifest doesn't show it but the focus should actually change in
that case too

Well, that would be a 'workaround' for most Controls, but I would like a
TrackBar that can also be manipulated with the keyboard (up/down) and then
that does not work anymore.

Of course you could get the input via the Control you set focus on via
OnKeyPress...

Nevertheless it would be nice to just get rid of that dotted focus rect.

Jasper
Back to top
4N
Guest





PostPosted: Sun Sep 03, 2006 10:00 pm    Post subject: Re: Prevent a Object (TrackBar) from getting 'Focus'. Reply with quote

hmm, if you click on a control thats's what happens, unless you draw it
yourself or you can set Form->KeyPreview and catch arrow keys to change the
trackbar from FormKeyUp

"JasperP" <Spam (AT) SpamCop (DOT) net> ha scritto nel messaggio
news:44f97cb2$1 (AT) newsgroups (DOT) borland.com...
Quote:

4N wrote:
you can use "DifferentControl"->SetFocus() to set the focus to a
different control.
If you click on a control is only natural that it gets the focus... maybe
the xp manifest doesn't show it but the focus should actually change in
that case too

Well, that would be a 'workaround' for most Controls, but I would like a
TrackBar that can also be manipulated with the keyboard (up/down) and then
that does not work anymore.

Of course you could get the input via the Control you set focus on via
OnKeyPress...

Nevertheless it would be nice to just get rid of that dotted focus rect.

Jasper
Back to top
Display posts from previous:   
Post new topic   Reply to topic    BorlandTalk.com Forum Index -> C++ Builder (VCL Components Usage) All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2006 phpBB Group
SEO toolkit © 2004-2006 webmedic.