expo icon indicating copy to clipboard operation
expo copied to clipboard

[video] Add `keepScreenOnWhilePlaying` property

Open behenate opened this issue 10 months ago • 2 comments

Why

Currently on iOS the player will keep the screen on while a video is playing, on Android playing a video has no effect on screen going to sleep. This PR unifies the behavior and adds a new property: keepScreenOnWhilePlaying to allow users to control this feature.

How

Added keepScreenOnWhilePlaying, enabled it by default on Android. Also the fullscreen player on Android will always stay on.

Test Plan

Tested in BareExpo on physical Android and iOS devices.

behenate avatar May 29 '25 14:05 behenate

Subscribed to pull request

File Patterns Mentions
docs/** @amandeepmittal
packages/expo-video/** @lukmccall, @aleqsio

Generated by CodeMention

github-actions[bot] avatar May 29 '25 14:05 github-actions[bot]

The Pull Request introduced fingerprint changes against the base commit: 85df98e3bc6ae15787a2ce2d4502421d0e9d7a7f

Fingerprint diff
[
  {
    "op": "changed",
    "beforeSource": {
      "type": "dir",
      "filePath": "../../packages/expo-video/android",
      "reasons": [
        "expoAutolinkingAndroid"
      ],
      "hash": "bbb366edf67088552dd4d01fe2eac4f33b73942f"
    },
    "afterSource": {
      "type": "dir",
      "filePath": "../../packages/expo-video/android",
      "reasons": [
        "expoAutolinkingAndroid"
      ],
      "hash": "1fc7b05fe86dcd22f6c5fda374a1c29ce759894d"
    }
  },
  {
    "op": "changed",
    "beforeSource": {
      "type": "dir",
      "filePath": "../../packages/expo-video/ios",
      "reasons": [
        "expoAutolinkingIos"
      ],
      "hash": "65a62e3d0e168aa569658d7af79a47112fbca707"
    },
    "afterSource": {
      "type": "dir",
      "filePath": "../../packages/expo-video/ios",
      "reasons": [
        "expoAutolinkingIos"
      ],
      "hash": "e9ad654df3b8320041a97671a7acff5535c8f9d8"
    }
  }
]

Generated by PR labeler 🤖

expo-bot avatar Jun 11 '25 15:06 expo-bot