2002-7-6 DennisHayes <dennish@raytek.com>
[mono.git] / mcs / class / System.Windows.Forms / System.Windows.Forms / DragEventArgs.cs
1 //\r
2 // System.Windows.Forms.DragEventArgs\r
3 //\r
4 // Author:\r
5 //   stubbed out by Richard Baumann (biochem333@nyc.rr.com)\r
6 //   Implemented by Richard Baumann <biochem333@nyc.rr.com>\r
7 // (C) Ximian, Inc., 2002\r
8 //\r
9 \r
10 using System;\r
11 \r
12 namespace System.Windows.Forms\r
13 {\r
14         /// <summary>\r
15         ///     Provides data for the DragDrop, DragEnter, or DragOver event.\r
16         /// </summary>\r
17         [ComVisible(true)]\r
18         public class DragEventArgs : EventArgs\r
19         {\r
20                 //\r
21                 //  --- Private Fields\r
22                 //\r
23                 private DragDropEffects allowedEffect;\r
24                 private IDataObject data;\r
25                 private DragDropEffects effect;\r
26                 private int keyState;\r
27                 private int x;\r
28                 private int y;\r
29 \r
30                 //\r
31                 //  --- Constructors/Destructors\r
32                 //\r
33                 [ComVisible(true)]\r
34                 public DragEventArgs(IDataObject data, int keyState, int x, int y, DragDropEffects allowedEffect, DragDropEffects effect) : base()\r
35                 {\r
36                         this.data = data;\r
37                         this.keyState = keyState;\r
38                         this.x = x;\r
39                         this.y = y;\r
40                         this.allowedEffect = allowedEffect;\r
41                         this.effect = effect;\r
42                 }\r
43 \r
44                 //\r
45                 //  --- Public Properties\r
46                 //\r
47                 [ComVisible(true)]\r
48                 public DragDropEffects AllowedEffect\r
49                 {\r
50                         get { return allowedEffect; }\r
51                 }\r
52                 [ComVisible(true)]\r
53                 public IDataObject Data\r
54                 {\r
55                         get { return data; }\r
56                 }\r
57                 [ComVisible(true)]\r
58                 public DragDropEffects Effect\r
59                 {\r
60                         get { return effect; }\r
61                         set { effect = value; }\r
62                 }\r
63                 [ComVisible(true)]\r
64                 public int KeyState\r
65                 {\r
66                         get { return keyState; }\r
67                 }\r
68                 [ComVisible(true)]\r
69                 public int X\r
70                 {\r
71                         get { return x; }\r
72                 }\r
73                 [ComVisible(true)]\r
74                 public int Y\r
75                 {\r
76                         get { return y; }\r
77                 }\r
78         }\r
79 }