Main.java Source code

Java tutorial

Introduction

Here is the source code for Main.java

Source

//package com.java2s;

import android.app.Dialog;
import android.content.Context;

public class Main {
    /**
     * create dialog with layout content designed in XML. can used such as a common method.
     * This dialog will full screen
     * 
     * @param context
     * @param idLayout
     * @return
     */
    public static Dialog createDialogFullScreen(Context context, int idLayout) {
        Dialog dialog = new Dialog(context, android.R.style.Theme_Translucent_NoTitleBar);
        dialog.setContentView(idLayout);
        return dialog;
    }
}