[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Swftools-common] patch for rfxview.sc for browser window resize
From: |
Chris Pugh |
Subject: |
Re: [Swftools-common] patch for rfxview.sc for browser window resize |
Date: |
Thu, 25 Feb 2010 23:27:07 +0000 |
Maybe here should be a Patch section here,
http://wiki.swftools.org
rather than sending to the list?
Chris.
On 25 February 2010 23:10, Haronil Estevez <address@hidden> wrote:
> Here is my patch to handle browser window resize events so that the viewer
> resizes as well.
> See: http://www.mail-archive.com/address@hidden/msg03006.html
> --
> Haronil Estevez
>
> 637a638,708
>>
>> var myListener = new Object();
>>
>> myListener.onResize = function ()
>> {
>>
>> et_total_pages.text=viewport._totalframes;
>> //swfwidth = viewport._width;
>> //swfheight = viewport._height;
>>
>> Dragging = "";
>>
>> Stage.scaleMode="noScale";
>> Stage.align ="LT";
>>
>> Stage.showMenu = false;
>>
>> fullwidth = Stage.width;
>> fullheight = Stage.height;
>>
>> contentwidth = fullwidth - 40;
>> contentheight = fullheight - 70;
>>
>> background._width = fullwidth-1;
>> background._height = fullheight-1;
>>
>> // resize/position hscroll outline
>> hscroll_outline._x = 10;
>> hscroll_outline._y = fullheight-20;
>> hscroll_outline._width = fullwidth-40;
>> hscroll_outline._height = 10;
>>
>> // resize/position vscroll outline
>> vscroll_outline._x = fullwidth-20;
>> vscroll_outline._y = 40;
>> vscroll_outline._width = 10;
>> vscroll_outline._height = fullheight-70;
>>
>> // resize/position content outline
>> content_outline._x = 9;
>> content_outline._y = 39;
>> content_outline._width = contentwidth+1;
>> content_outline._height = contentheight+1;
>>
>> // move all objects to their proper positions
>> vscrollbar._x = fullwidth-22;
>> hscrollbar._y = fullheight-22;
>> p1._x = fullwidth-25-20 - p1._width/2;
>> o1._x = fullwidth-50-20 - o1._width/2;
>> z1._x = fullwidth-75-20 - z1._width/2;
>> m1._x = fullwidth-100-20 - m1._width/2;
>>
>> l1._x = fullwidth/2-100 - l1._width/2;
>> r1._x = fullwidth/2+100 - r1._width/2;
>>
>> et._x = fullwidth/2 -
>> (et._width+etmiddle._width+et_total_pages._width)/2;
>> etmiddle._x = fullwidth/2 -
>> (et._width+etmiddle._width+et_total_pages._width)/2 + et._width;
>> et_total_pages._x = fullwidth/2 -
>> (et._width+etmiddle._width+et_total_pages._width)/2 +
>> et._width+etmiddle._width;
>>
>> areabutton._xscale = contentwidth;
>> areabutton._yscale = contentheight;
>> cliparea._xscale = contentwidth;
>> cliparea._yscale = contentheight;
>> viewport.setMask(cliparea);
>>
>>
>> setOneDirScrollZoomLevel();
>> };
>>
>> Stage.addListener(myListener);
>>