diff options
author | Michael Hutchinson <m.j.hutchinson@gmail.com> | 2011-11-08 21:57:22 +0400 |
---|---|---|
committer | Michael Hutchinson <m.j.hutchinson@gmail.com> | 2011-11-08 21:57:22 +0400 |
commit | 3d7a7f93a50819a5089e21bfedd332dc08d4f0ce (patch) | |
tree | 0956c7d9cd3c6d2cc7344398ea6fb182952a55be /main/src/addins/VersionControl | |
parent | e51679b1a150ba564ade1510f94e9c05c4e6fa65 (diff) | |
parent | ec035e02db5d9b6e9a2c2275d3145b44264dc546 (diff) |
Merge remote-tracking branch 'origin/master' into macgtk
Conflicts:
extras/GtkSourceViewEditor/MonoDevelop.SourceEditor.addin.xml
main/src/addins/MonoDevelop.AssemblyBrowser/MonoDevelop.AssemblyBrowser/AssemblyBrowserWidget.cs
main/src/core/Mono.Texteditor/Mono.TextEditor/GtkWorkarounds.cs
Diffstat (limited to 'main/src/addins/VersionControl')
10 files changed, 44 insertions, 51 deletions
diff --git a/main/src/addins/VersionControl/MonoDevelop.VersionControl.Git/MonoDevelop.VersionControl.Git.addin.xml b/main/src/addins/VersionControl/MonoDevelop.VersionControl.Git/MonoDevelop.VersionControl.Git.addin.xml index 07a656579b..0f956b4a76 100644 --- a/main/src/addins/VersionControl/MonoDevelop.VersionControl.Git/MonoDevelop.VersionControl.Git.addin.xml +++ b/main/src/addins/VersionControl/MonoDevelop.VersionControl.Git/MonoDevelop.VersionControl.Git.addin.xml @@ -6,16 +6,16 @@ url = "http://www.monodevelop.com/" description = "Git support for the Version Control Add-in" category = "Version Control" - version = "2.8.1"> + version = "2.8.2"> <Runtime> <Import assembly="MonoDevelop.VersionControl.Git.dll"/> </Runtime> <Dependencies> - <Addin id="Core" version="2.8.1"/> - <Addin id="Ide" version="2.8.1"/> - <Addin id="VersionControl" version="2.8.1"/> + <Addin id="Core" version="2.8.2"/> + <Addin id="Ide" version="2.8.2"/> + <Addin id="VersionControl" version="2.8.2"/> </Dependencies> <Extension path="/MonoDevelop/VersionControl/VersionControlSystems"> diff --git a/main/src/addins/VersionControl/MonoDevelop.VersionControl.Subversion.Unix/MonoDevelop.VersionControl.Subversion.Unix.addin.xml b/main/src/addins/VersionControl/MonoDevelop.VersionControl.Subversion.Unix/MonoDevelop.VersionControl.Subversion.Unix.addin.xml index 717c6c3c1c..89733b4fc4 100644 --- a/main/src/addins/VersionControl/MonoDevelop.VersionControl.Subversion.Unix/MonoDevelop.VersionControl.Subversion.Unix.addin.xml +++ b/main/src/addins/VersionControl/MonoDevelop.VersionControl.Subversion.Unix/MonoDevelop.VersionControl.Subversion.Unix.addin.xml @@ -6,13 +6,13 @@ url = "http://taubz.for.net/code/diff"
description = "Subversion support for Linux and MacOSX"
category = "Version Control"
- version = "2.8.1">
+ version = "2.8.2">
<Dependencies>
- <Addin id="Core" version="2.8.1"/>
- <Addin id="Ide" version="2.8.1"/>
- <Addin id="VersionControl" version="2.8.1"/>
- <Addin id="VersionControl.Subversion" version="2.8.1"/>
+ <Addin id="Core" version="2.8.2"/>
+ <Addin id="Ide" version="2.8.2"/>
+ <Addin id="VersionControl" version="2.8.2"/>
+ <Addin id="VersionControl.Subversion" version="2.8.2"/>
</Dependencies> <Extension path = "/MonoDevelop/VersionControl/VersionControlSystems">
diff --git a/main/src/addins/VersionControl/MonoDevelop.VersionControl.Subversion.Unix/MonoDevelop.VersionControl.Subversion.Unix/SvnClient.cs b/main/src/addins/VersionControl/MonoDevelop.VersionControl.Subversion.Unix/MonoDevelop.VersionControl.Subversion.Unix/SvnClient.cs index 4e0cc04613..f168a3c555 100644 --- a/main/src/addins/VersionControl/MonoDevelop.VersionControl.Subversion.Unix/MonoDevelop.VersionControl.Subversion.Unix/SvnClient.cs +++ b/main/src/addins/VersionControl/MonoDevelop.VersionControl.Subversion.Unix/MonoDevelop.VersionControl.Subversion.Unix/SvnClient.cs @@ -639,7 +639,8 @@ namespace MonoDevelop.VersionControl.Subversion.Unix IntPtr result_rev = IntPtr.Zero; IntPtr localpool = newpool (pool); try { - url = NormalizePath (url, localpool); + // Using Uri here because the normalization method doesn't remove the redundant port number when using https + url = NormalizePath (new Uri(url).ToString(), localpool); string npath = NormalizePath (path, localpool); CheckError (svn.client_checkout (result_rev, url, npath, ref rev, (recurse ? 1 :0), ctx, localpool)); } finally { diff --git a/main/src/addins/VersionControl/MonoDevelop.VersionControl.Subversion/MonoDevelop.VersionControl.Subversion.addin.xml b/main/src/addins/VersionControl/MonoDevelop.VersionControl.Subversion/MonoDevelop.VersionControl.Subversion.addin.xml index 9b3837be01..1c9c1694dd 100644 --- a/main/src/addins/VersionControl/MonoDevelop.VersionControl.Subversion/MonoDevelop.VersionControl.Subversion.addin.xml +++ b/main/src/addins/VersionControl/MonoDevelop.VersionControl.Subversion/MonoDevelop.VersionControl.Subversion.addin.xml @@ -7,12 +7,12 @@ description = "Subversion core engine"
category = "Version Control"
flags = "Hidden"
- version = "2.8.1">
+ version = "2.8.2">
<Dependencies>
- <Addin id="Core" version="2.8.1"/>
- <Addin id="Ide" version="2.8.1"/>
- <Addin id="VersionControl" version="2.8.1"/>
+ <Addin id="Core" version="2.8.2"/>
+ <Addin id="Ide" version="2.8.2"/>
+ <Addin id="VersionControl" version="2.8.2"/>
</Dependencies> <Extension path = "/MonoDevelop/Ide/Commands/VersionControl"> diff --git a/main/src/addins/VersionControl/MonoDevelop.VersionControl.Subversion/MonoDevelop.VersionControl.Subversion/SubversionRepository.cs b/main/src/addins/VersionControl/MonoDevelop.VersionControl.Subversion/MonoDevelop.VersionControl.Subversion/SubversionRepository.cs index 8062dac616..0e4cfe6b4a 100644 --- a/main/src/addins/VersionControl/MonoDevelop.VersionControl.Subversion/MonoDevelop.VersionControl.Subversion/SubversionRepository.cs +++ b/main/src/addins/VersionControl/MonoDevelop.VersionControl.Subversion/MonoDevelop.VersionControl.Subversion/SubversionRepository.cs @@ -230,6 +230,8 @@ namespace MonoDevelop.VersionControl.Subversion {
foreach (FilePath path in paths) {
if (IsVersioned (path) && File.Exists (path) && !Directory.Exists (path)) {
+ if (rootPath == null)
+ throw new UserException (GettextCatalog.GetString ("Project publishing failed. There is a stale .svn folder in the path '{0}'", path.ParentDirectory));
VersionInfo srcInfo = GetVersionInfo (path, false);
if (srcInfo.HasLocalChange (VersionStatus.ScheduledDelete)) {
// It is a file that was deleted. It can be restored now since it's going
diff --git a/main/src/addins/VersionControl/MonoDevelop.VersionControl/MonoDevelop.VersionControl.Views/BlameView.cs b/main/src/addins/VersionControl/MonoDevelop.VersionControl/MonoDevelop.VersionControl.Views/BlameView.cs index d39f273e51..656a2f2ab3 100644 --- a/main/src/addins/VersionControl/MonoDevelop.VersionControl/MonoDevelop.VersionControl.Views/BlameView.cs +++ b/main/src/addins/VersionControl/MonoDevelop.VersionControl/MonoDevelop.VersionControl.Views/BlameView.cs @@ -93,15 +93,10 @@ namespace MonoDevelop.VersionControl.Views { this.widget.Editor.Document.Redo (); } - - void IUndoHandler.BeginAtomicUndo () - { - this.widget.Editor.Document.BeginAtomicUndo (); - } - - void IUndoHandler.EndAtomicUndo () + + IDisposable IUndoHandler.OpenUndoGroup () { - this.widget.Editor.Document.EndAtomicUndo (); + return this.widget.Editor.OpenUndoGroup (); } bool IUndoHandler.EnableUndo { diff --git a/main/src/addins/VersionControl/MonoDevelop.VersionControl/MonoDevelop.VersionControl.Views/DiffView.cs b/main/src/addins/VersionControl/MonoDevelop.VersionControl/MonoDevelop.VersionControl.Views/DiffView.cs index ca36faf2e7..067aeb2520 100644 --- a/main/src/addins/VersionControl/MonoDevelop.VersionControl/MonoDevelop.VersionControl.Views/DiffView.cs +++ b/main/src/addins/VersionControl/MonoDevelop.VersionControl/MonoDevelop.VersionControl.Views/DiffView.cs @@ -156,14 +156,9 @@ namespace MonoDevelop.VersionControl.Views this.ComparisonWidget.OriginalEditor.Document.Redo (); } - void IUndoHandler.BeginAtomicUndo () + IDisposable IUndoHandler.OpenUndoGroup () { - this.ComparisonWidget.OriginalEditor.Document.BeginAtomicUndo (); - } - - void IUndoHandler.EndAtomicUndo () - { - this.ComparisonWidget.OriginalEditor.Document.EndAtomicUndo (); + return this.ComparisonWidget.OriginalEditor.OpenUndoGroup (); } bool IUndoHandler.EnableUndo { diff --git a/main/src/addins/VersionControl/MonoDevelop.VersionControl/MonoDevelop.VersionControl.Views/EditorCompareWidgetBase.cs b/main/src/addins/VersionControl/MonoDevelop.VersionControl/MonoDevelop.VersionControl.Views/EditorCompareWidgetBase.cs index 9a3fb20d01..b67178b913 100644 --- a/main/src/addins/VersionControl/MonoDevelop.VersionControl/MonoDevelop.VersionControl.Views/EditorCompareWidgetBase.cs +++ b/main/src/addins/VersionControl/MonoDevelop.VersionControl/MonoDevelop.VersionControl.Views/EditorCompareWidgetBase.cs @@ -627,23 +627,22 @@ namespace MonoDevelop.VersionControl.Views protected virtual void UndoChange (TextEditor fromEditor, TextEditor toEditor, Hunk hunk) { - toEditor.Document.BeginAtomicUndo (); - var start = toEditor.Document.GetLine (hunk.InsertStart); - int toOffset = start != null ? start.Offset : toEditor.Document.Length; - if (start != null && hunk.Inserted > 0) { - int line = Math.Min (hunk.InsertStart + hunk.Inserted - 1, toEditor.Document.LineCount); - var end = toEditor.Document.GetLine (line); - toEditor.Remove (start.Offset, end.EndOffset - start.Offset); - } - - if (hunk.Removed > 0) { - start = fromEditor.Document.GetLine (Math.Min (hunk.RemoveStart, fromEditor.Document.LineCount)); - int line = Math.Min (hunk.RemoveStart + hunk.Removed - 1, fromEditor.Document.LineCount); - var end = fromEditor.Document.GetLine (line); - toEditor.Insert (toOffset, start.Offset == end.EndOffset ? toEditor.EolMarker : fromEditor.Document.GetTextBetween (start.Offset, end.EndOffset)); + using (var undo = toEditor.OpenUndoGroup ()) { + var start = toEditor.Document.GetLine (hunk.InsertStart); + int toOffset = start != null ? start.Offset : toEditor.Document.Length; + if (start != null && hunk.Inserted > 0) { + int line = Math.Min (hunk.InsertStart + hunk.Inserted - 1, toEditor.Document.LineCount); + var end = toEditor.Document.GetLine (line); + toEditor.Remove (start.Offset, end.EndOffset - start.Offset); + } + + if (hunk.Removed > 0) { + start = fromEditor.Document.GetLine (Math.Min (hunk.RemoveStart, fromEditor.Document.LineCount)); + int line = Math.Min (hunk.RemoveStart + hunk.Removed - 1, fromEditor.Document.LineCount); + var end = fromEditor.Document.GetLine (line); + toEditor.Insert (toOffset, start.Offset == end.EndOffset ? toEditor.EolMarker : fromEditor.Document.GetTextBetween (start.Offset, end.EndOffset)); + } } - - toEditor.Document.EndAtomicUndo (); } class MiddleArea : DrawingArea diff --git a/main/src/addins/VersionControl/MonoDevelop.VersionControl/MonoDevelop.VersionControl.Views/MergeWidget.cs b/main/src/addins/VersionControl/MonoDevelop.VersionControl/MonoDevelop.VersionControl.Views/MergeWidget.cs index f9a87a1525..25b03dbbb5 100644 --- a/main/src/addins/VersionControl/MonoDevelop.VersionControl/MonoDevelop.VersionControl.Views/MergeWidget.cs +++ b/main/src/addins/VersionControl/MonoDevelop.VersionControl/MonoDevelop.VersionControl.Views/MergeWidget.cs @@ -44,7 +44,7 @@ namespace MonoDevelop.VersionControl.Views { protected override TextEditor MainEditor { get { - return editors[1]; + return editors != null && editors.Length >= 2 ? editors[1] : null; } } @@ -96,7 +96,8 @@ namespace MonoDevelop.VersionControl.Views protected override void OnDestroyed () { base.OnDestroyed (); - MainEditor.Document.TextReplaced -= UpdateConflictsOnTextReplace; + if (MainEditor != null && MainEditor.Document != null) + MainEditor.Document.TextReplaced -= UpdateConflictsOnTextReplace; } public string GetResultText () diff --git a/main/src/addins/VersionControl/MonoDevelop.VersionControl/VersionControl.addin.xml b/main/src/addins/VersionControl/MonoDevelop.VersionControl/VersionControl.addin.xml index c467105df5..da12073cdf 100644 --- a/main/src/addins/VersionControl/MonoDevelop.VersionControl/VersionControl.addin.xml +++ b/main/src/addins/VersionControl/MonoDevelop.VersionControl/VersionControl.addin.xml @@ -7,7 +7,7 @@ description = "A MonoDevelop addin for using version control systems like Subversion" category = "Version Control" flags = "Hidden" - version = "2.8.1"> + version = "2.8.2"> <Runtime> <Import file="comment.png" /> @@ -24,9 +24,9 @@ </Runtime> <Dependencies> - <Addin id="Core" version="2.8.1"/> - <Addin id="Ide" version="2.8.1"/> - <Addin id="SourceEditor2" version="2.8.1"/> + <Addin id="Core" version="2.8.2"/> + <Addin id="Ide" version="2.8.2"/> + <Addin id="SourceEditor2" version="2.8.2"/> </Dependencies> <ExtensionPoint path = "/MonoDevelop/VersionControl/VersionControlSystems" name = "Version control systems"> |