• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1<?xml version="1.0" encoding="utf-8"?>
2
3<!--
4/*
5 * Copyright (C) 2008, The Android Open Source Project
6 *
7 * Licensed under the Apache License, Version 2.0 (the "License");
8 * you may not use this file except in compliance with the License.
9 * You may obtain a copy of the License at
10 *
11 *     http://www.apache.org/licenses/LICENSE-2.0
12 *
13 * Unless required by applicable law or agreed to in writing, software
14 * distributed under the License is distributed on an "AS IS" BASIS,
15 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16 * See the License for the specific language governing permissions and
17 * limitations under the License.
18 */
19-->
20
21<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
22              android:orientation="vertical"
23              android:layout_width="fill_parent"
24              android:layout_height="fill_parent"
25              android:background="#ff000000">
26    <LinearLayout
27         android:layout_width="fill_parent"
28         android:layout_height="0dp"
29         android:layout_weight="2"
30         >
31
32            <com.android.calculator2.CalculatorDisplay
33                 android:id="@+id/display"
34                 android:layout_width="0dp"
35                 android:layout_weight="5"
36                 android:layout_height="fill_parent"
37                 >
38
39                <EditText style="@style/display_style" />
40                <EditText style="@style/display_style" />
41
42            </com.android.calculator2.CalculatorDisplay>
43
44        <com.android.calculator2.ColorButton
45             android:id="@+id/del"
46             android:text="@string/clear"
47             android:layout_width="0dp"
48             android:layout_weight="1"
49             android:layout_height="fill_parent"
50             android:textColor="#ffffffff"
51             android:layout_marginRight="0dp"
52             android:textSize="15dp"
53             style="@style/button_style"
54             />
55    </LinearLayout>
56
57    <com.android.calculator2.PanelSwitcher
58         android:id="@+id/panelswitch"
59         android:layout_width="fill_parent"
60         android:layout_height="0dp"
61         android:layout_weight="5"
62         >
63
64    <LinearLayout
65         android:id="@+id/simplePad"
66         android:layout_width="fill_parent"
67         android:layout_height="fill_parent"
68         android:orientation="vertical"
69         android:layout_gravity="center"
70         >
71        <LinearLayout
72             android:layout_weight="1"
73             android:layout_width="fill_parent"
74             android:layout_height="0dp"
75             >
76            <com.android.calculator2.ColorButton
77                android:id="@+id/digit7"
78                android:text="@string/digit7"
79                style="@style/digit_button_style"
80                />
81            <com.android.calculator2.ColorButton
82                android:id="@+id/digit8"
83                android:text="@string/digit8"
84                style="@style/digit_button_style"
85                />
86            <com.android.calculator2.ColorButton
87                android:id="@+id/digit9"
88                android:text="@string/digit9"
89                style="@style/digit_button_style"
90                />
91            <com.android.calculator2.ColorButton
92                android:id="@+id/leftParen"
93                android:text="@string/leftParen"
94                style="@style/button_style"
95                />
96            <com.android.calculator2.ColorButton
97                android:id="@+id/rightParen"
98                android:text="@string/rightParen"
99                style="@style/button_style"
100                />
101            <com.android.calculator2.ColorButton
102                android:id="@+id/mul"
103                android:text="@string/mul"
104                style="@style/button_style"
105                />
106        </LinearLayout>
107
108        <LinearLayout
109             android:layout_weight="1"
110             android:layout_width="fill_parent"
111             android:layout_height="0dp"
112             >
113            <com.android.calculator2.ColorButton
114                android:id="@+id/digit4"
115                android:text="@string/digit4"
116                style="@style/digit_button_style"
117                />
118            <com.android.calculator2.ColorButton
119                android:id="@+id/digit5"
120                android:text="@string/digit5"
121                style="@style/digit_button_style"
122                />
123            <com.android.calculator2.ColorButton
124                android:id="@+id/digit6"
125                android:text="@string/digit6"
126                style="@style/digit_button_style"
127                />
128            <com.android.calculator2.ColorButton
129                android:id="@+id/dot"
130                android:text="@string/dot"
131                style="@style/digit_button_style"
132                />
133            <com.android.calculator2.ColorButton
134                android:id="@+id/div"
135                android:text="@string/div"
136                style="@style/button_style"
137                />
138            <com.android.calculator2.ColorButton
139                android:id="@+id/minus"
140                android:text="@string/minus"
141                style="@style/button_style"
142                />
143        </LinearLayout>
144
145        <LinearLayout
146             android:layout_weight="1"
147             android:layout_width="fill_parent"
148             android:layout_height="0dp"
149             >
150            <com.android.calculator2.ColorButton
151                android:id="@+id/digit1"
152                android:text="@string/digit1"
153                style="@style/digit_button_style"
154                />
155            <com.android.calculator2.ColorButton
156                android:id="@+id/digit2"
157                android:text="@string/digit2"
158                style="@style/digit_button_style"
159                />
160            <com.android.calculator2.ColorButton
161                android:id="@+id/digit3"
162                android:text="@string/digit3"
163                style="@style/digit_button_style"
164                />
165            <com.android.calculator2.ColorButton
166                android:id="@+id/digit0"
167                android:text="@string/digit0"
168                style="@style/digit_button_style"
169                />
170            <com.android.calculator2.ColorButton
171                android:id="@+id/equal"
172                android:text="@string/equal"
173                style="@style/button_style"
174                />
175            <com.android.calculator2.ColorButton
176                android:id="@+id/plus"
177                android:text="@string/plus"
178                style="@style/button_style"
179                />
180        </LinearLayout>
181    </LinearLayout>
182
183    <LinearLayout
184         android:id="@+id/advancedPad"
185         android:layout_width="fill_parent"
186         android:layout_height="fill_parent"
187         android:layout_weight="1"
188         android:orientation="vertical"
189         android:layout_gravity="center"
190         android:layout_marginTop="5dp"
191         android:layout_marginBottom="0dp"
192         >
193
194        <LinearLayout
195            android:layout_weight="1"
196            android:layout_width="fill_parent"
197            android:layout_height="0dp"
198            >
199            <com.android.calculator2.ColorButton
200                android:id="@+id/sin"
201                android:text="@string/sin"
202                style="@style/button_small_style"
203                />
204            <com.android.calculator2.ColorButton
205                android:id="@+id/cos"
206                android:text="@string/cos"
207                style="@style/button_small_style"
208                />
209            <com.android.calculator2.ColorButton
210                android:id="@+id/tan"
211                android:text="@string/tan"
212                style="@style/button_small_style"
213                />
214            <com.android.calculator2.ColorButton
215                android:id="@+id/pi"
216                android:text="@string/pi"
217                style="@style/button_style"
218                />
219            <com.android.calculator2.ColorButton
220                android:id="@+id/factorial"
221                android:text="@string/factorial"
222                style="@style/button_style"
223                />
224        </LinearLayout>
225
226        <LinearLayout
227            android:layout_weight="1"
228            android:layout_width="fill_parent"
229            android:layout_height="0dp"
230            >
231            <com.android.calculator2.ColorButton
232                android:id="@+id/ln"
233                android:text="@string/ln"
234                style="@style/button_small_style"
235                />
236            <com.android.calculator2.ColorButton
237                android:id="@+id/lg"
238                android:text="@string/lg"
239                style="@style/button_small_style"
240                />
241            <com.android.calculator2.ColorButton
242                android:id="@+id/e"
243                android:text="@string/e"
244                style="@style/button_style"
245                />
246            <com.android.calculator2.ColorButton
247                android:id="@+id/power"
248                android:text="@string/power"
249                style="@style/button_style"
250                />
251            <com.android.calculator2.ColorButton
252                android:id="@+id/sqrt"
253                android:text="@string/sqrt"
254                style="@style/button_style"
255                />
256        </LinearLayout>
257    </LinearLayout>
258    </com.android.calculator2.PanelSwitcher>
259</LinearLayout>
260