예제 #1
0
        /// <summary>
        /// 显示等待框,callback为需要执行的方法体(需要自己做异常处理)。
        /// 目前等等框为模式窗体
        /// </summary>
        public static void Show(Action callback, string mes = "...")
        {
            WaitingBox win  = new WaitingBox(callback);
            Window     pwin = ControlHelper.GetTopWindow();

            win.Owner = pwin;
            win.Text  = mes;
            win.ShowDialog();
        }
예제 #2
0
        void System.Windows.Markup.IComponentConnector.Connect(int connectionId, object target)
        {
            switch (connectionId)
            {
            case 1:
                this.wb = ((System.Windows.WaitingBox)(target));
                return;

            case 2:
                this.FIcon = ((System.Windows.Controls.TextBlock)(target));
                return;

            case 3:
                this.TransFIcon = ((System.Windows.Media.RotateTransform)(target));
                return;

            case 4:
                this.txtMessage = ((System.Windows.Controls.TextBlock)(target));
                return;
            }
            this._contentLoaded = true;
        }