Example #1
0
 private void Desk_EvClosed(object sender, ChatDeskEventArgs e)
 {
     DispatcherEx.xInvoke(() =>
     {
         Close();
     });
 }
Example #2
0
 private void Desk_EvHide(object sender, ChatDeskEventArgs e)
 {
     DispatcherEx.xInvoke(() =>
     {
         Hide();
         Sleep();
     });
 }
Example #3
0
 private void Desk_EvShow(object sender, ChatDeskEventArgs e)
 {
     DispatcherEx.xInvoke(() =>
     {
         if (!Desk.IsMinimized && Desk.IsVisible && base.Visibility > Visibility.Visible)
         {
             ShowAssist();
         }
     });
 }
Example #4
0
 private void Desk_EvGetForeground(object sender, ChatDeskEventArgs e)
 {
     DispatcherEx.xInvoke(() =>
     {
         ShowAssist();
         DelayCaller foregroundTrackDelayCaller = _foregroundTrackDelayCaller;
         if (foregroundTrackDelayCaller != null)
         {
             foregroundTrackDelayCaller.CallAfterDelay();
         }
     });
 }
Example #5
0
 private void Desk_EvMaximize(object sender, ChatDeskEventArgs e)
 {
     Desk.ShowNormal();
     DispatcherEx.xInvoke(() =>
     {
         XYRatio toLogicalRatio = ToLogicalRatio;
         double maxW            = SystemParameters.WorkArea.Width - (double)WaParams.GetRightPanelWidth(Desk.Seller) - (double)12f;
         int w       = (int)(maxW / toLogicalRatio.XRatio);
         double maxH = SystemParameters.WorkArea.Height - (double)WaParams.GetBottomPanelHeight(Desk.Seller) - (double)12f;
         int h       = (int)(maxH / toLogicalRatio.YRatio);
         Desk.SetRect(6, 6, w, h);
     });
     Track(false, false);
 }
Example #6
0
 private void Desk_EvMinimize(object sender, ChatDeskEventArgs e)
 {
     DispatcherEx.xInvoke(() =>
     {
         try
         {
             Hide();
             Sleep();
         }
         catch (Exception ex)
         {
             Log.Exception(ex);
         }
     });
 }
Example #7
0
 private void Editor_EvEditorTextChanged(object sender, ChatDeskEventArgs e)
 {
     Task.Factory.StartNew(OnEditorTextChangedAsync, TaskCreationOptions.LongRunning);
 }
Example #8
0
 private void Desk_EvNormalize(object sender, ChatDeskEventArgs e)
 {
     WakeUp();
     Track(false, false);
 }
Example #9
0
 private void Desk_EvMoved(object sender, ChatDeskEventArgs e)
 {
     Track(false, true);
 }
Example #10
0
 private void Desk_EvResized(object sender, ChatDeskEventArgs e)
 {
     Track(false, false);
 }
Example #11
0
 private void Desk_EvLostForeground(object sender, ChatDeskEventArgs e)
 {
 }