bool OutputDispatchHandler() { lock (updates) { lastTextWrite = null; if (updates.Count == 0) { outputDispatcherRunning = false; return(false); } else if (!outputDispatcherRunning) { updates.Clear(); return(false); } else { while (updates.Count > 0) { QueuedUpdate up = updates.Dequeue(); up.Execute(this); } } } return(true); }
public void Clear() { lock (updates) { updates.Clear(); lastTextWrite = null; outputDispatcherRunning = false; } outputModel.Clear(); }
public void Clear() { lock (updates) { updates.Clear(); lastTextWrite = null; outputDispatcherRunning = false; } outputModel.Clear(); }
protected override void OnDestroyed() { base.OnDestroyed(); lock (updates) { updates.Clear(); lastTextWrite = null; } IdeApp.Preferences.CustomOutputPadFontChanged -= HandleCustomFontChanged; }
public void WriteTask(object task, string name, string status, List <TaskMessage> error, bool clearOutput) { if (clearOutput) { Clear(); } QueuedTextWrite qtw = new QueuedTextWrite(error); AddQueuedUpdate(qtw); }
public void WriteTask_II(object task, string name, string status, List <TaskMessage> error, bool clearOutput) { if (clearOutput) { Clear(); } TaskResult tr = new TaskResult(name, status, error); QueuedTextWrite qtw = new QueuedTextWrite(tr); AddQueuedUpdate(qtw); }
//**// void AddQueuedUpdate(QueuedUpdate update) { lock (updates) { updates.Enqueue(update); if (!outputDispatcherRunning) { GLib.Timeout.Add(50, outputDispatcher); outputDispatcherRunning = true; } lastTextWrite = update as QueuedTextWrite; } }
public void WriteConsoleLogText(string text) { lock (updates) { if (lastTextWrite != null && lastTextWrite.Tag == consoleLogTag) { lastTextWrite.Write(text); return; } } QueuedTextWrite w = new QueuedTextWrite(text, consoleLogTag); addQueuedUpdate(w); }
public void WriteConsoleLogText(LogViewProgressMonitor monitor, string text) { lock (updates) { if (lastTextWrite != null && lastTextWrite.Tag == consoleLogTag) { lastTextWrite.Write(text); return; } } var w = new QueuedTextWrite(monitor, text, consoleLogTag); addQueuedUpdate(w); }
public void Clear() { unchecked { Cookie++; } lock (updates) { updates.Clear(); lastTextWrite = null; outputDispatcherRunning = false; } buffer.Clear(); }
protected override void OnDestroyed() { base.OnDestroyed(); lock (updates) { updates.Clear(); lastTextWrite = null; } //IdeApp.Preferences.CustomOutputPadFontChanged -= HandleCustomFontChanged; if (customFont != null) { customFont.Dispose(); customFont = null; } }
public void WriteText(string text) { //raw text has an extra optimisation here, as we can append it to existing updates lock (updates) { if (lastTextWrite != null) { if (lastTextWrite.Tag == null) { lastTextWrite.Write(text); return; } } } QueuedTextWrite qtw = new QueuedTextWrite(text, null); addQueuedUpdate(qtw); }
public void WriteText(LogViewProgressMonitor monitor, string text) { text = SanitizeConsoleText(text); //raw text has an extra optimisation here, as we can append it to existing updates lock (updates) { if (lastTextWrite != null) { if (lastTextWrite.Tag == null) { lastTextWrite.Write(text); return; } } } var qtw = new QueuedTextWrite(monitor, text, null); addQueuedUpdate(qtw); }
public void WriteTask_II(object task, string name, string status, List <TaskMessage> error, bool clearOutput) { if (clearOutput) { Clear(); } TaskResult tr = new TaskResult(name, status, error); //raw text has an extra optimisation here, as we can append it to existing updates /*lock (updates) { * if (lastTextWrite != null) { * if (lastTextWrite.Tag == null) { * lastTextWrite.Write(tr); * return; * } * } * }*/ QueuedTextWrite qtw = new QueuedTextWrite(tr); AddQueuedUpdate(qtw); }
public void WriteError(string text) { QueuedTextWrite w = new QueuedTextWrite(text, errorTag); addQueuedUpdate(w); }
protected override void OnDestroyed () { base.OnDestroyed (); lock (updates) { updates.Clear (); lastTextWrite = null; } IdeApp.Preferences.CustomOutputPadFont.Changed -= HandleCustomFontChanged; }
public void WriteError (string text) { var w = new QueuedTextWrite (text, errorTag); addQueuedUpdate (w); }
public void WriteConsoleLogText (string text) { lock (updates) { if (lastTextWrite != null && lastTextWrite.Tag == consoleLogTag) { lastTextWrite.Write (text); return; } } var w = new QueuedTextWrite (text, consoleLogTag); addQueuedUpdate (w); }
public void WriteText (string text) { //raw text has an extra optimisation here, as we can append it to existing updates lock (updates) { if (lastTextWrite != null) { if (lastTextWrite.Tag == null) { lastTextWrite.Write (text); return; } } } var qtw = new QueuedTextWrite (text, null); addQueuedUpdate (qtw); }
public void WriteTask(object task, string name, string status, List<TaskMessage> error, bool clearOutput) { if (clearOutput) Clear(); QueuedTextWrite qtw = new QueuedTextWrite(error); AddQueuedUpdate(qtw); }
public void WriteError(LogViewProgressMonitor monitor, string text) { var w = new QueuedTextWrite(monitor, text, errorTag); addQueuedUpdate(w); }
public void WriteTask_II(object task, string name, string status, List<TaskMessage> error, bool clearOutput) { if (clearOutput) Clear(); TaskResult tr = new TaskResult(name, status, error); //raw text has an extra optimisation here, as we can append it to existing updates /*lock (updates) { if (lastTextWrite != null) { if (lastTextWrite.Tag == null) { lastTextWrite.Write(tr); return; } } }*/ QueuedTextWrite qtw = new QueuedTextWrite(tr); AddQueuedUpdate(qtw); }
//mechanism to to batch copy text when large amounts are being dumped bool outputDispatchHandler () { lock (updates) { lastTextWrite = null; if (updates.Count == 0) { outputDispatcherRunning = false; return false; } if (!outputDispatcherRunning) { updates.Clear (); return false; } while (updates.Count > 0) { var up = updates.Dequeue (); up.Execute (this); } } return true; }
protected override void OnDestroyed() { base.OnDestroyed(); lock (updates) { updates.Clear(); lastTextWrite = null; } //IdeApp.Preferences.CustomOutputPadFontChanged -= HandleCustomFontChanged; if (customFont != null) { customFont.Dispose(); customFont = null; } }
void addQueuedUpdate (QueuedUpdate update) { lock (updates) { updates.Enqueue (update); if (!outputDispatcherRunning) { GLib.Timeout.Add (50, outputDispatcher); outputDispatcherRunning = true; } lastTextWrite = update as QueuedTextWrite; } }
public void WriteWarning(LogViewProgressMonitor monitor, string text) { var w = new QueuedTextWrite(monitor, text, warningTag); addQueuedUpdate(w); }