473,396 Members | 2,158 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

Why onResize fires 3 times when I re-size the window?

df
Why?

May 17 '06 #1
14 3070
df wrote on 18 mei 2006 in comp.lang.javascript:
Why?


Why not?

Afer all resizing can be a lenghty buziness.

--
Evertjan.
The Netherlands.
(Please change the x'es to dots in my emailaddress)
May 17 '06 #2
df
Not understand very much.Would you mind telling more details?

May 17 '06 #3
On 17 May 2006 15:01:07 -0700, "df" <df****@msn.com> wrote:
Why onResize fires 3 times when I re-size the window?


because it fires as you're resizing it, and not just at the end of the
resize, why would you expect it to only fire at the end?

Jim.
May 17 '06 #4
Jim Ley wrote :
On 17 May 2006 15:01:07 -0700, "df" <df****@msn.com> wrote:
Why onResize fires 3 times when I re-size the window?


because it fires as you're resizing it, and not just at the end of the
resize, why would you expect it to only fire at the end?

Jim.

IE 6+ will fire the resize event continuously. Opera 8+ also.

Firefox, Mozilla Seamonkey, Mozilla Suite will not.

Bug 114649: onresize events should fire while resizing the window, not
just when the mouse stops moving
https://bugzilla.mozilla.org/show_bug.cgi?id=114649

Gérard
--
remove blah to email me
May 18 '06 #5
Jim Ley wrote :
On 17 May 2006 15:01:07 -0700, "df" <df****@msn.com> wrote:
Why onResize fires 3 times when I re-size the window?


because it fires as you're resizing it, and not just at the end of the
resize, why would you expect it to only fire at the end?

Jim.

IE 6+ will fire the resize event continuously. Opera 8+ also.

Firefox, Mozilla Seamonkey, Mozilla Suite will not.

Bug 114649: onresize events should fire while resizing the window, not
just when the mouse stops moving
https://bugzilla.mozilla.org/show_bug.cgi?id=114649

Gérard
--
remove blah to email me
May 18 '06 #6
On Wed, 17 May 2006 19:56:42 -0400, =?ISO-8859-1?Q?G=E9rard_Talbot?=
<ne***********@gtalbot.org> wrote:
Jim Ley wrote :
On 17 May 2006 15:01:07 -0700, "df" <df****@msn.com> wrote:
Why onResize fires 3 times when I re-size the window?


because it fires as you're resizing it, and not just at the end of the
resize, why would you expect it to only fire at the end?

Jim.

IE 6+ will fire the resize event continuously. Opera 8+ also.


On windows both of these depend on the OS setting show window contents
whilst dragging.

Jim.
May 18 '06 #7
df wrote on 18 mei 2006 in comp.lang.javascript:
Not understand very much.Would you mind telling more details?


Would you mind where you are talking about?

Please quote what you are replying to.

If you want to post a followup via groups.google.com, don't use the
"Reply" link at the bottom of the article. Click on "show options" at the
top of the article, then click on the "Reply" at the bottom of the article
headers.
<http://www.safalra.com/special/googlegroupsreply/>

--
Evertjan.
The Netherlands.
(Please change the x'es to dots in my emailaddress)
May 18 '06 #8
df
Evertjan. 写é“:
df wrote on 18 mei 2006 in comp.lang.javascript:
Not understand very much.Would you mind telling more details?
Would you mind where you are talking about?
Please quote what you are replying to.

If you want to post a followup via groups.google.com, don't use the
"Reply" link at the bottom of the article. Click on "show options" at the
top of the article, then click on the "Reply" at the bottom of the article
headers.


Roger~
And now,Am I OK this time?

May 18 '06 #9
df
Well,dear guys,I just want append a function to run only *one* time
after the OnResize event is finished.How can I?

Jim Ley 写é“:
On Wed, 17 May 2006 19:56:42 -0400, =?ISO-8859-1?Q?G=E9rard_Talbot?=
<ne***********@gtalbot.org> wrote:
Jim Ley wrote :
On 17 May 2006 15:01:07 -0700, "df" <df****@msn.com> wrote:

Why onResize fires 3 times when I re-size the window?

because it fires as you're resizing it, and not just at the end of the
resize, why would you expect it to only fire at the end?

Jim.

IE 6+ will fire the resize event continuously. Opera 8+ also.


On windows both of these depend on the OS setting show window contents
whilst dragging


May 18 '06 #10
df wrote on 18 mei 2006 in comp.lang.javascript:
Evertjan. 写é“:
df wrote on 18 mei 2006 in comp.lang.javascript:
> Not understand very much.Would you mind telling more details?

Would you mind where you are talking about?
Please quote what you are replying to.

If you want to post a followup via groups.google.com, don't use the
"Reply" link at the bottom of the article. Click on "show options" at
the top of the article, then click on the "Reply" at the bottom of
the article headers.


Roger~
And now,Am I OK this time?


Roger roger, Roger.

--
Evertjan.
The Netherlands.
(Please change the x'es to dots in my emailaddress)
May 18 '06 #11
On 18 May 2006 04:55:48 -0700, "df" <df****@msn.com> wrote:
Well,dear guys,I just want append a function to run only *one* time
after the OnResize event is finished.How can I?

var globalWindowResizeTimer=0

window.onresize=function() {
clearTimeout(globalWindowResizeTimer);
globalWindowResizeTimer=setTimeout(whateverYouWant ,150);
}

The normal event culling method.

Jim.
May 18 '06 #12
df said the following on 5/18/2006 7:55 AM:
Well,dear guys,I just want append a function to run only *one* time
after the OnResize event is finished.How can I?


<URL:
http://msdn.microsoft.com/library/de...resizeend.asp?

"There is no public standard that applies to this event"

--
Randy
comp.lang.javascript FAQ - http://jibbering.com/faq & newsgroup weekly
Javascript Best Practices - http://www.JavascriptToolbox.com/bestpractices/
May 18 '06 #13
df
onresizeend Event doesn't work on IE 6(seems only on IE 5.5)

Well,this seems a old prolem,let's ignore this thing.Thk u,all friends.
;-)

http://groups.google.com/group/comp....6e76ef355d9059

Randy Webb 写é“:
df said the following on 5/18/2006 7:55 AM:
Well,dear guys,I just want append a function to run only *one* time
after the OnResize event is finished.How can I?


<URL:
http://msdn.microsoft.com/library/de...resizeend.asp?

"There is no public standard that applies to this event"


May 18 '06 #14
Jim Ley wrote:
On 18 May 2006 04:55:48 -0700, "df" <df****@msn.com> wrote:
Well,dear guys,I just want append a function to run only *one* time
after the OnResize event is finished.How can I?
var globalWindowResizeTimer=0


Initializing a timer variable with 0 is by no means a way ...
window.onresize=function() {
clearTimeout(globalWindowResizeTimer);
.... to prevent this from failing or producing undesired side effects.
Instead, the variable should be initialized with a value that is
unlikely to be returned by window.setTimeout(), such as `null', and
_window_.clearTimeout() should only be called iff

1. window.clearTimeout() is available as a method. It appears
safe to assume that if window.setTimeout() is supported,
window.clearTimeout() is supported as well.

2. The argument value is different from the initial value.
globalWindowResizeTimer=setTimeout(whateverYouWant ,150);
_window_.setTimeout() should only be called iff that method is supported.
}

The normal event culling method.


For suitable values of "normal".
PointedEars
--
This above all: To thine own self be true.
-- William Shakespeare (1564-1616)
May 23 '06 #15

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: Bas | last post by:
Hello all, I'm trying to create a little script which will save the width of a certain frame into a database, so that every user still has his/her "own" frame width when logging back on. Now,...
2
by: TF | last post by:
hi, i am using a ListBox control on a windows form using VB.Net. when i set the DataSource property of the control to an ArrayList it fires following events in this order: SelectedIndexChanged...
4
by: me54 | last post by:
does anyone know how to call some javascript function when firefox fire the onresize event? something like <body onresize="alert();"> doesn't work on forefox? thnx.
6
by: hannibal | last post by:
Hi, i need to refresh page cathcing "onResize" event. I wrote this code: <body onResize="javascript:winodw.location.reload(true); return true;"> On I.E. it works, but it doesn't work on...
5
by: Maxine G | last post by:
I have two forms, a menu and a data entry form. The entry form is bound to a query against linked SQL server tables. In the deactivate event, I have some code which asks the user if they want to...
9
by: HL | last post by:
I am using VS 2005 Beta - C# Problem: The Timer fires a few milliseconds before the actual Due-Time Let's say a timer is created in the following manner: System.Threading.Timer m_timer = null;...
6
by: whtinkm | last post by:
Hi, All Recently, my project need some code like following: using System; using System.Threading; namespace MyTimerTest { class Class1 {
1
by: Roland | last post by:
Hi, I have written a Windows Service with a Timer (System). The Interval is set to 60000 (60 seconds) for testing. In the Timer1_Elapsed event I execute a task. In this case I have to read a...
5
by: christianlott1 | last post by:
I admit my form is pretty complex and may need a total overhaul - I have two subforms synchronized on a form through an unbound text box. When I enter a new record in the second subform it used...
2
by: jwhitwork | last post by:
I'm trying to create a liquid layer and need to call my SetLayerPos() function onResize. When I create a test page: <html><body onresize="alert('test')"></body></html> It works fine. ...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.