What is image1?  What version of Flex?  This is a known issue that is
still under investigation but is better in Flex 3.  Does the process
memory shrink if you minimize the browser?

 

________________________________

From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of doepositive
Sent: Thursday, December 13, 2007 7:20 AM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] Browser size keeps growing when I load and image

 

I fooling around with flex to learn more and I ran into a problem. 
I'm trying to schedule a refresh of an image every 30 sec (or so), I 
I leave the browser open the IEXPLORER size grows with every load. I 
tried cachePolicy="off" 

Here is an example of what I'm doing

import flash.display.Sprite;
import flash.events.Event;
import flash.events.TimerEvent;
import flash.utils.Timer;

private function refreshCharts():void {
image1.cachePolicy="off"
image1.load("http:\/\/www.someSite.com/someImgage.gif");
} 
private function ShortTimer():void 
{

// creates a new five-second Timer
var minuteTimer:Timer = new Timer(1000, 150);

// designates listeners for the interval event and the 
completion event
minuteTimer.addEventListener(TimerEvent.TIMER, onTick);
minuteTimer.addEventListener(TimerEvent.TIMER_COMPLETE, 
onTimerComplete);

// starts the timer ticking
minuteTimer.start();
}

private function onTick(evt:TimerEvent):void 
{
if(evt.target.currentCount == 150){

ShortTimer();
}
}
public function onTimerComplete(evt:TimerEvent):void
{
refreshCharts();//
ShortTimer();

}

 

Reply via email to