HighDots Forums  

Re: onmouseup isn't always triggered when mouse button is released

Javascript JavaScript language (comp.lang.javascript)


Discuss Re: onmouseup isn't always triggered when mouse button is released in the Javascript forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Stevo
 
Posts: n/a

Default Re: onmouseup isn't always triggered when mouse button is released - 08-26-2008 , 12:25 PM






yawnmoth wrote:
Quote:
If I comment out "document.getElemenById("demo").onmousedown =
mousedown;", it works. Why would that make a difference?
Look very closely at it. If you need a clue:

Quote:
If I comment out "document.getElemenById("demo").onmousedown =
______________________________________^___________ ___

t


Reply With Quote
  #2  
Old   
yawnmoth
 
Posts: n/a

Default Re: onmouseup isn't always triggered when mouse button is released - 08-26-2008 , 05:57 PM






On Aug 26, 11:25*am, Stevo <n... (AT) mail (DOT) invalid> wrote:
Quote:
yawnmoth wrote:
If I comment out "document.getElemenById("demo").onmousedown =
mousedown;", it works. *Why would that make a difference?

Look very closely at it. If you need a clue:

*> If I comment out "document.getElemenById("demo").onmousedown =
______________________________________^___________ ___

t
I made the change and it's still not working as expected. I add the
't' and get the same behavior as before. The only difference is that
an entry isn't added to the Error Log. And now, if I comment out
document.getElementById("demo"), it doesn't make a difference.
Clicking outside of the box still doesn't do anything.

Any ideas as to why?

Thanks!


Reply With Quote
  #3  
Old   
Jorge
 
Posts: n/a

Default Re: onmouseup isn't always triggered when mouse button is released - 08-26-2008 , 10:29 PM



On Aug 26, 11:57*pm, yawnmoth <terra1... (AT) yahoo (DOT) com> wrote:
Quote:
I made the change and it's still not working as expected. *I add the
't' and get the same behavior as before. *The only difference is that
an entry isn't added to the Error Log. *And now, if I comment out
document.getElementById("demo"), it doesn't make a difference.
Clicking outside of the box still doesn't do anything.

Any ideas as to why?

Thanks!
The body's height happens to be much less than the size on the window
for that .html so that clicking under/below the box isn't cliking into
the body. Click at the right side next to the box... and it works.

--Jorge.


Reply With Quote
  #4  
Old   
yawnmoth
 
Posts: n/a

Default Re: onmouseup isn't always triggered when mouse button is released - 08-27-2008 , 03:01 PM



On Aug 26, 9:29*pm, Jorge <jo... (AT) jorgechamorro (DOT) com> wrote:
Quote:
On Aug 26, 11:57*pm,yawnmoth<terra1... (AT) yahoo (DOT) com> wrote:



I made the change and it's still not working as expected. *I add the
't' and get the same behavior as before. *The only difference is that
an entry isn't added to the Error Log. *And now, if I comment out
document.getElementById("demo"), it doesn't make a difference.
Clicking outside of the box still doesn't do anything.

Any ideas as to why?

Thanks!

The body's height happens to be much less than the size on the window
for that .html so that clicking under/below the box isn't cliking into
the body. Click at the right side next to the box... and it works.
That helped - thanks!

Am using document.onmouseup, instead, now.


Reply With Quote
  #5  
Old   
Thomas 'PointedEars' Lahn
 
Posts: n/a

Default Re: onmouseup isn't always triggered when mouse button is released - 08-27-2008 , 04:21 PM



yawnmoth wrote:
Quote:
Am using document.onmouseup, instead, now.
You should use that only as a fallback for the standards compliant

document.documentElement.addEventListener("mouseup ", ...);


PointedEars
--
Anyone who slaps a 'this page is best viewed with Browser X' label on
a Web page appears to be yearning for the bad old days, before the Web,
when you had very little chance of reading a document written on another
computer, another word processor, or another network. -- Tim Berners-Lee


Reply With Quote
  #6  
Old   
yawnmoth
 
Posts: n/a

Default Re: onmouseup isn't always triggered when mouse button is released - 08-28-2008 , 04:48 PM



On Aug 27, 3:21*pm, Thomas 'PointedEars' Lahn <PointedE... (AT) web (DOT) de>
wrote:
Quote:
yawnmothwrote:
Am using document.onmouseup, instead, now.

You should use that only as a fallback for the standards compliant

* document.documentElement.addEventListener("mouseup ", ...);
Thanks for the suggestion!


Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.