Browse Source

fix some more warnings

pull/80/head
Siegfried Pammer 12 years ago
parent
commit
293307cb9f
  1. 2
      src/AddIns/Analysis/CodeCoverage/Project/Src/ShowDisplayOptionsDropDown.cs
  2. 4
      src/AddIns/DisplayBindings/WpfDesign/WpfDesign.Designer/Project/Controls/CanvasPositionHandle.cs
  3. 14
      src/AddIns/DisplayBindings/WpfDesign/WpfDesign.Designer/Project/Controls/RotateThumb.cs
  4. 11
      src/AddIns/DisplayBindings/WpfDesign/WpfDesign.Designer/Project/Extensions/RenderTransformOriginExtension.cs
  5. 45
      src/AddIns/DisplayBindings/WpfDesign/WpfDesign.XamlDom/Project/DesignTimeProperties.cs
  6. 6
      src/AddIns/DisplayBindings/WpfDesign/WpfDesign/Project/Adorners/AdornerPanel.cs
  7. 4
      src/AddIns/Misc/Reports/ICSharpCode.Reports.Core/Project/BaseClasses/SortColumn.cs

2
src/AddIns/Analysis/CodeCoverage/Project/Src/ShowDisplayOptionsDropDown.cs

@ -10,7 +10,7 @@ namespace ICSharpCode.CodeCoverage @@ -10,7 +10,7 @@ namespace ICSharpCode.CodeCoverage
{
public class ShowDisplayOptionsDropDown : AbstractMenuCommand
{
ToolBarDropDownButton dropDownButton;
// ToolBarDropDownButton dropDownButton;
public override void Run()
{

4
src/AddIns/DisplayBindings/WpfDesign/WpfDesign.Designer/Project/Controls/CanvasPositionHandle.cs

@ -47,7 +47,7 @@ namespace ICSharpCode.WpfDesign.Designer.Controls @@ -47,7 +47,7 @@ namespace ICSharpCode.WpfDesign.Designer.Controls
readonly FrameworkElement adornedControl;
/// <summary> This grid contains the handle line and the endarrow.</summary>
Grid lineArrow;
// Grid lineArrow;
private DependencyPropertyDescriptor leftDescriptor;
private DependencyPropertyDescriptor rightDescriptor;
@ -114,7 +114,7 @@ namespace ICSharpCode.WpfDesign.Designer.Controls @@ -114,7 +114,7 @@ namespace ICSharpCode.WpfDesign.Designer.Controls
}
/// <summary>
/// Binds the <see cref="HandleLength"/> to the margin and place the handles.
/// Binds the <see cref="MarginHandle.HandleLength"/> to the margin and place the handles.
/// </summary>
void BindAndPlaceHandle()
{

14
src/AddIns/DisplayBindings/WpfDesign/WpfDesign.Designer/Project/Controls/RotateThumb.cs

@ -17,13 +17,13 @@ namespace ICSharpCode.WpfDesign.Designer.Controls @@ -17,13 +17,13 @@ namespace ICSharpCode.WpfDesign.Designer.Controls
{
public class RotateThumb : ResizeThumb
{
private double initialAngle;
private RotateTransform rotateTransform;
private Vector startVector;
private Point centerPoint;
private Control designerItem;
private Panel canvas;
private AdornerPanel parent;
// private double initialAngle;
// private RotateTransform rotateTransform;
// private Vector startVector;
// private Point centerPoint;
// private Control designerItem;
// private Panel canvas;
// private AdornerPanel parent;
static RotateThumb()
{

11
src/AddIns/DisplayBindings/WpfDesign/WpfDesign.Designer/Project/Extensions/RenderTransformOriginExtension.cs

@ -24,9 +24,9 @@ namespace ICSharpCode.WpfDesign.Designer.Extensions @@ -24,9 +24,9 @@ namespace ICSharpCode.WpfDesign.Designer.Extensions
RenderTransformOriginThumb renderTransformOriginThumb;
/// <summary>An array containing this.ExtendedItem as only element</summary>
readonly DesignItem[] extendedItemArray = new DesignItem[1];
IPlacementBehavior resizeBehavior;
PlacementOperation operation;
ChangeGroup changeGroup;
// IPlacementBehavior resizeBehavior;
// PlacementOperation operation;
// ChangeGroup changeGroup;
public RenderTransformOriginExtension()
{
@ -52,18 +52,19 @@ namespace ICSharpCode.WpfDesign.Designer.Extensions @@ -52,18 +52,19 @@ namespace ICSharpCode.WpfDesign.Designer.Extensions
void renderTransformOriginThumb_DragCompleted(object sender, DragCompletedEventArgs e)
{
this.ExtendedItem.Properties.GetProperty(FrameworkElement.RenderTransformOriginProperty).SetValue(new Point(Math.Round(renderTransformOrigin.X, 4), Math.Round(renderTransformOrigin.Y, 4)));
ExtendedItem.Properties.GetProperty(UIElement.RenderTransformOriginProperty).SetValue(new Point(Math.Round(renderTransformOrigin.X, 4), Math.Round(renderTransformOrigin.Y, 4)));
}
void renderTransformOriginThumb_DragDelta(object sender, DragDeltaEventArgs e)
{
var p = AdornerPanel.GetPlacement(renderTransformOriginThumb) as RelativePlacement;
if (p == null) return;
var pointAbs = adornerPanel.RelativeToAbsolute(new Vector(p.XRelativeToContentWidth, p.YRelativeToContentHeight));
var pointAbsNew = pointAbs + new Vector(e.HorizontalChange, e.VerticalChange);
var pRel = adornerPanel.AbsoluteToRelative(pointAbsNew);
renderTransformOrigin = new Point(pRel.X, pRel.Y);
this.ExtendedItem.View.SetValue(FrameworkElement.RenderTransformOriginProperty, renderTransformOrigin);
this.ExtendedItem.View.SetValue(UIElement.RenderTransformOriginProperty, renderTransformOrigin);
//this.ExtendedItem.Properties.GetProperty(FrameworkElement.RenderTransformOriginProperty).SetValue(new Point(Math.Round(pRel.X, 4), Math.Round(pRel.Y, 4)));
}

45
src/AddIns/DisplayBindings/WpfDesign/WpfDesign.XamlDom/Project/DesignTimeProperties.cs

@ -1,7 +1,6 @@ @@ -1,7 +1,6 @@
// Copyright (c) AlphaSierraPapa for the SharpDevelop Team (for details please see \doc\copyright.txt)
// This code is distributed under the GNU LGPL (for details please see \doc\license.txt)
using System.Security.Cryptography;
using System.Windows;
namespace ICSharpCode.WpfDesign.XamlDom
@ -9,12 +8,12 @@ namespace ICSharpCode.WpfDesign.XamlDom @@ -9,12 +8,12 @@ namespace ICSharpCode.WpfDesign.XamlDom
/// <summary>
/// Helper Class for the Design Time Properties used by VS and Blend
/// </summary>
public class DesignTimeProperties : FrameworkElement
public static class DesignTimeProperties
{
#region IsHidden
/// <summary>
/// Getter for the <see cref="IsHiddenProperty"/>
/// Getter for <see cref="IsHiddenProperty"/>
/// </summary>
public static bool GetIsHidden(DependencyObject obj)
{
@ -22,7 +21,7 @@ namespace ICSharpCode.WpfDesign.XamlDom @@ -22,7 +21,7 @@ namespace ICSharpCode.WpfDesign.XamlDom
}
/// <summary>
/// Setter for the <see cref="IsHiddenProperty"/>
/// Setter for <see cref="IsHiddenProperty"/>
/// </summary>
public static void SetIsHidden(DependencyObject obj, bool value)
{
@ -40,7 +39,7 @@ namespace ICSharpCode.WpfDesign.XamlDom @@ -40,7 +39,7 @@ namespace ICSharpCode.WpfDesign.XamlDom
#region IsLocked
/// <summary>
/// Getter for the <see cref="IsLockedProperty"/>
/// Getter for <see cref="IsLockedProperty"/>
/// </summary>
public static bool GetIsLocked(DependencyObject obj)
{
@ -48,7 +47,7 @@ namespace ICSharpCode.WpfDesign.XamlDom @@ -48,7 +47,7 @@ namespace ICSharpCode.WpfDesign.XamlDom
}
/// <summary>
/// Setter for the <see cref="IsLockedProperty"/>
/// Setter for <see cref="IsLockedProperty"/>
/// </summary>
public static void SetIsLocked(DependencyObject obj, bool value)
{
@ -65,7 +64,7 @@ namespace ICSharpCode.WpfDesign.XamlDom @@ -65,7 +64,7 @@ namespace ICSharpCode.WpfDesign.XamlDom
#region DataContext
/// <summary>
/// Getter for the <see cref="DataContextProperty"/>
/// Getter for <see cref="DataContextProperty"/>
/// </summary>
public static object GetDataContext(DependencyObject obj)
{
@ -73,7 +72,7 @@ namespace ICSharpCode.WpfDesign.XamlDom @@ -73,7 +72,7 @@ namespace ICSharpCode.WpfDesign.XamlDom
}
/// <summary>
/// Setter for the <see cref="DataContextProperty"/>
/// Setter for <see cref="DataContextProperty"/>
/// </summary>
public static void SetDataContext(DependencyObject obj, bool value)
{
@ -90,7 +89,7 @@ namespace ICSharpCode.WpfDesign.XamlDom @@ -90,7 +89,7 @@ namespace ICSharpCode.WpfDesign.XamlDom
#region DesignSource
/// <summary>
/// Getter for the <see cref="DesignSourceProperty"/>
/// Getter for <see cref="DesignSourceProperty"/>
/// </summary>
public static object GetDesignSource(DependencyObject obj)
{
@ -98,7 +97,7 @@ namespace ICSharpCode.WpfDesign.XamlDom @@ -98,7 +97,7 @@ namespace ICSharpCode.WpfDesign.XamlDom
}
/// <summary>
/// Setter for the <see cref="DesignSourceProperty"/>
/// Setter for <see cref="DesignSourceProperty"/>
/// </summary>
public static void SetDesignSource(DependencyObject obj, bool value)
{
@ -115,7 +114,7 @@ namespace ICSharpCode.WpfDesign.XamlDom @@ -115,7 +114,7 @@ namespace ICSharpCode.WpfDesign.XamlDom
#region DesignWidth
/// <summary>
/// Getter for the <see cref="DesignWidthProperty"/>
/// Getter for <see cref="DesignWidthProperty"/>
/// </summary>
public static double GetDesignWidth(DependencyObject obj)
{
@ -123,7 +122,7 @@ namespace ICSharpCode.WpfDesign.XamlDom @@ -123,7 +122,7 @@ namespace ICSharpCode.WpfDesign.XamlDom
}
/// <summary>
/// Setter for the <see cref="DesignWidthProperty"/>
/// Setter for <see cref="DesignWidthProperty"/>
/// </summary>
public static void SetDesignWidth(DependencyObject obj, double value)
{
@ -135,12 +134,11 @@ namespace ICSharpCode.WpfDesign.XamlDom @@ -135,12 +134,11 @@ namespace ICSharpCode.WpfDesign.XamlDom
/// </summary>
public static readonly DependencyProperty DesignWidthProperty =
DependencyProperty.RegisterAttached("DesignWidth", typeof(double), typeof(DesignTimeProperties));
#endregion
#region DesignHeight
/// <summary>
/// Getter for the <see cref="DesignHeightProperty"/>
/// Getter for <see cref="DesignHeightProperty"/>
/// </summary>
public static double GetDesignHeight(DependencyObject obj)
{
@ -148,7 +146,7 @@ namespace ICSharpCode.WpfDesign.XamlDom @@ -148,7 +146,7 @@ namespace ICSharpCode.WpfDesign.XamlDom
}
/// <summary>
/// Setter for the <see cref="DesignHeightProperty"/>
/// Setter for <see cref="DesignHeightProperty"/>
/// </summary>
public static void SetDesignHeight(DependencyObject obj, double value)
{
@ -160,23 +158,30 @@ namespace ICSharpCode.WpfDesign.XamlDom @@ -160,23 +158,30 @@ namespace ICSharpCode.WpfDesign.XamlDom
/// </summary>
public static readonly DependencyProperty DesignHeightProperty =
DependencyProperty.RegisterAttached("DesignHeight", typeof(double), typeof(DesignTimeProperties));
#endregion
#region LayoutRounding
/// <summary>
/// Getter for <see cref="LayoutRoundingProperty"/>
/// </summary>
public static bool GetLayoutRounding(DependencyObject obj)
{
return (bool)obj.GetValue(DesignLayoutRounding);
return (bool)obj.GetValue(LayoutRoundingProperty);
}
/// <summary>
/// Setter for <see cref="LayoutRoundingProperty"/>
/// </summary>
public static void SetLayoutRounding(DependencyObject obj, bool value)
{
obj.SetValue(DesignLayoutRounding, value);
obj.SetValue(LayoutRoundingProperty, value);
}
public static readonly DependencyProperty DesignLayoutRounding =
/// <summary>
/// Design-time layout rounding
/// </summary>
public static readonly DependencyProperty LayoutRoundingProperty =
DependencyProperty.RegisterAttached("LayoutRounding", typeof(bool), typeof(DesignTimeProperties));
#endregion
}
}

6
src/AddIns/DisplayBindings/WpfDesign/WpfDesign/Project/Adorners/AdornerPanel.cs

@ -34,11 +34,17 @@ namespace ICSharpCode.WpfDesign.Adorners @@ -34,11 +34,17 @@ namespace ICSharpCode.WpfDesign.Adorners
return (AdornerPlacement)adorner.GetValue(PlacementProperty);
}
/// <summary>
/// Converts an absolute vector to a vector relative to the element adorned by this <see cref="AdornerPanel" />.
/// </summary>
public Vector AbsoluteToRelative(Vector absolute)
{
return new Vector(absolute.X / ((FrameworkElement) this._adornedElement).ActualWidth, absolute.Y / ((FrameworkElement) this._adornedElement).ActualHeight);
}
/// <summary>
/// Converts a vector relative to the element adorned by this <see cref="AdornerPanel" /> to an absolute vector.
/// </summary>
public Vector RelativeToAbsolute(Vector relative)
{
return new Vector(relative.X * ((FrameworkElement) this._adornedElement).ActualWidth, relative.Y * ((FrameworkElement) this._adornedElement).ActualHeight);

4
src/AddIns/Misc/Reports/ICSharpCode.Reports.Core/Project/BaseClasses/SortColumn.cs

@ -15,10 +15,6 @@ namespace ICSharpCode.Reports.Core @@ -15,10 +15,6 @@ namespace ICSharpCode.Reports.Core
/// </remarks>
public class SortColumn : AbstractColumn {
private ListSortDirection sortDirection = ListSortDirection.Ascending;
private bool caseSensitive;
public SortColumn():this(String.Empty,ListSortDirection.Ascending,typeof(System.String),false)
{
}

Loading…
Cancel
Save