is Flash Supported - Android Camera

Android examples for Camera:Camera Flash

Description

is Flash Supported

Demo Code


//package com.java2s;

import android.content.pm.PackageManager;

public class Main {
    public static boolean isFlashSupported(PackageManager packageManager) {
        // if device support camera flash?
        if (packageManager
                .hasSystemFeature(PackageManager.FEATURE_CAMERA_FLASH)) {
            return true;
        }/*  ww w  .jav a  2s  .c  o  m*/
        return false;
    }
}

Related Tutorials