Example usage for android.widget Toast makeText

List of usage examples for android.widget Toast makeText

Introduction

In this page you can find the example usage for android.widget Toast makeText.

Prototype

public static Toast makeText(Context context, @StringRes int resId, @Duration int duration)
        throws Resources.NotFoundException 

Source Link

Document

Make a standard toast that just contains a text view with the text from a resource.

Usage

From source file:Main.java

public static void alert(Context context, String string) {
    Toast.makeText(context, string, Toast.LENGTH_SHORT).show();
}

From source file:Main.java

public static void notifyNoConnection(Context context) {
    Toast.makeText(context, "No internet connection", Toast.LENGTH_SHORT).show();
}

From source file:Main.java

public static void showTip(Activity activity, String msg) {
    Toast.makeText(activity, msg, Toast.LENGTH_SHORT).show();
}

From source file:Main.java

static public void say(Context context, String text) {
    Toast.makeText(context, text, Toast.LENGTH_SHORT).show();
}

From source file:Main.java

public static void show(Context context, String info) {
    Toast.makeText(context, info, Toast.LENGTH_LONG).show();
}

From source file:Main.java

public static void showNoImplementText(Context context) {
    Toast.makeText(context, "Add more codes to support!", Toast.LENGTH_SHORT).show();
}

From source file:Main.java

public static void addMsg(Activity activity, String msg) {
    Toast.makeText(activity, msg, Toast.LENGTH_SHORT).show();
}

From source file:Main.java

public static void displayErrorMessage(Context context) {
    Toast.makeText(context, "Input field must not be zero", Toast.LENGTH_LONG).show();
}

From source file:Main.java

public static void showToast(String msg, Context ctx) {
    Toast.makeText(ctx, msg, Toast.LENGTH_SHORT).show();
}

From source file:Main.java

public static void ShowMsg(Context context, String msg) {
    Toast.makeText(context, msg, Toast.LENGTH_SHORT).show();
}