Search in sources :

Example 26 with OnClickListener

use of android.content.DialogInterface.OnClickListener in project mobile-android by photo.

the class BordersPanel method showUpdateAlertMultipleItems.

/**
	 * 
	 * @param set
	 */
private void showUpdateAlertMultipleItems(final String pkgname, Set<PluginError> set) {
    if (null != set) {
        final String errorString = getContext().getBaseContext().getResources().getString(R.string.feather_effects_error_update_multiple);
        OnClickListener yesListener = new OnClickListener() {

            @Override
            public void onClick(DialogInterface dialog, int which) {
                searchOrDownloadPlugin(pkgname, true);
            }
        };
        onGenericError(errorString, R.string.feather_update, yesListener, android.R.string.cancel, null);
    }
}
Also used : DialogInterface(android.content.DialogInterface) OnClickListener(android.content.DialogInterface.OnClickListener)

Example 27 with OnClickListener

use of android.content.DialogInterface.OnClickListener in project JamsMusicPlayer by psaravan.

the class AsyncPlayFolderRecursiveTask method onPreExecute.

protected void onPreExecute() {
    pd = new ProgressDialog(mContext);
    pd.setCancelable(false);
    pd.setIndeterminate(false);
    pd.setTitle(R.string.play_folder_recursive);
    pd.setButton(DialogInterface.BUTTON_NEUTRAL, mContext.getResources().getString(R.string.cancel), new OnClickListener() {

        @Override
        public void onClick(DialogInterface arg0, int arg1) {
            pd.dismiss();
        }
    });
    pd.show();
}
Also used : DialogInterface(android.content.DialogInterface) OnClickListener(android.content.DialogInterface.OnClickListener) ProgressDialog(android.app.ProgressDialog)

Example 28 with OnClickListener

use of android.content.DialogInterface.OnClickListener in project JamsMusicPlayer by psaravan.

the class AsyncDeleteTask method onPreExecute.

protected void onPreExecute() {
    pd = new ProgressDialog(mContext);
    pd.setCancelable(false);
    pd.setIndeterminate(false);
    pd.setTitle(R.string.delete);
    pd.setMessage(mContext.getResources().getString(R.string.deleting_files));
    pd.setButton(DialogInterface.BUTTON_NEUTRAL, mContext.getResources().getString(R.string.run_in_background), new OnClickListener() {

        @Override
        public void onClick(DialogInterface arg0, int arg1) {
            pd.dismiss();
        }
    });
    pd.show();
}
Also used : DialogInterface(android.content.DialogInterface) OnClickListener(android.content.DialogInterface.OnClickListener) ProgressDialog(android.app.ProgressDialog)

Example 29 with OnClickListener

use of android.content.DialogInterface.OnClickListener in project JamsMusicPlayer by psaravan.

the class AsyncCopyMoveTask method onPreExecute.

protected void onPreExecute() {
    pd = new ProgressDialog(mFragment.getActivity());
    pd.setCancelable(false);
    pd.setIndeterminate(false);
    if (mShouldMove) {
        pd.setTitle(R.string.move);
        pd.setMessage(mContext.getResources().getString(R.string.moving_file));
    } else {
        pd.setTitle(R.string.copy);
        pd.setMessage(mContext.getResources().getString(R.string.copying_file));
    }
    pd.setButton(DialogInterface.BUTTON_NEUTRAL, mContext.getResources().getString(R.string.run_in_background), new OnClickListener() {

        @Override
        public void onClick(DialogInterface arg0, int arg1) {
            pd.dismiss();
        }
    });
    pd.show();
}
Also used : DialogInterface(android.content.DialogInterface) OnClickListener(android.content.DialogInterface.OnClickListener) ProgressDialog(android.app.ProgressDialog)

Example 30 with OnClickListener

use of android.content.DialogInterface.OnClickListener in project JamsMusicPlayer by psaravan.

the class AsyncAutoGetAlbumArtTask method onPreExecute.

public void onPreExecute() {
    super.onPreExecute();
    pd = new ProgressDialog(mActivity);
    pd.setTitle(R.string.downloading_album_art);
    pd.setProgressStyle(ProgressDialog.STYLE_HORIZONTAL);
    pd.setCancelable(false);
    pd.setCanceledOnTouchOutside(false);
    pd.setMessage(mContext.getResources().getString(R.string.scanning_for_missing_art));
    pd.setButton(DialogInterface.BUTTON_NEGATIVE, mContext.getResources().getString(R.string.cancel), new OnClickListener() {

        @Override
        public void onClick(DialogInterface dialog, int which) {
            dialog.dismiss();
            task.cancel(true);
        }
    });
    pd.show();
}
Also used : DialogInterface(android.content.DialogInterface) OnClickListener(android.content.DialogInterface.OnClickListener) ProgressDialog(android.app.ProgressDialog)

Aggregations

DialogInterface (android.content.DialogInterface)179 OnClickListener (android.content.DialogInterface.OnClickListener)179 AlertDialog (android.app.AlertDialog)118 View (android.view.View)45 SuppressLint (android.annotation.SuppressLint)36 TextView (android.widget.TextView)36 Intent (android.content.Intent)34 Context (android.content.Context)24 EditText (android.widget.EditText)22 Bundle (android.os.Bundle)21 LayoutInflater (android.view.LayoutInflater)16 Builder (android.app.AlertDialog.Builder)15 Paint (android.graphics.Paint)14 OnCancelListener (android.content.DialogInterface.OnCancelListener)12 KeyEvent (android.view.KeyEvent)12 Point (android.graphics.Point)11 AlertDialog (android.support.v7.app.AlertDialog)11 ContextThemeWrapper (android.view.ContextThemeWrapper)11 CompoundButton (android.widget.CompoundButton)11 OnCheckedChangeListener (android.widget.CompoundButton.OnCheckedChangeListener)11