right-click

Move a borderless Winform holding right mouse button, possibly with native methods

。_饼干妹妹 提交于 2019-12-23 21:26:09
问题 I have a situation where I would like to move a windows form by holding right mouse button on it's client area; the form it's borderless as i've stated. I would like to move it "natively" (if possible, otherwise other answers are ok too). I mean the way it behaves when you hold left mouse button on the titlebar (with mouse-move and things like that I get a lot of strange behaviours, but maybe it's just me). I've read around a lot of things and this post looks helpful http://social.msdn

python: Right Click on list menu not showing item selected

馋奶兔 提交于 2019-12-23 17:49:16
问题 In my ongoing effort to learn more about python, I am trying to add a right click event to my mp3 manager program. What currently works is that it shows the menu and all of the options. What is not working is the functions selected from the menu are not executing as I think they should be. Much of this code was taken from a 'how to' on another site. Here are the right click menu options menu_titles = ["Remove Selection from list", "Delete Selection from system", "Move Selection", "Copy

Disabled row on Datagrid WPF getting selected when clicked with the Right Mouse Button

旧城冷巷雨未停 提交于 2019-12-23 17:04:25
问题 I got some problems in Datagrid WPF I have a datagrid, and I want to set the IsEnabled property of a single row to false whenever the user assign a value to the binding item of the datagrid itemSource So I made it by datagrid Style triggers: <DataGrid AutoGenerateColumns="False" Margin="9,35,0,6" Name="dataGrid2" ItemsSource="{Binding}" SelectionChanged="dataGrid2_SelectionChanged" IsReadOnly="True" SelectionMode="Single"> <DataGrid.RowStyle> <Style TargetType="{x:Type DataGridRow}"> <Style

WPF DragDrop.DoDragDrop (for a RIGHT-Click?)

為{幸葍}努か 提交于 2019-12-23 16:49:39
问题 In WPF I want to do initiate a drag-drop using the right click. Something like windows explorer, right click, move slightly and you get the adorner to indicate a drag drop in operation. Don't move and you get the context menu when you let up the button. I have it all initiated but when I call the "DragDrop.DoDragDrop" it immediately falls right through, it doesn't wait for the mouse up. I did see this link Stack Overflow Question and it refers to a Silverlight article and the need for the

JavaScript: Capturing right click and disabling menu only within certain element

让人想犯罪 __ 提交于 2019-12-23 09:37:41
问题 I have coded a jquery script where there is a small grid on screen and using drag and drop users can place tiles on the grid (snaps in place). Currently if you hover over a tile it fades in the option to rotate, but I would much prefer it if you could right click to rotate (making it more natural). I understand blocking right click completely is often frowned upon so was wondering if it was possible just within a particular element, then capturing that event, doing something in JS and

Disable Right Click in website

不打扰是莪最后的温柔 提交于 2019-12-23 04:52:06
问题 I have this code below to disable right click. When you hit the right click it says Function is disabled. which works but i want it to show nothing at all basicaly when you hit the right click nothing happens... what kind of magic can we use to do that? var message="Function Disabled!"; function clickIE4(){ if (event.button==2){ alert(message); return false; } } function clickNS4(e){ if (document.layers||document.getElementById&&!document.all){ if (e.which==2||e.which==3){ alert(message);

jQuery Hover Menu disappears when right click

Deadly 提交于 2019-12-23 02:16:56
问题 I have a Menu that opens when hovering. But on right click the menu disappears when the contextmenu opens. But I can't figure out why. I need the hover menu open at the same time with contextmenu/right click. The jQuery Code (Version jquery-1.11.2.min.js) : jQuery(document).on('mouseover','#main_menu',function() { jQuery('#main_menu_inner').show(); }); jQuery(document).on('mouseleave','#main_menu',function() { jQuery('#main_menu_inner').hide(); }); The HTML: <div id="main_menu"> <img id="menu

Select ListBox item on rightclick in Word VBA

岁酱吖の 提交于 2019-12-22 18:15:21
问题 I'm developping a project in Word 2003 with VBA. I have a multiselect ListBox with some entries (dates). On rightclick I'd like to have an InputBox popping up where the user can change the selected date. This works well, as long a specific item is already focused (not only selected, but focused). But, if you rightclick on an item without focus, the box shows up and changes the date of the focused entry, not always the one you rightclicked. I found this answer (http://www.vbarchiv.net/tipps

Can I extend Button to add a RightClick event in such a way that the graphical side effects are also maintained?

柔情痞子 提交于 2019-12-22 08:01:15
问题 I'm trying to extend Button to add a RightClick event. My customer wants a button to do different things depending on if you left-click or right-click. I expected there to be an easy event for right-clicking, but it turns out there's not. I'd prefer Button's visual behavior to be identical to the preexisting Click event, but it's proving tough. Button has many graphical behaviors that occur when you click and drag on and off the button. When you click-down, the button lowers. If you drag off

how to simulate right click in javascript [duplicate]

こ雲淡風輕ζ 提交于 2019-12-21 05:05:05
问题 This question already has answers here : Trigger right click using pure Javascript (3 answers) Closed 6 years ago . Ok, so i know i can simulate a click by running this code document.getElementById('recover').click(); the closest this i could find was cntextmenu so i tried document.getElementById('recover').contextmenu(); however this does nothing Is it possible to right click and element to bring up the contextual menu so i can click an item on that list ? and if so could someone point me in