public void AddLogMessage(LogMessage logMessage) { if (lastRevision < 0) lastRevision = logMessage.Revision; ListViewItem newItem = new ListViewItem(new string[] { logMessage.Revision.ToString(), logMessage.Author, logMessage.Date.ToString(), logMessage.Message }); newItem.Tag = logMessage; revisionListView.Items.Add(newItem); }
public void Log(string[] paths, Revision start, Revision end, int limit, bool discoverChangePaths, bool strictNodeHistory, Action<LogMessage> logMessageReceiver) { Debug("SVN: Log({" + string.Join(",", paths) + "}, " + start + ", " + end + ", " + limit + ", " + discoverChangePaths + ", " + strictNodeHistory + ")"); BeforeOperation("log"); try { client.Log( paths, new SvnLogArgs { Start = start, End = end, Limit = limit, RetrieveChangedPaths = discoverChangePaths, StrictNodeHistory = strictNodeHistory }, delegate (object sender, SvnLogEventArgs e) { try { Debug("SVN: Log: Got revision " + e.Revision); LogMessage msg = new LogMessage() { Revision = e.Revision, Author = e.Author, Date = e.Time, Message = e.LogMessage }; if (discoverChangePaths) { msg.ChangedPaths = new List<ChangedPath>(); foreach (var entry in e.ChangedPaths) { msg.ChangedPaths.Add(new ChangedPath { Path = entry.Path, CopyFromPath = entry.CopyFromPath, CopyFromRevision = entry.CopyFromRevision, Action = entry.Action }); } } logMessageReceiver(msg); } catch (Exception ex) { MessageService.ShowError(ex); } } ); Debug("SVN: Log finished"); } catch (SvnOperationCanceledException) { // allow cancel without exception } catch (SvnException ex) { throw new SvnClientException(ex); } finally { AfterOperation(); } }
void ReceiveAllChangedPaths(LogMessage logMessage) { SD.MainThread.InvokeAsyncAndForget(() => this.ReceiveAllChangedPathsInvoked(logMessage)); }
void ReceiveAllChangedPathsInvoked(LogMessage logMessage) { foreach (ListViewItem item in revisionListView.Items) { LogMessage oldMessage = (LogMessage)item.Tag; if (oldMessage.Revision == logMessage.Revision) { item.Tag = logMessage; break; } } }
void ReceiveChangedPaths(LogMessage logMessage) { loadChangedPathsItem.Tag = logMessage; }
public void AddLogMessage(LogMessage logMessage) { ListViewItem newItem = new ListViewItem(new string[] { logMessage.Revision.ToString(), logMessage.Author, logMessage.Date.ToString(), logMessage.Message }); newItem.Tag = Revision.FromNumber(logMessage.Revision); leftListView.Items.Add(newItem); ListViewItem newItem2 = new ListViewItem(new string[] { logMessage.Revision.ToString(), logMessage.Author, logMessage.Date.ToString(), logMessage.Message }); newItem2.Tag = Revision.FromNumber(logMessage.Revision); rightListView.Items.Add(newItem2); }
void ReceiveLogMessage(LogMessage logMessage) { if (infoPanel != null) { SD.MainThread.InvokeAsyncAndForget(() => infoPanel.AddLogMessage(logMessage)); } // if (diffPanel != null) { // WorkbenchSingleton.SafeThreadAsyncCall(diffPanel.AddLogMessage, logMessage); // } }
void ReceiveLogMessage(LogMessage logMessage) { if (infoPanel != null) { WorkbenchSingleton.SafeThreadAsyncCall(infoPanel.AddLogMessage, logMessage); } if (diffPanel != null) { WorkbenchSingleton.SafeThreadAsyncCall(diffPanel.AddLogMessage, logMessage); } }
void ReceiveAllChangedPaths(LogMessage logMessage) { WorkbenchSingleton.SafeThreadAsyncCall(this.ReceiveAllChangedPathsInvoked, logMessage); }