bufanliu / flexlib

Automatically exported from code.google.com/p/flexlib
0 stars 0 forks source link

restore via actionscript vanish window control buttons #111

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. see below
2.
3.

What is the expected output? What do you see instead?
The expected is letting me restore the window in actionscript way.
I see instead a wierd thing :)  The control buttons of the window (like
maximize button, minimize button and close button) vanishes

What version of the product are you using? On what operating system?
FlexLib 2.4
WindowsXP-SP2- flashplayer 9.0.28  - Flex 2.0.1

Please provide any additional information below.

 here a simple code that reproduce the behavior:
<?xml version="1.0" encoding="utf-8"?>
<mx:Application
    xmlns:mx="http://www.adobe.com/2006/mxml"
    xmlns:code="http://code.google.com/p/flexlib/"
    >

    <code:MDICanvas id="mdiCanvas" width="100%" height="100%">
        <mx:Button label="restore" click="toUp()"/>
        <code:MDIWindow/>
    </code:MDICanvas>

    <mx:Script>
        <![CDATA[
            import flexlib.mdi.containers.MDIWindow;

            public function toUp():void {
                MDIWindow(mdiCanvas.windowManager.windowList[0]).restore();
            }
        ]]>
    </mx:Script>
</mx:Application>

run as follows:  first: minimize the MDI window
second: press the button labeled "restore".
and say bye to the window control buttons. R.I.P  :)

Original issue reported on code.google.com by illogic....@gmail.com on 15 Apr 2008 at 8:14

GoogleCodeExporter commented 8 years ago
This is the result of an unfortunate naming mistake on my part. This will be 
fixed at
some point but for now use unMinimize(), not restore().

Original comment by ben.clin...@gmail.com on 15 Apr 2008 at 8:35

GoogleCodeExporter commented 8 years ago

Original comment by dmcc...@gmail.com on 8 Jan 2009 at 5:01

GoogleCodeExporter commented 8 years ago
to fix, simply add the following line to the restore() function:

showControls = true;

Original comment by christop...@gmail.com on 22 Apr 2009 at 9:25