-
Notifications
You must be signed in to change notification settings - Fork 23
/
template.xml
executable file
·86 lines (55 loc) · 3.72 KB
/
template.xml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
<?xml version="1.0"?>
<template format="3" revision="1" name="MaterialTabsTemplate" minApi="7" minBuildApi="14" description="Creates a new Activity with Bottom or Top tabs">
<category value="Other"/>
<parameter id="activityClass" name="Activity Name" type="string" constraints="class|unique|nonempty" suggest="${layoutToActivity(layoutActivityName)}" default="RecyclerViewActivity" help="The name of the activity class to create"/>
<parameter id="layoutActivityName" name="Layout Name" type="string" constraints="layout|unique|nonempty" suggest="${activityToLayout(activityClass)}" default="activity_recycler_view" help="The name of the layout to create for the activity"/>
<parameter id="tabName1" name="Fragment Tab 1 Name" type="string" constraints="class|unique|nonempty" default="FirstFragment" help="The name of the first Tab 1"/>
<parameter id="tabName2" name="Fragment Tab 2 Name" type="string" constraints="class|unique|nonempty" default="SecondFragment" help="The name of the first Tab 2"/>
<parameter id="tabName3" name="Fragment Tab 3 Name" type="string" constraints="class|unique|nonempty" default="ThirdFragment" help="The name of the first Tab 3"/>
<parameter
id="tabLayoutName1"
name="Tab 1 Layout Name"
type="string"
constraints="layout|nonempty|unique"
default="fragment_first"
suggest="fragment_${classToResource(tabName1)}"
help="The name of the layout to create" />
<parameter
id="tabLayoutName2"
name="Tab 2 Layout Name"
type="string"
constraints="layout|nonempty|unique"
default="fragment_second"
suggest="fragment_${classToResource(tabName2)}"
help="The name of the layout to create" />
<parameter
id="tabLayoutName3"
name="Tab 3 Layout Name"
type="string"
constraints="layout|nonempty|unique"
default="fragment_third"
suggest="fragment_${classToResource(tabName3)}"
help="The name of the layout to create" />
<parameter id="activityTitle" name="Title" type="string" constraints="nonempty" default="TabActivity" suggest="${activityClass}" help="The name of the activity. For launcher activities, the application title."/>
<parameter id="isLauncher" name="Launcher Activity" type="boolean" default="false" help="If true, this activity will have a CATEGORY_LAUNCHER intent filter, making it visible in the launcher"/>
<parameter id="isToolbar" name="Need Toolbar" type="boolean" default="false" help="If true, this activity will have a Toolbar"/>
<parameter id="packageName" name="Package name" type="string" constraints="package" default="com.mycompany.myapp"/>
<parameter id="tabstyle" name="Tabs Style" type="enum" default="simple" help="Choose your own Tab style">
<option id="simple">Simple Tabs</option>
<option id="icons">Tabs with Icon</option>
<option id="iconswithtext">Tabs with Icon and Text</option>
<option id="badgewithicons">Tabs with Icon and Badge</option>
</parameter>
<parameter id="tabposition" name="Tabs Position" type="enum" default="top" help="Choose your own Tab Position">
<option id="top">Tabs on top</option>
<option id="bottom">Tabs on bottom</option>
</parameter>
<parameter id="isFragmentHistory" name="Need Fragment History stack like Instagram App?" type="boolean" default="false" visibility="(tabposition =='bottom')" help="If true, the Fragment history will be maintained like Instagram App"/>
<!-- 128x128 thumbnails relative to template.xml -->
<thumbs>
<!-- default thumbnail is required -->
<thumb>templates_adapter.png</thumb>
</thumbs>
<globals file="globals.xml.ftl"/>
<execute file="recipe.xml.ftl"/>
</template>