1
// Copyright (c) AlphaSierraPapa for the SharpDevelop Team (for details please see \doc\copyright.txt)
2
// This code is distributed under the GNU LGPL (for details please see \doc\license.txt)
5
using System.ComponentModel;
6
using System.ComponentModel.Design;
7
using System.Windows.Forms;
9
namespace ICSharpCode.Reports.Addin.Designer
12
/// Description of SmartTagTransactions.
14
public class SmartTagTransactions
17
IComponentChangeService changeService;
18
DesignerTransaction transaction;
20
DesignerActionList actionList;
22
public SmartTagTransactions(string transactionname,DesignerActionList list,Control ctrl)
25
this.actionList = list;
27
host = (IDesignerHost)this.actionList.GetService(typeof(IDesignerHost));
28
this.transaction = host.CreateTransaction(transactionname);
29
changeService = (IComponentChangeService)this.actionList.GetService(typeof(IComponentChangeService));
30
changeService.OnComponentChanging(ctrl,null);
37
changeService.OnComponentChanged (ctrl,null,null,null);
38
this.transaction.Commit();
39
DesignerActionUIService designerActionUISvc =
40
(DesignerActionUIService)this.actionList.GetService(typeof(DesignerActionUIService));
41
designerActionUISvc.Refresh(this.actionList.Component);