screen Off Duration - Android User Interface

Android examples for User Interface:Screen Dormant

Description

screen Off Duration

Demo Code


//package com.java2s;

import android.content.Context;

import android.provider.Settings;

public class Main {

    public static int screenOffDuration(Context $context) {
        return Settings.System.getInt($context.getContentResolver(),
                Settings.System.SCREEN_OFF_TIMEOUT, 15000);
    }//ww  w. jav a  2s .  c o  m
}

Related Tutorials