|
|
|
@ -81,9 +81,9 @@ namespace ICSharpCode.WpfDesign.Designer.Extensions |
|
|
|
{ |
|
|
|
{ |
|
|
|
InfoTextEnterArea.Stop(ref infoTextEnterArea); |
|
|
|
InfoTextEnterArea.Stop(ref infoTextEnterArea); |
|
|
|
|
|
|
|
|
|
|
|
this.ExtendedItem.Services.Selection.SetSelectedComponents(null); |
|
|
|
this.ExtendedItem.Services.Selection.SetSelectedComponents(null); |
|
|
|
this.ExtendedItem.Services.Selection.SetSelectedComponents(operation.PlacedItems.Select(x => x.Item).ToList()); |
|
|
|
this.ExtendedItem.Services.Selection.SetSelectedComponents(operation.PlacedItems.Select(x => x.Item).ToList()); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
public virtual Rect GetPosition(PlacementOperation operation, DesignItem item) |
|
|
|
public virtual Rect GetPosition(PlacementOperation operation, DesignItem item) |
|
|
|
{ |
|
|
|
{ |
|
|
|
@ -91,7 +91,7 @@ namespace ICSharpCode.WpfDesign.Designer.Extensions |
|
|
|
return Rect.Empty; |
|
|
|
return Rect.Empty; |
|
|
|
var p = item.View.TranslatePoint(new Point(), operation.CurrentContainer.View); |
|
|
|
var p = item.View.TranslatePoint(new Point(), operation.CurrentContainer.View); |
|
|
|
|
|
|
|
|
|
|
|
return new Rect(p, PlacementOperation.GetRealElementSize(item.View)); |
|
|
|
return new Rect(p, PlacementOperation.GetRealElementSize(item.View)); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
public virtual void BeforeSetPosition(PlacementOperation operation) |
|
|
|
public virtual void BeforeSetPosition(PlacementOperation operation) |
|
|
|
@ -100,8 +100,8 @@ namespace ICSharpCode.WpfDesign.Designer.Extensions |
|
|
|
|
|
|
|
|
|
|
|
public virtual void SetPosition(PlacementInformation info) |
|
|
|
public virtual void SetPosition(PlacementInformation info) |
|
|
|
{ |
|
|
|
{ |
|
|
|
if (info.Operation.Type != PlacementType.Move) |
|
|
|
if (info.Operation.Type != PlacementType.Move) |
|
|
|
ModelTools.Resize(info.Item, info.Bounds.Width, info.Bounds.Height); |
|
|
|
ModelTools.Resize(info.Item, info.Bounds.Width, info.Bounds.Height); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
public virtual bool CanLeaveContainer(PlacementOperation operation) |
|
|
|
public virtual bool CanLeaveContainer(PlacementOperation operation) |
|
|
|
@ -164,8 +164,8 @@ namespace ICSharpCode.WpfDesign.Designer.Extensions |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
if (ExtendedItem.ContentProperty.ReturnType == typeof(string)) |
|
|
|
if (ExtendedItem.ContentProperty.ReturnType == typeof(string)) |
|
|
|
return false; |
|
|
|
return false; |
|
|
|
|
|
|
|
|
|
|
|
if (!ExtendedItem.ContentProperty.IsSet) |
|
|
|
if (!ExtendedItem.ContentProperty.IsSet) |
|
|
|
return true; |
|
|
|
return true; |
|
|
|
|