Browse Source

Prevent Boo forms designer from changing the type of fields to 'void'

git-svn-id: svn://svn.sharpdevelop.net/sharpdevelop/branches/3.0@4014 1ccf3a8d-04fe-1044-b7c0-cef0b8235c61
shortcuts
Daniel Grunwald 16 years ago
parent
commit
1b38904278
  1. 6
      src/AddIns/DisplayBindings/FormsDesigner/Project/Src/DesignerGenerator/AbstractDesignerGenerator.cs

6
src/AddIns/DisplayBindings/FormsDesigner/Project/Src/DesignerGenerator/AbstractDesignerGenerator.cs

@ -342,6 +342,12 @@ namespace ICSharpCode.FormsDesigner @@ -342,6 +342,12 @@ namespace ICSharpCode.FormsDesigner
// ignore type changes to untyped VB fields
return false;
}
if (newType.BaseType == "System.Void") {
// field types get replaced with System.Void if the type cannot be resolved
// (e.g. generic fields in the Boo designer which aren't converted to CodeDom)
// we'll ignore such type changes (fields should never have the type void)
return false;
}
ArrayReturnType oldArray = oldType.IsArrayReturnType ? oldType.CastToArrayReturnType() : null;
if (oldArray == null ^ newType.ArrayRank < 1)

Loading…
Cancel
Save