Merging from ub-launcher3-rvc-dev @ build 6469858 am: fe68c9eec1 am: dab51b766e

Change-Id: Ibd7f08f52c846c218f85d5fa157de4249592231b
This commit is contained in:
James O'Leary
2020-05-08 16:41:56 +00:00
committed by Automerger Merge Worker
151 changed files with 5740 additions and 1493 deletions
-1
View File
@@ -156,7 +156,6 @@
<provider
android:name="com.android.launcher3.graphics.GridOptionsProvider"
android:authorities="${packageName}.grid_control"
android:enabled="false"
android:exported="true" />
<!--
+26 -18
View File
@@ -23,7 +23,7 @@ option java_outer_classname = "LauncherAtom";
message ItemInfo {
oneof Item {
Application application = 1;
Task task= 2;
Task task = 2;
Shortcut shortcut = 3;
Widget widget = 4;
}
@@ -34,13 +34,23 @@ message ItemInfo {
optional bool is_work = 6;
// Item can be child node to parent container or parent containers (nested)
oneof Container {
WorkspaceContainer workspace = 7;
HotseatContainer hotseat = 8;
FolderContainer folder = 9;
}
optional ContainerInfo container_info = 7;
// Stores the origin of the Item
optional Origin source = 10;
optional Origin source = 8;
}
// Represents various launcher surface where items are placed.
message ContainerInfo {
oneof Container {
WorkspaceContainer workspace = 1;
HotseatContainer hotseat = 2;
FolderContainer folder = 3;
AllAppsContainer all_apps_container = 4;
}
}
message AllAppsContainer {
}
enum Origin {
@@ -68,8 +78,8 @@ message Shortcut {
// AppWidgets handled by AppWidgetManager
message Widget {
optional int32 span_x = 1;
optional int32 span_y = 2;
optional int32 span_x = 1 [default = 1];
optional int32 span_y = 2 [default = 1];
optional int32 app_widget_id = 3;
optional string package_name = 4; // only populated during snapshot if from workspace
optional string component_name = 5; // only populated during snapshot if from workspace
@@ -86,9 +96,9 @@ message Task {
// Containers
message WorkspaceContainer {
optional int32 page_index = 1; // range [-1, l], 0 is the index of the main homescreen
optional int32 grid_x = 2; // [0, m], m varies based on the display density and resolution
optional int32 grid_y = 3; // [0, n], n varies based on the display density and resolution
optional int32 page_index = 1 [default = -2]; // range [-1, l], 0 is the index of the main homescreen
optional int32 grid_x = 2 [default = -1]; // [0, m], m varies based on the display density and resolution
optional int32 grid_y = 3 [default = -1]; // [0, n], n varies based on the display density and resolution
}
message HotseatContainer {
@@ -96,13 +106,11 @@ message HotseatContainer {
}
message FolderContainer {
optional int32 page_index = 1;
optional int32 grid_x = 2;
optional int32 grid_y = 3;
oneof Container {
optional int32 page_index = 1 [default = -1];
optional int32 grid_x = 2 [default = -1];
optional int32 grid_y = 3 [default = -1];
oneof ParentContainer {
WorkspaceContainer workspace = 4;
HotseatContainer hotseat = 5;
}
}
@@ -49,7 +49,6 @@ import com.android.launcher3.anim.AnimatorPlaybackController;
import com.android.launcher3.anim.Interpolators;
import com.android.launcher3.anim.SpringAnimationBuilder;
import com.android.launcher3.states.StateAnimationConfig;
import com.android.quickstep.util.AppWindowAnimationHelper;
import com.android.quickstep.views.RecentsView;
import com.android.quickstep.views.TaskView;
import com.android.systemui.shared.system.RemoteAnimationTargetCompat;
@@ -86,11 +85,8 @@ public final class LauncherAppTransitionManagerImpl extends QuickstepAppTransiti
boolean skipLauncherChanges = !launcherClosing;
TaskView taskView = findTaskViewToLaunch(mLauncher, v, appTargets);
AppWindowAnimationHelper helper =
new AppWindowAnimationHelper(recentsView.getPagedViewOrientedState(), mLauncher);
Animator recentsAnimator = getRecentsWindowAnimator(taskView, skipLauncherChanges,
appTargets, wallpaperTargets, mLauncher.getDepthController(), helper);
appTargets, wallpaperTargets, mLauncher.getDepthController());
anim.play(recentsAnimator.setDuration(RECENTS_LAUNCH_DURATION));
Animator childStateAnimation = null;
@@ -98,7 +94,7 @@ public final class LauncherAppTransitionManagerImpl extends QuickstepAppTransiti
Animator launcherAnim;
final AnimatorListenerAdapter windowAnimEndListener;
if (launcherClosing) {
launcherAnim = recentsView.createAdjacentPageAnimForTaskLaunch(taskView, helper);
launcherAnim = recentsView.createAdjacentPageAnimForTaskLaunch(taskView);
launcherAnim.setInterpolator(Interpolators.TOUCH_RESPONSE_INTERPOLATOR);
launcherAnim.setDuration(RECENTS_LAUNCH_DURATION);
@@ -151,6 +147,7 @@ public final class LauncherAppTransitionManagerImpl extends QuickstepAppTransiti
return () -> {
overview.setFreezeViewVisibility(false);
overview.setTranslationY(0);
mLauncher.getStateManager().reapplyState();
};
}
@@ -43,6 +43,7 @@ import com.android.launcher3.DropTarget;
import com.android.launcher3.Hotseat;
import com.android.launcher3.InvariantDeviceProfile;
import com.android.launcher3.Launcher;
import com.android.launcher3.LauncherAppState;
import com.android.launcher3.LauncherSettings;
import com.android.launcher3.LauncherState;
import com.android.launcher3.R;
@@ -56,6 +57,7 @@ import com.android.launcher3.dragndrop.DragController;
import com.android.launcher3.dragndrop.DragOptions;
import com.android.launcher3.icons.IconCache;
import com.android.launcher3.logging.FileLog;
import com.android.launcher3.model.PredictionModel;
import com.android.launcher3.model.data.AppInfo;
import com.android.launcher3.model.data.FolderInfo;
import com.android.launcher3.model.data.ItemInfo;
@@ -69,6 +71,7 @@ import com.android.launcher3.uioverrides.PredictedAppIcon;
import com.android.launcher3.uioverrides.QuickstepLauncher;
import com.android.launcher3.userevent.nano.LauncherLogProto;
import com.android.launcher3.util.ComponentKey;
import com.android.launcher3.util.IntArray;
import java.lang.ref.WeakReference;
import java.util.ArrayList;
@@ -93,8 +96,6 @@ public class HotseatPredictionController implements DragController.DragListener,
//TODO: replace this with AppTargetEvent.ACTION_UNPIN (b/144119543)
private static final int APPTARGET_ACTION_UNPIN = 4;
private static final String PREDICTED_ITEMS_CACHE_KEY = "predicted_item_keys";
private static final String APP_LOCATION_HOTSEAT = "hotseat";
private static final String APP_LOCATION_WORKSPACE = "workspace";
@@ -115,11 +116,13 @@ public class HotseatPredictionController implements DragController.DragListener,
private DynamicItemCache mDynamicItemCache;
private final PredictionModel mPredictionModel;
private AppPredictor mAppPredictor;
private AllAppsStore mAllAppsStore;
private AnimatorSet mIconRemoveAnimators;
private boolean mUIUpdatePaused = false;
private boolean mRequiresCacheUpdate = false;
private boolean mRequiresCacheUpdate = true;
private boolean mIsCacheEmpty;
private HotseatEduController mHotseatEduController;
@@ -138,15 +141,16 @@ public class HotseatPredictionController implements DragController.DragListener,
mLauncher = launcher;
mHotseat = launcher.getHotseat();
mAllAppsStore = mLauncher.getAppsView().getAppsStore();
mPredictionModel = LauncherAppState.INSTANCE.get(launcher).getPredictionModel();
mAllAppsStore.addUpdateListener(this);
mDynamicItemCache = new DynamicItemCache(mLauncher, this::fillGapsWithPrediction);
mHotSeatItemsCount = mLauncher.getDeviceProfile().inv.numHotseatIcons;
launcher.getDeviceProfile().inv.addOnChangeListener(this);
mHotseat.addOnAttachStateChangeListener(this);
mIsCacheEmpty = mPredictionModel.getPredictionComponentKeys().isEmpty();
if (mHotseat.isAttachedToWindow()) {
onViewAttachedToWindow(mHotseat);
}
showCachedItems();
}
/**
@@ -185,6 +189,11 @@ public class HotseatPredictionController implements DragController.DragListener,
return;
}
List<WorkspaceItemInfo> predictedApps = mapToWorkspaceItemInfo(mComponentKeyMappers);
if (mComponentKeyMappers.isEmpty() != predictedApps.isEmpty()) {
// Safely ignore update as AppsList is not ready yet. This will called again once
// apps are ready (HotseatPredictionController#onAppsUpdated)
return;
}
int predictionIndex = 0;
ArrayList<WorkspaceItemInfo> newItems = new ArrayList<>();
// make sure predicted icon removal and filling predictions don't step on each other
@@ -305,14 +314,23 @@ public class HotseatPredictionController implements DragController.DragListener,
mAppPredictor.requestPredictionUpdate();
}
private void showCachedItems() {
ArrayList<ComponentKey> componentKeys = getCachedComponentKeys();
/**
* Create WorkspaceItemInfo objects and binds PredictedAppIcon views for cached predicted items.
*/
public void showCachedItems(List<AppInfo> apps, IntArray ranks) {
int count = Math.min(ranks.size(), apps.size());
List<WorkspaceItemInfo> items = new ArrayList<>(count);
for (int i = 0; i < count; i++) {
WorkspaceItemInfo item = new WorkspaceItemInfo(apps.get(i));
preparePredictionInfo(item, ranks.get(i));
items.add(item);
}
mComponentKeyMappers.clear();
for (ComponentKey key : componentKeys) {
for (ComponentKey key : mPredictionModel.getPredictionComponentKeys()) {
mComponentKeyMappers.add(new ComponentKeyMapper(key, mDynamicItemCache));
}
updateDependencies();
fillGapsWithPrediction();
bindItems(items, false, null);
}
private Bundle getAppPredictionContextExtra() {
@@ -390,41 +408,20 @@ public class HotseatPredictionController implements DragController.DragListener,
predictionLog.append("]");
if (Utilities.IS_DEBUG_DEVICE) FileLog.d(TAG, predictionLog.toString());
updateDependencies();
fillGapsWithPrediction();
fillGapsWithPrediction();
if (!isEduSeen() && mHotseatEduController != null) {
mHotseatEduController.setPredictedApps(mapToWorkspaceItemInfo(mComponentKeyMappers));
}
// should invalidate cache if AiAi sends empty list of AppTargets
if (appTargets.isEmpty()) {
mRequiresCacheUpdate = true;
}
cachePredictionComponentKeys(componentKeys);
cachePredictionComponentKeysIfNecessary(componentKeys);
}
private void cachePredictionComponentKeys(ArrayList<ComponentKey> componentKeys) {
if (!mRequiresCacheUpdate) return;
StringBuilder builder = new StringBuilder();
for (ComponentKey componentKey : componentKeys) {
builder.append(componentKey);
builder.append("\n");
}
mLauncher.getDevicePrefs().edit().putString(PREDICTED_ITEMS_CACHE_KEY,
builder.toString()).apply();
private void cachePredictionComponentKeysIfNecessary(ArrayList<ComponentKey> componentKeys) {
if (!mRequiresCacheUpdate && componentKeys.isEmpty() == mIsCacheEmpty) return;
mPredictionModel.cachePredictionComponentKeys(componentKeys);
mIsCacheEmpty = componentKeys.isEmpty();
mRequiresCacheUpdate = false;
}
private ArrayList<ComponentKey> getCachedComponentKeys() {
String cachedBlob = mLauncher.getDevicePrefs().getString(PREDICTED_ITEMS_CACHE_KEY, "");
ArrayList<ComponentKey> results = new ArrayList<>();
for (String line : cachedBlob.split("\n")) {
ComponentKey key = ComponentKey.fromString(line);
if (key != null) {
results.add(key);
}
}
return results;
}
private void updateDependencies() {
mDynamicItemCache.updateDependencies(mComponentKeyMappers, mAllAppsStore, this,
mHotSeatItemsCount);
@@ -15,8 +15,16 @@
*/
package com.android.launcher3.uioverrides;
import static android.view.accessibility.AccessibilityEvent.TYPE_VIEW_FOCUSED;
import static com.android.launcher3.LauncherState.NORMAL;
import static com.android.launcher3.LauncherState.OVERVIEW;
import static com.android.launcher3.LauncherState.OVERVIEW_MODAL_TASK;
import static com.android.launcher3.compat.AccessibilityManagerCompat.sendCustomAccessibilityEvent;
import static com.android.launcher3.testing.TestProtocol.HINT_STATE_ORDINAL;
import static com.android.launcher3.testing.TestProtocol.OVERVIEW_STATE_ORDINAL;
import static com.android.launcher3.testing.TestProtocol.QUICK_SWITCH_STATE_ORDINAL;
import static com.android.launcher3.util.Executors.MAIN_EXECUTOR;
import static com.android.quickstep.SysUINavigationMode.Mode.NO_BUTTON;
import android.content.Intent;
@@ -30,10 +38,13 @@ import com.android.launcher3.BaseQuickstepLauncher;
import com.android.launcher3.DeviceProfile;
import com.android.launcher3.Launcher;
import com.android.launcher3.LauncherState;
import com.android.launcher3.Workspace;
import com.android.launcher3.allapps.DiscoveryBounce;
import com.android.launcher3.anim.AnimatorPlaybackController;
import com.android.launcher3.config.FeatureFlags;
import com.android.launcher3.folder.Folder;
import com.android.launcher3.hybridhotseat.HotseatPredictionController;
import com.android.launcher3.model.data.AppInfo;
import com.android.launcher3.model.data.ItemInfo;
import com.android.launcher3.model.data.WorkspaceItemInfo;
import com.android.launcher3.popup.SystemShortcut;
@@ -48,6 +59,7 @@ import com.android.launcher3.uioverrides.touchcontrollers.QuickSwitchTouchContro
import com.android.launcher3.uioverrides.touchcontrollers.StatusBarTouchController;
import com.android.launcher3.uioverrides.touchcontrollers.TaskViewTouchController;
import com.android.launcher3.uioverrides.touchcontrollers.TransposedQuickSwitchTouchController;
import com.android.launcher3.util.IntArray;
import com.android.launcher3.util.TouchController;
import com.android.launcher3.util.UiThreadHelper;
import com.android.launcher3.util.UiThreadHelper.AsyncCommand;
@@ -56,8 +68,12 @@ import com.android.quickstep.SysUINavigationMode;
import com.android.quickstep.SysUINavigationMode.Mode;
import com.android.quickstep.SystemUiProxy;
import com.android.quickstep.views.RecentsView;
import com.android.quickstep.views.TaskView;
import java.io.FileDescriptor;
import java.io.PrintWriter;
import java.util.ArrayList;
import java.util.List;
import java.util.stream.Stream;
public class QuickstepLauncher extends BaseQuickstepLauncher {
@@ -165,6 +181,14 @@ public class QuickstepLauncher extends BaseQuickstepLauncher {
}
}
@Override
public void bindPredictedItems(List<AppInfo> appInfos, IntArray ranks) {
super.bindPredictedItems(appInfos, ranks);
if (mHotseatPredictionController != null) {
mHotseatPredictionController.showCachedItems(appInfos, ranks);
}
}
@Override
public void onDestroy() {
super.onDestroy();
@@ -174,6 +198,49 @@ public class QuickstepLauncher extends BaseQuickstepLauncher {
}
}
@Override
public void onStateSetEnd(LauncherState state) {
super.onStateSetEnd(state);
switch (state.ordinal) {
case HINT_STATE_ORDINAL: {
Workspace workspace = getWorkspace();
boolean willMoveScreens = workspace.getNextPage() != Workspace.DEFAULT_PAGE;
getStateManager().goToState(NORMAL, true,
willMoveScreens ? null : getScrimView()::startDragHandleEducationAnim);
if (willMoveScreens) {
workspace.post(workspace::moveToDefaultScreen);
}
break;
}
case OVERVIEW_STATE_ORDINAL: {
DiscoveryBounce.showForOverviewIfNeeded(this);
RecentsView rv = getOverviewPanel();
sendCustomAccessibilityEvent(
rv.getPageAt(rv.getCurrentPage()), TYPE_VIEW_FOCUSED, null);
break;
}
case QUICK_SWITCH_STATE_ORDINAL: {
RecentsView rv = getOverviewPanel();
TaskView tasktolaunch = rv.getTaskViewAt(0);
if (tasktolaunch != null) {
tasktolaunch.launchTask(false, success -> {
if (!success) {
getStateManager().goToState(OVERVIEW);
tasktolaunch.notifyTaskLaunchFailed(TAG);
} else {
getStateManager().moveToRestState();
}
}, MAIN_EXECUTOR.getHandler());
} else {
getStateManager().goToState(NORMAL);
}
break;
}
}
}
@Override
public TouchController[] createTouchControllers() {
Mode mode = SysUINavigationMode.getMode(this);
@@ -221,7 +288,12 @@ public class QuickstepLauncher extends BaseQuickstepLauncher {
@Override
protected boolean isRecentsInteractive() {
return mActivity.isInState(OVERVIEW);
return mActivity.isInState(OVERVIEW) || mActivity.isInState(OVERVIEW_MODAL_TASK);
}
@Override
protected boolean isRecentsModal() {
return mActivity.isInState(OVERVIEW_MODAL_TASK);
}
@Override
@@ -229,4 +301,13 @@ public class QuickstepLauncher extends BaseQuickstepLauncher {
mActivity.getStateManager().setCurrentUserControlledAnimation(animController);
}
}
@Override
public void dump(String prefix, FileDescriptor fd, PrintWriter writer, String[] args) {
super.dump(prefix, fd, writer, args);
RecentsView recentsView = getOverviewPanel();
writer.println("\nQuickstepLauncher:");
writer.println(prefix + "\tmOrientationState: " + (recentsView == null ? "recentsNull" :
recentsView.getPagedViewOrientedState()));
}
}
@@ -19,6 +19,7 @@ import static com.android.launcher3.LauncherState.OVERVIEW_BUTTONS;
import static com.android.launcher3.anim.Interpolators.LINEAR;
import static com.android.quickstep.views.RecentsView.CONTENT_ALPHA;
import static com.android.quickstep.views.RecentsView.FULLSCREEN_PROGRESS;
import static com.android.quickstep.views.RecentsView.TASK_MODALNESS;
import android.annotation.TargetApi;
import android.os.Build;
@@ -87,6 +88,11 @@ public final class RecentsViewStateController extends
MultiValueAlpha.VALUE, buttonAlpha, LINEAR);
}
@Override
FloatProperty<RecentsView> getTaskModalnessProperty() {
return TASK_MODALNESS;
}
@Override
FloatProperty<RecentsView> getContentAlphaProperty() {
return CONTENT_ALPHA;
@@ -17,22 +17,19 @@ package com.android.launcher3.uioverrides.states;
import android.content.Context;
import com.android.launcher3.AbstractFloatingView;
import com.android.launcher3.Launcher;
import com.android.launcher3.allapps.AllAppsTransitionController;
import com.android.launcher3.userevent.nano.LauncherLogProto;
import com.android.quickstep.util.LayoutUtils;
import com.android.quickstep.views.RecentsView;
import com.android.quickstep.views.TaskView;
/**
* State indicating that the Launcher is behind an app
*/
public class BackgroundAppState extends OverviewState {
private static final int STATE_FLAGS =
FLAG_DISABLE_RESTORE | FLAG_OVERVIEW_UI | FLAG_DISABLE_ACCESSIBILITY
| FLAG_DISABLE_INTERACTION;
private static final int STATE_FLAGS = FLAG_DISABLE_RESTORE | FLAG_OVERVIEW_UI
| FLAG_WORKSPACE_INACCESSIBLE | FLAG_NON_INTERACTIVE | FLAG_CLOSE_POPUPS;
public BackgroundAppState(int id) {
this(id, LauncherLogProto.ContainerType.TASKSWITCHER);
@@ -42,11 +39,6 @@ public class BackgroundAppState extends OverviewState {
super(id, logContainer, STATE_FLAGS);
}
@Override
public void onStateEnabled(Launcher launcher) {
AbstractFloatingView.closeAllOpenViews(launcher, false);
}
@Override
public float getVerticalProgress(Launcher launcher) {
if (launcher.getDeviceProfile().isVerticalBarLayout()) {
@@ -66,23 +58,7 @@ public class BackgroundAppState extends OverviewState {
}
private float getOverviewScale(Launcher launcher) {
// Initialize the recents view scale to what it would be when starting swipe up
RecentsView recentsView = launcher.getOverviewPanel();
int taskCount = recentsView.getTaskViewCount();
if (taskCount == 0) return 1;
TaskView dummyTask;
if (recentsView.getCurrentPage() >= recentsView.getTaskViewStartIndex()) {
if (recentsView.getCurrentPage() <= taskCount - 1) {
dummyTask = recentsView.getCurrentPageTaskView();
} else {
dummyTask = recentsView.getTaskViewAt(taskCount - 1);
}
} else {
dummyTask = recentsView.getTaskViewAt(0);
}
return recentsView.getTempAppWindowAnimationHelper()
.updateForFullscreenOverview(dummyTask).getSrcToTargetScale();
return ((RecentsView) launcher.getOverviewPanel()).getMaxScaleForFullScreen();
}
@Override
@@ -0,0 +1,70 @@
/*
* 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.
*/
package com.android.launcher3.uioverrides.states;
import android.content.Context;
import android.content.res.Resources;
import android.graphics.Rect;
import com.android.launcher3.Launcher;
import com.android.launcher3.R;
import com.android.launcher3.userevent.nano.LauncherLogProto.ContainerType;
import com.android.quickstep.views.RecentsView;
/**
* An Overview state that shows the current task in a modal fashion. Modal state is where the
* current task is shown on its own without other tasks visible.
*/
public class OverviewModalTaskState extends OverviewState {
private static final int STATE_FLAGS =
FLAG_DISABLE_RESTORE | FLAG_OVERVIEW_UI | FLAG_WORKSPACE_INACCESSIBLE;
public OverviewModalTaskState(int id) {
super(id, ContainerType.OVERVIEW, STATE_FLAGS);
}
@Override
public int getTransitionDuration(Context launcher) {
return 300;
}
@Override
public int getVisibleElements(Launcher launcher) {
return OVERVIEW_BUTTONS;
}
@Override
public float[] getOverviewScaleAndOffset(Launcher launcher) {
Resources res = launcher.getBaseContext().getResources();
Rect out = new Rect();
launcher.<RecentsView>getOverviewPanel().getTaskSize(out);
int taskHeight = out.height();
float topMargin = res.getDimension(R.dimen.task_thumbnail_top_margin);
float bottomMargin = res.getDimension(R.dimen.task_thumbnail_bottom_margin_with_actions);
float newHeight = taskHeight + topMargin + bottomMargin;
float scale = newHeight / taskHeight;
return new float[] {scale, 0};
}
@Override
public float getOverviewModalness() {
return 1.0f;
}
}
@@ -37,17 +37,13 @@ import static com.android.quickstep.SysUINavigationMode.removeShelfFromOverview;
import android.content.Context;
import android.graphics.Rect;
import android.view.View;
import android.view.accessibility.AccessibilityEvent;
import android.view.animation.Interpolator;
import com.android.launcher3.AbstractFloatingView;
import com.android.launcher3.DeviceProfile;
import com.android.launcher3.Launcher;
import com.android.launcher3.LauncherState;
import com.android.launcher3.R;
import com.android.launcher3.Workspace;
import com.android.launcher3.allapps.DiscoveryBounce;
import com.android.launcher3.compat.AccessibilityManagerCompat;
import com.android.launcher3.states.StateAnimationConfig;
import com.android.launcher3.userevent.nano.LauncherLogProto.Action;
import com.android.launcher3.userevent.nano.LauncherLogProto.ContainerType;
@@ -67,7 +63,8 @@ public class OverviewState extends LauncherState {
protected static final Rect sTempRect = new Rect();
private static final int STATE_FLAGS = FLAG_WORKSPACE_ICONS_CAN_BE_DRAGGED
| FLAG_DISABLE_RESTORE | FLAG_OVERVIEW_UI | FLAG_DISABLE_ACCESSIBILITY;
| FLAG_DISABLE_RESTORE | FLAG_OVERVIEW_UI | FLAG_WORKSPACE_INACCESSIBLE
| FLAG_CLOSE_POPUPS;
public OverviewState(int id) {
this(id, STATE_FLAGS);
@@ -82,9 +79,9 @@ public class OverviewState extends LauncherState {
}
@Override
public int getTransitionDuration(Launcher launcher) {
public int getTransitionDuration(Context context) {
// In no-button mode, overview comes in all the way from the left, so give it more time.
boolean isNoButtonMode = SysUINavigationMode.INSTANCE.get(launcher).getMode() == NO_BUTTON;
boolean isNoButtonMode = SysUINavigationMode.INSTANCE.get(context).getMode() == NO_BUTTON;
return isNoButtonMode && ENABLE_OVERVIEW_ACTIONS.get() ? 380 : 250;
}
@@ -136,20 +133,6 @@ public class OverviewState extends LauncherState {
return super.getQsbScaleAndTranslation(launcher);
}
@Override
public void onStateEnabled(Launcher launcher) {
AbstractFloatingView.closeAllOpenViews(launcher);
}
@Override
public void onStateTransitionEnd(Launcher launcher) {
DiscoveryBounce.showForOverviewIfNeeded(launcher);
RecentsView recentsView = launcher.getOverviewPanel();
AccessibilityManagerCompat.sendCustomAccessibilityEvent(
recentsView.getPageAt(recentsView.getCurrentPage()),
AccessibilityEvent.TYPE_VIEW_FOCUSED, null);
}
@Override
public PageAlphaProvider getWorkspacePageAlphaProvider(Launcher launcher) {
return new PageAlphaProvider(DEACCEL_2) {
@@ -259,4 +242,11 @@ public class OverviewState extends LauncherState {
public static OverviewState newSwitchState(int id) {
return new QuickSwitchState(id);
}
/**
* New Overview substate that represents the overview in modal mode (one task shown on its own)
*/
public static OverviewState newModalTaskState(int id) {
return new OverviewModalTaskState(id);
}
}
@@ -15,24 +15,16 @@
*/
package com.android.launcher3.uioverrides.states;
import android.os.Handler;
import android.os.Looper;
import com.android.launcher3.Launcher;
import com.android.launcher3.userevent.nano.LauncherLogProto;
import com.android.quickstep.GestureState;
import com.android.quickstep.views.RecentsView;
import com.android.quickstep.views.TaskView;
/**
* State to indicate we are about to launch a recent task. Note that this state is only used when
* quick switching from launcher; quick switching from an app uses LauncherSwipeHandler.
* @see GestureState.GestureEndTarget#NEW_TASK
* @see com.android.quickstep.GestureState.GestureEndTarget#NEW_TASK
*/
public class QuickSwitchState extends BackgroundAppState {
private static final String TAG = "QuickSwitchState";
public QuickSwitchState(int id) {
super(id, LauncherLogProto.ContainerType.APP);
}
@@ -49,21 +41,4 @@ public class QuickSwitchState extends BackgroundAppState {
public int getVisibleElements(Launcher launcher) {
return NONE;
}
@Override
public void onStateTransitionEnd(Launcher launcher) {
TaskView tasktolaunch = launcher.<RecentsView>getOverviewPanel().getTaskViewAt(0);
if (tasktolaunch != null) {
tasktolaunch.launchTask(false, success -> {
if (!success) {
launcher.getStateManager().goToState(OVERVIEW);
tasktolaunch.notifyTaskLaunchFailed(TAG);
} else {
launcher.getStateManager().moveToRestState();
}
}, new Handler(Looper.getMainLooper()));
} else {
launcher.getStateManager().goToState(NORMAL);
}
}
}
@@ -17,7 +17,6 @@ package com.android.launcher3.uioverrides.touchcontrollers;
import static com.android.launcher3.LauncherState.ALL_APPS;
import static com.android.launcher3.LauncherState.NORMAL;
import static com.android.launcher3.LauncherState.OVERVIEW;
import static com.android.launcher3.allapps.AllAppsTransitionController.ALL_APPS_PROGRESS;
import static com.android.launcher3.anim.Interpolators.DEACCEL_3;
import static com.android.launcher3.config.FeatureFlags.ENABLE_QUICKSTEP_LIVE_TILE;
@@ -99,7 +98,7 @@ public class NavBarToHomeTouchController implements TouchController,
if (!cameFromNavBar) {
return false;
}
if (mStartState == OVERVIEW || mStartState == ALL_APPS) {
if (mStartState.overviewUi || mStartState == ALL_APPS) {
return true;
}
if (AbstractFloatingView.getTopOpenView(mLauncher) != null) {
@@ -129,7 +128,7 @@ public class NavBarToHomeTouchController implements TouchController,
private void initCurrentAnimation() {
long accuracy = (long) (getShiftRange() * 2);
final PendingAnimation builder = new PendingAnimation(accuracy);
if (mStartState == OVERVIEW) {
if (mStartState.overviewUi) {
RecentsView recentsView = mLauncher.getOverviewPanel();
builder.setFloat(recentsView, ADJACENT_PAGE_OFFSET,
-mPullbackDistance / recentsView.getPageOffsetScale(), PULLBACK_INTERPOLATOR);
@@ -35,8 +35,6 @@ import static com.android.systemui.shared.system.QuickStepContract.SYSUI_STATE_O
import android.view.MotionEvent;
import androidx.annotation.Nullable;
import com.android.launcher3.Launcher;
import com.android.launcher3.LauncherState;
import com.android.launcher3.Utilities;
@@ -57,7 +55,7 @@ import com.android.systemui.shared.system.ActivityManagerWrapper;
*/
public class QuickSwitchTouchController extends AbstractStateChangeTouchController {
private @Nullable TaskView mTaskToLaunch;
protected final RecentsView mOverviewPanel;
public QuickSwitchTouchController(Launcher launcher) {
this(launcher, SingleAxisSwipeDetector.HORIZONTAL);
@@ -65,6 +63,7 @@ public class QuickSwitchTouchController extends AbstractStateChangeTouchControll
protected QuickSwitchTouchController(Launcher l, SingleAxisSwipeDetector.Direction dir) {
super(l, dir);
mOverviewPanel = l.getOverviewPanel();
}
@Override
@@ -94,7 +93,6 @@ public class QuickSwitchTouchController extends AbstractStateChangeTouchControll
public void onDragStart(boolean start, float startDisplacement) {
super.onDragStart(start, startDisplacement);
mStartContainerType = LauncherLogProto.ContainerType.NAVBAR;
mTaskToLaunch = mLauncher.<RecentsView>getOverviewPanel().getTaskViewAt(0);
ActivityManagerWrapper.getInstance()
.closeSystemWindows(CLOSE_SYSTEM_WINDOWS_REASON_RECENTS);
}
@@ -102,7 +100,6 @@ public class QuickSwitchTouchController extends AbstractStateChangeTouchControll
@Override
protected void onSwipeInteractionCompleted(LauncherState targetState, int logAction) {
super.onSwipeInteractionCompleted(targetState, logAction);
mTaskToLaunch = null;
}
@Override
@@ -141,13 +138,15 @@ public class QuickSwitchTouchController extends AbstractStateChangeTouchControll
}
private void updateFullscreenProgress(float progress) {
if (mTaskToLaunch != null) {
mTaskToLaunch.setFullscreenProgress(progress);
int sysuiFlags = progress > UPDATE_SYSUI_FLAGS_THRESHOLD
? mTaskToLaunch.getThumbnail().getSysUiStatusNavFlags()
: 0;
mLauncher.getSystemUiController().updateUiState(UI_STATE_OVERVIEW, sysuiFlags);
mOverviewPanel.setFullscreenProgress(progress);
int sysuiFlags = 0;
if (progress > UPDATE_SYSUI_FLAGS_THRESHOLD) {
TaskView tv = mOverviewPanel.getTaskViewAt(0);
if (tv != null) {
sysuiFlags = tv.getThumbnail().getSysUiStatusNavFlags();
}
}
mLauncher.getSystemUiController().updateUiState(UI_STATE_OVERVIEW, sysuiFlags);
}
@Override
@@ -96,6 +96,9 @@ public abstract class TaskViewTouchController<T extends BaseDraggingActivity>
protected abstract boolean isRecentsInteractive();
/** Is recents view showing a single task in a modal way. */
protected abstract boolean isRecentsModal();
protected void onUserControlledAnimationCreated(AnimatorPlaybackController animController) {
}
@@ -134,7 +137,7 @@ public abstract class TaskViewTouchController<T extends BaseDraggingActivity>
if (mRecentsView.isTaskViewVisible(view) && mActivity.getDragLayer()
.isEventOverView(view, ev)) {
// Disable swiping up and down if the task overlay is modal.
if (view.isTaskOverlayModal()) {
if (isRecentsModal()) {
mTaskBeingDragged = null;
break;
}
@@ -156,7 +156,7 @@ final class AppToOverviewAnimationProvider<T extends BaseDraggingActivity> exten
mActivityInterface.getSwipeUpDestinationAndLength(mActivity.getDeviceProfile(), mActivity,
targetRect);
clipHelper.updateTargetRect(targetRect);
clipHelper.prepareAnimation(mActivity.getDeviceProfile(), false /* isOpening */);
clipHelper.prepareAnimation(mActivity.getDeviceProfile());
TransformParams params = new TransformParams()
.setSyncTransactionApplier(new SyncRtSurfaceTransactionApplierCompat(rootView));
@@ -26,7 +26,6 @@ import android.animation.Animator;
import android.annotation.TargetApi;
import android.content.Context;
import android.content.Intent;
import android.graphics.Point;
import android.graphics.PointF;
import android.graphics.Rect;
import android.graphics.RectF;
@@ -265,8 +264,7 @@ public abstract class BaseSwipeUpHandler<T extends BaseDraggingActivity, Q exten
if (targets.minimizedHomeBounds != null && runningTaskTarget != null) {
overviewStackBounds = mActivityInterface
.getOverviewWindowBounds(targets.minimizedHomeBounds, runningTaskTarget);
dp = dp.getMultiWindowProfile(mContext, new Point(
overviewStackBounds.width(), overviewStackBounds.height()));
dp = dp.getMultiWindowProfile(mContext, overviewStackBounds);
} else {
// If we are not in multi-window mode, home insets should be same as system insets.
dp = dp.copy(mContext);
@@ -278,7 +276,7 @@ public abstract class BaseSwipeUpHandler<T extends BaseDraggingActivity, Q exten
updateSource(overviewStackBounds, runningTaskTarget);
}
mAppWindowAnimationHelper.prepareAnimation(dp, false /* isOpening */);
mAppWindowAnimationHelper.prepareAnimation(dp);
initTransitionEndpoints(dp);
// Notify when the animation starts
@@ -347,10 +345,7 @@ public abstract class BaseSwipeUpHandler<T extends BaseDraggingActivity, Q exten
mAppWindowAnimationHelper.updateTargetRect(TEMP_RECT);
if (mDeviceState.isFullyGesturalNavMode()) {
// We can drag all the way to the top of the screen.
// TODO(b/149609070): Landscape apps are currently limited in
// their ability to scale past the target rect.
float dragFactor = (float) dp.heightPx / mTransitionDragLength;
mDragLengthFactor = displayRotation == 0 ? dragFactor : Math.min(1.0f, dragFactor);
mDragLengthFactor = (float) dp.heightPx / mTransitionDragLength;
Pair<Float, Float> dragFactorStartAndMaxProgress =
mActivityInterface.getSwipeUpPullbackStartAndMaxProgress();
mDragLengthFactorStartPullback = dragFactorStartAndMaxProgress.first;
@@ -18,6 +18,7 @@ package com.android.quickstep;
import static com.android.launcher3.anim.Interpolators.LINEAR;
import static com.android.quickstep.SysUINavigationMode.Mode.NO_BUTTON;
import static com.android.quickstep.fallback.FallbackRecentsView.ZOOM_PROGRESS;
import static com.android.quickstep.util.WindowSizeStrategy.FALLBACK_RECENTS_SIZE_STRATEGY;
import static com.android.quickstep.views.RecentsView.CONTENT_ALPHA;
import android.animation.Animator;
@@ -36,7 +37,6 @@ import com.android.launcher3.anim.AnimatorPlaybackController;
import com.android.launcher3.userevent.nano.LauncherLogProto;
import com.android.quickstep.fallback.FallbackRecentsView;
import com.android.quickstep.util.ActivityInitListener;
import com.android.quickstep.util.LayoutUtils;
import com.android.quickstep.views.RecentsView;
import com.android.systemui.shared.system.RemoteAnimationTargetCompat;
@@ -60,7 +60,7 @@ public final class FallbackActivityInterface implements
@Override
public int getSwipeUpDestinationAndLength(DeviceProfile dp, Context context, Rect outRect) {
LayoutUtils.calculateFallbackTaskSize(context, dp, outRect);
FALLBACK_RECENTS_SIZE_STRATEGY.calculateTaskSize(context, dp, outRect);
if (dp.isVerticalBarLayout()
&& SysUINavigationMode.INSTANCE.get(context).getMode() != NO_BUTTON) {
Rect targetInsets = dp.getInsets();
@@ -215,7 +215,7 @@ public final class FallbackActivityInterface implements
}
@Override
public boolean shouldMinimizeSplitScreen() {
public boolean allowMinimizeSplitScreen() {
// TODO: Remove this once b/77875376 is fixed
return false;
}
@@ -250,8 +250,11 @@ public class FallbackSwipeHandler extends BaseSwipeUpHandler<RecentsActivity, Fa
public void updateFinalShift() {
mTransformParams.setProgress(mCurrentShift.value);
if (mRecentsAnimationController != null) {
mRecentsAnimationController.setWindowThresholdCrossed(!mInQuickSwitchMode
&& (mCurrentShift.value > 1 - UPDATE_SYSUI_FLAGS_THRESHOLD));
boolean swipeUpThresholdPassed = mCurrentShift.value > 1 - UPDATE_SYSUI_FLAGS_THRESHOLD;
mRecentsAnimationController.setUseLauncherSystemBarFlags(mInQuickSwitchMode
|| swipeUpThresholdPassed);
mRecentsAnimationController.setSplitScreenMinimized(!mInQuickSwitchMode
&& swipeUpThresholdPassed);
}
if (!mInQuickSwitchMode && !mDeviceState.isFullyGesturalNavMode()) {
@@ -476,7 +479,7 @@ public class FallbackSwipeHandler extends BaseSwipeUpHandler<RecentsActivity, Fa
mRecentsAnimationController.enableInputConsumer();
if (mRunningOverHome) {
mAppWindowAnimationHelper.prepareAnimation(mDp, true);
mAppWindowAnimationHelper.prepareAnimation(mDp);
}
applyTransformUnchecked();
@@ -26,6 +26,7 @@ import static com.android.launcher3.anim.Interpolators.ACCEL_2;
import static com.android.launcher3.anim.Interpolators.INSTANT;
import static com.android.launcher3.anim.Interpolators.LINEAR;
import static com.android.quickstep.LauncherSwipeHandler.RECENTS_ATTACH_DURATION;
import static com.android.quickstep.util.WindowSizeStrategy.LAUNCHER_ACTIVITY_SIZE_STRATEGY;
import static com.android.quickstep.views.RecentsView.ADJACENT_PAGE_OFFSET;
import android.animation.Animator;
@@ -82,7 +83,7 @@ public final class LauncherActivityInterface implements BaseActivityInterface<La
@Override
public int getSwipeUpDestinationAndLength(DeviceProfile dp, Context context, Rect outRect) {
LayoutUtils.calculateLauncherTaskSize(context, dp, outRect);
LAUNCHER_ACTIVITY_SIZE_STRATEGY.calculateTaskSize(context, dp, outRect);
if (dp.isVerticalBarLayout() && SysUINavigationMode.getMode(context) != Mode.NO_BUTTON) {
Rect targetInsets = dp.getInsets();
int hotseatInset = dp.isSeascape() ? targetInsets.left : targetInsets.right;
@@ -211,7 +212,7 @@ public final class LauncherActivityInterface implements BaseActivityInterface<La
final LauncherState startState = launcher.getStateManager().getState();
LauncherState resetState = startState;
if (startState.disableRestore) {
if (startState.shouldDisableRestore()) {
resetState = launcher.getStateManager().getRestState();
}
launcher.getStateManager().setRestState(resetState);
@@ -407,7 +408,7 @@ public final class LauncherActivityInterface implements BaseActivityInterface<La
}
@Override
public boolean shouldMinimizeSplitScreen() {
public boolean allowMinimizeSplitScreen() {
return true;
}
@@ -37,6 +37,7 @@ import static com.android.quickstep.MultiStateCallback.DEBUG_STATES;
import static com.android.quickstep.SysUINavigationMode.Mode.TWO_BUTTONS;
import static com.android.quickstep.util.ShelfPeekAnim.ShelfAnimState.HIDE;
import static com.android.quickstep.util.ShelfPeekAnim.ShelfAnimState.PEEK;
import static com.android.quickstep.util.WindowSizeStrategy.LAUNCHER_ACTIVITY_SIZE_STRATEGY;
import static com.android.quickstep.views.RecentsView.UPDATE_SYSUI_FLAGS_THRESHOLD;
import android.animation.Animator;
@@ -80,7 +81,6 @@ import com.android.quickstep.GestureState.GestureEndTarget;
import com.android.quickstep.inputconsumers.OverviewInputConsumer;
import com.android.quickstep.util.ActiveGestureLog;
import com.android.quickstep.util.AppWindowAnimationHelper.TargetAlphaProvider;
import com.android.quickstep.util.LayoutUtils;
import com.android.quickstep.util.RectFSpringAnim;
import com.android.quickstep.util.ShelfPeekAnim;
import com.android.quickstep.util.ShelfPeekAnim.ShelfAnimState;
@@ -208,8 +208,7 @@ public class LauncherSwipeHandler<T extends BaseDraggingActivity>
mTaskAnimationManager = taskAnimationManager;
mTouchTimeMs = touchTimeMs;
mContinuingLastGesture = continuingLastGesture;
mTaskViewSimulator = new TaskViewSimulator(
context, LayoutUtils::calculateLauncherTaskSize, true);
mTaskViewSimulator = new TaskViewSimulator(context, LAUNCHER_ACTIVITY_SIZE_STRATEGY);
initAfterSubclassConstructor();
initStateCallbacks();
@@ -531,7 +530,7 @@ public class LauncherSwipeHandler<T extends BaseDraggingActivity>
@Override
protected void initTransitionEndpoints(DeviceProfile dp) {
super.initTransitionEndpoints(dp);
mTaskViewSimulator.setDp(dp, false /* isOpening */);
mTaskViewSimulator.setDp(dp);
mTaskViewSimulator.setLayoutRotation(
mDeviceState.getCurrentActiveRotation(),
mDeviceState.getDisplayRotation());
@@ -631,17 +630,21 @@ public class LauncherSwipeHandler<T extends BaseDraggingActivity>
* @param windowProgress 0 == app, 1 == overview
*/
private void updateSysUiFlags(float windowProgress) {
if (mRecentsView != null) {
if (mRecentsAnimationController != null && mRecentsView != null) {
TaskView runningTask = mRecentsView.getRunningTaskView();
TaskView centermostTask = mRecentsView.getTaskViewNearestToCenterOfScreen();
int centermostTaskFlags = centermostTask == null ? 0
: centermostTask.getThumbnail().getSysUiStatusNavFlags();
boolean useHomeScreenFlags = windowProgress > 1 - UPDATE_SYSUI_FLAGS_THRESHOLD;
boolean swipeUpThresholdPassed = windowProgress > 1 - UPDATE_SYSUI_FLAGS_THRESHOLD;
boolean quickswitchThresholdPassed = centermostTask != runningTask;
// We will handle the sysui flags based on the centermost task view.
if (mRecentsAnimationController != null) {
mRecentsAnimationController.setWindowThresholdCrossed(centermostTaskFlags != 0
&& useHomeScreenFlags);
}
int sysuiFlags = useHomeScreenFlags ? 0 : centermostTaskFlags;
mRecentsAnimationController.setUseLauncherSystemBarFlags(
(swipeUpThresholdPassed || quickswitchThresholdPassed)
&& centermostTaskFlags != 0);
mRecentsAnimationController.setSplitScreenMinimized(swipeUpThresholdPassed);
int sysuiFlags = swipeUpThresholdPassed ? 0 : centermostTaskFlags;
mActivity.getSystemUiController().updateUiState(UI_STATE_OVERVIEW, sysuiFlags);
}
}
@@ -44,7 +44,6 @@ import com.android.launcher3.util.ObjectWrapper;
import com.android.launcher3.views.BaseDragLayer;
import com.android.quickstep.fallback.FallbackRecentsView;
import com.android.quickstep.fallback.RecentsRootView;
import com.android.quickstep.util.AppWindowAnimationHelper;
import com.android.quickstep.views.TaskView;
import com.android.systemui.shared.recents.model.ThumbnailData;
import com.android.systemui.shared.system.ActivityOptionsCompat;
@@ -121,7 +120,7 @@ public final class RecentsActivity extends BaseRecentsActivity {
protected DeviceProfile createDeviceProfile() {
DeviceProfile dp = InvariantDeviceProfile.INSTANCE.get(this).getDeviceProfile(this);
return (mRecentsRootView != null) && isInMultiWindowMode()
? dp.getMultiWindowProfile(this, mRecentsRootView.getLastKnownSize())
? dp.getMultiWindowProfile(this, getMultiWindowDisplaySize())
: super.createDeviceProfile();
}
@@ -184,17 +183,14 @@ public final class RecentsActivity extends BaseRecentsActivity {
RemoteAnimationTargetCompat[] wallpaperTargets) {
AnimatorSet target = new AnimatorSet();
boolean activityClosing = taskIsATargetWithMode(appTargets, getTaskId(), MODE_CLOSING);
AppWindowAnimationHelper helper = new AppWindowAnimationHelper(
mFallbackRecentsView.getPagedViewOrientedState(), this);
Animator recentsAnimator = getRecentsWindowAnimator(taskView, !activityClosing, appTargets,
wallpaperTargets, null /* depthController */,
helper);
wallpaperTargets, null /* depthController */);
target.play(recentsAnimator.setDuration(RECENTS_LAUNCH_DURATION));
// Found a visible recents task that matches the opening app, lets launch the app from there
if (activityClosing) {
Animator adjacentAnimation = mFallbackRecentsView
.createAdjacentPageAnimForTaskLaunch(taskView, helper);
.createAdjacentPageAnimForTaskLaunch(taskView);
adjacentAnimation.setInterpolator(Interpolators.TOUCH_RESPONSE_INTERPOLATOR);
adjacentAnimation.setDuration(RECENTS_LAUNCH_DURATION);
adjacentAnimation.addListener(new AnimatorListenerAdapter() {
@@ -130,13 +130,6 @@ public class TaskOverlayFactory implements ResourceBasedOverride {
public void reset() {
}
/**
* Whether the overlay is modal, which means only tapping is enabled, but no swiping.
*/
public boolean isOverlayModal() {
return false;
}
/**
* Gets the task snapshot as it is displayed on the screen.
*
@@ -123,8 +123,10 @@ public final class TaskViewUtils {
public static Animator getRecentsWindowAnimator(TaskView v, boolean skipViewChanges,
RemoteAnimationTargetCompat[] appTargets,
RemoteAnimationTargetCompat[] wallpaperTargets,
DepthController depthController,
final AppWindowAnimationHelper inOutHelper) {
DepthController depthController) {
AppWindowAnimationHelper inOutHelper = new AppWindowAnimationHelper(
v.getRecentsView().getPagedViewOrientedState(), v.getContext());
SyncRtSurfaceTransactionApplierCompat applier =
new SyncRtSurfaceTransactionApplierCompat(v);
final RemoteAnimationTargets targets =
@@ -149,10 +151,8 @@ public final class TaskViewUtils {
{
inOutHelper.setTaskAlphaCallback((t, alpha) -> mTaskAlpha.value);
inOutHelper.prepareAnimation(
BaseActivity.fromContext(v.getContext()).getDeviceProfile(),
true /* isOpening */);
BaseActivity.fromContext(v.getContext()).getDeviceProfile());
inOutHelper.fromTaskThumbnailView(v.getThumbnail(), (RecentsView) v.getParent(),
targets.apps.length == 0 ? null : targets.apps[0]);
@@ -16,22 +16,19 @@
package com.android.quickstep.fallback;
import static com.android.launcher3.LauncherAnimUtils.SCALE_PROPERTY;
import static com.android.quickstep.util.WindowSizeStrategy.FALLBACK_RECENTS_SIZE_STRATEGY;
import android.app.ActivityManager.RunningTaskInfo;
import android.content.Context;
import android.graphics.Canvas;
import android.graphics.Rect;
import android.util.AttributeSet;
import android.util.FloatProperty;
import android.view.View;
import com.android.launcher3.DeviceProfile;
import com.android.launcher3.Utilities;
import com.android.quickstep.RecentsActivity;
import com.android.quickstep.util.LayoutUtils;
import com.android.quickstep.views.OverviewActionsView;
import com.android.quickstep.views.RecentsView;
import com.android.quickstep.views.TaskView;
import com.android.systemui.shared.recents.model.Task;
import com.android.systemui.shared.recents.model.Task.TaskKey;
@@ -65,7 +62,7 @@ public class FallbackRecentsView extends RecentsView<RecentsActivity> {
}
public FallbackRecentsView(Context context, AttributeSet attrs, int defStyleAttr) {
super(context, attrs, defStyleAttr, false);
super(context, attrs, defStyleAttr, FALLBACK_RECENTS_SIZE_STRATEGY);
}
@Override
@@ -104,11 +101,6 @@ public class FallbackRecentsView extends RecentsView<RecentsActivity> {
resetViewUI();
}
@Override
protected void getTaskSize(DeviceProfile dp, Rect outRect) {
LayoutUtils.calculateFallbackTaskSize(getContext(), dp, outRect);
}
@Override
public boolean shouldUseMultiWindowTaskSizeStrategy() {
// Just use the activity task size for multi-window as well.
@@ -140,16 +132,7 @@ public class FallbackRecentsView extends RecentsView<RecentsActivity> {
@Override
protected void onLayout(boolean changed, int left, int top, int right, int bottom) {
super.onLayout(changed, left, top, right, bottom);
if (getTaskViewCount() == 0) {
mZoomScale = 1f;
} else {
TaskView dummyTask = getTaskViewAt(0);
mZoomScale = getTempAppWindowAnimationHelper()
.updateForFullscreenOverview(dummyTask)
.getSrcToTargetScale();
}
mZoomScale = getMaxScaleForFullScreen();
setZoomProgress(mZoomInProgress);
}
@@ -28,4 +28,9 @@ public class RecentsTaskController extends TaskViewTouchController<RecentsActivi
protected boolean isRecentsInteractive() {
return mActivity.hasWindowFocus();
}
@Override
protected boolean isRecentsModal() {
return false;
}
}
@@ -20,7 +20,6 @@ import static com.android.systemui.shared.system.QuickStepContract.getWindowCorn
import static com.android.systemui.shared.system.QuickStepContract.supportsRoundedCornersOnWindows;
import static com.android.systemui.shared.system.RemoteAnimationTargetCompat.ACTIVITY_TYPE_HOME;
import static com.android.systemui.shared.system.RemoteAnimationTargetCompat.MODE_CLOSING;
import static com.android.systemui.shared.system.RemoteAnimationTargetCompat.MODE_OPENING;
import android.annotation.TargetApi;
import android.content.Context;
@@ -43,7 +42,6 @@ import com.android.quickstep.RemoteAnimationTargets;
import com.android.quickstep.SystemUiProxy;
import com.android.quickstep.views.RecentsView;
import com.android.quickstep.views.TaskThumbnailView;
import com.android.quickstep.views.TaskView;
import com.android.systemui.shared.recents.utilities.RectFEvaluator;
import com.android.systemui.shared.system.RemoteAnimationTargetCompat;
import com.android.systemui.shared.system.SyncRtSurfaceTransactionApplierCompat;
@@ -96,9 +94,6 @@ public class AppWindowAnimationHelper {
// Corner radius currently applied to transformed window.
private float mCurrentCornerRadius;
// Whether to boost the opening animation target layers, or the closing
private int mBoostModeTargetLayers = -1;
private TargetAlphaProvider mTaskAlphaCallback = (t, a) -> a;
private TargetAlphaProvider mBaseAlphaCallback = (t, a) -> 1;
@@ -163,8 +158,7 @@ public class AppWindowAnimationHelper {
mTargetRect.width(), mTargetRect.height());
}
public void prepareAnimation(DeviceProfile dp, boolean isOpening) {
mBoostModeTargetLayers = isOpening ? MODE_OPENING : MODE_CLOSING;
public void prepareAnimation(DeviceProfile dp) {
mUseRoundedCornersOnWindows = mSupportsRoundedCornersOnWindows && !dp.isMultiWindowMode;
}
@@ -317,10 +311,6 @@ public class AppWindowAnimationHelper {
mBaseAlphaCallback = callback;
}
public void fromTaskThumbnailView(TaskThumbnailView ttv, RecentsView rv) {
fromTaskThumbnailView(ttv, rv, null);
}
public void fromTaskThumbnailView(TaskThumbnailView ttv, RecentsView rv,
@Nullable RemoteAnimationTargetCompat target) {
BaseDraggingActivity activity = BaseDraggingActivity.fromContext(ttv.getContext());
@@ -357,19 +347,6 @@ public class AppWindowAnimationHelper {
}
}
/**
* Compute scale and translation y such that the specified task view fills the screen.
*/
public AppWindowAnimationHelper updateForFullscreenOverview(TaskView v) {
TaskThumbnailView thumbnailView = v.getThumbnail();
RecentsView recentsView = v.getRecentsView();
fromTaskThumbnailView(thumbnailView, recentsView);
Rect taskSize = new Rect();
recentsView.getTaskSize(taskSize);
updateTargetRect(taskSize);
return this;
}
private void updateStackBoundsToMultiWindowTaskSize(BaseDraggingActivity activity) {
SystemUiProxy proxy = SystemUiProxy.INSTANCE.get(activity);
if (proxy.isActive()) {
@@ -202,6 +202,12 @@ public class StaggeredWorkspaceAnim {
alpha.setInterpolator(LINEAR);
alpha.setDuration(ALPHA_DURATION_MS);
alpha.setStartDelay(startDelay);
alpha.addListener(new AnimatorListenerAdapter() {
@Override
public void onAnimationEnd(Animator animation) {
v.setAlpha(1f);
}
});
mAnimators.play(alpha);
}
@@ -17,14 +17,11 @@ package com.android.quickstep.util;
import static android.view.Surface.ROTATION_0;
import static com.android.launcher3.config.FeatureFlags.ENABLE_QUICKSTEP_LIVE_TILE;
import static com.android.launcher3.states.RotationHelper.deltaRotation;
import static com.android.launcher3.touch.PagedOrientationHandler.MATRIX_POST_TRANSLATE;
import static com.android.quickstep.util.AppWindowAnimationHelper.applySurfaceParams;
import static com.android.quickstep.util.RecentsOrientedState.isFixedRotationTransformEnabled;
import static com.android.quickstep.util.RecentsOrientedState.postDisplayRotation;
import static com.android.systemui.shared.system.RemoteAnimationTargetCompat.MODE_CLOSING;
import static com.android.systemui.shared.system.RemoteAnimationTargetCompat.MODE_OPENING;
import static com.android.systemui.shared.system.WindowManagerWrapper.WINDOWING_MODE_FULLSCREEN;
import android.content.Context;
@@ -61,7 +58,7 @@ public class TaskViewSimulator {
private final RecentsOrientedState mOrientationState;
private final Context mContext;
private final TaskSizeProvider mSizeProvider;
private final WindowSizeStrategy mSizeStrategy;
private final Rect mTaskRect = new Rect();
private final PointF mPivot = new PointF();
@@ -71,8 +68,6 @@ public class TaskViewSimulator {
private RemoteAnimationTargetCompat mRunningTarget;
private RecentsAnimationTargets mAllTargets;
// Whether to boost the opening animation target layers, or the closing
private int mBoostModeTargetLayers = -1;
private TargetAlphaProvider mTaskAlphaCallback = (t, a) -> a;
// Thumbnail view properties
@@ -95,14 +90,12 @@ public class TaskViewSimulator {
private boolean mLayoutValid = false;
private boolean mScrollValid = false;
public TaskViewSimulator(Context context, TaskSizeProvider sizeProvider,
boolean rotationSupportedByActivity) {
public TaskViewSimulator(Context context, WindowSizeStrategy sizeStrategy) {
mContext = context;
mSizeProvider = sizeProvider;
mSizeStrategy = sizeStrategy;
mPositionHelper = new PreviewPositionHelper(context);
mOrientationState = new RecentsOrientedState(context, rotationSupportedByActivity,
i -> { });
mOrientationState = new RecentsOrientedState(context, sizeStrategy, i -> { });
// We do not need to attach listeners as the simulator is created just for the gesture
// duration, and any settings are unlikely to change during this
mOrientationState.initWithoutListeners();
@@ -114,9 +107,9 @@ public class TaskViewSimulator {
/**
* Sets the device profile for the current state
*/
public void setDp(DeviceProfile dp, boolean isOpening) {
public void setDp(DeviceProfile dp) {
mDp = dp;
mBoostModeTargetLayers = isOpening ? MODE_OPENING : MODE_CLOSING;
mOrientationState.setMultiWindowMode(mDp.isMultiWindowMode);
mLayoutValid = false;
}
@@ -143,7 +136,7 @@ public class TaskViewSimulator {
if (mDp == null) {
return 1;
}
mSizeProvider.calculateTaskSize(mContext, mDp, mTaskRect);
mSizeStrategy.calculateTaskSize(mContext, mDp, mTaskRect);
return mOrientationState.getFullScreenScaleAndPivot(mTaskRect, mDp, mPivot);
}
@@ -161,8 +154,7 @@ public class TaskViewSimulator {
mThumbnailPosition.set(runningTarget.screenSpaceBounds);
// TODO: Should sourceContainerBounds already have this offset?
mThumbnailPosition.offsetTo(mRunningTarget.position.x, mRunningTarget.position.y);
mThumbnailPosition.offset(-mRunningTarget.position.x, -mRunningTarget.position.y);
mLayoutValid = false;
}
@@ -198,7 +190,7 @@ public class TaskViewSimulator {
? mOrientationState.getDisplayRotation() : mPositionHelper.getCurrentRotation();
mPositionHelper.updateThumbnailMatrix(mThumbnailPosition, mThumbnailData,
mDp.isMultiWindowMode, mTaskRect.width(), mTaskRect.height());
mTaskRect.width(), mTaskRect.height(), mDp);
mPositionHelper.getMatrix().invert(mInversePositionMatrix);
@@ -209,6 +201,7 @@ public class TaskViewSimulator {
mScrollValid = false;
}
if (!mScrollValid) {
mScrollValid = true;
int start = mOrientationState.getOrientationHandler()
@@ -243,6 +236,8 @@ public class TaskViewSimulator {
postDisplayRotation(deltaRotation(
mOrientationState.getLauncherRotation(), mOrientationState.getDisplayRotation()),
mDp.widthPx, mDp.heightPx, mMatrix);
mMatrix.postTranslate(mDp.windowX - mRunningTarget.position.x,
mDp.windowY - mRunningTarget.position.y);
// Crop rect is the inverse of thumbnail matrix
mTempRectF.set(-insets.left, -insets.top,
@@ -253,8 +248,7 @@ public class TaskViewSimulator {
SurfaceParams[] surfaceParams = new SurfaceParams[mAllTargets.unfilteredApps.length];
for (int i = 0; i < mAllTargets.unfilteredApps.length; i++) {
RemoteAnimationTargetCompat app = mAllTargets.unfilteredApps[i];
SurfaceParams.Builder builder = new SurfaceParams.Builder(app.leash)
.withLayer(RemoteAnimationProvider.getLayer(app, mBoostModeTargetLayers));
SurfaceParams.Builder builder = new SurfaceParams.Builder(app.leash);
if (app.mode == mAllTargets.targetMode) {
float alpha = mTaskAlphaCallback.getAlpha(app, params.getTargetAlpha());
@@ -275,9 +269,6 @@ public class TaskViewSimulator {
}
} else {
builder.withAlpha(1);
if (ENABLE_QUICKSTEP_LIVE_TILE.get() && params.isLauncherOnTop()) {
builder.withLayer(Integer.MAX_VALUE);
}
}
surfaceParams[i] = builder.build();
}
@@ -298,16 +289,4 @@ public class TaskViewSimulator {
// Ideally we should use square-root. This is an optimization as one of the dimension is 0.
return Math.max(Math.abs(mTempPoint[0]), Math.abs(mTempPoint[1]));
}
/**
* Interface for calculating taskSize
*/
public interface TaskSizeProvider {
/**
* Sets the outRect to the expected taskSize
*/
void calculateTaskSize(Context context, DeviceProfile dp, Rect outRect);
}
}
@@ -56,7 +56,8 @@ public class ClearAllButton extends Button implements PageCallbacks {
@Override
protected void onLayout(boolean changed, int left, int top, int right, int bottom) {
super.onLayout(changed, left, top, right, bottom);
mScrollOffset = mIsRtl ? mParent.getPaddingRight() / 2 : - mParent.getPaddingLeft() / 2;
PagedOrientationHandler orientationHandler = mParent.getPagedOrientationHandler();
mScrollOffset = orientationHandler.getClearAllScrollOffset(mParent, mIsRtl);
}
@Override
@@ -21,12 +21,12 @@ import android.graphics.drawable.Drawable;
import android.util.AttributeSet;
import android.view.View;
import androidx.annotation.NonNull;
import com.android.launcher3.FastBitmapDrawable;
import java.util.ArrayList;
import androidx.annotation.NonNull;
/**
* A view which draws a drawable stretched to fit its size. Unlike ImageView, it avoids relayout
* when the drawable changes.
@@ -130,4 +130,14 @@ public class IconView extends View {
mScaleListeners.remove(listener);
}
}
@Override
public void setAlpha(float alpha) {
super.setAlpha(alpha);
if (alpha > 0) {
setVisibility(VISIBLE);
} else {
setVisibility(INVISIBLE);
}
}
}
@@ -20,17 +20,18 @@ import static com.android.launcher3.LauncherState.ALL_APPS_HEADER_EXTRA;
import static com.android.launcher3.LauncherState.NORMAL;
import static com.android.launcher3.LauncherState.OVERVIEW;
import static com.android.launcher3.LauncherState.OVERVIEW_BUTTONS;
import static com.android.launcher3.LauncherState.OVERVIEW_MODAL_TASK;
import static com.android.launcher3.LauncherState.SPRING_LOADED;
import static com.android.launcher3.QuickstepAppTransitionManagerImpl.ALL_APPS_PROGRESS_OFF_SCREEN;
import static com.android.launcher3.allapps.AllAppsTransitionController.ALL_APPS_PROGRESS;
import static com.android.launcher3.config.FeatureFlags.ENABLE_QUICKSTEP_LIVE_TILE;
import static com.android.quickstep.util.WindowSizeStrategy.LAUNCHER_ACTIVITY_SIZE_STRATEGY;
import android.animation.AnimatorSet;
import android.animation.ObjectAnimator;
import android.annotation.TargetApi;
import android.content.Context;
import android.graphics.Canvas;
import android.graphics.Rect;
import android.os.Build;
import android.util.AttributeSet;
import android.view.MotionEvent;
@@ -38,7 +39,6 @@ import android.view.View;
import android.widget.FrameLayout;
import com.android.launcher3.BaseQuickstepLauncher;
import com.android.launcher3.DeviceProfile;
import com.android.launcher3.Hotseat;
import com.android.launcher3.LauncherState;
import com.android.launcher3.LauncherStateManager.StateListener;
@@ -52,7 +52,6 @@ import com.android.launcher3.views.ScrimView;
import com.android.quickstep.SysUINavigationMode;
import com.android.quickstep.util.AppWindowAnimationHelper;
import com.android.quickstep.util.AppWindowAnimationHelper.TransformParams;
import com.android.quickstep.util.LayoutUtils;
import com.android.systemui.plugins.PluginListener;
import com.android.systemui.plugins.RecentsExtraCard;
@@ -63,8 +62,6 @@ import com.android.systemui.plugins.RecentsExtraCard;
public class LauncherRecentsView extends RecentsView<BaseQuickstepLauncher>
implements StateListener {
private static final Rect sTempRect = new Rect();
private final TransformParams mTransformParams = new TransformParams();
private RecentsExtraCard mRecentsExtraCardPlugin;
@@ -95,7 +92,7 @@ public class LauncherRecentsView extends RecentsView<BaseQuickstepLauncher>
}
public LauncherRecentsView(Context context, AttributeSet attrs, int defStyleAttr) {
super(context, attrs, defStyleAttr, true);
super(context, attrs, defStyleAttr, LAUNCHER_ACTIVITY_SIZE_STRATEGY);
mActivity.getStateManager().addStateListener(this);
}
@@ -149,9 +146,8 @@ public class LauncherRecentsView extends RecentsView<BaseQuickstepLauncher>
* Animates adjacent tasks and translate hotseat off screen as well.
*/
@Override
public AnimatorSet createAdjacentPageAnimForTaskLaunch(TaskView tv,
AppWindowAnimationHelper helper) {
AnimatorSet anim = super.createAdjacentPageAnimForTaskLaunch(tv, helper);
public AnimatorSet createAdjacentPageAnimForTaskLaunch(TaskView tv) {
AnimatorSet anim = super.createAdjacentPageAnimForTaskLaunch(tv);
if (!SysUINavigationMode.getMode(mActivity).hasGestures) {
// Hotseat doesn't move when opening recents with the button,
@@ -177,11 +173,6 @@ public class LauncherRecentsView extends RecentsView<BaseQuickstepLauncher>
return anim;
}
@Override
protected void getTaskSize(DeviceProfile dp, Rect outRect) {
LayoutUtils.calculateLauncherTaskSize(getContext(), dp, outRect);
}
@Override
protected void onTaskLaunchAnimationUpdate(float progress, TaskView tv) {
if (ENABLE_QUICKSTEP_LIVE_TILE.get()) {
@@ -284,7 +275,7 @@ public class LauncherRecentsView extends RecentsView<BaseQuickstepLauncher>
// Clean-up logic that occurs when recents is no longer in use/visible.
reset();
}
setOverlayEnabled(finalState == OVERVIEW);
setOverlayEnabled(finalState == OVERVIEW || finalState == OVERVIEW_MODAL_TASK);
setFreezeViewVisibility(false);
}
@@ -42,6 +42,8 @@ import java.lang.annotation.RetentionPolicy;
public class OverviewActionsView<T extends OverlayUICallbacks> extends FrameLayout
implements OnClickListener {
public static final long VISIBILITY_TRANSITION_DURATION_MS = 80;
@IntDef(flag = true, value = {
HIDDEN_UNSUPPORTED_NAVIGATION,
HIDDEN_DISABLED_FEATURE,
@@ -22,6 +22,7 @@ import static com.android.launcher3.LauncherAnimUtils.SCALE_PROPERTY;
import static com.android.launcher3.LauncherAnimUtils.VIEW_ALPHA;
import static com.android.launcher3.LauncherState.BACKGROUND_APP;
import static com.android.launcher3.Utilities.EDGE_NAV_BAR;
import static com.android.launcher3.Utilities.mapToRange;
import static com.android.launcher3.Utilities.squaredHypot;
import static com.android.launcher3.Utilities.squaredTouchSlop;
import static com.android.launcher3.anim.Interpolators.ACCEL;
@@ -70,7 +71,6 @@ import android.text.StaticLayout;
import android.text.TextPaint;
import android.util.AttributeSet;
import android.util.FloatProperty;
import android.util.Log;
import android.util.Property;
import android.util.SparseBooleanArray;
import android.view.HapticFeedbackConstants;
@@ -110,6 +110,7 @@ import com.android.launcher3.userevent.nano.LauncherLogProto.Action.Direction;
import com.android.launcher3.userevent.nano.LauncherLogProto.Action.Touch;
import com.android.launcher3.util.ComponentKey;
import com.android.launcher3.util.DynamicResource;
import com.android.launcher3.util.MultiValueAlpha;
import com.android.launcher3.util.OverScroller;
import com.android.launcher3.util.Themes;
import com.android.launcher3.util.ViewPool;
@@ -123,6 +124,7 @@ import com.android.quickstep.TaskUtils;
import com.android.quickstep.ViewUtils;
import com.android.quickstep.util.AppWindowAnimationHelper;
import com.android.quickstep.util.RecentsOrientedState;
import com.android.quickstep.util.WindowSizeStrategy;
import com.android.systemui.plugins.ResourceProvider;
import com.android.systemui.shared.recents.IPinnedStackAnimationListener;
import com.android.systemui.shared.recents.model.Task;
@@ -173,13 +175,26 @@ public abstract class RecentsView<T extends BaseActivity> extends PagedView impl
}
};
public static final FloatProperty<RecentsView> TASK_MODALNESS =
new FloatProperty<RecentsView>("taskModalness") {
@Override
public void setValue(RecentsView recentsView, float v) {
recentsView.setTaskModalness(v);
}
@Override
public Float get(RecentsView recentsView) {
return recentsView.mTaskModalness;
}
};
public static final FloatProperty<RecentsView> ADJACENT_PAGE_OFFSET =
new FloatProperty<RecentsView>("adjacentPageOffset") {
@Override
public void setValue(RecentsView recentsView, float v) {
if (recentsView.mAdjacentPageOffset != v) {
recentsView.mAdjacentPageOffset = v;
recentsView.updateAdjacentPageOffset();
recentsView.updatePageOffsets();
}
}
@@ -190,6 +205,7 @@ public abstract class RecentsView<T extends BaseActivity> extends PagedView impl
};
protected final RecentsOrientedState mOrientationState;
protected final WindowSizeStrategy mSizeStrategy;
protected RecentsAnimationController mRecentsAnimationController;
protected RecentsAnimationTargets mRecentsAnimationTargets;
protected AppWindowAnimationHelper mAppWindowAnimationHelper;
@@ -200,6 +216,7 @@ public abstract class RecentsView<T extends BaseActivity> extends PagedView impl
protected final Rect mTempRect = new Rect();
protected final RectF mTempRectF = new RectF();
private final PointF mTempPointF = new PointF();
private final float[] mTempFloatPoint = new float[2];
private static final int DISMISS_TASK_DURATION = 300;
private static final int ADDITION_TASK_DURATION = 200;
@@ -213,7 +230,6 @@ public abstract class RecentsView<T extends BaseActivity> extends PagedView impl
private final ClearAllButton mClearAllButton;
private final Rect mClearAllButtonDeadZoneRect = new Rect();
private final Rect mTaskViewDeadZoneRect = new Rect();
protected final AppWindowAnimationHelper mTempAppWindowAnimationHelper;
private final ScrollState mScrollState = new ScrollState();
// Keeps track of the previously known visible tasks for purposes of loading/unloading task data
@@ -327,6 +343,12 @@ public abstract class RecentsView<T extends BaseActivity> extends PagedView impl
protected float mContentAlpha = 1;
@ViewDebug.ExportedProperty(category = "launcher")
protected float mFullscreenProgress = 0;
/**
* How modal is the current task to be displayed, 1 means the task is fully modal and no other
* tasks are show. 0 means the task is displays in context in the list with other tasks.
*/
@ViewDebug.ExportedProperty(category = "launcher")
protected float mTaskModalness = 0;
// Keeps track of task id whose visual state should not be reset
private int mIgnoreResetTaskId = -1;
@@ -355,20 +377,19 @@ public abstract class RecentsView<T extends BaseActivity> extends PagedView impl
};
public RecentsView(Context context, AttributeSet attrs, int defStyleAttr,
boolean rotationSupportedByActivity) {
WindowSizeStrategy sizeStrategy) {
super(context, attrs, defStyleAttr);
setPageSpacing(getResources().getDimensionPixelSize(R.dimen.recents_page_spacing));
setEnableFreeScroll(true);
mSizeStrategy = sizeStrategy;
mOrientationState = new RecentsOrientedState(
context, rotationSupportedByActivity, this::animateRecentsRotationInPlace);
context, mSizeStrategy, this::animateRecentsRotationInPlace);
mFastFlingVelocity = getResources()
.getDimensionPixelSize(R.dimen.recents_fast_fling_velocity);
mActivity = BaseActivity.fromContext(context);
mModel = RecentsModel.INSTANCE.get(context);
mIdp = InvariantDeviceProfile.INSTANCE.get(context);
mTempAppWindowAnimationHelper =
new AppWindowAnimationHelper(getPagedViewOrientedState(), context);
mClearAllButton = (ClearAllButton) LayoutInflater.from(context)
.inflate(R.layout.overview_clear_all_button, this, false);
@@ -619,7 +640,7 @@ public abstract class RecentsView<T extends BaseActivity> extends PagedView impl
case MotionEvent.ACTION_DOWN:
// Touch down anywhere but the deadzone around the visible clear all button and
// between the task views will start home on touch up
if (!isHandlingTouch()) {
if (!isHandlingTouch() && !isModal()) {
if (mShowEmptyMessage) {
mTouchDownToStartHome = true;
} else {
@@ -647,7 +668,7 @@ public abstract class RecentsView<T extends BaseActivity> extends PagedView impl
@Override
protected void determineScrollingStart(MotionEvent ev, float touchSlopScale) {
// Enables swiping to the left or right only if the task overlay is not modal.
if (getCurrentPageTaskView() == null || !getCurrentPageTaskView().isTaskOverlayModal()) {
if (!isModal()) {
super.determineScrollingStart(ev, touchSlopScale);
}
}
@@ -694,7 +715,7 @@ public abstract class RecentsView<T extends BaseActivity> extends PagedView impl
final int pageIndex = requiredTaskCount - i - 1 + mTaskViewStartIndex;
final Task task = tasks.get(i);
final TaskView taskView = (TaskView) getChildAt(pageIndex);
taskView.bind(task, mOrientationState, mActivity.getDeviceProfile().isMultiWindowMode);
taskView.bind(task, mOrientationState);
}
if (mNextPage == INVALID_PAGE) {
@@ -718,6 +739,10 @@ public abstract class RecentsView<T extends BaseActivity> extends PagedView impl
updateEnabledOverlays();
}
private boolean isModal() {
return mTaskModalness > 0;
}
private void removeTasksViewsAndClearAllButton() {
for (int i = getTaskViewCount() - 1; i >= 0; i--) {
removeView(getTaskViewAt(i));
@@ -735,25 +760,6 @@ public abstract class RecentsView<T extends BaseActivity> extends PagedView impl
return taskViewCount;
}
/**
* Updates UI for a modal task, including hiding other tasks.
*/
public void updateUiForModalTask(TaskView taskView, boolean isTaskOverlayModal) {
int currentIndex = indexOfChild(taskView);
TaskView previousTask = getTaskViewAt(currentIndex - 1);
TaskView nextTask = getTaskViewAt(currentIndex + 1);
float alpha = isTaskOverlayModal ? 0.0f : 1.0f;
if (previousTask != null) {
previousTask.animate().alpha(alpha)
.translationX(isTaskOverlayModal ? previousTask.getWidth() / 2 : 0);
}
if (nextTask != null) {
nextTask.animate().alpha(alpha)
.translationX(isTaskOverlayModal ? -nextTask.getWidth() / 2 : 0);
}
}
protected void onTaskStackUpdated() { }
public void resetTaskVisuals() {
@@ -776,6 +782,7 @@ public abstract class RecentsView<T extends BaseActivity> extends PagedView impl
updateCurveProperties();
// Update the set of visible task's data
loadVisibleTaskData();
setTaskModalness(0);
}
public void setFullscreenProgress(float fullscreenProgress) {
@@ -784,7 +791,10 @@ public abstract class RecentsView<T extends BaseActivity> extends PagedView impl
for (int i = 0; i < taskCount; i++) {
getTaskViewAt(i).setFullscreenProgress(mFullscreenProgress);
}
mActionsView.updateHiddenFlags(HIDDEN_FULLESCREEN_PROGRESS, fullscreenProgress > 0);
// Fade out the actions view quickly (0.1 range)
mActionsView.getVisibilityAlpha().setValue(
mapToRange(fullscreenProgress, 0, 0.1f, 1f, 0f, LINEAR));
mActionsView.updateHiddenFlags(HIDDEN_FULLESCREEN_PROGRESS, fullscreenProgress == 1.0f);
}
private void updateTaskStackListenerState() {
@@ -802,7 +812,8 @@ public abstract class RecentsView<T extends BaseActivity> extends PagedView impl
public void setInsets(Rect insets) {
mInsets.set(insets);
DeviceProfile dp = mActivity.getDeviceProfile();
getTaskSize(dp, mTempRect);
mOrientationState.setMultiWindowMode(dp.isMultiWindowMode);
getTaskSize(mTempRect);
mTaskWidth = mTempRect.width();
mTaskHeight = mTempRect.height();
@@ -812,10 +823,8 @@ public abstract class RecentsView<T extends BaseActivity> extends PagedView impl
dp.heightPx - mInsets.bottom - mTempRect.bottom);
}
protected abstract void getTaskSize(DeviceProfile dp, Rect outRect);
public void getTaskSize(Rect outRect) {
getTaskSize(mActivity.getDeviceProfile(), outRect);
mSizeStrategy.calculateTaskSize(mActivity, mActivity.getDeviceProfile(), outRect);
}
@Override
@@ -1044,7 +1053,7 @@ public abstract class RecentsView<T extends BaseActivity> extends PagedView impl
}
setRunningTaskHidden(false);
animateUpRunningTaskIconScale();
mActionsView.updateHiddenFlags(HIDDEN_GESTURE_RUNNING, false);
animateActionsViewIn();
}
/**
@@ -1068,8 +1077,7 @@ public abstract class RecentsView<T extends BaseActivity> extends PagedView impl
new ComponentName(getContext(), getClass()), 0, 0), null, null, "", "", 0, 0,
false, true, false, false, new ActivityManager.TaskDescription(), 0,
new ComponentName("", ""), false);
taskView.bind(mTmpRunningTask, mOrientationState,
mActivity.getDeviceProfile().isMultiWindowMode);
taskView.bind(mTmpRunningTask, mOrientationState);
}
boolean runningTaskTileHidden = mRunningTaskTileHidden;
@@ -1158,6 +1166,14 @@ public abstract class RecentsView<T extends BaseActivity> extends PagedView impl
}
}
private void animateActionsViewIn() {
mActionsView.updateHiddenFlags(HIDDEN_GESTURE_RUNNING, false);
ObjectAnimator anim = ObjectAnimator.ofFloat(
mActionsView.getVisibilityAlpha(), MultiValueAlpha.VALUE, 1);
anim.setDuration(OverviewActionsView.VISIBILITY_TRANSITION_DURATION_MS);
anim.start();
}
public void animateUpRunningTaskIconScale() {
animateUpRunningTaskIconScale(0);
}
@@ -1653,21 +1669,28 @@ public abstract class RecentsView<T extends BaseActivity> extends PagedView impl
mTempRect, mActivity.getDeviceProfile(), mTempPointF);
setPivotX(mTempPointF.x);
setPivotY(mTempPointF.y);
updateAdjacentPageOffset();
setTaskModalness(mTaskModalness);
updatePageOffsets();
}
private void updateAdjacentPageOffset() {
private void updatePageOffsets() {
float offset = mAdjacentPageOffset * getWidth();
float modalOffset = mTaskModalness * getWidth();
if (mIsRtl) {
offset = -offset;
modalOffset = -modalOffset;
}
int count = getChildCount();
TaskView runningTask = mRunningTaskId == -1 ? null : getTaskView(mRunningTaskId);
int midPoint = runningTask == null ? -1 : indexOfChild(runningTask);
int currentPage = getCurrentPage();
for (int i = 0; i < count; i++) {
getChildAt(i).setTranslationX(i == midPoint ? 0 : (i < midPoint ? -offset : offset));
float translation = i == midPoint ? 0 : (i < midPoint ? -offset : offset);
float modalTranslation =
i == currentPage ? 0 : (i < currentPage ? -modalOffset : modalOffset);
getChildAt(i).setTranslationX(translation + modalTranslation);
}
updateCurveProperties();
}
@@ -1750,15 +1773,14 @@ public abstract class RecentsView<T extends BaseActivity> extends PagedView impl
* If launching one of the adjacent tasks, parallax the center task and other adjacent task
* to the right.
*/
public AnimatorSet createAdjacentPageAnimForTaskLaunch(
TaskView tv, AppWindowAnimationHelper appWindowAnimationHelper) {
public AnimatorSet createAdjacentPageAnimForTaskLaunch(TaskView tv) {
AnimatorSet anim = new AnimatorSet();
int taskIndex = indexOfChild(tv);
int centerTaskIndex = getCurrentPage();
boolean launchingCenterTask = taskIndex == centerTaskIndex;
float toScale = appWindowAnimationHelper.getSrcToTargetScale();
float toScale = getMaxScaleForFullScreen();
if (launchingCenterTask) {
RecentsView recentsView = tv.getRecentsView();
anim.play(ObjectAnimator.ofFloat(recentsView, SCALE_PROPERTY, toScale));
@@ -1780,6 +1802,15 @@ public abstract class RecentsView<T extends BaseActivity> extends PagedView impl
return anim;
}
/**
* Returns the scale up required on the view, so that it coves the screen completely
*/
public float getMaxScaleForFullScreen() {
getTaskSize(mTempRect);
return getPagedViewOrientedState().getFullScreenScaleAndPivot(
mTempRect, mActivity.getDeviceProfile(), mTempPointF);
}
public PendingAnimation createTaskLaunchAnimation(
TaskView tv, long duration, Interpolator interpolator) {
if (FeatureFlags.IS_STUDIO_BUILD && mPendingAnimation != null) {
@@ -1814,11 +1845,7 @@ public abstract class RecentsView<T extends BaseActivity> extends PagedView impl
}
});
AppWindowAnimationHelper appWindowAnimationHelper = new AppWindowAnimationHelper(
getPagedViewOrientedState(), mActivity);
appWindowAnimationHelper.fromTaskThumbnailView(tv.getThumbnail(), this);
appWindowAnimationHelper.prepareAnimation(mActivity.getDeviceProfile(), true /* isOpening */);
AnimatorSet anim = createAdjacentPageAnimForTaskLaunch(tv, appWindowAnimationHelper);
AnimatorSet anim = createAdjacentPageAnimForTaskLaunch(tv);
DepthController depthController = getDepthController();
if (depthController != null) {
@@ -2073,10 +2100,6 @@ public abstract class RecentsView<T extends BaseActivity> extends PagedView impl
return mAppWindowAnimationHelper;
}
public AppWindowAnimationHelper getTempAppWindowAnimationHelper() {
return mTempAppWindowAnimationHelper;
}
public AppWindowAnimationHelper.TransformParams getLiveTileParams(
boolean mightNeedToRefill) {
return null;
@@ -2113,6 +2136,30 @@ public abstract class RecentsView<T extends BaseActivity> extends PagedView impl
}
}
/**
* The current task is fully modal (modalness = 1) when it is shown on its own in a modal
* way. Modalness 0 means the task is shown in context with all the other tasks.
*/
private void setTaskModalness(float modalness) {
mTaskModalness = modalness;
updatePageOffsets();
if (getCurrentPageTaskView() != null) {
getCurrentPageTaskView().setModalness(modalness);
TaskView tv = getCurrentPageTaskView();
// Move the task view up as it scales...
// ...the icon on taskview is hidden in modal state, so consider the top of the task
mTempFloatPoint[0] = 0;
mTempFloatPoint[1] = tv.getTop() + mTaskTopMargin;
// ...find the top after the transformation
getMatrix().mapPoints(mTempFloatPoint);
// ...make it match the top inset
float calcOffset = (mInsets.top - mTempFloatPoint[1]) * mTaskModalness;
tv.setTranslationY(calcOffset);
}
}
@Nullable
protected DepthController getDepthController() {
return null;
@@ -239,7 +239,8 @@ public class TaskMenuView extends AbstractFloatingView {
setLayoutParams(params);
setScaleX(taskView.getScaleX());
setScaleY(taskView.getScaleY());
mOptionLayout.setOrientation(orientationHandler.getTaskMenuLayoutOrientation());
mOptionLayout.setOrientation(orientationHandler
.getTaskMenuLayoutOrientation(mOptionLayout));
setPosition(sTempRect.left - insets.left, sTempRect.top - insets.top,
taskView.getPagedOrientationHandler());
}
@@ -36,12 +36,12 @@ import android.graphics.RectF;
import android.graphics.Shader;
import android.util.AttributeSet;
import android.util.FloatProperty;
import android.util.Log;
import android.util.Property;
import android.view.Surface;
import android.view.View;
import com.android.launcher3.BaseActivity;
import com.android.launcher3.DeviceProfile;
import com.android.launcher3.R;
import com.android.launcher3.Utilities;
import com.android.launcher3.uioverrides.plugins.PluginManagerWrapper;
@@ -104,7 +104,6 @@ public class TaskThumbnailView extends View implements PluginListener<OverviewSc
private boolean mOverlayEnabled;
private OverviewScreenshotActions mOverviewScreenshotActionsPlugin;
private boolean mIsMultiWindowMode;
public TaskThumbnailView(Context context) {
this(context, null);
@@ -126,8 +125,11 @@ public class TaskThumbnailView extends View implements PluginListener<OverviewSc
mPreviewPositionHelper = new PreviewPositionHelper(context);
}
public void bind(Task task, boolean isMultiWindowMode) {
mIsMultiWindowMode = isMultiWindowMode;
/**
* Updates the thumbnail to draw the provided task
* @param task
*/
public void bind(Task task) {
mOverlay.reset();
mTask = task;
int color = task == null ? Color.BLACK : task.colorBackground | 0xFF000000;
@@ -193,11 +195,6 @@ public class TaskThumbnailView extends View implements PluginListener<OverviewSc
updateThumbnailPaintFilter();
}
public void setSaturation(float saturation) {
mSaturation = saturation;
updateThumbnailPaintFilter();
}
public TaskOverlay getTaskOverlay() {
return mOverlay;
}
@@ -353,7 +350,7 @@ public class TaskThumbnailView extends View implements PluginListener<OverviewSc
mPreviewRect.set(0, 0, mThumbnailData.thumbnail.getWidth(),
mThumbnailData.thumbnail.getHeight());
mPreviewPositionHelper.updateThumbnailMatrix(mPreviewRect, mThumbnailData,
mIsMultiWindowMode, getMeasuredWidth(), getMeasuredHeight());
getMeasuredWidth(), getMeasuredHeight(), mActivity.getDeviceProfile());
mBitmapShader.setLocalMatrix(mPreviewPositionHelper.mMatrix);
mPaint.setShader(mBitmapShader);
@@ -439,13 +436,14 @@ public class TaskThumbnailView extends View implements PluginListener<OverviewSc
* Updates the matrix based on the provided parameters
*/
public void updateThumbnailMatrix(Rect thumbnailPosition, ThumbnailData thumbnailData,
boolean isInMultiWindowMode, int canvasWidth, int canvasHeight) {
int canvasWidth, int canvasHeight, DeviceProfile dp) {
boolean isRotated = false;
boolean isOrientationDifferent;
mClipBottom = -1;
float scale = thumbnailData.scale;
Rect thumbnailInsets = thumbnailData.insets;
Rect activityInsets = dp.getInsets();
Rect thumbnailInsets = getBoundedInsets(activityInsets, thumbnailData.insets);
final float thumbnailWidth = thumbnailPosition.width()
- (thumbnailInsets.left + thumbnailInsets.right) * scale;
final float thumbnailHeight = thumbnailPosition.height()
@@ -456,8 +454,9 @@ public class TaskThumbnailView extends View implements PluginListener<OverviewSc
int currentRotation = getCurrentRotation();
int deltaRotate = getRotationDelta(currentRotation, thumbnailRotation);
Rect deviceInsets = dp.getInsets();
// Landscape vs portrait change
boolean windowingModeSupportsRotation = !isInMultiWindowMode
boolean windowingModeSupportsRotation = !dp.isMultiWindowMode
&& thumbnailData.windowingMode == WINDOWING_MODE_FULLSCREEN;
isOrientationDifferent = isOrientationChange(deltaRotate)
&& windowingModeSupportsRotation;
@@ -476,9 +475,10 @@ public class TaskThumbnailView extends View implements PluginListener<OverviewSc
if (!isRotated) {
// No Rotation
mClippedInsets.offsetTo(thumbnailInsets.left * scale,
thumbnailInsets.top * scale);
mMatrix.setTranslate(-mClippedInsets.left, -mClippedInsets.top);
mClippedInsets.offsetTo(deviceInsets.left * scale, deviceInsets.top * scale);
mMatrix.setTranslate(
-thumbnailInsets.left * scale,
-thumbnailInsets.top * scale);
} else {
setThumbnailRotation(deltaRotate, thumbnailInsets, scale, thumbnailPosition);
}
@@ -495,8 +495,16 @@ public class TaskThumbnailView extends View implements PluginListener<OverviewSc
}
mClippedInsets.left *= thumbnailScale;
mClippedInsets.top *= thumbnailScale;
mClippedInsets.right = widthWithInsets - mClippedInsets.left - canvasWidth;
mClippedInsets.bottom = heightWithInsets - mClippedInsets.top - canvasHeight;
if (dp.isMultiWindowMode) {
mClippedInsets.right = deviceInsets.right * scale * thumbnailScale;
mClippedInsets.bottom = deviceInsets.bottom * scale * thumbnailScale;
} else {
mClippedInsets.right = Math.max(0,
widthWithInsets - mClippedInsets.left - canvasWidth);
mClippedInsets.bottom = Math.max(0,
heightWithInsets - mClippedInsets.top - canvasHeight);
}
mMatrix.postScale(thumbnailScale, thumbnailScale);
@@ -508,6 +516,13 @@ public class TaskThumbnailView extends View implements PluginListener<OverviewSc
mIsOrientationChanged = isOrientationDifferent;
}
private Rect getBoundedInsets(Rect activityInsets, Rect insets) {
return new Rect(Math.min(insets.left, activityInsets.left),
Math.min(insets.top, activityInsets.top),
Math.min(insets.right, activityInsets.right),
Math.min(insets.bottom, activityInsets.bottom));
}
private int getRotationDelta(int oldRotation, int newRotation) {
int delta = newRotation - oldRotation;
if (delta < 0) delta += 4;
@@ -557,9 +572,8 @@ public class TaskThumbnailView extends View implements PluginListener<OverviewSc
/**
* Insets to used for clipping the thumbnail (in case it is drawing outside its own space)
*/
public RectF getInsetsToDrawInFullscreen(boolean isMultiWindowMode) {
// Don't show insets in multi window mode.
return isMultiWindowMode ? EMPTY_RECT_F : mClippedInsets;
public RectF getInsetsToDrawInFullscreen() {
return mClippedInsets;
}
}
}
@@ -25,6 +25,7 @@ import static android.view.Gravity.TOP;
import static android.widget.Toast.LENGTH_SHORT;
import static com.android.launcher3.QuickstepAppTransitionManagerImpl.RECENTS_LAUNCH_DURATION;
import static com.android.launcher3.Utilities.comp;
import static com.android.launcher3.anim.Interpolators.FAST_OUT_SLOW_IN;
import static com.android.launcher3.anim.Interpolators.LINEAR;
import static com.android.launcher3.anim.Interpolators.TOUCH_RESPONSE_INTERPOLATOR;
@@ -165,10 +166,10 @@ public class TaskView extends FrameLayout implements PageCallbacks, Reusable {
private ObjectAnimator mIconAndDimAnimator;
private float mIconScaleAnimStartProgress = 0;
private float mFocusTransitionProgress = 1;
private float mModalness = 0;
private float mStableAlpha = 1;
private boolean mShowScreenshot;
private boolean mRunningModalAnimation = false;
// The current background requests to load the task thumbnail and icon
private TaskThumbnailCache.ThumbnailLoadRequest mThumbnailLoadRequest;
@@ -239,59 +240,24 @@ public class TaskView extends FrameLayout implements PageCallbacks, Reusable {
mIconView = findViewById(R.id.icon);
}
public boolean isTaskOverlayModal() {
return mSnapshotView.getTaskOverlay().isOverlayModal();
}
/** Updates UI based on whether the task is modal. */
public void updateUiForModalTask() {
boolean isOverlayModal = isTaskOverlayModal();
mRunningModalAnimation = true;
if (getRecentsView() != null) {
getRecentsView().updateUiForModalTask(this, isOverlayModal);
/**
* The modalness of this view is how it should be displayed when it is shown on its own in the
* modal state of overview.
*
* @param modalness [0, 1] 0 being in context with other tasks, 1 being shown on its own.
*/
public void setModalness(float modalness) {
mModalness = modalness;
mIconView.setAlpha(comp(modalness));
if (mContextualChip != null) {
mContextualChip.setScaleX(comp(modalness));
mContextualChip.setScaleY(comp(modalness));
}
if (mContextualChipWrapper != null) {
mContextualChipWrapper.setAlpha(comp(modalness));
}
// Hides footers and icon when overlay is modal.
if (isOverlayModal) {
for (FooterWrapper footer : mFooters) {
if (footer != null) {
footer.animateHide();
}
}
if (mContextualChipWrapper != null) {
mContextualChipWrapper.animate().alpha(0f).setDuration(300);
}
if (mContextualChip != null) {
mContextualChip.animate().scaleX(0f).scaleY(0f).setDuration(300);
}
mIconView.animate().alpha(0.0f);
} else {
if (mContextualChip != null) {
mContextualChip.animate().scaleX(1f).scaleY(1f).setDuration(300);
}
if (mContextualChipWrapper != null) {
mContextualChipWrapper.animate().alpha(1f).setDuration(300);
}
mIconView.animate().alpha(1.0f);
}
// Sets animations for modal UI. We will remove the margins to zoom in the snapshot.
float topMargin = getResources().getDimension(R.dimen.task_thumbnail_top_margin);
float bottomMargin =
getResources().getDimension(R.dimen.task_thumbnail_bottom_margin_with_actions);
float newHeight = mSnapshotView.getHeight() + topMargin + bottomMargin;
float scale = isOverlayModal ? newHeight / mSnapshotView.getHeight() : 1.0f;
float centerDifference = (bottomMargin - topMargin) / 2;
float translationY = isOverlayModal ? centerDifference : 0;
this.animate().scaleX(scale).scaleY(scale).translationY(translationY)
.withEndAction(new Runnable() {
@Override
public void run() {
setCurveScale(scale);
mRunningModalAnimation = false;
}
});
updateFooterVerticalOffset(mFooterVerticalOffset);
}
public TaskMenuView getMenuView() {
@@ -308,10 +274,10 @@ public class TaskView extends FrameLayout implements PageCallbacks, Reusable {
* TODO(b/142282126) Re-evaluate if we need to pass in isMultiWindowMode after
* that issue is fixed
*/
public void bind(Task task, RecentsOrientedState orientedState, boolean isMultiWindowMode) {
public void bind(Task task, RecentsOrientedState orientedState) {
cancelPendingLoadTasks();
mTask = task;
mSnapshotView.bind(task, isMultiWindowMode);
mSnapshotView.bind(task);
setOrientationState(orientedState);
}
@@ -482,14 +448,12 @@ public class TaskView extends FrameLayout implements PageCallbacks, Reusable {
}
public void setOrientationState(RecentsOrientedState orientationState) {
int iconRotation = orientationState.getTouchRotation();
PagedOrientationHandler orientationHandler = orientationState.getOrientationHandler();
boolean isRtl = orientationHandler.getRecentsRtlSetting(getResources());
LayoutParams snapshotParams = (LayoutParams) mSnapshotView.getLayoutParams();
int thumbnailPadding = (int) getResources().getDimension(R.dimen.task_thumbnail_top_margin);
LayoutParams iconParams = (LayoutParams) mIconView.getLayoutParams();
int rotation = orientationState.getTouchRotationDegrees();
switch (iconRotation) {
switch (orientationHandler.getRotation()) {
case Surface.ROTATION_90:
iconParams.gravity = (isRtl ? END : START) | CENTER_VERTICAL;
iconParams.rightMargin = -thumbnailPadding;
@@ -514,7 +478,7 @@ public class TaskView extends FrameLayout implements PageCallbacks, Reusable {
break;
}
mIconView.setLayoutParams(iconParams);
mIconView.setRotation(rotation);
mIconView.setRotation(orientationHandler.getDegreesRotated());
if (mMenuView != null) {
mMenuView.onRotationChanged();
@@ -535,12 +499,7 @@ public class TaskView extends FrameLayout implements PageCallbacks, Reusable {
mIconView.setScaleX(scale);
mIconView.setScaleY(scale);
mFooterVerticalOffset = 1.0f - scale;
for (FooterWrapper footer : mFooters) {
if (footer != null) {
footer.updateFooterOffset();
}
}
updateFooterVerticalOffset(1.0f - scale);
}
public void setIconScaleAnimStartProgress(float startProgress) {
@@ -586,6 +545,7 @@ public class TaskView extends FrameLayout implements PageCallbacks, Reusable {
public void resetVisualProperties() {
resetViewTransforms();
setFullscreenProgress(0);
setModalness(0);
}
public void setStableAlpha(float parentAlpha) {
@@ -606,7 +566,7 @@ public class TaskView extends FrameLayout implements PageCallbacks, Reusable {
@Override
public void onPageScroll(ScrollState scrollState) {
// Don't do anything if it's modal.
if (mRunningModalAnimation || isTaskOverlayModal()) {
if (mModalness > 0) {
return;
}
@@ -709,7 +669,7 @@ public class TaskView extends FrameLayout implements PageCallbacks, Reusable {
mContextualChip.setScaleY(0f);
GradientDrawable scrimDrawable = (GradientDrawable) getResources().getDrawable(
R.drawable.chip_scrim_gradient, mActivity.getTheme());
float cornerRadius = TaskCornerRadius.get(mActivity);
float cornerRadius = getTaskCornerRadius();
scrimDrawable.setCornerRadii(
new float[]{0, 0, 0, 0, cornerRadius, cornerRadius, cornerRadius,
cornerRadius});
@@ -728,6 +688,10 @@ public class TaskView extends FrameLayout implements PageCallbacks, Reusable {
}
}
public float getTaskCornerRadius() {
return TaskCornerRadius.get(mActivity);
}
/**
* Clears the contextual chip from TaskView.
*
@@ -759,6 +723,12 @@ public class TaskView extends FrameLayout implements PageCallbacks, Reusable {
mStackHeight += footer.mView.getHeight();
}
}
updateFooterVerticalOffset(0);
}
private void updateFooterVerticalOffset(float offset) {
mFooterVerticalOffset = offset;
for (FooterWrapper footer : mFooters) {
if (footer != null) {
footer.updateFooterOffset();
@@ -857,7 +827,8 @@ public class TaskView extends FrameLayout implements PageCallbacks, Reusable {
}
void updateFooterOffset() {
mAnimationOffset = Math.round(mStackHeight * mFooterVerticalOffset);
float offset = Utilities.or(mFooterVerticalOffset, mModalness);
mAnimationOffset = Math.round(mStackHeight * offset);
mView.setTranslationY(mAnimationOffset + mEntryAnimationOffset
+ mCurrentFullscreenParams.mCurrentDrawnInsets.bottom
+ mCurrentFullscreenParams.mCurrentDrawnInsets.top);
@@ -880,22 +851,6 @@ public class TaskView extends FrameLayout implements PageCallbacks, Reusable {
animator.setDuration(100);
animator.start();
}
void animateHide() {
ValueAnimator animator = ValueAnimator.ofFloat(0.0f, 1.0f);
animator.addUpdateListener(anim -> {
mFooterVerticalOffset = anim.getAnimatedFraction();
updateFooterOffset();
});
animator.addListener(new AnimatorListenerAdapter() {
@Override
public void onAnimationEnd(Animator animation) {
removeView(mView);
}
});
animator.setDuration(100);
animator.start();
}
}
private int getExpectedViewHeight(View view) {
@@ -1064,14 +1019,13 @@ public class TaskView extends FrameLayout implements PageCallbacks, Reusable {
*/
public void setProgress(float fullscreenProgress, float parentScale, int previewWidth,
DeviceProfile dp, PreviewPositionHelper pph) {
boolean isMultiWindowMode = dp.isMultiWindowMode;
RectF insets = pph.getInsetsToDrawInFullscreen(isMultiWindowMode);
RectF insets = pph.getInsetsToDrawInFullscreen();
float currentInsetsLeft = insets.left * fullscreenProgress;
float currentInsetsRight = insets.right * fullscreenProgress;
mCurrentDrawnInsets.set(currentInsetsLeft, insets.top * fullscreenProgress,
currentInsetsRight, insets.bottom * fullscreenProgress);
float fullscreenCornerRadius = isMultiWindowMode ? 0 : mWindowCornerRadius;
float fullscreenCornerRadius = dp.isMultiWindowMode ? 0 : mWindowCornerRadius;
mCurrentDrawnCornerRadius =
Utilities.mapRange(fullscreenProgress, mCornerRadius, fullscreenCornerRadius)
@@ -0,0 +1,989 @@
<animated-vector xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:aapt="http://schemas.android.com/aapt">
<aapt:attr name="android:drawable">
<vector
android:width="412dp"
android:height="890dp"
android:viewportWidth="412"
android:viewportHeight="890">
<group android:name="_R_G">
<group
android:name="_R_G_L_4_G_N_2_N_3_N_4_T_1"
android:rotation="-10"
android:translateX="661.757"
android:translateY="1026.235">
<group
android:name="_R_G_L_4_G_N_2_N_3_N_4_T_0"
android:translateX="-148.438"
android:translateY="-239.65">
<group
android:name="_R_G_L_4_G_N_2_N_3_T_0"
android:translateX="-61.73500000000001"
android:translateY="38.257000000000005">
<group
android:name="_R_G_L_4_G_N_2_T_0"
android:pivotX="83.124"
android:pivotY="89.259"
android:rotation="-16"
android:translateX="-50.44799999999999"
android:translateY="-62.925">
<group
android:name="_R_G_L_4_G"
android:translateX="-18.21"
android:translateY="-17.394">
<path
android:name="_R_G_L_4_G_D_0_P_0"
android:fillAlpha="0"
android:fillColor="#e8f0fe"
android:fillType="nonZero"
android:pathData=" M96.25 48.25 C96.25,74.76 74.76,96.25 48.25,96.25 C21.74,96.25 0.25,74.76 0.25,48.25 C0.25,21.74 21.74,0.25 48.25,0.25 C74.76,0.25 96.25,21.74 96.25,48.25c " />
</group>
</group>
</group>
</group>
</group>
<group
android:name="_R_G_L_3_G"
android:pivotX="48.25"
android:pivotY="48.25"
android:rotation="11"
android:translateX="227.046"
android:translateY="642.467">
<path
android:name="_R_G_L_3_G_D_0_P_0"
android:fillAlpha="1"
android:fillColor="#e8f0fe"
android:fillType="nonZero"
android:pathData=" M96.25 48.25 C96.25,74.76 74.76,96.25 48.25,96.25 C21.74,96.25 0.25,74.76 0.25,48.25 C0.25,21.74 21.74,0.25 48.25,0.25 C74.76,0.25 96.25,21.74 96.25,48.25c " />
</group>
<group
android:name="_R_G_L_2_G_T_1"
android:rotation="-10"
android:translateX="661.757"
android:translateY="1026.235">
<group
android:name="_R_G_L_2_G"
android:translateX="-148.438"
android:translateY="-239.65">
<path
android:name="_R_G_L_2_G_D_0_P_0"
android:fillAlpha="1"
android:fillColor="#d2e3fc"
android:fillType="nonZero"
android:pathData=" M14.25 224.54 C40.46,320.73 128.6,415.05 212.61,415.05 C296.63,415.05 188.65,199.66 188.65,99.96 C188.65,0.25 122.97,160.22 18.3,95.88 C1.02,85.21 0.25,173.17 14.25,224.54c " />
</group>
</group>
<group
android:name="_R_G_L_1_G_N_4_T_1"
android:rotation="-10"
android:translateX="661.757"
android:translateY="1026.235">
<group
android:name="_R_G_L_1_G_N_4_T_0"
android:translateX="-148.438"
android:translateY="-239.65">
<group
android:name="_R_G_L_1_G"
android:translateX="-61.73500000000001"
android:translateY="38.257000000000005">
<path
android:name="_R_G_L_1_G_D_0_P_0"
android:fillAlpha="1"
android:fillColor="#d2e3fc"
android:fillType="nonZero"
android:pathData=" M60.8 0.25 C60.8,0.25 76.32,20.36 105.56,60.3 C134.8,100.25 207.8,82.25 207.8,82.25 C207.8,82.25 211.01,150.18 211.01,150.18 C211.01,150.18 81.43,193.5 81.43,193.5 C81.43,193.5 31.8,174.25 31.8,174.25 C31.8,174.25 27.8,109.25 22.8,89.25 C17.8,69.25 6.15,49.9 2.17,41.17 C0.25,36.95 13.88,27.25 28.48,18.35 C44.09,8.84 60.8,0.25 60.8,0.25c " />
</group>
</group>
</group>
<group
android:name="_R_G_L_0_G_N_3_N_4_T_1"
android:rotation="-10"
android:translateX="661.757"
android:translateY="1026.235">
<group
android:name="_R_G_L_0_G_N_3_N_4_T_0"
android:translateX="-148.438"
android:translateY="-239.65">
<group
android:name="_R_G_L_0_G_N_3_T_0"
android:translateX="-61.73500000000001"
android:translateY="38.257000000000005">
<group
android:name="_R_G_L_0_G"
android:pivotX="83.124"
android:pivotY="89.259"
android:rotation="-16"
android:translateX="-50.44799999999999"
android:translateY="-62.925">
<path
android:name="_R_G_L_0_G_D_0_P_0"
android:fillAlpha="1"
android:fillColor="#d2e3fc"
android:fillType="nonZero"
android:pathData=" M19.19 14.59 C40.48,0.25 55.28,10.31 73.92,28.68 C92.56,47.05 106.44,53.33 112.22,64.44 C118,75.56 76.45,102.74 64.42,104.51 C52.38,106.27 30.98,101.06 19.76,76.77 C8.07,51.48 0.54,27.15 19.19,14.59c " />
<path
android:name="_R_G_L_0_G_D_1_P_0"
android:pathData=" M57.29 26.52 C59.8,29.86 61.05,33.88 55.15,38.41 C55.15,38.41 49.91,42.03 36.73,51.93 C34.96,53.26 32.72,55.37 30.64,55.46 C28.92,55.55 26.91,54.65 25.14,51.9 C19.1,42.49 15,36.09 17.17,30.02 "
android:strokeWidth="6"
android:strokeAlpha="1"
android:strokeColor="#a0c2f9" />
<path
android:name="_R_G_L_0_G_D_2_P_0"
android:pathData=" M64.41 90.04 C64.41,90.04 69.67,62.88 99.15,59.26 "
android:strokeWidth="6"
android:strokeAlpha="1"
android:strokeColor="#a0c2f9" />
</group>
</group>
</group>
</group>
</group>
<group android:name="time_group" />
</vector>
</aapt:attr>
<target android:name="_R_G_L_4_G_D_0_P_0">
<aapt:attr name="android:animation">
<set android:ordering="together">
<objectAnimator
android:duration="333"
android:propertyName="fillAlpha"
android:startOffset="0"
android:valueFrom="0"
android:valueTo="0"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.167,0.167 0.833,0.833 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="233"
android:propertyName="fillAlpha"
android:startOffset="333"
android:valueFrom="0"
android:valueTo="1"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.167,0.167 0.833,0.833 1.0,1.0" />
</aapt:attr>
</objectAnimator>
</set>
</aapt:attr>
</target>
<target android:name="_R_G_L_4_G_N_2_T_0">
<aapt:attr name="android:animation">
<set android:ordering="together">
<objectAnimator
android:duration="450"
android:propertyName="rotation"
android:startOffset="0"
android:valueFrom="-16"
android:valueTo="-16"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.4,0 0.2,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="783"
android:propertyName="rotation"
android:startOffset="450"
android:valueFrom="-16"
android:valueTo="11"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.4,0 0.2,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="450"
android:propertyName="rotation"
android:startOffset="1233"
android:valueFrom="11"
android:valueTo="11"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.167,0 0.833,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="1400"
android:propertyName="rotation"
android:startOffset="1683"
android:valueFrom="11"
android:valueTo="-16"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.167,0 0.205,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
</set>
</aapt:attr>
</target>
<target android:name="_R_G_L_4_G_N_2_N_3_N_4_T_1">
<aapt:attr name="android:animation">
<set android:ordering="together">
<objectAnimator
android:duration="333"
android:propertyName="translateX"
android:startOffset="0"
android:valueFrom="661.757"
android:valueTo="661.757"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.4,0 0.2,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="900"
android:propertyName="translateX"
android:startOffset="333"
android:valueFrom="661.757"
android:valueTo="493.757"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.4,0 0.2,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="450"
android:propertyName="translateX"
android:startOffset="1233"
android:valueFrom="493.757"
android:valueTo="497.757"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.167,0 0.833,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="1400"
android:propertyName="translateX"
android:startOffset="1683"
android:valueFrom="497.757"
android:valueTo="661.757"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.303,0 0.205,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
</set>
</aapt:attr>
</target>
<target android:name="_R_G_L_4_G_N_2_N_3_N_4_T_1">
<aapt:attr name="android:animation">
<set android:ordering="together">
<objectAnimator
android:duration="333"
android:propertyName="translateY"
android:startOffset="0"
android:valueFrom="1026.235"
android:valueTo="1026.235"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.4,0 0.2,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="900"
android:propertyName="translateY"
android:startOffset="333"
android:valueFrom="1026.235"
android:valueTo="933.235"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.4,0 0.2,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="450"
android:propertyName="translateY"
android:startOffset="1233"
android:valueFrom="933.235"
android:valueTo="939.235"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.167,0 0.833,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="1400"
android:propertyName="translateY"
android:startOffset="1683"
android:valueFrom="939.235"
android:valueTo="1026.235"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.303,0 0.205,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
</set>
</aapt:attr>
</target>
<target android:name="_R_G_L_4_G_N_2_N_3_N_4_T_1">
<aapt:attr name="android:animation">
<set android:ordering="together">
<objectAnimator
android:duration="333"
android:propertyName="rotation"
android:startOffset="0"
android:valueFrom="-10"
android:valueTo="-10"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.4,0 0.2,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="900"
android:propertyName="rotation"
android:startOffset="333"
android:valueFrom="-10"
android:valueTo="0"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.4,0 0.2,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="450"
android:propertyName="rotation"
android:startOffset="1233"
android:valueFrom="0"
android:valueTo="0"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.167,0 0.833,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="1400"
android:propertyName="rotation"
android:startOffset="1683"
android:valueFrom="0"
android:valueTo="-10"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.167,0 0.205,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
</set>
</aapt:attr>
</target>
<target android:name="_R_G_L_4_G_N_2_N_3_N_4_T_1">
<aapt:attr name="android:animation">
<set android:ordering="together">
<objectAnimator
android:duration="0"
android:propertyName="scaleY"
android:startOffset="1233"
android:valueFrom="1"
android:valueTo="0"
android:valueType="floatType" />
</set>
</aapt:attr>
</target>
<target android:name="_R_G_L_3_G_D_0_P_0">
<aapt:attr name="android:animation">
<set android:ordering="together">
<objectAnimator
android:duration="1233"
android:propertyName="fillAlpha"
android:startOffset="0"
android:valueFrom="1"
android:valueTo="1"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.167,0.167 0.833,0.833 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="383"
android:propertyName="fillAlpha"
android:startOffset="1233"
android:valueFrom="1"
android:valueTo="0"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.167,0.167 0.833,0.833 1.0,1.0" />
</aapt:attr>
</objectAnimator>
</set>
</aapt:attr>
</target>
<target android:name="_R_G_L_3_G">
<aapt:attr name="android:animation">
<set android:ordering="together">
<objectAnimator
android:duration="0"
android:propertyName="scaleX"
android:startOffset="1233"
android:valueFrom="0"
android:valueTo="1"
android:valueType="floatType" />
</set>
</aapt:attr>
</target>
<target android:name="_R_G_L_2_G_T_1">
<aapt:attr name="android:animation">
<set android:ordering="together">
<objectAnimator
android:duration="333"
android:propertyName="translateX"
android:startOffset="0"
android:valueFrom="661.757"
android:valueTo="661.757"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.4,0 0.2,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="900"
android:propertyName="translateX"
android:startOffset="333"
android:valueFrom="661.757"
android:valueTo="493.757"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.4,0 0.2,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="450"
android:propertyName="translateX"
android:startOffset="1233"
android:valueFrom="493.757"
android:valueTo="497.757"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.167,0 0.833,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="1400"
android:propertyName="translateX"
android:startOffset="1683"
android:valueFrom="497.757"
android:valueTo="661.757"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.303,0 0.205,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
</set>
</aapt:attr>
</target>
<target android:name="_R_G_L_2_G_T_1">
<aapt:attr name="android:animation">
<set android:ordering="together">
<objectAnimator
android:duration="333"
android:propertyName="translateY"
android:startOffset="0"
android:valueFrom="1026.235"
android:valueTo="1026.235"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.4,0 0.2,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="900"
android:propertyName="translateY"
android:startOffset="333"
android:valueFrom="1026.235"
android:valueTo="933.235"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.4,0 0.2,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="450"
android:propertyName="translateY"
android:startOffset="1233"
android:valueFrom="933.235"
android:valueTo="939.235"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.167,0 0.833,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="1400"
android:propertyName="translateY"
android:startOffset="1683"
android:valueFrom="939.235"
android:valueTo="1026.235"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.303,0 0.205,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
</set>
</aapt:attr>
</target>
<target android:name="_R_G_L_2_G_T_1">
<aapt:attr name="android:animation">
<set android:ordering="together">
<objectAnimator
android:duration="333"
android:propertyName="rotation"
android:startOffset="0"
android:valueFrom="-10"
android:valueTo="-10"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.4,0 0.2,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="900"
android:propertyName="rotation"
android:startOffset="333"
android:valueFrom="-10"
android:valueTo="0"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.4,0 0.2,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="450"
android:propertyName="rotation"
android:startOffset="1233"
android:valueFrom="0"
android:valueTo="0"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.167,0 0.833,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="1400"
android:propertyName="rotation"
android:startOffset="1683"
android:valueFrom="0"
android:valueTo="-10"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.167,0 0.205,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
</set>
</aapt:attr>
</target>
<target android:name="_R_G_L_1_G_N_4_T_1">
<aapt:attr name="android:animation">
<set android:ordering="together">
<objectAnimator
android:duration="333"
android:propertyName="translateX"
android:startOffset="0"
android:valueFrom="661.757"
android:valueTo="661.757"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.4,0 0.2,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="900"
android:propertyName="translateX"
android:startOffset="333"
android:valueFrom="661.757"
android:valueTo="493.757"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.4,0 0.2,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="450"
android:propertyName="translateX"
android:startOffset="1233"
android:valueFrom="493.757"
android:valueTo="497.757"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.167,0 0.833,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="1400"
android:propertyName="translateX"
android:startOffset="1683"
android:valueFrom="497.757"
android:valueTo="661.757"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.303,0 0.205,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
</set>
</aapt:attr>
</target>
<target android:name="_R_G_L_1_G_N_4_T_1">
<aapt:attr name="android:animation">
<set android:ordering="together">
<objectAnimator
android:duration="333"
android:propertyName="translateY"
android:startOffset="0"
android:valueFrom="1026.235"
android:valueTo="1026.235"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.4,0 0.2,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="900"
android:propertyName="translateY"
android:startOffset="333"
android:valueFrom="1026.235"
android:valueTo="933.235"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.4,0 0.2,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="450"
android:propertyName="translateY"
android:startOffset="1233"
android:valueFrom="933.235"
android:valueTo="939.235"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.167,0 0.833,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="1400"
android:propertyName="translateY"
android:startOffset="1683"
android:valueFrom="939.235"
android:valueTo="1026.235"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.303,0 0.205,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
</set>
</aapt:attr>
</target>
<target android:name="_R_G_L_1_G_N_4_T_1">
<aapt:attr name="android:animation">
<set android:ordering="together">
<objectAnimator
android:duration="333"
android:propertyName="rotation"
android:startOffset="0"
android:valueFrom="-10"
android:valueTo="-10"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.4,0 0.2,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="900"
android:propertyName="rotation"
android:startOffset="333"
android:valueFrom="-10"
android:valueTo="0"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.4,0 0.2,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="450"
android:propertyName="rotation"
android:startOffset="1233"
android:valueFrom="0"
android:valueTo="0"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.167,0 0.833,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="1400"
android:propertyName="rotation"
android:startOffset="1683"
android:valueFrom="0"
android:valueTo="-10"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.167,0 0.205,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
</set>
</aapt:attr>
</target>
<target android:name="_R_G_L_0_G_D_0_P_0">
<aapt:attr name="android:animation">
<set android:ordering="together">
<objectAnimator
android:duration="450"
android:propertyName="pathData"
android:startOffset="0"
android:valueFrom="M19.19 14.59 C40.48,0.25 55.28,10.31 73.92,28.68 C92.56,47.05 106.44,53.33 112.22,64.44 C118,75.56 76.45,102.74 64.42,104.51 C52.38,106.27 30.98,101.06 19.76,76.77 C8.07,51.48 0.54,27.15 19.19,14.59c "
android:valueTo="M19.19 14.59 C40.48,0.25 55.28,10.31 73.92,28.68 C92.56,47.05 106.44,53.33 112.22,64.44 C118,75.56 76.45,102.74 64.42,104.51 C52.38,106.27 30.98,101.06 19.76,76.77 C8.07,51.48 0.54,27.15 19.19,14.59c "
android:valueType="pathType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.4,0 0.2,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="783"
android:propertyName="pathData"
android:startOffset="450"
android:valueFrom="M19.19 14.59 C40.48,0.25 55.28,10.31 73.92,28.68 C92.56,47.05 106.44,53.33 112.22,64.44 C118,75.56 76.45,102.74 64.42,104.51 C52.38,106.27 30.98,101.06 19.76,76.77 C8.07,51.48 0.54,27.15 19.19,14.59c "
android:valueTo="M19.19 14.59 C40.48,0.25 55.28,10.31 73.92,28.68 C92.56,47.05 106.44,53.33 112.22,64.44 C118,75.56 103.84,114.98 73.16,119.19 C61.1,120.84 30.98,101.06 19.76,76.77 C8.07,51.48 0.54,27.15 19.19,14.59c "
android:valueType="pathType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.4,0 0.2,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="450"
android:propertyName="pathData"
android:startOffset="1233"
android:valueFrom="M19.19 14.59 C40.48,0.25 55.28,10.31 73.92,28.68 C92.56,47.05 106.44,53.33 112.22,64.44 C118,75.56 103.84,114.98 73.16,119.19 C61.1,120.84 30.98,101.06 19.76,76.77 C8.07,51.48 0.54,27.15 19.19,14.59c "
android:valueTo="M19.19 14.59 C40.48,0.25 55.28,10.31 73.92,28.68 C92.56,47.05 106.44,53.33 112.22,64.44 C118,75.56 103.84,114.98 73.16,119.19 C61.1,120.84 30.98,101.06 19.76,76.77 C8.07,51.48 0.54,27.15 19.19,14.59c "
android:valueType="pathType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.167,0 0.833,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="1400"
android:propertyName="pathData"
android:startOffset="1683"
android:valueFrom="M19.19 14.59 C40.48,0.25 55.28,10.31 73.92,28.68 C92.56,47.05 106.44,53.33 112.22,64.44 C118,75.56 103.84,114.98 73.16,119.19 C61.1,120.84 30.98,101.06 19.76,76.77 C8.07,51.48 0.54,27.15 19.19,14.59c "
android:valueTo="M19.19 14.59 C40.48,0.25 55.28,10.31 73.92,28.68 C92.56,47.05 106.44,53.33 112.22,64.44 C118,75.56 76.45,102.74 64.42,104.51 C52.38,106.27 30.98,101.06 19.76,76.77 C8.07,51.48 0.54,27.15 19.19,14.59c "
android:valueType="pathType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.167,0 0.833,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
</set>
</aapt:attr>
</target>
<target android:name="_R_G_L_0_G">
<aapt:attr name="android:animation">
<set android:ordering="together">
<objectAnimator
android:duration="450"
android:propertyName="rotation"
android:startOffset="0"
android:valueFrom="-16"
android:valueTo="-16"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.4,0 0.2,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="783"
android:propertyName="rotation"
android:startOffset="450"
android:valueFrom="-16"
android:valueTo="11"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.4,0 0.2,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="450"
android:propertyName="rotation"
android:startOffset="1233"
android:valueFrom="11"
android:valueTo="11"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.167,0 0.833,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="1400"
android:propertyName="rotation"
android:startOffset="1683"
android:valueFrom="11"
android:valueTo="-16"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.167,0 0.205,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
</set>
</aapt:attr>
</target>
<target android:name="_R_G_L_0_G_N_3_N_4_T_1">
<aapt:attr name="android:animation">
<set android:ordering="together">
<objectAnimator
android:duration="333"
android:propertyName="translateX"
android:startOffset="0"
android:valueFrom="661.757"
android:valueTo="661.757"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.4,0 0.2,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="900"
android:propertyName="translateX"
android:startOffset="333"
android:valueFrom="661.757"
android:valueTo="493.757"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.4,0 0.2,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="450"
android:propertyName="translateX"
android:startOffset="1233"
android:valueFrom="493.757"
android:valueTo="497.757"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.167,0 0.833,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="1400"
android:propertyName="translateX"
android:startOffset="1683"
android:valueFrom="497.757"
android:valueTo="661.757"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.303,0 0.205,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
</set>
</aapt:attr>
</target>
<target android:name="_R_G_L_0_G_N_3_N_4_T_1">
<aapt:attr name="android:animation">
<set android:ordering="together">
<objectAnimator
android:duration="333"
android:propertyName="translateY"
android:startOffset="0"
android:valueFrom="1026.235"
android:valueTo="1026.235"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.4,0 0.2,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="900"
android:propertyName="translateY"
android:startOffset="333"
android:valueFrom="1026.235"
android:valueTo="933.235"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.4,0 0.2,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="450"
android:propertyName="translateY"
android:startOffset="1233"
android:valueFrom="933.235"
android:valueTo="939.235"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.167,0 0.833,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="1400"
android:propertyName="translateY"
android:startOffset="1683"
android:valueFrom="939.235"
android:valueTo="1026.235"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.303,0 0.205,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
</set>
</aapt:attr>
</target>
<target android:name="_R_G_L_0_G_N_3_N_4_T_1">
<aapt:attr name="android:animation">
<set android:ordering="together">
<objectAnimator
android:duration="333"
android:propertyName="rotation"
android:startOffset="0"
android:valueFrom="-10"
android:valueTo="-10"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.4,0 0.2,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="900"
android:propertyName="rotation"
android:startOffset="333"
android:valueFrom="-10"
android:valueTo="0"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.4,0 0.2,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="450"
android:propertyName="rotation"
android:startOffset="1233"
android:valueFrom="0"
android:valueTo="0"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.167,0 0.833,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="1400"
android:propertyName="rotation"
android:startOffset="1683"
android:valueFrom="0"
android:valueTo="-10"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.167,0 0.205,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
</set>
</aapt:attr>
</target>
<target android:name="time_group">
<aapt:attr name="android:animation">
<set android:ordering="together">
<objectAnimator
android:duration="3167"
android:propertyName="translateX"
android:startOffset="0"
android:valueFrom="0"
android:valueTo="1"
android:valueType="floatType" />
</set>
</aapt:attr>
</target>
</animated-vector>
File diff suppressed because it is too large Load Diff
+932 -43
View File
@@ -1,46 +1,935 @@
<!--
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.
-->
<!-- Dummy translating rectangle until we have a proper animation. -->
<animated-vector xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:aapt="http://schemas.android.com/aapt" >
<aapt:attr name="android:drawable">
<vector
android:height="64dp"
android:width="64dp"
android:viewportHeight="600"
android:viewportWidth="600" >
<group
android:name="translationGroup"
android:pivotX="300.0"
android:pivotY="300.0"
android:rotation="180.0" >
<path
android:fillColor="#eeeeee"
android:pathData="M300,70 l 0,-70 70,0 0,140 -70,0 z" />
</group>
</vector>
</aapt:attr>
<target android:name="translationGroup">
<aapt:attr name="android:animation">
<objectAnimator
android:duration="3000"
android:propertyName="translateY"
android:valueFrom="0"
android:valueTo="-100" />
xmlns:aapt="http://schemas.android.com/aapt">
<aapt:attr name="android:drawable">
<vector
android:width="412dp"
android:height="890dp"
android:viewportWidth="412"
android:viewportHeight="890">
<group android:name="_R_G">
<group
android:name="_R_G_L_3_G_T_1"
android:translateX="206"
android:translateY="880.283">
<group
android:name="_R_G_L_3_G"
android:translateX="-48.25"
android:translateY="-51.643">
<path
android:name="_R_G_L_3_G_D_0_P_0"
android:fillAlpha="0"
android:fillColor="#e8f0fe"
android:fillType="nonZero"
android:pathData=" M96.25 48.25 C96.25,74.76 74.76,96.25 48.25,96.25 C21.74,96.25 0.25,74.76 0.25,48.25 C0.25,21.74 21.74,0.25 48.25,0.25 C74.76,0.25 96.25,21.74 96.25,48.25c " />
</group>
</group>
<group
android:name="_R_G_L_2_G_N_4_N_3_T_1"
android:rotation="-60"
android:translateX="513.995"
android:translateY="909.041">
<group
android:name="_R_G_L_2_G_N_4_N_3_T_0"
android:translateX="-125.282"
android:translateY="-222.031">
<group
android:name="_R_G_L_2_G_N_4_T_0"
android:translateX="-27.223000000000006"
android:translateY="-19.78200000000001">
<group
android:name="_R_G_L_2_G"
android:pivotX="49.356"
android:pivotY="100.997"
android:rotation="-4"
android:translateX="-12.881"
android:translateY="-68.965">
<path
android:name="_R_G_L_2_G_D_0_P_0"
android:fillAlpha="1"
android:fillColor="#d2e3fc"
android:fillType="nonZero"
android:pathData=" M29.51 3.44 C29.51,3.44 29.51,3.44 29.51,3.44 C44.17,0.25 58.86,8.71 63.48,22.99 C63.48,22.99 95.13,76.48 95.13,76.48 C98.47,94.41 92.03,116.16 52.12,115.41 C52.12,115.41 31.32,103.09 31.32,103.09 C23.59,101.22 5.39,82.22 3.78,59.83 C3.78,59.83 3.05,36.42 3.05,36.42 C5.71,17.29 15.16,6.55 29.51,3.44c " />
<path
android:name="_R_G_L_2_G_D_1_P_0"
android:pathData=" M58.16 28.36 C59.49,32.32 59.42,36.53 52.4,38.99 C52.4,38.99 46.29,40.77 30.67,46.05 C28.57,46.76 25.79,48.06 23.78,47.5 C22.12,47.04 20.49,45.56 19.68,42.39 C16.89,31.56 15,24.2 18.96,19.11 "
android:strokeWidth="6"
android:strokeAlpha="1"
android:strokeColor="#a0c2f9" />
</group>
</group>
</group>
</group>
<group
android:name="_R_G_L_1_G_N_3_T_1"
android:rotation="-60"
android:translateX="513.995"
android:translateY="909.041">
<group
android:name="_R_G_L_1_G_N_3_T_0"
android:translateX="-125.282"
android:translateY="-222.031">
<group
android:name="_R_G_L_1_G"
android:translateX="-27.223000000000006"
android:translateY="-19.78200000000001">
<path
android:name="_R_G_L_1_G_D_0_P_0"
android:fillAlpha="1"
android:fillColor="#d2e3fc"
android:fillType="nonZero"
android:pathData=" M62.05 -4.24 C62.05,-4.24 76.43,1.82 76.43,1.82 C91.76,16.39 83.61,36.19 86.21,52.29 C92.02,88.24 84.86,126.82 117.41,193.95 C87.71,242.97 78.03,245.45 48.32,294.5 C48.32,294.5 18.2,137.31 18.2,137.31 C19.12,123.7 17.54,107.98 13.81,87.39 C10.28,67.94 10.58,45.16 10,31.95 C10.04,30.08 8.74,12.88 15.64,8.72 C26.15,2.4 40.27,-9.2 62.05,-4.24c " />
<path
android:name="_R_G_L_1_G_D_1_P_0"
android:pathData=" M31.4 21.98 C31.4,21.98 41.87,1.7 68.18,3.97 "
android:strokeWidth="6"
android:strokeAlpha="1"
android:strokeColor="#a0c2f9" />
</group>
</group>
</group>
<group
android:name="_R_G_L_0_G_T_1"
android:rotation="-60"
android:translateX="513.995"
android:translateY="909.041">
<group
android:name="_R_G_L_0_G"
android:translateX="-125.282"
android:translateY="-222.031">
<path
android:name="_R_G_L_0_G_D_0_P_0"
android:fillAlpha="1"
android:fillColor="#d2e3fc"
android:fillType="nonZero"
android:pathData=" M5.87 164.71 C0.43,267.95 56.57,389.47 139.31,416.77 C222.04,444.07 215.7,295.51 248.09,197.33 C280.49,99.14 111.3,154.92 55.02,40.63 C41.48,24.52 8.77,109.58 5.87,164.71c " />
</group>
</group>
</group>
<group android:name="time_group" />
</vector>
</aapt:attr>
</target>
<target android:name="_R_G_L_3_G_D_0_P_0">
<aapt:attr name="android:animation">
<set android:ordering="together">
<objectAnimator
android:duration="333"
android:propertyName="fillAlpha"
android:startOffset="0"
android:valueFrom="0"
android:valueTo="0"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.167,0.167 0.833,0.833 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="133"
android:propertyName="fillAlpha"
android:startOffset="333"
android:valueFrom="0"
android:valueTo="1"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.167,0.167 0.833,0.833 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="450"
android:propertyName="fillAlpha"
android:startOffset="467"
android:valueFrom="1"
android:valueTo="1"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.167,0.167 0.833,0.833 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="300"
android:propertyName="fillAlpha"
android:startOffset="917"
android:valueFrom="1"
android:valueTo="0"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.167,0.167 0.833,0.833 1.0,1.0" />
</aapt:attr>
</objectAnimator>
</set>
</aapt:attr>
</target>
<target android:name="_R_G_L_3_G_T_1">
<aapt:attr name="android:animation">
<set android:ordering="together">
<objectAnimator
android:duration="333"
android:propertyName="translateY"
android:startOffset="0"
android:valueFrom="880.283"
android:valueTo="880.283"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.247,0 0,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="883"
android:propertyName="translateY"
android:startOffset="333"
android:valueFrom="880.283"
android:valueTo="486.283"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.247,0 0,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
</set>
</aapt:attr>
</target>
<target android:name="_R_G_L_2_G_D_0_P_0">
<aapt:attr name="android:animation">
<set android:ordering="together">
<objectAnimator
android:duration="333"
android:propertyName="pathData"
android:startOffset="0"
android:valueFrom="M29.51 3.44 C29.51,3.44 29.51,3.44 29.51,3.44 C44.17,0.25 58.86,8.71 63.48,22.99 C63.48,22.99 95.13,76.48 95.13,76.48 C98.47,94.41 92.03,116.16 52.12,115.41 C52.12,115.41 31.32,103.09 31.32,103.09 C23.59,101.22 5.39,82.22 3.78,59.83 C3.78,59.83 3.05,36.42 3.05,36.42 C5.71,17.29 15.16,6.55 29.51,3.44c "
android:valueTo="M29.51 3.44 C29.51,3.44 29.51,3.44 29.51,3.44 C44.17,0.25 58.86,8.71 63.48,22.99 C63.48,22.99 95.13,76.48 95.13,76.48 C98.47,94.41 92.03,116.16 52.12,115.41 C52.12,115.41 31.32,103.09 31.32,103.09 C23.59,101.22 5.39,82.22 3.78,59.83 C3.78,59.83 3.05,36.42 3.05,36.42 C5.71,17.29 15.16,6.55 29.51,3.44c "
android:valueType="pathType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.4,0 0.2,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="583"
android:propertyName="pathData"
android:startOffset="333"
android:valueFrom="M29.51 3.44 C29.51,3.44 29.51,3.44 29.51,3.44 C44.17,0.25 58.86,8.71 63.48,22.99 C63.48,22.99 95.13,76.48 95.13,76.48 C98.47,94.41 92.03,116.16 52.12,115.41 C52.12,115.41 31.32,103.09 31.32,103.09 C23.59,101.22 5.39,82.22 3.78,59.83 C3.78,59.83 3.05,36.42 3.05,36.42 C5.71,17.29 15.16,6.55 29.51,3.44c "
android:valueTo="M29.51 3.44 C29.51,3.44 29.51,3.44 29.51,3.44 C44.17,0.25 58.86,8.71 63.48,22.99 C63.48,22.99 81.12,76.53 81.12,76.53 C84.46,94.46 74.07,117.8 56.14,121.15 C56.14,121.15 51.31,122.05 51.31,122.05 C31.42,125.74 12.82,111.19 11.57,91 C11.57,91 6.61,34.54 6.61,34.54 C5.34,19.87 15.16,6.55 29.51,3.44c "
android:valueType="pathType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.4,0 0.2,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="567"
android:propertyName="pathData"
android:startOffset="917"
android:valueFrom="M29.51 3.44 C29.51,3.44 29.51,3.44 29.51,3.44 C44.17,0.25 58.86,8.71 63.48,22.99 C63.48,22.99 81.12,76.53 81.12,76.53 C84.46,94.46 74.07,117.8 56.14,121.15 C56.14,121.15 51.31,122.05 51.31,122.05 C31.42,125.74 12.82,111.19 11.57,91 C11.57,91 6.61,34.54 6.61,34.54 C5.34,19.87 15.16,6.55 29.51,3.44c "
android:valueTo="M29.51 3.44 C29.51,3.44 29.51,3.44 29.51,3.44 C44.17,0.25 58.86,8.71 63.48,22.99 C63.48,22.99 81.12,76.53 81.12,76.53 C84.46,94.46 74.07,117.8 56.14,121.15 C56.14,121.15 51.31,122.05 51.31,122.05 C31.42,125.74 12.82,111.19 11.57,91 C11.57,91 6.61,34.54 6.61,34.54 C5.34,19.87 15.16,6.55 29.51,3.44c "
android:valueType="pathType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.167,0 0.2,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="1350"
android:propertyName="pathData"
android:startOffset="1483"
android:valueFrom="M29.51 3.44 C29.51,3.44 29.51,3.44 29.51,3.44 C44.17,0.25 58.86,8.71 63.48,22.99 C63.48,22.99 81.12,76.53 81.12,76.53 C84.46,94.46 74.07,117.8 56.14,121.15 C56.14,121.15 51.31,122.05 51.31,122.05 C31.42,125.74 12.82,111.19 11.57,91 C11.57,91 6.61,34.54 6.61,34.54 C5.34,19.87 15.16,6.55 29.51,3.44c "
android:valueTo="M29.51 3.44 C29.51,3.44 29.51,3.44 29.51,3.44 C44.17,0.25 58.86,8.71 63.48,22.99 C63.48,22.99 95.13,76.48 95.13,76.48 C98.47,94.41 92.03,116.16 52.12,115.41 C52.12,115.41 31.32,103.09 31.32,103.09 C23.59,101.22 5.39,82.22 3.78,59.83 C3.78,59.83 3.05,36.42 3.05,36.42 C5.71,17.29 15.16,6.55 29.51,3.44c "
android:valueType="pathType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.167,0 0.833,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
</set>
</aapt:attr>
</target>
<target android:name="_R_G_L_2_G">
<aapt:attr name="android:animation">
<set android:ordering="together">
<objectAnimator
android:duration="333"
android:propertyName="rotation"
android:startOffset="0"
android:valueFrom="-4"
android:valueTo="-4"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.001,0 0.2,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="200"
android:propertyName="rotation"
android:startOffset="333"
android:valueFrom="-4"
android:valueTo="0"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.001,0 0.2,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="2300"
android:propertyName="rotation"
android:startOffset="533"
android:valueFrom="0"
android:valueTo="-4"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.167,0 0.833,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
</set>
</aapt:attr>
</target>
<target android:name="_R_G_L_2_G_N_4_N_3_T_1">
<aapt:attr name="android:animation">
<set android:ordering="together">
<objectAnimator
android:duration="333"
android:propertyName="translateX"
android:startOffset="0"
android:valueFrom="513.995"
android:valueTo="513.995"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.711,0 0.772,0.166 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="150"
android:propertyName="translateX"
android:startOffset="333"
android:valueFrom="513.995"
android:valueTo="469.109"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.711,0 0.772,0.166 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="433"
android:propertyName="translateX"
android:startOffset="483"
android:valueFrom="469.109"
android:valueTo="343.995"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.094,0.355 0.269,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="567"
android:propertyName="translateX"
android:startOffset="917"
android:valueFrom="343.995"
android:valueTo="367.995"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.307,0 0.475,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="1350"
android:propertyName="translateX"
android:startOffset="1483"
android:valueFrom="367.995"
android:valueTo="513.995"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.513,0 0.219,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
</set>
</aapt:attr>
</target>
<target android:name="_R_G_L_2_G_N_4_N_3_T_1">
<aapt:attr name="android:animation">
<set android:ordering="together">
<objectAnimator
android:duration="333"
android:propertyName="translateY"
android:startOffset="0"
android:valueFrom="909.041"
android:valueTo="909.041"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.4,0 0,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="583"
android:propertyName="translateY"
android:startOffset="333"
android:valueFrom="909.041"
android:valueTo="859.041"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.4,0 0,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="567"
android:propertyName="translateY"
android:startOffset="917"
android:valueFrom="859.041"
android:valueTo="883.041"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.307,0 0.475,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="1350"
android:propertyName="translateY"
android:startOffset="1483"
android:valueFrom="883.041"
android:valueTo="909.041"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.513,0 0.219,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
</set>
</aapt:attr>
</target>
<target android:name="_R_G_L_2_G_N_4_N_3_T_1">
<aapt:attr name="android:animation">
<set android:ordering="together">
<objectAnimator
android:duration="333"
android:propertyName="rotation"
android:startOffset="0"
android:valueFrom="-60"
android:valueTo="-60"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.4,0 0,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="583"
android:propertyName="rotation"
android:startOffset="333"
android:valueFrom="-60"
android:valueTo="0"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.4,0 0,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="567"
android:propertyName="rotation"
android:startOffset="917"
android:valueFrom="0"
android:valueTo="-2"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.307,0 0.545,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="1350"
android:propertyName="rotation"
android:startOffset="1483"
android:valueFrom="-2"
android:valueTo="-60"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.513,0 0.219,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
</set>
</aapt:attr>
</target>
<target android:name="_R_G_L_1_G_D_0_P_0">
<aapt:attr name="android:animation">
<set android:ordering="together">
<objectAnimator
android:duration="333"
android:propertyName="pathData"
android:startOffset="0"
android:valueFrom="M62.05 -4.24 C62.05,-4.24 76.43,1.82 76.43,1.82 C91.76,16.39 83.61,36.19 86.21,52.29 C92.02,88.24 84.86,126.82 117.41,193.95 C87.71,242.97 78.03,245.45 48.32,294.5 C48.32,294.5 18.2,137.31 18.2,137.31 C19.12,123.7 17.54,107.98 13.81,87.39 C10.28,67.94 10.58,45.16 10,31.95 C10.04,30.08 8.74,12.88 15.64,8.72 C26.15,2.4 40.27,-9.2 62.05,-4.24c "
android:valueTo="M62.05 -4.24 C62.05,-4.24 76.43,1.82 76.43,1.82 C91.76,16.39 83.61,36.19 86.21,52.29 C92.02,88.24 84.86,126.82 117.41,193.95 C87.71,242.97 78.03,245.45 48.32,294.5 C48.32,294.5 18.2,137.31 18.2,137.31 C19.12,123.7 17.54,107.98 13.81,87.39 C10.28,67.94 10.58,45.16 10,31.95 C10.04,30.08 8.74,12.88 15.64,8.72 C26.15,2.4 40.27,-9.2 62.05,-4.24c "
android:valueType="pathType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.4,0 0.2,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="583"
android:propertyName="pathData"
android:startOffset="333"
android:valueFrom="M62.05 -4.24 C62.05,-4.24 76.43,1.82 76.43,1.82 C91.76,16.39 83.61,36.19 86.21,52.29 C92.02,88.24 84.86,126.82 117.41,193.95 C87.71,242.97 78.03,245.45 48.32,294.5 C48.32,294.5 18.2,137.31 18.2,137.31 C19.12,123.7 17.54,107.98 13.81,87.39 C10.28,67.94 10.58,45.16 10,31.95 C10.04,30.08 8.74,12.88 15.64,8.72 C26.15,2.4 40.27,-9.2 62.05,-4.24c "
android:valueTo="M51.44 5.02 C51.44,5.02 68.24,7.56 68.24,7.56 C73.26,21.67 72.7,36.77 79.13,51.76 C94.55,87.66 106.15,89.19 144.51,111.49 C114.82,160.51 78.03,245.45 48.32,294.5 C48.32,294.5 18.2,137.31 18.2,137.31 C19.12,123.7 19.02,105.73 15.29,85.14 C11.76,65.68 5.52,42.3 0.25,30.23 C0.29,28.36 0.58,17.81 15.64,8.72 C26.15,2.39 40.15,0.25 51.44,5.02c "
android:valueType="pathType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.4,0 0.2,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="567"
android:propertyName="pathData"
android:startOffset="917"
android:valueFrom="M51.44 5.02 C51.44,5.02 68.24,7.56 68.24,7.56 C73.26,21.67 72.7,36.77 79.13,51.76 C94.55,87.66 106.15,89.19 144.51,111.49 C114.82,160.51 78.03,245.45 48.32,294.5 C48.32,294.5 18.2,137.31 18.2,137.31 C19.12,123.7 19.02,105.73 15.29,85.14 C11.76,65.68 5.52,42.3 0.25,30.23 C0.29,28.36 0.58,17.81 15.64,8.72 C26.15,2.39 40.15,0.25 51.44,5.02c "
android:valueTo="M51.44 5.02 C51.44,5.02 68.24,7.56 68.24,7.56 C73.26,21.67 72.7,36.77 79.13,51.76 C94.55,87.66 106.15,89.19 144.51,111.49 C114.82,160.51 78.03,245.45 48.32,294.5 C48.32,294.5 18.2,137.31 18.2,137.31 C19.12,123.7 19.02,105.73 15.29,85.14 C11.76,65.68 5.52,42.3 0.25,30.23 C0.29,28.36 0.58,17.81 15.64,8.72 C26.15,2.39 40.15,0.25 51.44,5.02c "
android:valueType="pathType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.167,0 0.2,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="1350"
android:propertyName="pathData"
android:startOffset="1483"
android:valueFrom="M51.44 5.02 C51.44,5.02 68.24,7.56 68.24,7.56 C73.26,21.67 72.7,36.77 79.13,51.76 C94.55,87.66 106.15,89.19 144.51,111.49 C114.82,160.51 78.03,245.45 48.32,294.5 C48.32,294.5 18.2,137.31 18.2,137.31 C19.12,123.7 19.02,105.73 15.29,85.14 C11.76,65.68 5.52,42.3 0.25,30.23 C0.29,28.36 0.58,17.81 15.64,8.72 C26.15,2.39 40.15,0.25 51.44,5.02c "
android:valueTo="M62.05 -4.24 C62.05,-4.24 76.43,1.82 76.43,1.82 C91.76,16.39 83.61,36.19 86.21,52.29 C92.02,88.24 84.86,126.82 117.41,193.95 C87.71,242.97 78.03,245.45 48.32,294.5 C48.32,294.5 18.2,137.31 18.2,137.31 C19.12,123.7 17.54,107.98 13.81,87.39 C10.28,67.94 10.58,45.16 10,31.95 C10.04,30.08 8.74,12.88 15.64,8.72 C26.15,2.4 40.27,-9.2 62.05,-4.24c "
android:valueType="pathType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.167,0 0.833,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
</set>
</aapt:attr>
</target>
<target android:name="_R_G_L_1_G_D_1_P_0">
<aapt:attr name="android:animation">
<set android:ordering="together">
<objectAnimator
android:duration="333"
android:propertyName="pathData"
android:startOffset="0"
android:valueFrom="M31.4 21.98 C31.4,21.98 41.87,1.7 68.18,3.97 "
android:valueTo="M31.4 21.98 C31.4,21.98 41.87,1.7 68.18,3.97 "
android:valueType="pathType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.4,0 0.2,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="583"
android:propertyName="pathData"
android:startOffset="333"
android:valueFrom="M31.4 21.98 C31.4,21.98 41.87,1.7 68.18,3.97 "
android:valueTo="M17.9 26.98 C17.9,26.98 29.87,13.7 56.18,15.97 "
android:valueType="pathType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.4,0 0.2,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="567"
android:propertyName="pathData"
android:startOffset="917"
android:valueFrom="M17.9 26.98 C17.9,26.98 29.87,13.7 56.18,15.97 "
android:valueTo="M17.9 26.98 C17.9,26.98 29.87,13.7 56.18,15.97 "
android:valueType="pathType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.167,0 0.2,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="1350"
android:propertyName="pathData"
android:startOffset="1483"
android:valueFrom="M17.9 26.98 C17.9,26.98 29.87,13.7 56.18,15.97 "
android:valueTo="M31.4 21.98 C31.4,21.98 41.87,1.7 68.18,3.97 "
android:valueType="pathType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.167,0 0.833,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
</set>
</aapt:attr>
</target>
<target android:name="_R_G_L_1_G_N_3_T_1">
<aapt:attr name="android:animation">
<set android:ordering="together">
<objectAnimator
android:duration="333"
android:propertyName="translateX"
android:startOffset="0"
android:valueFrom="513.995"
android:valueTo="513.995"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.711,0 0.772,0.166 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="150"
android:propertyName="translateX"
android:startOffset="333"
android:valueFrom="513.995"
android:valueTo="469.109"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.711,0 0.772,0.166 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="433"
android:propertyName="translateX"
android:startOffset="483"
android:valueFrom="469.109"
android:valueTo="343.995"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.094,0.355 0.269,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="567"
android:propertyName="translateX"
android:startOffset="917"
android:valueFrom="343.995"
android:valueTo="367.995"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.307,0 0.475,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="1350"
android:propertyName="translateX"
android:startOffset="1483"
android:valueFrom="367.995"
android:valueTo="513.995"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.513,0 0.219,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
</set>
</aapt:attr>
</target>
<target android:name="_R_G_L_1_G_N_3_T_1">
<aapt:attr name="android:animation">
<set android:ordering="together">
<objectAnimator
android:duration="333"
android:propertyName="translateY"
android:startOffset="0"
android:valueFrom="909.041"
android:valueTo="909.041"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.4,0 0,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="583"
android:propertyName="translateY"
android:startOffset="333"
android:valueFrom="909.041"
android:valueTo="859.041"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.4,0 0,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="567"
android:propertyName="translateY"
android:startOffset="917"
android:valueFrom="859.041"
android:valueTo="883.041"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.307,0 0.475,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="1350"
android:propertyName="translateY"
android:startOffset="1483"
android:valueFrom="883.041"
android:valueTo="909.041"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.513,0 0.219,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
</set>
</aapt:attr>
</target>
<target android:name="_R_G_L_1_G_N_3_T_1">
<aapt:attr name="android:animation">
<set android:ordering="together">
<objectAnimator
android:duration="333"
android:propertyName="rotation"
android:startOffset="0"
android:valueFrom="-60"
android:valueTo="-60"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.4,0 0,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="583"
android:propertyName="rotation"
android:startOffset="333"
android:valueFrom="-60"
android:valueTo="0"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.4,0 0,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="567"
android:propertyName="rotation"
android:startOffset="917"
android:valueFrom="0"
android:valueTo="-2"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.307,0 0.545,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="1350"
android:propertyName="rotation"
android:startOffset="1483"
android:valueFrom="-2"
android:valueTo="-60"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.513,0 0.219,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
</set>
</aapt:attr>
</target>
<target android:name="_R_G_L_0_G_D_0_P_0">
<aapt:attr name="android:animation">
<set android:ordering="together">
<objectAnimator
android:duration="333"
android:propertyName="pathData"
android:startOffset="0"
android:valueFrom="M5.87 164.71 C0.43,267.95 56.57,389.47 139.31,416.77 C222.04,444.07 215.7,295.51 248.09,197.33 C280.49,99.14 111.3,154.92 55.02,40.63 C41.48,24.52 8.77,109.58 5.87,164.71c "
android:valueTo="M5.87 164.71 C0.43,267.95 56.57,389.47 139.31,416.77 C222.04,444.07 215.7,295.51 248.09,197.33 C280.49,99.14 111.3,154.92 55.02,40.63 C41.48,24.52 8.77,109.58 5.87,164.71c "
android:valueType="pathType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.4,0 0.833,0.833 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="150"
android:propertyName="pathData"
android:startOffset="333"
android:valueFrom="M5.87 164.71 C0.43,267.95 56.57,389.47 139.31,416.77 C222.04,444.07 215.7,295.51 248.09,197.33 C280.49,99.14 111.3,154.92 55.02,40.63 C41.48,24.52 8.77,109.58 5.87,164.71c "
android:valueTo="M-9.23 115.79 C-30.45,216.96 -36.73,359.16 139.26,416.71 C222.07,443.78 220.51,278.25 244.3,175.03 C268.14,75.53 116.98,150.23 54.13,40.23 C40.58,24.12 5.18,47.09 -9.23,115.79c "
android:valueType="pathType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.4,0 0.833,0.833 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="433"
android:propertyName="pathData"
android:startOffset="483"
android:valueFrom="M-9.23 115.79 C-30.45,216.96 -36.73,359.16 139.26,416.71 C222.07,443.78 220.51,278.25 244.3,175.03 C268.14,75.53 116.98,150.23 54.13,40.23 C40.58,24.12 5.18,47.09 -9.23,115.79c "
android:valueTo="M-8.56 118.7 C-9.54,222.08 56.39,389.22 139.13,416.51 C221.86,443.81 234.66,227.56 233.16,109.56 C231.84,6.17 133.65,136.44 51.49,39.06 C37.94,22.95 -7.96,56.24 -8.56,118.7c "
android:valueType="pathType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.167,0.167 0.2,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="917"
android:propertyName="pathData"
android:startOffset="917"
android:valueFrom="M-8.56 118.7 C-9.54,222.08 56.39,389.22 139.13,416.51 C221.86,443.81 234.66,227.56 233.16,109.56 C231.84,6.17 133.65,136.44 51.49,39.06 C37.94,22.95 -7.96,56.24 -8.56,118.7c "
android:valueTo="M-8.56 118.7 C-9.54,222.08 56.39,389.22 139.13,416.51 C221.86,443.81 238.66,196.56 237.16,78.56 C235.84,-24.83 133.65,136.44 51.49,39.06 C37.94,22.95 -7.96,56.24 -8.56,118.7c "
android:valueType="pathType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.167,0 0.212,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="1000"
android:propertyName="pathData"
android:startOffset="1833"
android:valueFrom="M-8.56 118.7 C-9.54,222.08 56.39,389.22 139.13,416.51 C221.86,443.81 238.66,196.56 237.16,78.56 C235.84,-24.83 133.65,136.44 51.49,39.06 C37.94,22.95 -7.96,56.24 -8.56,118.7c "
android:valueTo="M5.87 164.71 C0.43,267.95 56.57,389.47 139.31,416.77 C222.04,444.07 215.7,295.51 248.09,197.33 C280.49,99.14 111.3,154.92 55.02,40.63 C41.48,24.52 8.77,109.58 5.87,164.71c "
android:valueType="pathType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.167,0 0.833,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
</set>
</aapt:attr>
</target>
<target android:name="_R_G_L_0_G_T_1">
<aapt:attr name="android:animation">
<set android:ordering="together">
<objectAnimator
android:duration="333"
android:propertyName="translateX"
android:startOffset="0"
android:valueFrom="513.995"
android:valueTo="513.995"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.711,0 0.772,0.166 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="150"
android:propertyName="translateX"
android:startOffset="333"
android:valueFrom="513.995"
android:valueTo="469.109"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.711,0 0.772,0.166 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="433"
android:propertyName="translateX"
android:startOffset="483"
android:valueFrom="469.109"
android:valueTo="343.995"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.094,0.355 0.269,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="567"
android:propertyName="translateX"
android:startOffset="917"
android:valueFrom="343.995"
android:valueTo="367.995"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.307,0 0.475,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="1350"
android:propertyName="translateX"
android:startOffset="1483"
android:valueFrom="367.995"
android:valueTo="513.995"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.513,0 0.219,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
</set>
</aapt:attr>
</target>
<target android:name="_R_G_L_0_G_T_1">
<aapt:attr name="android:animation">
<set android:ordering="together">
<objectAnimator
android:duration="333"
android:propertyName="translateY"
android:startOffset="0"
android:valueFrom="909.041"
android:valueTo="909.041"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.4,0 0,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="583"
android:propertyName="translateY"
android:startOffset="333"
android:valueFrom="909.041"
android:valueTo="859.041"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.4,0 0,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="567"
android:propertyName="translateY"
android:startOffset="917"
android:valueFrom="859.041"
android:valueTo="883.041"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.307,0 0.475,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="1350"
android:propertyName="translateY"
android:startOffset="1483"
android:valueFrom="883.041"
android:valueTo="909.041"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.513,0 0.219,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
</set>
</aapt:attr>
</target>
<target android:name="_R_G_L_0_G_T_1">
<aapt:attr name="android:animation">
<set android:ordering="together">
<objectAnimator
android:duration="333"
android:propertyName="rotation"
android:startOffset="0"
android:valueFrom="-60"
android:valueTo="-60"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.4,0 0,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="583"
android:propertyName="rotation"
android:startOffset="333"
android:valueFrom="-60"
android:valueTo="0"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.4,0 0,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="567"
android:propertyName="rotation"
android:startOffset="917"
android:valueFrom="0"
android:valueTo="-2"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.307,0 0.545,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
<objectAnimator
android:duration="1350"
android:propertyName="rotation"
android:startOffset="1483"
android:valueFrom="-2"
android:valueTo="-60"
android:valueType="floatType">
<aapt:attr name="android:interpolator">
<pathInterpolator android:pathData="M 0.0,0.0 c0.513,0 0.219,1 1.0,1.0" />
</aapt:attr>
</objectAnimator>
</set>
</aapt:attr>
</target>
<target android:name="time_group">
<aapt:attr name="android:animation">
<set android:ordering="together">
<objectAnimator
android:duration="2850"
android:propertyName="translateX"
android:startOffset="0"
android:valueFrom="0"
android:valueTo="1"
android:valueType="floatType" />
</set>
</aapt:attr>
</target>
</animated-vector>
File diff suppressed because it is too large Load Diff
@@ -35,6 +35,7 @@
</Space>
<Button
android:id="@+id/action_screenshot"
android:theme="@style/ThemeControlHighlightWorkspaceColor"
style="@style/OverviewActionButton"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
@@ -48,6 +49,7 @@
<Button
android:id="@+id/action_share"
android:theme="@style/ThemeControlHighlightWorkspaceColor"
style="@style/OverviewActionButton"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
+1 -1
View File
@@ -45,5 +45,5 @@
<string name="hotseat_tip_gaps_filled" msgid="3035673010274223538">"Se han añadido sugerencias de aplicaciones a espacios vacíos"</string>
<string name="hotseat_prediction_content_description" msgid="4582028296938078419">"Aplicación sugerida: <xliff:g id="TITLE">%1$s</xliff:g>"</string>
<string name="action_share" msgid="2648470652637092375">"Compartir"</string>
<string name="action_screenshot" msgid="8171125848358142917">"Hacer captura de pantalla"</string>
<string name="action_screenshot" msgid="8171125848358142917">"Hacer captura"</string>
</resources>
+8
View File
@@ -69,6 +69,14 @@
<item name="android:textColor">@color/gesture_tutorial_primary_color</item>
</style>
<!--
Can be applied to views to color things like ripples and list highlights the workspace text
color.
-->
<style name="ThemeControlHighlightWorkspaceColor">
<item name="android:colorControlHighlight">?attr/workspaceTextColor</item>
</style>
<style name="OverviewActionButton"
parent="@android:style/Widget.DeviceDefault.Button.Borderless">
<item name="android:textColor">?attr/workspaceTextColor</item>
@@ -17,6 +17,7 @@ package com.android.launcher3;
import static com.android.launcher3.AbstractFloatingView.TYPE_ALL;
import static com.android.launcher3.AbstractFloatingView.TYPE_HIDE_BACK_BUTTON;
import static com.android.launcher3.LauncherState.FLAG_HIDE_BACK_BUTTON;
import static com.android.launcher3.LauncherState.NORMAL;
import static com.android.quickstep.SysUINavigationMode.removeShelfFromOverview;
import static com.android.systemui.shared.system.ActivityManagerWrapper.CLOSE_SYSTEM_WINDOWS_REASON_HOME_KEY;
@@ -251,13 +252,10 @@ public abstract class BaseQuickstepLauncher extends Launcher
super.onActivityFlagsChanged(changeBits);
}
/**
* Sets the back button visibility based on the current state/window focus.
*/
private void onLauncherStateOrFocusChanged() {
public boolean shouldBackButtonBeHidden(LauncherState toState) {
Mode mode = SysUINavigationMode.getMode(this);
boolean shouldBackButtonBeHidden = mode.hasGestures
&& getStateManager().getState().hideBackButton
&& toState.hasFlag(FLAG_HIDE_BACK_BUTTON)
&& hasWindowFocus()
&& (getActivityFlags() & ACTIVITY_STATE_TRANSITION_ACTIVE) == 0;
if (shouldBackButtonBeHidden) {
@@ -265,6 +263,14 @@ public abstract class BaseQuickstepLauncher extends Launcher
shouldBackButtonBeHidden = AbstractFloatingView.getTopOpenViewWithType(this,
TYPE_ALL & ~TYPE_HIDE_BACK_BUTTON) == null;
}
return shouldBackButtonBeHidden;
}
/**
* Sets the back button visibility based on the current state/window focus.
*/
private void onLauncherStateOrFocusChanged() {
boolean shouldBackButtonBeHidden = shouldBackButtonBeHidden(getStateManager().getState());
UiThreadHelper.setBackButtonAlphaAsync(this, SET_BACK_BUTTON_ALPHA,
shouldBackButtonBeHidden ? 0f : 1f, true /* animate */);
if (getDragLayer() != null) {
@@ -493,7 +493,7 @@ public abstract class QuickstepAppTransitionManagerImpl extends LauncherAppTrans
: APP_LAUNCH_ALPHA_DOWN_DURATION;
RectF targetBounds = new RectF(windowTargetBounds);
RectF currentBounds = new RectF();
RectF iconBounds = new RectF();
RectF temp = new RectF();
Point tmpPos = new Point();
@@ -531,7 +531,7 @@ public abstract class QuickstepAppTransitionManagerImpl extends LauncherAppTrans
appAnimator.addUpdateListener(new MultiValueUpdateListener() {
FloatProp mDx = new FloatProp(0, dX, 0, xDuration, AGGRESSIVE_EASE);
FloatProp mDy = new FloatProp(0, dY, 0, yDuration, AGGRESSIVE_EASE);
FloatProp mIconScale = new FloatProp(initialStartScale, scale, 0, APP_LAUNCH_DURATION,
FloatProp mScale = new FloatProp(initialStartScale, scale, 0, APP_LAUNCH_DURATION,
EXAGGERATED_EASE);
FloatProp mIconAlpha = new FloatProp(1f, 0f, APP_LAUNCH_ALPHA_START_DELAY,
alphaDuration, LINEAR);
@@ -542,40 +542,48 @@ public abstract class QuickstepAppTransitionManagerImpl extends LauncherAppTrans
@Override
public void onUpdate(float percent) {
// Calculate app icon size.
float iconWidth = bounds.width() * mIconScale.value;
float iconHeight = bounds.height() * mIconScale.value;
// Calculate the size.
float width = bounds.width() * mScale.value;
float height = bounds.height() * mScale.value;
// Animate the window crop so that it starts off as a square.
final int windowWidth;
final int windowHeight;
// Animate the crop so that it starts off as a square.
final int cropWidth;
final int cropHeight;
if (mDeviceProfile.isVerticalBarLayout()) {
windowWidth = (int) mCroppedSize.value;
windowHeight = windowTargetBounds.height();
cropWidth = (int) mCroppedSize.value;
cropHeight = windowTargetBounds.height();
} else {
windowWidth = windowTargetBounds.width();
windowHeight = (int) mCroppedSize.value;
cropWidth = windowTargetBounds.width();
cropHeight = (int) mCroppedSize.value;
}
crop.set(0, 0, windowWidth, windowHeight);
crop.set(0, 0, cropWidth, cropHeight);
// Scale the app window to match the icon size.
float scaleX = iconWidth / windowWidth;
float scaleY = iconHeight / windowHeight;
// Scale the size to match the crop.
float scaleX = width / cropWidth;
float scaleY = height / cropHeight;
float scale = Math.min(1f, Math.max(scaleX, scaleY));
float scaledWindowWidth = windowWidth * scale;
float scaledWindowHeight = windowHeight * scale;
float scaledCropWidth = cropWidth * scale;
float scaledCropHeight = cropHeight * scale;
float offsetX = (scaledCropWidth - width) / 2;
float offsetY = (scaledCropHeight - height) / 2;
float offsetX = (scaledWindowWidth - iconWidth) / 2;
float offsetY = (scaledWindowHeight - iconHeight) / 2;
// Calculate the window position
// Calculate the window position.
temp.set(bounds);
temp.offset(dragLayerBounds[0], dragLayerBounds[1]);
temp.offset(mDx.value, mDy.value);
Utilities.scaleRectFAboutCenter(temp, mIconScale.value);
float transX0 = temp.left - offsetX;
float transY0 = temp.top - offsetY;
Utilities.scaleRectFAboutCenter(temp, mScale.value);
float windowTransX0 = temp.left - offsetX;
float windowTransY0 = temp.top - offsetY;
// Calculate the icon position.
iconBounds.set(bounds);
iconBounds.offset(mDx.value, mDy.value);
Utilities.scaleRectFAboutCenter(iconBounds, mScale.value);
iconBounds.left -= offsetX;
iconBounds.top -= offsetY;
iconBounds.right += offsetX;
iconBounds.bottom += offsetY;
float croppedHeight = (windowTargetBounds.height() - crop.height()) * scale;
float croppedWidth = (windowTargetBounds.width() - crop.width()) * scale;
@@ -584,28 +592,23 @@ public abstract class QuickstepAppTransitionManagerImpl extends LauncherAppTrans
RemoteAnimationTargetCompat target = appTargets[i];
SurfaceParams.Builder builder = new SurfaceParams.Builder(target.leash);
tmpPos.set(target.position.x, target.position.y);
if (target.localBounds != null) {
final Rect localBounds = target.localBounds;
tmpPos.set(target.localBounds.left, target.localBounds.top);
}
if (target.mode == MODE_OPENING) {
matrix.setScale(scale, scale);
matrix.postTranslate(transX0, transY0);
matrix.mapRect(currentBounds, targetBounds);
if (mDeviceProfile.isVerticalBarLayout()) {
currentBounds.right -= croppedWidth;
} else {
currentBounds.bottom -= croppedHeight;
}
floatingView.update(currentBounds, mIconAlpha.value, percent, 0f,
matrix.postTranslate(windowTransX0, windowTransY0);
floatingView.update(iconBounds, mIconAlpha.value, percent, 0f,
mWindowRadius.value * scale, true /* isOpening */);
builder.withMatrix(matrix)
.withWindowCrop(crop)
.withAlpha(1f - mIconAlpha.value)
.withCornerRadius(mWindowRadius.value);
} else {
tmpPos.set(target.position.x, target.position.y);
if (target.localBounds != null) {
final Rect localBounds = target.localBounds;
tmpPos.set(target.localBounds.left, target.localBounds.top);
}
matrix.setTranslate(tmpPos.x, tmpPos.y);
builder.withMatrix(matrix)
.withWindowCrop(target.screenSpaceBounds)
@@ -16,6 +16,7 @@
package com.android.launcher3.statehandlers;
import static com.android.launcher3.LauncherState.FLAG_HIDE_BACK_BUTTON;
import static com.android.launcher3.anim.Interpolators.LINEAR;
import static com.android.quickstep.AnimatedFloat.VALUE;
@@ -59,7 +60,8 @@ public class BackButtonAlphaHandler implements LauncherStateManager.StateHandler
}
mBackAlpha.value = SystemUiProxy.INSTANCE.get(mLauncher).getLastBackButtonAlpha();
animation.setFloat(mBackAlpha, VALUE, toState.hideBackButton ? 0 : 1, LINEAR);
animation.setFloat(mBackAlpha, VALUE,
mLauncher.shouldBackButtonBeHidden(toState) ? 0 : 1, LINEAR);
}
private void updateBackAlpha() {
@@ -193,8 +193,17 @@ public class DepthController implements LauncherStateManager.StateHandler {
if (windowToken != null) {
mWallpaperManager.setWallpaperZoomOut(windowToken, mDepth);
}
final int blur;
if (mLauncher.isInState(LauncherState.ALL_APPS) && mDepth == 1) {
// All apps has a solid background. We don't need to draw blurs after it's fully
// visible. This will take us out of GPU composition, saving battery and increasing
// performance.
blur = 0;
} else {
blur = (int) (mDepth * mMaxBlurRadius);
}
new TransactionCompat()
.setBackgroundBlurRadius(mSurface, (int) (mDepth * mMaxBlurRadius))
.setBackgroundBlurRadius(mSurface, blur)
.apply();
}
}
@@ -21,6 +21,7 @@ import static com.android.launcher3.anim.Interpolators.AGGRESSIVE_EASE_IN_OUT;
import static com.android.launcher3.anim.Interpolators.LINEAR;
import static com.android.launcher3.graphics.Scrim.SCRIM_PROGRESS;
import static com.android.launcher3.states.StateAnimationConfig.ANIM_OVERVIEW_FADE;
import static com.android.launcher3.states.StateAnimationConfig.ANIM_OVERVIEW_MODAL;
import static com.android.launcher3.states.StateAnimationConfig.ANIM_OVERVIEW_SCALE;
import static com.android.launcher3.states.StateAnimationConfig.ANIM_OVERVIEW_SCRIM_FADE;
import static com.android.launcher3.states.StateAnimationConfig.ANIM_OVERVIEW_TRANSLATE_X;
@@ -66,6 +67,7 @@ public abstract class BaseRecentsViewStateController<T extends RecentsView>
getContentAlphaProperty().set(mRecentsView, state.overviewUi ? 1f : 0);
OverviewScrim scrim = mLauncher.getDragLayer().getOverviewScrim();
SCRIM_PROGRESS.set(scrim, state.getOverviewScrimAlpha(mLauncher));
getTaskModalnessProperty().set(mRecentsView, state.getOverviewModalness());
}
@Override
@@ -101,8 +103,15 @@ public abstract class BaseRecentsViewStateController<T extends RecentsView>
OverviewScrim scrim = mLauncher.getDragLayer().getOverviewScrim();
setter.setFloat(scrim, SCRIM_PROGRESS, toState.getOverviewScrimAlpha(mLauncher),
config.getInterpolator(ANIM_OVERVIEW_SCRIM_FADE, LINEAR));
setter.setFloat(
mRecentsView, getTaskModalnessProperty(),
toState.getOverviewModalness(),
config.getInterpolator(ANIM_OVERVIEW_MODAL, LINEAR));
}
abstract FloatProperty getTaskModalnessProperty();
/**
* Get property for content alpha for the recents view.
*
@@ -21,7 +21,6 @@ import static com.android.quickstep.SysUINavigationMode.Mode.NO_BUTTON;
import android.content.Context;
import com.android.launcher3.AbstractFloatingView;
import com.android.launcher3.Launcher;
import com.android.launcher3.LauncherState;
import com.android.launcher3.allapps.AllAppsContainerView;
@@ -33,7 +32,7 @@ import com.android.quickstep.SysUINavigationMode;
*/
public class AllAppsState extends LauncherState {
private static final int STATE_FLAGS = FLAG_DISABLE_ACCESSIBILITY;
private static final int STATE_FLAGS = FLAG_WORKSPACE_INACCESSIBLE | FLAG_CLOSE_POPUPS;
private static final PageAlphaProvider PAGE_ALPHA_PROVIDER = new PageAlphaProvider(DEACCEL_2) {
@Override
@@ -47,22 +46,10 @@ public class AllAppsState extends LauncherState {
}
@Override
public int getTransitionDuration(Launcher launcher) {
public int getTransitionDuration(Context context) {
return 320;
}
@Override
public void onStateEnabled(Launcher launcher) {
AbstractFloatingView.closeAllOpenViews(launcher);
dispatchWindowStateChanged(launcher);
}
@Override
public void onStateDisabled(Launcher launcher) {
super.onStateDisabled(launcher);
AbstractFloatingView.closeAllOpenViews(launcher);
}
@Override
public String getDescription(Launcher launcher) {
AllAppsContainerView appsView = launcher.getAppsView();
@@ -105,7 +105,7 @@ public interface BaseActivityInterface<T extends BaseDraggingActivity> {
Rect getOverviewWindowBounds(Rect homeBounds, RemoteAnimationTargetCompat target);
boolean shouldMinimizeSplitScreen();
boolean allowMinimizeSplitScreen();
default boolean deferStartingActivity(RecentsAnimationDeviceState deviceState, MotionEvent ev) {
return true;
@@ -19,13 +19,11 @@ import static com.android.launcher3.util.Executors.MAIN_EXECUTOR;
import android.graphics.Rect;
import android.util.ArraySet;
import android.util.Log;
import androidx.annotation.BinderThread;
import androidx.annotation.UiThread;
import com.android.launcher3.Utilities;
import com.android.launcher3.testing.TestProtocol;
import com.android.launcher3.util.Preconditions;
import com.android.systemui.shared.recents.model.ThumbnailData;
import com.android.systemui.shared.system.RecentsAnimationControllerCompat;
@@ -41,15 +39,15 @@ public class RecentsAnimationCallbacks implements
com.android.systemui.shared.system.RecentsAnimationListener {
private final Set<RecentsAnimationListener> mListeners = new ArraySet<>();
private final boolean mShouldMinimizeSplitScreen;
private final boolean mAllowMinimizeSplitScreen;
// TODO(141886704): Remove these references when they are no longer needed
private RecentsAnimationController mController;
private boolean mCancelled;
public RecentsAnimationCallbacks(boolean shouldMinimizeSplitScreen) {
mShouldMinimizeSplitScreen = shouldMinimizeSplitScreen;
public RecentsAnimationCallbacks(boolean allowMinimizeSplitScreen) {
mAllowMinimizeSplitScreen = allowMinimizeSplitScreen;
}
@UiThread
@@ -94,7 +92,7 @@ public class RecentsAnimationCallbacks implements
RecentsAnimationTargets targets = new RecentsAnimationTargets(appTargets,
wallpaperTargets, homeContentInsets, minimizedHomeBounds);
mController = new RecentsAnimationController(animationController,
mShouldMinimizeSplitScreen, this::onAnimationFinished);
mAllowMinimizeSplitScreen, this::onAnimationFinished);
if (mCancelled) {
Utilities.postAsyncCallback(MAIN_EXECUTOR.getHandler(),
@@ -49,21 +49,22 @@ public class RecentsAnimationController {
private final RecentsAnimationControllerCompat mController;
private final Consumer<RecentsAnimationController> mOnFinishedListener;
private final boolean mShouldMinimizeSplitScreen;
private final boolean mAllowMinimizeSplitScreen;
private InputConsumerController mInputConsumerController;
private Supplier<InputConsumer> mInputProxySupplier;
private InputConsumer mInputConsumer;
private boolean mWindowThresholdCrossed = false;
private boolean mUseLauncherSysBarFlags = false;
private boolean mSplitScreenMinimized = false;
private boolean mTouchInProgress;
private boolean mFinishPending;
public RecentsAnimationController(RecentsAnimationControllerCompat controller,
boolean shouldMinimizeSplitScreen,
boolean allowMinimizeSplitScreen,
Consumer<RecentsAnimationController> onFinishedListener) {
mController = controller;
mOnFinishedListener = onFinishedListener;
mShouldMinimizeSplitScreen = shouldMinimizeSplitScreen;
mAllowMinimizeSplitScreen = allowMinimizeSplitScreen;
}
/**
@@ -76,16 +77,31 @@ public class RecentsAnimationController {
/**
* Indicates that the gesture has crossed the window boundary threshold and system UI can be
* update the represent the window behind
* update the system bar flags accordingly.
*/
public void setWindowThresholdCrossed(boolean windowThresholdCrossed) {
if (mWindowThresholdCrossed != windowThresholdCrossed) {
mWindowThresholdCrossed = windowThresholdCrossed;
public void setUseLauncherSystemBarFlags(boolean useLauncherSysBarFlags) {
if (mUseLauncherSysBarFlags != useLauncherSysBarFlags) {
mUseLauncherSysBarFlags = useLauncherSysBarFlags;
UI_HELPER_EXECUTOR.execute(() -> {
mController.setAnimationTargetsBehindSystemBars(!useLauncherSysBarFlags);
});
}
}
/**
* Indicates that the gesture has crossed the window boundary threshold and we should minimize
* if we are in splitscreen.
*/
public void setSplitScreenMinimized(boolean splitScreenMinimized) {
if (!mAllowMinimizeSplitScreen) {
return;
}
if (mSplitScreenMinimized != splitScreenMinimized) {
mSplitScreenMinimized = splitScreenMinimized;
UI_HELPER_EXECUTOR.execute(() -> {
mController.setAnimationTargetsBehindSystemBars(!windowThresholdCrossed);
SystemUiProxy p = SystemUiProxy.INSTANCE.getNoCreate();
if (p != null && mShouldMinimizeSplitScreen) {
p.setSplitScreenMinimized(windowThresholdCrossed);
if (p != null) {
p.setSplitScreenMinimized(splitScreenMinimized);
}
});
}
@@ -17,6 +17,7 @@ package com.android.quickstep;
import static android.content.Intent.ACTION_USER_UNLOCKED;
import static com.android.launcher3.util.DefaultDisplay.CHANGE_ALL;
import static com.android.launcher3.util.Executors.UI_HELPER_EXECUTOR;
import static com.android.quickstep.SysUINavigationMode.Mode.NO_BUTTON;
import static com.android.quickstep.SysUINavigationMode.Mode.THREE_BUTTONS;
@@ -216,6 +217,7 @@ public class RecentsAnimationDeviceState implements
mDefaultDisplay.removeChangeListener(this);
if (newMode.hasGestures) {
mDefaultDisplay.addChangeListener(this);
onDisplayInfoChanged(mDefaultDisplay.getInfo(), CHANGE_ALL);
}
if (newMode == NO_BUTTON) {
@@ -26,7 +26,6 @@ import androidx.annotation.UiThread;
import com.android.launcher3.Utilities;
import com.android.launcher3.config.FeatureFlags;
import com.android.launcher3.testing.TestProtocol;
import com.android.systemui.shared.recents.model.ThumbnailData;
import com.android.systemui.shared.system.ActivityManagerWrapper;
@@ -67,11 +66,17 @@ public class TaskAnimationManager implements RecentsAnimationCallbacks.RecentsAn
final BaseActivityInterface activityInterface = gestureState.getActivityInterface();
mLastGestureState = gestureState;
mCallbacks = new RecentsAnimationCallbacks(activityInterface.shouldMinimizeSplitScreen());
mCallbacks = new RecentsAnimationCallbacks(activityInterface.allowMinimizeSplitScreen());
mCallbacks.addListener(new RecentsAnimationCallbacks.RecentsAnimationListener() {
@Override
public void onRecentsAnimationStart(RecentsAnimationController controller,
RecentsAnimationTargets targets) {
if (mCallbacks == null) {
// It's possible for the recents animation to have finished and be cleaned up
// by the time we process the start callback, and in that case, just we can skip
// handling this call entirely
return;
}
mController = controller;
mTargets = targets;
}
@@ -56,11 +56,6 @@ public class StatsLogCompatManager extends StatsLogManager {
sContext = context;
}
@Override
public void log(LauncherEvent eventId, LauncherAtom.ItemInfo item) {
// Call StatsLog method
}
@Override
public void verify() {
if (!(StatsLogUtils.LAUNCHER_STATE_ALLAPPS == ALLAPPS
@@ -88,17 +83,17 @@ public class StatsLogCompatManager extends StatsLogManager {
ArrayList<LauncherAppWidgetInfo> appWidgets = (ArrayList) dataModel.appWidgets.clone();
for (ItemInfo info : workspaceItems) {
LauncherAtom.ItemInfo atomInfo = info.buildProto(null, null);
LauncherAtom.ItemInfo atomInfo = info.buildProto(null);
// call StatsLog method
}
for (FolderInfo fInfo : folders) {
for (ItemInfo info : fInfo.contents) {
LauncherAtom.ItemInfo atomInfo = info.buildProto(null, fInfo);
LauncherAtom.ItemInfo atomInfo = info.buildProto(fInfo);
// call StatsLog method
}
}
for (ItemInfo info : appWidgets) {
LauncherAtom.ItemInfo atomInfo = info.buildProto(null, null);
LauncherAtom.ItemInfo atomInfo = info.buildProto(null);
// call StatsLog method
}
}
@@ -17,31 +17,17 @@ package com.android.quickstep.util;
import static com.android.launcher3.config.FeatureFlags.ENABLE_OVERVIEW_ACTIONS;
import static com.android.quickstep.SysUINavigationMode.removeShelfFromOverview;
import static java.lang.annotation.RetentionPolicy.SOURCE;
import static com.android.quickstep.util.WindowSizeStrategy.LAUNCHER_ACTIVITY_SIZE_STRATEGY;
import android.content.Context;
import android.content.res.Resources;
import android.graphics.Rect;
import androidx.annotation.AnyThread;
import androidx.annotation.IntDef;
import com.android.launcher3.DeviceProfile;
import com.android.launcher3.R;
import com.android.quickstep.SysUINavigationMode;
import java.lang.annotation.Retention;
public class LayoutUtils {
private static final int MULTI_WINDOW_STRATEGY_HALF_SCREEN = 1;
private static final int MULTI_WINDOW_STRATEGY_DEVICE_PROFILE = 2;
@Retention(SOURCE)
@IntDef({MULTI_WINDOW_STRATEGY_HALF_SCREEN, MULTI_WINDOW_STRATEGY_DEVICE_PROFILE})
private @interface MultiWindowStrategy {}
/**
* The height for the swipe up motion
*/
@@ -53,112 +39,11 @@ public class LayoutUtils {
return swipeHeight;
}
public static void calculateLauncherTaskSize(Context context, DeviceProfile dp, Rect outRect) {
float extraSpace;
if (dp.isVerticalBarLayout()) {
extraSpace = 0;
} else {
Resources res = context.getResources();
if (ENABLE_OVERVIEW_ACTIONS.get() && removeShelfFromOverview(context)) {
//TODO: this needs to account for the swipe gesture height and accessibility
// UI when shown.
extraSpace = res.getDimensionPixelSize(R.dimen.overview_actions_height);
} else {
extraSpace = getDefaultSwipeHeight(context, dp) + dp.workspacePageIndicatorHeight
+ res.getDimensionPixelSize(
R.dimen.dynamic_grid_hotseat_extra_vertical_size)
+ res.getDimensionPixelSize(R.dimen.dynamic_grid_hotseat_bottom_padding);
}
}
calculateTaskSize(context, dp, extraSpace, MULTI_WINDOW_STRATEGY_HALF_SCREEN, outRect);
}
public static void calculateFallbackTaskSize(Context context, DeviceProfile dp, Rect outRect) {
float extraSpace;
if (ENABLE_OVERVIEW_ACTIONS.get() && removeShelfFromOverview(context)) {
extraSpace = context.getResources()
.getDimensionPixelSize(R.dimen.overview_actions_height);
} else {
extraSpace = 0;
}
calculateTaskSize(context, dp, extraSpace, MULTI_WINDOW_STRATEGY_DEVICE_PROFILE, outRect);
}
@AnyThread
public static void calculateTaskSize(Context context, DeviceProfile dp,
float extraVerticalSpace, @MultiWindowStrategy int multiWindowStrategy, Rect outRect) {
float taskWidth, taskHeight, paddingHorz;
Resources res = context.getResources();
Rect insets = dp.getInsets();
final boolean overviewActionsEnabled = ENABLE_OVERVIEW_ACTIONS.get();
if (dp.isMultiWindowMode) {
if (multiWindowStrategy == MULTI_WINDOW_STRATEGY_HALF_SCREEN) {
DeviceProfile fullDp = dp.getFullScreenProfile();
// Use availableWidthPx and availableHeightPx instead of widthPx and heightPx to
// account for system insets
taskWidth = fullDp.availableWidthPx;
taskHeight = fullDp.availableHeightPx;
float halfDividerSize = res.getDimension(R.dimen.multi_window_task_divider_size)
/ 2;
if (fullDp.isLandscape) {
taskWidth = taskWidth / 2 - halfDividerSize;
} else {
taskHeight = taskHeight / 2 - halfDividerSize;
}
} else {
// multiWindowStrategy == MULTI_WINDOW_STRATEGY_DEVICE_PROFILE
taskWidth = dp.widthPx;
taskHeight = dp.heightPx;
}
paddingHorz = res.getDimension(R.dimen.multi_window_task_card_horz_space);
} else {
taskWidth = dp.availableWidthPx;
taskHeight = dp.availableHeightPx;
final int paddingResId;
if (dp.isVerticalBarLayout()) {
paddingResId = R.dimen.landscape_task_card_horz_space;
} else if (overviewActionsEnabled && removeShelfFromOverview(context)) {
paddingResId = R.dimen.portrait_task_card_horz_space_big_overview;
} else {
paddingResId = R.dimen.portrait_task_card_horz_space;
}
paddingHorz = res.getDimension(paddingResId);
}
float topIconMargin = res.getDimension(R.dimen.task_thumbnail_top_margin);
float paddingVert = overviewActionsEnabled && removeShelfFromOverview(context)
? 0 : res.getDimension(R.dimen.task_card_vert_space);
// Note this should be same as dp.availableWidthPx and dp.availableHeightPx unless
// we override the insets ourselves.
int launcherVisibleWidth = dp.widthPx - insets.left - insets.right;
int launcherVisibleHeight = dp.heightPx - insets.top - insets.bottom;
float availableHeight = launcherVisibleHeight
- topIconMargin - extraVerticalSpace - paddingVert;
float availableWidth = launcherVisibleWidth - paddingHorz;
float scale = Math.min(availableWidth / taskWidth, availableHeight / taskHeight);
float outWidth = scale * taskWidth;
float outHeight = scale * taskHeight;
// Center in the visible space
float x = insets.left + (launcherVisibleWidth - outWidth) / 2;
float y = insets.top + Math.max(topIconMargin,
(launcherVisibleHeight - extraVerticalSpace - outHeight) / 2);
outRect.set(Math.round(x), Math.round(y),
Math.round(x) + Math.round(outWidth), Math.round(y) + Math.round(outHeight));
}
public static int getShelfTrackingDistance(Context context, DeviceProfile dp) {
// Track the bottom of the window.
if (ENABLE_OVERVIEW_ACTIONS.get() && removeShelfFromOverview(context)) {
Rect taskSize = new Rect();
calculateLauncherTaskSize(context, dp, taskSize);
LAUNCHER_ACTIVITY_SIZE_STRATEGY.calculateTaskSize(context, dp, taskSize);
return (dp.heightPx - taskSize.height()) / 2;
}
int shelfHeight = dp.hotseatBarSizePx + dp.getInsets().bottom;
@@ -169,6 +54,7 @@ public class LayoutUtils {
/**
* Gets the scale that should be applied to the TaskView so that it matches the target
* TODO: Remove this method
*/
public static float getTaskScale(RecentsOrientedState orientedState,
float srcWidth, float srcHeight, float targetWidth, float targetHeight) {
@@ -17,6 +17,7 @@
package com.android.quickstep.util;
import static android.util.DisplayMetrics.DENSITY_DEVICE_STABLE;
import static android.view.OrientationEventListener.ORIENTATION_UNKNOWN;
import static android.view.Surface.ROTATION_0;
import static android.view.Surface.ROTATION_180;
import static android.view.Surface.ROTATION_270;
@@ -44,6 +45,7 @@ import android.view.OrientationEventListener;
import android.view.Surface;
import androidx.annotation.IntDef;
import androidx.annotation.NonNull;
import com.android.launcher3.DeviceProfile;
import com.android.launcher3.Utilities;
@@ -64,7 +66,7 @@ import java.util.function.IntConsumer;
public final class RecentsOrientedState implements SharedPreferences.OnSharedPreferenceChangeListener {
private static final String TAG = "RecentsOrientedState";
private static final boolean DEBUG = false;
private static final boolean DEBUG = true;
private static final String FIXED_ROTATION_TRANSFORM_SETTING_NAME = "fixed_rotation_transform";
@@ -94,28 +96,29 @@ public final class RecentsOrientedState implements SharedPreferences.OnSharedPre
private static final int FLAG_HOME_ROTATION_ALLOWED_IN_PREFS = 1 << 3;
// If the user has enabled system rotation
private static final int FLAG_SYSTEM_ROTATION_ALLOWED = 1 << 4;
// Multiple orientation is not supported in multiwindow mode
private static final int FLAG_MULTIWINDOW_ROTATION_ALLOWED = 1 << 5;
// Whether to rotation sensor is supported on the device
private static final int FLAG_ROTATION_WATCHER_SUPPORTED = 1 << 5;
private static final int FLAG_ROTATION_WATCHER_SUPPORTED = 1 << 6;
// Whether to enable rotation watcher when multi-rotation is supported
private static final int FLAG_ROTATION_WATCHER_ENABLED = 1 << 6;
private static final int FLAG_ROTATION_WATCHER_ENABLED = 1 << 7;
private static final int MASK_MULTIPLE_ORIENTATION_SUPPORTED_BY_DEVICE =
FLAG_MULTIPLE_ORIENTATION_SUPPORTED_BY_ACTIVITY
| FLAG_MULTIPLE_ORIENTATION_SUPPORTED_BY_DENSITY
| FLAG_MULTIPLE_ORIENTATION_SUPPORTED_BY_FLAG;
private static final int MASK_ACTIVITY_ROTATING =
FLAG_HOME_ROTATION_ALLOWED_IN_PREFS | FLAG_SYSTEM_ROTATION_ALLOWED;
// State for which rotation watcher will be enabled.
// We skip it when home rotation is enabled as in that case, activity itself rotates
// State for which rotation watcher will be enabled. We skip it when home rotation or
// multi-window is enabled as in that case, activity itself rotates.
private static final int VALUE_ROTATION_WATCHER_ENABLED =
MASK_MULTIPLE_ORIENTATION_SUPPORTED_BY_DEVICE | FLAG_SYSTEM_ROTATION_ALLOWED
| FLAG_ROTATION_WATCHER_SUPPORTED | FLAG_ROTATION_WATCHER_ENABLED;
private final Context mContext;
private final ContentResolver mContentResolver;
private final SharedPreferences mSharedPrefs;
private final OrientationEventListener mOrientationListener;
private final WindowSizeStrategy mSizeStrategy;
private final Matrix mTmpMatrix = new Matrix();
private final Matrix mTmpInverseMatrix = new Matrix();
@@ -128,14 +131,16 @@ public final class RecentsOrientedState implements SharedPreferences.OnSharedPre
* is enabled
* @see #setRotationWatcherEnabled(boolean)
*/
public RecentsOrientedState(Context context, boolean rotationSupportedByActivity,
public RecentsOrientedState(Context context, WindowSizeStrategy sizeStrategy,
IntConsumer rotationChangeListener) {
mContext = context;
mContentResolver = context.getContentResolver();
mSharedPrefs = Utilities.getPrefs(context);
mSizeStrategy = sizeStrategy;
mOrientationListener = new OrientationEventListener(context) {
@Override
public void onOrientationChanged(int degrees) {
int newRotation = getRotationForUserDegreesRotated(degrees);
int newRotation = getRotationForUserDegreesRotated(degrees, mPreviousRotation);
if (newRotation != mPreviousRotation) {
mPreviousRotation = newRotation;
rotationChangeListener.accept(newRotation);
@@ -143,7 +148,8 @@ public final class RecentsOrientedState implements SharedPreferences.OnSharedPre
}
};
mFlags = rotationSupportedByActivity ? FLAG_MULTIPLE_ORIENTATION_SUPPORTED_BY_ACTIVITY : 0;
mFlags = sizeStrategy.rotationSupportedByActivity
? FLAG_MULTIPLE_ORIENTATION_SUPPORTED_BY_ACTIVITY : 0;
Resources res = context.getResources();
int originalSmallestWidth = res.getConfiguration().smallestScreenWidthDp
@@ -159,6 +165,13 @@ public final class RecentsOrientedState implements SharedPreferences.OnSharedPre
}
}
/**
* Sets if the host is in multi-window mode
*/
public void setMultiWindowMode(boolean isMultiWindow) {
setFlag(FLAG_MULTIWINDOW_ROTATION_ALLOWED, isMultiWindow);
}
/**
* Sets the appropriate {@link PagedOrientationHandler} for {@link #mOrientationHandler}
* @param touchRotation The rotation the nav bar region that is touched is in
@@ -296,11 +309,12 @@ public final class RecentsOrientedState implements SharedPreferences.OnSharedPre
}
public boolean isHomeRotationAllowed() {
return (mFlags & FLAG_HOME_ROTATION_ALLOWED_IN_PREFS) != 0;
return (mFlags & (FLAG_HOME_ROTATION_ALLOWED_IN_PREFS | FLAG_MULTIWINDOW_ROTATION_ALLOWED))
!= 0;
}
public boolean canLauncherRotate() {
return (mFlags & MASK_ACTIVITY_ROTATING) == MASK_ACTIVITY_ROTATING;
return (mFlags & FLAG_SYSTEM_ROTATION_ALLOWED) != 0 && isHomeRotationAllowed();
}
/**
@@ -331,11 +345,26 @@ public final class RecentsOrientedState implements SharedPreferences.OnSharedPre
Rect insets = dp.getInsets();
float fullWidth = dp.widthPx - insets.left - insets.right;
float fullHeight = dp.heightPx - insets.top - insets.bottom;
final float scale = LayoutUtils.getTaskScale(this,
fullWidth, fullHeight, taskView.width(), taskView.height());
if (dp.isMultiWindowMode) {
mSizeStrategy.getMultiWindowSize(mContext, dp, outPivot);
} else {
outPivot.set(fullWidth, fullHeight);
}
float scale = Math.min(outPivot.x / taskView.width(), outPivot.y / taskView.height());
// We also scale the preview as part of fullScreenParams, so account for that as well.
if (fullWidth > 0) {
scale = scale * dp.widthPx / fullWidth;
}
if (scale == 1) {
outPivot.set(fullWidth / 2, fullHeight / 2);
} else if (dp.isMultiWindowMode) {
float denominator = 1 / (scale - 1);
// Ensure that the task aligns to right bottom for the root view
float y = (scale * taskView.bottom - fullHeight) * denominator;
float x = (scale * taskView.right - fullWidth) * denominator;
outPivot.set(x, y);
} else {
float factor = scale / (scale - 1);
outPivot.set(taskView.left * factor, taskView.top * factor);
@@ -392,17 +421,48 @@ public final class RecentsOrientedState implements SharedPreferences.OnSharedPre
}
@SurfaceRotation
public static int getRotationForUserDegreesRotated(float degrees) {
int threshold = 70;
if (degrees >= (360 - threshold) || degrees < (threshold)) {
return ROTATION_0;
} else if (degrees < (90 + threshold)) {
return ROTATION_270;
} else if (degrees < 180 + threshold) {
return ROTATION_180;
} else {
return ROTATION_90;
public static int getRotationForUserDegreesRotated(float degrees, int currentRotation) {
if (degrees == ORIENTATION_UNKNOWN) {
return currentRotation;
}
int threshold = 70;
switch (currentRotation) {
case ROTATION_0:
if (degrees > 180 && degrees < (360 - threshold)) {
return ROTATION_90;
}
if (degrees < 180 && degrees > threshold) {
return ROTATION_270;
}
break;
case ROTATION_270:
if (degrees < (90 - threshold)) {
return ROTATION_0;
}
if (degrees > (90 + threshold)) {
return ROTATION_180;
}
break;
case ROTATION_180:
if (degrees < (180 - threshold)) {
return ROTATION_270;
}
if (degrees > (180 + threshold)) {
return ROTATION_90;
}
break;
case ROTATION_90:
if (degrees < (270 - threshold)) {
return ROTATION_180;
}
if (degrees > (270 + threshold)) {
return ROTATION_0;
}
break;
}
return currentRotation;
}
public boolean isDisplayPhoneNatural() {
@@ -440,4 +500,19 @@ public final class RecentsOrientedState implements SharedPreferences.OnSharedPre
return Settings.Global.getInt(
context.getContentResolver(), FIXED_ROTATION_TRANSFORM_SETTING_NAME, 1) == 1;
}
@NonNull
@Override
public String toString() {
boolean systemRotationOn = (mFlags & FLAG_SYSTEM_ROTATION_ALLOWED) != 0;
return "["
+ "mDisplayRotation=" + mDisplayRotation
+ " mTouchRotation=" + mTouchRotation
+ " mLauncherRotation=" + mLauncherRotation
+ " mHomeRotation=" + isHomeRotationAllowed()
+ " mSystemRotation=" + systemRotationOn
+ " mFlags=" + mFlags
+ " mOrientationHandler=" + mOrientationHandler
+ "]";
}
}
@@ -25,12 +25,10 @@ import com.android.launcher3.WrappedLauncherAnimationRunner;
import com.android.systemui.shared.system.ActivityOptionsCompat;
import com.android.systemui.shared.system.RemoteAnimationAdapterCompat;
import com.android.systemui.shared.system.RemoteAnimationTargetCompat;
import com.android.systemui.shared.system.TransactionCompat;
public abstract class RemoteAnimationProvider {
LauncherAnimationRunner mAnimationRunner;
static final int Z_BOOST_BASE = 800570000;
public abstract AnimatorSet createWindowAnimation(RemoteAnimationTargetCompat[] appTargets,
RemoteAnimationTargetCompat[] wallpaperTargets);
@@ -52,24 +50,6 @@ public abstract class RemoteAnimationProvider {
new RemoteAnimationAdapterCompat(wrapper, duration, 0));
}
/**
* Prepares the given {@param targets} for a remote animation, and should be called with the
* transaction from the first frame of animation.
*
* @param boostModeTargets The mode indicating which targets to boost in z-order above other
* targets.
*/
static void prepareTargetsForFirstFrame(RemoteAnimationTargetCompat[] targets,
TransactionCompat t, int boostModeTargets) {
for (RemoteAnimationTargetCompat target : targets) {
t.show(target.leash);
}
}
public static int getLayer(RemoteAnimationTargetCompat target, int boostModeTarget) {
return target.prefixOrderIndex;
}
/**
* @return the target with the lowest opaque layer for a certain app animation, or null.
*/
@@ -80,7 +60,7 @@ public abstract class RemoteAnimationProvider {
for (int i = appTargets.length - 1; i >= 0; i--) {
RemoteAnimationTargetCompat target = appTargets[i];
if (target.mode == mode && !target.isTranslucent) {
int layer = getLayer(target, mode);
int layer = target.prefixOrderIndex;
if (layer < lowestLayer) {
lowestLayer = layer;
lowestLayerIndex = i;
@@ -15,7 +15,6 @@
*/
package com.android.quickstep.util;
import static com.android.quickstep.util.RemoteAnimationProvider.prepareTargetsForFirstFrame;
import static com.android.systemui.shared.system.RemoteAnimationTargetCompat.MODE_CLOSING;
import android.animation.ValueAnimator;
@@ -42,7 +41,9 @@ public class RemoteFadeOutAnimationListener implements AnimatorUpdateListener {
public void onAnimationUpdate(ValueAnimator valueAnimator) {
TransactionCompat t = new TransactionCompat();
if (mFirstFrame) {
prepareTargetsForFirstFrame(mTarget.unfilteredApps, t, MODE_CLOSING);
for (RemoteAnimationTargetCompat target : mTarget.unfilteredApps) {
t.show(target.leash);
}
mFirstFrame = false;
}
@@ -0,0 +1,169 @@
/*
* 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.
*/
package com.android.quickstep.util;
import static com.android.launcher3.config.FeatureFlags.ENABLE_OVERVIEW_ACTIONS;
import static com.android.quickstep.SysUINavigationMode.removeShelfFromOverview;
import static com.android.quickstep.util.LayoutUtils.getDefaultSwipeHeight;
import android.content.Context;
import android.content.res.Resources;
import android.graphics.PointF;
import android.graphics.Rect;
import com.android.launcher3.DeviceProfile;
import com.android.launcher3.R;
/**
* Utility class to wrap different layout behavior for Launcher and RecentsView
* TODO: Merge is with {@link com.android.quickstep.BaseActivityInterface} once we remove the
* state dependent members from {@link com.android.quickstep.LauncherActivityInterface}
*/
public abstract class WindowSizeStrategy {
private final PointF mTempPoint = new PointF();
public final boolean rotationSupportedByActivity;
private WindowSizeStrategy(boolean rotationSupportedByActivity) {
this.rotationSupportedByActivity = rotationSupportedByActivity;
}
/**
* Sets the expected window size in multi-window mode
*/
public abstract void getMultiWindowSize(Context context, DeviceProfile dp, PointF out);
/**
* Calculates the taskView size for the provided device configuration
*/
public final void calculateTaskSize(Context context, DeviceProfile dp, Rect outRect) {
calculateTaskSize(context, dp, getExtraSpace(context, dp), outRect);
}
abstract float getExtraSpace(Context context, DeviceProfile dp);
private void calculateTaskSize(
Context context, DeviceProfile dp, float extraVerticalSpace, Rect outRect) {
float taskWidth, taskHeight, paddingHorz;
Resources res = context.getResources();
Rect insets = dp.getInsets();
final boolean showLargeTaskSize = showOverviewActions(context);
if (dp.isMultiWindowMode) {
getMultiWindowSize(context, dp, mTempPoint);
taskWidth = mTempPoint.x;
taskHeight = mTempPoint.y;
paddingHorz = res.getDimension(R.dimen.multi_window_task_card_horz_space);
} else {
taskWidth = dp.availableWidthPx;
taskHeight = dp.availableHeightPx;
final int paddingResId;
if (dp.isVerticalBarLayout()) {
paddingResId = R.dimen.landscape_task_card_horz_space;
} else if (showLargeTaskSize) {
paddingResId = R.dimen.portrait_task_card_horz_space_big_overview;
} else {
paddingResId = R.dimen.portrait_task_card_horz_space;
}
paddingHorz = res.getDimension(paddingResId);
}
float topIconMargin = res.getDimension(R.dimen.task_thumbnail_top_margin);
float paddingVert = showLargeTaskSize
? 0 : res.getDimension(R.dimen.task_card_vert_space);
// Note this should be same as dp.availableWidthPx and dp.availableHeightPx unless
// we override the insets ourselves.
int launcherVisibleWidth = dp.widthPx - insets.left - insets.right;
int launcherVisibleHeight = dp.heightPx - insets.top - insets.bottom;
float availableHeight = launcherVisibleHeight
- topIconMargin - extraVerticalSpace - paddingVert;
float availableWidth = launcherVisibleWidth - paddingHorz;
float scale = Math.min(availableWidth / taskWidth, availableHeight / taskHeight);
float outWidth = scale * taskWidth;
float outHeight = scale * taskHeight;
// Center in the visible space
float x = insets.left + (launcherVisibleWidth - outWidth) / 2;
float y = insets.top + Math.max(topIconMargin,
(launcherVisibleHeight - extraVerticalSpace - outHeight) / 2);
outRect.set(Math.round(x), Math.round(y),
Math.round(x) + Math.round(outWidth), Math.round(y) + Math.round(outHeight));
}
public static final WindowSizeStrategy LAUNCHER_ACTIVITY_SIZE_STRATEGY =
new WindowSizeStrategy(true) {
@Override
public void getMultiWindowSize(Context context, DeviceProfile dp, PointF out) {
DeviceProfile fullDp = dp.getFullScreenProfile();
// Use availableWidthPx and availableHeightPx instead of widthPx and heightPx to
// account for system insets
out.set(fullDp.availableWidthPx, fullDp.availableHeightPx);
float halfDividerSize = context.getResources()
.getDimension(R.dimen.multi_window_task_divider_size) / 2;
if (fullDp.isLandscape) {
out.x = out.x / 2 - halfDividerSize;
} else {
out.y = out.y / 2 - halfDividerSize;
}
}
@Override
float getExtraSpace(Context context, DeviceProfile dp) {
if (dp.isVerticalBarLayout()) {
return 0;
} else {
Resources res = context.getResources();
if (showOverviewActions(context)) {
//TODO: this needs to account for the swipe gesture height and accessibility
// UI when shown.
return res.getDimensionPixelSize(R.dimen.overview_actions_height);
} else {
return getDefaultSwipeHeight(context, dp) + dp.workspacePageIndicatorHeight
+ res.getDimensionPixelSize(
R.dimen.dynamic_grid_hotseat_extra_vertical_size)
+ res.getDimensionPixelSize(
R.dimen.dynamic_grid_hotseat_bottom_padding);
}
}
}
};
public static final WindowSizeStrategy FALLBACK_RECENTS_SIZE_STRATEGY =
new WindowSizeStrategy(false) {
@Override
public void getMultiWindowSize(Context context, DeviceProfile dp, PointF out) {
out.set(dp.widthPx, dp.heightPx);
}
@Override
float getExtraSpace(Context context, DeviceProfile dp) {
return showOverviewActions(context)
? context.getResources().getDimensionPixelSize(R.dimen.overview_actions_height)
: 0;
}
};
static boolean showOverviewActions(Context context) {
return ENABLE_OVERVIEW_ACTIONS.get() && removeShelfFromOverview(context);
}
}
+6 -6
View File
@@ -133,14 +133,14 @@
<string name="notification_dismissed" msgid="6002233469409822874">"Obaveštenje je odbačeno"</string>
<string name="all_apps_personal_tab" msgid="4190252696685155002">"Lične"</string>
<string name="all_apps_work_tab" msgid="4884822796154055118">"Poslovne"</string>
<string name="work_profile_toggle_label" msgid="3081029915775481146">"Profil za Work"</string>
<string name="work_profile_toggle_label" msgid="3081029915775481146">"Poslovni profil"</string>
<string name="work_profile_edu_personal_apps" msgid="4155536355149317441">"Lični podaci su odvojeni i sakriveni od aplikacija za posao"</string>
<string name="work_profile_edu_work_apps" msgid="237051938268703058">"IT administrator vidi aplikacije za posao i podatke"</string>
<string name="work_profile_edu_work_apps" msgid="237051938268703058">"IT administrator vidi poslovne aplikacije i podatke"</string>
<string name="work_profile_edu_next" msgid="8783418929296503629">"Dalje"</string>
<string name="work_profile_edu_accept" msgid="6069788082535149071">"Važi"</string>
<string name="work_apps_paused_title" msgid="2389865654362803723">"Profil za Work je pauziran"</string>
<string name="work_apps_paused_body" msgid="5388070126389079077">"Aplikacije za posao ne mogu da vam šalju obaveštenja, koriste bateriju ni pristupaju lokaciji"</string>
<string name="work_apps_paused_content_description" msgid="7553586952985486433">"Profil za Work je pauziran. Aplikacije za posao ne mogu da vam šalju obaveštenja, koriste bateriju niti pristupaju lokaciji"</string>
<string name="work_switch_tip" msgid="808075064383839144">"Pauzirajte aplikacije za posao i obaveštenja"</string>
<string name="work_apps_paused_title" msgid="2389865654362803723">"Poslovni profil je pauziran"</string>
<string name="work_apps_paused_body" msgid="5388070126389079077">"Poslovne aplikacije ne mogu da vam šalju obaveštenja, koriste bateriju ni pristupaju lokaciji"</string>
<string name="work_apps_paused_content_description" msgid="7553586952985486433">"Poslovni profil je pauziran. Poslovne aplikacije ne mogu da vam šalju obaveštenja, koriste bateriju niti pristupaju lokaciji"</string>
<string name="work_switch_tip" msgid="808075064383839144">"Pauzirajte poslovne aplikacije i obaveštenja"</string>
<string name="remote_action_failed" msgid="1383965239183576790">"Nije uspelo: <xliff:g id="WHAT">%1$s</xliff:g>"</string>
</resources>
+3 -3
View File
@@ -134,12 +134,12 @@
<string name="all_apps_work_tab" msgid="4884822796154055118">"অফিস"</string>
<string name="work_profile_toggle_label" msgid="3081029915775481146">"অফিসের প্রোফাইল"</string>
<string name="work_profile_edu_personal_apps" msgid="4155536355149317441">"অফিসের অ্যাপের থেকে ব্যক্তিগত ডেটা আলাদা করে লুকিয়ে রাখা হয়"</string>
<string name="work_profile_edu_work_apps" msgid="237051938268703058">"অফিসের অ্যাপ এবং ডেটা আপনার আইটি অ্যাডমিন দেখতে পাবেন"</string>
<string name="work_profile_edu_work_apps" msgid="237051938268703058">"আপনার আইটি অ্যাডমিন অফিস অ্যাপ এবং ডেটা দেখতে পাবেন"</string>
<string name="work_profile_edu_next" msgid="8783418929296503629">"পরের"</string>
<string name="work_profile_edu_accept" msgid="6069788082535149071">"বুঝেছি"</string>
<string name="work_apps_paused_title" msgid="2389865654362803723">"অফিস প্রোফাইল বন্ধ করা আছে"</string>
<string name="work_apps_paused_body" msgid="5388070126389079077">"অফিসের অ্যাপ আপনাকে বিজ্ঞপ্তি পাঠাতে, আপনার ব্যাটারি ব্যবহার করতে বা লোকেশন অ্যাক্সেস করতে পারে না"</string>
<string name="work_apps_paused_body" msgid="5388070126389079077">"অফিস অ্যাপ আপনাকে বিজ্ঞপ্তি পাঠাতে, আপনার ব্যাটারি ব্যবহার করতে বা লোকেশন অ্যাক্সেস করতে পারে না"</string>
<string name="work_apps_paused_content_description" msgid="7553586952985486433">"অফিসের প্রোফাইল পজ করা আছে। অফিসের অ্যাপ আপনাকে বিজ্ঞপ্তি পাঠাতে, ব্যাটারি ব্যবহার করতে বা লোকেশন অ্যাক্সেস করতে পারবে না"</string>
<string name="work_switch_tip" msgid="808075064383839144">"অফিসের অ্যাপ এবং বিজ্ঞপ্তি বন্ধ করুন"</string>
<string name="work_switch_tip" msgid="808075064383839144">"অফিস অ্যাপ এবং বিজ্ঞপ্তি বন্ধ করুন"</string>
<string name="remote_action_failed" msgid="1383965239183576790">"কাজটি করা যায়নি: <xliff:g id="WHAT">%1$s</xliff:g>"</string>
</resources>
+1 -1
View File
@@ -139,7 +139,7 @@
<string name="work_profile_edu_next" msgid="8783418929296503629">"Sljedeće"</string>
<string name="work_profile_edu_accept" msgid="6069788082535149071">"Razumijem"</string>
<string name="work_apps_paused_title" msgid="2389865654362803723">"Radni profil je pauziran"</string>
<string name="work_apps_paused_body" msgid="5388070126389079077">"Poslovne aplikacije ne mogu vam slati obavještenja, koristiti bateriju ili pristupiti vašoj lokaciji"</string>
<string name="work_apps_paused_body" msgid="5388070126389079077">"Poslovne aplikacije vam ne mogu slati obavještenja, koristiti bateriju ili pristupiti vašoj lokaciji"</string>
<string name="work_apps_paused_content_description" msgid="7553586952985486433">"Radni profil je pauziran. Poslovne aplikacije vam ne mogu slati obavještenja, koristiti bateriju ili pristupiti vašoj lokaciji"</string>
<string name="work_switch_tip" msgid="808075064383839144">"Pauzirajte poslovne aplikacije i obavještenja"</string>
<string name="remote_action_failed" msgid="1383965239183576790">"Nije uspjelo: <xliff:g id="WHAT">%1$s</xliff:g>"</string>
+2 -2
View File
@@ -133,12 +133,12 @@
<string name="all_apps_personal_tab" msgid="4190252696685155002">"Privat"</string>
<string name="all_apps_work_tab" msgid="4884822796154055118">"Geschäftlich"</string>
<string name="work_profile_toggle_label" msgid="3081029915775481146">"Arbeitsprofil"</string>
<string name="work_profile_edu_personal_apps" msgid="4155536355149317441">"Personenbezogene Daten sind separat und für geschäftliche Apps nicht sichtbar"</string>
<string name="work_profile_edu_personal_apps" msgid="4155536355149317441">"Personenbezogene Daten sind für geschäftlichen Apps nicht sichtbar oder zugänglich"</string>
<string name="work_profile_edu_work_apps" msgid="237051938268703058">"Geschäftliche Apps und Daten können von deinem IT-Administrator eingesehen werden"</string>
<string name="work_profile_edu_next" msgid="8783418929296503629">"Weiter"</string>
<string name="work_profile_edu_accept" msgid="6069788082535149071">"OK"</string>
<string name="work_apps_paused_title" msgid="2389865654362803723">"Arbeitsprofil pausiert"</string>
<string name="work_apps_paused_body" msgid="5388070126389079077">"Geschäftliche Apps können dir Benachrichtigungen senden, deinen Akku verbrauchen oder auf deinen Standort zugreifen"</string>
<string name="work_apps_paused_body" msgid="5388070126389079077">"Geschäftliche Apps können dir keine Benachrichtigungen senden, deinen Akku nicht nutzen und nicht auf deinen Standort zugreifen"</string>
<string name="work_apps_paused_content_description" msgid="7553586952985486433">"Das Arbeitsprofil ist pausiert. Geschäftliche Apps können dir keine Benachrichtigungen senden, deinen Akku nicht beanspruchen und nicht auf deinen Standort zugreifen."</string>
<string name="work_switch_tip" msgid="808075064383839144">"Geschäftliche Apps und Benachrichtigungen pausieren"</string>
<string name="remote_action_failed" msgid="1383965239183576790">"Fehler: <xliff:g id="WHAT">%1$s</xliff:g>"</string>
+4 -4
View File
@@ -133,13 +133,13 @@
<string name="all_apps_personal_tab" msgid="4190252696685155002">"Προσωπικές"</string>
<string name="all_apps_work_tab" msgid="4884822796154055118">"Εργασίας"</string>
<string name="work_profile_toggle_label" msgid="3081029915775481146">"Προφίλ εργασίας"</string>
<string name="work_profile_edu_personal_apps" msgid="4155536355149317441">"Τα προσωπικά δεδομένα βρίσκονται σε ξεχωριστή θέση και δεν είναι ορατά από τις εφαρμογές εργασιών"</string>
<string name="work_profile_edu_work_apps" msgid="237051938268703058">"Οι εφαρμογές εργασιών και τα δεδομένα τους είναι ορατά στον διαχειριστή IT"</string>
<string name="work_profile_edu_personal_apps" msgid="4155536355149317441">"Τα προσωπικά δεδομένα βρίσκονται σε ξεχωριστή θέση και δεν είναι ορατά από τις εφαρμογές εργασίας"</string>
<string name="work_profile_edu_work_apps" msgid="237051938268703058">"Οι εφαρμογές εργασίας και τα δεδομένα τους είναι ορατά στον διαχειριστή IT"</string>
<string name="work_profile_edu_next" msgid="8783418929296503629">"Επόμενο"</string>
<string name="work_profile_edu_accept" msgid="6069788082535149071">"Το κατάλαβα"</string>
<string name="work_apps_paused_title" msgid="2389865654362803723">"Το προφίλ εργασίας έχει τεθεί σε παύση"</string>
<string name="work_apps_paused_body" msgid="5388070126389079077">"Οι εφαρμογές εργασιών δεν μπορούν να σας στέλνουν ειδοποιήσεις, να χρησιμοποιούν την μπαταρία ή να έχουν πρόσβαση στην τοποθεσία σας"</string>
<string name="work_apps_paused_body" msgid="5388070126389079077">"Οι εφαρμογές εργασίας δεν μπορούν να σας στέλνουν ειδοποιήσεις, να χρησιμοποιούν την μπαταρία ή να έχουν πρόσβαση στην τοποθεσία σας"</string>
<string name="work_apps_paused_content_description" msgid="7553586952985486433">"Το προφίλ εργασίας έχει τεθεί σε παύση. Οι εφαρμογές εργασιών δεν μπορούν να σας στέλνουν ειδοποιήσεις, να χρησιμοποιούν την μπαταρία ή να έχουν πρόσβαση στην τοποθεσία σας."</string>
<string name="work_switch_tip" msgid="808075064383839144">"Παύση εφαρμογών εργασιών και ειδοποιήσεων"</string>
<string name="work_switch_tip" msgid="808075064383839144">"Παύση εφαρμογών εργασίας και ειδοποιήσεων"</string>
<string name="remote_action_failed" msgid="1383965239183576790">"Αποτυχία: <xliff:g id="WHAT">%1$s</xliff:g>"</string>
</resources>
+1 -1
View File
@@ -138,7 +138,7 @@
<string name="work_profile_edu_next" msgid="8783418929296503629">"Next"</string>
<string name="work_profile_edu_accept" msgid="6069788082535149071">"OK"</string>
<string name="work_apps_paused_title" msgid="2389865654362803723">"Work profile is paused"</string>
<string name="work_apps_paused_body" msgid="5388070126389079077">"Work apps cant send you notifications, use your battery or access your location"</string>
<string name="work_apps_paused_body" msgid="5388070126389079077">"Work apps can\'t send you notifications, use your battery or access your location"</string>
<string name="work_apps_paused_content_description" msgid="7553586952985486433">"Work profile is paused. Work apps can\'t send you notifications, use your battery or access your location"</string>
<string name="work_switch_tip" msgid="808075064383839144">"Pause work apps and notifications"</string>
<string name="remote_action_failed" msgid="1383965239183576790">"Failed: <xliff:g id="WHAT">%1$s</xliff:g>"</string>
+1 -1
View File
@@ -138,7 +138,7 @@
<string name="work_profile_edu_next" msgid="8783418929296503629">"Next"</string>
<string name="work_profile_edu_accept" msgid="6069788082535149071">"OK"</string>
<string name="work_apps_paused_title" msgid="2389865654362803723">"Work profile is paused"</string>
<string name="work_apps_paused_body" msgid="5388070126389079077">"Work apps cant send you notifications, use your battery or access your location"</string>
<string name="work_apps_paused_body" msgid="5388070126389079077">"Work apps can\'t send you notifications, use your battery or access your location"</string>
<string name="work_apps_paused_content_description" msgid="7553586952985486433">"Work profile is paused. Work apps can\'t send you notifications, use your battery or access your location"</string>
<string name="work_switch_tip" msgid="808075064383839144">"Pause work apps and notifications"</string>
<string name="remote_action_failed" msgid="1383965239183576790">"Failed: <xliff:g id="WHAT">%1$s</xliff:g>"</string>
+1 -1
View File
@@ -138,7 +138,7 @@
<string name="work_profile_edu_next" msgid="8783418929296503629">"Next"</string>
<string name="work_profile_edu_accept" msgid="6069788082535149071">"OK"</string>
<string name="work_apps_paused_title" msgid="2389865654362803723">"Work profile is paused"</string>
<string name="work_apps_paused_body" msgid="5388070126389079077">"Work apps cant send you notifications, use your battery or access your location"</string>
<string name="work_apps_paused_body" msgid="5388070126389079077">"Work apps can\'t send you notifications, use your battery or access your location"</string>
<string name="work_apps_paused_content_description" msgid="7553586952985486433">"Work profile is paused. Work apps can\'t send you notifications, use your battery or access your location"</string>
<string name="work_switch_tip" msgid="808075064383839144">"Pause work apps and notifications"</string>
<string name="remote_action_failed" msgid="1383965239183576790">"Failed: <xliff:g id="WHAT">%1$s</xliff:g>"</string>
+1 -1
View File
@@ -138,7 +138,7 @@
<string name="work_profile_edu_next" msgid="8783418929296503629">"Next"</string>
<string name="work_profile_edu_accept" msgid="6069788082535149071">"OK"</string>
<string name="work_apps_paused_title" msgid="2389865654362803723">"Work profile is paused"</string>
<string name="work_apps_paused_body" msgid="5388070126389079077">"Work apps cant send you notifications, use your battery or access your location"</string>
<string name="work_apps_paused_body" msgid="5388070126389079077">"Work apps can\'t send you notifications, use your battery or access your location"</string>
<string name="work_apps_paused_content_description" msgid="7553586952985486433">"Work profile is paused. Work apps can\'t send you notifications, use your battery or access your location"</string>
<string name="work_switch_tip" msgid="808075064383839144">"Pause work apps and notifications"</string>
<string name="remote_action_failed" msgid="1383965239183576790">"Failed: <xliff:g id="WHAT">%1$s</xliff:g>"</string>
+3 -3
View File
@@ -133,13 +133,13 @@
<string name="all_apps_personal_tab" msgid="4190252696685155002">"Personal"</string>
<string name="all_apps_work_tab" msgid="4884822796154055118">"Trabajo"</string>
<string name="work_profile_toggle_label" msgid="3081029915775481146">"Perfil de trabajo"</string>
<string name="work_profile_edu_personal_apps" msgid="4155536355149317441">"Los datos personales están separados y ocultos de las aplicaciones de trabajo, que no pueden acceder a ellos"</string>
<string name="work_profile_edu_personal_apps" msgid="4155536355149317441">"Los datos personales están separados y ocultos de las aplicaciones de trabajo"</string>
<string name="work_profile_edu_work_apps" msgid="237051938268703058">"Tu administrador de TI puede ver tus aplicaciones y datos de trabajo"</string>
<string name="work_profile_edu_next" msgid="8783418929296503629">"Siguiente"</string>
<string name="work_profile_edu_accept" msgid="6069788082535149071">"Listo"</string>
<string name="work_apps_paused_title" msgid="2389865654362803723">"El perfil de trabajo está en pausa"</string>
<string name="work_apps_paused_body" msgid="5388070126389079077">"Las aplicaciones de trabajo no pueden enviarte notificaciones, gastar tu batería ni acceder a tu ubicación"</string>
<string name="work_apps_paused_body" msgid="5388070126389079077">"Las aplicaciones de trabajo no pueden enviarte notificaciones, gastar batería ni acceder a tu ubicación"</string>
<string name="work_apps_paused_content_description" msgid="7553586952985486433">"El perfil de trabajo está en pausa. Las aplicaciones de trabajo no pueden enviarte notificaciones, consumir tu batería ni acceder a tu ubicación"</string>
<string name="work_switch_tip" msgid="808075064383839144">"Pausar notificaciones y aplicaciones de trabajo"</string>
<string name="work_switch_tip" msgid="808075064383839144">"Pausa apps y notificaciones de trabajo"</string>
<string name="remote_action_failed" msgid="1383965239183576790">"Se ha producido un error: <xliff:g id="WHAT">%1$s</xliff:g>"</string>
</resources>
+1 -1
View File
@@ -138,7 +138,7 @@
<string name="work_profile_edu_next" msgid="8783418929296503629">"Järgmine"</string>
<string name="work_profile_edu_accept" msgid="6069788082535149071">"Selge"</string>
<string name="work_apps_paused_title" msgid="2389865654362803723">"Tööprofiil on peatatud"</string>
<string name="work_apps_paused_body" msgid="5388070126389079077">"Töörakendused ei saa teile märguandeid saata, akut kasutada ega teie asukohale juurdepääseda"</string>
<string name="work_apps_paused_body" msgid="5388070126389079077">"Töörakendused ei saa teile märguandeid saata, akut kasutada ega teie asukohale juurde pääseda"</string>
<string name="work_apps_paused_content_description" msgid="7553586952985486433">"Tööprofiil on peatatud. Töörakendused ei saa teile märguandeid saata, akut kasutada ega teie asukohale juurde pääseda"</string>
<string name="work_switch_tip" msgid="808075064383839144">"Peatage töörakendused ja märguanded"</string>
<string name="remote_action_failed" msgid="1383965239183576790">"Nurjus: <xliff:g id="WHAT">%1$s</xliff:g>"</string>
+1 -1
View File
@@ -133,7 +133,7 @@
<string name="all_apps_personal_tab" msgid="4190252696685155002">"شخصی"</string>
<string name="all_apps_work_tab" msgid="4884822796154055118">"محل کار"</string>
<string name="work_profile_toggle_label" msgid="3081029915775481146">"نمایه کاری"</string>
<string name="work_profile_edu_personal_apps" msgid="4155536355149317441">"داده‌های شخصی مجزا هستند و از دسترس برنامه‌های کاری پنهان هستند"</string>
<string name="work_profile_edu_personal_apps" msgid="4155536355149317441">"داده‌های شخصی از برنامه‌های کاری جدا است و از آن پنهان است"</string>
<string name="work_profile_edu_work_apps" msgid="237051938268703058">"برنامه‌های کاری و داده‌ها برای سرپرست فناوری اطلاعات نمایان هستند"</string>
<string name="work_profile_edu_next" msgid="8783418929296503629">"بعدی"</string>
<string name="work_profile_edu_accept" msgid="6069788082535149071">"متوجه‌ام"</string>
+1 -1
View File
@@ -80,7 +80,7 @@
<string name="widget_button_text" msgid="2880537293434387943">"Widgets"</string>
<string name="wallpaper_button_text" msgid="8404103075899945851">"Fonds d\'écran"</string>
<string name="styles_wallpaper_button_text" msgid="4342122323125579619">"Styles et fonds d\'écran"</string>
<string name="settings_button_text" msgid="8873672322605444408">"Paramètres d\'écran d\'accueil"</string>
<string name="settings_button_text" msgid="8873672322605444408">"Paramètres d\'accueil"</string>
<string name="msg_disabled_by_admin" msgid="6898038085516271325">"Désactivé par votre administrateur"</string>
<string name="allow_rotation_title" msgid="7728578836261442095">"Autoriser la rotation de l\'écran d\'accueil"</string>
<string name="allow_rotation_desc" msgid="8662546029078692509">"Lorsque vous faites pivoter le téléphone"</string>
+2 -2
View File
@@ -132,12 +132,12 @@
<string name="notification_dismissed" msgid="6002233469409822874">"સૂચના છોડી દીધી"</string>
<string name="all_apps_personal_tab" msgid="4190252696685155002">"મનગમતી ઍપ"</string>
<string name="all_apps_work_tab" msgid="4884822796154055118">"કાર્યાલયની ઍપ"</string>
<string name="work_profile_toggle_label" msgid="3081029915775481146">"કાર્યાલયની પ્રોફાઇલ"</string>
<string name="work_profile_toggle_label" msgid="3081029915775481146">"ઑફિસની પ્રોફાઇલ"</string>
<string name="work_profile_edu_personal_apps" msgid="4155536355149317441">"વ્યક્તિગત ડેટા ઑફિસ માટેની ઍપથી અલગ અને છુપાવીને રાખેલો છે"</string>
<string name="work_profile_edu_work_apps" msgid="237051938268703058">"ઑફિસ માટેની ઍપ અને ડેટા તમારા IT વ્યવસ્થાપકને દેખાય છે"</string>
<string name="work_profile_edu_next" msgid="8783418929296503629">"આગળ"</string>
<string name="work_profile_edu_accept" msgid="6069788082535149071">"સમજાઈ ગયું"</string>
<string name="work_apps_paused_title" msgid="2389865654362803723">"કાર્યાલયની પ્રોફાઇલ થોભાવી છે"</string>
<string name="work_apps_paused_title" msgid="2389865654362803723">"ઑફિસની પ્રોફાઇલ થોભાવી છે"</string>
<string name="work_apps_paused_body" msgid="5388070126389079077">"ઑફિસ માટેની ઍપ તમને નોટિફિકેશન મોકલી શકતી નથી, તમારી બૅટરી વાપરી શકતી નથી કે તમારું સ્થાન ઍક્સેસ કરી શકતી નથી"</string>
<string name="work_apps_paused_content_description" msgid="7553586952985486433">"કાર્યાલયની પ્રોફાઇલ થોભાવી છે. ઑફિસ માટેની ઍપ તમને નોટિફિકેશન મોકલી શકતી નથી, તમારી બૅટરી વાપરી શકતી નથી કે તમારું સ્થાન ઍક્સેસ કરી શકતી નથી"</string>
<string name="work_switch_tip" msgid="808075064383839144">"ઑફિસ માટેની ઍપ અને નોટિફિકેશન થોભાવો"</string>
+2 -2
View File
@@ -133,8 +133,8 @@
<string name="all_apps_personal_tab" msgid="4190252696685155002">"निजी ऐप"</string>
<string name="all_apps_work_tab" msgid="4884822796154055118">"काम से जुड़े ऐप"</string>
<string name="work_profile_toggle_label" msgid="3081029915775481146">"वर्क प्रोफ़ाइल"</string>
<string name="work_profile_edu_personal_apps" msgid="4155536355149317441">"निजी डेटा को अलग र ऑफ़िस के काम से जुड़े ऐप्लिकेशन से छिपा कर रखा जाता है"</string>
<string name="work_profile_edu_work_apps" msgid="237051938268703058">"ऑफ़िस के काम से जुड़े ऐप्लिकेशन और डेटा आपके आईटी एडमिन को दिखते हैं"</string>
<string name="work_profile_edu_personal_apps" msgid="4155536355149317441">"निजी डेटा को अलग रखा जाता है. साथ ही, ऑफ़िस के काम से जुड़े ऐप्लिकेशन से छिपा कर रखा जाता है"</string>
<string name="work_profile_edu_work_apps" msgid="237051938268703058">"ऑफ़िस के काम से जुड़े ऐप्लिकेशन और डेटा, आपके आईटी एडमिन को दिखते हैं"</string>
<string name="work_profile_edu_next" msgid="8783418929296503629">"आगे बढ़ें"</string>
<string name="work_profile_edu_accept" msgid="6069788082535149071">"ठीक है"</string>
<string name="work_apps_paused_title" msgid="2389865654362803723">"वर्क प्रोफ़ाइल रोक दी गई है"</string>
+2 -2
View File
@@ -137,9 +137,9 @@
<string name="work_profile_edu_work_apps" msgid="237051938268703058">"A munkahelyi alkalmazásokat és adatokat látja a rendszergazda"</string>
<string name="work_profile_edu_next" msgid="8783418929296503629">"Tovább"</string>
<string name="work_profile_edu_accept" msgid="6069788082535149071">"Értem"</string>
<string name="work_apps_paused_title" msgid="2389865654362803723">"A munkaprofil szüneteltetve van"</string>
<string name="work_apps_paused_title" msgid="2389865654362803723">"A munkaprofil használata szünetel"</string>
<string name="work_apps_paused_body" msgid="5388070126389079077">"A munkahelyi alkalmazások nem küldhetnek értesítéseket, nem használhatják az akkumulátort, és nem férhetnek hozzá az Ön tartózkodási helyéhez"</string>
<string name="work_apps_paused_content_description" msgid="7553586952985486433">"A munkaprofil szüneteltetve van. A munkahelyi alkalmazások nem küldhetnek értesítéseket, nem használhatják az akkumulátort, és nem férhetnek hozzá az Ön tartózkodási helyéhez"</string>
<string name="work_apps_paused_content_description" msgid="7553586952985486433">"A munkaprofil használata szünetel. A munkahelyi alkalmazások nem küldhetnek értesítéseket, nem használhatják az akkumulátort, és nem férhetnek hozzá az Ön tartózkodási helyéhez"</string>
<string name="work_switch_tip" msgid="808075064383839144">"Munkahelyi alkalmazások és értesítések szüneteltetése"</string>
<string name="remote_action_failed" msgid="1383965239183576790">"Sikertelen: <xliff:g id="WHAT">%1$s</xliff:g>"</string>
</resources>
+3 -3
View File
@@ -133,13 +133,13 @@
<string name="all_apps_personal_tab" msgid="4190252696685155002">"Անձնական"</string>
<string name="all_apps_work_tab" msgid="4884822796154055118">"Աշխատանքային"</string>
<string name="work_profile_toggle_label" msgid="3081029915775481146">"Աշխատանքային պրոֆիլ"</string>
<string name="work_profile_edu_personal_apps" msgid="4155536355149317441">"Անձնական հավելվածները առանձնացված են և թաքցված աշխատանքային հավելվածներից։"</string>
<string name="work_profile_edu_personal_apps" msgid="4155536355149317441">"Անձնական հավելվածները թաքցված են և առանձնացված աշխատանքային հավելվածներից։"</string>
<string name="work_profile_edu_work_apps" msgid="237051938268703058">"Աշխատանքային հավելվածներն ու դրանց տվյալները տեսանելի են ձեր ադմինիստրատորին"</string>
<string name="work_profile_edu_next" msgid="8783418929296503629">"Առաջ"</string>
<string name="work_profile_edu_accept" msgid="6069788082535149071">"Եղավ"</string>
<string name="work_apps_paused_title" msgid="2389865654362803723">"Աշխատանքային պրոֆիլը դադարեցված է"</string>
<string name="work_apps_paused_body" msgid="5388070126389079077">"Աշխատանքային հավելվածները չեն կարող օգտագործել ձեր մարտկոցը, գտնվելու վայրի մասին տվյալները և ուղարկել ձեզ ծանուցումներ։"</string>
<string name="work_apps_paused_content_description" msgid="7553586952985486433">"Աշխատանքային պրոֆիլը դադարեցված է։ Աշխատանքային հավելվածները չեն կարող օգտագործել ձեր մարտկոցը, գտնվելու վայրի մասին տվյալները և ուղարկել ձեզ ծանուցումներ։"</string>
<string name="work_apps_paused_body" msgid="5388070126389079077">"Աշխատանքային հավելվածները չեն կարող ձեզ ծանուցումներ ուղարկել և օգտագործել ձեր մարտկոցն ու տեղադրության տվյալները։"</string>
<string name="work_apps_paused_content_description" msgid="7553586952985486433">"Աշխատանքային պրոֆիլը դադարեցված է։ Աշխատանքային հավելվածները չեն կարող ձեզ ծանուցումներ ուղարկել և օգտագործել ձեր մարտկոցն ու տեղադրության տվյալները։"</string>
<string name="work_switch_tip" msgid="808075064383839144">"Դադարեցնել աշխատանքային հավելվածներն ու ծանուցումները"</string>
<string name="remote_action_failed" msgid="1383965239183576790">"Չհաջողվեց կատարել գործողությունը (<xliff:g id="WHAT">%1$s</xliff:g>)"</string>
</resources>
+1 -1
View File
@@ -133,7 +133,7 @@
<string name="all_apps_personal_tab" msgid="4190252696685155002">"Personali"</string>
<string name="all_apps_work_tab" msgid="4884822796154055118">"Lavoro"</string>
<string name="work_profile_toggle_label" msgid="3081029915775481146">"Profilo di lavoro"</string>
<string name="work_profile_edu_personal_apps" msgid="4155536355149317441">"I dati personali sono separati e sono nascosti alle app di lavoro"</string>
<string name="work_profile_edu_personal_apps" msgid="4155536355149317441">"I dati personali sono separati e non sono visibili nelle app di lavoro"</string>
<string name="work_profile_edu_work_apps" msgid="237051938268703058">"I dati e le app di lavoro sono visibili all\'amministratore IT"</string>
<string name="work_profile_edu_next" msgid="8783418929296503629">"Avanti"</string>
<string name="work_profile_edu_accept" msgid="6069788082535149071">"OK"</string>
+1 -1
View File
@@ -133,7 +133,7 @@
<string name="all_apps_personal_tab" msgid="4190252696685155002">"個人用"</string>
<string name="all_apps_work_tab" msgid="4884822796154055118">"仕事用"</string>
<string name="work_profile_toggle_label" msgid="3081029915775481146">"仕事用プロファイル"</string>
<string name="work_profile_edu_personal_apps" msgid="4155536355149317441">"個人データは仕事用アプリとは別に保存され、一緒に表示されません"</string>
<string name="work_profile_edu_personal_apps" msgid="4155536355149317441">"個人データは仕事用アプリとは別に保存され、一緒に表示されません"</string>
<string name="work_profile_edu_work_apps" msgid="237051938268703058">"仕事用アプリと仕事用データは IT 管理者に公開されます"</string>
<string name="work_profile_edu_next" msgid="8783418929296503629">"次へ"</string>
<string name="work_profile_edu_accept" msgid="6069788082535149071">"OK"</string>
+2 -2
View File
@@ -138,8 +138,8 @@
<string name="work_profile_edu_next" msgid="8783418929296503629">"Кийинки"</string>
<string name="work_profile_edu_accept" msgid="6069788082535149071">"Түшүндүм"</string>
<string name="work_apps_paused_title" msgid="2389865654362803723">"Жумуш профили тындырылган"</string>
<string name="work_apps_paused_body" msgid="5388070126389079077">"Жумуш колдонмолору билдирмелерди жөнөтүп, батареяңызды колдонуп же кайда жүргөнүңүздү көрө албайт"</string>
<string name="work_apps_paused_content_description" msgid="7553586952985486433">"Жумуш профили тындырылган. Жумуш колдонмолору билдирмелерди жөнөтүп, батареяңызды колдонуп же кайда жүргөнүңүздү көрө албайт"</string>
<string name="work_apps_paused_body" msgid="5388070126389079077">"Жумуш колдонмолору билдирмелерди жөнөтүп, түзмөгүңүздүн батареясын керектеп же кайда жүргөнүңүздү көрө албайт"</string>
<string name="work_apps_paused_content_description" msgid="7553586952985486433">"Жумуш профили тындырылган. Жумуш колдонмолору билдирмелерди жөнөтүп, түзмөгүңүздүн батареясын керектеп же кайда жүргөнүңүздү көрө албайт"</string>
<string name="work_switch_tip" msgid="808075064383839144">"Жумуш колдонмолорун жана билдирмелерди тындыруу"</string>
<string name="remote_action_failed" msgid="1383965239183576790">"Аткарылган жок: <xliff:g id="WHAT">%1$s</xliff:g>"</string>
</resources>
+1 -2
View File
@@ -139,8 +139,7 @@
<string name="work_profile_edu_accept" msgid="6069788082535149071">"बुझेँ"</string>
<string name="work_apps_paused_title" msgid="2389865654362803723">"कार्यालयको प्रोफाइल अस्थायी रूपमा रोक्का गरिएको छ"</string>
<string name="work_apps_paused_body" msgid="5388070126389079077">"कामसम्बन्धी एपहरूले तपाईंलाई सूचना पठाउन, तपाईंको ब्याट्री प्रयोग गर्न वा तपाईंको स्थानसम्बन्धी जानकारीमाथि पहुँच राख्न सक्दैनन्"</string>
<!-- no translation found for work_apps_paused_content_description (7553586952985486433) -->
<skip />
<string name="work_apps_paused_content_description" msgid="7553586952985486433">"कार्यालयको प्रोफाइल अस्थायी रूपमा रोक्का गरिएको छ। कामसम्बन्धी एपहरूले तपाईंलाई सूचना पठाउन, तपाईंको यन्त्रको ब्याट्री प्रयोग गर्न वा तपाईंको स्थान हेर्न सक्दैनन्"</string>
<string name="work_switch_tip" msgid="808075064383839144">"कामसम्बन्धी एप र सूचनाहरू अस्थायी रूपमा रोक्का गर्नुहोस्"</string>
<string name="remote_action_failed" msgid="1383965239183576790">"कार्य पूरा गर्न सकिएन: <xliff:g id="WHAT">%1$s</xliff:g>"</string>
</resources>
+1 -1
View File
@@ -139,7 +139,7 @@
<string name="work_profile_edu_accept" msgid="6069788082535149071">"ବୁଝିଗଲି"</string>
<string name="work_apps_paused_title" msgid="2389865654362803723">"ୱାର୍କ ପ୍ରୋଫାଇଲକୁ ବିରତ କରାଯାଇଛି"</string>
<string name="work_apps_paused_body" msgid="5388070126389079077">"କାର୍ଯ୍ୟସ୍ଥଳୀ ଆପ୍ ଆପଣଙ୍କୁ ବିଜ୍ଞପ୍ତିଗୁଡ଼ିକ ପଠାଇପାରିବ ନାହିଁ, ଆପଣଙ୍କ ବ୍ୟାଟେରୀକୁ ବ୍ୟବହାର କରିପାରିବ ନାହିଁ କିମ୍ବା ଆପଣଙ୍କ ଲୋକେସନକୁ ଆକ୍ସେସ୍ କରିପାରିବ ନାହିଁ"</string>
<string name="work_apps_paused_content_description" msgid="7553586952985486433">"ୱାର୍କ ପ୍ରୋଫାଇଲ୍ ବିରତ କରାଯାଇଛି। କାର୍ଯ୍ୟସ୍ଥଳୀ ଆପ୍ ଆପଣଙ୍କୁ ବିଜ୍ଞପ୍ତିଗୁଡ଼ିକ ପଠାଇପାରିବ ନାହିଁ, ଆପଣଙ୍କ ବ୍ୟାଟେରୀ ବ୍ୟବହାର କରନ୍ତୁ କିମ୍ବା ଆପଣଙ୍କ ଲୋକେସନ୍ ଆକ୍ସେସ୍ କରନ୍ତୁ"</string>
<string name="work_apps_paused_content_description" msgid="7553586952985486433">"ୱାର୍କ ପ୍ରୋଫାଇଲ୍ ବିରତ କରାଯାଇଛି। କାର୍ଯ୍ୟସ୍ଥଳୀ ଆପ୍ ଆପଣଙ୍କୁ ବିଜ୍ଞପ୍ତିଗୁଡ଼ିକ ପଠାଇପାରିବ ନାହିଁ, ଆପଣଙ୍କ ବ୍ୟାଟେରୀ ବ୍ୟବହାର କରନ୍ତୁ କିମ୍ବା ଆପଣଙ୍କ ଲୋକେସନ୍ ଆକ୍ସେସ୍ କରନ୍ତୁ"</string>
<string name="work_switch_tip" msgid="808075064383839144">"କାର୍ଯ୍ୟସ୍ଥଳୀ ଆପ୍ ଏବଂ ବିଜ୍ଞପ୍ତିଗୁଡ଼ିକୁ ବିରତ କରନ୍ତୁ"</string>
<string name="remote_action_failed" msgid="1383965239183576790">"ବିଫଳ ହୋଇଛି: <xliff:g id="WHAT">%1$s</xliff:g>"</string>
</resources>
+3 -3
View File
@@ -133,10 +133,10 @@
<string name="accessibility_close" msgid="2277148124685870734">"Zamknij"</string>
<string name="notification_dismissed" msgid="6002233469409822874">"Powiadomienie odrzucone"</string>
<string name="all_apps_personal_tab" msgid="4190252696685155002">"Osobiste"</string>
<string name="all_apps_work_tab" msgid="4884822796154055118">"Służbowe"</string>
<string name="work_profile_toggle_label" msgid="3081029915775481146">"Profil służbowy"</string>
<string name="all_apps_work_tab" msgid="4884822796154055118">"Do pracy"</string>
<string name="work_profile_toggle_label" msgid="3081029915775481146">"Profil do pracy"</string>
<string name="work_profile_edu_personal_apps" msgid="4155536355149317441">"Dane osobowe znajdują się w innym miejscu i są niewidoczne dla aplikacji do pracy"</string>
<string name="work_profile_edu_work_apps" msgid="237051938268703058">"Dane z profilu do pracy są widoczne dla Twojego administratora IT"</string>
<string name="work_profile_edu_work_apps" msgid="237051938268703058">"Dane i aplikacje z profilu do pracy są widoczne dla Twojego administratora IT"</string>
<string name="work_profile_edu_next" msgid="8783418929296503629">"Dalej"</string>
<string name="work_profile_edu_accept" msgid="6069788082535149071">"OK"</string>
<string name="work_apps_paused_title" msgid="2389865654362803723">"Wstrzymano profil do pracy"</string>
+12 -12
View File
@@ -21,8 +21,8 @@
xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
<string name="app_name" msgid="649227358658669779">"Launcher3"</string>
<string name="work_folder_name" msgid="3753320833950115786">"Trabalho"</string>
<string name="activity_not_found" msgid="8071924732094499514">"A aplicação não está instalada."</string>
<string name="activity_not_available" msgid="7456344436509528827">"A aplicação não está disponível"</string>
<string name="activity_not_found" msgid="8071924732094499514">"A app não está instalada."</string>
<string name="activity_not_available" msgid="7456344436509528827">"A app não está disponível"</string>
<string name="safemode_shortcut_error" msgid="9160126848219158407">"Aplicação transferida desativada no Modo de segurança"</string>
<string name="safemode_widget_error" msgid="4863470563535682004">"Widgets desativados no Modo de segurança"</string>
<string name="shortcut_not_available" msgid="2536503539825726397">"O atalho não está disponível"</string>
@@ -36,7 +36,7 @@
<string name="place_automatically" msgid="8064208734425456485">"Adicionar automaticamente"</string>
<string name="all_apps_search_bar_hint" msgid="1390553134053255246">"Pesquisar aplicações"</string>
<string name="all_apps_loading_message" msgid="5813968043155271636">"A carregar aplicações…"</string>
<string name="all_apps_no_search_results" msgid="3200346862396363786">"Nenhuma aplicação correspondente a \"<xliff:g id="QUERY">%1$s</xliff:g>\""</string>
<string name="all_apps_no_search_results" msgid="3200346862396363786">"Nenhuma app correspondente a \"<xliff:g id="QUERY">%1$s</xliff:g>\""</string>
<string name="all_apps_search_market_message" msgid="1366263386197059176">"Pesquisar mais aplicações"</string>
<string name="label_application" msgid="8531721983832654978">"Aplicação"</string>
<string name="notifications_header" msgid="1404149926117359025">"Notificações"</string>
@@ -50,23 +50,23 @@
<string name="all_apps_home_button_label" msgid="252062713717058851">"Ecrã principal"</string>
<string name="remove_drop_target_label" msgid="7812859488053230776">"Remover"</string>
<string name="uninstall_drop_target_label" msgid="4722034217958379417">"Desinstalar"</string>
<string name="app_info_drop_target_label" msgid="692894985365717661">"Info. da aplicação"</string>
<string name="app_info_drop_target_label" msgid="692894985365717661">"Info. da app"</string>
<string name="install_drop_target_label" msgid="2539096853673231757">"Instalar"</string>
<string name="permlab_install_shortcut" msgid="5632423390354674437">"instalar atalhos"</string>
<string name="permdesc_install_shortcut" msgid="923466509822011139">"Permite a uma aplicação adicionar atalhos sem a intervenção do utilizador."</string>
<string name="permdesc_install_shortcut" msgid="923466509822011139">"Permite a uma app adicionar atalhos sem a intervenção do utilizador."</string>
<string name="permlab_read_settings" msgid="1941457408239617576">"ler definições e atalhos do Ecrã Principal"</string>
<string name="permdesc_read_settings" msgid="5833423719057558387">"Permite à aplicação ler as definições e os atalhos no Ecrã Principal."</string>
<string name="permdesc_read_settings" msgid="5833423719057558387">"Permite à app ler as definições e os atalhos no Ecrã Principal."</string>
<string name="permlab_write_settings" msgid="3574213698004620587">"escrever definições e atalhos do Ecrã principal"</string>
<string name="permdesc_write_settings" msgid="5440712911516509985">"Permite à aplicação alterar as definições e os atalhos no Ecrã Principal."</string>
<string name="permdesc_write_settings" msgid="5440712911516509985">"Permite à app alterar as definições e os atalhos no Ecrã Principal."</string>
<string name="msg_no_phone_permission" msgid="9208659281529857371">"O <xliff:g id="APP_NAME">%1$s</xliff:g> não tem autorização para efetuar chamadas telefónicas"</string>
<string name="gadget_error_text" msgid="6081085226050792095">"Problema ao carregar o widget"</string>
<string name="gadget_setup_text" msgid="8274003207686040488">"Configuração"</string>
<string name="uninstall_system_app_text" msgid="4172046090762920660">"É uma aplicação de sistema e não pode ser desinstalada."</string>
<string name="uninstall_system_app_text" msgid="4172046090762920660">"É uma app de sistema e não pode ser desinstalada."</string>
<string name="folder_hint_text" msgid="5174843001373488816">"Edite o nome"</string>
<string name="disabled_app_label" msgid="6673129024321402780">"<xliff:g id="APP_NAME">%1$s</xliff:g> desativado"</string>
<plurals name="dotted_app_label" formatted="false" msgid="5194538107138265416">
<item quantity="other">A aplicação <xliff:g id="APP_NAME_2">%1$s</xliff:g> tem <xliff:g id="NOTIFICATION_COUNT_3">%2$d</xliff:g> notificações.</item>
<item quantity="one">A aplicação <xliff:g id="APP_NAME_0">%1$s</xliff:g> tem <xliff:g id="NOTIFICATION_COUNT_1">%2$d</xliff:g> notificação</item>
<item quantity="other">A app <xliff:g id="APP_NAME_2">%1$s</xliff:g> tem <xliff:g id="NOTIFICATION_COUNT_3">%2$d</xliff:g> notificações.</item>
<item quantity="one">A app <xliff:g id="APP_NAME_0">%1$s</xliff:g> tem <xliff:g id="NOTIFICATION_COUNT_1">%2$d</xliff:g> notificação</item>
</plurals>
<string name="default_scroll_format" msgid="7475544710230993317">"Página %1$d de %2$d"</string>
<string name="workspace_scroll_format" msgid="8458889198184077399">"Ecrã principal %1$d de %2$d"</string>
@@ -96,8 +96,8 @@
<string name="package_state_unknown" msgid="7592128424511031410">"Desconhecido"</string>
<string name="abandoned_clean_this" msgid="7610119707847920412">"Remover"</string>
<string name="abandoned_search" msgid="891119232568284442">"Pesquisar"</string>
<string name="abandoned_promises_title" msgid="7096178467971716750">"Esta aplicação não está instalada"</string>
<string name="abandoned_promise_explanation" msgid="3990027586878167529">"A aplicação deste ícone não está instalada. Pode removê-lo ou pesquisar a aplicação e instalá-la manualmente."</string>
<string name="abandoned_promises_title" msgid="7096178467971716750">"Esta app não está instalada"</string>
<string name="abandoned_promise_explanation" msgid="3990027586878167529">"A app deste ícone não está instalada. Pode removê-lo ou pesquisar a app e instalá-la manualmente."</string>
<string name="app_downloading_title" msgid="8336702962104482644">"A transferir o <xliff:g id="NAME">%1$s</xliff:g>, <xliff:g id="PROGRESS">%2$s</xliff:g> concluído"</string>
<string name="app_waiting_download_title" msgid="7053938513995617849">"A aguardar a instalação do <xliff:g id="NAME">%1$s</xliff:g>"</string>
<string name="widgets_bottom_sheet_title" msgid="2904559530954183366">"Widgets de <xliff:g id="NAME">%1$s</xliff:g>"</string>
+1 -1
View File
@@ -131,7 +131,7 @@
<string name="accessibility_close" msgid="2277148124685870734">"Fechar"</string>
<string name="notification_dismissed" msgid="6002233469409822874">"Notificação dispensada"</string>
<string name="all_apps_personal_tab" msgid="4190252696685155002">"Pessoais"</string>
<string name="all_apps_work_tab" msgid="4884822796154055118">"Comerciais"</string>
<string name="all_apps_work_tab" msgid="4884822796154055118">"Trabalho"</string>
<string name="work_profile_toggle_label" msgid="3081029915775481146">"Perfil de trabalho"</string>
<string name="work_profile_edu_personal_apps" msgid="4155536355149317441">"Os dados pessoais ficam separados e ocultos dos apps de trabalho"</string>
<string name="work_profile_edu_work_apps" msgid="237051938268703058">"Os dados de apps de trabalho ficam visíveis para seu administrador de TI"</string>
+1 -1
View File
@@ -136,7 +136,7 @@
<string name="all_apps_work_tab" msgid="4884822796154055118">"Рабочие"</string>
<string name="work_profile_toggle_label" msgid="3081029915775481146">"Рабочий профиль"</string>
<string name="work_profile_edu_personal_apps" msgid="4155536355149317441">"Личные данные скрыты от рабочих приложений и недоступны им"</string>
<string name="work_profile_edu_work_apps" msgid="237051938268703058">"Рабочие приложения и данные видны системному администратору"</string>
<string name="work_profile_edu_work_apps" msgid="237051938268703058">"Рабочие приложения и данные видны системному администратору."</string>
<string name="work_profile_edu_next" msgid="8783418929296503629">"Далее"</string>
<string name="work_profile_edu_accept" msgid="6069788082535149071">"ОК"</string>
<string name="work_apps_paused_title" msgid="2389865654362803723">"Рабочий профиль приостановлен"</string>
+3 -3
View File
@@ -135,13 +135,13 @@
<string name="all_apps_personal_tab" msgid="4190252696685155002">"Osobné"</string>
<string name="all_apps_work_tab" msgid="4884822796154055118">"Pracovné"</string>
<string name="work_profile_toggle_label" msgid="3081029915775481146">"Pracovný profil"</string>
<string name="work_profile_edu_personal_apps" msgid="4155536355149317441">"Osobné údaje sú od pracovných aplikácií oddelené a nie je ich vidieť"</string>
<string name="work_profile_edu_work_apps" msgid="237051938268703058">"Pracovné aplikácie a údaje vidí správca IT"</string>
<string name="work_profile_edu_personal_apps" msgid="4155536355149317441">"Osobné údaje sú oddelené a sú pred pracovnými aplikáciami skryté"</string>
<string name="work_profile_edu_work_apps" msgid="237051938268703058">"Pracovné aplikácie a údaje môže vidieť váš správca IT"</string>
<string name="work_profile_edu_next" msgid="8783418929296503629">"Ďalej"</string>
<string name="work_profile_edu_accept" msgid="6069788082535149071">"Dobre"</string>
<string name="work_apps_paused_title" msgid="2389865654362803723">"Pracovný profil je pozastavený"</string>
<string name="work_apps_paused_body" msgid="5388070126389079077">"Pracovné aplikácie nemôžu posielať upozornenia, používať batériu ani polohu"</string>
<string name="work_apps_paused_content_description" msgid="7553586952985486433">"Pracovný profil je pozastavený. Pracovné aplikácie nemôžu posielať upozornenia, používať batériu ani polohu"</string>
<string name="work_switch_tip" msgid="808075064383839144">"Pozastavenie pracovných aplikácií a upozornení"</string>
<string name="work_switch_tip" msgid="808075064383839144">"Pozastavte pracovné aplikácie a upozornenia"</string>
<string name="remote_action_failed" msgid="1383965239183576790">"Zlyhalo: <xliff:g id="WHAT">%1$s</xliff:g>"</string>
</resources>
+6 -6
View File
@@ -133,14 +133,14 @@
<string name="notification_dismissed" msgid="6002233469409822874">"Обавештење је одбачено"</string>
<string name="all_apps_personal_tab" msgid="4190252696685155002">"Личне"</string>
<string name="all_apps_work_tab" msgid="4884822796154055118">"Пословне"</string>
<string name="work_profile_toggle_label" msgid="3081029915775481146">"Профил за Work"</string>
<string name="work_profile_toggle_label" msgid="3081029915775481146">ословни профил"</string>
<string name="work_profile_edu_personal_apps" msgid="4155536355149317441">"Лични подаци су одвојени и сакривени од апликација за посао"</string>
<string name="work_profile_edu_work_apps" msgid="237051938268703058">"ИТ администратор види апликације за посао и податке"</string>
<string name="work_profile_edu_work_apps" msgid="237051938268703058">"ИТ администратор види пословне апликације и податке"</string>
<string name="work_profile_edu_next" msgid="8783418929296503629">"Даље"</string>
<string name="work_profile_edu_accept" msgid="6069788082535149071">"Важи"</string>
<string name="work_apps_paused_title" msgid="2389865654362803723">"Профил за Work је паузиран"</string>
<string name="work_apps_paused_body" msgid="5388070126389079077">"Апликације за посао не могу да вам шаљу обавештења, користе батерију ни приступају локацији"</string>
<string name="work_apps_paused_content_description" msgid="7553586952985486433">рофил за Work је паузиран. Апликације за посао не могу да вам шаљу обавештења, користе батерију нити приступају локацији"</string>
<string name="work_switch_tip" msgid="808075064383839144">"Паузирајте апликације за посао и обавештења"</string>
<string name="work_apps_paused_title" msgid="2389865654362803723">ословни профил је паузиран"</string>
<string name="work_apps_paused_body" msgid="5388070126389079077">"Пословне апликације не могу да вам шаљу обавештења, користе батерију ни приступају локацији"</string>
<string name="work_apps_paused_content_description" msgid="7553586952985486433">ословни профил је паузиран. Пословне апликације не могу да вам шаљу обавештења, користе батерију нити приступају локацији"</string>
<string name="work_switch_tip" msgid="808075064383839144">"Паузирајте пословне апликације и обавештења"</string>
<string name="remote_action_failed" msgid="1383965239183576790">"Није успело: <xliff:g id="WHAT">%1$s</xliff:g>"</string>
</resources>
+1 -1
View File
@@ -136,7 +136,7 @@
<string name="all_apps_work_tab" msgid="4884822796154055118">"Kazini"</string>
<string name="work_profile_toggle_label" msgid="3081029915775481146">"Wasifu wa kazini"</string>
<string name="work_profile_edu_personal_apps" msgid="4155536355149317441">"Data ya binafsi ni tofauti na haionyeshwi kwenye programu za kazini"</string>
<string name="work_profile_edu_work_apps" msgid="237051938268703058">"Programu na data ya kazini huonyeshwa kwa msimamizi wako wa TEHAMA"</string>
<string name="work_profile_edu_work_apps" msgid="237051938268703058">"Programu na data ya kazini huonekana kwa msimamizi wako wa TEHAMA"</string>
<string name="work_profile_edu_next" msgid="8783418929296503629">"Endelea"</string>
<string name="work_profile_edu_accept" msgid="6069788082535149071">"Nimeelewa"</string>
<string name="work_apps_paused_title" msgid="2389865654362803723">"Wasifu wa kazini umesimamishwa"</string>
-1
View File
@@ -1,4 +1,3 @@
<resources>
<bool name="is_tablet">true</bool>
<bool name="allow_rotation">true</bool>
</resources>
-1
View File
@@ -1,6 +1,5 @@
<resources>
<bool name="config_largeHeap">true</bool>
<bool name="is_large_tablet">true</bool>
<!-- All Apps & Widgets -->
<!-- Out of 100, the percent to shrink the workspace during spring loaded mode. -->
+3 -3
View File
@@ -46,7 +46,7 @@
<string name="hotseat_out_of_space" msgid="7448809638125333693">"Ajratilganlarda birorta ham xona yoq"</string>
<string name="all_apps_button_label" msgid="8130441508702294465">"Ilovalar royxati"</string>
<string name="all_apps_button_personal_label" msgid="1315764287305224468">"Shaxsiy ilovalar royxati"</string>
<string name="all_apps_button_work_label" msgid="7270707118948892488">"Ishchi ilovalar royxati"</string>
<string name="all_apps_button_work_label" msgid="7270707118948892488">"Ishga oid ilovalar royxati"</string>
<string name="all_apps_home_button_label" msgid="252062713717058851">"Bosh sahifa"</string>
<string name="remove_drop_target_label" msgid="7812859488053230776">"Olib tashlash"</string>
<string name="uninstall_drop_target_label" msgid="4722034217958379417">"Ochirib tashlash"</string>
@@ -131,8 +131,8 @@
<string name="accessibility_close" msgid="2277148124685870734">"Yopish"</string>
<string name="notification_dismissed" msgid="6002233469409822874">"Bildirishnoma yopildi"</string>
<string name="all_apps_personal_tab" msgid="4190252696685155002">"Shaxsiy"</string>
<string name="all_apps_work_tab" msgid="4884822796154055118">"Ishchi"</string>
<string name="work_profile_toggle_label" msgid="3081029915775481146">"Ishchi profil"</string>
<string name="all_apps_work_tab" msgid="4884822796154055118">"Ish"</string>
<string name="work_profile_toggle_label" msgid="3081029915775481146">"Ish profili"</string>
<string name="work_profile_edu_personal_apps" msgid="4155536355149317441">"Shaxsiy maʼlumotlar ishga oid ilovalardan alohida va berkitilgan"</string>
<string name="work_profile_edu_work_apps" msgid="237051938268703058">"Ishga oid ilovalar va maʼlumotlarni AT administratoringiz koʻra oladi"</string>
<string name="work_profile_edu_next" msgid="8783418929296503629">"Keyingisi"</string>
+2 -2
View File
@@ -134,11 +134,11 @@
<string name="all_apps_work_tab" msgid="4884822796154055118">"Cơ quan"</string>
<string name="work_profile_toggle_label" msgid="3081029915775481146">"Hồ sơ công việc"</string>
<string name="work_profile_edu_personal_apps" msgid="4155536355149317441">"Dữ liệu cá nhân được lưu trữ riêng biệt và ẩn khỏi các ứng dụng công việc"</string>
<string name="work_profile_edu_work_apps" msgid="237051938268703058">"Quản trị viên CNTT của bạn có thể xem ứng dụng công việc và dữ liệu"</string>
<string name="work_profile_edu_work_apps" msgid="237051938268703058">"Quản trị viên CNTT của bạn có thể xem dữ liệu và các ứng dụng công việc"</string>
<string name="work_profile_edu_next" msgid="8783418929296503629">"Tiếp theo"</string>
<string name="work_profile_edu_accept" msgid="6069788082535149071">"OK"</string>
<string name="work_apps_paused_title" msgid="2389865654362803723">"Hồ sơ công việc của bạn đã bị tạm dừng"</string>
<string name="work_apps_paused_body" msgid="5388070126389079077">"ng dụng công việc không thể gửi thông báo cho bạn, sử dụng pin hoặc xem dữ liệu vị trí"</string>
<string name="work_apps_paused_body" msgid="5388070126389079077">"Các ứng dụng công việc không thể gửi thông báo cho bạn, sử dụng pin hoặc truy cập thông tin vị trí của bạn"</string>
<string name="work_apps_paused_content_description" msgid="7553586952985486433">"Hồ sơ công việc của bạn đã bị tạm dừng. Các ứng dụng công việc không thể: gửi thông báo cho bạn, sử dụng pin hoặc xem dữ liệu vị trí"</string>
<string name="work_switch_tip" msgid="808075064383839144">"Tạm dừng các ứng dụng và thông báo liên quan tới công việc"</string>
<string name="remote_action_failed" msgid="1383965239183576790">"Không thực hiện được thao tác: <xliff:g id="WHAT">%1$s</xliff:g>"</string>
+4 -4
View File
@@ -133,13 +133,13 @@
<string name="all_apps_personal_tab" msgid="4190252696685155002">"个人"</string>
<string name="all_apps_work_tab" msgid="4884822796154055118">"工作"</string>
<string name="work_profile_toggle_label" msgid="3081029915775481146">"工作资料"</string>
<string name="work_profile_edu_personal_apps" msgid="4155536355149317441">"个人数据与工作应用相互独立,两者不会同时显示"</string>
<string name="work_profile_edu_personal_apps" msgid="4155536355149317441">"工作应用与个人数据相互独立,它们无法获取此类数据"</string>
<string name="work_profile_edu_work_apps" msgid="237051938268703058">"您的 IT 管理员可以查看工作应用和工作数据"</string>
<string name="work_profile_edu_next" msgid="8783418929296503629">"继续"</string>
<string name="work_profile_edu_accept" msgid="6069788082535149071">"知道了"</string>
<string name="work_apps_paused_title" msgid="2389865654362803723">"工作资料已暂停使用"</string>
<string name="work_apps_paused_body" msgid="5388070126389079077">"工作应用无法向您发送通知、使用电池电量,也无法获取您的位置信息"</string>
<string name="work_apps_paused_content_description" msgid="7553586952985486433">"工作资料已暂停使用。工作应用无法向您发送通知、不能使用电池电量,也无法获取您的位置信息"</string>
<string name="work_apps_paused_title" msgid="2389865654362803723">"工作资料已暂停"</string>
<string name="work_apps_paused_body" msgid="5388070126389079077">"现在,工作应用无法向您发送通知、不能耗用电池电量,也无法获取您的位置信息"</string>
<string name="work_apps_paused_content_description" msgid="7553586952985486433">"工作资料已暂停。现在,工作应用无法向您发送通知、不能用电池电量,也无法获取您的位置信息"</string>
<string name="work_switch_tip" msgid="808075064383839144">"暂停工作应用和工作通知"</string>
<string name="remote_action_failed" msgid="1383965239183576790">"失败:<xliff:g id="WHAT">%1$s</xliff:g>"</string>
</resources>
+1 -3
View File
@@ -1,8 +1,6 @@
<resources>
<!-- Miscellaneous -->
<bool name="config_largeHeap">false</bool>
<bool name="is_tablet">false</bool>
<bool name="is_large_tablet">false</bool>
<bool name="allow_rotation">false</bool>
<integer name="extracted_color_gradient_alpha">153</integer>
@@ -132,7 +130,7 @@
<item name="dismiss_task_trans_x_stiffness" type="dimen" format="float">800</item>
<item name="horizontal_spring_damping_ratio" type="dimen" format="float">0.8</item>
<item name="horizontal_spring_stiffness" type="dimen" format="float">400</item>
<item name="horizontal_spring_stiffness" type="dimen" format="float">250</item>
<item name="swipe_up_rect_scale_damping_ratio" type="dimen" format="float">0.75</item>
<item name="swipe_up_rect_scale_stiffness" type="dimen" format="float">200</item>
@@ -24,6 +24,7 @@ import android.content.ActivityNotFoundException;
import android.content.Intent;
import android.content.pm.LauncherApps;
import android.content.res.Configuration;
import android.graphics.Point;
import android.graphics.Rect;
import android.os.Bundle;
import android.os.Process;
@@ -31,6 +32,7 @@ import android.os.StrictMode;
import android.os.UserHandle;
import android.util.Log;
import android.view.ActionMode;
import android.view.Display;
import android.view.View;
import android.view.View.OnClickListener;
import android.widget.Toast;
@@ -183,7 +185,7 @@ public abstract class BaseDraggingActivity extends BaseActivity
getUserEventDispatcher().logAppLaunch(v, intent, user);
getStatsLogManager().log(APP_LAUNCH_TAP, item == null ? null
: item.buildProto(null, null));
: item.buildProto(null));
return true;
} catch (NullPointerException|ActivityNotFoundException|SecurityException e) {
Toast.makeText(this, R.string.activity_not_found, Toast.LENGTH_SHORT).show();
@@ -270,4 +272,16 @@ public abstract class BaseDraggingActivity extends BaseActivity
}
protected abstract void reapplyUi();
protected Rect getMultiWindowDisplaySize() {
if (Utilities.ATLEAST_R) {
return new Rect(getWindowManager().getCurrentWindowMetrics().getBounds());
}
// Note: Calls to getSize() can't rely on our cached DefaultDisplay since it can return
// the app window size
Display display = getWindowManager().getDefaultDisplay();
Point mwSize = new Point();
display.getSize(mwSize);
return new Rect(0, 0, mwSize.x, mwSize.y);
}
}
+38 -15
View File
@@ -32,6 +32,10 @@ import com.android.launcher3.util.DefaultDisplay;
public class DeviceProfile {
private static final float TABLET_MIN_DPS = 600;
private static final float LARGE_TABLET_MIN_DPS = 720;
public final InvariantDeviceProfile inv;
private final DefaultDisplay.Info mInfo;
@@ -45,6 +49,8 @@ public class DeviceProfile {
public final boolean isLandscape;
public final boolean isMultiWindowMode;
public final int windowX;
public final int windowY;
public final int widthPx;
public final int heightPx;
public final int availableWidthPx;
@@ -133,13 +139,16 @@ public class DeviceProfile {
public DotRenderer mDotRendererWorkSpace;
public DotRenderer mDotRendererAllApps;
public DeviceProfile(Context context, InvariantDeviceProfile inv, DefaultDisplay.Info info,
DeviceProfile(Context context, InvariantDeviceProfile inv, DefaultDisplay.Info info,
Point minSize, Point maxSize, int width, int height, boolean isLandscape,
boolean isMultiWindowMode, boolean transposeLayoutWithOrientation) {
boolean isMultiWindowMode, boolean transposeLayoutWithOrientation,
Point windowPosition) {
this.inv = inv;
this.isLandscape = isLandscape;
this.isMultiWindowMode = isMultiWindowMode;
windowX = windowPosition.x;
windowY = windowPosition.y;
// Determine sizes.
widthPx = width;
@@ -153,11 +162,12 @@ public class DeviceProfile {
}
mInfo = info;
Resources res = context.getResources();
// Constants from resources
isTablet = res.getBoolean(R.bool.is_tablet);
isLargeTablet = res.getBoolean(R.bool.is_large_tablet);
float swDPs = Utilities.dpiFromPx(
Math.min(info.smallestSize.x, info.smallestSize.y), info.metrics);
isTablet = swDPs >= TABLET_MIN_DPS;
isLargeTablet = swDPs >= LARGE_TABLET_MIN_DPS;
isPhone = !isTablet && !isLargeTablet;
aspectRatio = ((float) Math.max(widthPx, heightPx)) / Math.min(widthPx, heightPx);
boolean isTallDevice = Float.compare(aspectRatio, TALL_DEVICE_ASPECT_RATIO_THRESHOLD) >= 0;
@@ -165,10 +175,10 @@ public class DeviceProfile {
// Some more constants
this.transposeLayoutWithOrientation = transposeLayoutWithOrientation;
context = getContext(context, isVerticalBarLayout()
context = getContext(context, info, isVerticalBarLayout()
? Configuration.ORIENTATION_LANDSCAPE
: Configuration.ORIENTATION_PORTRAIT);
res = context.getResources();
final Resources res = context.getResources();
edgeMarginPx = res.getDimensionPixelSize(R.dimen.dynamic_grid_edge_margin);
desiredWorkspaceLeftRightMarginPx = isVerticalBarLayout() ? 0 : edgeMarginPx;
@@ -244,6 +254,7 @@ public class DeviceProfile {
return new Builder(context, inv, mInfo)
.setSizeRange(size, size)
.setSize(widthPx, heightPx)
.setWindowPosition(windowX, windowY)
.setMultiWindowMode(isMultiWindowMode);
}
@@ -254,10 +265,11 @@ public class DeviceProfile {
/**
* TODO: Move this to the builder as part of setMultiWindowMode
*/
public DeviceProfile getMultiWindowProfile(Context context, Point mwSize) {
public DeviceProfile getMultiWindowProfile(Context context, Rect windowPosition) {
// We take the minimum sizes of this profile and it's multi-window variant to ensure that
// the system decor is always excluded.
mwSize.set(Math.min(availableWidthPx, mwSize.x), Math.min(availableHeightPx, mwSize.y));
Point mwSize = new Point(Math.min(availableWidthPx, windowPosition.width()),
Math.min(availableHeightPx, windowPosition.height()));
// In multi-window mode, we can have widthPx = availableWidthPx
// and heightPx = availableHeightPx because Launcher uses the InvariantDeviceProfiles'
@@ -265,6 +277,7 @@ public class DeviceProfile {
DeviceProfile profile = toBuilder(context)
.setSizeRange(mwSize, mwSize)
.setSize(mwSize.x, mwSize.y)
.setWindowPosition(windowPosition.left, windowPosition.top)
.setMultiWindowMode(true)
.build();
@@ -286,7 +299,7 @@ public class DeviceProfile {
}
/**
* Inverse of {@link #getMultiWindowProfile(Context, Point)}
* Inverse of {@link #getMultiWindowProfile(Context, Rect)}
* @return device profile corresponding to the current orientation in non multi-window mode.
*/
public DeviceProfile getFullScreenProfile() {
@@ -624,10 +637,11 @@ public class DeviceProfile {
}
}
private static Context getContext(Context c, int orientation) {
Configuration context = new Configuration(c.getResources().getConfiguration());
context.orientation = orientation;
return c.createConfigurationContext(context);
private static Context getContext(Context c, DefaultDisplay.Info info, int orientation) {
Configuration config = new Configuration(c.getResources().getConfiguration());
config.orientation = orientation;
config.densityDpi = info.metrics.densityDpi;
return c.createConfigurationContext(config);
}
/**
@@ -649,6 +663,7 @@ public class DeviceProfile {
private InvariantDeviceProfile mInv;
private DefaultDisplay.Info mInfo;
private final Point mWindowPosition = new Point();
private Point mMinSize, mMaxSize;
private int mWidth, mHeight;
@@ -682,6 +697,14 @@ public class DeviceProfile {
return this;
}
/**
* Sets the window position if not full-screen
*/
public Builder setWindowPosition(int x, int y) {
mWindowPosition.set(x, y);
return this;
}
public Builder setTransposeLayoutWithOrientation(boolean transposeLayoutWithOrientation) {
mTransposeLayoutWithOrientation = transposeLayoutWithOrientation;
return this;
@@ -690,7 +713,7 @@ public class DeviceProfile {
public DeviceProfile build() {
return new DeviceProfile(mContext, mInv, mInfo, mMinSize, mMaxSize,
mWidth, mHeight, mIsLandscape, mIsMultiWindowMode,
mTransposeLayoutWithOrientation);
mTransposeLayoutWithOrientation, mWindowPosition);
}
}
@@ -25,6 +25,8 @@ import com.android.launcher3.dragndrop.DragOptions;
import com.android.launcher3.dragndrop.DragView;
import com.android.launcher3.dragndrop.DraggableView;
import com.android.launcher3.folder.FolderNameProvider;
import com.android.launcher3.logging.InstanceId;
import com.android.launcher3.logging.InstanceIdSequence;
import com.android.launcher3.model.data.ItemInfo;
/**
@@ -75,6 +77,11 @@ public interface DropTarget {
* DragView represents. May be an actual View class or a virtual stand-in */
public DraggableView originalView = null;
/** Used for matching DROP event with its corresponding DRAG event on the server side. */
final InstanceId mLogInstanceId =
new InstanceIdSequence(1 << 20 /*InstanceId.INSTANCE_ID_MAX*/)
.newInstanceId();
public DragObject(Context context) {
if (FeatureFlags.FOLDER_NAME_SUGGEST.get()) {
folderNameProvider = FolderNameProvider.newInstance(context);
@@ -19,7 +19,6 @@ package com.android.launcher3;
import static com.android.launcher3.Utilities.getDevicePrefs;
import static com.android.launcher3.Utilities.getPointString;
import static com.android.launcher3.config.FeatureFlags.APPLY_CONFIG_AT_RUNTIME;
import static com.android.launcher3.settings.SettingsActivity.GRID_OPTIONS_PREFERENCE_KEY;
import static com.android.launcher3.util.Executors.MAIN_EXECUTOR;
import static com.android.launcher3.util.PackageManagerHelper.getPackageFilter;
@@ -29,7 +28,6 @@ import android.content.BroadcastReceiver;
import android.content.ComponentName;
import android.content.Context;
import android.content.Intent;
import android.content.SharedPreferences;
import android.content.res.Configuration;
import android.content.res.Resources;
import android.content.res.TypedArray;
@@ -216,9 +214,8 @@ public class InvariantDeviceProfile {
}
public static String getCurrentGridName(Context context) {
SharedPreferences prefs = Utilities.getPrefs(context);
return prefs.getBoolean(GRID_OPTIONS_PREFERENCE_KEY, false)
? prefs.getString(KEY_IDP_GRID_NAME, null) : null;
return Utilities.isGridOptionsEnabled(context)
? Utilities.getPrefs(context).getString(KEY_IDP_GRID_NAME, null) : null;
}
/**
@@ -263,7 +260,7 @@ public class InvariantDeviceProfile {
iconTextSize = displayOption.iconTextSize;
fillResIconDpi = getLauncherIconDensity(iconBitmapSize);
if (Utilities.getPrefs(context).getBoolean(GRID_OPTIONS_PREFERENCE_KEY, false)) {
if (Utilities.isGridOptionsEnabled(context)) {
allAppsIconSize = displayOption.allAppsIconSize;
allAppsIconTextSize = displayOption.allAppsIconTextSize;
} else {
@@ -344,9 +341,7 @@ public class InvariantDeviceProfile {
InvariantDeviceProfile oldProfile = new InvariantDeviceProfile(this);
// Re-init grid
String gridName = Utilities.getPrefs(context).getBoolean(GRID_OPTIONS_PREFERENCE_KEY, false)
? Utilities.getPrefs(context).getString(KEY_IDP_GRID_NAME, null)
: null;
String gridName = getCurrentGridName(context);
initGrid(context, gridName);
int changeFlags = 0;
+47 -15
View File
@@ -18,23 +18,30 @@ package com.android.launcher3;
import static android.content.pm.ActivityInfo.CONFIG_ORIENTATION;
import static android.content.pm.ActivityInfo.CONFIG_SCREEN_SIZE;
import static android.view.accessibility.AccessibilityEvent.TYPE_WINDOW_STATE_CHANGED;
import static com.android.launcher3.AbstractFloatingView.TYPE_ALL;
import static com.android.launcher3.AbstractFloatingView.TYPE_REBIND_SAFE;
import static com.android.launcher3.AbstractFloatingView.TYPE_SNACKBAR;
import static com.android.launcher3.InstallShortcutReceiver.FLAG_DRAG_AND_DROP;
import static com.android.launcher3.LauncherAnimUtils.SPRING_LOADED_EXIT_DELAY;
import static com.android.launcher3.LauncherState.ALL_APPS;
import static com.android.launcher3.LauncherState.FLAG_CLOSE_POPUPS;
import static com.android.launcher3.LauncherState.FLAG_MULTI_PAGE;
import static com.android.launcher3.LauncherState.FLAG_NON_INTERACTIVE;
import static com.android.launcher3.LauncherState.NORMAL;
import static com.android.launcher3.LauncherState.NO_OFFSET;
import static com.android.launcher3.LauncherState.NO_SCALE;
import static com.android.launcher3.LauncherState.OVERVIEW;
import static com.android.launcher3.LauncherState.OVERVIEW_PEEK;
import static com.android.launcher3.LauncherState.SPRING_LOADED;
import static com.android.launcher3.Utilities.postAsyncCallback;
import static com.android.launcher3.dragndrop.DragLayer.ALPHA_INDEX_LAUNCHER_LOAD;
import static com.android.launcher3.logging.LoggerUtils.newContainerTarget;
import static com.android.launcher3.popup.SystemShortcut.APP_INFO;
import static com.android.launcher3.popup.SystemShortcut.INSTALL;
import static com.android.launcher3.popup.SystemShortcut.WIDGETS;
import static com.android.launcher3.states.RotationHelper.REQUEST_LOCK;
import static com.android.launcher3.states.RotationHelper.REQUEST_NONE;
import android.animation.Animator;
@@ -57,7 +64,6 @@ import android.content.SharedPreferences;
import android.content.pm.PackageManager;
import android.content.res.Configuration;
import android.database.sqlite.SQLiteDatabase;
import android.graphics.Point;
import android.os.Build;
import android.os.Bundle;
import android.os.CancellationSignal;
@@ -69,7 +75,6 @@ import android.text.TextUtils;
import android.text.method.TextKeyListener;
import android.util.Log;
import android.util.SparseArray;
import android.view.Display;
import android.view.KeyEvent;
import android.view.KeyboardShortcutGroup;
import android.view.KeyboardShortcutInfo;
@@ -94,6 +99,7 @@ import com.android.launcher3.allapps.AllAppsStore;
import com.android.launcher3.allapps.AllAppsTransitionController;
import com.android.launcher3.allapps.DiscoveryBounce;
import com.android.launcher3.anim.PropertyListBuilder;
import com.android.launcher3.compat.AccessibilityManagerCompat;
import com.android.launcher3.config.FeatureFlags;
import com.android.launcher3.dot.DotInfo;
import com.android.launcher3.dragndrop.DragController;
@@ -560,12 +566,8 @@ public class Launcher extends BaseDraggingActivity implements LauncherExterns,
// Load configuration-specific DeviceProfile
mDeviceProfile = idp.getDeviceProfile(this);
if (isInMultiWindowMode()) {
// Note: Calls to getSize() can't rely on our cached DefaultDisplay since it can return
// the app window size
Display display = getWindowManager().getDefaultDisplay();
Point mwSize = new Point();
display.getSize(mwSize);
mDeviceProfile = mDeviceProfile.getMultiWindowProfile(this, mwSize);
mDeviceProfile = mDeviceProfile.getMultiWindowProfile(
this, getMultiWindowDisplaySize());
}
onDeviceProfileInitiated();
@@ -921,8 +923,6 @@ public class Launcher extends BaseDraggingActivity implements LauncherExterns,
}
});
}
TestLogging.recordEvent(TestProtocol.SEQUENCE_MAIN, "Activity.onStop");
}
@Override
@@ -936,11 +936,10 @@ public class Launcher extends BaseDraggingActivity implements LauncherExterns,
mAppWidgetHost.setListenIfResumed(true);
TraceHelper.INSTANCE.endSection(traceToken);
TestLogging.recordEvent(TestProtocol.SEQUENCE_MAIN, "Activity.onStart");
}
private void handleDeferredResume() {
if (hasBeenResumed() && !mStateManager.getState().disableInteraction) {
if (hasBeenResumed() && !mStateManager.getState().hasFlag(FLAG_NON_INTERACTIVE)) {
logStopAndResume(Action.Command.RESUME);
getUserEventDispatcher().startSession();
@@ -988,7 +987,8 @@ public class Launcher extends BaseDraggingActivity implements LauncherExterns,
if (!mDeferOverlayCallbacks) {
return;
}
if (isStarted() && (!hasBeenResumed() || mStateManager.getState().disableInteraction)) {
if (isStarted() && (!hasBeenResumed()
|| mStateManager.getState().hasFlag(FLAG_NON_INTERACTIVE))) {
return;
}
mDeferOverlayCallbacks = false;
@@ -1023,13 +1023,42 @@ public class Launcher extends BaseDraggingActivity implements LauncherExterns,
scheduleDeferredCheck();
}
addActivityFlags(ACTIVITY_STATE_TRANSITION_ACTIVE);
if (state.hasFlag(FLAG_CLOSE_POPUPS)) {
AbstractFloatingView.closeAllOpenViews(this, !state.hasFlag(FLAG_NON_INTERACTIVE));
}
if (state == SPRING_LOADED) {
// Prevent any Un/InstallShortcutReceivers from updating the db while we are
// not on homescreen
InstallShortcutReceiver.enableInstallQueue(FLAG_DRAG_AND_DROP);
getRotationHelper().setCurrentStateRequest(REQUEST_LOCK);
mWorkspace.showPageIndicatorAtCurrentScroll();
mWorkspace.setClipChildren(false);
}
// When multiple pages are visible, show persistent page indicator
mWorkspace.getPageIndicator().setShouldAutoHide(!state.hasFlag(FLAG_MULTI_PAGE));
}
public void onStateSetEnd(LauncherState state) {
getAppWidgetHost().setResumed(state == LauncherState.NORMAL);
getWorkspace().setClipChildren(!state.disablePageClipping);
getWorkspace().setClipChildren(!state.hasFlag(FLAG_MULTI_PAGE));
finishAutoCancelActionMode();
removeActivityFlags(ACTIVITY_STATE_TRANSITION_ACTIVE);
// dispatch window state changed
getWindow().getDecorView().sendAccessibilityEvent(TYPE_WINDOW_STATE_CHANGED);
AccessibilityManagerCompat.sendStateEventToTest(this, state.ordinal);
if (state == NORMAL) {
// Re-enable any Un/InstallShortcutReceiver and now process any queued items
InstallShortcutReceiver.disableAndFlushInstallQueue(FLAG_DRAG_AND_DROP, this);
// Clear any rotation locks when going to normal state
getRotationHelper().setCurrentStateRequest(REQUEST_NONE);
}
}
@Override
@@ -1100,7 +1129,7 @@ public class Launcher extends BaseDraggingActivity implements LauncherExterns,
int stateOrdinal = savedState.getInt(RUNTIME_STATE, NORMAL.ordinal);
LauncherState[] stateValues = LauncherState.values();
LauncherState state = stateValues[stateOrdinal];
if (!state.disableRestore) {
if (!state.shouldDisableRestore()) {
mStateManager.goToState(state, false /* animated */);
}
@@ -2196,6 +2225,9 @@ public class Launcher extends BaseDraggingActivity implements LauncherExterns,
workspace.requestLayout();
}
@Override
public void bindPredictedItems(List<AppInfo> appInfos, IntArray ranks) { }
/**
* Add the views for a widget to the workspace.
*/
@@ -33,6 +33,7 @@ import com.android.launcher3.config.FeatureFlags;
import com.android.launcher3.icons.IconCache;
import com.android.launcher3.icons.IconProvider;
import com.android.launcher3.icons.LauncherIcons;
import com.android.launcher3.model.PredictionModel;
import com.android.launcher3.notification.NotificationListener;
import com.android.launcher3.pm.InstallSessionHelper;
import com.android.launcher3.pm.InstallSessionTracker;
@@ -57,6 +58,7 @@ public class LauncherAppState {
private final IconCache mIconCache;
private final WidgetPreviewLoader mWidgetCache;
private final InvariantDeviceProfile mInvariantDeviceProfile;
private final PredictionModel mPredictionModel;
private SecureSettingsObserver mNotificationDotsObserver;
private InstallSessionTracker mInstallSessionTracker;
@@ -127,6 +129,7 @@ public class LauncherAppState {
mIconCache = new IconCache(mContext, mInvariantDeviceProfile, iconCacheFileName);
mWidgetCache = new WidgetPreviewLoader(mContext, mIconCache);
mModel = new LauncherModel(this, mIconCache, AppFilter.newInstance(mContext));
mPredictionModel = new PredictionModel(mContext);
}
protected void onNotificationSettingsChanged(boolean areNotificationDotsEnabled) {
@@ -182,6 +185,10 @@ public class LauncherAppState {
return mModel;
}
public PredictionModel getPredictionModel() {
return mPredictionModel;
}
public WidgetPreviewLoader getWidgetCache() {
return mWidgetCache;
}

Some files were not shown because too many files have changed in this diff Show More