Skip to content

Commit

Permalink
Mirror "secure" content
Browse files Browse the repository at this point in the history
Some applications, like Silence, prevent the content of a window from
being viewed on non-secure displays:
<https://developer.android.com/reference/android/view/WindowManager.LayoutParams.html#FLAG_SECURE>

We can mirror it by just creating a "secure" display:
<https://developer.android.com/reference/android/view/Display#FLAG_SECURE>
  • Loading branch information
rom1v committed Jan 16, 2019
1 parent 39c5e71 commit 1fdde49
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 15 deletions.
14 changes: 0 additions & 14 deletions FAQ.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,20 +24,6 @@ If you still encounter problems, please see [issue 9].
[issue 9]: https://github.com/Genymobile/scrcpy/issues/9


### I get a black screen for some applications like Silence

This is expected, they requested to [protect] the screen.

In [Silence], you can disable it in settings → Privacy → Screen security.

[protect]: https://developer.android.com/reference/android/view/Display#FLAG_SECURE
[silence]: https://f-droid.org/en/packages/org.smssecure.smssecure/

See [issue 36].

[issue 36]: https://github.com/Genymobile/scrcpy/issues/36


### Mouse clicks do not work

On some devices, you may need to enable an option to allow [simulating input].
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -151,7 +151,7 @@ private static MediaFormat createFormat(int bitRate, int frameRate, int iFrameIn
}

private static IBinder createDisplay() {
return SurfaceControl.createDisplay("scrcpy", false);
return SurfaceControl.createDisplay("scrcpy", true);
}

private static void configure(MediaCodec codec, MediaFormat format) {
Expand Down

0 comments on commit 1fdde49

Please sign in to comment.