Search packages, repositories and app categories

Package detailsv1.0.2

flutter_screen_wake

A Flutter plugin to manage the device's screen on Android and iOS.

AndroidiOS
30-day downloads
491
Likes
32
Pub points
140

Install package

flutter pub add flutter_screen_wake

Package Overview

Package selection guidance compiled from public package information, community data, and project usage.

A Flutter plugin that enables control over the device's screen state on both Android and iOS, allowing developers to keep the screen awake or dim it as needed. It provides a simple API to manage screen wake locks, useful for applications requiring uninterrupted display, such as video players, navigation apps, or kiosk modes. The plugin works across platforms with consistent behavior and integrates smoothly into existing Flutter projects.

Use cases

  • Keeping screen on during video playback
  • Enabling kiosk mode in public displays
  • Preventing screen timeout in navigation apps
  • Maintaining visibility in AR/VR applications
  • Supporting long-running task interfaces

Key features

  • Cross-platform support (Android & iOS)
  • Simple API for screen wake management
  • Automatic release of wake locks
  • Minimal performance overhead
  • Compatible with Flutter's async model

Suitable for

  • Media playback apps
  • Interactive kiosks
  • Navigation and mapping tools
  • AR/VR experiences
  • Long-duration task interfaces

Considerations

  • May impact battery life
  • Requires appropriate permissions on Android
  • iOS has limited background capabilities
  • Should be used sparingly to avoid user frustration
  • Must release wake locks to prevent drain

Original README

Original README snapshot from the linked source repository. Visit the repository for the latest content.

Flutter Screen Wake

Plugin is Null Safety`

pub package A Flutter plugin to manage the device's screen on Android and iOS.

Usage

To use this plugin, add flutter_screen_wake as a dependency in your pubspec.yaml file.

Make sure you add the following permissions to your Android Manifest

<uses-permission android:name="android.permission.WAKE_LOCK" />

Example

// Import package
import 'package:flutter_screen_wake/flutter_screen_wake.dart';

// Get the current brightness:
double brightness = await FlutterScreenWake.brightness;

// Set the brightness:
FlutterScreenWake.setBrightness(0.5);

// Check if the screen is kept on:
bool isKeptOn = await FlutterScreenWake.isKeptOn;

// Prevent screen from going into sleep mode:
FlutterScreenWake.keepOn(true);

Categories

Source repository

Projects using this package