How to prevent an applet getting refreshed when browser is resized?
Hello ,
How to prevent an applet getting refreshed when browser is resized?
The problem is like this - I have an applet with a custom component .
The Internal layouting mechanism of the component is gridbag . When
there is an application triggered repainting there is no problem.
But When the browser is resized , a system triggered repainting occurs
and hence recursive layouting was done resulting in the component getting haywire.
Any help in this regard is greatly appreciated .
regards,
Krishna
Re: How to prevent an applet getting refreshed when browser is resized?
hi, there:
I have the same question as u do, Did u come up with an idea?
Thanxxx
Vivian
Re: How to prevent an applet getting refreshed when browser is resized?
Hi
i am also facing same kind of problem.......
Re: How to prevent an applet getting refreshed when browser is resized?
Hi there,
When a browser is resized then it automatically calls the update(..) and paint(..) events of the applet. So what you have to do is override the these two methods and use a flag so that on any subsequent calls
to these paints does not result in the original update(..) and paint(.) getting executed.
If the problem that you are facing is due to layout problems of a component inside the applet you can try
overriding the validate and invalidate methods with appropriate code. You also have to take care of the
individual paint and update methods of the components themselves I think.
Re: How to prevent an applet getting refreshed when browser is resized?
hi!!
Which browser are you using.
Jawwad.