 |
BorlandTalk.com Borland discussion newsgroups
|
| View previous topic :: View next topic |
| Author |
Message |
Jeff Grant Guest
|
Posted: Thu Apr 13, 2006 10:03 pm Post subject: TComboBox ContextPopup, preventing |
|
|
C++ BDS 2006, TComboBox.
The following is intended to prevent the default popup menu on a TComboBox.
//////////////////////////////////////////////////////////////
void __fastcall TAutomaticTestingForm::LockTimeComboBoxContextPopup(
TObject *Sender, TPoint &MousePos, bool &Handled)
{
Handled = true;
}
///////////////////////////////////////////////////////
The right click still displays the popup menu. Setting a breakpoint at "Handled = true;" revealed that the code did not reach this point.
The same code work fine for TMemo.
Is there something I am missing or is there something wrong?
THANKS
Jeff |
|
| Back to top |
|
 |
Remy Lebeau (TeamB) Guest
|
Posted: Fri Apr 14, 2006 12:03 am Post subject: Re: TComboBox ContextPopup, preventing |
|
|
"Jeff Grant" <jeff.grant (AT) jdsu (DOT) com> wrote in message
news:443ebd3b$1 (AT) newsgroups (DOT) borland.com...
| Quote: | The right click still displays the popup menu. Setting a breakpoint
at "Handled = true;" revealed that the code did not reach this point.
|
Do you have your menu assigned to the component's PopupMenu property? If
so, is the menu's AutoPopup property set to false?
Gambit |
|
| Back to top |
|
 |
Jeff Grant Guest
|
Posted: Thu Apr 20, 2006 8:03 pm Post subject: Re: TComboBox ContextPopup, preventing |
|
|
I do not have a popup menu in the project. The popup menu property is blank. I don't even know why there is a popup at all.
The popup contains the following items.
Undo
--------
Cut
Copy
Paste
Delete
--------
Select All
I have had this happen on edit boxes and the Handled = true worked there.
THANKS
Jeff
"Remy Lebeau \(TeamB\)" <no.spam (AT) no (DOT) spam.com> wrote:
| Quote: |
"Jeff Grant" <jeff.grant (AT) jdsu (DOT) com> wrote in message
news:443ebd3b$1 (AT) newsgroups (DOT) borland.com...
The right click still displays the popup menu. Setting a breakpoint
at "Handled = true;" revealed that the code did not reach this point.
Do you have your menu assigned to the component's PopupMenu property? If
so, is the menu's AutoPopup property set to false?
Gambit
|
|
|
| Back to top |
|
 |
|
|
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
|
|