Questions tagged [onmouseclick]

78 questions
92
votes
4 answers

javascript get x and y coordinates on mouse click

I have a little div tag that when I click on it (onClick event), it will run the printMousePos() function. These are the HTML tags:
Bryce Hahn
  • 1,585
  • 4
  • 16
  • 26
6
votes
2 answers

Can't find the parent of a templated control by type(!) (wpf)

In my WPF project I have a bit complex control. In the project I only use Controls (they're all templated), besides MainWindow. On one screen I have the following layout (for showing the layout after templates have been applied and contents…
Tenshiko
  • 1,450
  • 3
  • 17
  • 33
4
votes
1 answer

Set order of mouse click events JavaScript

I have two elements - a parent and a child. Both have on click event handlers. If I click on the child element then both event handlers run - parent's first then child's (at least on Chrome). I don't know how the browser determines which order to…
MrMadsen
  • 2,713
  • 3
  • 22
  • 31
3
votes
1 answer

How do I fire a mouse click on a C# MenuStrip when a form become activated/focused?

Possible Duplicate: Click lost on focusing form If a form with a MenuStrip is not the window that has focus and you click on the MenuStrip, it uses that first click to make the window active, and then you have to click the MenuStrip again to get…
Ryan R
  • 167
  • 7
3
votes
3 answers

How to find mouseclick first and if not clicked, then go for mouseover

How to find mouseclick first and if not clicked, then go for mouseover ? I had implemented two types of functionalities in two mouse events. One in mouseover and the other in mouseclick. If I clicked, i need to trigger mouseclick event first,…
Earth
  • 3,477
  • 6
  • 37
  • 78
3
votes
1 answer

Jquery mouse onclick inside angularjs

I am working with a page where both JQuery and AngularJS are used. Using jQuery taggable-text.js plugin I am able to select "Share-with" items by mouse click and keyboard. But when I try to select elements inside table (in scope of AngularJS), I am…
3
votes
1 answer

Read coordinates from mouse click in mpld3

I generated a figure using mpld3 and linked it to plugins.MousePosition() to display the coordinates, as below. import numpy as np import matplotlib import matplotlib.pyplot as plt import mpld3 from mpld3 import plugins, utils x,y =…
sjp14051
  • 99
  • 9
3
votes
1 answer

Clickable enemies

Hi im totally new to javascript and need help.im making an HtML javascript game. I just wanted to ask how do i get my enemies to be clickable?? i have managed to successfully create my enemies for my game but currently they come down from the top of…
2
votes
1 answer

JavaScript - event relatedTarget is not working for onClick

I am getting an error when I use event.relatedTarget for a onClick only, however it works well for onMouseout. This is the code I have: