Java Code Examples for com.afollestad.materialdialogs.MaterialDialog#ButtonCallback
The following examples show how to use
com.afollestad.materialdialogs.MaterialDialog#ButtonCallback .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: DialogsUtils.java From q-municate-android with Apache License 2.0 | 5 votes |
public static void showOpenAppSettingsDialog(FragmentManager fm, final String dialogMessage, final MaterialDialog.ButtonCallback callback) { //postDelayed() is temp fix before fixing this bug https://code.google.com/p/android/issues/detail?id=190966 TwoButtonsDialogFragment.showDelayed( fm, App.getInstance().getString(R.string.app_name), dialogMessage, App.getInstance().getString(R.string.dlg_cancel), App.getInstance().getString(R.string.dlg_open_app_settings), callback, OPEN_APP_SETTINGS_DIALOG_DELAY); }
Example 2
Source File: TwoButtonsDialogFragment.java From q-municate-android with Apache License 2.0 | 5 votes |
public static void show(FragmentManager fm, String title, String message, boolean dismiss, String positiveText, String negativeText, MaterialDialog.ButtonCallback callback) { Bundle args = new Bundle(); args.putString(ARG_TITLE, title); args.putString(ARG_CONTENT, message); args.putBoolean(ARG_DISMISS, dismiss); args.putString(ARG_POSITIVE_TEXT, positiveText); args.putString(ARG_NEGATIVE_TEXT, negativeText); TwoButtonsDialogFragment twoButtonsDialog = new TwoButtonsDialogFragment(); twoButtonsDialog.setCallbacks(callback); twoButtonsDialog.setArguments(args); twoButtonsDialog.show(fm, TAG); }
Example 3
Source File: TwoButtonsDialogFragment.java From q-municate-android with Apache License 2.0 | 5 votes |
public static void showDelayed(final FragmentManager fm, final String title, final String message, final String positiveText, final String negativeText, final MaterialDialog.ButtonCallback callback, long delay) { new Handler().postDelayed(new Runnable() { @Override public void run() { show(fm, title, message, true, positiveText, negativeText, callback); } }, delay); }
Example 4
Source File: OneButtonDialogFragment.java From q-municate-android with Apache License 2.0 | 5 votes |
public static void show(FragmentManager fm, String content, boolean cancelable, MaterialDialog.ButtonCallback callback) { OneButtonDialogFragment oneButtonDialogFragment = new OneButtonDialogFragment(); Bundle args = new Bundle(); args.putString(ARG_CONTENT, content); args.putBoolean(ARG_CANCELABLE, cancelable); oneButtonDialogFragment.setArguments(args); oneButtonDialogFragment.setCallbacks(callback); oneButtonDialogFragment.show(fm, TAG); }
Example 5
Source File: TwoButtonsDialogFragment.java From q-municate-android with Apache License 2.0 | 4 votes |
public static void show(FragmentManager fm, String message, boolean dismiss, MaterialDialog.ButtonCallback callback) { show(fm, null, message, dismiss, null, null, callback); }
Example 6
Source File: TwoButtonsDialogFragment.java From q-municate-android with Apache License 2.0 | 4 votes |
public static void show(FragmentManager fm, String message, MaterialDialog.ButtonCallback callback) { show(fm, null, message, true, null, null, callback); }
Example 7
Source File: TwoButtonsDialogFragment.java From q-municate-android with Apache License 2.0 | 4 votes |
public static void show(FragmentManager fm, int message, MaterialDialog.ButtonCallback callback) { show(fm, null, App.getInstance().getString(message), true, null, null, callback); }
Example 8
Source File: TwoButtonsDialogFragment.java From q-municate-android with Apache License 2.0 | 4 votes |
public static void show(FragmentManager fm, int title, int message, MaterialDialog.ButtonCallback callback) { show(fm, App.getInstance().getString(title), App.getInstance().getString(message), true, null, null, callback); }
Example 9
Source File: TwoButtonsDialogFragment.java From q-municate-android with Apache License 2.0 | 4 votes |
public static void show(FragmentManager fm, int title, int message, int positiveText, int negativeText, MaterialDialog.ButtonCallback callback) { show(fm, App.getInstance().getString(title), App.getInstance().getString(message), true, App.getInstance().getString(positiveText), App.getInstance().getString(negativeText), callback); }
Example 10
Source File: TwoButtonsDialogFragment.java From q-municate-android with Apache License 2.0 | 4 votes |
public void setCallbacks(MaterialDialog.ButtonCallback callback) { this.buttonsCallback = callback; }
Example 11
Source File: OneButtonDialogFragment.java From q-municate-android with Apache License 2.0 | 4 votes |
public static void show(FragmentManager fm, int content, boolean cancelable, MaterialDialog.ButtonCallback callback) { show(fm, App.getInstance().getString(content), cancelable, callback); }
Example 12
Source File: OneButtonDialogFragment.java From q-municate-android with Apache License 2.0 | 4 votes |
public void setCallbacks(MaterialDialog.ButtonCallback callback) { this.callback = callback; }
Example 13
Source File: UserAgreementDialogFragment.java From q-municate-android with Apache License 2.0 | 4 votes |
public static void show(FragmentManager fragmentManager, MaterialDialog.ButtonCallback callback) { UserAgreementDialogFragment fragment = new UserAgreementDialogFragment(); fragment.setCallbacks(callback); fragment.show(fragmentManager, UserAgreementDialogFragment.class.getSimpleName()); }
Example 14
Source File: UserAgreementDialogFragment.java From q-municate-android with Apache License 2.0 | 4 votes |
public void setCallbacks(MaterialDialog.ButtonCallback callback) { this.buttonsCallback = callback; }