Adding smart tags in VS2010 (or VS2008 for that matter) to my control makes VS crash.
The following designer is used for the action list:
internal class DataEditorDesigner : ComponentDesigner {
[...]
public override DesignerActionListCollection ActionLists {
get {
var lists = new DesignerActionListCollection();
lists.AddRange(base.ActionLists);
lists.Add(new DataEditorActionList(Component));
return lists;
}
}
}
internal class DataEditorActionList : DesignerActionList {
public DataEditorActionList(IComponent component) : base(component) {}
public override DesignerActionItemCollection GetSortedActionItems() {
var items = new DesignerActionItemCollection();
items.Add(new DesignerActionPropertyItem("DataSource", "Data Source:", "Data"));
items.Add(new DesignerActionMethodItem(this, "AddControl", "Add column..."));
return items;
}
private void AddControl() {
System.Windows.Forms.MessageBox.Show("dpa");
}
}
The DataSource property is declared as such:
[AttributeProvider(typeof (IListSource))]
[DefaultValue(null)]
public object DataSource {
[...]
Any ideas on how to debug it?