Put in a breakpoint or something to see how many are being instantiated.
I would imagine in the first scenario a new dialog gets instantiated every
time.

-Alex

On 6/7/16, 11:21 AM, "mark goldin" <[email protected]> wrote:

>I am showing my popup from datagrid custom item renderer in two ways.
>
>1.
>var aad:popupDialog = new popupDialog();
>aad.show(this);
>
>2.
>this.document._showPopupDialog.show();
>
>for the second one the main screen has the following:
>
>_showPopupDialog = new ShowPopupDialog();
>_showSomeDialog.initDialog(this);
>
>public class ShowPopupDialog
>{
>public function ShowPopupDialog()
>{
>}
>public function initDialog(view:*):void
>{
>_view = view;
>_dialog = new popupDialog();
>}
>public function show():void
>{
>_dialog.show(_view);
>}
>}
>
>The popupDialog is a TileWindow. I have a break point in its
>CreationComplete and it gets hit every time when I use 1. If I use 2. it's
>only called for the first time.
>Why is there any difference?
>
>Thanks

Reply via email to