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

Commit 0fda8bb2 authored by TreeHugger Robot's avatar TreeHugger Robot Committed by Android (Google) Code Review
Browse files

Merge "App Pinning strings; security notes on startup dialog." into rvc-dev

parents dcc609a1 cc4f6f24
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -907,6 +907,8 @@
    <dimen name="screen_pinning_nav_highlight_size">56dp</dimen>
    <!-- Screen pinning inner nav bar outer circle size -->
    <dimen name="screen_pinning_nav_highlight_outer_size">84dp</dimen>
    <!-- Screen pinning description bullet gap width -->
    <dimen name="screen_pinning_description_bullet_gap_width">6sp</dimen>

    <!-- Padding to be used on the bottom of the fingerprint icon on Keyguard so it better aligns
         with the other icons. -->
+10 −6
Original line number Diff line number Diff line
@@ -1522,7 +1522,7 @@
    <string name="accessibility_output_chooser">Switch output device</string>

    <!-- Screen pinning dialog title. -->
    <string name="screen_pinning_title">Screen is pinned</string>
    <string name="screen_pinning_title">App is pinned</string>
    <!-- Screen pinning dialog description. -->
    <string name="screen_pinning_description">This keeps it in view until you unpin. Touch &amp; hold Back and Overview to unpin.</string>
    <string name="screen_pinning_description_recents_invisible">This keeps it in view until you unpin. Touch &amp; hold Back and Home to unpin.</string>
@@ -1530,20 +1530,24 @@
    <!-- Screen pinning dialog description. -->
    <string name="screen_pinning_description_accessible">This keeps it in view until you unpin. Touch &amp; hold Overview to unpin.</string>
    <string name="screen_pinning_description_recents_invisible_accessible">This keeps it in view until you unpin. Touch &amp; hold Home to unpin.</string>
    <!-- Screen pinning security warning: personal data, email, contacts may be exposed while screen is pinned. [CHAR LIMIT=NONE] -->
    <string name="screen_pinning_exposes_personal_data">Personal data may be accessible (such as contacts and email content).</string>
    <!-- Screen pinning security warning: a pinned app can still launch other apps. [CHAR LIMIT=NONE] -->
    <string name="screen_pinning_can_open_other_apps">Pinned app may open other apps.</string>
    <!-- Notify use that they are in Lock-to-app -->
    <string name="screen_pinning_toast">To unpin this screen, touch &amp; hold Back and Overview
    <string name="screen_pinning_toast">To unpin this app, touch &amp; hold Back and Overview
        buttons</string>
    <string name="screen_pinning_toast_recents_invisible">To unpin this screen, touch &amp; hold Back
    <string name="screen_pinning_toast_recents_invisible">To unpin this app, touch &amp; hold Back
        and Home buttons</string>
    <!-- Notify (in toast) user how to unpin screen in gesture navigation mode [CHAR LIMIT=NONE] -->
    <string name="screen_pinning_toast_gesture_nav">To unpin this screen, swipe up &amp; hold</string>
    <string name="screen_pinning_toast_gesture_nav">To unpin this app, swipe up &amp; hold</string>
    <!-- Screen pinning positive response. -->
    <string name="screen_pinning_positive">Got it</string>
    <!-- Screen pinning negative response. -->
    <string name="screen_pinning_negative">No thanks</string>
    <!-- Enter/Exiting screen pinning indication. -->
    <string name="screen_pinning_start">Screen pinned</string>
    <string name="screen_pinning_exit">Screen unpinned</string>
    <string name="screen_pinning_start">App pinned</string>
    <string name="screen_pinning_exit">App unpinned</string>


    <!-- Hide quick settings tile confirmation title -->
+16 −2
Original line number Diff line number Diff line
@@ -31,6 +31,8 @@ import android.graphics.PixelFormat;
import android.graphics.drawable.ColorDrawable;
import android.os.Binder;
import android.os.RemoteException;
import android.text.SpannableStringBuilder;
import android.text.style.BulletSpan;
import android.util.DisplayMetrics;
import android.view.Gravity;
import android.view.View;
@@ -293,8 +295,20 @@ public class ScreenPinningRequest implements View.OnClickListener,
                        .setImageDrawable(navigationBarView.getHomeDrawable());
            }

            ((TextView) mLayout.findViewById(R.id.screen_pinning_description))
                    .setText(descriptionStringResId);
            // Create a bulleted list of the default description plus the two security notes.
            int gapWidth = getResources().getDimensionPixelSize(
                    R.dimen.screen_pinning_description_bullet_gap_width);
            SpannableStringBuilder description = new SpannableStringBuilder();
            description.append(getContext().getText(descriptionStringResId),
                    new BulletSpan(gapWidth), /* flags */ 0);
            description.append(System.lineSeparator());
            description.append(getContext().getText(R.string.screen_pinning_exposes_personal_data),
                    new BulletSpan(gapWidth), /* flags */ 0);
            description.append(System.lineSeparator());
            description.append(getContext().getText(R.string.screen_pinning_can_open_other_apps),
                    new BulletSpan(gapWidth), /* flags */ 0);
            ((TextView) mLayout.findViewById(R.id.screen_pinning_description)).setText(description);

            final int backBgVisibility = touchExplorationEnabled ? View.INVISIBLE : View.VISIBLE;
            mLayout.findViewById(R.id.screen_pinning_back_bg).setVisibility(backBgVisibility);
            mLayout.findViewById(R.id.screen_pinning_back_bg_light).setVisibility(backBgVisibility);