/// <summary>
		/// 停止 the progress dialog.
		/// </summary>
		public static void StopProgressDialog()
		{
			if (progressDialog != null && progressDialog.IsShowing)
				progressDialog.Dismiss ();
			progressDialog = null;

		}
 public static CustomProgressDialog createDialog(Context context)
 {
     customProgressDialog = new CustomProgressDialog(context, Resource.Style.CustomProgressDialog);
     customProgressDialog.SetContentView(Resource.Layout.customprogressdialog);
     customProgressDialog.Window.Attributes.Gravity = Android.Views.GravityFlags.Center;
     return(customProgressDialog);
 }
		public static CustomProgressDialog createDialog(Context context){
			customProgressDialog = new CustomProgressDialog (context, Resource.Style.CustomProgressDialog);
			customProgressDialog.SetContentView(Resource.Layout.customprogressdialog);
			customProgressDialog.Window.Attributes.Gravity = Android.Views.GravityFlags.Center;
			return customProgressDialog;
		
		}
 /// <summary>
 /// 停止 the progress dialog.
 /// </summary>
 public static void StopProgressDialog()
 {
     if (progressDialog != null && progressDialog.IsShowing)
     {
         progressDialog.Dismiss();
     }
     progressDialog = null;
 }
        /// <summary>
        /// 启动 progress dialog.
        /// </summary>
        /// <param name="context">Context.</param>
        /// <param name="msg">Message.</param>
        public static void StartProgressDialog(Activity _activity, string msg, bool canceleable = false)
        {
//			if(progressDialog == null)
            progressDialog = CustomProgressDialog.createDialog(_activity);
            progressDialog.Window.SetGravity(GravityFlags.Center);
            progressDialog.SetMessage(msg);
            progressDialog.Show();
            progressDialog.SetCancelable(canceleable);
        }
		/// <summary>
		/// 启动 progress dialog.
		/// </summary>
		/// <param name="context">Context.</param>
		/// <param name="msg">Message.</param>
		public static void StartProgressDialog(Activity _activity,string msg,bool canceleable =false)
		{

//			if(progressDialog == null)
				progressDialog = CustomProgressDialog.createDialog (_activity);
			progressDialog.Window.SetGravity (GravityFlags.Center); 
			progressDialog.SetMessage (msg);
			progressDialog.Show ();
			progressDialog.SetCancelable (canceleable);

		}