You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@royale.apache.org by Serkan Taş <se...@likyateknoloji.com> on 2019/11/02 12:07:24 UTC

menu is not initialized

Hi,

I am using the below declaration for the initialization of menu :

     <fx:Declarations>
         <fx:XMLList id="menuDataXMLList">
             <menuitem label="{resourceManager.getString('messages', 
'configFiles')}" id="configfiles" role="{UserRole.OPERATION}">
                 <menuitem label="label-1-1"/>
                 <menuitem label="label-1-2"/>
             </menuitem>
         </fx:XMLList>
</fx:Declarations>

Unfortunately it is not working. I guess the resource can not be 
retrieved this way, because when I change the code as below it is 
disğlayed as expected :


<fx:Declarations>
         <fx:XMLList id="menuDataXMLList">
             <menuitem label="label-1" id="configfiles">
                 <menuitem label="label-1-1"/>
                 <menuitem label="label-1-2"/>
             </menuitem>
         </fx:XMLList>
   </fx:Declarations>

Should I file an issue ?

Thanks,
Serkan

Re: menu is not initialized

Posted by Serkan Taş <se...@likyateknoloji.com>.
created the issue https://github.com/apache/royale-asjs/issues/545

any advice for workaround ?

3.11.2019 02:23 tarihinde Alex Harui yazdı:
>
> If it worked in Flex, file an issue with a simple test case.
>
> -Alex
>
> *From: *Piotr Zarzycki <pi...@gmail.com>
> *Reply-To: *"users@royale.apache.org" <us...@royale.apache.org>
> *Date: *Saturday, November 2, 2019 at 9:16 AM
> *To: *"users@royale.apache.org" <us...@royale.apache.org>
> *Subject: *menu is not initialized
>
> Ahh I'm sorry I understand now. :) I bet this is something in the 
> compiler.
>
> On Sat, Nov 2, 2019, 2:51 PM Serkan Taş <serkan.tas@likyateknoloji.com 
> <ma...@likyateknoloji.com>> wrote:
>
>     Hi Piotr,
>
>     If you mean to define it as xml variable within mxml, yes it works
>     for another test case as below :
>
>         private var menubarXML:XMLList =
>                     <>
>                         <menuitem label="Menu1" data="top">
>                             <menuitem label="MenuItem 1-A" data="1A"/>
>                             <menuitem label="MenuItem 1-B" data="1B"/>
>                         </menuitem>
>                         <menuitem label="Menu2" data="top">
>                             <menuitem label="MenuItem 2-A"
>     type="check"  data="2A"/>
>                             <menuitem type="separator"/>
>                             <menuitem label="MenuItem 2-B" >
>                                 <menuitem label="SubMenuItem 3-A"
>     type="radio"
>                                     groupName="one" data="3A"/>
>                                 <menuitem label="SubMenuItem 3-B"
>     type="radio"
>                                     groupName="one" data="3B"/>
>                             </menuitem>
>                         </menuitem>
>                     </>;
>
>     Should I change my code and define it as variable ?
>
>     This is my question :)
>
>     Thanks,
>     Serkan
>
>     2.11.2019 16:18 tarihinde Piotr Zarzycki yazdı:
>
>         Hi Serkan,
>
>         Try provide to this menu dataProvider with XML instead
>         declaring it in MXML ? Does it work ?
>
>         Thanks,
>
>         Piotr
>
>         sob., 2 lis 2019 o 13:08 Serkan Taş
>         <serkan.tas@likyateknoloji.com
>         <ma...@likyateknoloji.com>> napisał(a):
>
>             Hi,
>
>             I am using the below declaration for the initialization of
>             menu :
>
>             <fx:Declarations>
>                     <fx:XMLList id="menuDataXMLList">
>                         <menuitem
>             label="{resourceManager.getString('messages',
>             'configFiles')}" id="configfiles"
>             role="{UserRole.OPERATION}">
>                             <menuitem label="label-1-1"/>
>                             <menuitem label="label-1-2"/>
>                         </menuitem>
>                     </fx:XMLList>
>             </fx:Declarations>
>
>             Unfortunately it is not working. I guess the resource can
>             not be retrieved this way, because when I change the code
>             as below it is disğlayed as expected :
>
>
>             <fx:Declarations>
>                     <fx:XMLList id="menuDataXMLList">
>                         <menuitem label="label-1" id="configfiles">
>                             <menuitem label="label-1-1"/>
>                             <menuitem label="label-1-2"/>
>                         </menuitem>
>                     </fx:XMLList>
>             </fx:Declarations>
>
>             Should I file an issue ?
>
>             Thanks,
>             Serkan
>
>
>         -- 
>
>         /Piotr Zarzycki /
>
>         Patreon: _https://www.patreon.com/piotrzarzycki
>         <https://nam04.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.patreon.com%2Fpiotrzarzycki&data=02%7C01%7Caharui%40adobe.com%7C4beb5605e1f047fca5b408d75fafffde%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C637083081827039793&sdata=KYqNZWoBsPDyBtOkhAR7y2Xb5HlSPBfysRFb8zNotyQ%3D&reserved=0>_
>


Re: menu is not initialized

Posted by Alex Harui <ah...@adobe.com>.
If it worked in Flex, file an issue with a simple test case.

-Alex

From: Piotr Zarzycki <pi...@gmail.com>
Reply-To: "users@royale.apache.org" <us...@royale.apache.org>
Date: Saturday, November 2, 2019 at 9:16 AM
To: "users@royale.apache.org" <us...@royale.apache.org>
Subject: menu is not initialized

Ahh I'm sorry I understand now. :) I bet this is something in the compiler.

On Sat, Nov 2, 2019, 2:51 PM Serkan Taş <se...@likyateknoloji.com>> wrote:
Hi Piotr,

If you mean to define it as xml variable within mxml, yes it works for another test case as below :

        private var menubarXML:XMLList =
                <>
                    <menuitem label="Menu1" data="top">
                        <menuitem label="MenuItem 1-A" data="1A"/>
                        <menuitem label="MenuItem 1-B" data="1B"/>
                    </menuitem>
                    <menuitem label="Menu2" data="top">
                        <menuitem label="MenuItem 2-A" type="check"  data="2A"/>
                        <menuitem type="separator"/>
                        <menuitem label="MenuItem 2-B" >
                            <menuitem label="SubMenuItem 3-A" type="radio"
                                groupName="one" data="3A"/>
                            <menuitem label="SubMenuItem 3-B" type="radio"
                                groupName="one" data="3B"/>
                        </menuitem>
                    </menuitem>
                </>;

Should I change my code and define it as variable ?

This is my question :)

Thanks,
Serkan
2.11.2019 16:18 tarihinde Piotr Zarzycki yazdı:
Hi Serkan,

Try provide to this menu dataProvider with XML instead declaring it in MXML ? Does it work ?

Thanks,
Piotr

sob., 2 lis 2019 o 13:08 Serkan Taş <se...@likyateknoloji.com>> napisał(a):
Hi,

I am using the below declaration for the initialization of menu :

    <fx:Declarations>
        <fx:XMLList id="menuDataXMLList">
            <menuitem label="{resourceManager.getString('messages', 'configFiles')}" id="configfiles" role="{UserRole.OPERATION}">
                <menuitem label="label-1-1"/>
                <menuitem label="label-1-2"/>
            </menuitem>
        </fx:XMLList>
        </fx:Declarations>

Unfortunately it is not working. I guess the resource can not be retrieved this way, because when I change the code as below it is disğlayed as expected :


    <fx:Declarations>
        <fx:XMLList id="menuDataXMLList">
            <menuitem label="label-1" id="configfiles">
                <menuitem label="label-1-1"/>
                <menuitem label="label-1-2"/>
            </menuitem>
        </fx:XMLList>
      </fx:Declarations>

Should I file an issue ?

Thanks,
Serkan


--

Piotr Zarzycki

Patreon: https://www.patreon.com/piotrzarzycki<https://nam04.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.patreon.com%2Fpiotrzarzycki&data=02%7C01%7Caharui%40adobe.com%7C4beb5605e1f047fca5b408d75fafffde%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C0%7C637083081827039793&sdata=KYqNZWoBsPDyBtOkhAR7y2Xb5HlSPBfysRFb8zNotyQ%3D&reserved=0>


menu is not initialized

Posted by Piotr Zarzycki <pi...@gmail.com>.
Ahh I'm sorry I understand now. :) I bet this is something in the compiler.

On Sat, Nov 2, 2019, 2:51 PM Serkan Taş <se...@likyateknoloji.com>
wrote:

> Hi Piotr,
>
> If you mean to define it as xml variable within mxml, yes it works for
> another test case as below :
>
>         private var menubarXML:XMLList =
>                 <>
>                     <menuitem label="Menu1" data="top">
>                         <menuitem label="MenuItem 1-A" data="1A"/>
>                         <menuitem label="MenuItem 1-B" data="1B"/>
>                     </menuitem>
>                     <menuitem label="Menu2" data="top">
>                         <menuitem label="MenuItem 2-A" type="check"
> data="2A"/>
>                         <menuitem type="separator"/>
>                         <menuitem label="MenuItem 2-B" >
>                             <menuitem label="SubMenuItem 3-A" type="radio"
>                                 groupName="one" data="3A"/>
>                             <menuitem label="SubMenuItem 3-B" type="radio"
>                                 groupName="one" data="3B"/>
>                         </menuitem>
>                     </menuitem>
>                 </>;
>
> Should I change my code and define it as variable ?
>
> This is my question :)
>
> Thanks,
> Serkan
>
> 2.11.2019 16:18 tarihinde Piotr Zarzycki yazdı:
>
> Hi Serkan,
>
> Try provide to this menu dataProvider with XML instead declaring it in
> MXML ? Does it work ?
>
> Thanks,
> Piotr
>
> sob., 2 lis 2019 o 13:08 Serkan Taş <se...@likyateknoloji.com>
> napisał(a):
>
>> Hi,
>>
>> I am using the below declaration for the initialization of menu :
>>
>>     <fx:Declarations>
>>         <fx:XMLList id="menuDataXMLList">
>>             <menuitem label="{resourceManager.getString('messages',
>> 'configFiles')}" id="configfiles" role="{UserRole.OPERATION}">
>>                 <menuitem label="label-1-1"/>
>>                 <menuitem label="label-1-2"/>
>>             </menuitem>
>>         </fx:XMLList>
>>         </fx:Declarations>
>>
>> Unfortunately it is not working. I guess the resource can not be
>> retrieved this way, because when I change the code as below it is disğlayed
>> as expected :
>>
>>
>>     <fx:Declarations>
>>         <fx:XMLList id="menuDataXMLList">
>>             <menuitem label="label-1" id="configfiles">
>>                 <menuitem label="label-1-1"/>
>>                 <menuitem label="label-1-2"/>
>>             </menuitem>
>>         </fx:XMLList>
>>       </fx:Declarations>
>>
>> Should I file an issue ?
>>
>> Thanks,
>> Serkan
>>
>
>
> --
>
> Piotr Zarzycki
>
> Patreon: *https://www.patreon.com/piotrzarzycki
> <https://www.patreon.com/piotrzarzycki>*
>
>
>

Re: menu is not initialized

Posted by Serkan Taş <se...@likyateknoloji.com>.
Hi Piotr,

If you mean to define it as xml variable within mxml, yes it works for 
another test case as below :

         private var menubarXML:XMLList =
                 <>
                     <menuitem label="Menu1" data="top">
                         <menuitem label="MenuItem 1-A" data="1A"/>
                         <menuitem label="MenuItem 1-B" data="1B"/>
                     </menuitem>
                     <menuitem label="Menu2" data="top">
                         <menuitem label="MenuItem 2-A" type="check"  
data="2A"/>
                         <menuitem type="separator"/>
                         <menuitem label="MenuItem 2-B" >
                             <menuitem label="SubMenuItem 3-A" type="radio"
                                 groupName="one" data="3A"/>
                             <menuitem label="SubMenuItem 3-B" type="radio"
                                 groupName="one" data="3B"/>
                         </menuitem>
                     </menuitem>
                 </>;

Should I change my code and define it as variable ?

This is my question :)

Thanks,
Serkan

2.11.2019 16:18 tarihinde Piotr Zarzycki yazdı:
> Hi Serkan,
>
> Try provide to this menu dataProvider with XML instead declaring it in 
> MXML ? Does it work ?
>
> Thanks,
> Piotr
>
> sob., 2 lis 2019 o 13:08 Serkan Taş <serkan.tas@likyateknoloji.com 
> <ma...@likyateknoloji.com>> napisał(a):
>
>     Hi,
>
>     I am using the below declaration for the initialization of menu :
>
>     <fx:Declarations>
>             <fx:XMLList id="menuDataXMLList">
>                 <menuitem
>     label="{resourceManager.getString('messages', 'configFiles')}"
>     id="configfiles" role="{UserRole.OPERATION}">
>                     <menuitem label="label-1-1"/>
>                     <menuitem label="label-1-2"/>
>                 </menuitem>
>             </fx:XMLList>
>     </fx:Declarations>
>
>     Unfortunately it is not working. I guess the resource can not be
>     retrieved this way, because when I change the code as below it is
>     disğlayed as expected :
>
>
>     <fx:Declarations>
>             <fx:XMLList id="menuDataXMLList">
>                 <menuitem label="label-1" id="configfiles">
>                     <menuitem label="label-1-1"/>
>                     <menuitem label="label-1-2"/>
>                 </menuitem>
>             </fx:XMLList>
>       </fx:Declarations>
>
>     Should I file an issue ?
>
>     Thanks,
>     Serkan
>
>
>
> -- 
>
> Piotr Zarzycki
>
> Patreon: _https://www.patreon.com/piotrzarzycki_
>


Re: menu is not initialized

Posted by Piotr Zarzycki <pi...@gmail.com>.
Hi Serkan,

Try provide to this menu dataProvider with XML instead declaring it in MXML
? Does it work ?

Thanks,
Piotr

sob., 2 lis 2019 o 13:08 Serkan Taş <se...@likyateknoloji.com>
napisał(a):

> Hi,
>
> I am using the below declaration for the initialization of menu :
>
>     <fx:Declarations>
>         <fx:XMLList id="menuDataXMLList">
>             <menuitem label="{resourceManager.getString('messages',
> 'configFiles')}" id="configfiles" role="{UserRole.OPERATION}">
>                 <menuitem label="label-1-1"/>
>                 <menuitem label="label-1-2"/>
>             </menuitem>
>         </fx:XMLList>
>         </fx:Declarations>
>
> Unfortunately it is not working. I guess the resource can not be retrieved
> this way, because when I change the code as below it is disğlayed as
> expected :
>
>
>     <fx:Declarations>
>         <fx:XMLList id="menuDataXMLList">
>             <menuitem label="label-1" id="configfiles">
>                 <menuitem label="label-1-1"/>
>                 <menuitem label="label-1-2"/>
>             </menuitem>
>         </fx:XMLList>
>       </fx:Declarations>
>
> Should I file an issue ?
>
> Thanks,
> Serkan
>


-- 

Piotr Zarzycki

Patreon: *https://www.patreon.com/piotrzarzycki
<https://www.patreon.com/piotrzarzycki>*