diff --git a/packages/SystemUI/res/drawable/action_chip_background.xml b/packages/SystemUI/res/drawable/action_chip_background.xml index 0e1453c42e80f..eeff39b7a8fdf 100644 --- a/packages/SystemUI/res/drawable/action_chip_background.xml +++ b/packages/SystemUI/res/drawable/action_chip_background.xml @@ -17,7 +17,7 @@ + android:color="@color/screenshot_button_ripple"> diff --git a/packages/SystemUI/res/drawable/screenshot_actions_background_protection.xml b/packages/SystemUI/res/drawable/screenshot_actions_background_protection.xml index 21013c6c7b164..dd818a068d61a 100644 --- a/packages/SystemUI/res/drawable/screenshot_actions_background_protection.xml +++ b/packages/SystemUI/res/drawable/screenshot_actions_background_protection.xml @@ -17,6 +17,6 @@ \ No newline at end of file diff --git a/packages/SystemUI/res/layout/global_screenshot_legacy.xml b/packages/SystemUI/res/layout/global_screenshot_legacy.xml deleted file mode 100644 index 791c7ea875fe4..0000000000000 --- a/packages/SystemUI/res/layout/global_screenshot_legacy.xml +++ /dev/null @@ -1,42 +0,0 @@ - - - - - - - - diff --git a/packages/SystemUI/res/layout/global_screenshot.xml b/packages/SystemUI/res/layout/screenshot.xml similarity index 86% rename from packages/SystemUI/res/layout/global_screenshot.xml rename to packages/SystemUI/res/layout/screenshot.xml index c92b10c447b17..7c0ee665755ae 100644 --- a/packages/SystemUI/res/layout/global_screenshot.xml +++ b/packages/SystemUI/res/layout/screenshot.xml @@ -16,7 +16,7 @@ --> - + diff --git a/packages/SystemUI/res/layout/global_screenshot_action_chip.xml b/packages/SystemUI/res/layout/screenshot_action_chip.xml similarity index 97% rename from packages/SystemUI/res/layout/global_screenshot_action_chip.xml rename to packages/SystemUI/res/layout/screenshot_action_chip.xml index aeae722c4ed4f..b80469febf3cf 100644 --- a/packages/SystemUI/res/layout/global_screenshot_action_chip.xml +++ b/packages/SystemUI/res/layout/screenshot_action_chip.xml @@ -16,7 +16,7 @@ --> + app:layout_constraintTop_toTopOf="@+id/screenshot_actions_container" + app:layout_constraintEnd_toEndOf="@+id/screenshot_actions_container"/> - - - + app:constraint_referenced_ids="screenshot_preview"/> + app:constraint_referenced_ids="screenshot_preview"/> + app:layout_constraintBottom_toBottomOf="@+id/screenshot_preview_border" + app:layout_constraintStart_toStartOf="@+id/screenshot_preview_border" + app:layout_constraintEnd_toEndOf="@+id/screenshot_preview_border" + app:layout_constraintTop_toTopOf="@+id/screenshot_preview_border"> + app:layout_constraintStart_toStartOf="@id/screenshot_preview" + app:layout_constraintTop_toTopOf="@id/screenshot_preview" + app:layout_constraintEnd_toEndOf="@id/screenshot_preview" + app:layout_constraintBottom_toBottomOf="@id/screenshot_preview"/> diff --git a/packages/SystemUI/res/values-night/colors.xml b/packages/SystemUI/res/values-night/colors.xml index b98694e2fae73..e7a158e0ce306 100644 --- a/packages/SystemUI/res/values-night/colors.xml +++ b/packages/SystemUI/res/values-night/colors.xml @@ -59,14 +59,8 @@ @color/GM2_red_300 - @color/GM2_grey_800 - #42FFFFFF - #FFFFFF - @color/GM2_grey_600 - @color/GM2_blue_300 - @color/GM2_grey_800 - #FFFFFF - #80000000 + #42FFFFFF + #80000000 #85ffffff diff --git a/packages/SystemUI/res/values/colors.xml b/packages/SystemUI/res/values/colors.xml index 08778bf14c668..4b606bcf2e73e 100644 --- a/packages/SystemUI/res/values/colors.xml +++ b/packages/SystemUI/res/values/colors.xml @@ -196,8 +196,8 @@ #ffffffff - #1f000000 - #40000000 + #1f000000 + #40000000 #F8F9FA diff --git a/packages/SystemUI/res/values/dimens.xml b/packages/SystemUI/res/values/dimens.xml index 182c9b7113fab..c8f3aedf81194 100644 --- a/packages/SystemUI/res/values/dimens.xml +++ b/packages/SystemUI/res/values/dimens.xml @@ -322,10 +322,7 @@ - 20dp - 20dp - 400dp - 80dp + 80dp 242dp 4dp 8dp diff --git a/packages/SystemUI/src/com/android/systemui/screenshot/SaveImageInBackgroundTask.java b/packages/SystemUI/src/com/android/systemui/screenshot/SaveImageInBackgroundTask.java index e9dea65c2078d..04f33c1f9a91f 100644 --- a/packages/SystemUI/src/com/android/systemui/screenshot/SaveImageInBackgroundTask.java +++ b/packages/SystemUI/src/com/android/systemui/screenshot/SaveImageInBackgroundTask.java @@ -378,8 +378,7 @@ class SaveImageInBackgroundTask extends AsyncTask { List actions, Context context) { List broadcastActions = new ArrayList<>(); for (Notification.Action action : actions) { - // Proxy smart actions through {@link GlobalScreenshot.SmartActionsReceiver} - // for logging smart actions. + // Proxy smart actions through {@link SmartActionsReceiver} for logging smart actions. Bundle extras = action.getExtras(); String actionType = extras.getString( ScreenshotNotificationSmartActionsProvider.ACTION_TYPE, @@ -433,8 +432,7 @@ class SaveImageInBackgroundTask extends AsyncTask { context, 0, sharingIntent, PendingIntent.FLAG_CANCEL_CURRENT | PendingIntent.FLAG_IMMUTABLE); - // Proxy smart actions through {@link GlobalScreenshot.SmartActionsReceiver} - // for logging smart actions. + // Proxy smart actions through {@link SmartActionsReceiver} for logging smart actions. Bundle extras = action.getExtras(); String actionType = extras.getString( ScreenshotNotificationSmartActionsProvider.ACTION_TYPE, diff --git a/packages/SystemUI/src/com/android/systemui/screenshot/ScreenshotController.java b/packages/SystemUI/src/com/android/systemui/screenshot/ScreenshotController.java index 8def475c192c0..c8a97e9558335 100644 --- a/packages/SystemUI/src/com/android/systemui/screenshot/ScreenshotController.java +++ b/packages/SystemUI/src/com/android/systemui/screenshot/ScreenshotController.java @@ -452,7 +452,7 @@ public class ScreenshotController { // Inflate the screenshot layout mScreenshotView = (ScreenshotView) - LayoutInflater.from(mContext).inflate(R.layout.global_screenshot, null); + LayoutInflater.from(mContext).inflate(R.layout.screenshot, null); mScreenshotView.init(mUiEventLogger, new ScreenshotView.ScreenshotViewCallback() { @Override public void onUserInteraction() { diff --git a/packages/SystemUI/src/com/android/systemui/screenshot/ScreenshotView.java b/packages/SystemUI/src/com/android/systemui/screenshot/ScreenshotView.java index dfb39e3004504..01dc0ca047006 100644 --- a/packages/SystemUI/src/com/android/systemui/screenshot/ScreenshotView.java +++ b/packages/SystemUI/src/com/android/systemui/screenshot/ScreenshotView.java @@ -193,7 +193,7 @@ public class ScreenshotView extends FrameLayout implements super(context, attrs, defStyleAttr, defStyleRes); mResources = mContext.getResources(); - mCornerSizeX = mResources.getDimensionPixelSize(R.dimen.global_screenshot_x_scale); + mCornerSizeX = mResources.getDimensionPixelSize(R.dimen.screenshot_x_scale); mDismissDeltaY = mResources.getDimensionPixelSize( R.dimen.screenshot_dismissal_height_delta); @@ -339,23 +339,23 @@ public class ScreenshotView extends FrameLayout implements @Override // View protected void onFinishInflate() { mScrollingScrim = requireNonNull(findViewById(R.id.screenshot_scrolling_scrim)); - mScreenshotStatic = requireNonNull(findViewById(R.id.global_screenshot_static)); - mScreenshotPreview = requireNonNull(findViewById(R.id.global_screenshot_preview)); + mScreenshotStatic = requireNonNull(findViewById(R.id.screenshot_static)); + mScreenshotPreview = requireNonNull(findViewById(R.id.screenshot_preview)); mTransitionView = requireNonNull(findViewById(R.id.screenshot_transition_view)); mScreenshotPreviewBorder = requireNonNull( - findViewById(R.id.global_screenshot_preview_border)); + findViewById(R.id.screenshot_preview_border)); mScreenshotPreview.setClipToOutline(true); mActionsContainerBackground = requireNonNull(findViewById( - R.id.global_screenshot_actions_container_background)); - mActionsContainer = requireNonNull(findViewById(R.id.global_screenshot_actions_container)); - mActionsView = requireNonNull(findViewById(R.id.global_screenshot_actions)); + R.id.screenshot_actions_container_background)); + mActionsContainer = requireNonNull(findViewById(R.id.screenshot_actions_container)); + mActionsView = requireNonNull(findViewById(R.id.screenshot_actions)); mBackgroundProtection = requireNonNull( - findViewById(R.id.global_screenshot_actions_background)); - mDismissButton = requireNonNull(findViewById(R.id.global_screenshot_dismiss_button)); + findViewById(R.id.screenshot_actions_background)); + mDismissButton = requireNonNull(findViewById(R.id.screenshot_dismiss_button)); mScrollablePreview = requireNonNull(findViewById(R.id.screenshot_scrollable_preview)); - mScreenshotFlash = requireNonNull(findViewById(R.id.global_screenshot_flash)); - mScreenshotSelectorView = requireNonNull(findViewById(R.id.global_screenshot_selector)); + mScreenshotFlash = requireNonNull(findViewById(R.id.screenshot_flash)); + mScreenshotSelectorView = requireNonNull(findViewById(R.id.screenshot_selector)); mShareChip = requireNonNull(mActionsContainer.findViewById(R.id.screenshot_share_chip)); mEditChip = requireNonNull(mActionsContainer.findViewById(R.id.screenshot_edit_chip)); mScrollChip = requireNonNull(mActionsContainer.findViewById(R.id.screenshot_scroll_chip)); @@ -452,7 +452,7 @@ public class ScreenshotView extends FrameLayout implements mOrientationPortrait = (orientation == ORIENTATION_PORTRAIT); updateInsets(insets); int screenshotFixedSize = - mContext.getResources().getDimensionPixelSize(R.dimen.global_screenshot_x_scale); + mContext.getResources().getDimensionPixelSize(R.dimen.screenshot_x_scale); ViewGroup.LayoutParams params = mScreenshotPreview.getLayoutParams(); if (mOrientationPortrait) { params.width = screenshotFixedSize; @@ -748,7 +748,7 @@ public class ScreenshotView extends FrameLayout implements for (Notification.Action smartAction : imageData.smartActions) { ScreenshotActionChip actionChip = (ScreenshotActionChip) inflater.inflate( - R.layout.global_screenshot_action_chip, mActionsView, false); + R.layout.screenshot_action_chip, mActionsView, false); actionChip.setText(smartAction.title); actionChip.setIcon(smartAction.getIcon(), false); actionChip.setPendingIntent(smartAction.actionIntent, @@ -767,7 +767,7 @@ public class ScreenshotView extends FrameLayout implements if (mPendingInteraction == null) { LayoutInflater inflater = LayoutInflater.from(mContext); mQuickShareChip = (ScreenshotActionChip) inflater.inflate( - R.layout.global_screenshot_action_chip, mActionsView, false); + R.layout.screenshot_action_chip, mActionsView, false); mQuickShareChip.setText(quickShareAction.title); mQuickShareChip.setIcon(quickShareAction.getIcon(), false); mQuickShareChip.setOnClickListener(v -> {