Exemplo n.º 1
0
        void UpdateLog(object sender, EventArgs args)
        {
            if (!bar.Install())
            {
                return;
            }

            var timestamp = setting.GetLogTimestamp();

            if (updateTimeStamp == timestamp)
            {
                bar.Remove();
                return;
            }

            try
            {
                repaintCtrl.Disable();
                rtBoxLogger.Text = setting.GetLogContent();
                ScrollToBottom();
                updateTimeStamp = timestamp;
                repaintCtrl.Enable();
            }
            catch { }
            finally
            {
                bar.Remove();
            }
        }
Exemplo n.º 2
0
        void UpdateOutput()
        {
            if (!bar.Install())
            {
                return;
            }

            var timestamp = qLogger.GetTimestamp();

            if (updateOutputTimeStamp == timestamp)
            {
                bar.Remove();
                return;
            }

            VgcApis.Libs.UI.RunInUiThread(rtboxOutput, () =>
            {
                // form maybe closed
                try
                {
                    repaintCtrl.Disable();
                    rtboxOutput.Text = qLogger.GetLogAsString(true);
                    VgcApis.Libs.UI.ScrollToBottom(rtboxOutput);
                    repaintCtrl.Enable();
                    updateOutputTimeStamp = timestamp;
                }
                catch { }
                finally
                {
                    bar.Remove();
                }
            });
        }
Exemplo n.º 3
0
 void UpdateLogBox()
 {
     repaintCtrl.Disable();
     rtBoxLogger.Text           = qLogger.GetLogAsString(true);
     rtBoxLogger.SelectionStart = rtBoxLogger.Text.Length;
     rtBoxLogger.ScrollToCaret();
     repaintCtrl.Enable();
 }