Free cookie consent management tool by TermsFeed Policy Generator

source: trunk/sources/HeuristicLab.ExtLibs/HeuristicLab.Netron/3.0.2672.12446/Netron.Diagramming.Core-3.0.2672.12446/Declarations/Delegates/EventArguments.cs @ 2768

Last change on this file since 2768 was 2768, checked in by mkommend, 14 years ago

added solution folders and sources for the netron library (ticket #867)

File size: 28.4 KB
Line 
1using System;
2using System.Windows.Forms;
3using System.Drawing;
4using System.Collections.Generic;
5using System.IO;
6namespace Netron.Diagramming.Core
7{
8    #region PaintStyle EventArgs
9
10    // ----------------------------------------------------------------------
11    /// <summary>
12    /// Provides information about a PaintStyleChanged event.
13    /// </summary>
14    // ----------------------------------------------------------------------
15    public class PaintStyleChangedEventArgs : EventArgs
16    {
17        IPaintStyle mPaintStyle;
18        FillType mFillType;
19
20        // ------------------------------------------------------------------
21        /// <summary>
22        /// Gets the paint style that changed.
23        /// </summary>
24        // ------------------------------------------------------------------
25        public IPaintStyle PaintStyle
26        {
27            get
28            {
29                return mPaintStyle;
30            }
31        }
32
33        // ------------------------------------------------------------------
34        /// <summary>
35        /// Gets the new FillType.
36        /// </summary>
37        // ------------------------------------------------------------------
38        public FillType FillType
39        {
40            get
41            {
42                return mFillType;
43            }
44        }
45
46        // ------------------------------------------------------------------
47        /// <summary>
48        /// Constructor.
49        /// </summary>
50        /// <param name="paintStyle">IPaintStyle: The IPaintStyle that
51        /// changed.</param>
52        /// <param name="newFillType">FillType: The new fill type.</param>
53        // ------------------------------------------------------------------
54        public PaintStyleChangedEventArgs(
55            IPaintStyle paintStyle,
56            FillType newFillType)
57        {
58            mPaintStyle = paintStyle;
59            mFillType = newFillType;
60        }
61    }
62
63    #endregion
64
65    #region TextStyle EventArgs
66
67    // ----------------------------------------------------------------------
68    /// <summary>
69    /// Provides information about a TextStyleChanged event.
70    /// </summary>
71    // ----------------------------------------------------------------------
72    public class TextStyleChangedEventArgs : EventArgs
73    {
74        ITextStyle mTextStyle;
75
76        // ------------------------------------------------------------------
77        /// <summary>
78        /// Gets the text style that changed.
79        /// </summary>
80        // ------------------------------------------------------------------
81        public ITextStyle TextStyle
82        {
83            get
84            {
85                return mTextStyle;
86            }
87        }
88
89        // ------------------------------------------------------------------
90        /// <summary>
91        /// Constructor.
92        /// </summary>
93        /// <param name="textStyle">ITextStyle: The ITextStyle that
94        /// changed.</param>
95        // ------------------------------------------------------------------
96        public TextStyleChangedEventArgs(ITextStyle textStyle)
97        {
98            mTextStyle = textStyle;
99        }
100    }
101
102    #endregion
103
104    #region ConnectorAttachmentEventArgs
105    /// <summary>
106    /// Event argument on connecting a connection to a connector
107    /// </summary>
108    public sealed class ConnectorAttachmentEventArgs : EventArgs
109    {
110        /// <summary>
111        /// the child connector
112        /// </summary>
113        IConnector child;
114        /// <summary>
115        /// the parent connector
116        /// </summary>
117        IConnector parent;
118        /// <summary>
119        /// the actual connection
120        /// </summary>
121        IConnection connection;
122
123
124        /// <summary>
125        /// Gets the child connector.
126        /// </summary>
127        /// <value>The child.</value>
128        public IConnector Child
129        {
130            get
131            {
132                return child;
133            }
134        }
135
136        /// <summary>
137        /// Gets the parent connector.
138        /// </summary>
139        /// <value>The parent.</value>
140        public IConnector Parent
141        {
142            get
143            {
144                return parent;
145            }
146        }
147
148        /// <summary>
149        /// Gets the connection.
150        /// </summary>
151        /// <value>The connection.</value>
152        public IConnection Connection
153        {
154            get
155            {
156                return connection;
157            }
158        }
159
160        /// <summary>
161        /// Initializes a new instance of the <see cref="T:ConnectorAttachmentEventArgs"/> class.
162        /// </summary>
163        /// <param name="child">The child.</param>
164        /// <param name="parent">The parent.</param>
165        /// <param name="connection">The connection.</param>
166        public ConnectorAttachmentEventArgs(IConnector child, IConnector parent, IConnection connection)
167        {
168            this.child = child;
169            this.parent = parent;
170            this.connection = connection;
171        }
172    }
173    #endregion
174
175    #region EntityMenuEventArgs
176    /// <summary>
177    /// Event argument on creation of the contextmenu f an entity
178    /// </summary>
179    public sealed class EntityMenuEventArgs : EventArgs
180    {
181        #region Fields
182        /// <summary>
183        /// the entity
184        /// </summary>
185        private IDiagramEntity entity;
186        /// <summary>
187        /// the mouse event argument containing location etc.
188        /// </summary>
189        private MouseEventArgs e;
190        /// <summary>
191        /// the additional menu items to add
192        /// </summary>
193        private ToolStripItem[] additionalItems;
194        #endregion;
195
196        #region Properties
197        /// <summary>
198        /// Gets the entity.
199        /// </summary>
200        /// <value>The entity.</value>
201        public IDiagramEntity Entity
202        {
203            get
204            {
205                return entity;
206            }
207        }
208
209        /// <summary>
210        /// Gets the mouse event args.
211        /// </summary>
212        /// <value>The mouse event args.</value>
213        public MouseEventArgs MouseEventArgs
214        {
215            get
216            {
217                return e;
218            }
219        }
220
221        /// <summary>
222        /// Gets the additional items.
223        /// </summary>
224        /// <value>The additional items.</value>
225        public ToolStripItem[] AdditionalItems
226        {
227            get
228            {
229                return additionalItems;
230            }
231        }
232
233        #endregion
234
235        #region Constructor
236        /// <summary>
237        /// Initializes a new instance of the <see cref="T:EntityMenuEventArgs"/> class.
238        /// </summary>
239        /// <param name="entity">The entity.</param>
240        /// <param name="e">The <see cref="T:System.Windows.Forms.MouseEventArgs"/> instance containing the event data.</param>
241        /// <param name="additionalItems">The additional items.</param>
242        public EntityMenuEventArgs(
243            IDiagramEntity entity,
244            MouseEventArgs e,
245            ref ToolStripItem[] additionalItems)
246        {
247            this.entity = entity;
248            this.e = e;
249            this.additionalItems = additionalItems;
250        }
251        #endregion
252
253    }
254    #endregion
255
256    #region CursorEventArgs
257    /// <summary>
258    /// Cursor event argument
259    /// </summary>
260    public sealed class CursorEventArgs : EventArgs
261    {
262        /// <summary>
263        /// the Empty argument
264        /// </summary>
265        public static readonly new CursorEventArgs Empty = new CursorEventArgs();
266        /// <summary>
267        /// the Tool field
268        /// </summary>
269        private Cursor mCursor;
270        /// <summary>
271        /// Gets or sets the Cursor
272        /// </summary>
273        public Cursor Cursor
274        {
275            get
276            {
277                return mCursor;
278            }
279            set
280            {
281                mCursor = value;
282            }
283        }
284
285
286
287        #region Constructor
288        ///<summary>
289        ///Default constructor
290        ///</summary>
291        public CursorEventArgs(Cursor cursor)
292        {
293            this.mCursor = cursor;
294        }
295        /// <summary>
296        /// Initializes a new instance of the <see cref="T:CursorEventArgs"/> class.
297        /// </summary>
298        public CursorEventArgs()
299        {
300        }
301        #endregion
302
303    }
304    #endregion
305
306
307    #region CursorEventArgs
308    /// <summary>
309    /// Cursor event argument
310    /// </summary>
311    public sealed class ColorEventArgs : EventArgs
312    {
313        /// <summary>
314        /// the Empty argument
315        /// </summary>
316        public static readonly new CursorEventArgs Empty = new CursorEventArgs();
317        /// <summary>
318        /// the Color field
319        /// </summary>
320        private Color mColor;
321        /// <summary>
322        /// Gets or sets the Color
323        /// </summary>
324        public Color Color
325        {
326            get
327            {
328                return mColor;
329            }
330            set
331            {
332                mColor = value;
333            }
334        }
335
336        #region Constructor
337        ///<summary>
338        ///Default constructor
339        ///</summary>
340        public ColorEventArgs(Color color)
341        {
342            this.mColor = color;
343        }
344        /// <summary>
345        /// Initializes a new instance of the <see cref="T:CursorEventArgs"/> class.
346        /// </summary>
347        public ColorEventArgs()
348        {
349        }
350        #endregion
351
352    }
353    #endregion
354
355    #region PageEventArgs
356
357    // ----------------------------------------------------------------------
358    /// <summary>
359    /// Provides information about a page event (page added, current page
360    /// changed, etc.).
361    /// </summary>
362    // ----------------------------------------------------------------------
363    public sealed class PageEventArgs : EventArgs
364    {
365        // ------------------------------------------------------------------
366        /// <summary>
367        /// The page.
368        /// </summary>
369        // ------------------------------------------------------------------
370        IPage mPage;
371
372        // ------------------------------------------------------------------
373        /// <summary>
374        /// Gets the page for the event argument.
375        /// </summary>
376        // ------------------------------------------------------------------
377        public IPage Page
378        {
379            get
380            {
381                return mPage;
382            }
383        }
384
385        // ------------------------------------------------------------------
386        /// <summary>
387        /// Constructor.
388        /// </summary>
389        /// <param name="page">IPage</param>
390        // ------------------------------------------------------------------
391        public PageEventArgs(IPage page)
392        {
393            mPage = page;
394        }
395    }
396
397    #endregion
398
399    #region ToolEventArgs
400    /// <summary>
401    /// Tool event argument
402    /// </summary>
403    public sealed class ToolEventArgs : EventArgs
404    {
405
406        /// <summary>
407        /// the Tool field
408        /// </summary>
409        private ITool mTool;
410        /// <summary>
411        /// Gets or sets the Properties
412        /// </summary>
413        public ITool Properties
414        {
415            get
416            {
417                return mTool;
418            }
419            set
420            {
421                mTool = value;
422            }
423        }
424        /// <summary>
425        /// The empty argument.
426        /// </summary>
427        public static readonly new ToolEventArgs Empty = new ToolEventArgs();
428
429        #region Constructor
430        ///<summary>
431        ///Default constructor
432        ///</summary>
433        public ToolEventArgs(ITool tool)
434        {
435            this.mTool = tool;
436        }
437        /// <summary>
438        /// Initializes a new instance of the <see cref="T:ToolEventArgs"/> class.
439        /// </summary>
440        public ToolEventArgs()
441        {
442        }
443        #endregion
444
445    }
446    #endregion
447
448    #region PropertiesEventArgs
449    /// <summary>
450    /// Properties event argument
451    /// </summary>
452    public sealed class PropertiesEventArgs : EventArgs
453    {
454
455        /// <summary>
456        /// the Properties field
457        /// </summary>
458        private Document mProperties;
459        /// <summary>
460        /// Gets or sets the Properties
461        /// </summary>
462        public Document Properties
463        {
464            get
465            {
466                return mProperties;
467            }
468            set
469            {
470                mProperties = value;
471            }
472        }
473        /// <summary>
474        /// The empty argument.
475        /// </summary>
476        public static readonly new PropertiesEventArgs Empty = new PropertiesEventArgs();
477
478        #region Constructor
479        ///<summary>
480        ///Default constructor
481        ///</summary>
482        public PropertiesEventArgs(Document document)
483        {
484            this.mProperties = document;
485        }
486        /// <summary>
487        /// Initializes a new instance of the <see cref="T:PropertiesEventArgs"/> class.
488        /// </summary>
489        public PropertiesEventArgs()
490        {
491        }
492        #endregion
493
494    }
495    #endregion
496
497    #region AmbienceEventArgs
498    /// <summary>
499    /// Ambience event argument
500    /// </summary>
501    public sealed class AmbienceEventArgs : EventArgs
502    {
503
504
505        /// <summary>
506        /// the Ambience field
507        /// </summary>
508        private Ambience mAmbience;
509        /// <summary>
510        /// Gets or sets the Ambience
511        /// </summary>
512        public Ambience Ambience
513        {
514            get
515            {
516                return mAmbience;
517            }
518            set
519            {
520                mAmbience = value;
521            }
522        }
523
524        /// <summary>
525        /// The Empty event argument
526        /// </summary>
527        public static readonly new AmbienceEventArgs Empty = new AmbienceEventArgs();
528
529
530        #region Constructor
531        ///<summary>
532        ///Default constructor
533        ///</summary>
534        public AmbienceEventArgs()
535        {
536
537        }
538        /// <summary>
539        /// Initializes a new instance of the <see cref="T:AmbienceEventArgs"/> class.
540        /// </summary>
541        /// <param name="ambience">The ambience.</param>
542        public AmbienceEventArgs(Ambience ambience)
543        {
544            this.mAmbience = ambience;
545        }
546        #endregion
547
548    }
549    #endregion
550
551    #region ConnectionCollectionEventArgs
552    /// <summary>
553    /// ConnectionCollection event argument
554    /// </summary>
555    public sealed class ConnectionCollectionEventArgs : EventArgs
556    {
557
558        /// <summary>
559        /// the Connection field
560        /// </summary>
561        private IConnection mConnection;
562        /// <summary>
563        /// Gets or sets the Connection
564        /// </summary>
565        public IConnection Connection
566        {
567            get
568            {
569                return mConnection;
570            }
571            set
572            {
573                mConnection = value;
574            }
575        }
576
577        /// <summary>
578        /// The Empty event argument
579        /// </summary>
580        public static readonly new ConnectionCollectionEventArgs Empty = new ConnectionCollectionEventArgs();
581
582
583        #region Constructor
584        ///<summary>
585        ///Default constructor
586        ///</summary>
587        public ConnectionCollectionEventArgs()
588        {
589
590        }
591        /// <summary>
592        /// Initializes a new instance of the <see cref="T:ConnectionCollectionEventArgs"/> class.
593        /// </summary>
594        /// <param name="connection">The connection.</param>
595        public ConnectionCollectionEventArgs(IConnection connection)
596        {
597            this.mConnection = connection;
598        }
599        #endregion
600
601    }
602    #endregion
603
604    #region DiagramInformationEventArgs
605    /// <summary>
606    /// Event argument on passing diagram information (metdata)
607    /// </summary>
608    public sealed class DiagramInformationEventArgs : EventArgs
609    {
610
611        /// <summary>
612        /// the Information field
613        /// </summary>
614        private DocumentInformation mInformation;
615        /// <summary>
616        /// Gets or sets the Information
617        /// </summary>
618        public DocumentInformation Information
619        {
620            get
621            {
622                return mInformation;
623            }
624            set
625            {
626                mInformation = value;
627            }
628        }
629
630        #region Constructor
631        ///<summary>
632        ///Default constructor
633        ///</summary>
634        private DiagramInformationEventArgs()
635        {
636
637        }
638        /// <summary>
639        /// Initializes a new instance of the <see cref="T:DiagramInformationEventArgs"/> class.
640        /// </summary>
641        /// <param name="info">The info.</param>
642        public DiagramInformationEventArgs(DocumentInformation info)
643        {
644            this.mInformation = info;
645        }
646        #endregion
647        /// <summary>
648        /// The Empty event argument
649        /// </summary>
650        public static readonly new DiagramInformationEventArgs Empty = new DiagramInformationEventArgs();
651    }
652    #endregion
653
654    #region CollectionEventArgs
655    /// <summary>
656    /// Event argument to pass <see cref="CollectionBase"/> information via events
657    /// </summary>
658    /// <typeparam name="T"></typeparam>
659    public class CollectionEventArgs<T> : EventArgs
660    {
661        private T item;
662
663        /// <summary>
664        /// Gets the item.
665        /// </summary>
666        /// <value>The item.</value>
667        public T Item
668        {
669            get { return item; }
670        }
671        /// <summary>
672        /// Initializes a new instance of the <see cref="T:CollectionEventArgs&lt;T&gt;"/> class.
673        /// </summary>
674        /// <param name="item">A parameter of the generics Type T</param>
675        public CollectionEventArgs(T item)
676        {
677            this.item = item;
678        }
679    }
680    #endregion
681
682    #region RectangleEventArgs
683    /// <summary>
684    /// Event argument to pass <see cref="Rectangle"/> information via events
685    /// </summary>
686    public sealed class RectangleEventArgs : EventArgs
687    {
688        /// <summary>
689        /// the rectangle
690        /// </summary>
691        private Rectangle mRectangle;
692
693        /// <summary>
694        /// Gets the rectangle.
695        /// </summary>
696        /// <value>The rectangle.</value>
697        public Rectangle Rectangle
698        {
699            get
700            {
701                return mRectangle;
702            }
703        }
704        /// <summary>
705        /// The Empty event argument
706        /// </summary>
707        public static readonly new RectangleEventArgs Empty = new RectangleEventArgs();
708
709
710        #region Constructor
711        ///<summary>
712        ///Default constructor
713        ///</summary>
714        public RectangleEventArgs(Rectangle rectangle)
715        {
716            this.mRectangle = rectangle;
717        }
718        /// <summary>
719        /// Initializes a new instance of the <see cref="T:RectangleEventArgs"/> class.
720        /// </summary>
721        private RectangleEventArgs()
722        {
723        }
724        #endregion
725
726    }
727    #endregion
728
729    #region EntityEventArgs
730    /// <summary>
731    /// Event argument carrying an item
732    /// </summary>
733    public sealed class EntityEventArgs : EventArgs
734    {
735        /// <summary>
736        /// Gets or sets the entity
737        /// </summary>
738        IDiagramEntity mEntity;
739
740        /// <summary>
741        /// Gets or sets the entity.
742        /// </summary>
743        /// <value>The entity.</value>
744        public IDiagramEntity Entity
745        {
746            get
747            {
748                return mEntity;
749            }
750            set
751            {
752                mEntity = value;
753            }
754        }
755        /// <summary>
756        /// Default constructor
757        /// </summary>
758        /// <param name="entity"></param>
759        public EntityEventArgs(IDiagramEntity entity)
760        {
761            this.Entity = entity;
762        }
763    }
764    #endregion
765
766    #region EntityMouseEventArgs
767    /// <summary>
768    /// MouseEvent argument carrying an item
769    /// </summary>
770    public sealed class EntityMouseEventArgs : MouseEventArgs
771    {
772
773
774        /// <summary>
775        /// Gets or sets the entity
776        /// </summary>
777        IDiagramEntity mEntity;
778
779        /// <summary>
780        /// Gets or sets the entity.
781        /// </summary>
782        /// <value>The entity.</value>
783        public IDiagramEntity Entity
784        {
785            get
786            {
787                return mEntity;
788            }
789            set
790            {
791                mEntity = value;
792            }
793        }
794        /// <summary>
795        /// Default constructor
796        /// </summary>
797        /// <param name="entity">The entity.</param>
798        /// <param name="button">The button.</param>
799        /// <param name="clicks">The clicks.</param>
800        /// <param name="x">The x.</param>
801        /// <param name="y">The y.</param>
802        /// <param name="delta">The delta.</param>
803        public EntityMouseEventArgs(IDiagramEntity entity, MouseButtons button, int clicks, int x, int y, int delta)
804            : base(button, clicks, x, y, delta)
805        {
806            this.mEntity = entity;
807        }
808        /// <summary>
809        /// Initializes a new instance of the <see cref="T:EntityMouseEventArgs"/> class.
810        /// </summary>
811        /// <param name="entity">The entity.</param>
812        /// <param name="e">The <see cref="T:System.Windows.Forms.MouseEventArgs"/> instance containing the event data.</param>
813        public EntityMouseEventArgs(IDiagramEntity entity, MouseEventArgs e)
814            : base(e.Button, e.Clicks, e.X, e.Y, e.Delta)
815        {
816            if(e == null)
817                throw new ArgumentNullException("The argument object is 'null'");
818            this.mEntity = entity;
819        }
820    }
821    #endregion
822
823    #region StringEventArgs
824    /// <summary>
825    /// Contains a string event argument
826    /// </summary>
827    public sealed class StringEventArgs : EventArgs
828    {
829
830        string mData;
831        /// <summary>
832        /// Gets or sets the string data
833        /// </summary>
834        public string Data
835        {
836            get
837            {
838                return mData;
839            }
840
841        }
842        /// <summary>
843        /// Default constructor
844        /// </summary>
845        /// <param name="data"></param>
846        public StringEventArgs(string data)
847        {
848            this.mData = data;
849        }
850    }
851    #endregion
852
853    #region SingleDataEventArgs
854    /// <summary>
855    /// A single-bucket data transfer event argument
856    /// </summary>
857    /// <typeparam name="T"></typeparam>
858    public sealed class SingleDataEventArgs<T> : EventArgs
859    {
860        /// <summary>
861        /// whatever data
862        /// </summary>
863        T mData;
864
865        /// <summary>
866        /// Gets the data.
867        /// </summary>
868        /// <value>The data.</value>
869        public T Data
870        {
871            get
872            {
873                return mData;
874            }
875        }
876
877        /// <summary>
878        /// Initializes a new instance of the <see cref="T:SingleDataEventArgs&lt;T&gt;"/> class.
879        /// </summary>
880        /// <param name="data">A parameter of the generics Type T</param>
881        public SingleDataEventArgs(T data)
882        {
883            //if (data is default(T))
884            //    throw new ArgumentNullException("The argument does not contain any data.");
885
886            this.mData = data;
887        }
888    }
889
890    #endregion
891
892    #region HistoryChangeEventArgs
893
894    /// <summary>
895    /// Event argument to communicate history changes in the undo/redo mechanism
896    /// </summary>
897    public sealed class HistoryChangeEventArgs : EventArgs
898    {
899        /// <summary>
900        /// the RedoText field
901        /// </summary>
902        private string mRedoText;
903        /// <summary>
904        /// Gets or sets the RedoText
905        /// </summary>
906        public string RedoText
907        {
908            get
909            {
910                return mRedoText;
911            }
912            set
913            {
914                mRedoText = value;
915            }
916        }
917
918        /// <summary>
919        /// the UndoText field
920        /// </summary>
921        private string mUndoText;
922        /// <summary>
923        /// Gets or sets the UndoText
924        /// </summary>
925        public string UndoText
926        {
927            get
928            {
929                return mUndoText;
930            }
931            set
932            {
933                mUndoText = value;
934            }
935        }
936
937        #region Constructor
938        ///<summary>
939        ///Default constructor
940        ///</summary>
941        public HistoryChangeEventArgs(string redoText, string undoText)
942        {
943            this.mRedoText = redoText;
944            this.mUndoText = undoText;
945        }
946
947        #endregion
948
949    }
950    #endregion
951
952    #region SelectionEventArgs
953    /// <summary>
954    /// Properties event argument
955    /// </summary>
956    public sealed class SelectionEventArgs : EventArgs
957    {
958        /// <summary>
959        /// the Properties field
960        /// </summary>
961        private object[] mObjects;
962        /// <summary>
963        /// Gets or sets the selected objects
964        /// </summary>
965        public object[] SelectedObjects
966        {
967            get
968            {
969                return mObjects;
970            }
971            set
972            {
973                mObjects = value;
974            }
975        }
976        /// <summary>
977        /// The empty argument.
978        /// </summary>
979        public static readonly new PropertiesEventArgs Empty = new PropertiesEventArgs();
980
981        #region Constructor
982        ///<summary>
983        ///Default constructor
984        ///</summary>
985        public SelectionEventArgs(object[] objects)
986        {
987            this.mObjects = objects;
988        }
989        /// <summary>
990        /// Initializes a new instance of the <see cref="T:SelectionEventArgs"/> class.
991        /// </summary>
992        public SelectionEventArgs()
993        {
994        }
995        #endregion
996
997    }
998    #endregion
999
1000    #region CancelableEntityEventArgs
1001    /// <summary>
1002    /// Event argument carrying an item
1003    /// </summary>
1004    public sealed class CancelableEntityEventArgs : EventArgs
1005    {
1006
1007        /// <summary>
1008        /// the Cancel field
1009        /// </summary>
1010        private bool mCancel;
1011        /// <summary>
1012        /// Gets or sets the Cancel
1013        /// </summary>
1014        public bool Cancel
1015        {
1016            get
1017            {
1018                return mCancel;
1019            }
1020            set
1021            {
1022                mCancel = value;
1023            }
1024        }
1025
1026
1027        /// <summary>
1028        /// Gets or sets the entity
1029        /// </summary>
1030        IDiagramEntity mEntity;
1031
1032        /// <summary>
1033        /// Gets or sets the entity.
1034        /// </summary>
1035        /// <value>The entity.</value>
1036        public IDiagramEntity Entity
1037        {
1038            get
1039            {
1040                return mEntity;
1041            }
1042            set
1043            {
1044                mEntity = value;
1045            }
1046        }
1047        /// <summary>
1048        /// Default constructor
1049        /// </summary>
1050        /// <param name="entity"></param>
1051        public CancelableEntityEventArgs(IDiagramEntity entity)
1052        {
1053            this.Entity = entity;
1054        }
1055    }
1056    #endregion
1057
1058    #region FileEventArgs
1059    /// <summary>
1060    /// Contains a string event argument
1061    /// </summary>
1062    public sealed class FileEventArgs : EventArgs
1063    {
1064
1065
1066        /// <summary>
1067        /// the File field
1068        /// </summary>
1069        private FileInfo mFile;
1070        /// <summary>
1071        /// Gets or sets the file information
1072        /// </summary>
1073        public FileInfo File
1074        {
1075            get
1076            {
1077                return mFile;
1078            }
1079        }
1080
1081        /// <summary>
1082        /// Default constructor
1083        /// </summary>
1084        /// <param name="info">The info.</param>
1085        public FileEventArgs(FileInfo info)
1086        {
1087            this.mFile = info;
1088        }
1089    }
1090    #endregion
1091}
Note: See TracBrowser for help on using the repository browser.