Skip to content

Commit 6ccced5

Browse files
committed
権限許可画面をアプリ履歴に残さない。オーバーレイを複数追加させない。
1 parent 61d8454 commit 6ccced5

2 files changed

Lines changed: 6 additions & 2 deletions

File tree

dConnectManager/dConnectManager/dconnect-manager-app/src/main/AndroidManifest.xml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -244,12 +244,14 @@
244244
<!-- コピーガード用オーバーレイ許可取得画面 -->
245245
<activity android:name=".protection.OverlayPermissionActivity"
246246
android:exported="false"
247+
android:excludeFromRecents="true"
247248
android:taskAffinity=".permission"
248249
android:theme="@style/Theme.Dialog.Transparent"/>
249250

250251
<!-- 開発者向けオプション表示確認画面 -->
251252
<activity android:name=".protection.DeveloperToolDialogActivity"
252253
android:exported="false"
254+
android:excludeFromRecents="true"
253255
android:taskAffinity=".permission"
254256
android:theme="@style/Theme.Dialog.Transparent"/>
255257
</application>

dConnectManager/dConnectManager/dconnect-manager-app/src/main/java/org/deviceconnect/android/manager/protection/ScreenRecordingGuardOverlay.java

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -162,8 +162,10 @@ public synchronized void enable() {
162162

163163
private void showInternal() {
164164
mMainHandler.post(() -> {
165-
mWindowManager.addView(mOverlayView, mLayoutParams);
166-
mIsShown = true;
165+
if (!mIsShown) {
166+
mWindowManager.addView(mOverlayView, mLayoutParams);
167+
mIsShown = true;
168+
}
167169
});
168170
}
169171

0 commit comments

Comments
 (0)