Titanium JIRA Archive
Alloy (ALOY)

[ALOY-531] Alloy: add TabGroup inside SplitWindow is not working

GitHub Issuen/a
TypeBug
PriorityMedium
StatusClosed
ResolutionFixed
Resolution Date2013-03-14T21:34:39.000+0000
Affected Version/sAlloy 0.3.1
Fix Version/sAlloy 1.1.0, 2013 Sprint 06
ComponentsXML
Labelsn/a
ReporterCarter Lathrop
AssigneeTony Lukasavage
Created2013-02-20T23:44:55.000+0000
Updated2013-05-14T17:19:17.000+0000

Description

Steps to Reproduce

I just tried to add tabGroup inside SplitWindow but it doesnt seems to be working, just because TabGroup cannot be child of master/detailed window.

Actual Result

I see blank view

Expected Result

Expect TabGroup to be child of master/detailed window of splitView.

Test Case

<Alloy>
<!-- iPad -->
<SplitWindow id="index" formFactor="tablet" platform="ios">
<Window>
<TabGroup>
<!-- Explicit Window declaration -->
<Tab id="tab1">
<Window id="win1">
<Label>Label 1</Label>
<Label>Label 2</Label>
<Label platform="ios">Label 3</Label>
<Label>Label 4</Label>
<Label>Label 5</Label>
</Window>
</Tab>
</TabGroup>
</Window>
<Window>
<NavigationGroup id="navgroup">
<Require src="detail" id="detail"/>
</NavigationGroup>
</Window>
</SplitWindow>

</Alloy>

Attachments

FileDateSize
.log2013-02-20T23:44:57.000+0000753274
diagnostic1523076668199639099.log2013-02-20T23:45:05.000+00001233

Comments

  1. Carter Lathrop 2013-02-21

    Hello, Can you please provide a simple test case that shows this error so that I may more quickly determine if this is indeed a bug? Then I would be glad to pass it along to engineering. Thanks, Carter
  2. Andrey Buligin 2013-02-21

    Please use this snippet So issue here you will see empty window insted of tabbed one because as I reported : according to alloy permissions TabGroup cannot reside inside window, even though it could be done manually without alloy.
  3. Andrey Buligin 2013-02-21

    ALSO PLEASE REFER TO THIS ISSUE : http://developer.appcelerator.com/question/148562/alloy---add-tabgroup-inside-splitwindow#answer-257203
  4. Carter Lathrop 2013-02-21

    Thank you Andrey, I reopened the issue and moved to Ti-Mob.
  5. Tony Lukasavage 2013-02-21

    @Carter: from now on, Alloy-specific issues should be moved to the ALOY project, not TIMOB. Thanks.
  6. Carter Lathrop 2013-02-21

    Got it, sorry for the mixup.
  7. Tony Lukasavage 2013-03-14

    Basic syntax will look like this:
       <Alloy>
           <SplitWindow>
               <TabGroup id="master">
                   <Tab title="tab 1">
                       <Window title="tab 1"/>
                   </Tab>
               <TabGroup>
               <Window id="detail">
           </SplitWindow>
       </Alloy>
       
  8. Paras Mishra 2013-05-14

    Tried running the app using the following code.
       <Alloy>
           <SplitWindow>
               <Window>
               <TabGroup id="master">
                   <Tab title="tab 1">
                       <Window title="tab 1"/>
                   </Tab>
               <TabGroup>
               </Window>
               <Window id="detail">
               <Window>
           </SplitWindow>
       </Alloy>
       
    App runs with no error but tabgroup is not added to the window.
  9. Tony Lukasavage 2013-05-14

    [~pmishra] TabGroup is a top-level view, it should not be nested inside of a Window. Also, your XML was invalid since you didn't close your TabGroup or Window tags.
       <Alloy>
           <SplitWindow>
               <TabGroup id="master">
                   <Tab title="tab 1">
                       <Window title="tab 1"/>
                   </Tab>
               </TabGroup>
               <Window id="detail"/>
           </SplitWindow>
       </Alloy>
       
  10. Federico Casali 2013-05-14

    Verified as fixed and working as expected with: Alloy 1.1.2 GA and 1.1.3-alpha TiSDK 3.1.0 GA and 3.1.1.v20130513131554 CLI 3.1.0 Sample code:
        <Alloy>
            <SplitWindow>
                <TabGroup id="master">
                    <Tab title="tab 1">
                        <Window title="tab 1">
                        	<Label>This is Tab1/Window 1</Label>
                        </Window>
                    </Tab>
                    <Tab title="tab 2">
                        <Window title="tab 2">
                        	<View top="5" backgroundColor="red" width="30" height="30"></View>
                        </Window>
                    </Tab>
                    <Tab title="tab 3">
                        <Window title="tab 3"/>
                    </Tab>
                </TabGroup>
                <Window id="detail">
                	<View top='20' width="200" height="200" backgroundColor="blue"></View>
                </Window>
            </SplitWindow>
        </Alloy>
        
    Closing.

JSON Source