Browse Source

Fixed SD-318 and SD-347. Many small changes.

git-svn-id: svn://svn.sharpdevelop.net/sharpdevelop/trunk@93 1ccf3a8d-04fe-1044-b7c0-cef0b8235c61
shortcuts
Daniel Grunwald 21 years ago
parent
commit
8f0d6da9ad
  1. 2
      data/resources/image/BitmapResources/ResAsm.exe.config
  2. 2
      data/resources/image/BitmapResources/build.bat
  3. 3
      src/AddIns/BackendBindings/CSharpBinding/Project/Src/Parser/ExpressionFinder.cs
  4. 2
      src/AddIns/Misc/Debugger/Debugger.AddIn/Project/Src/Service/ExceptionForm.cs
  5. 3
      src/Libraries/ICSharpCode.TextEditor/Project/Src/Document/MarkerStrategy/MarkerStrategy.cs
  6. 5
      src/Libraries/ICSharpCode.TextEditor/Project/Src/Gui/TextEditorControlBase.cs
  7. 15
      src/Libraries/ICSharpCode.TextEditor/Project/Src/Gui/TextView.cs
  8. 1
      src/Main/Base/Project/Src/Gui/Components/ExtTreeView/ExtTreeView.cs
  9. 2
      src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/AssemblyReferencePanel.cs
  10. 3
      src/Main/Base/Project/Src/Internal/Auswerter/WindowActiveAuswerter.cs
  11. 6
      src/Main/Base/Project/Src/Services/Tasks/Task.cs
  12. 3
      src/build.bat
  13. 3
      src/clean.bat
  14. 3
      src/releasebuild.bat

2
data/resources/image/BitmapResources/ResAsm.exe.config

@ -3,7 +3,7 @@
<appSettings/> <appSettings/>
<startup> <startup>
<supportedRuntime version="v2.0.41115" /> <supportedRuntime version="v2.0.50215" />
</startup> </startup>
<!-- <!--

2
data/resources/image/BitmapResources/build.bat

@ -1,5 +1,3 @@
@echo off
resasm BitmapResources.res resasm BitmapResources.res
move BitmapResources.resources ..\..\SharpDevelop\Src\Main\StartUp\Project\Resources\BitmapResources.resources move BitmapResources.resources ..\..\SharpDevelop\Src\Main\StartUp\Project\Resources\BitmapResources.resources
pause pause

3
src/AddIns/BackendBindings/CSharpBinding/Project/Src/Parser/ExpressionFinder.cs

@ -30,6 +30,9 @@ namespace CSharpBinding.Parser
} }
} }
if (lastAccept < 0)
return null;
return this.text.Substring(this.lastAccept + 1, offset - this.lastAccept); return this.text.Substring(this.lastAccept + 1, offset - this.lastAccept);
} }

2
src/AddIns/Misc/Debugger/Debugger.AddIn/Project/Src/Service/ExceptionForm.cs

@ -1,5 +1,5 @@
// <file> // <file>
// <owner name="David Srbecký" email="dsrbecky@post.cz"/> // <owner name="David Srbeck" email="dsrbecky@post.cz"/>
// </file> // </file>
using System; using System;

3
src/Libraries/ICSharpCode.TextEditor/Project/Src/Document/MarkerStrategy/MarkerStrategy.cs

@ -75,9 +75,8 @@ namespace ICSharpCode.TextEditor.Document
public List<TextMarker> GetMarkers(Point position) public List<TextMarker> GetMarkers(Point position)
{ {
List<TextMarker> markers = new List<TextMarker>();
if (position.Y >= document.TotalNumberOfLines || position.Y < 0) { if (position.Y >= document.TotalNumberOfLines || position.Y < 0) {
return markers; return new List<TextMarker>();
} }
LineSegment segment = document.GetLineSegment(position.Y); LineSegment segment = document.GetLineSegment(position.Y);
return GetMarkers(segment.Offset + position.X); return GetMarkers(segment.Offset + position.X);

5
src/Libraries/ICSharpCode.TextEditor/Project/Src/Gui/TextEditorControlBase.cs

@ -667,10 +667,7 @@ namespace ICSharpCode.TextEditor
try { try {
if (File.Exists(fileName)) { if (File.Exists(fileName)) {
string backupName = fileName + ".bak"; string backupName = fileName + ".bak";
if (File.Exists(backupName)) { File.Copy(fileName, backupName, true);
File.Delete(backupName);
}
File.Copy(fileName, backupName);
} }
} catch (Exception) { } catch (Exception) {
// //

15
src/Libraries/ICSharpCode.TextEditor/Project/Src/Gui/TextView.cs

@ -1,7 +1,7 @@
// <file> // <file>
// <copyright see="prj:///doc/copyright.txt"/> // <copyright see="prj:///doc/copyright.txt"/>
// <license see="prj:///doc/license.txt"/> // <license see="prj:///doc/license.txt"/>
// <owner name="Mike Krüger" email="mike@icsharpcode.net"/> // <owner name="Mike Krger" email="mike@icsharpcode.net"/>
// <version value="$version"/> // <version value="$version"/>
// </file> // </file>
@ -306,10 +306,11 @@ namespace ICSharpCode.TextEditor
/// </summary> /// </summary>
/// <param name="offset">The offset.</param> /// <param name="offset">The offset.</param>
/// <param name="length">The length.</param> /// <param name="length">The length.</param>
/// <param name="markers">All markers that have been found.</param>
/// <returns>The Brush or null when no marker was found.</returns> /// <returns>The Brush or null when no marker was found.</returns>
Brush GetMarkerBrushAt(int offset, int length, ref Color foreColor) Brush GetMarkerBrushAt(int offset, int length, ref Color foreColor, out List<TextMarker> markers)
{ {
List<TextMarker> markers = Document.MarkerStrategy.GetMarkers(offset, length); markers = Document.MarkerStrategy.GetMarkers(offset, length);
foreach (TextMarker marker in markers) { foreach (TextMarker marker in markers) {
if (marker.TextMarkerType == TextMarkerType.SolidBlock) { if (marker.TextMarkerType == TextMarkerType.SolidBlock) {
if (marker.OverrideForeColor) { if (marker.OverrideForeColor) {
@ -392,7 +393,7 @@ namespace ICSharpCode.TextEditor
if (ColumnRange.WholeColumn.Equals(selectionRange) || logicalColumn >= selectionRange.StartColumn && logicalColumn < selectionRange.EndColumn) { if (ColumnRange.WholeColumn.Equals(selectionRange) || logicalColumn >= selectionRange.StartColumn && logicalColumn < selectionRange.EndColumn) {
spaceBackgroundBrush = selectionBackgroundBrush; spaceBackgroundBrush = selectionBackgroundBrush;
} else { } else {
Brush markerBrush = GetMarkerBrushAt(currentLine.Offset + logicalColumn, 1, ref spaceMarkerForeColor); Brush markerBrush = GetMarkerBrushAt(currentLine.Offset + logicalColumn, 1, ref spaceMarkerForeColor, out markers);
if (!drawLineMarker && markerBrush != null) { if (!drawLineMarker && markerBrush != null) {
spaceBackgroundBrush = markerBrush; spaceBackgroundBrush = markerBrush;
} else if (!drawLineMarker && currentWord.SyntaxColor != null && currentWord.SyntaxColor.HasBackground) { } else if (!drawLineMarker && currentWord.SyntaxColor != null && currentWord.SyntaxColor.HasBackground) {
@ -428,7 +429,7 @@ namespace ICSharpCode.TextEditor
if (ColumnRange.WholeColumn.Equals(selectionRange) || logicalColumn >= selectionRange.StartColumn && logicalColumn <= selectionRange.EndColumn - 1) { if (ColumnRange.WholeColumn.Equals(selectionRange) || logicalColumn >= selectionRange.StartColumn && logicalColumn <= selectionRange.EndColumn - 1) {
spaceBackgroundBrush = selectionBackgroundBrush; spaceBackgroundBrush = selectionBackgroundBrush;
} else { } else {
Brush markerBrush = GetMarkerBrushAt(currentLine.Offset + logicalColumn, 1, ref tabMarkerForeColor); Brush markerBrush = GetMarkerBrushAt(currentLine.Offset + logicalColumn, 1, ref tabMarkerForeColor, out markers);
if (!drawLineMarker && markerBrush != null) { if (!drawLineMarker && markerBrush != null) {
spaceBackgroundBrush = markerBrush; spaceBackgroundBrush = markerBrush;
} else if (!drawLineMarker && currentWord.SyntaxColor != null && currentWord.SyntaxColor.HasBackground) { } else if (!drawLineMarker && currentWord.SyntaxColor != null && currentWord.SyntaxColor.HasBackground) {
@ -457,7 +458,7 @@ namespace ICSharpCode.TextEditor
float lastPos = physicalXPos; float lastPos = physicalXPos;
Color wordForeColor = currentWord.Color; Color wordForeColor = currentWord.Color;
Brush bgMarkerBrush = GetMarkerBrushAt(currentLine.Offset + logicalColumn, word.Length, ref wordForeColor); Brush bgMarkerBrush = GetMarkerBrushAt(currentLine.Offset + logicalColumn, word.Length, ref wordForeColor, out markers);
Brush wordBackgroundBrush; Brush wordBackgroundBrush;
if (!drawLineMarker && bgMarkerBrush != null) { if (!drawLineMarker && bgMarkerBrush != null) {
wordBackgroundBrush = bgMarkerBrush; wordBackgroundBrush = bgMarkerBrush;
@ -530,7 +531,7 @@ namespace ICSharpCode.TextEditor
logicalColumn += word.Length; logicalColumn += word.Length;
break; break;
} }
markers.Clear(); //markers.Clear();
} }
} }

1
src/Main/Base/Project/Src/Gui/Components/ExtTreeView/ExtTreeView.cs

@ -164,6 +164,7 @@ namespace ICSharpCode.SharpDevelop.Gui
base.OnKeyPress(e); base.OnKeyPress(e);
if (e.KeyChar == '\r') { if (e.KeyChar == '\r') {
ActivateSelectedItem(); ActivateSelectedItem();
e.Handled = true;
} }
} }

2
src/Main/Base/Project/Src/Gui/Dialogs/ReferenceDialog/AssemblyReferencePanel.cs

@ -58,7 +58,7 @@ namespace ICSharpCode.SharpDevelop.Gui
public void AddReference(object sender, EventArgs e) public void AddReference(object sender, EventArgs e)
{ {
MessageBox.Show("This panel will contain a file browser, but so long use the browse button :)"); SelectReferenceDialog(null, null);
} }
} }
} }

3
src/Main/Base/Project/Src/Internal/Auswerter/WindowActiveAuswerter.cs

@ -16,9 +16,6 @@ namespace ICSharpCode.Core
{ {
public class WindowActiveAuswerter : IAuswerter public class WindowActiveAuswerter : IAuswerter
{ {
Type prevType = null;
bool prevValidFlag = false;
public bool IsValid(object caller, Condition condition) public bool IsValid(object caller, Condition condition)
{ {
if (WorkbenchSingleton.Workbench == null) { if (WorkbenchSingleton.Workbench == null) {

6
src/Main/Base/Project/Src/Services/Tasks/Task.cs

@ -81,6 +81,12 @@ namespace ICSharpCode.Core
} }
} }
public Task(string fileName, string description, int column, int line, TaskType type, IProject project)
: this(fileName, description, column, line, type)
{
this.project = project;
}
public Task(string fileName, string description, int column, int line, TaskType type) public Task(string fileName, string description, int column, int line, TaskType type)
{ {
this.type = type; this.type = type;

3
src/build.bat

@ -1,3 +1,2 @@
@ECHO OFF
%windir%\microsoft.net\framework\v2.0.50215\msbuild %windir%\microsoft.net\framework\v2.0.50215\msbuild
IF %ERRORLEVEL% NEQ 0 PAUSE @IF %ERRORLEVEL% NEQ 0 PAUSE

3
src/clean.bat

@ -1,3 +1,2 @@
@ECHO OFF
%windir%\microsoft.net\framework\v2.0.50215\msbuild /t:clean %windir%\microsoft.net\framework\v2.0.50215\msbuild /t:clean
IF %ERRORLEVEL% NEQ 0 PAUSE @IF %ERRORLEVEL% NEQ 0 PAUSE

3
src/releasebuild.bat

@ -1,3 +1,2 @@
@ECHO OFF
%windir%\microsoft.net\framework\v2.0.50215\msbuild /property:Configuration=Release %windir%\microsoft.net\framework\v2.0.50215\msbuild /property:Configuration=Release
IF %ERRORLEVEL% NEQ 0 PAUSE @IF %ERRORLEVEL% NEQ 0 PAUSE
Loading…
Cancel
Save