Пример #1
0
 public static AlertDialog createIncomingCallDialog(Context context, IncomingCall incomingCall, DialogInterface.OnClickListener answerCallClickListener, DialogInterface.OnClickListener cancelClickListener)
 {
     AlertDialog.Builder alertDialogBuilder = new AlertDialog.Builder(context);
     alertDialogBuilder.Icon  = R.drawable.ic_call_black_24dp;
     alertDialogBuilder.Title = "Incoming Call";
     alertDialogBuilder.setPositiveButton("Accept", answerCallClickListener);
     alertDialogBuilder.setNegativeButton("Reject", cancelClickListener);
     alertDialogBuilder.Message = incomingCall.From + " is calling.";
     return(alertDialogBuilder.create());
 }
Пример #2
0
        private void showAlertMessage(string msg)
        {
            if (msg == null)
            {
                throw new System.NullReferenceException("AlertMessage is Null!!");
            }

            AlertDialog.Builder builder = new AlertDialog.Builder(this);
            builder.Title   = "Error";
            builder.Message = msg;
            builder.setNegativeButton("close", new OnClickListenerAnonymousInnerClassHelper(this));
            builder.show();
        }
Пример #3
0
 public virtual void onFileActionTransferRequested(int id, string path)
 {
     outerInstance.mFilePath = path;
     outerInstance.mTransId  = id;
     runOnUiThread(() =>
     {
         AlertDialog.Builder alertbox = new AlertDialog.Builder(outerInstance);
         alertbox.Message             = "Do you want to receive file: " + outerInstance.mFilePath + " ?";
         alertbox.setPositiveButton("Accept", new OnClickListenerAnonymousInnerClassHelper(this));
         alertbox.setNegativeButton("Reject", new OnClickListenerAnonymousInnerClassHelper2(this));
         alertbox.Cancelable  = false;
         outerInstance.mAlert = alertbox.create();
         outerInstance.mAlert.show();
     });
 }
//JAVA TO C# CONVERTER WARNING: 'final' parameters are not available in .NET:
//ORIGINAL LINE: public void showDiallog(final int position)
        public virtual void showDiallog(int position)
        {
            AlertDialog.Builder builder = new AlertDialog.Builder(this);

            builder.Title   = "Confirm";
            builder.Message = "Disconnect ?";

            builder.setPositiveButton("YES", new OnClickListenerAnonymousInnerClassHelper(this, position));

            builder.setNegativeButton("NO", new OnClickListenerAnonymousInnerClassHelper2(this));

            AlertDialog alert = builder.create();

            alert.show();
        }
			public virtual void onFileActionTransferRequested(int id, string path)
			{
				outerInstance.mFilePath = path;
				outerInstance.mTransId = id;
				runOnUiThread(() =>
				{
					AlertDialog.Builder alertbox = new AlertDialog.Builder(outerInstance);
					alertbox.Message = "Do you want to receive file: " + outerInstance.mFilePath + " ?";
					alertbox.setPositiveButton("Accept", new OnClickListenerAnonymousInnerClassHelper(this));
					alertbox.setNegativeButton("Reject", new OnClickListenerAnonymousInnerClassHelper2(this));
					alertbox.Cancelable = false;
					outerInstance.mAlert = alertbox.create();
					outerInstance.mAlert.show();
				});
			}