[DO NOT MERGE] Update QuickStepContract.getWindowCornerRadius API
Update from getWindowCornerRadius(Resources) to getWindowCornerRadius(Context) Bug: 131221697 Test: make Change-Id: Ia5f10e9292e205dab7e69d97dfc82d17690816fb
This commit is contained in:
@@ -682,7 +682,7 @@ public class QuickstepTransitionManager implements OnDeviceProfileChangeListener
|
||||
? Math.max(crop.width(), crop.height()) / 2f
|
||||
: 0f;
|
||||
final float finalWindowRadius = mDeviceProfile.isMultiWindowMode
|
||||
? 0 : getWindowCornerRadius(mLauncher.getResources());
|
||||
? 0 : getWindowCornerRadius(mLauncher);
|
||||
final float finalShadowRadius = appTargetsAreTranslucent ? 0 : mMaxShadowRadius;
|
||||
|
||||
MultiValueUpdateListener listener = new MultiValueUpdateListener() {
|
||||
@@ -871,7 +871,7 @@ public class QuickstepTransitionManager implements OnDeviceProfileChangeListener
|
||||
}
|
||||
|
||||
final float finalWindowRadius = mDeviceProfile.isMultiWindowMode
|
||||
? 0 : getWindowCornerRadius(mLauncher.getResources());
|
||||
? 0 : getWindowCornerRadius(mLauncher);
|
||||
final FloatingWidgetView floatingView = FloatingWidgetView.getFloatingWidgetView(mLauncher,
|
||||
v, widgetBackgroundBounds,
|
||||
new Size(windowTargetBounds.width(), windowTargetBounds.height()),
|
||||
@@ -1151,7 +1151,7 @@ public class QuickstepTransitionManager implements OnDeviceProfileChangeListener
|
||||
ValueAnimator unlockAnimator = ValueAnimator.ofFloat(0, 1);
|
||||
unlockAnimator.setDuration(CLOSING_TRANSITION_DURATION_MS);
|
||||
float cornerRadius = mDeviceProfile.isMultiWindowMode ? 0 :
|
||||
QuickStepContract.getWindowCornerRadius(mLauncher.getResources());
|
||||
QuickStepContract.getWindowCornerRadius(mLauncher);
|
||||
unlockAnimator.addListener(new AnimatorListenerAdapter() {
|
||||
@Override
|
||||
public void onAnimationStart(Animator animation) {
|
||||
@@ -1193,7 +1193,7 @@ public class QuickstepTransitionManager implements OnDeviceProfileChangeListener
|
||||
ValueAnimator closingAnimator = ValueAnimator.ofFloat(0, 1);
|
||||
int duration = CLOSING_TRANSITION_DURATION_MS;
|
||||
float windowCornerRadius = mDeviceProfile.isMultiWindowMode
|
||||
? 0 : getWindowCornerRadius(mLauncher.getResources());
|
||||
? 0 : getWindowCornerRadius(mLauncher);
|
||||
float startShadowRadius = areAllTargetsTranslucent(appTargets) ? 0 : mMaxShadowRadius;
|
||||
closingAnimator.setDuration(duration);
|
||||
closingAnimator.addUpdateListener(new MultiValueUpdateListener() {
|
||||
|
||||
@@ -25,7 +25,6 @@ import static com.android.quickstep.SysUINavigationMode.Mode.THREE_BUTTONS;
|
||||
|
||||
import android.content.Context;
|
||||
import android.content.res.Resources;
|
||||
import android.util.Log;
|
||||
import android.view.MotionEvent;
|
||||
import android.view.OrientationEventListener;
|
||||
|
||||
@@ -35,7 +34,6 @@ import com.android.launcher3.util.DisplayController.DisplayInfoChangeListener;
|
||||
import com.android.launcher3.util.DisplayController.Info;
|
||||
import com.android.launcher3.util.MainThreadInitializedObject;
|
||||
import com.android.quickstep.util.RecentsOrientedState;
|
||||
import com.android.systemui.shared.system.ActivityManagerWrapper;
|
||||
import com.android.systemui.shared.system.QuickStepContract;
|
||||
import com.android.systemui.shared.system.TaskStackChangeListener;
|
||||
import com.android.systemui.shared.system.TaskStackChangeListeners;
|
||||
@@ -149,7 +147,7 @@ public class RotationTouchHelper implements
|
||||
mDisplayId = mDisplayController.getInfo().id;
|
||||
|
||||
mOrientationTouchTransformer = new OrientationTouchTransformer(resources, mMode,
|
||||
() -> QuickStepContract.getWindowCornerRadius(resources));
|
||||
() -> QuickStepContract.getWindowCornerRadius(mContext));
|
||||
|
||||
// Register for navigation mode changes
|
||||
SysUINavigationMode.Mode newMode = mSysUiNavMode.addModeChangeListener(this);
|
||||
|
||||
@@ -120,7 +120,7 @@ public class NavBarGestureHandler implements OnTouchListener,
|
||||
mAssistantGestureDetector = new GestureDetector(context, new AssistantGestureListener());
|
||||
int assistantWidth = resources.getDimensionPixelSize(R.dimen.gestures_assistant_width);
|
||||
final float assistantHeight = Math.max(mBottomGestureHeight,
|
||||
QuickStepContract.getWindowCornerRadius(resources));
|
||||
QuickStepContract.getWindowCornerRadius(context));
|
||||
mAssistantLeftRegion.bottom = mAssistantRightRegion.bottom = mDisplaySize.y;
|
||||
mAssistantLeftRegion.top = mAssistantRightRegion.top = mDisplaySize.y - assistantHeight;
|
||||
mAssistantLeftRegion.left = 0;
|
||||
|
||||
@@ -1520,7 +1520,7 @@ public class TaskView extends FrameLayout implements Reusable {
|
||||
|
||||
public FullscreenDrawParams(Context context) {
|
||||
mCornerRadius = TaskCornerRadius.get(context);
|
||||
mWindowCornerRadius = QuickStepContract.getWindowCornerRadius(context.getResources());
|
||||
mWindowCornerRadius = QuickStepContract.getWindowCornerRadius(context);
|
||||
|
||||
mCurrentDrawnCornerRadius = mCornerRadius;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user