Add BatteryMeterView in Settings
1. Show gauge icon at the top of battery main page instead of battery usage graph. 2. Move the click action from battery usage graph to gauge icon. Bug: 34387464 Test: RunSettingsRoboTest Change-Id: Ib182619d6805b401cde03a50e2ae907cf4df7b94
This commit is contained in:
@@ -59,7 +59,6 @@ public class LayoutPreference extends Preference {
|
||||
|
||||
private void setView(View view) {
|
||||
setLayoutResource(R.layout.layout_preference_frame);
|
||||
setSelectable(false);
|
||||
final ViewGroup allDetails = (ViewGroup) view.findViewById(R.id.all_details);
|
||||
if (allDetails != null) {
|
||||
Utils.forceCustomPadding(allDetails, true /* additive padding */);
|
||||
@@ -70,6 +69,7 @@ public class LayoutPreference extends Preference {
|
||||
|
||||
@Override
|
||||
public void onBindViewHolder(PreferenceViewHolder view) {
|
||||
super.onBindViewHolder(view);
|
||||
FrameLayout layout = (FrameLayout) view.itemView;
|
||||
layout.removeAllViews();
|
||||
ViewGroup parent = (ViewGroup) mRootView.getParent();
|
||||
|
||||
Reference in New Issue
Block a user