set View Enable - Android User Interface

Android examples for User Interface:View Enable

Description

set View Enable

Demo Code


//package com.java2s;
import android.view.View;

public class Main {
    public static void setEnable(View... views) {
        if (views != null && views.length > 0) {
            for (View view : views) {
                if (view != null && !view.isEnabled()) {
                    view.setEnabled(true);
                }/*from   ww  w . java2s .  c o  m*/
            }
        }
    }
}

Related Tutorials