mirror of
https://github.com/streetwriters/notesnook.git
synced 2026-08-29 10:09:26 +02:00
mobile: keep note and reminder content off the lock screen
From Android 16 QPR1 widgets are lock screen eligible by default, so the note widget (title + preview text) and the reminders widget (titles and descriptions) could render user content on a locked device. Adds res/xml-v36 overrides declaring not_keyguard for both. The new note widget is left eligible - it is only a button and leaks nothing.
This commit is contained in:
@@ -0,0 +1,22 @@
|
||||
<?xml version="1.0" encoding="utf-8"?><!--
|
||||
Keep this in sync with res/xml/note_widget_info.xml. It exists only to add not_keyguard: from
|
||||
Android 16 QPR1 widgets are lock screen eligible by default, and this one renders the note's
|
||||
title and preview text, which should not be readable on a locked device.
|
||||
-->
|
||||
<appwidget-provider xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:initialKeyguardLayout="@layout/note_widget"
|
||||
android:initialLayout="@layout/note_widget"
|
||||
android:configure="com.streetwriters.notesnook.NotePreviewConfigureActivity"
|
||||
android:widgetFeatures="reconfigurable"
|
||||
android:minResizeWidth="100dp"
|
||||
android:minResizeHeight="50dp"
|
||||
android:minWidth="400dp"
|
||||
android:description="@string/note_description"
|
||||
android:minHeight="50dp"
|
||||
android:targetCellWidth="5"
|
||||
android:targetCellHeight="1"
|
||||
android:previewImage="@drawable/note_widget_preview"
|
||||
android:previewLayout="@layout/note_widget_preview"
|
||||
android:resizeMode="horizontal|vertical"
|
||||
android:updatePeriodMillis="86400000"
|
||||
android:widgetCategory="home_screen|not_keyguard"/>
|
||||
@@ -0,0 +1,20 @@
|
||||
<!--
|
||||
Keep this in sync with res/xml/widget_reminders_info.xml. It exists only to add not_keyguard:
|
||||
from Android 16 QPR1 widgets are lock screen eligible by default, and this one renders reminder
|
||||
titles and descriptions, which should not be readable on a locked device.
|
||||
-->
|
||||
<appwidget-provider xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:initialLayout="@layout/widget_reminders"
|
||||
android:minWidth="400dp"
|
||||
android:minHeight="100dp"
|
||||
android:minResizeWidth="400dp"
|
||||
android:minResizeHeight="50dp"
|
||||
android:description="@string/reminders"
|
||||
android:targetCellWidth="5"
|
||||
android:targetCellHeight="2"
|
||||
android:resizeMode="horizontal|vertical"
|
||||
android:previewImage="@drawable/reminder_preview"
|
||||
android:previewLayout="@layout/widget_reminders_preview"
|
||||
android:updatePeriodMillis="1800000"
|
||||
android:widgetCategory="home_screen|not_keyguard"
|
||||
/>
|
||||
Reference in New Issue
Block a user