i have a problem when i add event trigger to a grid. I want when right mouse is clicked anywhere on a grid a menu to pop up, the problem is when i click somewhere in the grid where there is a stack panel for example the menu doesn't pop up. Any ideas?
Related
I created a custom tooltip that stays open when the mouse hovers over a button by using a popup. My solution is here. You can see the following attachment that displays the popup working correctly. By the way, any mouse event will be triggered on the popup in this state, such as MouseEnter:
For simplicity, hovering a mouse over the popup will trigger the MouseEnter event:
<Popup MouseEnter="TT_Popup_Control_MouseEnter"></Popup>
The issue is when the Child Ribbon Buttons collapse. When I click on the collapsed Parent Ribbon Button to expand the Child Buttons, and hover over the Child Button, I get something like this:
Again for simplicity, hovering a mouse over the popup will no longer trigger the MouseEnter event:
<Popup MouseEnter="TT_Popup_Control_MouseEnter"></Popup>
So when I hover over the popup, the popup no longer stays open in this state. Since the popup mouse events are no longer triggered, I believe this is the issue, but I don't know why this is the issue. Did I discover a bug in the .NET framework? Or is there something I am missing here?
In the fiddle mentioned below, when I scrolls the combobox down and then tries to drag the scroll bar up, I am not able to click the Select All button. This happens in internet explorer.
https://fiddle.sencha.com/#view/editor&fiddle/1kn2
I have grid and action column in this grid. When I click on action column on grid it displays menu. when I clicked anywhere else after menu shown, menu gets hide.
But when I scroll grid with mouse wheel, menu doesn't hide. Instead its position changes as per scrolling...so I want solution for this to handle this situation so that I can hide menu on mouse-wheeel scroll
Hi Could you please add this in the afterRender of your grid
this.body.on('scroll', this.handleScroll);
handleScroll: function() {
//hide your menu.
},
Hope it helps you.
I have a wondows form which contains a WPF control as well. When I click on the control it brings up a WPF popup control with a listbox. The goal is, when I select an item on the listbox, the windows form will be repopulated accordingly and the popup should get closed. The current implementation with SelectionChanged on the listbox works fine.
Here is the problem. The popup is big and covers some portion of the winform which contains some links. Now, when I select an item on the listbox, the popup closes after doing necessary actions, but if there is a link just below the popup (on the winform) that is under the cursor (when you selected the item on the listbox), that link is also taking the click event.
Is there any way to prevent the links getting clicked when I click on the popup? I have to close the popup though.
I think I figured this out.
SelectionChanged gets executed when we press the mouse key down and before we lift it.(Mouse key up). The popup gets closed in SelectionChanged before we lift the Mouse key. So, when we leave the mouse key, the keyUp event actually gets fired for a link on the Winform as the popup has been closed by now.
I moved the logic from SelectionChanged to PreviewMouseUp and the popup stays till I leave the mouse key and therefore the links on the Winform do not get the event. Of course, I check whether the selection has been changed or not.
I want to make a control which will work like the tab header in Visual Studio 2010.
When you have a few tabs open (MainWindow.xaml, MainWindow.xaml.cs, etc.) only the active tab has a close button visible, but when you hover the mouse over an inactive tab the close button appears, which means you can close any tab with one click.
It probably will be a border with text under the floated buttons.
All WPF controls are containers, you can put a button inside a button for example. You can have a layout manager to a control with the items you want in it.
For what you are asking about you could have a user control that has a TextArea and a Button in a StackPanel. Then hide the button. You then have the user control register for its MouseEnter and MouseLeave events and when the mouse is over you make the button visible, and when it leaves you hide it again.