diff options
author | Amith Yamasani <yamasani@google.com> | 2009-06-03 15:45:40 -0700 |
---|---|---|
committer | Amith Yamasani <yamasani@google.com> | 2009-06-03 16:31:15 -0700 |
commit | 7f6aa6283ae759c5b013c142be036617cf79f725 (patch) | |
tree | cd5f60bdf8707632db5f070a16715b6b69e8976d /res/layout | |
parent | 110b75cde7ca21e83fb84cab70b7d11bdff54f2c (diff) | |
download | packages_apps_Settings-7f6aa6283ae759c5b013c142be036617cf79f725.zip packages_apps_Settings-7f6aa6283ae759c5b013c142be036617cf79f725.tar.gz packages_apps_Settings-7f6aa6283ae759c5b013c142be036617cf79f725.tar.bz2 |
Add detail page for Battery usage and track GPS and foreground CPU.
Show details such as Cpu time, Cpu foreground time, data sent/received,
and GPS usage.
Diffstat (limited to 'res/layout')
-rw-r--r-- | res/layout/power_usage_detail_item_text.xml | 43 | ||||
-rw-r--r-- | res/layout/power_usage_details.xml | 90 |
2 files changed, 133 insertions, 0 deletions
diff --git a/res/layout/power_usage_detail_item_text.xml b/res/layout/power_usage_detail_item_text.xml new file mode 100644 index 0000000..097469b --- /dev/null +++ b/res/layout/power_usage_detail_item_text.xml @@ -0,0 +1,43 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Copyright (C) 2009 The Android Open Source Project + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--> + +<RelativeLayout + xmlns:android="http://schemas.android.com/apk/res/android" + android:layout_width="fill_parent" + android:layout_height="wrap_content"> + <!--Label for the item--> + <TextView + android:id="@+id/label" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:textAppearance="?android:attr/textAppearanceMedium" + android:textStyle="bold" + android:singleLine="true" + android:layout_alignParentLeft="true" + android:layout_marginBottom="2dip" + android:layout_marginTop="2dip" /> + <TextView + android:id="@+id/value" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:layout_alignParentRight="true" + android:textAppearance="?android:attr/textAppearanceMedium" + android:textStyle="normal" + android:singleLine="true" + android:layout_marginBottom="2dip" + android:layout_marginTop="2dip" + android:layout_marginRight="4dip"/> +</RelativeLayout> diff --git a/res/layout/power_usage_details.xml b/res/layout/power_usage_details.xml new file mode 100644 index 0000000..dd8d486 --- /dev/null +++ b/res/layout/power_usage_details.xml @@ -0,0 +1,90 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Copyright (C) 2009 The Android Open Source Project + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--> + +<ScrollView + xmlns:android="http://schemas.android.com/apk/res/android" + android:layout_width="fill_parent" + android:layout_height="fill_parent"> + <LinearLayout + android:id="@+id/all_details" + android:layout_width="fill_parent" + android:layout_height="fill_parent" + android:paddingRight="6dip" + android:paddingTop="5dip" + android:paddingBottom="5dip" + android:orientation="vertical"> + + <!-- Details header - icon, label and percentage --> + <RelativeLayout + android:layout_width="fill_parent" + android:layout_height="wrap_content" + android:layout_gravity="center_vertical"> + + <LinearLayout + android:orientation="vertical" + android:layout_alignParentLeft="true" + android:layout_width="fill_parent" + android:layout_height="wrap_content" + android:paddingTop="6dip" + android:paddingBottom="6dip" + android:paddingRight="6dip" + android:paddingLeft="6dip" > + <!-- application name --> + <TextView android:id="@+id/name" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:textAppearance="?android:attr/textAppearanceMedium" + android:textStyle="bold" + android:singleLine="true" + android:ellipsize="marquee" + android:layout_marginBottom="2dip" /> + <!-- application version --> + <TextView android:id="@+id/battery_percentage" + android:layout_marginTop="-4dip" + android:layout_gravity="center_vertical" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:textAppearance="?android:attr/textAppearanceSmall" /> + </LinearLayout> + + <!-- application icon --> + <ImageView android:id="@+id/icon" + android:layout_width="@android:dimen/app_icon_size" + android:layout_height="@android:dimen/app_icon_size" + android:layout_alignParentRight="true" + android:paddingTop="6dip" + android:paddingBottom="6dip" + android:paddingRight="6dip" + android:scaleType="fitCenter" /> + </RelativeLayout> + + + <TextView + style="?android:attr/listSeparatorTextViewStyle" + android:text="@string/details_subtitle" /> + + <LinearLayout + android:id="@+id/details" + android:layout_width="fill_parent" + android:layout_height="wrap_content" + android:paddingLeft="6dip" + android:orientation="vertical"> + + <!-- Insert detail items here --> + + </LinearLayout> + </LinearLayout> +</ScrollView> |