Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Feature Request]: Remove designer visibility of MouseDoubleClick and DoubleClick Events for the KryptonComboxBox #1461

Closed
lesandrog opened this issue May 12, 2024 · 9 comments
Labels
area:designer All issues related to the designer. area:toolkit All issues related to the toolkit components. completed This issue has been completed. discussion Discussion thread. enhancement New feature or request
Milestone

Comments

@lesandrog
Copy link

lesandrog commented May 12, 2024

Describe the bug.
KryptonComboxBox MouseDoubleClick and DoubleClick Event is not triggered.

To Reproduce
Steps to reproduce the behavior:
Add a KryptonComboBox.
Add the KryptonComboBox1.MouseDoubleClick event.

Private Sub KryptonComboBox1_MouseDoubleClick(sender As Object, e As MouseEventArgs) Handles KryptonComboBox1.MouseDoubleClick
    MessageBox.Show("test")
End Sub

Expected behavior
With a double click on the combobox, the event should trigger the messagebox, but this does not happen.

Desktop (please complete the following information):

  • OS: Windows 11
  • Version: 23H2 22631.3527
  • Framework/.NET Version: 4.8 (vb.net \ Windows Forms)
  • Toolkit Version: Krypton.Toolkit 80.24.3.64
@lesandrog lesandrog added the bug Something isn't working label May 12, 2024
@Smurf-IV
Copy link
Member

The KComboBox should NOT have the DoubleClick event anyway :
Here's the Winform ComboBox:
image

@Smurf-IV
Copy link
Member

And I cannot get a normal winform comboBox to fire the following either:
this.comboBox1.MouseDoubleClick += new System.Windows.Forms.MouseEventHandler(this.comboBox1_MouseDoubleClick);

@Smurf-IV
Copy link
Member

HMM:
image
https://learn.microsoft.com/en-us/dotnet/api/system.windows.forms.combobox.doubleclick?view=netframework-4.8

So there is a bug in the KComboBox, in that it "Should NOT" be showing this event in the designer !

@Wagnerp
Copy link
Contributor

Wagnerp commented May 26, 2024

?

image

image

@Smurf-IV
Copy link
Member

Yes, You can programmatically add it, as it is part of the base control class, but it does nothing (i.e. does not fire) in a combobox, because the first click is absorbed to perform the select.

@Wagnerp
Copy link
Contributor

Wagnerp commented May 26, 2024

The KComboBox derives from VisualControlBase, is it possible to 'hide' these options for this case?

@Smurf-IV
Copy link
Member

The KComboBox derives from VisualControlBase, is it possible to 'hide' these options for this case?

Yes, by overriding them and making them designer hidden via attribute(s)

@Smurf-IV
Copy link
Member

More info:
By default, a combo box cell cannot receive a double-click with the left mouse button. The cell goes into edit mode on the first click, so the next click goes to the Combo control that is the subeditor.

@Smurf-IV Smurf-IV changed the title [Bug]: KryptonComboxBox MouseDoubleClick and DoubleClick Event is not triggered. [Feature Request]: Remove designer visibility of MouseDoubleClick and DoubleClick Events for the KryptonComboxBox May 27, 2024
@Smurf-IV Smurf-IV added enhancement New feature or request discussion Discussion thread. area:designer All issues related to the designer. area:toolkit All issues related to the toolkit components. and removed bug Something isn't working labels May 27, 2024
@Smurf-IV Smurf-IV self-assigned this May 27, 2024
@Smurf-IV Smurf-IV added the under investigation This bug/issue is currently under investigation. label May 27, 2024
@Smurf-IV Smurf-IV added this to the Version 90 milestone May 27, 2024
@Smurf-IV
Copy link
Member

Remove ###DoubleClick from the designer events:
image

@Smurf-IV Smurf-IV removed their assignment May 27, 2024
@Smurf-IV Smurf-IV added completed This issue has been completed. and removed under investigation This bug/issue is currently under investigation. labels May 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area:designer All issues related to the designer. area:toolkit All issues related to the toolkit components. completed This issue has been completed. discussion Discussion thread. enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants