From 81ca1f880268cb5ab14df843f572954880ebce41 Mon Sep 17 00:00:00 2001 From: Tony Wickham Date: Fri, 9 Apr 2021 15:40:08 -0700 Subject: [PATCH 01/25] Remove some noisy logs by setting DEBUG = false Change-Id: I050676c0f4750e06a9052fd1c2ebe1e8badcfd92 --- src/com/android/launcher3/allapps/AllAppsRecyclerView.java | 2 +- src/com/android/launcher3/folder/FolderNameProvider.java | 2 +- src/com/android/launcher3/model/GridSizeMigrationTask.java | 2 +- src/com/android/launcher3/model/GridSizeMigrationTaskV2.java | 2 +- src/com/android/launcher3/model/data/ItemInfo.java | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) diff --git a/src/com/android/launcher3/allapps/AllAppsRecyclerView.java b/src/com/android/launcher3/allapps/AllAppsRecyclerView.java index 66575eb289..b1c764c1d1 100644 --- a/src/com/android/launcher3/allapps/AllAppsRecyclerView.java +++ b/src/com/android/launcher3/allapps/AllAppsRecyclerView.java @@ -51,7 +51,7 @@ import java.util.List; */ public class AllAppsRecyclerView extends BaseRecyclerView { private static final String TAG = "AllAppsContainerView"; - private static final boolean DEBUG = true; + private static final boolean DEBUG = false; private AlphabeticalAppsList mApps; private final int mNumAppsPerRow; diff --git a/src/com/android/launcher3/folder/FolderNameProvider.java b/src/com/android/launcher3/folder/FolderNameProvider.java index d166e27c23..9c1b24d96c 100644 --- a/src/com/android/launcher3/folder/FolderNameProvider.java +++ b/src/com/android/launcher3/folder/FolderNameProvider.java @@ -48,7 +48,7 @@ import java.util.stream.Collectors; public class FolderNameProvider implements ResourceBasedOverride { private static final String TAG = "FolderNameProvider"; - private static final boolean DEBUG = true; + private static final boolean DEBUG = false; /** * IME usually has up to 3 suggest slots. In total, there are 4 suggest slots as the folder diff --git a/src/com/android/launcher3/model/GridSizeMigrationTask.java b/src/com/android/launcher3/model/GridSizeMigrationTask.java index 804e72ee29..5e05e9930a 100644 --- a/src/com/android/launcher3/model/GridSizeMigrationTask.java +++ b/src/com/android/launcher3/model/GridSizeMigrationTask.java @@ -53,7 +53,7 @@ import java.util.HashSet; public class GridSizeMigrationTask { private static final String TAG = "GridSizeMigrationTask"; - private static final boolean DEBUG = true; + private static final boolean DEBUG = false; // These are carefully selected weights for various item types (Math.random?), to allow for // the least absurd migration experience. diff --git a/src/com/android/launcher3/model/GridSizeMigrationTaskV2.java b/src/com/android/launcher3/model/GridSizeMigrationTaskV2.java index c6c0791a17..8e7af55892 100644 --- a/src/com/android/launcher3/model/GridSizeMigrationTaskV2.java +++ b/src/com/android/launcher3/model/GridSizeMigrationTaskV2.java @@ -67,7 +67,7 @@ import java.util.Set; public class GridSizeMigrationTaskV2 { private static final String TAG = "GridSizeMigrationTaskV2"; - private static final boolean DEBUG = true; + private static final boolean DEBUG = false; private final Context mContext; private final SQLiteDatabase mDb; diff --git a/src/com/android/launcher3/model/data/ItemInfo.java b/src/com/android/launcher3/model/data/ItemInfo.java index e54f1e7705..05fd77d720 100644 --- a/src/com/android/launcher3/model/data/ItemInfo.java +++ b/src/com/android/launcher3/model/data/ItemInfo.java @@ -66,7 +66,7 @@ import java.util.Optional; */ public class ItemInfo { - public static final boolean DEBUG = true; + public static final boolean DEBUG = false; public static final int NO_ID = -1; /** From a1c5443a1c3ee7d40bfeed7a9964b9d140862046 Mon Sep 17 00:00:00 2001 From: Winson Chung Date: Fri, 16 Apr 2021 21:30:34 +0000 Subject: [PATCH 02/25] Revert "Add logs to verify receiver is unregistered" Revert "Add logs to verify receiver is unregistered" Revert submission 14193940-receiver_logs Reason for revert: Not needed Reverted Changes: I67fb3d8a0:Add logs to verify receiver is unregistered I0ab5a8199:Add logs to verify receiver is unregistered Change-Id: I32a05ff6639a7512fac2391430dde8b939d136df --- src/com/android/launcher3/testing/TestProtocol.java | 1 - 1 file changed, 1 deletion(-) diff --git a/src/com/android/launcher3/testing/TestProtocol.java b/src/com/android/launcher3/testing/TestProtocol.java index fdd7fc4817..943d129047 100644 --- a/src/com/android/launcher3/testing/TestProtocol.java +++ b/src/com/android/launcher3/testing/TestProtocol.java @@ -109,7 +109,6 @@ public final class TestProtocol { public static final String REQUEST_MOCK_SENSOR_ROTATION = "mock-sensor-rotation"; public static final String PERMANENT_DIAG_TAG = "TaplTarget"; - public static final String RECEIVER_LEAK = "b/185385047"; public static final String NO_SWIPE_TO_HOME = "b/158017601"; public static final String WORK_PROFILE_REMOVED = "b/159671700"; public static final String TIS_NO_EVENTS = "b/180915942"; From 3242720ce7659fb316b8f1f9f3876ddaa8c0fd65 Mon Sep 17 00:00:00 2001 From: Steven Ng Date: Mon, 19 Apr 2021 18:12:12 +0100 Subject: [PATCH 03/25] Inflate LauncherAppWidgetHostView directly in DragView Also removes AppWidgetHostViewDrawable Bug: 183609936 Test: drag-n-drop icons, folders, widgets, shortcuts Change-Id: I26d8b05b9f9171037f2459fa2389e7e02c8ca6dc --- src/com/android/launcher3/CellLayout.java | 9 +- src/com/android/launcher3/Workspace.java | 75 +++++++++---- .../dragndrop/AppWidgetHostViewDrawable.java | 88 --------------- .../launcher3/dragndrop/DragController.java | 101 +++++++++++++++--- .../android/launcher3/dragndrop/DragView.java | 61 ++++++++++- .../graphics/DragPreviewProvider.java | 33 +++++- .../widget/PendingItemDragHelper.java | 33 ++++-- .../AppWidgetHostViewDragListener.java | 8 +- 8 files changed, 257 insertions(+), 151 deletions(-) delete mode 100644 src/com/android/launcher3/dragndrop/AppWidgetHostViewDrawable.java diff --git a/src/com/android/launcher3/CellLayout.java b/src/com/android/launcher3/CellLayout.java index fc09295d7b..82a28cf446 100644 --- a/src/com/android/launcher3/CellLayout.java +++ b/src/com/android/launcher3/CellLayout.java @@ -61,7 +61,6 @@ import com.android.launcher3.LauncherSettings.Favorites; import com.android.launcher3.accessibility.DragAndDropAccessibilityDelegate; import com.android.launcher3.anim.Interpolators; import com.android.launcher3.config.FeatureFlags; -import com.android.launcher3.dragndrop.AppWidgetHostViewDrawable; import com.android.launcher3.folder.PreviewBackground; import com.android.launcher3.model.data.ItemInfo; import com.android.launcher3.util.CellAndSpan; @@ -70,6 +69,7 @@ import com.android.launcher3.util.ParcelableSparseArray; import com.android.launcher3.util.Themes; import com.android.launcher3.util.Thunk; import com.android.launcher3.views.ActivityContext; +import com.android.launcher3.widget.LauncherAppWidgetHostView; import java.lang.annotation.Retention; import java.lang.annotation.RetentionPolicy; @@ -1062,15 +1062,14 @@ public class CellLayout extends ViewGroup { private void applyColorExtraction(DropTarget.DragObject dragObject, int[] targetCell, int spanX, int spanY) { // Apply local extracted color if the DragView is an AppWidgetHostViewDrawable. - Drawable drawable = dragObject.dragView.getDrawable(); - if (drawable instanceof AppWidgetHostViewDrawable) { + View view = dragObject.dragView.getContentView(); + if (view instanceof LauncherAppWidgetHostView) { Workspace workspace = Launcher.getLauncher(dragObject.dragView.getContext()).getWorkspace(); int screenId = workspace.getIdForScreen(this); int pageId = workspace.getPageIndexForScreenId(screenId); - AppWidgetHostViewDrawable hostViewDrawable = ((AppWidgetHostViewDrawable) drawable); cellToRect(targetCell[0], targetCell[1], spanX, spanY, mTempRect); - hostViewDrawable.getAppWidgetHostView().handleDrag(mTempRect, pageId); + ((LauncherAppWidgetHostView) view).handleDrag(mTempRect, pageId); } } diff --git a/src/com/android/launcher3/Workspace.java b/src/com/android/launcher3/Workspace.java index 1931c29754..10091a18b8 100644 --- a/src/com/android/launcher3/Workspace.java +++ b/src/com/android/launcher3/Workspace.java @@ -69,7 +69,6 @@ import com.android.launcher3.anim.Interpolators; import com.android.launcher3.anim.PendingAnimation; import com.android.launcher3.config.FeatureFlags; import com.android.launcher3.dot.FolderDotInfo; -import com.android.launcher3.dragndrop.AppWidgetHostViewDrawable; import com.android.launcher3.dragndrop.DragController; import com.android.launcher3.dragndrop.DragLayer; import com.android.launcher3.dragndrop.DragOptions; @@ -414,7 +413,9 @@ public class Workspace extends PagedView } if (mDragInfo != null && mDragInfo.cell != null) { - CellLayout layout = (CellLayout) mDragInfo.cell.getParent().getParent(); + CellLayout layout = (CellLayout) (mDragInfo.cell instanceof LauncherAppWidgetHostView + ? dragObject.dragView.getContentViewParent().getParent() + : mDragInfo.cell.getParent().getParent()); layout.markCellsAsUnoccupiedForView(mDragInfo.cell); } @@ -1527,10 +1528,19 @@ public class Workspace extends PagedView draggableView = (DraggableView) child; } + final View contentView = previewProvider.getContentView(); + final float scale; // The draggable drawable follows the touch point around on the screen - final Drawable drawable = previewProvider.createDrawable(); + final Drawable drawable; + if (contentView == null) { + drawable = previewProvider.createDrawable(); + scale = previewProvider.getScaleAndPosition(drawable, mTempXY); + } else { + drawable = null; + scale = previewProvider.getScaleAndPosition(contentView, mTempXY); + } + int halfPadding = previewProvider.previewPadding / 2; - float scale = previewProvider.getScaleAndPosition(drawable, mTempXY); int dragLayerX = mTempXY[0]; int dragLayerY = mTempXY[1]; @@ -1556,21 +1566,37 @@ public class Workspace extends PagedView } } - if (drawable instanceof AppWidgetHostViewDrawable) { - mDragController.addDragListener(new AppWidgetHostViewDragListener(mLauncher)); + final DragView dv; + if (contentView instanceof View) { + if (contentView instanceof LauncherAppWidgetHostView) { + mDragController.addDragListener(new AppWidgetHostViewDragListener(mLauncher)); + } + dv = mDragController.startDrag( + contentView, + draggableView, + dragLayerX, + dragLayerY, + source, + dragObject, + dragVisualizeOffset, + dragRect, + scale * iconScale, + scale, + dragOptions); + } else { + dv = mDragController.startDrag( + drawable, + draggableView, + dragLayerX, + dragLayerY, + source, + dragObject, + dragVisualizeOffset, + dragRect, + scale * iconScale, + scale, + dragOptions); } - DragView dv = mDragController.startDrag( - drawable, - draggableView, - dragLayerX, - dragLayerY, - source, - dragObject, - dragVisualizeOffset, - dragRect, - scale * iconScale, - scale, - dragOptions); return dv; } @@ -1900,6 +1926,8 @@ public class Workspace extends PagedView CellLayout parentCell = getParentCellLayoutForView(cell); if (parentCell != null) { parentCell.removeView(cell); + } else if (mDragInfo.cell instanceof LauncherAppWidgetHostView) { + d.dragView.detachContentView(/* reattachToPreviousParent= */ false); } else if (FeatureFlags.IS_STUDIO_BUILD) { throw new NullPointerException("mDragInfo.cell has null parent"); } @@ -1938,6 +1966,9 @@ public class Workspace extends PagedView if (!returnToOriginalCellToPreventShuffling) { onNoCellFound(dropTargetLayout); } + if (mDragInfo.cell instanceof LauncherAppWidgetHostView) { + d.dragView.detachContentView(/* reattachToPreviousParent= */ true); + } // If we can't find a drop location, we return the item to its original position CellLayout.LayoutParams lp = (CellLayout.LayoutParams) cell.getLayoutParams(); @@ -2636,10 +2667,6 @@ public class Workspace extends PagedView } private Drawable createWidgetDrawable(ItemInfo widgetInfo, View layout) { - if (layout instanceof LauncherAppWidgetHostView) { - return new AppWidgetHostViewDrawable((LauncherAppWidgetHostView) layout); - } - int[] unScaledSize = estimateItemSize(widgetInfo); int visibility = layout.getVisibility(); layout.setVisibility(VISIBLE); @@ -2720,7 +2747,9 @@ public class Workspace extends PagedView boolean isWidget = info.itemType == LauncherSettings.Favorites.ITEM_TYPE_APPWIDGET || info.itemType == LauncherSettings.Favorites.ITEM_TYPE_CUSTOM_APPWIDGET; - if ((animationType == ANIMATE_INTO_POSITION_AND_RESIZE || external) && finalView != null) { + if ((animationType == ANIMATE_INTO_POSITION_AND_RESIZE || external) + && finalView != null + && dragView.getContentView() != finalView) { Drawable crossFadeDrawable = createWidgetDrawable(info, finalView); dragView.crossFadeContent(crossFadeDrawable, (int) (duration * 0.8f)); } else if (isWidget && external) { diff --git a/src/com/android/launcher3/dragndrop/AppWidgetHostViewDrawable.java b/src/com/android/launcher3/dragndrop/AppWidgetHostViewDrawable.java deleted file mode 100644 index 2135f5dff9..0000000000 --- a/src/com/android/launcher3/dragndrop/AppWidgetHostViewDrawable.java +++ /dev/null @@ -1,88 +0,0 @@ -/* - * Copyright (C) 2021 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.dragndrop; - -import android.graphics.Canvas; -import android.graphics.ColorFilter; -import android.graphics.Paint; -import android.graphics.PixelFormat; -import android.graphics.drawable.Drawable; - -import com.android.launcher3.widget.LauncherAppWidgetHostView; - -/** - * A drawable which renders {@link LauncherAppWidgetHostView} to a canvas. - * - * TODO(b/183609936) Stop using that class and remove it. - */ -public final class AppWidgetHostViewDrawable extends Drawable { - - private final LauncherAppWidgetHostView mAppWidgetHostView; - private Paint mPaint = new Paint(); - - public AppWidgetHostViewDrawable(LauncherAppWidgetHostView appWidgetHostView) { - mAppWidgetHostView = appWidgetHostView; - } - - @Override - public void draw(Canvas canvas) { - int saveCount = canvas.saveLayer(0, 0, getIntrinsicWidth(), getIntrinsicHeight(), mPaint); - mAppWidgetHostView.draw(canvas); - canvas.restoreToCount(saveCount); - } - - @Override - public int getIntrinsicWidth() { - return mAppWidgetHostView.getMeasuredWidth(); - } - - @Override - public int getIntrinsicHeight() { - return mAppWidgetHostView.getMeasuredHeight(); - } - - @Override - public int getOpacity() { - // This is up to app widget provider. We don't know if the host view will cover anything - // behind the drawable. - return PixelFormat.UNKNOWN; - } - - @Override - public void setAlpha(int alpha) { - mPaint.setAlpha(alpha); - } - - @Override - public int getAlpha() { - return mPaint.getAlpha(); - } - - @Override - public void setColorFilter(ColorFilter colorFilter) { - mPaint.setColorFilter(colorFilter); - } - - @Override - public ColorFilter getColorFilter() { - return mPaint.getColorFilter(); - } - - /** Returns the {@link LauncherAppWidgetHostView}. */ - public LauncherAppWidgetHostView getAppWidgetHostView() { - return mAppWidgetHostView; - } -} diff --git a/src/com/android/launcher3/dragndrop/DragController.java b/src/com/android/launcher3/dragndrop/DragController.java index b7a70cb654..d7f6cdb8bb 100644 --- a/src/com/android/launcher3/dragndrop/DragController.java +++ b/src/com/android/launcher3/dragndrop/DragController.java @@ -34,6 +34,8 @@ import android.view.KeyEvent; import android.view.MotionEvent; import android.view.View; +import androidx.annotation.Nullable; + import com.android.launcher3.AbstractFloatingView; import com.android.launcher3.DragSource; import com.android.launcher3.DropTarget; @@ -125,20 +127,23 @@ public class DragController implements DragDriver.EventListener, TouchController /** * Starts a drag. - * When the drag is started, the UI automatically goes into spring loaded mode. On a successful - * drop, it is the responsibility of the {@link DropTarget} to exit out of the spring loaded - * mode. If the drop was cancelled for some reason, the UI will automatically exit out of this mode. + * + *

When the drag is started, the UI automatically goes into spring loaded mode. On a + * successful drop, it is the responsibility of the {@link DropTarget} to exit out of the spring + * loaded mode. If the drop was cancelled for some reason, the UI will automatically exit out of + * this mode. * * @param drawable The drawable to be displayed in the drag view. It will be re-scaled to the - * enlarged size. - * @param originalView The source view (ie. icon, widget etc.) that is being dragged - * and which the DragView represents + * enlarged size. + * @param originalView The source view (ie. icon, widget etc.) that is being dragged and which + * the DragView represents * @param dragLayerX The x position in the DragLayer of the left-top of the bitmap. * @param dragLayerY The y position in the DragLayer of the left-top of the bitmap. * @param source An object representing where the drag originated * @param dragInfo The data associated with the object that is being dragged * @param dragRegion Coordinates within the bitmap b for the position of item being dragged. - * Makes dragging feel more precise, e.g. you can clip out a transparent border + * Makes dragging feel more precise, e.g. you can clip out a transparent + * border */ public DragView startDrag( Drawable drawable, @@ -152,6 +157,61 @@ public class DragController implements DragDriver.EventListener, TouchController float initialDragViewScale, float dragViewScaleOnDrop, DragOptions options) { + return startDrag(drawable, /* view= */ null, originalView, dragLayerX, dragLayerY, + source, dragInfo, dragOffset, dragRegion, initialDragViewScale, dragViewScaleOnDrop, + options); + } + + /** + * Starts a drag. + * + *

When the drag is started, the UI automatically goes into spring loaded mode. On a + * successful drop, it is the responsibility of the {@link DropTarget} to exit out of the spring + * loaded mode. If the drop was cancelled for some reason, the UI will automatically exit out of + * this mode. + * + * @param view The view to be displayed in the drag view. It will be re-scaled to the + * enlarged size. + * @param originalView The source view (ie. icon, widget etc.) that is being dragged and which + * the DragView represents + * @param dragLayerX The x position in the DragLayer of the left-top of the bitmap. + * @param dragLayerY The y position in the DragLayer of the left-top of the bitmap. + * @param source An object representing where the drag originated + * @param dragInfo The data associated with the object that is being dragged + * @param dragRegion Coordinates within the bitmap b for the position of item being dragged. + * Makes dragging feel more precise, e.g. you can clip out a transparent + * border + */ + public DragView startDrag( + View view, + DraggableView originalView, + int dragLayerX, + int dragLayerY, + DragSource source, + ItemInfo dragInfo, + Point dragOffset, + Rect dragRegion, + float initialDragViewScale, + float dragViewScaleOnDrop, + DragOptions options) { + return startDrag(/* drawable= */ null, view, originalView, dragLayerX, dragLayerY, + source, dragInfo, dragOffset, dragRegion, initialDragViewScale, dragViewScaleOnDrop, + options); + } + + private DragView startDrag( + @Nullable Drawable drawable, + @Nullable View view, + DraggableView originalView, + int dragLayerX, + int dragLayerY, + DragSource source, + ItemInfo dragInfo, + Point dragOffset, + Rect dragRegion, + float initialDragViewScale, + float dragViewScaleOnDrop, + DragOptions options) { if (PROFILE_DRAWING_DURING_DRAG) { android.os.Debug.startMethodTracing("Launcher"); } @@ -182,14 +242,25 @@ public class DragController implements DragDriver.EventListener, TouchController final Resources res = mLauncher.getResources(); final float scaleDps = mIsInPreDrag ? res.getDimensionPixelSize(R.dimen.pre_drag_view_scale) : 0f; - final DragView dragView = mDragObject.dragView = new DragView( - mLauncher, - drawable, - registrationX, - registrationY, - initialDragViewScale, - dragViewScaleOnDrop, - scaleDps); + final DragView dragView = mDragObject.dragView = drawable != null + ? new DragView( + mLauncher, + drawable, + registrationX, + registrationY, + initialDragViewScale, + dragViewScaleOnDrop, + scaleDps) + : new DragView( + mLauncher, + view, + view.getMeasuredWidth(), + view.getMeasuredHeight(), + registrationX, + registrationY, + initialDragViewScale, + dragViewScaleOnDrop, + scaleDps); dragView.setItemInfo(dragInfo); mDragObject.dragComplete = false; diff --git a/src/com/android/launcher3/dragndrop/DragView.java b/src/com/android/launcher3/dragndrop/DragView.java index 346359954e..68a8af238e 100644 --- a/src/com/android/launcher3/dragndrop/DragView.java +++ b/src/com/android/launcher3/dragndrop/DragView.java @@ -42,9 +42,11 @@ import android.os.Build; import android.os.Handler; import android.os.Looper; import android.view.View; +import android.view.ViewGroup; import android.widget.FrameLayout; import android.widget.ImageView; +import androidx.annotation.Nullable; import androidx.dynamicanimation.animation.FloatPropertyCompat; import androidx.dynamicanimation.animation.SpringAnimation; import androidx.dynamicanimation.animation.SpringForce; @@ -69,6 +71,10 @@ public class DragView extends FrameLayout implements StateListenerIn the case of no change in the drop position, sets {@code reattachToPreviousParent} to + * {@code true} to attach the {@link #mContent} back to its previous parent. + */ + public void detachContentView(boolean reattachToPreviousParent) { + if (mContent != null && mContentViewParent != null && mContentViewInParentViewIndex >= 0) { + removeView(mContent); + mContent.setLayoutParams(mContentViewLayoutParams); + if (reattachToPreviousParent) { + mContentViewParent.addView(mContent, mContentViewInParentViewIndex); + } + mContentViewParent = null; + mContentViewInParentViewIndex = -1; + } + } + + /** + * Removes this view from the {@link DragLayer}. + * + *

If the drag content is a {@link #mContent}, this call doesn't reattach the + * {@link #mContent} back to its previous parent. To reattach to previous parent, the caller + * should call {@link #detachContentView} with {@code reattachToPreviousParent} sets to true + * before this call. + */ public void remove() { if (getParent() != null) { mDragLayer.removeView(DragView.this); @@ -449,9 +495,18 @@ public class DragView extends FrameLayout implements StateListener drawDragView(c, scale))); } + /** + * Returns the content view if the content should be rendered directly in + * {@link com.android.launcher3.dragndrop.DragView}. Otherwise, returns null. + */ + @Nullable + public View getContentView() { + if (mView instanceof LauncherAppWidgetHostView) { + return mView; + } + return null; + } + public final void generateDragOutline(Bitmap preview) { if (FeatureFlags.IS_STUDIO_BUILD && mOutlineGeneratorCallback != null) { throw new RuntimeException("Drag outline generated twice"); @@ -152,6 +165,22 @@ public class DragPreviewProvider { return scale; } + /** Returns the scale and position of a given view for drag-n-drop. */ + public float getScaleAndPosition(View view, int[] outPos) { + float scale = Launcher.getLauncher(mView.getContext()) + .getDragLayer().getLocationInDragLayer(mView, outPos); + if (mView instanceof LauncherAppWidgetHostView) { + // App widgets are technically scaled, but are drawn at their expected size -- so the + // app widget scale should not affect the scale of the preview. + scale /= ((LauncherAppWidgetHostView) mView).getScaleToFit(); + } + + outPos[0] = Math.round(outPos[0] + - (view.getWidth() - scale * mView.getWidth() * mView.getScaleX()) / 2); + outPos[1] = Math.round(outPos[1] - (1 - scale) * view.getHeight() / 2 - previewPadding / 2); + return scale; + } + protected Bitmap convertPreviewToAlphaBitmap(Bitmap preview) { return preview.copy(Bitmap.Config.ALPHA_8, true); } diff --git a/src/com/android/launcher3/widget/PendingItemDragHelper.java b/src/com/android/launcher3/widget/PendingItemDragHelper.java index e78d517b09..df368cd3e5 100644 --- a/src/com/android/launcher3/widget/PendingItemDragHelper.java +++ b/src/com/android/launcher3/widget/PendingItemDragHelper.java @@ -33,7 +33,6 @@ import com.android.launcher3.Launcher; import com.android.launcher3.LauncherAppState; import com.android.launcher3.PendingAddItemInfo; import com.android.launcher3.R; -import com.android.launcher3.dragndrop.AppWidgetHostViewDrawable; import com.android.launcher3.dragndrop.DragOptions; import com.android.launcher3.dragndrop.DraggableView; import com.android.launcher3.graphics.DragPreviewProvider; @@ -93,6 +92,8 @@ public class PendingItemDragHelper extends DragPreviewProvider { LauncherAppState app = LauncherAppState.getInstance(launcher); Drawable preview = null; + final int previewWidth; + final int previewHeight; final float scale; final Point dragOffset; final Rect dragRegion; @@ -114,12 +115,11 @@ public class PendingItemDragHelper extends DragPreviewProvider { createWidgetInfo.info, maxWidth, previewSizeBeforeScale)); } if (mAppWidgetHostViewPreview != null) { - preview = new AppWidgetHostViewDrawable(mAppWidgetHostViewPreview); previewSizeBeforeScale[0] = mAppWidgetHostViewPreview.getMeasuredWidth(); launcher.getDragController() .addDragListener(new AppWidgetHostViewDragListener(launcher)); } - if (preview == null) { + if (preview == null && mAppWidgetHostViewPreview == null) { Drawable p = new FastBitmapDrawable( app.getWidgetCache().generateWidgetPreview(launcher, createWidgetInfo.info, maxWidth, null, @@ -140,7 +140,14 @@ public class PendingItemDragHelper extends DragPreviewProvider { previewBounds.left += padding; previewBounds.right -= padding; } - scale = previewBounds.width() / (float) preview.getIntrinsicWidth(); + if (mAppWidgetHostViewPreview != null) { + previewWidth = mAppWidgetHostViewPreview.getMeasuredWidth(); + previewHeight = mAppWidgetHostViewPreview.getMeasuredHeight(); + } else { + previewWidth = preview.getIntrinsicWidth(); + previewHeight = preview.getIntrinsicHeight(); + } + scale = previewBounds.width() / (float) previewWidth; launcher.getDragController().addDragListener(new WidgetHostViewLoader(launcher, mView)); dragOffset = null; @@ -152,8 +159,10 @@ public class PendingItemDragHelper extends DragPreviewProvider { LauncherIcons li = LauncherIcons.obtain(launcher); preview = new FastBitmapDrawable( li.createScaledBitmapWithoutShadow(icon, 0)); + previewWidth = preview.getIntrinsicWidth(); + previewHeight = preview.getIntrinsicHeight(); li.recycle(); - scale = ((float) launcher.getDeviceProfile().iconSizePx) / preview.getIntrinsicWidth(); + scale = ((float) launcher.getDeviceProfile().iconSizePx) / previewWidth; dragOffset = new Point(previewPadding / 2, previewPadding / 2); @@ -181,13 +190,19 @@ public class PendingItemDragHelper extends DragPreviewProvider { launcher.getWorkspace().prepareDragWithProvider(this); int dragLayerX = screenPos.x + previewBounds.left - + (int) ((scale * preview.getIntrinsicWidth() - preview.getIntrinsicWidth()) / 2); + + (int) ((scale * previewWidth - previewWidth) / 2); int dragLayerY = screenPos.y + previewBounds.top - + (int) ((scale * preview.getIntrinsicHeight() - preview.getIntrinsicHeight()) / 2); + + (int) ((scale * previewHeight - previewHeight) / 2); // Start the drag - launcher.getDragController().startDrag(preview, draggableView, dragLayerX, dragLayerY, - source, mAddInfo, dragOffset, dragRegion, scale, scale, options); + if (mAppWidgetHostViewPreview != null) { + launcher.getDragController().startDrag(mAppWidgetHostViewPreview, draggableView, + dragLayerX, dragLayerY, source, mAddInfo, dragOffset, dragRegion, scale, scale, + options); + } else { + launcher.getDragController().startDrag(preview, draggableView, dragLayerX, dragLayerY, + source, mAddInfo, dragOffset, dragRegion, scale, scale, options); + } } @Override diff --git a/src/com/android/launcher3/widget/dragndrop/AppWidgetHostViewDragListener.java b/src/com/android/launcher3/widget/dragndrop/AppWidgetHostViewDragListener.java index 66bb363dde..4a60983624 100644 --- a/src/com/android/launcher3/widget/dragndrop/AppWidgetHostViewDragListener.java +++ b/src/com/android/launcher3/widget/dragndrop/AppWidgetHostViewDragListener.java @@ -17,7 +17,6 @@ package com.android.launcher3.widget.dragndrop; import com.android.launcher3.DropTarget; import com.android.launcher3.Launcher; -import com.android.launcher3.dragndrop.AppWidgetHostViewDrawable; import com.android.launcher3.dragndrop.DragController; import com.android.launcher3.dragndrop.DragOptions; import com.android.launcher3.widget.LauncherAppWidgetHostView; @@ -26,7 +25,6 @@ import com.android.launcher3.widget.LauncherAppWidgetHostView; public final class AppWidgetHostViewDragListener implements DragController.DragListener { private final Launcher mLauncher; private DropTarget.DragObject mDragObject; - private AppWidgetHostViewDrawable mAppWidgetHostViewDrawable; private LauncherAppWidgetHostView mAppWidgetHostView; public AppWidgetHostViewDragListener(Launcher launcher) { @@ -35,11 +33,9 @@ public final class AppWidgetHostViewDragListener implements DragController.DragL @Override public void onDragStart(DropTarget.DragObject dragObject, DragOptions unused) { - if (dragObject.dragView.getDrawable() instanceof AppWidgetHostViewDrawable) { + if (dragObject.dragView.getContentView() instanceof LauncherAppWidgetHostView) { mDragObject = dragObject; - mAppWidgetHostViewDrawable = - (AppWidgetHostViewDrawable) mDragObject.dragView.getDrawable(); - mAppWidgetHostView = mAppWidgetHostViewDrawable.getAppWidgetHostView(); + mAppWidgetHostView = (LauncherAppWidgetHostView) dragObject.dragView.getContentView(); mAppWidgetHostView.startDrag(this); } else { mLauncher.getDragController().removeDragListener(this); From 5a85912b92478edb46392f0fa773716f0f2f5f7a Mon Sep 17 00:00:00 2001 From: Andy Wickham Date: Mon, 19 Apr 2021 17:23:11 -0700 Subject: [PATCH 04/25] Adds a flag for Smartspace feedback. Test: Manual Change-Id: I96dd8dad8bd2ab136960d0bebeac67b8bc00b583 --- src/com/android/launcher3/config/FeatureFlags.java | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/com/android/launcher3/config/FeatureFlags.java b/src/com/android/launcher3/config/FeatureFlags.java index 6331ef2862..06166289b0 100644 --- a/src/com/android/launcher3/config/FeatureFlags.java +++ b/src/com/android/launcher3/config/FeatureFlags.java @@ -168,7 +168,11 @@ public final class FeatureFlags { public static final BooleanFlag ENABLE_SMARTSPACE_ENHANCED = new DeviceFlag( "ENABLE_SMARTSPACE_ENHANCED", false, "Replace Smartspace with the enhanced version. " - + "Ignored if ENABLE_SMARTSPACE_UNIVERSAL is enabled."); + + "Ignored if ENABLE_SMARTSPACE_UNIVERSAL is enabled."); + + public static final BooleanFlag ENABLE_SMARTSPACE_FEEDBACK = new DeviceFlag( + "ENABLE_SMARTSPACE_FEEDBACK", true, + "Adds a menu option to send feedback for Enhanced Smartspace."); public static final BooleanFlag ALWAYS_USE_HARDWARE_OPTIMIZATION_FOR_FOLDER_ANIMATIONS = getDebugFlag( From 8559ae324c3509a9594f1c94db66a0138d0f3e3a Mon Sep 17 00:00:00 2001 From: Tony Wickham Date: Fri, 16 Apr 2021 11:59:07 -0700 Subject: [PATCH 05/25] Update TwoButtonNavbarTouchController logs - Fix wrong bug number - Log when we intercept and reinit to a state rather than in getTargetState() which is used to determine possible swipe directions too (which makes the logs confusing) Test: run TaplTestsQuickstep#testOverviewActions Bug: 177316094 Change-Id: Ibe5db6317c16c429c9c46bf237d3f8adc1458037 --- .../TwoButtonNavbarTouchController.java | 27 ++++++++++++++----- .../launcher3/testing/TestProtocol.java | 2 +- 2 files changed, 22 insertions(+), 7 deletions(-) diff --git a/quickstep/src/com/android/launcher3/uioverrides/touchcontrollers/TwoButtonNavbarTouchController.java b/quickstep/src/com/android/launcher3/uioverrides/touchcontrollers/TwoButtonNavbarTouchController.java index c4263290f7..b0d0b1528c 100644 --- a/quickstep/src/com/android/launcher3/uioverrides/touchcontrollers/TwoButtonNavbarTouchController.java +++ b/quickstep/src/com/android/launcher3/uioverrides/touchcontrollers/TwoButtonNavbarTouchController.java @@ -98,23 +98,35 @@ public class TwoButtonNavbarTouchController extends AbstractStateChangeTouchCont return mLauncher.isInState(NORMAL); } + @Override + public boolean onControllerInterceptTouchEvent(MotionEvent ev) { + boolean intercept = super.onControllerInterceptTouchEvent(ev); + if (TestProtocol.sDebugTracing) { + Log.d(TestProtocol.TWO_BUTTON_NORMAL_NOT_OVERVIEW, + "2 button touch controller intercept touch? " + intercept); + } + return intercept; + } + @Override protected LauncherState getTargetState(LauncherState fromState, boolean isDragTowardPositive) { - final LauncherState targetState; if (mIsTransposed) { boolean draggingFromNav = mLauncher.getDeviceProfile().isSeascape() == isDragTowardPositive; - targetState = draggingFromNav ? HINT_STATE_TWO_BUTTON : NORMAL; + return draggingFromNav ? HINT_STATE_TWO_BUTTON : NORMAL; } else { LauncherState startState = mStartState != null ? mStartState : fromState; - targetState = isDragTowardPositive ^ (startState == OVERVIEW) - ? HINT_STATE_TWO_BUTTON : NORMAL; + return isDragTowardPositive ^ (startState == OVERVIEW) ? HINT_STATE_TWO_BUTTON : NORMAL; } + } + + @Override + protected void onReinitToState(LauncherState newToState) { + super.onReinitToState(newToState); if (TestProtocol.sDebugTracing) { - Log.d(TestProtocol.TWO_BUTTON_NORMAL_NOT_OVERVIEW, "Target state: " + targetState); + Log.d(TestProtocol.TWO_BUTTON_NORMAL_NOT_OVERVIEW, "onReinitToState: " + newToState); } - return targetState; } @Override @@ -163,6 +175,9 @@ public class TwoButtonNavbarTouchController extends AbstractStateChangeTouchCont @Override protected void onSwipeInteractionCompleted(LauncherState targetState) { super.onSwipeInteractionCompleted(targetState); + if (TestProtocol.sDebugTracing) { + Log.d(TestProtocol.TWO_BUTTON_NORMAL_NOT_OVERVIEW, "Reached state: " + targetState); + } if (!mIsTransposed) { mContinuousTouchCount++; } diff --git a/src/com/android/launcher3/testing/TestProtocol.java b/src/com/android/launcher3/testing/TestProtocol.java index 60dd0f353d..d747a06313 100644 --- a/src/com/android/launcher3/testing/TestProtocol.java +++ b/src/com/android/launcher3/testing/TestProtocol.java @@ -114,5 +114,5 @@ public final class TestProtocol { public static final String WORK_PROFILE_REMOVED = "b/159671700"; public static final String TIS_NO_EVENTS = "b/180915942"; public static final String GET_RECENTS_FAILED = "b/177472267"; - public static final String TWO_BUTTON_NORMAL_NOT_OVERVIEW = "b/13714484"; + public static final String TWO_BUTTON_NORMAL_NOT_OVERVIEW = "b/177316094"; } From 12acb4559edb1d421cafd52129e4af2e998b89d2 Mon Sep 17 00:00:00 2001 From: vadimt Date: Mon, 19 Apr 2021 18:50:25 -0700 Subject: [PATCH 06/25] Partial cleanup after b/143488140 Apparently, failures in constructor don't have screenshots. Test: presubmit Bug: 177318681 Change-Id: I8d354658c01fd2f06fb559b0fe5506d0058688b4 --- .../tests/src/com/android/quickstep/FallbackRecentsTest.java | 4 ---- 1 file changed, 4 deletions(-) diff --git a/quickstep/tests/src/com/android/quickstep/FallbackRecentsTest.java b/quickstep/tests/src/com/android/quickstep/FallbackRecentsTest.java index 713fd074be..88f1850072 100644 --- a/quickstep/tests/src/com/android/quickstep/FallbackRecentsTest.java +++ b/quickstep/tests/src/com/android/quickstep/FallbackRecentsTest.java @@ -139,10 +139,6 @@ public class FallbackRecentsTest { TestCommandReceiver.GET_SYSTEM_HEALTH_MESSAGE, startTime.toString()). getString("result")); } - // b/143488140 - mDevice.pressHome(); - mDevice.waitForIdle(); - startAppFast(resolveSystemApp(Intent.CATEGORY_APP_CALCULATOR)); } // b/143488140 From e485941c106550dbecc004b865bdb8d967faa470 Mon Sep 17 00:00:00 2001 From: Alex Chau Date: Tue, 20 Apr 2021 12:18:48 +0100 Subject: [PATCH 07/25] Check null for actinosView in resetPaddingFromTaskSize Bug: 185805100 Fixes: 185805100 Test: manual Change-Id: I03cc5820d77c16873acf3d9600c544d90b515a29 --- .../android/quickstep/views/RecentsView.java | 36 ++++++++++--------- 1 file changed, 19 insertions(+), 17 deletions(-) diff --git a/quickstep/src/com/android/quickstep/views/RecentsView.java b/quickstep/src/com/android/quickstep/views/RecentsView.java index 0eb23920f8..291eef2259 100644 --- a/quickstep/src/com/android/quickstep/views/RecentsView.java +++ b/quickstep/src/com/android/quickstep/views/RecentsView.java @@ -1165,24 +1165,26 @@ public abstract class RecentsView Date: Tue, 20 Apr 2021 15:55:35 +0000 Subject: [PATCH 08/25] Import translations. DO NOT MERGE ANYWHERE Auto-generated-cl: translation import Change-Id: I6e94505a2803c2bd43cb4204944b72987dbb81d2 --- quickstep/res/values-af/strings.xml | 3 +- quickstep/res/values-am/strings.xml | 3 +- quickstep/res/values-ar/strings.xml | 3 +- quickstep/res/values-as/strings.xml | 3 +- quickstep/res/values-az/strings.xml | 3 +- quickstep/res/values-b+sr+Latn/strings.xml | 3 +- quickstep/res/values-be/strings.xml | 3 +- quickstep/res/values-bg/strings.xml | 3 +- quickstep/res/values-bn/strings.xml | 3 +- quickstep/res/values-bs/strings.xml | 3 +- quickstep/res/values-ca/strings.xml | 3 +- quickstep/res/values-cs/strings.xml | 5 +- quickstep/res/values-da/strings.xml | 3 +- quickstep/res/values-de/strings.xml | 99 ++++++++-------------- quickstep/res/values-el/strings.xml | 3 +- quickstep/res/values-es-rUS/strings.xml | 3 +- quickstep/res/values-es/strings.xml | 3 +- quickstep/res/values-et/strings.xml | 3 +- quickstep/res/values-eu/strings.xml | 3 +- quickstep/res/values-fa/strings.xml | 3 +- quickstep/res/values-fi/strings.xml | 3 +- quickstep/res/values-fr-rCA/strings.xml | 3 +- quickstep/res/values-fr/strings.xml | 3 +- quickstep/res/values-gl/strings.xml | 3 +- quickstep/res/values-hi/strings.xml | 3 +- quickstep/res/values-hr/strings.xml | 3 +- quickstep/res/values-hu/strings.xml | 3 +- quickstep/res/values-in/strings.xml | 3 +- quickstep/res/values-is/strings.xml | 3 +- quickstep/res/values-it/strings.xml | 5 +- quickstep/res/values-iw/strings.xml | 3 +- quickstep/res/values-ja/strings.xml | 3 +- quickstep/res/values-ka/strings.xml | 3 +- quickstep/res/values-kk/strings.xml | 3 +- quickstep/res/values-ko/strings.xml | 3 +- quickstep/res/values-ky/strings.xml | 3 +- quickstep/res/values-lt/strings.xml | 3 +- quickstep/res/values-lv/strings.xml | 3 +- quickstep/res/values-mk/strings.xml | 3 +- quickstep/res/values-ml/strings.xml | 3 +- quickstep/res/values-mn/strings.xml | 3 +- quickstep/res/values-ms/strings.xml | 3 +- quickstep/res/values-my/strings.xml | 3 +- quickstep/res/values-nb/strings.xml | 3 +- quickstep/res/values-nl/strings.xml | 3 +- quickstep/res/values-pa/strings.xml | 3 +- quickstep/res/values-pl/strings.xml | 3 +- quickstep/res/values-pt-rPT/strings.xml | 3 +- quickstep/res/values-pt/strings.xml | 3 +- quickstep/res/values-ro/strings.xml | 3 +- quickstep/res/values-ru/strings.xml | 3 +- quickstep/res/values-si/strings.xml | 3 +- quickstep/res/values-sk/strings.xml | 3 +- quickstep/res/values-sl/strings.xml | 3 +- quickstep/res/values-sq/strings.xml | 3 +- quickstep/res/values-sr/strings.xml | 3 +- quickstep/res/values-sv/strings.xml | 3 +- quickstep/res/values-ta/strings.xml | 3 +- quickstep/res/values-th/strings.xml | 3 +- quickstep/res/values-tl/strings.xml | 3 +- quickstep/res/values-tr/strings.xml | 3 +- quickstep/res/values-uk/strings.xml | 3 +- quickstep/res/values-vi/strings.xml | 3 +- quickstep/res/values-zh-rCN/strings.xml | 3 +- quickstep/res/values-zh-rHK/strings.xml | 3 +- quickstep/res/values-zh-rTW/strings.xml | 3 +- quickstep/res/values-zu/strings.xml | 3 +- 67 files changed, 101 insertions(+), 200 deletions(-) diff --git a/quickstep/res/values-af/strings.xml b/quickstep/res/values-af/strings.xml index 6aed173c7d..815ba042b2 100644 --- a/quickstep/res/values-af/strings.xml +++ b/quickstep/res/values-af/strings.xml @@ -78,8 +78,7 @@ "Skermkiekie" "Jou organisasie laat nie hierdie program toe nie" "Slaan navigasietutoriaal oor?" - - + "Jy kan dit later in die %1$s-program kry" "Kanselleer" "Slaan oor" diff --git a/quickstep/res/values-am/strings.xml b/quickstep/res/values-am/strings.xml index dd4f76d9a9..5a3df9d9bb 100644 --- a/quickstep/res/values-am/strings.xml +++ b/quickstep/res/values-am/strings.xml @@ -78,8 +78,7 @@ "ቅጽበታዊ ገጽ እይታ" "ይህ ድርጊት በመተግበሪያው ወይም በእርስዎ ድርጅት አይፈቀድም" "የአሰሳ አጋዥ ሥልጠናን ይዝለሉ?" - - + "ይህን በኋላ በ%1$s መተግበሪያው ውስጥ ማግኘት ይችላሉ" "ይቅር" "ዝለል" diff --git a/quickstep/res/values-ar/strings.xml b/quickstep/res/values-ar/strings.xml index ee58f170a5..8205f89444 100644 --- a/quickstep/res/values-ar/strings.xml +++ b/quickstep/res/values-ar/strings.xml @@ -78,8 +78,7 @@ "لقطة شاشة" "لا يسمح التطبيق أو لا تسمح مؤسستك بهذا الإجراء." "هل تريد تخطي الدليل التوجيهي؟" - - + "يمكنك العثور على هذا الدليل التوجيهي لاحقًا في التطبيق %1$s" "إلغاء" "التخطي" diff --git a/quickstep/res/values-as/strings.xml b/quickstep/res/values-as/strings.xml index be08f08dda..c1a746fdf1 100644 --- a/quickstep/res/values-as/strings.xml +++ b/quickstep/res/values-as/strings.xml @@ -78,8 +78,7 @@ "স্ক্ৰীনশ্বট" "এপ্‌টোৱে অথবা আপোনাৰ প্ৰতিষ্ঠানে এই কাৰ্যটোৰ অনুমতি নিদিয়ে" "নেভিগেশ্বনৰ টিউট’ৰিয়েল এৰিব বিচাৰে নেকি?" - - + "আপুনি এয়া পাছত %1$s এপ্‌টোত বিচাৰিব পাৰিব" "বাতিল কৰক" "এৰি যাওক" diff --git a/quickstep/res/values-az/strings.xml b/quickstep/res/values-az/strings.xml index 2c15eb025a..bd88392075 100644 --- a/quickstep/res/values-az/strings.xml +++ b/quickstep/res/values-az/strings.xml @@ -78,8 +78,7 @@ "Ekran şəkli" "Bu əməliyyata tətbiq və ya təşkilatınız tərəfindən icazə verilmir" "Naviqasiya dərsliyi ötürülsün?" - - + "Bunu sonra %1$s tətbiqində tapa bilərsiniz" "Ləğv edin" "Ötürün" diff --git a/quickstep/res/values-b+sr+Latn/strings.xml b/quickstep/res/values-b+sr+Latn/strings.xml index 3d13a4db6e..21295fc31a 100644 --- a/quickstep/res/values-b+sr+Latn/strings.xml +++ b/quickstep/res/values-b+sr+Latn/strings.xml @@ -78,8 +78,7 @@ "Snimak ekrana" "Aplikacija ili organizacija ne dozvoljavaju ovu radnju" "Želite da preskočite vodič za kretanje?" - - + "Možete da pronađete ovo kasnije u aplikaciji %1$s" "Otkaži" "Preskoči" diff --git a/quickstep/res/values-be/strings.xml b/quickstep/res/values-be/strings.xml index 930a296016..d31468c2fd 100644 --- a/quickstep/res/values-be/strings.xml +++ b/quickstep/res/values-be/strings.xml @@ -78,8 +78,7 @@ "Здымак экрана" "Гэта дзеянне не дазволена праграмай ці вашай арганізацыяй" "Прапусціць дапаможнік па навігацыі?" - - + "Знайсці дапаможнік можна ў праграме \"%1$s\"" "Скасаваць" "Прапусціць" diff --git a/quickstep/res/values-bg/strings.xml b/quickstep/res/values-bg/strings.xml index 3e8deda6c2..d2554d5809 100644 --- a/quickstep/res/values-bg/strings.xml +++ b/quickstep/res/values-bg/strings.xml @@ -78,8 +78,7 @@ "Екранна снимка" "Това действие не е разрешено от приложението или организацията ви" "Пропускане на урока за навигиране?" - - + "Урокът е налице в приложението %1$s" "Отказ" "Пропускане" diff --git a/quickstep/res/values-bn/strings.xml b/quickstep/res/values-bn/strings.xml index df706f93b9..48d26905c0 100644 --- a/quickstep/res/values-bn/strings.xml +++ b/quickstep/res/values-bn/strings.xml @@ -78,8 +78,7 @@ "স্ক্রিনশট নিন" "এই অ্যাপ বা আপনার প্রতিষ্ঠান এই অ্যাকশনটি পারফর্ম করার অনুমতি দেয়নি" "নেভিগেশন টিউটোরিয়াল এড়িয়ে যেতে চান?" - - + "আপনি %1$s অ্যাপে পরে এটি খুঁজে পাবেন" "বাতিল করুন" "এড়িয়ে যান" diff --git a/quickstep/res/values-bs/strings.xml b/quickstep/res/values-bs/strings.xml index 5a99a14581..18494a9c19 100644 --- a/quickstep/res/values-bs/strings.xml +++ b/quickstep/res/values-bs/strings.xml @@ -78,8 +78,7 @@ "Snimak ekrana" "Ovu radnju ne dozvoljava aplikacija ili vaša organizacija" "Preskočiti vodič za navigiranje?" - - + "To možete pronaći kasnije u aplikaciji %1$s" "Otkaži" "Preskoči" diff --git a/quickstep/res/values-ca/strings.xml b/quickstep/res/values-ca/strings.xml index f7006b018b..7c417effa0 100644 --- a/quickstep/res/values-ca/strings.xml +++ b/quickstep/res/values-ca/strings.xml @@ -78,8 +78,7 @@ "Captura de pantalla" "L\'aplicació o la teva organització no permeten aquesta acció" "Vols ometre el tutorial de navegació?" - - + "Pots trobar-ho més tard a l\'aplicació %1$s" "Cancel·la" "Omet" diff --git a/quickstep/res/values-cs/strings.xml b/quickstep/res/values-cs/strings.xml index 23515ffd10..9d1b94e9cd 100644 --- a/quickstep/res/values-cs/strings.xml +++ b/quickstep/res/values-cs/strings.xml @@ -30,7 +30,7 @@ "dnes zbývá: %1$s" "Návrhy aplikací" "Všechny aplikace" - "Vaše předpovídané aplikace" + "Návrhy aplikací pro vás" "Nechte si ve spodním řádku na ploše zobrazovat návrhy aplikací" "Nechte si na řádku oblíbených na ploše zobrazovat návrhy aplikací" "Mějte nejpoužívanější aplikace k dispozici přímo na ploše. Návrhy se budou měnit v závislosti na sledech činností. Aplikace ve spodním řádku se přesunou na vaši plochu." @@ -78,8 +78,7 @@ "Snímek obrazovky" "Aplikace nebo organizace zakazuje tuto akci" "Přeskočit výukový program k navigaci?" - - + "Program později najdete v aplikaci %1$s" "Zrušit" "Přeskočit" diff --git a/quickstep/res/values-da/strings.xml b/quickstep/res/values-da/strings.xml index 8d1166b302..42098dc036 100644 --- a/quickstep/res/values-da/strings.xml +++ b/quickstep/res/values-da/strings.xml @@ -78,8 +78,7 @@ "Screenshot" "Appen eller din organisation tillader ikke denne handling" "Vil du springe selvstudiet for navigation over?" - - + "Du kan finde dette senere i appen %1$s" "Annuller" "Spring over" diff --git a/quickstep/res/values-de/strings.xml b/quickstep/res/values-de/strings.xml index efee106a69..e7d9523c14 100644 --- a/quickstep/res/values-de/strings.xml +++ b/quickstep/res/values-de/strings.xml @@ -45,73 +45,40 @@ "Funktion \"App-Vorschläge\" aktiviert" "Funktion \"App-Vorschläge\" deaktiviert" "Vorgeschlagene App: %1$s" - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + "Wische vom äußersten linken Bildschirmrand." + "Wische vom linken Bildschirmrand zur Bildschirmmitte und lass los." + "Gut gemacht. Versuch es jetzt mal vom rechten Rand aus." + "Wische vom äußersten rechten Bildschirmrand." + "Wische vom rechten Bildschirmrand zur Bildschirmmitte und lass los." + "Du hast die „Zurück“-Touch-Geste abgeschlossen. Nun lernst du, wie du zum Startbildschirm gelangst." + "Wische nicht zu nah am unteren Bildschirmrand." + "Du kannst die Empfindlichkeit von „Zurück“ in den Einstellungen ändern" + "Zum Zurückgehen wischen" + "Wenn du zum letzten Bildschirm zurückgehen möchtest, wische vom linken oder rechten Rand zur Mitte." + "Wische vom unteren Bildschirmrand nach oben." + "Achte darauf, nicht innezuhalten, bevor du loslässt." + "Wische gerade nach oben." + "Du hast die „Startbildschirm“-Touch-Geste abgeschlossen. Als Nächstes lernst du, wie du zwischen Apps wechseln kannst." + "Zum Startbildschirm gehen" + "Wenn du zum Startbildschirm gehen möchtest, wische einfach vom unteren Bildschirmrand nach oben." + "Wische vom unteren Bildschirmrand nach oben." + "Versuche, das Fenster länger festzuhalten, bevor du es loslässt." + "Wische gerade nach oben und halte dann inne." + "Du hast die „Apps wechseln“-Touch-Geste abgeschlossen. Nun bist du bereit, dein Smartphone zu verwenden!" + "Zwischen Apps wechseln" + "Wische auf dem Bildschirm von unten nach oben, halte ihn gedrückt und lass ihn dann los." + "Fertig" + "Weiter" + "Fertig" + "Einstellungen" + "Wiederholen" + "Sehr gut!" + "Anleitung %1$d/%2$d" "Teilen" "Screenshot" "Die App oder deine Organisation lässt diese Aktion nicht zu" - - - - - - - - + "Navigationstutorial überspringen?" + "Das findest du später in der %1$s App" + "Abbrechen" + "Überspringen" diff --git a/quickstep/res/values-el/strings.xml b/quickstep/res/values-el/strings.xml index baf1b87a13..21c29844f5 100644 --- a/quickstep/res/values-el/strings.xml +++ b/quickstep/res/values-el/strings.xml @@ -78,8 +78,7 @@ "Στιγμιότυπο οθόνης" "Αυτή η ενέργεια δεν επιτρέπεται από την εφαρμογή ή τον οργανισμό σας." "Παράβλεψη οδηγού πλοήγησης;" - - + "Βρείτε τον αργότερα στην εφαρμογή %1$s" "Ακύρωση" "Παράβλεψη" diff --git a/quickstep/res/values-es-rUS/strings.xml b/quickstep/res/values-es-rUS/strings.xml index a4cf4bd201..478d1cdb1e 100644 --- a/quickstep/res/values-es-rUS/strings.xml +++ b/quickstep/res/values-es-rUS/strings.xml @@ -78,8 +78,7 @@ "Captura de pantalla" "La app o tu organización no permiten realizar esta acción" "¿Omitir el instructivo de navegación?" - - + "Puedes encontrarlo en la app de %1$s" "Cancelar" "Omitir" diff --git a/quickstep/res/values-es/strings.xml b/quickstep/res/values-es/strings.xml index 4dd7f02d44..454bea7784 100644 --- a/quickstep/res/values-es/strings.xml +++ b/quickstep/res/values-es/strings.xml @@ -78,8 +78,7 @@ "Hacer captura" "No puedes hacerlo porque la aplicación o tu organización no lo permiten" "¿Saltar tutorial de navegación?" - - + "Puedes consultarlo en otro momento en la aplicación %1$s" "Cancelar" "Saltar" diff --git a/quickstep/res/values-et/strings.xml b/quickstep/res/values-et/strings.xml index c0339b96f5..b7299345ab 100644 --- a/quickstep/res/values-et/strings.xml +++ b/quickstep/res/values-et/strings.xml @@ -78,8 +78,7 @@ "Ekraanipilt" "Rakendus või teie organisatsioon on selle toimingu keelanud" "Kas jätta navigeerimise õpetused vahele?" - - + "Leiate selle hiljem rakendusest %1$s" "Tühista" "Jäta vahele" diff --git a/quickstep/res/values-eu/strings.xml b/quickstep/res/values-eu/strings.xml index 7671e778c2..f6d3f235c4 100644 --- a/quickstep/res/values-eu/strings.xml +++ b/quickstep/res/values-eu/strings.xml @@ -78,8 +78,7 @@ "Atera pantaila-argazki bat" "Aplikazioak edo erakundeak ez du eman ekintza hori gauzatzeko baimena" "Nabigazio-tutoriala saltatu nahi duzu?" - - + "Tutorial hau %1$s aplikazioan aurki dezakezu geroago" "Utzi" "Saltatu" diff --git a/quickstep/res/values-fa/strings.xml b/quickstep/res/values-fa/strings.xml index 60e31c5a6f..8ca0f95ec9 100644 --- a/quickstep/res/values-fa/strings.xml +++ b/quickstep/res/values-fa/strings.xml @@ -78,8 +78,7 @@ "نماگرفت" "برنامه یا سازمان شما اجازه نمی‌دهد این کنش انجام شود." "آموزش گام‌به‌گام پیمایش رد شود؟" - - + "می‌توانید آن را بعداً در برنامه %1$s پیدا کنید" "لغو" "رد شدن" diff --git a/quickstep/res/values-fi/strings.xml b/quickstep/res/values-fi/strings.xml index 2f524b5d66..9ce7e6b4f2 100644 --- a/quickstep/res/values-fi/strings.xml +++ b/quickstep/res/values-fi/strings.xml @@ -78,8 +78,7 @@ "Kuvakaappaus" "Sovellus tai organisaatio ei salli tätä toimintoa" "Ohitetaanko navigointiohje?" - - + "Löydät tämän myöhemmin sovelluksesta: %1$s" "Peru" "Ohita" diff --git a/quickstep/res/values-fr-rCA/strings.xml b/quickstep/res/values-fr-rCA/strings.xml index 1277366e5f..da738495c7 100644 --- a/quickstep/res/values-fr-rCA/strings.xml +++ b/quickstep/res/values-fr-rCA/strings.xml @@ -78,8 +78,7 @@ "Capture d\'écran" "L\'application ou votre organisation n\'autorise pas cette action" "Ignorer le tutoriel sur la navigation?" - - + "Vous trouverez le tutoriel dans l\'application %1$s" "Annuler" "Ignorer" diff --git a/quickstep/res/values-fr/strings.xml b/quickstep/res/values-fr/strings.xml index 5f9d6bb676..b6abea7bc9 100644 --- a/quickstep/res/values-fr/strings.xml +++ b/quickstep/res/values-fr/strings.xml @@ -78,8 +78,7 @@ "Capture d\'écran" "Cette action n\'est pas autorisée par l\'application ou par votre organisation" "Ignorer le tutoriel de navigation ?" - - + "Vous le retrouverez dans l\'appli %1$s" "Annuler" "Passer" diff --git a/quickstep/res/values-gl/strings.xml b/quickstep/res/values-gl/strings.xml index b158f311d8..846f68a4c5 100644 --- a/quickstep/res/values-gl/strings.xml +++ b/quickstep/res/values-gl/strings.xml @@ -78,8 +78,7 @@ "Facer captura" "A aplicación ou a túa organización non permite realizar esta acción" "Queres omitir o titorial de navegación?" - - + "Podes atopar isto máis tarde na aplicación %1$s" "Cancelar" "Omitir" diff --git a/quickstep/res/values-hi/strings.xml b/quickstep/res/values-hi/strings.xml index 51b8c13e75..a7711fe10c 100644 --- a/quickstep/res/values-hi/strings.xml +++ b/quickstep/res/values-hi/strings.xml @@ -78,8 +78,7 @@ "स्क्रीनशॉट" "ऐप्लिकेशन या आपका संगठन इस कार्रवाई की अनुमति नहीं देता" "नेविगेशन ट्यूटोरियल छोड़ना चाहते हैं?" - - + "आप बाद में, %1$s ऐप्लिकेशन पर इसे देख सकते हैं" "अभी नहीं" "छोड़ें" diff --git a/quickstep/res/values-hr/strings.xml b/quickstep/res/values-hr/strings.xml index 4b19eab254..d5e4b9dd93 100644 --- a/quickstep/res/values-hr/strings.xml +++ b/quickstep/res/values-hr/strings.xml @@ -78,8 +78,7 @@ "Snimka zaslona" "Aplikacija ili vaša organizacija ne dopuštaju ovu radnju" "Želite li preskočiti vodič za kretanje?" - - + "Kasnije ga možete pronaći u aplikaciji %1$s" "Odustani" "Preskoči" diff --git a/quickstep/res/values-hu/strings.xml b/quickstep/res/values-hu/strings.xml index 215023a86f..386ef3ee3f 100644 --- a/quickstep/res/values-hu/strings.xml +++ b/quickstep/res/values-hu/strings.xml @@ -78,8 +78,7 @@ "Képernyőkép" "Az alkalmazás vagy az Ön szervezete nem engedélyezi ezt a műveletet" "Kihagyja a navigáció bemutatóját?" - - + "Ezt később megtalálhatja a(z) %1$s alkalmazásban" "Mégse" "Kihagyás" diff --git a/quickstep/res/values-in/strings.xml b/quickstep/res/values-in/strings.xml index f9cf9ebd01..941bdb7dd0 100644 --- a/quickstep/res/values-in/strings.xml +++ b/quickstep/res/values-in/strings.xml @@ -78,8 +78,7 @@ "Screenshot" "Tindakan ini tidak diizinkan oleh aplikasi atau organisasi Anda" "Lewati tutorial navigasi?" - - + "Anda dapat menemukan tutorial ini di lain waktu di aplikasi %1$s" "Batal" "Lewati" diff --git a/quickstep/res/values-is/strings.xml b/quickstep/res/values-is/strings.xml index 4e8cce7d9d..6042b47e45 100644 --- a/quickstep/res/values-is/strings.xml +++ b/quickstep/res/values-is/strings.xml @@ -78,8 +78,7 @@ "Skjámynd" "Forritið eða fyrirtækið leyfir ekki þessa aðgerð" "Sleppa flettileiðsögn?" - - + "Þú getur fundið þetta síðar í forritinu %1$s" "Hætta við" "Sleppa" diff --git a/quickstep/res/values-it/strings.xml b/quickstep/res/values-it/strings.xml index a2877ac2f2..6c81d1720e 100644 --- a/quickstep/res/values-it/strings.xml +++ b/quickstep/res/values-it/strings.xml @@ -30,7 +30,7 @@ "Rimanente oggi: %1$s" "App suggerite" "Tutte le app" - "Le app previste" + "App previste per te" "Visualizza app suggerite nella riga inferiore della schermata Home" "Visualizza app suggerite nella riga dei Preferiti della schermata Home" "Accedi facilmente alle app più utilizzate direttamente dalla schermata Home. I suggerimenti varieranno in base alle tue routine. Le app nella riga inferiore verranno spostate più in alto sulla schermata Home." @@ -78,8 +78,7 @@ "Screenshot" "Questa azione non è consentita dall\'app o dall\'organizzazione" "Saltare il tutorial di navigazione?" - - + "Puoi trovarlo in un secondo momento nell\'app %1$s" "Annulla" "Salta" diff --git a/quickstep/res/values-iw/strings.xml b/quickstep/res/values-iw/strings.xml index 0532081654..b77faeb4fa 100644 --- a/quickstep/res/values-iw/strings.xml +++ b/quickstep/res/values-iw/strings.xml @@ -78,8 +78,7 @@ "צילום מסך" "האפליקציה או הארגון שלך אינם מתירים את הפעולה הזאת" "לדלג על המדריך לניווט?" - - + "ניתן למצוא את המדריך מאוחר יותר באפליקציה %1$s" "ביטול" "דילוג" diff --git a/quickstep/res/values-ja/strings.xml b/quickstep/res/values-ja/strings.xml index 87dbb950c8..1cbdf7331c 100644 --- a/quickstep/res/values-ja/strings.xml +++ b/quickstep/res/values-ja/strings.xml @@ -78,8 +78,7 @@ "スクリーンショット" "この操作はアプリまたは組織で許可されていません" "操作チュートリアルをスキップしますか?" - - + "これは後から %1$s アプリで確認できます" "キャンセル" "スキップ" diff --git a/quickstep/res/values-ka/strings.xml b/quickstep/res/values-ka/strings.xml index cdc70d6f88..5dd818d9ac 100644 --- a/quickstep/res/values-ka/strings.xml +++ b/quickstep/res/values-ka/strings.xml @@ -78,8 +78,7 @@ "ეკრანის ანაბეჭდი" "ეს მოქმედება არ არის დაშვებული აპის ან თქვენი ორგანიზაციის მიერ" "გსურთ, გამოტოვოთ ნავიგაციის სახელმძღვანელო?" - - + "ამის მოგვიანებით პოვნა %1$s აპში შეგიძლიათ" "გაუქმება" "გამოტოვება" diff --git a/quickstep/res/values-kk/strings.xml b/quickstep/res/values-kk/strings.xml index bd84c93af1..554d10dc82 100644 --- a/quickstep/res/values-kk/strings.xml +++ b/quickstep/res/values-kk/strings.xml @@ -78,8 +78,7 @@ "Скриншот" "Бұл әрекетке қолданба не ұйым рұқсат етпейді." "Қимылдар оқулығын өткізіп жіберу керек пе?" - - + "Мұны кейін %1$s қолданбасынан таба аласыз." "Бас тарту" "Өткізіп жіберу" diff --git a/quickstep/res/values-ko/strings.xml b/quickstep/res/values-ko/strings.xml index 4138b0f5a0..fbbddd6699 100644 --- a/quickstep/res/values-ko/strings.xml +++ b/quickstep/res/values-ko/strings.xml @@ -78,8 +78,7 @@ "스크린샷" "이 작업은 앱 또는 조직에서 허용되지 않습니다." "이동 방법 튜토리얼을 건너뛰시겠습니까?" - - + "이 튜토리얼은 %1$s 앱에서 다시 볼 수 있습니다" "취소" "건너뛰기" diff --git a/quickstep/res/values-ky/strings.xml b/quickstep/res/values-ky/strings.xml index 2ab089f117..bd50eed506 100644 --- a/quickstep/res/values-ky/strings.xml +++ b/quickstep/res/values-ky/strings.xml @@ -78,8 +78,7 @@ "Скриншот" "Бул аракетти аткарууга колдонмо же ишканаңыз тыюу салган" "Жаңсап өтүү үйрөткүчүн өт-рүп жибер-би?" - - + "Аны кийин %1$s колдонмосунан табасыз" "Жокко чыгаруу" "Өтк-п жиберүү" diff --git a/quickstep/res/values-lt/strings.xml b/quickstep/res/values-lt/strings.xml index 457db01962..2f1db5038a 100644 --- a/quickstep/res/values-lt/strings.xml +++ b/quickstep/res/values-lt/strings.xml @@ -78,8 +78,7 @@ "Ekrano kopija" "Jūsų organizacijoje arba naudojant šią programą neleidžiama atlikti šio veiksmo" "Praleisti naršymo mokymo programą?" - - + "Tai galėsite rasti vėliau programoje „%1$s“" "Atšaukti" "Praleisti" diff --git a/quickstep/res/values-lv/strings.xml b/quickstep/res/values-lv/strings.xml index 2a117be1eb..ce941bc3d9 100644 --- a/quickstep/res/values-lv/strings.xml +++ b/quickstep/res/values-lv/strings.xml @@ -78,8 +78,7 @@ "Veikt ekrānuzņēmumu" "Lietotne vai jūsu organizācija neatļauj veikt šo darbību." "Vai izlaist navigācijas mācības?" - - + "Varēsiet to vēlāk atrast lietotnē %1$s." "Atcelt" "Izlaist" diff --git a/quickstep/res/values-mk/strings.xml b/quickstep/res/values-mk/strings.xml index 120e63e066..f9fd8b3d06 100644 --- a/quickstep/res/values-mk/strings.xml +++ b/quickstep/res/values-mk/strings.xml @@ -78,8 +78,7 @@ "Слика од екранот" "Апликацијата или вашата организација не го дозволува дејствово" "Да се прескокне упатството за навигација?" - - + "Ова може да го најдете подоцна во апликацијата %1$s" "Откажи" "Прескокни" diff --git a/quickstep/res/values-ml/strings.xml b/quickstep/res/values-ml/strings.xml index e8d7f4ca72..fc6bc82d01 100644 --- a/quickstep/res/values-ml/strings.xml +++ b/quickstep/res/values-ml/strings.xml @@ -78,8 +78,7 @@ "സ്ക്രീൻഷോട്ട്" "ഈ നടപടി എടുക്കുന്നത് ആപ്പോ നിങ്ങളുടെ സ്ഥാപനമോ അനുവദിക്കുന്നില്ല" "നാവിഗേഷൻ ട്യൂട്ടോറിയൽ ഒഴിവാക്കണോ?" - - + "%1$s ആപ്പിൽ നിങ്ങൾക്ക് ഇത് പിന്നീട് കാണാനാകും" "റദ്ദാക്കുക" "ഒഴിവാക്കുക" diff --git a/quickstep/res/values-mn/strings.xml b/quickstep/res/values-mn/strings.xml index 86237e18aa..48513eb928 100644 --- a/quickstep/res/values-mn/strings.xml +++ b/quickstep/res/values-mn/strings.xml @@ -78,8 +78,7 @@ "Дэлгэцийн агшин дарах" "Энэ үйлдлийг апп эсвэл танай байгууллага зөвшөөрдөггүй" "Навигацын практик хичээлийг алгасах уу?" - - + "Та үүнийг дараа нь %1$s аппаас олох боломжтой" "Цуцлах" "Алгасах" diff --git a/quickstep/res/values-ms/strings.xml b/quickstep/res/values-ms/strings.xml index 6ec7a81ea9..74b9d086e8 100644 --- a/quickstep/res/values-ms/strings.xml +++ b/quickstep/res/values-ms/strings.xml @@ -78,8 +78,7 @@ "Tangkapan skrin" "Tindakan ini tidak dibenarkan oleh apl atau organisasi anda" "Langkau tutorial navigasi?" - - + "Anda boleh mendapatkan tutorial ini kemudian dalam apl %1$s" "Batal" "Langkau" diff --git a/quickstep/res/values-my/strings.xml b/quickstep/res/values-my/strings.xml index d9c4cfbbd4..919ad6efa7 100644 --- a/quickstep/res/values-my/strings.xml +++ b/quickstep/res/values-my/strings.xml @@ -78,8 +78,7 @@ "ဖန်သားပြင်ဓာတ်ပုံ" "ဤလုပ်ဆောင်ချက်ကို အက်ပ် သို့မဟုတ် သင်၏အဖွဲ့အစည်းက ခွင့်မပြုပါ" "လမ်းညွှန်ခြင်း ရှင်းလင်းပို့ချချက်ကို ကျော်မလား။" - - + "၎င်းကို နောက်မှ %1$s အက်ပ်တွင် ရှာနိုင်သည်" "မလုပ်တော့" "ကျော်ရန်" diff --git a/quickstep/res/values-nb/strings.xml b/quickstep/res/values-nb/strings.xml index 0b3117bfb8..6e7e4a3cf7 100644 --- a/quickstep/res/values-nb/strings.xml +++ b/quickstep/res/values-nb/strings.xml @@ -78,8 +78,7 @@ "Skjermdump" "Appen eller organisasjonen din tillater ikke denne handlingen" "Vil du hoppe over navigeringsveiledning?" - - + "Du kan finne dette i %1$s-appen senere" "Avbryt" "Hopp over" diff --git a/quickstep/res/values-nl/strings.xml b/quickstep/res/values-nl/strings.xml index ecf22eb484..be9329f000 100644 --- a/quickstep/res/values-nl/strings.xml +++ b/quickstep/res/values-nl/strings.xml @@ -78,8 +78,7 @@ "Screenshot" "Deze actie wordt niet toegestaan door de app of je organisatie" "Navigatietutorial overslaan?" - - + "Je vindt dit later terug in de app %1$s" "Annuleren" "Overslaan" diff --git a/quickstep/res/values-pa/strings.xml b/quickstep/res/values-pa/strings.xml index d9fad16a56..227c060230 100644 --- a/quickstep/res/values-pa/strings.xml +++ b/quickstep/res/values-pa/strings.xml @@ -78,8 +78,7 @@ "ਸਕ੍ਰੀਨਸ਼ਾਟ" "ਐਪ ਜਾਂ ਤੁਹਾਡੀ ਸੰਸਥਾ ਵੱਲੋਂ ਇਸ ਕਾਰਵਾਈ ਦੀ ਇਜਾਜ਼ਤ ਨਹੀਂ ਹੈ" "ਕੀ ਨੈਵੀਗੇਸ਼ਨ ਟਿਊਟੋਰੀਅਲ ਨੂੰ ਛੱਡਣਾ ਹੈ?" - - + "ਤੁਸੀਂ ਇਸਨੂੰ ਬਾਅਦ ਵਿੱਚ %1$s ਐਪ ਵਿੱਚ ਲੱਭ ਸਕਦੇ ਹੋ" "ਰੱਦ ਕਰੋ" "ਛੱਡੋ" diff --git a/quickstep/res/values-pl/strings.xml b/quickstep/res/values-pl/strings.xml index 0df44efc39..61d9b9377a 100644 --- a/quickstep/res/values-pl/strings.xml +++ b/quickstep/res/values-pl/strings.xml @@ -78,8 +78,7 @@ "Zrzut ekranu" "Nie możesz wykonać tego działania, bo nie zezwala na to aplikacja lub Twoja organizacja" "Pominąć samouczek nawigacji?" - - + "Znajdziesz to później w aplikacji %1$s" "Anuluj" "Pomiń" diff --git a/quickstep/res/values-pt-rPT/strings.xml b/quickstep/res/values-pt-rPT/strings.xml index 390596c06f..bbc4ce8811 100644 --- a/quickstep/res/values-pt-rPT/strings.xml +++ b/quickstep/res/values-pt-rPT/strings.xml @@ -78,8 +78,7 @@ "Fazer captura de ecrã" "Esta ação não é permitida pela app ou a sua entidade." "Ignorar o tutorial de navegação?" - - + "Pode encontrar isto mais tarde na app %1$s" "Cancelar" "Ignorar" diff --git a/quickstep/res/values-pt/strings.xml b/quickstep/res/values-pt/strings.xml index 1252e60de8..f533bbcbc3 100644 --- a/quickstep/res/values-pt/strings.xml +++ b/quickstep/res/values-pt/strings.xml @@ -78,8 +78,7 @@ "Capturar tela" "Essa ação não é permitida pelo app ou pela organização" "Pular o tutorial de navegação?" - - + "Veja o tutorial mais tarde no app %1$s" "Cancelar" "Pular" diff --git a/quickstep/res/values-ro/strings.xml b/quickstep/res/values-ro/strings.xml index 556acb5a9f..37d2935683 100644 --- a/quickstep/res/values-ro/strings.xml +++ b/quickstep/res/values-ro/strings.xml @@ -78,8 +78,7 @@ "Captură de ecran" "Această acțiune nu este permisă de aplicație sau de organizația dvs." "Omiteți tutorialul de navigare?" - - + "Îl puteți găsi mai târziu în aplicația %1$s" "Anulați" "Omiteți" diff --git a/quickstep/res/values-ru/strings.xml b/quickstep/res/values-ru/strings.xml index 3039a9a60b..8d4c40a210 100644 --- a/quickstep/res/values-ru/strings.xml +++ b/quickstep/res/values-ru/strings.xml @@ -78,8 +78,7 @@ "Скриншот" "Это действие заблокировано приложением или организацией." "Пропустить руководство по жестам?" - - + "Его можно найти в приложении \"%1$s\"." "Отмена" "Пропустить" diff --git a/quickstep/res/values-si/strings.xml b/quickstep/res/values-si/strings.xml index 8ffb580a4e..d526e139ee 100644 --- a/quickstep/res/values-si/strings.xml +++ b/quickstep/res/values-si/strings.xml @@ -78,8 +78,7 @@ "තිර රුව" "මෙම ක්‍රියාව යෙදුම හෝ ඔබේ සංවිධානය මගින් ඉඩ නොදේ" "නිබන්ධනය සංචාලනය මඟ හරින්නද?" - - + "ඔබට මෙය පසුව %1$s යෙදුම තුළ සොයා ගත හැකිය" "අවලංගු කරන්න" "මඟ හරින්න" diff --git a/quickstep/res/values-sk/strings.xml b/quickstep/res/values-sk/strings.xml index 86d0a8e296..24a4ac974f 100644 --- a/quickstep/res/values-sk/strings.xml +++ b/quickstep/res/values-sk/strings.xml @@ -78,8 +78,7 @@ "Snímka obrazovky" "Aplikácia alebo vaša organizácia túto akciu nepovoľuje" "Chcete preskočiť návod na navigáciu?" - - + "Tento návod nájdete v aplikácii %1$s" "Zrušiť" "Preskočiť" diff --git a/quickstep/res/values-sl/strings.xml b/quickstep/res/values-sl/strings.xml index 0d1f015ef2..fdc8a6a4b4 100644 --- a/quickstep/res/values-sl/strings.xml +++ b/quickstep/res/values-sl/strings.xml @@ -78,8 +78,7 @@ "Posnetek zaslona" "Aplikacija ali vaša organizacija ne dovoljuje tega dejanja" "Želite preskočiti vadnico za krmarjenje?" - - + "To lahko pozneje najdete v aplikaciji %1$s." "Prekliči" "Preskoči" diff --git a/quickstep/res/values-sq/strings.xml b/quickstep/res/values-sq/strings.xml index b50976fedc..36e0afc371 100644 --- a/quickstep/res/values-sq/strings.xml +++ b/quickstep/res/values-sq/strings.xml @@ -78,8 +78,7 @@ "Pamja e ekranit" "Ky veprim nuk lejohet nga aplikacioni ose organizata jote" "Të kapërcehet udhëzuesi i navigimit?" - - + "Këtë mund ta gjesh më vonë tek aplikacioni %1$s" "Anulo" "Kapërce" diff --git a/quickstep/res/values-sr/strings.xml b/quickstep/res/values-sr/strings.xml index c940c15646..8a462f982d 100644 --- a/quickstep/res/values-sr/strings.xml +++ b/quickstep/res/values-sr/strings.xml @@ -78,8 +78,7 @@ "Снимак екрана" "Апликација или организација не дозвољавају ову радњу" "Желите да прескочите водич за кретање?" - - + "Можете да пронађете ово касније у апликацији %1$s" "Откажи" "Прескочи" diff --git a/quickstep/res/values-sv/strings.xml b/quickstep/res/values-sv/strings.xml index b72f10294e..bf6985030c 100644 --- a/quickstep/res/values-sv/strings.xml +++ b/quickstep/res/values-sv/strings.xml @@ -78,8 +78,7 @@ "Skärmbild" "Appen eller organisationen tillåter inte den här åtgärden" "Vill du hoppa över självstudierna?" - - + "Du kan hitta det här igen i %1$s-appen" "Avbryt" "Hoppa över" diff --git a/quickstep/res/values-ta/strings.xml b/quickstep/res/values-ta/strings.xml index 1f25cc930c..089c95de7b 100644 --- a/quickstep/res/values-ta/strings.xml +++ b/quickstep/res/values-ta/strings.xml @@ -78,8 +78,7 @@ "ஸ்கிரீன்ஷாட்" "ஆப்ஸோ உங்கள் நிறுவனமோ இந்த செயலை அனுமதிப்பதில்லை" "வழிகாட்டுதல் பயிற்சியைத் தவிர்க்கவா?" - - + "%1$s ஆப்ஸில் பிறகு இதைக் கண்டறியலாம்" "ரத்துசெய்" "தவிர்" diff --git a/quickstep/res/values-th/strings.xml b/quickstep/res/values-th/strings.xml index 8ca076f57e..d7061089f2 100644 --- a/quickstep/res/values-th/strings.xml +++ b/quickstep/res/values-th/strings.xml @@ -78,8 +78,7 @@ "ภาพหน้าจอ" "แอปหรือองค์กรของคุณไม่อนุญาตการดำเนินการนี้" "ข้ามบทแนะนำการนำทางไหม" - - + "คุณดูบทแนะนำนี้ได้ภายหลังในแอป %1$s" "ยกเลิก" "ข้าม" diff --git a/quickstep/res/values-tl/strings.xml b/quickstep/res/values-tl/strings.xml index be9dc95338..5056481ccf 100644 --- a/quickstep/res/values-tl/strings.xml +++ b/quickstep/res/values-tl/strings.xml @@ -78,8 +78,7 @@ "Screenshot" "Hindi pinapayagan ng app o ng iyong organisasyon ang pagkilos na ito" "Laktawan ang tutorial sa pag-navigate?" - - + "Makikita mo ito sa %1$s app sa ibang pagkakataon" "Kanselahin" "Laktawan" diff --git a/quickstep/res/values-tr/strings.xml b/quickstep/res/values-tr/strings.xml index 7df01363a8..a22247b2de 100644 --- a/quickstep/res/values-tr/strings.xml +++ b/quickstep/res/values-tr/strings.xml @@ -78,8 +78,7 @@ "Ekran görüntüsü" "Uygulamanız veya kuruluşunuz bu işleme izin vermiyor" "Gezinme eğitici içeriği atlansın mı?" - - + "Bunu daha sonra %1$s uygulamasında bulabilirsiniz" "İptal" "Atla" diff --git a/quickstep/res/values-uk/strings.xml b/quickstep/res/values-uk/strings.xml index 6c11d95179..c63cec4c0a 100644 --- a/quickstep/res/values-uk/strings.xml +++ b/quickstep/res/values-uk/strings.xml @@ -78,8 +78,7 @@ "Знімок екрана" "Ця дія заборонена додатком або адміністратором організації" "Пропустити посібник із навігації?" - - + "Ви знайдете його пізніше в додатку %1$s" "Скасувати" "Пропустити" diff --git a/quickstep/res/values-vi/strings.xml b/quickstep/res/values-vi/strings.xml index 215125c6a6..fc3ef3ffff 100644 --- a/quickstep/res/values-vi/strings.xml +++ b/quickstep/res/values-vi/strings.xml @@ -78,8 +78,7 @@ "Chụp ảnh màn hình" "Ứng dụng hoặc tổ chức của bạn không cho phép thực hiện hành động này" "Bỏ qua phần hướng dẫn thao tác?" - - + "Bạn có thể tìm lại phần hướng dẫn này trong ứng dụng %1$s" "Hủy" "Bỏ qua" diff --git a/quickstep/res/values-zh-rCN/strings.xml b/quickstep/res/values-zh-rCN/strings.xml index 22d8393e32..9d39100128 100644 --- a/quickstep/res/values-zh-rCN/strings.xml +++ b/quickstep/res/values-zh-rCN/strings.xml @@ -78,8 +78,7 @@ "屏幕截图" "该应用或您所在的单位不允许执行此操作" "要跳过导航教程吗?" - - + "您之后可以在“%1$s”应用中找到此教程" "取消" "跳过" diff --git a/quickstep/res/values-zh-rHK/strings.xml b/quickstep/res/values-zh-rHK/strings.xml index b6efec28ef..5522a67f05 100644 --- a/quickstep/res/values-zh-rHK/strings.xml +++ b/quickstep/res/values-zh-rHK/strings.xml @@ -78,8 +78,7 @@ "螢幕截圖" "應用程式或您的機構不允許此操作" "要略過手勢操作教學課程嗎?" - - + "您之後可以在「%1$s」應用程式找到這些說明" "取消" "略過" diff --git a/quickstep/res/values-zh-rTW/strings.xml b/quickstep/res/values-zh-rTW/strings.xml index 410e70a67d..20af2b4f88 100644 --- a/quickstep/res/values-zh-rTW/strings.xml +++ b/quickstep/res/values-zh-rTW/strings.xml @@ -78,8 +78,7 @@ "擷取螢幕畫面" "這個應用程式或貴機構不允許執行這個動作" "要略過手勢操作教學課程嗎?" - - + "你之後可以在「%1$s」應用程式找到這些說明" "取消" "略過" diff --git a/quickstep/res/values-zu/strings.xml b/quickstep/res/values-zu/strings.xml index 4df1a45220..a118f1d773 100644 --- a/quickstep/res/values-zu/strings.xml +++ b/quickstep/res/values-zu/strings.xml @@ -78,8 +78,7 @@ "Isithombe-skrini" "Lesi senzo asivunyelwanga uhlelo lokusebenza noma inhlangano yakho" "Yeqa isifundo sokuzulazula?" - - + "Lokhu ungakuthola kamuva ku-app ye-%1$s" "Khansela" "Yeqa" From 5a3b0497c8037868345b0b80ef17915d8b6f746e Mon Sep 17 00:00:00 2001 From: Bill Yi Date: Tue, 20 Apr 2021 15:56:18 +0000 Subject: [PATCH 09/25] Import translations. DO NOT MERGE ANYWHERE Auto-generated-cl: translation import Change-Id: Ifdb448fe337ff8ebb0ec85928563e18d09603bb5 --- res/values-cs/strings.xml | 2 +- res/values-de/strings.xml | 78 ++++++++++++++++----------------------- res/values-es/strings.xml | 2 +- res/values-fr/strings.xml | 4 +- res/values-hi/strings.xml | 2 +- res/values-hr/strings.xml | 2 +- res/values-it/strings.xml | 4 +- res/values-iw/strings.xml | 58 ++++++++++++++--------------- res/values-ky/strings.xml | 6 +-- res/values-mr/strings.xml | 2 +- res/values-my/strings.xml | 8 ++-- 11 files changed, 76 insertions(+), 92 deletions(-) diff --git a/res/values-cs/strings.xml b/res/values-cs/strings.xml index a742f2f44d..a7f99087a2 100644 --- a/res/values-cs/strings.xml +++ b/res/values-cs/strings.xml @@ -116,7 +116,7 @@ "Změnit nastavení" "Zobrazovat puntíky s oznámením" "Přidat na plochu ikony aplikací" - "Pro nové aplikace" + "U nových aplikací" "Neznámé" "Odstranit" "Hledat" diff --git a/res/values-de/strings.xml b/res/values-de/strings.xml index 63e5192067..77ddc86a8d 100644 --- a/res/values-de/strings.xml +++ b/res/values-de/strings.xml @@ -26,47 +26,39 @@ "Heruntergeladene App im abgesicherten Modus deaktiviert" "Widgets im abgesicherten Modus deaktiviert" "Verknüpfung nicht verfügbar" - - - - - - - - + "Startbildschirm" + "Splitscreen" + "Tippen und halten, um ein Widget zu bewegen." + "Doppeltippen und halten, um ein Widget zu bewegen oder benutzerdefinierte Aktionen zu nutzen." "%1$d × %2$d" "%1$d breit und %2$d hoch" "Zum manuellen Hinzufügen gedrückt halten" "Automatisch hinzufügen" - - - - + + %1$d Widgets + %1$d Widget + + + %1$d Verknüpfungen + %1$d Verknüpfung + + "%1$s, %2$s" "Widgets" - - - - - - - - - - - - - - + "Suche" + "Text aus dem Suchfeld löschen" + "Keine Widgets verfügbar" + "Keine Suchergebnisse" + "Privat" + "Geschäftlich" + "Unterhaltungen" "Apps finden" "Apps werden geladen…" "Keine Apps für \"%1$s\" gefunden" "Weitere Apps suchen" "App" "Benachrichtigungen" - - - - + "Tippen und halten, um eine Verknüpfung zu bewegen." + "Doppeltippen und halten, um eine Verknüpfung zu bewegen oder benutzerdefinierte Aktionen zu nutzen." "Auf diesem Startbildschirm ist kein Platz mehr vorhanden." "Ablage \"Favoriten\" ist voll." "Liste der Apps" @@ -108,7 +100,7 @@ "Designs und Hintergründe" "Startbildschirm-Einstellungen" "Von deinem Administrator deaktiviert" - "Drehung des Startbildschirms zulassen" + "Drehen des Startbildschirms zulassen" "Beim Drehen des Smartphones" "App-Benachrichtigungspunkte" "An" @@ -124,8 +116,7 @@ "Suchen" "Diese App ist nicht installiert" "Die App für dieses Symbol ist nicht installiert. Du kannst das Symbol entfernen oder die App lokalisieren und dann manuell installieren." - - + "%1$s wird installiert, %2$s abgeschlossen" "%1$s wird heruntergeladen, %2$s abgeschlossen" "Warten auf Installation von %1$s" "Widgetliste" @@ -165,20 +156,13 @@ "Weiter" "OK" "Arbeitsprofil pausiert" - - - - - - - - - - - - - - + "Geschäftliche Apps können dir keine Benachrichtigungen senden, deinen Akku nicht nutzen und nicht auf deinen Standort zugreifen" + "Das Arbeitsprofil ist pausiert. Geschäftliche Apps können dir keine Benachrichtigungen senden, deinen Akku nicht nutzen und nicht auf deinen Standort zugreifen." + "Geschäftliche Apps sind gekennzeichnet und für deinen IT-Administrator sichtbar" + "OK" + "Geschäftliche Apps pausieren" + "Aktivieren" + "Filter" "Geschäftliche Apps und Benachrichtigungen pausieren" "Fehler: %1$s" diff --git a/res/values-es/strings.xml b/res/values-es/strings.xml index 3cd084bc8d..8b9ab0cb5c 100644 --- a/res/values-es/strings.xml +++ b/res/values-es/strings.xml @@ -110,7 +110,7 @@ "Cambiar ajustes" "Mostrar puntos de notificación" "Añadir aplicaciones a la pantalla de inicio" - "Para aplicaciones nuevas" + "Añade el icono de una aplicación nueva instalada a la pantalla de inicio" "Desconocido" "Quitar" "Buscar" diff --git a/res/values-fr/strings.xml b/res/values-fr/strings.xml index fe12e37e94..f336031a31 100644 --- a/res/values-fr/strings.xml +++ b/res/values-fr/strings.xml @@ -20,7 +20,7 @@ "Launcher3" - "Travail" + "Pro" "L\'application n\'est pas installée." "Application indisponible" "L\'application téléchargée est désactivée en mode sécurisé." @@ -98,7 +98,7 @@ "Dossier : %1$s, %2$d éléments ou plus" "Fonds d\'écran" "Styles et fonds d\'écran" - "Paramètres d\'accueil" + "Paramètres de l\'accueil" "Désactivé par votre administrateur" "Autoriser la rotation de l\'écran d\'accueil" "Lorsque vous faites pivoter le téléphone" diff --git a/res/values-hi/strings.xml b/res/values-hi/strings.xml index 1bdbbcb74e..478d87ea35 100644 --- a/res/values-hi/strings.xml +++ b/res/values-hi/strings.xml @@ -124,7 +124,7 @@ "होम स्‍क्रीन में जोड़ें" "आइटम यहां ले जाएं" "होम स्क्रीन में आइटम जोड़ा गया" - "आइटम निकाला गया" + "आइटम हटाया गया" "पहले जैसा करें" "आइटम ले जाएं" "पंक्ति %1$s स्तंभ %2$s पर ले जाएं" diff --git a/res/values-hr/strings.xml b/res/values-hr/strings.xml index 7589ea87bb..8ebc33ff47 100644 --- a/res/values-hr/strings.xml +++ b/res/values-hr/strings.xml @@ -68,7 +68,7 @@ "Popis radnih aplikacija" "Ukloni" "Deinstaliraj" - "Info o aplikaciji" + "Podaci o aplikaciji" "Instaliraj" "Ne predlaži aplikaciju" "Prikvači predviđenu apl." diff --git a/res/values-it/strings.xml b/res/values-it/strings.xml index 7857feff3e..9e135763ae 100644 --- a/res/values-it/strings.xml +++ b/res/values-it/strings.xml @@ -98,7 +98,7 @@ "Cartella: %1$s, %2$d o più elementi" "Sfondi" "Stili e sfondi" - "Impostazioni Home" + "Impostazioni schermata Home" "Disattivata dall\'amministratore" "Consenti rotazione della schermata Home" "Con il telefono ruotato" @@ -109,7 +109,7 @@ "Per mostrare gli indicatori di notifica, attiva le notifiche per l\'app %1$s" "Modifica impostazioni" "Mostra indicatori di notifica" - "Aggiungi icone app a schermata Home" + "Aggiungi icone delle app alla schermata Home" "Per le nuove app" "Sconosciuto" "Rimuovi" diff --git a/res/values-iw/strings.xml b/res/values-iw/strings.xml index 9636353be6..639aa86c3a 100644 --- a/res/values-iw/strings.xml +++ b/res/values-iw/strings.xml @@ -56,9 +56,9 @@ "עבודה" "שיחות" "חיפוש אפליקציות" - "טוען אפליקציות…" + "טעינת אפליקציות מתבצעת…" "לא נמצאו אפליקציות התואמות ל-\"%1$s\"" - "חפש אפליקציות נוספות" + "חיפוש אפליקציות נוספות" "אפליקציה" "התראות" "כדי להעביר קיצור דרך למקום אחר יש לגעת ולא להרפות." @@ -68,17 +68,17 @@ "רשימת אפליקציות" "רשימת אפליקציות אישיות" "רשימת אפליקציות עבודה" - "הסר" + "הסרה" "להסרת התקנה" "פרטי אפליקציה" "התקנה" "בלי להציע את האפליקציה" "הצמדת החיזוי" - "התקן קיצורי דרך" + "התקנת קיצורי דרך" "מאפשר לאפליקציה להוסיף קיצורי דרך ללא התערבות המשתמש." - "קרא הגדרות וקיצורי דרך של דף הבית" + "קריאת הגדרות וקיצורי דרך של דף הבית" "מאפשר לאפליקציה לקרוא את ההגדרות וקיצורי הדרך בדף הבית." - "כתוב הגדרות וקיצורי דרך של דף הבית" + "כתיבת הגדרות וקיצורי דרך של דף הבית" "מאפשר לאפליקציה לשנות את ההגדרות וקיצורי הדרך בדף הבית." "%1$s אינו רשאי להתקשר" "בעיה בטעינת ווידג\'ט" @@ -95,59 +95,59 @@ "‏דף %1$d מתוך %2$d" "‏מסך דף הבית %1$d מתוך %2$d" "מסך דף הבית חדש" - "תיקיה פתוחה, %1$d על %2$d" - "הקש כדי לסגור את התיקייה" - "הקש כדי לשמור שינוי שם" - "התיקיה נסגרה" - "שם התיקיה שונה ל-%1$s" + "תיקייה פתוחה, %1$d על %2$d" + "יש להקיש כדי לסגור את התיקייה" + "יש להקיש כדי לשמור שינוי שם" + "התיקייה נסגרה" + "שם התיקייה שונה ל-%1$s" "תיקייה: %1$s, מספר הפריטים: %2$d" "תיקייה: %1$s, %2$d פריטים או יותר" "טפטים" "סגנונות וטפטים" - "הגדרות דף הבית" + "הגדרות של מסך הבית" "הושבת על ידי מנהל המערכת שלך" - "אפשרות סיבוב של מסך דף הבית" + "סיבוב של מסך הבית" "כאשר הטלפון מסובב" "סימני ההתראות" "מופעל" "כבוי" "נדרשת גישה להתראות" "כדי להציג את סימני ההתראות,יש להפעיל התראות מהאפליקציה %1$s" - "שנה את ההגדרות" + "שינוי ההגדרות" "הצגת סימני ההתראות" "הוספת סמלי אפליקציות למסך הבית" "לאפליקציות חדשות" "לא ידוע" - "הסר" + "הסרה" "חיפוש" "אפליקציה זו אינה מותקנת" "האפליקציה של סמל זה אינה מותקנת. ניתן להסיר אותו, או לחפש את האפליקציה ולהתקין אותה ידנית." "%1$s בתהליך התקנה, %2$s הושלמו" - "מוריד את %1$s, %2$s הושלמו" + "הורדת %1$s מתבצעת, %2$s הושלמו" "מחכה להתקנה של %1$s" "רשימת ווידג\'טים" "רשימת הווידג\'טים נסגרה" "הוספה למסך דף הבית" - "העבר את הפריט לכאן" + "העברת הפריט לכאן" "הפריט הועבר אל מסך דף הבית" "הפריט הוסר" "ביטול" - "העבר את הפריט" - "העבר אל שורה %1$s עמודה %2$s" - "העבר אל מיקום %1$s" - "העבר אל מיקום %1$s במועדפים" + "העברת הפריט" + "העברה אל שורה %1$s עמודה %2$s" + "העברה אל מיקום %1$s" + "העברה אל מיקום %1$s במועדפים" "הפריט הועבר" - "הוסף לתיקייה: %1$s" - "העבר אל התיקייה עם %1$s" + "הוספה לתיקייה: %1$s" + "הוספה לתיקייה עם %1$s" "הפריט נוסף לתיקייה" - "צור תיקייה עם: %1$s" + "יצירת תיקייה עם: %1$s" "התיקייה נוצרה" "העבר אל מסך דף הבית" - "שנה גודל" - "הגדל רוחב" - "הגדל גובה" - "הקטן רוחב" - "הקטן גובה" + "שינוי גודל" + "הגדלת רוחב" + "הגדלת גובה" + "הקטנת רוחב" + "הקטנת גובה" "גודל הווידג\'ט שונה - רוחב %1$s גובה %2$s" "קיצורי דרך" "קיצורי דרך והתראות" diff --git a/res/values-ky/strings.xml b/res/values-ky/strings.xml index 7606ca10e2..50c36d58c9 100644 --- a/res/values-ky/strings.xml +++ b/res/values-ky/strings.xml @@ -50,7 +50,7 @@ "Издөө жыйынтыктары жок" "Жеке" "Жумуш" - "Жазышуулар" + "Сүйлөшүүлөр" "Колдонмолорду издөө" "Колдонмолор жүктөлүүдө…" "\"%1$s\" сурамына дал келген колдонмолор табылган жок" @@ -100,8 +100,8 @@ "Стилдер жана тушкагаздар" "Башкы бет жөндөөлөрү" "Администраторуңуз өчүрүп койгон" - "Башкы экранды айлантууга уруксат берүү" - "Телефон айланганда" + "Башкы экранды бурууга уруксат берүү" + "Телефон бурулганда" "Билдирмелер белгилери" "Күйүк" "Өчүк" diff --git a/res/values-mr/strings.xml b/res/values-mr/strings.xml index 8ae7bdfa0d..7fc330eb61 100644 --- a/res/values-mr/strings.xml +++ b/res/values-mr/strings.xml @@ -110,7 +110,7 @@ "सेटिंग्ज बदला" "सूचना बिंदू दाखवा" "होम स्क्रीनवर ॲप आयकन जोडा" - "नवीन ॲप्ससाठी" + "नवीन अ‍ॅप्ससाठी" "अज्ञात" "काढा" "Search" diff --git a/res/values-my/strings.xml b/res/values-my/strings.xml index c7960a663a..b42960204b 100644 --- a/res/values-my/strings.xml +++ b/res/values-my/strings.xml @@ -103,13 +103,13 @@ "ပင်မစာမျက်နှာလှည့်ခြင်းကို ခွင့်ပြုပါ" "ဖုန်းကိုလှည့်ထားစဉ်" "သတိပေးချက် အစက်များ" - "ဖွင့်ထားသည်" - "ပိတ်ထားသည်" + "ဖွင့်" + "ပိတ်" "အကြောင်းကြားချက် အသုံးပြုခွင့် လိုအပ်သည်" "အကြောင်းကြားချက် အစက်များကို ပြသရန် %1$s အတွက် အက်ပ်အကြောင်းကြားချက်များကို ဖွင့်ပါ" "ဆက်တင်များ ပြောင်းရန်" - "သတိပေးချက် အစက်များ ပြရန်" - "\'ပင်မစာမျက်နှာ\' တွင် အက်ပ်သင်္ကေတထည့်ရန်" + "အကြောင်းကြားချက် အစက်များ ပြရန်" + "ပင်မစာမျက်နှာတွင် အက်ပ်သင်္ကေတထည့်ရန်" "အက်ပ်အသစ်များအတွက်" "မသိ" "ဖယ်ရှားရန်" From 006cdeb6410768e1c79c3bab1e96680588c6e520 Mon Sep 17 00:00:00 2001 From: Schneider Victor-tulias Date: Tue, 20 Apr 2021 10:23:31 -0700 Subject: [PATCH 10/25] Add a feature flag for smartspace dismiss option. Test: manual bug: 184179894 Change-Id: I568f7809f9a2407cf470d82c32a05956fcaaf807 --- src/com/android/launcher3/config/FeatureFlags.java | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/com/android/launcher3/config/FeatureFlags.java b/src/com/android/launcher3/config/FeatureFlags.java index 6331ef2862..aa9cc17965 100644 --- a/src/com/android/launcher3/config/FeatureFlags.java +++ b/src/com/android/launcher3/config/FeatureFlags.java @@ -170,6 +170,10 @@ public final class FeatureFlags { "Replace Smartspace with the enhanced version. " + "Ignored if ENABLE_SMARTSPACE_UNIVERSAL is enabled."); + public static final BooleanFlag ENABLE_SMARTSPACE_DISMISS = new DeviceFlag( + "ENABLE_SMARTSPACE_DISMISS", false, + "Adds a menu option to dismiss the current Enhanced Smartspace card."); + public static final BooleanFlag ALWAYS_USE_HARDWARE_OPTIMIZATION_FOR_FOLDER_ANIMATIONS = getDebugFlag( "ALWAYS_USE_HARDWARE_OPTIMIZATION_FOR_FOLDER_ANIMATIONS", false, From 0dfce759a9972e8ac72ebd13e30afd75a6f91913 Mon Sep 17 00:00:00 2001 From: Winson Chung Date: Tue, 20 Apr 2021 11:33:29 -0700 Subject: [PATCH 11/25] Reset activity reference after invalidation Bug: 185909226 Test: Presubmit Change-Id: Id0a6a1c5301c66a515cefcab58b77495081c6190 --- quickstep/src/com/android/quickstep/AbsSwipeUpHandler.java | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/quickstep/src/com/android/quickstep/AbsSwipeUpHandler.java b/quickstep/src/com/android/quickstep/AbsSwipeUpHandler.java index 75992342aa..dbb8272621 100644 --- a/quickstep/src/com/android/quickstep/AbsSwipeUpHandler.java +++ b/quickstep/src/com/android/quickstep/AbsSwipeUpHandler.java @@ -65,6 +65,7 @@ import android.graphics.Matrix; import android.graphics.PointF; import android.graphics.Rect; import android.os.Build; +import android.os.Handler; import android.os.SystemClock; import android.view.MotionEvent; import android.view.View; @@ -135,6 +136,7 @@ public abstract class AbsSwipeUpHandler, protected final BaseActivityInterface mActivityInterface; protected final InputConsumerProxy mInputConsumerProxy; protected final ActivityInitListener mActivityInitListener; + private final Handler mHandler = new Handler(); // Callbacks to be made once the recents animation starts private final ArrayList mRecentsAnimationStartCallbacks = new ArrayList<>(); protected RecentsAnimationController mRecentsAnimationController; @@ -1357,6 +1359,10 @@ public abstract class AbsSwipeUpHandler, mActivityInitListener.unregister(); ActivityManagerWrapper.getInstance().unregisterTaskStackListener(mActivityRestartListener); mTaskSnapshot = null; + mHandler.post(() -> { + // Defer clearing the activity since invalidation can happen over multiple callbacks + mActivity = null; + }); } private void invalidateHandlerWithLauncher() { From 8e64bba9cf5079dadc677d876958afc2f4aea706 Mon Sep 17 00:00:00 2001 From: Winson Chung Date: Tue, 20 Apr 2021 13:26:26 -0700 Subject: [PATCH 12/25] Add some logging for transposed mode in landscape Bug: 185820525 Test: Presubmit Change-Id: Id4cf605fd5c3277273025ac1a73f25add0608412 --- .../src/com/android/quickstep/TaplTestsQuickstep.java | 4 ++++ src/com/android/launcher3/DeviceProfile.java | 10 ++++++++++ src/com/android/launcher3/InvariantDeviceProfile.java | 9 +++++++++ src/com/android/launcher3/Launcher.java | 4 +++- src/com/android/launcher3/testing/TestProtocol.java | 1 + .../android/launcher3/ui/PortraitLandscapeRunner.java | 5 +++++ 6 files changed, 32 insertions(+), 1 deletion(-) diff --git a/quickstep/tests/src/com/android/quickstep/TaplTestsQuickstep.java b/quickstep/tests/src/com/android/quickstep/TaplTestsQuickstep.java index 0fe5432ceb..a700e16d64 100644 --- a/quickstep/tests/src/com/android/quickstep/TaplTestsQuickstep.java +++ b/quickstep/tests/src/com/android/quickstep/TaplTestsQuickstep.java @@ -23,6 +23,7 @@ import static org.junit.Assert.assertNotNull; import static org.junit.Assert.assertTrue; import android.content.Intent; +import android.util.Log; import androidx.test.filters.LargeTest; import androidx.test.runner.AndroidJUnit4; @@ -36,6 +37,7 @@ import com.android.launcher3.tapl.LauncherInstrumentation.NavigationModel; import com.android.launcher3.tapl.Overview; import com.android.launcher3.tapl.OverviewActions; import com.android.launcher3.tapl.OverviewTask; +import com.android.launcher3.testing.TestProtocol; import com.android.launcher3.ui.TaplTestsLauncher3; import com.android.quickstep.NavigationModeSwitchRule.NavigationModeSwitch; import com.android.quickstep.views.RecentsView; @@ -187,10 +189,12 @@ public class TaplTestsQuickstep extends AbstractQuickStepTest { @NavigationModeSwitch @PortraitLandscape public void testSwitchToOverview() throws Exception { + Log.d(TestProtocol.LAUNCHER_NOT_TRANSPOSED, "testSwitchToOverview"); assertNotNull("Workspace.switchToOverview() returned null", mLauncher.pressHome().switchToOverview()); assertTrue("Launcher internal state didn't switch to Overview", isInState(() -> LauncherState.OVERVIEW)); + Log.d(TestProtocol.LAUNCHER_NOT_TRANSPOSED, "testSwitchToOverview finished"); } @Test diff --git a/src/com/android/launcher3/DeviceProfile.java b/src/com/android/launcher3/DeviceProfile.java index 985a445f81..dae4f3b8dd 100644 --- a/src/com/android/launcher3/DeviceProfile.java +++ b/src/com/android/launcher3/DeviceProfile.java @@ -25,6 +25,7 @@ import android.content.res.Resources; import android.graphics.Point; import android.graphics.PointF; import android.graphics.Rect; +import android.util.Log; import android.view.Surface; import android.view.WindowInsets; import android.view.WindowManager; @@ -35,6 +36,7 @@ import com.android.launcher3.config.FeatureFlags; import com.android.launcher3.graphics.IconShape; import com.android.launcher3.icons.DotRenderer; import com.android.launcher3.icons.IconNormalizer; +import com.android.launcher3.testing.TestProtocol; import com.android.launcher3.util.DisplayController; import com.android.launcher3.util.DisplayController.Info; import com.android.launcher3.util.WindowBounds; @@ -973,6 +975,10 @@ public class DeviceProfile { mInfo = info; mTransposeLayoutWithOrientation = context.getResources() .getBoolean(R.bool.hotseat_transpose_layout_with_orientation); + if (TestProtocol.sDebugTracing) { + Log.d(TestProtocol.LAUNCHER_NOT_TRANSPOSED, + "transposeLayout=" + mTransposeLayoutWithOrientation); + } } public Builder setSizeRange(Point minSize, Point maxSize) { @@ -985,6 +991,10 @@ public class DeviceProfile { mWidth = width; mHeight = height; mIsLandscape = mWidth > mHeight; + if (TestProtocol.sDebugTracing) { + Log.d(TestProtocol.LAUNCHER_NOT_TRANSPOSED, + "isLandscape=" + mIsLandscape + " w=" + mWidth + " h=" + mHeight); + } return this; } diff --git a/src/com/android/launcher3/InvariantDeviceProfile.java b/src/com/android/launcher3/InvariantDeviceProfile.java index f19877793b..a863e6b55c 100644 --- a/src/com/android/launcher3/InvariantDeviceProfile.java +++ b/src/com/android/launcher3/InvariantDeviceProfile.java @@ -48,6 +48,7 @@ import androidx.annotation.Nullable; import androidx.annotation.VisibleForTesting; import com.android.launcher3.graphics.IconShape; +import com.android.launcher3.testing.TestProtocol; import com.android.launcher3.util.ConfigMonitor; import com.android.launcher3.util.DisplayController; import com.android.launcher3.util.DisplayController.Info; @@ -338,6 +339,10 @@ public class InvariantDeviceProfile { DeviceProfile.Builder builder = new DeviceProfile.Builder(context, this, displayInfo) .setSizeRange(new Point(displayInfo.smallestSize), new Point(displayInfo.largestSize)); + if (TestProtocol.sDebugTracing) { + Log.d(TestProtocol.LAUNCHER_NOT_TRANSPOSED, + "largeSide=" + largeSide + " smallSide=" + smallSide); + } landscapeProfile = builder.setSize(largeSide, smallSide).build(); portraitProfile = builder.setSize(smallSide, largeSide).build(); @@ -571,6 +576,10 @@ public class InvariantDeviceProfile { } public DeviceProfile getDeviceProfile(Context context) { + if (TestProtocol.sDebugTracing) { + Log.d(TestProtocol.LAUNCHER_NOT_TRANSPOSED, "getDeviceProfile: orientation=" + + context.getResources().getConfiguration().orientation, new Throwable()); + } return context.getResources().getConfiguration().orientation == Configuration.ORIENTATION_LANDSCAPE ? landscapeProfile : portraitProfile; } diff --git a/src/com/android/launcher3/Launcher.java b/src/com/android/launcher3/Launcher.java index 3236f5d542..30dd5481d2 100644 --- a/src/com/android/launcher3/Launcher.java +++ b/src/com/android/launcher3/Launcher.java @@ -566,7 +566,9 @@ public class Launcher extends StatefulActivity implements Launche } private void onIdpChanged(InvariantDeviceProfile idp) { - + if (TestProtocol.sDebugTracing) { + Log.d(TestProtocol.LAUNCHER_NOT_TRANSPOSED, "onIdpChanged", new Throwable()); + } initDeviceProfile(idp); dispatchDeviceProfileChanged(); reapplyUi(); diff --git a/src/com/android/launcher3/testing/TestProtocol.java b/src/com/android/launcher3/testing/TestProtocol.java index 18f1df18cb..3296ea51f6 100644 --- a/src/com/android/launcher3/testing/TestProtocol.java +++ b/src/com/android/launcher3/testing/TestProtocol.java @@ -109,6 +109,7 @@ public final class TestProtocol { public static final String REQUEST_MOCK_SENSOR_ROTATION = "mock-sensor-rotation"; public static final String PERMANENT_DIAG_TAG = "TaplTarget"; + public static final String LAUNCHER_NOT_TRANSPOSED = "b/185820525"; public static final String NO_SWIPE_TO_HOME = "b/158017601"; public static final String WORK_PROFILE_REMOVED = "b/159671700"; public static final String TIS_NO_EVENTS = "b/180915942"; diff --git a/tests/src/com/android/launcher3/ui/PortraitLandscapeRunner.java b/tests/src/com/android/launcher3/ui/PortraitLandscapeRunner.java index 266f0aeb1d..6c68daa8c1 100644 --- a/tests/src/com/android/launcher3/ui/PortraitLandscapeRunner.java +++ b/tests/src/com/android/launcher3/ui/PortraitLandscapeRunner.java @@ -4,6 +4,7 @@ import android.util.Log; import android.view.Surface; import com.android.launcher3.tapl.TestHelpers; +import com.android.launcher3.testing.TestProtocol; import org.junit.rules.TestRule; import org.junit.runner.Description; @@ -54,19 +55,23 @@ class PortraitLandscapeRunner implements TestRule { } private void evaluateInPortrait() throws Throwable { + Log.d(TestProtocol.LAUNCHER_NOT_TRANSPOSED, "evaluateInPortrait"); mTest.mDevice.setOrientationNatural(); mTest.mLauncher.setExpectedRotation(Surface.ROTATION_0); AbstractLauncherUiTest.checkDetectedLeaks(mTest.mLauncher); base.evaluate(); mTest.getDevice().pressHome(); + Log.d(TestProtocol.LAUNCHER_NOT_TRANSPOSED, "evaluateInPortrait finished"); } private void evaluateInLandscape() throws Throwable { + Log.d(TestProtocol.LAUNCHER_NOT_TRANSPOSED, "evaluateInLandscape"); mTest.mDevice.setOrientationLeft(); mTest.mLauncher.setExpectedRotation(Surface.ROTATION_90); AbstractLauncherUiTest.checkDetectedLeaks(mTest.mLauncher); base.evaluate(); mTest.getDevice().pressHome(); + Log.d(TestProtocol.LAUNCHER_NOT_TRANSPOSED, "evaluateInLandscape finished"); } }; } From 936c340405cea4e10e81d795ff821f07aaecd606 Mon Sep 17 00:00:00 2001 From: Bob Badour Date: Tue, 20 Apr 2021 14:02:30 -0700 Subject: [PATCH 13/25] [LSC] Add LOCAL_LICENSE_KINDS to packages/apps/Launcher3 Added SPDX-license-identifier-Apache-2.0 to: tests/dummy_app/Android.mk Bug: 68860345 Bug: 151177513 Bug: 151953481 Test: m all Exempt-From-Owner-Approval: janitorial work Change-Id: Iea957fe3cfc434246acfe19eb7917fbe22079cde --- tests/dummy_app/Android.mk | 3 +++ 1 file changed, 3 insertions(+) diff --git a/tests/dummy_app/Android.mk b/tests/dummy_app/Android.mk index f4ab582ebf..3472079d16 100644 --- a/tests/dummy_app/Android.mk +++ b/tests/dummy_app/Android.mk @@ -7,6 +7,9 @@ LOCAL_MODULE_TAGS := samples LOCAL_SRC_FILES := $(call all-java-files-under, src) LOCAL_PACKAGE_NAME := Aardwolf +LOCAL_LICENSE_KINDS := SPDX-license-identifier-Apache-2.0 +LOCAL_LICENSE_CONDITIONS := notice +LOCAL_NOTICE_FILE := $(LOCAL_PATH)/../../NOTICE LOCAL_SDK_VERSION := current From 8c8d99f966f8b62b6299c881cf0576f8d6f3bea3 Mon Sep 17 00:00:00 2001 From: Steven Ng Date: Tue, 20 Apr 2021 22:00:05 +0100 Subject: [PATCH 14/25] Fix flaky widget tapl tests Potential issues: 1. Widgets floating tips view is being shown 2. Header visible height is too small to be considered as a scroll gesture Test: Run AddConfigWidgetTest, AddWidgetTest, BindWidgetTest & RequestPinItemTest Bug: 185733371 Change-Id: Ic3e9188724dd920349ce8d8e8d98392b94b40642 --- .../launcher3/widget/picker/WidgetsFullSheet.java | 4 +++- tests/tapl/com/android/launcher3/tapl/Widgets.java | 9 +++++++-- 2 files changed, 10 insertions(+), 3 deletions(-) diff --git a/src/com/android/launcher3/widget/picker/WidgetsFullSheet.java b/src/com/android/launcher3/widget/picker/WidgetsFullSheet.java index 5543256897..5be9a955d9 100644 --- a/src/com/android/launcher3/widget/picker/WidgetsFullSheet.java +++ b/src/com/android/launcher3/widget/picker/WidgetsFullSheet.java @@ -50,6 +50,7 @@ import com.android.launcher3.Insettable; import com.android.launcher3.Launcher; import com.android.launcher3.LauncherAppState; import com.android.launcher3.R; +import com.android.launcher3.Utilities; import com.android.launcher3.anim.PendingAnimation; import com.android.launcher3.compat.AccessibilityManagerCompat; import com.android.launcher3.model.WidgetItem; @@ -649,7 +650,8 @@ public class WidgetsFullSheet extends BaseWidgetSheet } private boolean hasSeenEducationTip() { - return mLauncher.getSharedPrefs().getBoolean(WIDGETS_EDUCATION_TIP_SEEN, false); + return mLauncher.getSharedPrefs().getBoolean(WIDGETS_EDUCATION_TIP_SEEN, false) + || Utilities.IS_RUNNING_IN_TEST_HARNESS; } /** A holder class for holding adapters & their corresponding recycler view. */ diff --git a/tests/tapl/com/android/launcher3/tapl/Widgets.java b/tests/tapl/com/android/launcher3/tapl/Widgets.java index a3f9ade054..51e331de42 100644 --- a/tests/tapl/com/android/launcher3/tapl/Widgets.java +++ b/tests/tapl/com/android/launcher3/tapl/Widgets.java @@ -169,12 +169,16 @@ public final class Widgets extends LauncherInstrumentation.VisibleContainer { "widgets_table"); boolean hasHeaderExpanded = false; + int scrollDistance = 0; for (int i = 0; i < SCROLL_ATTEMPTS; i++) { UiObject2 fullWidgetsPicker = verifyActiveContainer(); UiObject2 header = mLauncher.waitForObjectInContainer(fullWidgetsPicker, headerSelector); - int headerHeight = header.getVisibleBounds().height(); + // If a header is barely visible in the bottom edge of the screen, its height could be + // too small for a scroll gesture. Since all header should have roughly the same height, + // let's pick the max height we have seen so far. + scrollDistance = Math.max(scrollDistance, header.getVisibleBounds().height()); // Look for a header that has the test app name. UiObject2 headerTitle = mLauncher.findObjectInContainer(fullWidgetsPicker, @@ -196,7 +200,8 @@ public final class Widgets extends LauncherInstrumentation.VisibleContainer { return widgetsContainer; } } - mLauncher.scrollDownByDistance(fullWidgetsPicker, headerHeight); + log("Finding test widget package - scroll with distance: " + scrollDistance); + mLauncher.scrollDownByDistance(fullWidgetsPicker, scrollDistance); } return null; From 0bba6a79fcad8cbe46b8cd625c9d6cc56279e27e Mon Sep 17 00:00:00 2001 From: Winson Chung Date: Tue, 20 Apr 2021 15:41:51 -0700 Subject: [PATCH 15/25] Reduce some logging from previous CL Bug: 185820525 Test: Presubmit Change-Id: I38a1da163eedf5f07bd507674ecb8661e8649d23 --- src/com/android/launcher3/InvariantDeviceProfile.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/com/android/launcher3/InvariantDeviceProfile.java b/src/com/android/launcher3/InvariantDeviceProfile.java index a863e6b55c..27e2995a28 100644 --- a/src/com/android/launcher3/InvariantDeviceProfile.java +++ b/src/com/android/launcher3/InvariantDeviceProfile.java @@ -578,7 +578,7 @@ public class InvariantDeviceProfile { public DeviceProfile getDeviceProfile(Context context) { if (TestProtocol.sDebugTracing) { Log.d(TestProtocol.LAUNCHER_NOT_TRANSPOSED, "getDeviceProfile: orientation=" - + context.getResources().getConfiguration().orientation, new Throwable()); + + context.getResources().getConfiguration().orientation); } return context.getResources().getConfiguration().orientation == Configuration.ORIENTATION_LANDSCAPE ? landscapeProfile : portraitProfile; From e1ce26e70cf522d7da046a9635d6d3a7e2a73056 Mon Sep 17 00:00:00 2001 From: Tracy Zhou Date: Thu, 15 Apr 2021 18:16:41 -0700 Subject: [PATCH 16/25] Fix weird task launch animation Sometimes a weird task launch animation can be observed where the task is animated to fullscreen before animated again from center to the left side of the screen. This is caused by stateManager.moveToRestState() call that internally animates FULLSCREEN_PROGRESS to 0 based on its launcher state (normal). The implementation right now finishes the recents animation after this call, instead of before. We should finish the recents animation first before doing the recents view clean up work. Fixes: 184878444 Test: manual Change-Id: Ib24fcf5ecb12e1a1357441427daface2778e1008 --- .../com/android/quickstep/TaskViewUtils.java | 14 ++++---- .../android/quickstep/views/RecentsView.java | 33 +++++-------------- .../com/android/quickstep/views/TaskView.java | 8 +++-- 3 files changed, 21 insertions(+), 34 deletions(-) diff --git a/quickstep/src/com/android/quickstep/TaskViewUtils.java b/quickstep/src/com/android/quickstep/TaskViewUtils.java index cbb2a66214..1db587285e 100644 --- a/quickstep/src/com/android/quickstep/TaskViewUtils.java +++ b/quickstep/src/com/android/quickstep/TaskViewUtils.java @@ -500,23 +500,25 @@ public final class TaskViewUtils { windowAnimEndListener = new AnimatorListenerAdapter() { @Override public void onAnimationEnd(Animator animation) { - recentsView.post(() -> { - stateManager.moveToRestState(); - stateManager.reapplyState(); + recentsView.finishRecentsAnimation(false /* toRecents */, () -> { + recentsView.post(() -> { + stateManager.moveToRestState(); + stateManager.reapplyState(); + }); }); } }; } else { AnimatorPlaybackController controller = - stateManager.createAnimationToNewWorkspace(NORMAL, - RECENTS_LAUNCH_DURATION); + stateManager.createAnimationToNewWorkspace(NORMAL, RECENTS_LAUNCH_DURATION); controller.dispatchOnStart(); childStateAnimation = controller.getTarget(); launcherAnim = controller.getAnimationPlayer().setDuration(RECENTS_LAUNCH_DURATION); windowAnimEndListener = new AnimatorListenerAdapter() { @Override public void onAnimationEnd(Animator animation) { - stateManager.goToState(NORMAL, false); + recentsView.finishRecentsAnimation(false /* toRecents */, + () -> stateManager.goToState(NORMAL, false)); } }; } diff --git a/quickstep/src/com/android/quickstep/views/RecentsView.java b/quickstep/src/com/android/quickstep/views/RecentsView.java index 4918036abc..150ae02cf0 100644 --- a/quickstep/src/com/android/quickstep/views/RecentsView.java +++ b/quickstep/src/com/android/quickstep/views/RecentsView.java @@ -137,7 +137,6 @@ import com.android.quickstep.TaskOverlayFactory; import com.android.quickstep.TaskThumbnailCache; import com.android.quickstep.TaskViewUtils; import com.android.quickstep.ViewUtils; -import com.android.quickstep.util.ActiveGestureLog; import com.android.quickstep.util.LayoutUtils; import com.android.quickstep.util.MultiValueUpdateListener; import com.android.quickstep.util.RecentsOrientedState; @@ -760,6 +759,12 @@ public abstract class RecentsView { + mRecentsAnimationController = null; if (onFinishComplete != null) { onFinishComplete.run(); } diff --git a/quickstep/src/com/android/quickstep/views/TaskView.java b/quickstep/src/com/android/quickstep/views/TaskView.java index 8f22622058..2bb14d2a0b 100644 --- a/quickstep/src/com/android/quickstep/views/TaskView.java +++ b/quickstep/src/com/android/quickstep/views/TaskView.java @@ -484,7 +484,6 @@ public class TaskView extends FrameLayout implements Reusable { mIsClickableAsLiveTile = false; RecentsView recentsView = getRecentsView(); RemoteAnimationTargets targets = recentsView.getLiveTileParams().getTargetSet(); - recentsView.getLiveTileTaskViewSimulator().setDrawsBelowRecents(false); AnimatorSet anim = new AnimatorSet(); TaskViewUtils.composeRecentsLaunchAnimator( @@ -493,10 +492,13 @@ public class TaskView extends FrameLayout implements Reusable { mActivity.getStateManager(), recentsView, recentsView.getDepthController()); anim.addListener(new AnimatorListenerAdapter() { + @Override + public void onAnimationStart(Animator animator) { + recentsView.getLiveTileTaskViewSimulator().setDrawsBelowRecents(false); + } + @Override public void onAnimationEnd(Animator animator) { - recentsView.getLiveTileTaskViewSimulator().setDrawsBelowRecents(true); - recentsView.finishRecentsAnimation(false, null); mIsClickableAsLiveTile = true; } }); From dc0f3978e7e1541a57da609260c42528da260b81 Mon Sep 17 00:00:00 2001 From: Winson Chung Date: Tue, 20 Apr 2021 18:18:51 -0700 Subject: [PATCH 17/25] Logging config changes as well Reduce some logging from previous CL Bug: 185820525 Test: Presubmit Change-Id: I69baed7b819b529db30a65cb39a80fb310d76243 --- src/com/android/launcher3/InvariantDeviceProfile.java | 3 +++ src/com/android/launcher3/Launcher.java | 9 +++++++-- src/com/android/launcher3/util/ConfigMonitor.java | 9 +++++++++ 3 files changed, 19 insertions(+), 2 deletions(-) diff --git a/src/com/android/launcher3/InvariantDeviceProfile.java b/src/com/android/launcher3/InvariantDeviceProfile.java index 27e2995a28..61023be019 100644 --- a/src/com/android/launcher3/InvariantDeviceProfile.java +++ b/src/com/android/launcher3/InvariantDeviceProfile.java @@ -394,6 +394,9 @@ public class InvariantDeviceProfile { } private void onConfigChanged(Context context) { + if (TestProtocol.sDebugTracing) { + Log.d(TestProtocol.LAUNCHER_NOT_TRANSPOSED, "IDP.onConfigChanged"); + } // Config changes, what shall we do? InvariantDeviceProfile oldProfile = new InvariantDeviceProfile(this); diff --git a/src/com/android/launcher3/Launcher.java b/src/com/android/launcher3/Launcher.java index 30dd5481d2..a54c791aff 100644 --- a/src/com/android/launcher3/Launcher.java +++ b/src/com/android/launcher3/Launcher.java @@ -551,11 +551,16 @@ public class Launcher extends StatefulActivity implements Launche @Override public void onConfigurationChanged(Configuration newConfig) { int diff = newConfig.diff(mOldConfig); - if ((diff & (CONFIG_ORIENTATION | CONFIG_SCREEN_SIZE)) != 0) { onIdpChanged(mDeviceProfile.inv); } + if (TestProtocol.sDebugTracing) { + Log.d(TestProtocol.LAUNCHER_NOT_TRANSPOSED, "onConfigurationChanged: diff=" + diff); + Log.d(TestProtocol.LAUNCHER_NOT_TRANSPOSED, "newConfig=" + newConfig); + Log.d(TestProtocol.LAUNCHER_NOT_TRANSPOSED, "oldConfig=" + mOldConfig); + } + mOldConfig.setTo(newConfig); super.onConfigurationChanged(newConfig); } @@ -567,7 +572,7 @@ public class Launcher extends StatefulActivity implements Launche private void onIdpChanged(InvariantDeviceProfile idp) { if (TestProtocol.sDebugTracing) { - Log.d(TestProtocol.LAUNCHER_NOT_TRANSPOSED, "onIdpChanged", new Throwable()); + Log.d(TestProtocol.LAUNCHER_NOT_TRANSPOSED, "onIdpChanged"); } initDeviceProfile(idp); dispatchDeviceProfileChanged(); diff --git a/src/com/android/launcher3/util/ConfigMonitor.java b/src/com/android/launcher3/util/ConfigMonitor.java index b3b69f6ab3..f7023e8f44 100644 --- a/src/com/android/launcher3/util/ConfigMonitor.java +++ b/src/com/android/launcher3/util/ConfigMonitor.java @@ -26,6 +26,7 @@ import android.content.res.Configuration; import android.graphics.Point; import android.util.Log; +import com.android.launcher3.testing.TestProtocol; import com.android.launcher3.util.DisplayController.DisplayInfoChangeListener; import com.android.launcher3.util.DisplayController.Info; @@ -72,6 +73,10 @@ public class ConfigMonitor extends BroadcastReceiver implements DisplayInfoChang // Listen for configuration change mContext.registerReceiver(this, new IntentFilter(Intent.ACTION_CONFIGURATION_CHANGED)); + if (TestProtocol.sDebugTracing) { + Log.d(TestProtocol.LAUNCHER_NOT_TRANSPOSED, "ConfigMonitor.register: this=" + + System.identityHashCode(this) + " callback=" + callback.getClass().getName()); + } } @Override @@ -113,6 +118,10 @@ public class ConfigMonitor extends BroadcastReceiver implements DisplayInfoChang } public void unregister() { + if (TestProtocol.sDebugTracing) { + Log.d(TestProtocol.LAUNCHER_NOT_TRANSPOSED, "ConfigMonitor.unregister: this=" + + System.identityHashCode(this)); + } try { mContext.unregisterReceiver(this); DisplayController.getDefaultDisplay(mContext).removeChangeListener(this); From 4fc242847436a83b2faaa5fecc0f07d6031780b7 Mon Sep 17 00:00:00 2001 From: Hyunyoung Song Date: Wed, 21 Apr 2021 00:30:54 -0700 Subject: [PATCH 18/25] Change spring effect on All Apps Bug: 185942188 Test: Manual Change-Id: Ic460d85e19074b7f2b2adf714b211591f0d23a08 --- .../android/launcher3/allapps/AllAppsContainerView.java | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/com/android/launcher3/allapps/AllAppsContainerView.java b/src/com/android/launcher3/allapps/AllAppsContainerView.java index 41865ce5e2..40f7ab167c 100644 --- a/src/com/android/launcher3/allapps/AllAppsContainerView.java +++ b/src/com/android/launcher3/allapps/AllAppsContainerView.java @@ -75,8 +75,9 @@ import com.android.launcher3.workprofile.PersonalWorkSlidingTabStrip.OnActivePag public class AllAppsContainerView extends SpringRelativeLayout implements DragSource, Insettable, OnDeviceProfileChangeListener, OnActivePageChangedListener { - private static final float FLING_VELOCITY_MULTIPLIER = 1000 * .2f; - // Starts the springs after at least 55% of the animation has passed. + private static final float FLING_VELOCITY_MULTIPLIER = 1800f; + + // Starts the springs after at least 25% of the animation has passed. private static final float FLING_ANIMATION_THRESHOLD = 0.25f; protected final BaseDraggingActivity mLauncher; @@ -610,7 +611,7 @@ public class AllAppsContainerView extends SpringRelativeLayout implements DragSo public void onAnimationUpdate(ValueAnimator valueAnimator) { if (shouldSpring && valueAnimator.getAnimatedFraction() >= FLING_ANIMATION_THRESHOLD) { - absorbSwipeUpVelocity(Math.abs( + absorbSwipeUpVelocity(-Math.abs( Math.round(velocity * FLING_VELOCITY_MULTIPLIER))); shouldSpring = false; } From 814728047beeb1f5dac4cbdfb2e9ee2f10922420 Mon Sep 17 00:00:00 2001 From: Bill Yi Date: Wed, 21 Apr 2021 08:49:29 +0000 Subject: [PATCH 19/25] Import translations. DO NOT MERGE ANYWHERE Auto-generated-cl: translation import Change-Id: I0c52edf741c9da39c882bc317258e63942ba0fd2 --- quickstep/res/values-or/strings.xml | 3 +-- quickstep/res/values-pt-rPT/strings.xml | 2 +- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/quickstep/res/values-or/strings.xml b/quickstep/res/values-or/strings.xml index 08c22fc80a..8c3697296f 100644 --- a/quickstep/res/values-or/strings.xml +++ b/quickstep/res/values-or/strings.xml @@ -78,8 +78,7 @@ "ସ୍କ୍ରିନସଟ୍" "ଆପ୍ କିମ୍ବା ଆପଣଙ୍କ ସଂସ୍ଥା ଦ୍ୱାରା ଏହି କାର୍ଯ୍ୟକୁ ଅନୁମତି ଦିଆଯାଇ ନାହିଁ" "ନାଭିଗେସନ୍ ଟ୍ୟୁଟୋରିଆଲକୁ ବାଦ୍ ଦେବେ?" - - + "ଆପଣ ପରେ ଏହାକୁ %1$s ଆପରେ ପାଇପାରିବେ" "ବାତିଲ୍ କରନ୍ତୁ" "ବାଦ୍ ଦିଅନ୍ତୁ" diff --git a/quickstep/res/values-pt-rPT/strings.xml b/quickstep/res/values-pt-rPT/strings.xml index bbc4ce8811..0feead77b1 100644 --- a/quickstep/res/values-pt-rPT/strings.xml +++ b/quickstep/res/values-pt-rPT/strings.xml @@ -30,7 +30,7 @@ "Resta(m) %1$s hoje." "Sugestões de apps" "Todas as apps" - "As suas aplicações previstas" + "As suas apps previstas" "Obtenha sugestões de apps na última fila do ecrã principal" "Obtenha sugestões de apps na fila dos favoritos do ecrã principal" "Aceda facilmente às suas apps mais utilizadas, diretamente no ecrã principal. As sugestões mudam em função das suas rotinas. As apps na última fila passam para o ecrã principal." From 8954828d68eb39c502c03a884ff70298217cf005 Mon Sep 17 00:00:00 2001 From: Bill Yi Date: Wed, 21 Apr 2021 08:50:07 +0000 Subject: [PATCH 20/25] Import translations. DO NOT MERGE ANYWHERE Auto-generated-cl: translation import Change-Id: I2f16395279d44a14cc82e54188978bfb8a1a9be7 --- res/values-ca/strings.xml | 2 +- res/values-km/strings.xml | 2 +- res/values-ne/strings.xml | 2 +- res/values-pt-rPT/strings.xml | 4 ++-- res/values-pt/strings.xml | 2 +- res/values-vi/strings.xml | 4 ++-- res/values-zh-rTW/strings.xml | 2 +- 7 files changed, 9 insertions(+), 9 deletions(-) diff --git a/res/values-ca/strings.xml b/res/values-ca/strings.xml index ac7c84b8f1..c49dce5219 100644 --- a/res/values-ca/strings.xml +++ b/res/values-ca/strings.xml @@ -109,7 +109,7 @@ "Per veure els punts de notificació, activa les notificacions de l\'aplicació %1$s" "Canvia la configuració" "Mostra els punts de notificació" - "Afegeix icones a la pantalla d\'inici" + "Afegeix icones d\'aplicacions a la pantalla d\'inici" "Per a les aplicacions noves" "Desconegut" "Suprimeix" diff --git a/res/values-km/strings.xml b/res/values-km/strings.xml index bc70a3d580..f460512a7f 100644 --- a/res/values-km/strings.xml +++ b/res/values-km/strings.xml @@ -124,7 +124,7 @@ "បញ្ចូលទៅអេក្រង់ដើម" "ផ្លាស់ធាតុមកទីនេះ" "ធាតុដែលត្រូវបានបន្ថែមទៅអេក្រង់ដើម" - "ធាតុដែលបានដកចេញ" + "បានដកធាតុចេញ" "ត្រឡប់វិញ" "ផ្លាស់ទីធាតុ" "ផ្លាស់ទីទៅជួរដេកទី %1$s ជួរឈរទី %2$s" diff --git a/res/values-ne/strings.xml b/res/values-ne/strings.xml index 6f2afc23e0..9c348e37f4 100644 --- a/res/values-ne/strings.xml +++ b/res/values-ne/strings.xml @@ -108,7 +108,7 @@ "शैली तथा वालपेपरहरू" "गृहपृष्ठका सेटिङहरू" "तपाईँको प्रशासकद्वारा असक्षम गरिएको" - "गृह स्क्रिनलाई घुम्ने अनुमति दिनुहोस्" + "गृह स्क्रिनलाई रोटेट हुन दिइयोस्" "फोनलाई घुमाइँदा" "सूचनाको प्रतीक जनाउने थोप्लाहरू" "सक्रिय" diff --git a/res/values-pt-rPT/strings.xml b/res/values-pt-rPT/strings.xml index 243f665b8e..fa2a50e8bc 100644 --- a/res/values-pt-rPT/strings.xml +++ b/res/values-pt-rPT/strings.xml @@ -97,7 +97,7 @@ "Pasta: %1$s, %2$d itens" "Pasta: %1$s, %2$d ou mais itens" "Imagens de fundo" - "Estilos e imagens de fundo" + "Estilos e fundo" "Definições de início" "Desativada pelo gestor" "Permitir rotação do ecrã principal" @@ -110,7 +110,7 @@ "Alterar definições" "Mostrar pontos de notificação" "Adic. ícones de apps ao ecrã principal" - "Para novas aplicações" + "Para novas apps" "Desconhecido" "Remover" "Pesquisar" diff --git a/res/values-pt/strings.xml b/res/values-pt/strings.xml index 22a041de3c..165a0133ec 100644 --- a/res/values-pt/strings.xml +++ b/res/values-pt/strings.xml @@ -98,7 +98,7 @@ "Pasta: %1$s, %2$d ou mais itens" "Planos de fundo" "Estilos e planos de fundo" - "Config. tela inicial" + "Configurações da tela inicial" "Desativado pelo administrador" "Permitir rotação da tela inicial" "Quando o smartphone for girado" diff --git a/res/values-vi/strings.xml b/res/values-vi/strings.xml index f7bef37440..318d453b95 100644 --- a/res/values-vi/strings.xml +++ b/res/values-vi/strings.xml @@ -108,7 +108,7 @@ "Cần quyền truy cập thông báo" "Để hiển thị Dấu chấm thông báo, hãy bật thông báo ứng dụng cho %1$s" "Thay đổi cài đặt" - "Hiển thị dấu chấm thông báo" + "Hiện dấu chấm thông báo" "Thêm biểu tượng ứng dụng vào Màn hình chính" "Cho ứng dụng mới" "Không xác định" @@ -125,7 +125,7 @@ "Di chuyển mục vào đây" "Đã thêm mục vào màn hình chính" "Đã xóa mục" - "Hoàn tác" + "Hủy" "Di chuyển mục" "Di chuyển đến hàng %1$s cột %2$s" "Di chuyển tới vị trí %1$s" diff --git a/res/values-zh-rTW/strings.xml b/res/values-zh-rTW/strings.xml index fd0ff0ecef..c6f933cdac 100644 --- a/res/values-zh-rTW/strings.xml +++ b/res/values-zh-rTW/strings.xml @@ -109,7 +109,7 @@ "如要顯示通知圓點,請開啟「%1$s」的應用程式通知功能" "變更設定" "顯示通知圓點" - "將應用程式圖示新增到主畫面" + "將應用程式圖示加到主畫面" "適用於新安裝的應用程式" "不明" "移除" From 260e98385e122afcbaa2e58a1299142e58ced89f Mon Sep 17 00:00:00 2001 From: Steven Ng Date: Wed, 21 Apr 2021 14:43:30 +0100 Subject: [PATCH 21/25] Use cellHeightPx to estimate recommended widgets' height Test: Set grid to 2x2 and open the widgets picker in portrait. Able to scroll the recycler view. Bug: 185915917 Change-Id: I02bb11a999fb1816de6e2410810c4ae6c1da137f --- .../widget/picker/WidgetsRecommendationTableLayout.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/com/android/launcher3/widget/picker/WidgetsRecommendationTableLayout.java b/src/com/android/launcher3/widget/picker/WidgetsRecommendationTableLayout.java index 824b5806f4..1aefe41f7b 100644 --- a/src/com/android/launcher3/widget/picker/WidgetsRecommendationTableLayout.java +++ b/src/com/android/launcher3/widget/picker/WidgetsRecommendationTableLayout.java @@ -146,7 +146,7 @@ public final class WidgetsRecommendationTableLayout extends TableLayout { List widgetItems = recommendedWidgetsInTable.get(i); float rowHeight = 0; for (int j = 0; j < widgetItems.size(); j++) { - float previewHeight = widgetItems.get(j).spanY * deviceProfile.allAppsCellHeightPx + float previewHeight = widgetItems.get(j).spanY * deviceProfile.cellHeightPx * previewScale; rowHeight = Math.max(rowHeight, previewHeight + mWidgetCellTextViewsHeight); } From 80732f89e74419d7f812d1e356f800cf93e93eac Mon Sep 17 00:00:00 2001 From: Alina Zaidi Date: Wed, 21 Apr 2021 15:21:30 +0100 Subject: [PATCH 22/25] Fix some widget picker recommended widgets bugs. - Bind recommended widgets only when not in search mode. (b/183503774) - Bind recommended widgets in onAttachedToWindow, Recommended widgets are available in PopupDataProvider at this point. (b/185461866) Bug: 183503774 Bug: 185461866 Test: tested manually Change-Id: If24e5b2b3e69a695821b5f7d9f42ff4c89ae62fc --- src/com/android/launcher3/widget/picker/WidgetsFullSheet.java | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/com/android/launcher3/widget/picker/WidgetsFullSheet.java b/src/com/android/launcher3/widget/picker/WidgetsFullSheet.java index 5be9a955d9..240958bc36 100644 --- a/src/com/android/launcher3/widget/picker/WidgetsFullSheet.java +++ b/src/com/android/launcher3/widget/picker/WidgetsFullSheet.java @@ -279,6 +279,7 @@ public class WidgetsFullSheet extends BaseWidgetSheet super.onAttachedToWindow(); mLauncher.getAppWidgetHost().addProviderChangeListener(this); notifyWidgetProvidersChanged(); + onRecommendedWidgetsBound(); } @Override @@ -416,6 +417,7 @@ public class WidgetsFullSheet extends BaseWidgetSheet @Override public void exitSearchMode() { + if (!mIsInSearchMode) return; onSearchResults(new ArrayList<>()); setViewVisibilityBasedOnSearch(/*isInSearchMode=*/ false); if (mHasWorkProfile) { @@ -464,7 +466,7 @@ public class WidgetsFullSheet extends BaseWidgetSheet mLauncher.getPopupDataProvider().getRecommendedWidgets(); WidgetsRecommendationTableLayout table = mSearchAndRecommendationViewHolder.mRecommendedWidgetsTable; - if (recommendedWidgets.size() > 0) { + if (!mIsInSearchMode && recommendedWidgets.size() > 0) { // TODO(b/185508758): Revert the following log after debugging. if (getHeaderViewHeight() == 0) { Log.d(TAG, "Header view height is 0 when inflating recommended widgets"); From e973d6f31fa6cba834ce4de4c323efb4756cdf37 Mon Sep 17 00:00:00 2001 From: Steven Ng Date: Tue, 20 Apr 2021 23:00:01 +0100 Subject: [PATCH 23/25] Render RemoteViews in LauncherAppWidgetHostView Test: Pin a conversation widget from a notification. RemoteViews are rendered with the default size. Drag-n-drop from the pin widget dialog works fine. Bug: 185934141 Change-Id: Idb76cce2807e55e7b42e2e044712519857beb202 --- .../launcher3/dragndrop/AddItemActivity.java | 29 ++++-- .../launcher3/widget/BaseWidgetSheet.java | 2 +- .../widget/PendingItemDragHelper.java | 26 +++-- .../android/launcher3/widget/WidgetCell.java | 99 ++++++------------- 4 files changed, 71 insertions(+), 85 deletions(-) diff --git a/src/com/android/launcher3/dragndrop/AddItemActivity.java b/src/com/android/launcher3/dragndrop/AddItemActivity.java index fc635a91db..d5a04a647d 100644 --- a/src/com/android/launcher3/dragndrop/AddItemActivity.java +++ b/src/com/android/launcher3/dragndrop/AddItemActivity.java @@ -59,6 +59,7 @@ import com.android.launcher3.pm.PinRequestHelper; import com.android.launcher3.views.BaseDragLayer; import com.android.launcher3.widget.LauncherAppWidgetHost; import com.android.launcher3.widget.LauncherAppWidgetProviderInfo; +import com.android.launcher3.widget.NavigableAppWidgetHostView; import com.android.launcher3.widget.PendingAddShortcutInfo; import com.android.launcher3.widget.PendingAddWidgetInfo; import com.android.launcher3.widget.WidgetCell; @@ -147,20 +148,31 @@ public class AddItemActivity extends BaseActivity implements OnLongClickListener public boolean onLongClick(View view) { // Find the position of the preview relative to the touch location. WidgetImageView img = mWidgetCell.getWidgetView(); + NavigableAppWidgetHostView appWidgetHostView = mWidgetCell.getAppWidgetHostViewPreview(); // If the ImageView doesn't have a drawable yet, the widget preview hasn't been loaded and // we abort the drag. - if (img.getDrawable() == null) { + if (img.getDrawable() == null && appWidgetHostView == null) { return false; } - Rect bounds = img.getBitmapBounds(); - bounds.offset(img.getLeft() - (int) mLastTouchPos.x, img.getTop() - (int) mLastTouchPos.y); - + final Rect bounds; // Start home and pass the draw request params - PinItemDragListener listener = new PinItemDragListener(mRequest, bounds, - img.getDrawable().getIntrinsicWidth(), img.getWidth()); - + final PinItemDragListener listener; + if (appWidgetHostView != null) { + bounds = new Rect(); + appWidgetHostView.getSourceVisualDragBounds(bounds); + bounds.offset(appWidgetHostView.getLeft() - (int) mLastTouchPos.x, + appWidgetHostView.getTop() - (int) mLastTouchPos.y); + listener = new PinItemDragListener(mRequest, bounds, + appWidgetHostView.getMeasuredWidth(), appWidgetHostView.getMeasuredWidth()); + } else { + bounds = img.getBitmapBounds(); + bounds.offset(img.getLeft() - (int) mLastTouchPos.x, + img.getTop() - (int) mLastTouchPos.y); + listener = new PinItemDragListener(mRequest, bounds, + img.getDrawable().getIntrinsicWidth(), img.getWidth()); + } // Start a system drag and drop. We use a transparent bitmap as preview for system drag // as the preview is handled internally by launcher. @@ -214,7 +226,7 @@ public class AddItemActivity extends BaseActivity implements OnLongClickListener // Cannot add widget return false; } - mWidgetCell.setPreview(PinItemDragListener.getPreview(mRequest)); + mWidgetCell.setRemoteViewsPreview(PinItemDragListener.getPreview(mRequest)); mAppWidgetManager = new WidgetManagerHelper(this); mAppWidgetHost = new LauncherAppWidgetHost(this); @@ -238,6 +250,7 @@ public class AddItemActivity extends BaseActivity implements OnLongClickListener @Override protected void onPostExecute(WidgetItem item) { + mWidgetCell.setPreviewSize(item.spanX, item.spanY); mWidgetCell.applyFromCellItem(item, mApp.getWidgetCache()); mWidgetCell.ensurePreview(); } diff --git a/src/com/android/launcher3/widget/BaseWidgetSheet.java b/src/com/android/launcher3/widget/BaseWidgetSheet.java index 95b887c4c6..415f48d30f 100644 --- a/src/com/android/launcher3/widget/BaseWidgetSheet.java +++ b/src/com/android/launcher3/widget/BaseWidgetSheet.java @@ -114,7 +114,7 @@ public abstract class BaseWidgetSheet extends AbstractSlideInView } PendingItemDragHelper dragHelper = new PendingItemDragHelper(v); - dragHelper.setRemoteViewsPreview(v.getPreview()); + dragHelper.setRemoteViewsPreview(v.getRemoteViewsPreview()); dragHelper.setAppWidgetHostViewPreview(v.getAppWidgetHostViewPreview()); if (image.getDrawable() != null) { diff --git a/src/com/android/launcher3/widget/PendingItemDragHelper.java b/src/com/android/launcher3/widget/PendingItemDragHelper.java index df368cd3e5..cea4de7b37 100644 --- a/src/com/android/launcher3/widget/PendingItemDragHelper.java +++ b/src/com/android/launcher3/widget/PendingItemDragHelper.java @@ -23,6 +23,7 @@ import android.graphics.Point; import android.graphics.Rect; import android.graphics.drawable.Drawable; import android.view.View; +import android.view.View.MeasureSpec; import android.widget.RemoteViews; import androidx.annotation.Nullable; @@ -53,7 +54,7 @@ public class PendingItemDragHelper extends DragPreviewProvider { private int[] mEstimatedCellSize; @Nullable private RemoteViews mRemoteViewsPreview; - @Nullable private LauncherAppWidgetHostView mAppWidgetHostViewPreview; + @Nullable private NavigableAppWidgetHostView mAppWidgetHostViewPreview; private final float mEnforcedRoundedCornersForWidget; public PendingItemDragHelper(View view) { @@ -71,9 +72,9 @@ public class PendingItemDragHelper extends DragPreviewProvider { mRemoteViewsPreview = remoteViewsPreview; } - /** Sets a {@link LauncherAppWidgetHostView} which shows a preview layout of an app widget. */ + /** Sets a {@link NavigableAppWidgetHostView} which shows a preview layout of an app widget. */ public void setAppWidgetHostViewPreview( - @Nullable LauncherAppWidgetHostView appWidgetHostViewPreview) { + @Nullable NavigableAppWidgetHostView appWidgetHostViewPreview) { mAppWidgetHostViewPreview = appWidgetHostViewPreview; } @@ -110,9 +111,22 @@ public class PendingItemDragHelper extends DragPreviewProvider { int[] previewSizeBeforeScale = new int[1]; if (mRemoteViewsPreview != null) { - preview = new FastBitmapDrawable( - WidgetCell.generateFromRemoteViews(launcher, mRemoteViewsPreview, - createWidgetInfo.info, maxWidth, previewSizeBeforeScale)); + mAppWidgetHostViewPreview = new LauncherAppWidgetHostView(launcher); + mAppWidgetHostViewPreview.setAppWidget(/* appWidgetId= */ -1, + ((PendingAddWidgetInfo) mAddInfo).info); + DeviceProfile deviceProfile = launcher.getDeviceProfile(); + Rect padding = new Rect(); + mAppWidgetHostViewPreview.getWidgetInset(deviceProfile, padding); + mAppWidgetHostViewPreview.setPadding(padding.left, padding.top, padding.right, + padding.bottom); + mAppWidgetHostViewPreview.updateAppWidget(/* remoteViews= */ mRemoteViewsPreview); + int width = + deviceProfile.cellWidthPx * mAddInfo.spanX + padding.left + padding.right; + int height = + deviceProfile.cellHeightPx * mAddInfo.spanY + padding.top + padding.bottom; + mAppWidgetHostViewPreview.measure( + MeasureSpec.makeMeasureSpec(width, MeasureSpec.EXACTLY), + MeasureSpec.makeMeasureSpec(height, MeasureSpec.EXACTLY)); } if (mAppWidgetHostViewPreview != null) { previewSizeBeforeScale[0] = mAppWidgetHostViewPreview.getMeasuredWidth(); diff --git a/src/com/android/launcher3/widget/WidgetCell.java b/src/com/android/launcher3/widget/WidgetCell.java index c08160bbef..3fcd3f7b03 100644 --- a/src/com/android/launcher3/widget/WidgetCell.java +++ b/src/com/android/launcher3/widget/WidgetCell.java @@ -46,7 +46,6 @@ import com.android.launcher3.DeviceProfile; import com.android.launcher3.R; import com.android.launcher3.WidgetPreviewLoader; import com.android.launcher3.icons.BaseIconFactory; -import com.android.launcher3.icons.BitmapRenderer; import com.android.launcher3.icons.FastBitmapDrawable; import com.android.launcher3.icons.RoundDrawableWrapper; import com.android.launcher3.model.WidgetItem; @@ -100,8 +99,8 @@ public class WidgetCell extends LinearLayout implements OnLayoutChangeListener { private final CheckLongPressHelper mLongPressHelper; private final float mEnforcedCornerRadius; - private RemoteViews mPreview; - private LauncherAppWidgetHostView mAppWidgetHostViewPreview; + private RemoteViews mRemoteViewsPreview; + private NavigableAppWidgetHostView mAppWidgetHostViewPreview; public WidgetCell(Context context) { this(context, null); @@ -143,12 +142,13 @@ public class WidgetCell extends LinearLayout implements OnLayoutChangeListener { mWidgetDescription = findViewById(R.id.widget_description); } - public void setPreview(RemoteViews view) { - mPreview = view; + public void setRemoteViewsPreview(RemoteViews view) { + mRemoteViewsPreview = view; } - public RemoteViews getPreview() { - return mPreview; + @Nullable + public RemoteViews getRemoteViewsPreview() { + return mRemoteViewsPreview; } /** @@ -172,7 +172,7 @@ public class WidgetCell extends LinearLayout implements OnLayoutChangeListener { mActiveRequest.cancel(); mActiveRequest = null; } - mPreview = null; + mRemoteViewsPreview = null; if (mAppWidgetHostViewPreview != null) { mWidgetImageContainer.removeView(mAppWidgetHostViewPreview); } @@ -180,7 +180,7 @@ public class WidgetCell extends LinearLayout implements OnLayoutChangeListener { } public void applyFromCellItem(WidgetItem item, WidgetPreviewLoader loader) { - applyPreviewLayout(item); + applyPreviewOnAppWidgetHostView(item); mItem = item; mWidgetName.setText(mItem.label); @@ -206,9 +206,26 @@ public class WidgetCell extends LinearLayout implements OnLayoutChangeListener { } } - private void applyPreviewLayout(WidgetItem item) { + + private void applyPreviewOnAppWidgetHostView(WidgetItem item) { + if (mRemoteViewsPreview != null) { + mAppWidgetHostViewPreview = new NavigableAppWidgetHostView(getContext()) { + @Override + protected boolean shouldAllowDirectClick() { + return false; + } + }; + mAppWidgetHostViewPreview.setAppWidget(/* appWidgetId= */ -1, item.widgetInfo); + Rect padding = new Rect(); + mAppWidgetHostViewPreview.getWidgetInset(mActivity.getDeviceProfile(), padding); + mAppWidgetHostViewPreview.setPadding(padding.left, padding.top, padding.right, + padding.bottom); + mAppWidgetHostViewPreview.updateAppWidget(/* remoteViews= */ mRemoteViewsPreview); + return; + } + if (ATLEAST_S - && mPreview == null + && mRemoteViewsPreview == null && item.widgetInfo != null && item.widgetInfo.previewLayout != Resources.ID_NULL) { mAppWidgetHostViewPreview = new LauncherAppWidgetHostView(getContext()); @@ -234,7 +251,7 @@ public class WidgetCell extends LinearLayout implements OnLayoutChangeListener { } @Nullable - public LauncherAppWidgetHostView getAppWidgetHostViewPreview() { + public NavigableAppWidgetHostView getAppWidgetHostViewPreview() { return mAppWidgetHostViewPreview; } @@ -303,15 +320,6 @@ public class WidgetCell extends LinearLayout implements OnLayoutChangeListener { } public void ensurePreview() { - if (mPreview != null && mActiveRequest == null) { - Bitmap preview = generateFromRemoteViews( - mActivity, mPreview, mItem.widgetInfo, mPresetPreviewSize, new int[1]); - if (preview != null) { - applyPreview(new FastBitmapDrawable(preview)); - return; - } - } - if (mAppWidgetHostViewPreview != null) { setContainerSize(mPreviewWidth, mPreviewHeight); FrameLayout.LayoutParams params = new FrameLayout.LayoutParams( @@ -385,53 +393,4 @@ public class WidgetCell extends LinearLayout implements OnLayoutChangeListener { super.onInitializeAccessibilityNodeInfo(info); info.removeAction(AccessibilityNodeInfo.AccessibilityAction.ACTION_CLICK); } - - /** - * Generates a bitmap by inflating {@param views}. - * @see com.android.launcher3.WidgetPreviewLoader#generateWidgetPreview - * - * TODO: Consider moving this to the background thread. - */ - public static Bitmap generateFromRemoteViews(BaseActivity activity, RemoteViews views, - LauncherAppWidgetProviderInfo info, int previewSize, int[] preScaledWidthOut) { - try { - return generateFromView(activity, views.apply(activity, new FrameLayout(activity)), - info, previewSize, preScaledWidthOut); - } catch (Exception e) { - return null; - } - } - - private static Bitmap generateFromView(BaseActivity activity, View v, - LauncherAppWidgetProviderInfo info, int previewSize, int[] preScaledWidthOut) { - - DeviceProfile dp = activity.getDeviceProfile(); - int viewWidth = dp.cellWidthPx * info.spanX; - int viewHeight = dp.cellHeightPx * info.spanY; - - v.measure(MeasureSpec.makeMeasureSpec(viewWidth, MeasureSpec.EXACTLY), - MeasureSpec.makeMeasureSpec(viewHeight, MeasureSpec.EXACTLY)); - - viewWidth = v.getMeasuredWidth(); - viewHeight = v.getMeasuredHeight(); - v.layout(0, 0, viewWidth, viewHeight); - - preScaledWidthOut[0] = viewWidth; - final int bitmapWidth, bitmapHeight; - final float scale; - if (viewWidth > previewSize) { - scale = ((float) previewSize) / viewWidth; - bitmapWidth = previewSize; - bitmapHeight = (int) (viewHeight * scale); - } else { - scale = 1; - bitmapWidth = viewWidth; - bitmapHeight = viewHeight; - } - - return BitmapRenderer.createSoftwareBitmap(bitmapWidth, bitmapHeight, c -> { - c.scale(scale, scale); - v.draw(c); - }); - } } From e74ea9ec9a098f3272a80b6c79d32d1b7b0e0821 Mon Sep 17 00:00:00 2001 From: Alex Chau Date: Wed, 21 Apr 2021 14:32:20 +0100 Subject: [PATCH 24/25] Adding new team members working on the launcher Test: N/A Change-Id: I446f3f1ed651bdd2b6ccd22a05d99ab39709262d --- OWNERS | 3 +++ 1 file changed, 3 insertions(+) diff --git a/OWNERS b/OWNERS index 381e5e93fd..21adf60f88 100644 --- a/OWNERS +++ b/OWNERS @@ -4,6 +4,9 @@ # People who can approve changes for submission # +alexchau@google.com +andraskloczl@google.com +patmanning@google.com petrcermak@google.com pbdr@google.com kideckel@google.com From 9d5ee199528b7b74640c2c6e03914f3e515b089f Mon Sep 17 00:00:00 2001 From: Tracy Zhou Date: Tue, 20 Apr 2021 23:07:31 -0700 Subject: [PATCH 25/25] Finish recents animation upon home rotation Fixes: 184054813 Test: manual Change-Id: Iba819ad1d7ea72aedd15b98d9a9a48c384d5fe1e --- .../src/com/android/quickstep/views/RecentsView.java | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/quickstep/src/com/android/quickstep/views/RecentsView.java b/quickstep/src/com/android/quickstep/views/RecentsView.java index 150ae02cf0..e4fa1aa831 100644 --- a/quickstep/src/com/android/quickstep/views/RecentsView.java +++ b/quickstep/src/com/android/quickstep/views/RecentsView.java @@ -2340,6 +2340,15 @@ public abstract class RecentsView finishRecentsAnimation(true, this::onConfigurationChangedInternal)); + } else { + onConfigurationChangedInternal(); + } + } + + private void onConfigurationChangedInternal() { final int rotation = mActivity.getDisplay().getRotation(); if (mOrientationState.setRecentsRotation(rotation)) { updateOrientationHandler();