Loading res/layout/panel_slice_slider_row_large_icon.xml 0 → 100644 +31 −0 Original line number Diff line number Diff line <?xml version="1.0" encoding="utf-8"?> <!-- Copyright (C) 2020 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. --> <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:id="@+id/slice_slider_layout" android:layout_width="match_parent" android:layout_height="wrap_content" android:orientation="vertical"> <androidx.slice.widget.SliceView android:id="@+id/slice_view" style="@style/Widget.SliceView.Panel.Slider.LargeIcon" android:layout_width="match_parent" android:layout_height="wrap_content" android:paddingStart="0dp" android:paddingEnd="0dp"/> </LinearLayout> No newline at end of file res/values/styles.xml +9 −0 Original line number Diff line number Diff line Loading @@ -533,6 +533,10 @@ <item name="rowStyle">@style/SliceRow.Slider</item> </style> <style name="Widget.SliceView.Panel.Slider.LargeIcon"> <item name="rowStyle">@style/SliceRow.Slider.LargeIcon</item> </style> <style name="SliceRow"> <!-- 2dp start padding for the start icon --> <item name="titleItemStartPadding">2dp</item> Loading Loading @@ -580,6 +584,11 @@ <item name="progressBarEndPadding">16dp</item> </style> <style name="SliceRow.Slider.LargeIcon"> <!-- Layout is 48dp and actual icon size is 48-(iconSize/2) --> <item name="iconSize">12dp</item> </style> <style name="DisclaimerPositiveButton" parent="@style/SudGlifButton.Primary"> <item name="android:layout_margin">16dp</item> <item name="android:paddingStart">8dp</item> Loading src/com/android/settings/panel/MediaOutputGroupPanel.java +1 −1 Original line number Diff line number Diff line Loading @@ -159,6 +159,6 @@ public class MediaOutputGroupPanel implements PanelContent, LocalMediaManager.De @Override public int getViewType() { return PanelContent.VIEW_TYPE_SLIDER; return PanelContent.VIEW_TYPE_SLIDER_LARGE_ICON; } } src/com/android/settings/panel/MediaOutputPanel.java +1 −1 Original line number Diff line number Diff line Loading @@ -246,7 +246,7 @@ public class MediaOutputPanel implements PanelContent, LocalMediaManager.DeviceC @Override public int getViewType() { return PanelContent.VIEW_TYPE_SLIDER; return PanelContent.VIEW_TYPE_SLIDER_LARGE_ICON; } private final MediaController.Callback mCb = new MediaController.Callback() { Loading src/com/android/settings/panel/PanelContent.java +1 −0 Original line number Diff line number Diff line Loading @@ -31,6 +31,7 @@ import java.util.List; public interface PanelContent extends Instrumentable { int VIEW_TYPE_SLIDER = 1; int VIEW_TYPE_SLIDER_LARGE_ICON = 2; /** * @return a icon for the title of the Panel. Loading Loading
res/layout/panel_slice_slider_row_large_icon.xml 0 → 100644 +31 −0 Original line number Diff line number Diff line <?xml version="1.0" encoding="utf-8"?> <!-- Copyright (C) 2020 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. --> <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:id="@+id/slice_slider_layout" android:layout_width="match_parent" android:layout_height="wrap_content" android:orientation="vertical"> <androidx.slice.widget.SliceView android:id="@+id/slice_view" style="@style/Widget.SliceView.Panel.Slider.LargeIcon" android:layout_width="match_parent" android:layout_height="wrap_content" android:paddingStart="0dp" android:paddingEnd="0dp"/> </LinearLayout> No newline at end of file
res/values/styles.xml +9 −0 Original line number Diff line number Diff line Loading @@ -533,6 +533,10 @@ <item name="rowStyle">@style/SliceRow.Slider</item> </style> <style name="Widget.SliceView.Panel.Slider.LargeIcon"> <item name="rowStyle">@style/SliceRow.Slider.LargeIcon</item> </style> <style name="SliceRow"> <!-- 2dp start padding for the start icon --> <item name="titleItemStartPadding">2dp</item> Loading Loading @@ -580,6 +584,11 @@ <item name="progressBarEndPadding">16dp</item> </style> <style name="SliceRow.Slider.LargeIcon"> <!-- Layout is 48dp and actual icon size is 48-(iconSize/2) --> <item name="iconSize">12dp</item> </style> <style name="DisclaimerPositiveButton" parent="@style/SudGlifButton.Primary"> <item name="android:layout_margin">16dp</item> <item name="android:paddingStart">8dp</item> Loading
src/com/android/settings/panel/MediaOutputGroupPanel.java +1 −1 Original line number Diff line number Diff line Loading @@ -159,6 +159,6 @@ public class MediaOutputGroupPanel implements PanelContent, LocalMediaManager.De @Override public int getViewType() { return PanelContent.VIEW_TYPE_SLIDER; return PanelContent.VIEW_TYPE_SLIDER_LARGE_ICON; } }
src/com/android/settings/panel/MediaOutputPanel.java +1 −1 Original line number Diff line number Diff line Loading @@ -246,7 +246,7 @@ public class MediaOutputPanel implements PanelContent, LocalMediaManager.DeviceC @Override public int getViewType() { return PanelContent.VIEW_TYPE_SLIDER; return PanelContent.VIEW_TYPE_SLIDER_LARGE_ICON; } private final MediaController.Callback mCb = new MediaController.Callback() { Loading
src/com/android/settings/panel/PanelContent.java +1 −0 Original line number Diff line number Diff line Loading @@ -31,6 +31,7 @@ import java.util.List; public interface PanelContent extends Instrumentable { int VIEW_TYPE_SLIDER = 1; int VIEW_TYPE_SLIDER_LARGE_ICON = 2; /** * @return a icon for the title of the Panel. Loading