Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 8600534d authored by John Spurlock's avatar John Spurlock
Browse files

VolumeZen: combine ringer/notification volume and zen.

- Implement a new volume panel widget, combining volume and
  zen mode + conditions.
- Show zen mode + conditions when modifying ringer or notification
  streams.
- Host the volume panel widget in a dialog when being controlled
  by the audio service / volume keys.
- Remove support for multiple sliders in the volume panel.
- Remove support for separate ringer + notification volumes
  in the volume panel.
- Move volume panel resources up to SystemUI.
- Create a new combined Notifications quick settings tile.
- Host the volume panel widget in the quick settings panel under
  Notifications.
- When the quick settings detail panel is visible, route the volume
  keys to the embedded widget instead of showing a redundant dialog.
- Create common styles for quick settings text to be closer to spec.
- Update the framework resources for the ringer stream.
- Show the ringer icons in global actions.
- Add "until you turn this off" back as a separate zen condition.
- Disable time condition buttons when they are N/A.
- Don't allow volume changes to set ringer mode silent.

Bug:15186070
Change-Id: Id5e321dd1d5e7c4cf3917027ffbdf7e80d38b00d
parent 41b170d6
Loading
Loading
Loading
Loading
+25 −20
Original line number Diff line number Diff line
<?xml version="1.0" encoding="utf-8"?>
<!--
/*
 * Copyright 2013, 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.
 */
Copyright (C) 2014 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.
-->
<vector xmlns:android="http://schemas.android.com/apk/res/android" >
    <size
        android:width="32dp"
        android:height="32dp"/>

    <viewport
        android:viewportWidth="24.0"
        android:viewportHeight="24.0"/>

<bitmap xmlns:android="http://schemas.android.com/apk/res/android"
    android:src="@drawable/ic_audio_ring_notif_am_alpha"
    android:autoMirrored="true"
    android:tint="?attr/colorControlNormal" />
    <path
        android:fill="#8A000000"
        android:pathData="M11.5,22.0c1.1,0.0 2.0,-0.9 2.0,-2.0l-4.0,0.0C9.5,21.1 10.4,22.0 11.5,22.0zM18.0,16.0l0.0,-5.5c0.0,-3.1 -2.1,-5.6 -5.0,-6.3L13.0,3.5C13.0,2.7 12.3,2.0 11.5,2.0C10.7,2.0 10.0,2.7 10.0,3.5l0.0,0.7c-2.9,0.7 -5.0,3.2 -5.0,6.3L5.0,16.0l-2.0,2.0l0.0,1.0l17.0,0.0l0.0,-1.0L18.0,16.0z"/>
</vector>
+25 −20
Original line number Diff line number Diff line
<?xml version="1.0" encoding="utf-8"?>
<!--
/*
 * Copyright 2013, 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.
 */
Copyright (C) 2014 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.
-->
<vector xmlns:android="http://schemas.android.com/apk/res/android" >
    <size
        android:width="32dp"
        android:height="32dp"/>

    <viewport
        android:viewportWidth="24.0"
        android:viewportHeight="24.0"/>

<bitmap xmlns:android="http://schemas.android.com/apk/res/android"
    android:src="@drawable/ic_audio_ring_notif_mute_am_alpha"
    android:autoMirrored="true"
    android:tint="?attr/colorControlNormal" />
    <path
        android:fill="#8A000000"
        android:pathData="M11.5,22.0c1.1,0.0 2.0,-0.9 2.0,-2.0l-4.0,0.0C9.5,21.1 10.4,22.0 11.5,22.0zM18.0,10.5c0.0,-3.1 -2.1,-5.6 -5.0,-6.3L13.0,3.5C13.0,2.7 12.3,2.0 11.5,2.0C10.7,2.0 10.0,2.7 10.0,3.5l0.0,0.7C9.5,4.3 9.0,4.5 8.6,4.7l9.4,9.4L18.0,10.5zM17.7,19.0l2.0,2.0l1.3,-1.3L4.3,3.0L3.0,4.3l2.9,2.9C5.3,8.2 5.0,9.3 5.0,10.5L5.0,16.0l-2.0,2.0l0.0,1.0L17.7,19.0z" />
</vector>
+25 −20
Original line number Diff line number Diff line
<?xml version="1.0" encoding="utf-8"?>
<!--
/*
 * Copyright 2013, 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.
 */
Copyright (C) 2014 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.
-->
<vector xmlns:android="http://schemas.android.com/apk/res/android" >
    <size
        android:width="32dp"
        android:height="32dp"/>

    <viewport
        android:viewportWidth="24.0"
        android:viewportHeight="24.0"/>

<bitmap xmlns:android="http://schemas.android.com/apk/res/android"
    android:src="@drawable/ic_audio_ring_notif_vibrate_am_alpha"
    android:autoMirrored="true"
    android:tint="?attr/colorControlNormal" />
    <path
        android:fill="#8A000000"
        android:pathData="M0.0,15.0l2.0,0.0L2.0,9.0L0.0,9.0L0.0,15.0zM3.0,17.0l2.0,0.0L5.0,7.0L3.0,7.0L3.0,17.0zM22.0,9.0l0.0,6.0l2.0,0.0L24.0,9.0L22.0,9.0zM19.0,17.0l2.0,0.0L21.0,7.0l-2.0,0.0L19.0,17.0zM16.5,3.0l-9.0,0.0C6.7,3.0 6.0,3.7 6.0,4.5l0.0,15.0C6.0,20.3 6.7,21.0 7.5,21.0l9.0,0.0c0.8,0.0 1.5,-0.7 1.5,-1.5l0.0,-15.0C18.0,3.7 17.3,3.0 16.5,3.0zM16.0,19.0L8.0,19.0L8.0,5.0l8.0,0.0L16.0,19.0z"/>
</vector>
+2 −2
Original line number Diff line number Diff line
@@ -37,7 +37,7 @@
            android:layout_marginEnd="8dp"
            android:layout_marginTop="6dp"
            android:layout_marginBottom="6dp"
            android:src="@drawable/ic_audio_vol_mute"
            android:src="@drawable/ic_audio_ring_notif_mute"
            android:scaleType="center"
            android:duplicateParentState="true"
            android:background="@drawable/silent_mode_indicator"
@@ -94,7 +94,7 @@
            android:layout_marginEnd="8dp"
            android:layout_marginTop="6dp"
            android:layout_marginBottom="6dp"
            android:src="@drawable/ic_audio_vol"
            android:src="@drawable/ic_audio_ring_notif"
            android:scaleType="center"
            android:duplicateParentState="true"
            android:background="@drawable/silent_mode_indicator"
+0 −3
Original line number Diff line number Diff line
@@ -206,9 +206,6 @@
    <!-- Default width for a textview error popup -->
    <dimen name="textview_error_popup_default_width">240dip</dimen>

    <!-- Volume panel y offset -->
    <dimen name="volume_panel_top">16dp</dimen>

    <!-- Default padding to apply to AppWidgetHostViews containing widgets targeting API level 14 and up. -->
    <dimen name="default_app_widget_padding_left">8dp</dimen>
    <dimen name="default_app_widget_padding_top">8dp</dimen>
Loading