1 /*!
2 	@file
3 	@author		Generate utility by Albert Semenov
4 	@date		01/2009
5 	@module
6 */
7 
8 using System;
9 using System.Runtime.InteropServices;
10 
11 namespace MyGUI.Sharp
12 {
13     public  class MenuControl :
14 		Widget
15     {
16         #region MenuControl
17 
GetWidgetType()18         protected override string GetWidgetType() { return "MenuControl"; }
19 
RequestWrapMenuControl(BaseWidget _parent, IntPtr _widget)20         internal static BaseWidget RequestWrapMenuControl(BaseWidget _parent, IntPtr _widget)
21         {
22 			MenuControl widget = new MenuControl();
23 			widget.WrapWidget(_parent, _widget);
24             return widget;
25         }
26 
RequestCreateMenuControl(BaseWidget _parent, WidgetStyle _style, string _skin, IntCoord _coord, Align _align, string _layer, string _name)27         internal static BaseWidget RequestCreateMenuControl(BaseWidget _parent, WidgetStyle _style, string _skin, IntCoord _coord, Align _align, string _layer, string _name)
28         {
29 			MenuControl widget = new MenuControl();
30 			widget.CreateWidgetImpl(_parent, _style, _skin, _coord, _align, _layer, _name);
31             return widget;
32         }
33 
34 		#endregion
35 
36 
37 		//InsertPoint
38 		#region Event MenuCtrlClose
39 
40 		[DllImport(DllName.m_dllName, CallingConvention = CallingConvention.Cdecl)]
ExportMenuControlEvent_AdviseMenuCtrlClose(IntPtr _native, bool _advise)41 		private static extern void ExportMenuControlEvent_AdviseMenuCtrlClose(IntPtr _native, bool _advise);
42 
HandleMenuCtrlClose( MenuControl _sender)43 		public delegate void HandleMenuCtrlClose(
44 			MenuControl _sender);
45 
46 		private HandleMenuCtrlClose mEventMenuCtrlClose;
47 		public event HandleMenuCtrlClose EventMenuCtrlClose
48 		{
49 			add
50 			{
51 				if (ExportEventMenuCtrlClose.mDelegate == null)
52 				{
53 					ExportEventMenuCtrlClose.mDelegate = new ExportEventMenuCtrlClose.ExportHandle(OnExportMenuCtrlClose);
54 					ExportEventMenuCtrlClose.ExportMenuControlEvent_DelegateMenuCtrlClose(ExportEventMenuCtrlClose.mDelegate);
55 				}
56 
57 				if (mEventMenuCtrlClose == null)
58 					ExportMenuControlEvent_AdviseMenuCtrlClose(Native, true);
59 				mEventMenuCtrlClose += value;
60 			}
61 			remove
62 			{
63 				mEventMenuCtrlClose -= value;
64 				if (mEventMenuCtrlClose == null)
65 					ExportMenuControlEvent_AdviseMenuCtrlClose(Native, false);
66 			}
67 		}
68 
69 		private struct ExportEventMenuCtrlClose
70 		{
71 			[DllImport(DllName.m_dllName, CallingConvention = CallingConvention.Cdecl)]
ExportMenuControlEvent_DelegateMenuCtrlCloseMyGUI.Sharp.MenuControl.ExportEventMenuCtrlClose72 			public static extern void ExportMenuControlEvent_DelegateMenuCtrlClose(ExportHandle _delegate);
73 			[UnmanagedFunctionPointer(CallingConvention.StdCall)]
ExportHandleMyGUI.Sharp.MenuControl.ExportEventMenuCtrlClose74 			public delegate void ExportHandle(
75 				IntPtr _sender);
76 
77 			public static ExportHandle mDelegate;
78 		}
79 
OnExportMenuCtrlClose( IntPtr _sender)80 		private static void OnExportMenuCtrlClose(
81 			IntPtr _sender)
82 		{
83 			MenuControl sender = (MenuControl)BaseWidget.GetByNative(_sender);
84 
85 			if (sender.mEventMenuCtrlClose != null)
86 				sender.mEventMenuCtrlClose(
87 					sender);
88 		}
89 
90 		#endregion
91 		#region Event MenuCtrlAccept
92 
93 		[DllImport(DllName.m_dllName, CallingConvention = CallingConvention.Cdecl)]
ExportMenuControlEvent_AdviseMenuCtrlAccept(IntPtr _native, bool _advise)94 		private static extern void ExportMenuControlEvent_AdviseMenuCtrlAccept(IntPtr _native, bool _advise);
95 
HandleMenuCtrlAccept( MenuControl _sender, MenuItem _item)96 		public delegate void HandleMenuCtrlAccept(
97 			MenuControl _sender,
98 			MenuItem _item);
99 
100 		private HandleMenuCtrlAccept mEventMenuCtrlAccept;
101 		public event HandleMenuCtrlAccept EventMenuCtrlAccept
102 		{
103 			add
104 			{
105 				if (ExportEventMenuCtrlAccept.mDelegate == null)
106 				{
107 					ExportEventMenuCtrlAccept.mDelegate = new ExportEventMenuCtrlAccept.ExportHandle(OnExportMenuCtrlAccept);
108 					ExportEventMenuCtrlAccept.ExportMenuControlEvent_DelegateMenuCtrlAccept(ExportEventMenuCtrlAccept.mDelegate);
109 				}
110 
111 				if (mEventMenuCtrlAccept == null)
112 					ExportMenuControlEvent_AdviseMenuCtrlAccept(Native, true);
113 				mEventMenuCtrlAccept += value;
114 			}
115 			remove
116 			{
117 				mEventMenuCtrlAccept -= value;
118 				if (mEventMenuCtrlAccept == null)
119 					ExportMenuControlEvent_AdviseMenuCtrlAccept(Native, false);
120 			}
121 		}
122 
123 		private struct ExportEventMenuCtrlAccept
124 		{
125 			[DllImport(DllName.m_dllName, CallingConvention = CallingConvention.Cdecl)]
ExportMenuControlEvent_DelegateMenuCtrlAcceptMyGUI.Sharp.MenuControl.ExportEventMenuCtrlAccept126 			public static extern void ExportMenuControlEvent_DelegateMenuCtrlAccept(ExportHandle _delegate);
127 			[UnmanagedFunctionPointer(CallingConvention.StdCall)]
ExportHandleMyGUI.Sharp.MenuControl.ExportEventMenuCtrlAccept128 			public delegate void ExportHandle(
129 				IntPtr _sender,
130 				IntPtr _item);
131 
132 			public static ExportHandle mDelegate;
133 		}
134 
OnExportMenuCtrlAccept( IntPtr _sender, IntPtr _item)135 		private static void OnExportMenuCtrlAccept(
136 			IntPtr _sender,
137 			IntPtr _item)
138 		{
139 			MenuControl sender = (MenuControl)BaseWidget.GetByNative(_sender);
140 
141 			if (sender.mEventMenuCtrlAccept != null)
142 				sender.mEventMenuCtrlAccept(
143 					sender ,
144 					(MenuItem)BaseWidget.GetByNative(_item));
145 		}
146 
147 		#endregion
148 		#region Method SetItemType
149 
150 		[DllImport(DllName.m_dllName, CallingConvention = CallingConvention.Cdecl)]
ExportMenuControl_SetItemType__item__type(IntPtr _native, IntPtr _item, [MarshalAs(UnmanagedType.I4)] MenuItemType _type)151 		private static extern void ExportMenuControl_SetItemType__item__type(IntPtr _native,
152 			IntPtr _item,
153 			[MarshalAs(UnmanagedType.I4)] MenuItemType _type);
154 
SetItemType( MenuItem _item, MenuItemType _type)155 		public void SetItemType(
156 			MenuItem _item,
157 			MenuItemType _type)
158 		{
159 			ExportMenuControl_SetItemType__item__type(Native,
160 				_item.Native,
161 				_type);
162 		}
163 
164 		#endregion
165 		#region Method SetItemTypeAt
166 
167 		[DllImport(DllName.m_dllName, CallingConvention = CallingConvention.Cdecl)]
ExportMenuControl_SetItemTypeAt__index__type(IntPtr _native, uint _index, [MarshalAs(UnmanagedType.I4)] MenuItemType _type)168 		private static extern void ExportMenuControl_SetItemTypeAt__index__type(IntPtr _native,
169 			uint _index,
170 			[MarshalAs(UnmanagedType.I4)] MenuItemType _type);
171 
SetItemTypeAt( uint _index, MenuItemType _type)172 		public void SetItemTypeAt(
173 			uint _index,
174 			MenuItemType _type)
175 		{
176 			ExportMenuControl_SetItemTypeAt__index__type(Native,
177 				_index,
178 				_type);
179 		}
180 
181 		#endregion
182 		#region Method GetItemType
183 
184 		[DllImport(DllName.m_dllName, CallingConvention = CallingConvention.Cdecl)]
185 
ExportMenuControl_GetItemType__item(IntPtr _native, IntPtr _item)186 		private static extern MenuItemType ExportMenuControl_GetItemType__item(IntPtr _native,
187 			IntPtr _item);
188 
GetItemType( MenuItem _item)189 		public MenuItemType GetItemType(
190 			MenuItem _item)
191 		{
192 			return ExportMenuControl_GetItemType__item(Native,
193 				_item.Native);
194 		}
195 
196 		#endregion
197 		#region Method GetItemTypeAt
198 
199 		[DllImport(DllName.m_dllName, CallingConvention = CallingConvention.Cdecl)]
200 
ExportMenuControl_GetItemTypeAt__index(IntPtr _native, uint _index)201 		private static extern MenuItemType ExportMenuControl_GetItemTypeAt__index(IntPtr _native,
202 			uint _index);
203 
GetItemTypeAt( uint _index)204 		public MenuItemType GetItemTypeAt(
205 			uint _index)
206 		{
207 			return ExportMenuControl_GetItemTypeAt__index(Native,
208 				_index);
209 		}
210 
211 		#endregion
212 		#region Method RemoveItemChild
213 
214 		[DllImport(DllName.m_dllName, CallingConvention = CallingConvention.Cdecl)]
ExportMenuControl_RemoveItemChild__item(IntPtr _native, IntPtr _item)215 		private static extern void ExportMenuControl_RemoveItemChild__item(IntPtr _native,
216 			IntPtr _item);
217 
RemoveItemChild( MenuItem _item)218 		public void RemoveItemChild(
219 			MenuItem _item)
220 		{
221 			ExportMenuControl_RemoveItemChild__item(Native,
222 				_item.Native);
223 		}
224 
225 		#endregion
226 		#region Method RemoveItemChildAt
227 
228 		[DllImport(DllName.m_dllName, CallingConvention = CallingConvention.Cdecl)]
ExportMenuControl_RemoveItemChildAt__index(IntPtr _native, uint _index)229 		private static extern void ExportMenuControl_RemoveItemChildAt__index(IntPtr _native,
230 			uint _index);
231 
RemoveItemChildAt( uint _index)232 		public void RemoveItemChildAt(
233 			uint _index)
234 		{
235 			ExportMenuControl_RemoveItemChildAt__index(Native,
236 				_index);
237 		}
238 
239 		#endregion
240 		#region Method CreateItemChild
241 
242 		[DllImport(DllName.m_dllName, CallingConvention = CallingConvention.Cdecl)]
243 
ExportMenuControl_CreateItemChild__item(IntPtr _native, IntPtr _item)244 		private static extern IntPtr ExportMenuControl_CreateItemChild__item(IntPtr _native,
245 			IntPtr _item);
246 
CreateItemChild( MenuItem _item)247 		public MenuControl CreateItemChild(
248 			MenuItem _item)
249 		{
250 			return (MenuControl)BaseWidget.GetByNative(ExportMenuControl_CreateItemChild__item(Native,
251 				_item.Native));
252 		}
253 
254 		#endregion
255 		#region Method CreateItemChildAt
256 
257 		[DllImport(DllName.m_dllName, CallingConvention = CallingConvention.Cdecl)]
258 
ExportMenuControl_CreateItemChildAt__index(IntPtr _native, uint _index)259 		private static extern IntPtr ExportMenuControl_CreateItemChildAt__index(IntPtr _native,
260 			uint _index);
261 
CreateItemChildAt( uint _index)262 		public MenuControl CreateItemChildAt(
263 			uint _index)
264 		{
265 			return (MenuControl)BaseWidget.GetByNative(ExportMenuControl_CreateItemChildAt__index(Native,
266 				_index));
267 		}
268 
269 		#endregion
270 		#region Method GetItemChild
271 
272 		[DllImport(DllName.m_dllName, CallingConvention = CallingConvention.Cdecl)]
273 
ExportMenuControl_GetItemChild__item(IntPtr _native, IntPtr _item)274 		private static extern IntPtr ExportMenuControl_GetItemChild__item(IntPtr _native,
275 			IntPtr _item);
276 
GetItemChild( MenuItem _item)277 		public MenuControl GetItemChild(
278 			MenuItem _item)
279 		{
280 			return (MenuControl)BaseWidget.GetByNative(ExportMenuControl_GetItemChild__item(Native,
281 				_item.Native));
282 		}
283 
284 		#endregion
285 		#region Method GetItemChildAt
286 
287 		[DllImport(DllName.m_dllName, CallingConvention = CallingConvention.Cdecl)]
288 
ExportMenuControl_GetItemChildAt__index(IntPtr _native, uint _index)289 		private static extern IntPtr ExportMenuControl_GetItemChildAt__index(IntPtr _native,
290 			uint _index);
291 
GetItemChildAt( uint _index)292 		public MenuControl GetItemChildAt(
293 			uint _index)
294 		{
295 			return (MenuControl)BaseWidget.GetByNative(ExportMenuControl_GetItemChildAt__index(Native,
296 				_index));
297 		}
298 
299 		#endregion
300 		#region Method SetItemChildVisible
301 
302 		[DllImport(DllName.m_dllName, CallingConvention = CallingConvention.Cdecl)]
ExportMenuControl_SetItemChildVisible__item__visible(IntPtr _native, IntPtr _item, [MarshalAs(UnmanagedType.U1)] bool _visible)303 		private static extern void ExportMenuControl_SetItemChildVisible__item__visible(IntPtr _native,
304 			IntPtr _item,
305 			[MarshalAs(UnmanagedType.U1)] bool _visible);
306 
SetItemChildVisible( MenuItem _item, bool _visible)307 		public void SetItemChildVisible(
308 			MenuItem _item,
309 			bool _visible)
310 		{
311 			ExportMenuControl_SetItemChildVisible__item__visible(Native,
312 				_item.Native,
313 				_visible);
314 		}
315 
316 		#endregion
317 		#region Method SetItemChildVisibleAt
318 
319 		[DllImport(DllName.m_dllName, CallingConvention = CallingConvention.Cdecl)]
ExportMenuControl_SetItemChildVisibleAt__index__visible(IntPtr _native, uint _index, [MarshalAs(UnmanagedType.U1)] bool _visible)320 		private static extern void ExportMenuControl_SetItemChildVisibleAt__index__visible(IntPtr _native,
321 			uint _index,
322 			[MarshalAs(UnmanagedType.U1)] bool _visible);
323 
SetItemChildVisibleAt( uint _index, bool _visible)324 		public void SetItemChildVisibleAt(
325 			uint _index,
326 			bool _visible)
327 		{
328 			ExportMenuControl_SetItemChildVisibleAt__index__visible(Native,
329 				_index,
330 				_visible);
331 		}
332 
333 		#endregion
334 		#region Method FindItemIndexWith
335 
336 		[DllImport(DllName.m_dllName, CallingConvention = CallingConvention.Cdecl)]
337 
ExportMenuControl_FindItemIndexWith__name(IntPtr _native, [MarshalAs(UnmanagedType.LPWStr)] string _name)338 		private static extern uint ExportMenuControl_FindItemIndexWith__name(IntPtr _native,
339 			[MarshalAs(UnmanagedType.LPWStr)] string _name);
340 
FindItemIndexWith( string _name)341 		public uint FindItemIndexWith(
342 			string _name)
343 		{
344 			return ExportMenuControl_FindItemIndexWith__name(Native,
345 				_name);
346 		}
347 
348 		#endregion
349 		#region Method GetItemName
350 
351 		[DllImport(DllName.m_dllName, CallingConvention = CallingConvention.Cdecl)]
352 
ExportMenuControl_GetItemName__item(IntPtr _native, IntPtr _item)353 		private static extern IntPtr ExportMenuControl_GetItemName__item(IntPtr _native,
354 			IntPtr _item);
355 
GetItemName( MenuItem _item)356 		public string GetItemName(
357 			MenuItem _item)
358 		{
359 			return Marshal.PtrToStringUni(ExportMenuControl_GetItemName__item(Native,
360 				_item.Native));
361 		}
362 
363 		#endregion
364 		#region Method GetItemNameAt
365 
366 		[DllImport(DllName.m_dllName, CallingConvention = CallingConvention.Cdecl)]
367 
ExportMenuControl_GetItemNameAt__index(IntPtr _native, uint _index)368 		private static extern IntPtr ExportMenuControl_GetItemNameAt__index(IntPtr _native,
369 			uint _index);
370 
GetItemNameAt( uint _index)371 		public string GetItemNameAt(
372 			uint _index)
373 		{
374 			return Marshal.PtrToStringUni(ExportMenuControl_GetItemNameAt__index(Native,
375 				_index));
376 		}
377 
378 		#endregion
379 		#region Method SetItemName
380 
381 		[DllImport(DllName.m_dllName, CallingConvention = CallingConvention.Cdecl)]
ExportMenuControl_SetItemName__item__name(IntPtr _native, IntPtr _item, [MarshalAs(UnmanagedType.LPWStr)] string _name)382 		private static extern void ExportMenuControl_SetItemName__item__name(IntPtr _native,
383 			IntPtr _item,
384 			[MarshalAs(UnmanagedType.LPWStr)] string _name);
385 
SetItemName( MenuItem _item, string _name)386 		public void SetItemName(
387 			MenuItem _item,
388 			string _name)
389 		{
390 			ExportMenuControl_SetItemName__item__name(Native,
391 				_item.Native,
392 				_name);
393 		}
394 
395 		#endregion
396 		#region Method SetItemNameAt
397 
398 		[DllImport(DllName.m_dllName, CallingConvention = CallingConvention.Cdecl)]
ExportMenuControl_SetItemNameAt__index__name(IntPtr _native, uint _index, [MarshalAs(UnmanagedType.LPWStr)] string _name)399 		private static extern void ExportMenuControl_SetItemNameAt__index__name(IntPtr _native,
400 			uint _index,
401 			[MarshalAs(UnmanagedType.LPWStr)] string _name);
402 
SetItemNameAt( uint _index, string _name)403 		public void SetItemNameAt(
404 			uint _index,
405 			string _name)
406 		{
407 			ExportMenuControl_SetItemNameAt__index__name(Native,
408 				_index,
409 				_name);
410 		}
411 
412 		#endregion
413 		#region Method GetItemIndexById
414 
415 		[DllImport(DllName.m_dllName, CallingConvention = CallingConvention.Cdecl)]
416 
ExportMenuControl_GetItemIndexById__id(IntPtr _native, [MarshalAs(UnmanagedType.LPStr)] string _id)417 		private static extern uint ExportMenuControl_GetItemIndexById__id(IntPtr _native,
418 			[MarshalAs(UnmanagedType.LPStr)] string _id);
419 
GetItemIndexById( string _id)420 		public uint GetItemIndexById(
421 			string _id)
422 		{
423 			return ExportMenuControl_GetItemIndexById__id(Native,
424 				_id);
425 		}
426 
427 		#endregion
428 		#region Method FindItemById
429 
430 		[DllImport(DllName.m_dllName, CallingConvention = CallingConvention.Cdecl)]
431 
ExportMenuControl_FindItemById__id__recursive(IntPtr _native, [MarshalAs(UnmanagedType.LPStr)] string _id, [MarshalAs(UnmanagedType.U1)] bool _recursive)432 		private static extern IntPtr ExportMenuControl_FindItemById__id__recursive(IntPtr _native,
433 			[MarshalAs(UnmanagedType.LPStr)] string _id,
434 			[MarshalAs(UnmanagedType.U1)] bool _recursive);
435 
FindItemById( string _id, bool _recursive)436 		public MenuItem FindItemById(
437 			string _id,
438 			bool _recursive)
439 		{
440 			return (MenuItem)BaseWidget.GetByNative(ExportMenuControl_FindItemById__id__recursive(Native,
441 				_id,
442 				_recursive));
443 		}
444 
445 		#endregion
446 		#region Method GetItemById
447 
448 		[DllImport(DllName.m_dllName, CallingConvention = CallingConvention.Cdecl)]
449 
ExportMenuControl_GetItemById__id(IntPtr _native, [MarshalAs(UnmanagedType.LPStr)] string _id)450 		private static extern IntPtr ExportMenuControl_GetItemById__id(IntPtr _native,
451 			[MarshalAs(UnmanagedType.LPStr)] string _id);
452 
GetItemById( string _id)453 		public MenuItem GetItemById(
454 			string _id)
455 		{
456 			return (MenuItem)BaseWidget.GetByNative(ExportMenuControl_GetItemById__id(Native,
457 				_id));
458 		}
459 
460 		#endregion
461 		#region Method GetItemId
462 
463 		[DllImport(DllName.m_dllName, CallingConvention = CallingConvention.Cdecl)]
464 
ExportMenuControl_GetItemId__item(IntPtr _native, IntPtr _item)465 		private static extern IntPtr ExportMenuControl_GetItemId__item(IntPtr _native,
466 			IntPtr _item);
467 
GetItemId( MenuItem _item)468 		public string GetItemId(
469 			MenuItem _item)
470 		{
471 			return Marshal.PtrToStringAnsi(ExportMenuControl_GetItemId__item(Native,
472 				_item.Native));
473 		}
474 
475 		#endregion
476 		#region Method GetItemIdAt
477 
478 		[DllImport(DllName.m_dllName, CallingConvention = CallingConvention.Cdecl)]
479 
ExportMenuControl_GetItemIdAt__index(IntPtr _native, uint _index)480 		private static extern IntPtr ExportMenuControl_GetItemIdAt__index(IntPtr _native,
481 			uint _index);
482 
GetItemIdAt( uint _index)483 		public string GetItemIdAt(
484 			uint _index)
485 		{
486 			return Marshal.PtrToStringAnsi(ExportMenuControl_GetItemIdAt__index(Native,
487 				_index));
488 		}
489 
490 		#endregion
491 		#region Method SetItemId
492 
493 		[DllImport(DllName.m_dllName, CallingConvention = CallingConvention.Cdecl)]
ExportMenuControl_SetItemId__item__id(IntPtr _native, IntPtr _item, [MarshalAs(UnmanagedType.LPStr)] string _id)494 		private static extern void ExportMenuControl_SetItemId__item__id(IntPtr _native,
495 			IntPtr _item,
496 			[MarshalAs(UnmanagedType.LPStr)] string _id);
497 
SetItemId( MenuItem _item, string _id)498 		public void SetItemId(
499 			MenuItem _item,
500 			string _id)
501 		{
502 			ExportMenuControl_SetItemId__item__id(Native,
503 				_item.Native,
504 				_id);
505 		}
506 
507 		#endregion
508 		#region Method SetItemIdAt
509 
510 		[DllImport(DllName.m_dllName, CallingConvention = CallingConvention.Cdecl)]
ExportMenuControl_SetItemIdAt__index__id(IntPtr _native, uint _index, [MarshalAs(UnmanagedType.LPStr)] string _id)511 		private static extern void ExportMenuControl_SetItemIdAt__index__id(IntPtr _native,
512 			uint _index,
513 			[MarshalAs(UnmanagedType.LPStr)] string _id);
514 
SetItemIdAt( uint _index, string _id)515 		public void SetItemIdAt(
516 			uint _index,
517 			string _id)
518 		{
519 			ExportMenuControl_SetItemIdAt__index__id(Native,
520 				_index,
521 				_id);
522 		}
523 
524 		#endregion
525 		#region Method FindItemWith
526 
527 		[DllImport(DllName.m_dllName, CallingConvention = CallingConvention.Cdecl)]
528 
ExportMenuControl_FindItemWith__name(IntPtr _native, [MarshalAs(UnmanagedType.LPWStr)] string _name)529 		private static extern IntPtr ExportMenuControl_FindItemWith__name(IntPtr _native,
530 			[MarshalAs(UnmanagedType.LPWStr)] string _name);
531 
FindItemWith( string _name)532 		public MenuItem FindItemWith(
533 			string _name)
534 		{
535 			return (MenuItem)BaseWidget.GetByNative(ExportMenuControl_FindItemWith__name(Native,
536 				_name));
537 		}
538 
539 		#endregion
540 		#region Method FindItemIndex
541 
542 		[DllImport(DllName.m_dllName, CallingConvention = CallingConvention.Cdecl)]
543 
ExportMenuControl_FindItemIndex__item(IntPtr _native, IntPtr _item)544 		private static extern uint ExportMenuControl_FindItemIndex__item(IntPtr _native,
545 			IntPtr _item);
546 
FindItemIndex( MenuItem _item)547 		public uint FindItemIndex(
548 			MenuItem _item)
549 		{
550 			return ExportMenuControl_FindItemIndex__item(Native,
551 				_item.Native);
552 		}
553 
554 		#endregion
555 		#region Method GetItemIndex
556 
557 		[DllImport(DllName.m_dllName, CallingConvention = CallingConvention.Cdecl)]
558 
ExportMenuControl_GetItemIndex__item(IntPtr _native, IntPtr _item)559 		private static extern uint ExportMenuControl_GetItemIndex__item(IntPtr _native,
560 			IntPtr _item);
561 
GetItemIndex( MenuItem _item)562 		public uint GetItemIndex(
563 			MenuItem _item)
564 		{
565 			return ExportMenuControl_GetItemIndex__item(Native,
566 				_item.Native);
567 		}
568 
569 		#endregion
570 		#region Method GetItemAt
571 
572 		[DllImport(DllName.m_dllName, CallingConvention = CallingConvention.Cdecl)]
573 
ExportMenuControl_GetItemAt__index(IntPtr _native, uint _index)574 		private static extern IntPtr ExportMenuControl_GetItemAt__index(IntPtr _native,
575 			uint _index);
576 
GetItemAt( uint _index)577 		public MenuItem GetItemAt(
578 			uint _index)
579 		{
580 			return (MenuItem)BaseWidget.GetByNative(ExportMenuControl_GetItemAt__index(Native,
581 				_index));
582 		}
583 
584 		#endregion
585 		#region Method RemoveAllItems
586 
587 		[DllImport(DllName.m_dllName, CallingConvention = CallingConvention.Cdecl)]
ExportMenuControl_RemoveAllItems(IntPtr _native)588 		private static extern void ExportMenuControl_RemoveAllItems(IntPtr _native);
589 
RemoveAllItems( )590 		public void RemoveAllItems( )
591 		{
592 			ExportMenuControl_RemoveAllItems(Native);
593 		}
594 
595 		#endregion
596 		#region Method RemoveItem
597 
598 		[DllImport(DllName.m_dllName, CallingConvention = CallingConvention.Cdecl)]
ExportMenuControl_RemoveItem__item(IntPtr _native, IntPtr _item)599 		private static extern void ExportMenuControl_RemoveItem__item(IntPtr _native,
600 			IntPtr _item);
601 
RemoveItem( MenuItem _item)602 		public void RemoveItem(
603 			MenuItem _item)
604 		{
605 			ExportMenuControl_RemoveItem__item(Native,
606 				_item.Native);
607 		}
608 
609 		#endregion
610 		#region Method RemoveItemAt
611 
612 		[DllImport(DllName.m_dllName, CallingConvention = CallingConvention.Cdecl)]
ExportMenuControl_RemoveItemAt__index(IntPtr _native, uint _index)613 		private static extern void ExportMenuControl_RemoveItemAt__index(IntPtr _native,
614 			uint _index);
615 
RemoveItemAt( uint _index)616 		public void RemoveItemAt(
617 			uint _index)
618 		{
619 			ExportMenuControl_RemoveItemAt__index(Native,
620 				_index);
621 		}
622 
623 		#endregion
624 		#region Method AddItem
625 
626 		[DllImport(DllName.m_dllName, CallingConvention = CallingConvention.Cdecl)]
627 
ExportMenuControl_AddItem__name__type__id(IntPtr _native, [MarshalAs(UnmanagedType.LPWStr)] string _name, [MarshalAs(UnmanagedType.I4)] MenuItemType _type, [MarshalAs(UnmanagedType.LPStr)] string _id)628 		private static extern IntPtr ExportMenuControl_AddItem__name__type__id(IntPtr _native,
629 			[MarshalAs(UnmanagedType.LPWStr)] string _name,
630 			[MarshalAs(UnmanagedType.I4)] MenuItemType _type,
631 			[MarshalAs(UnmanagedType.LPStr)] string _id);
632 
AddItem( string _name, MenuItemType _type, string _id)633 		public MenuItem AddItem(
634 			string _name,
635 			MenuItemType _type,
636 			string _id)
637 		{
638 			return (MenuItem)BaseWidget.GetByNative(ExportMenuControl_AddItem__name__type__id(Native,
639 				_name,
640 				_type,
641 				_id));
642 		}
643 
644 		[DllImport(DllName.m_dllName, CallingConvention = CallingConvention.Cdecl)]
645 
ExportMenuControl_AddItem__name__type(IntPtr _native, [MarshalAs(UnmanagedType.LPWStr)] string _name, [MarshalAs(UnmanagedType.I4)] MenuItemType _type)646 		private static extern IntPtr ExportMenuControl_AddItem__name__type(IntPtr _native,
647 			[MarshalAs(UnmanagedType.LPWStr)] string _name,
648 			[MarshalAs(UnmanagedType.I4)] MenuItemType _type);
649 
AddItem( string _name, MenuItemType _type)650 		public MenuItem AddItem(
651 			string _name,
652 			MenuItemType _type)
653 		{
654 			return (MenuItem)BaseWidget.GetByNative(ExportMenuControl_AddItem__name__type(Native,
655 				_name,
656 				_type));
657 		}
658 
659 		[DllImport(DllName.m_dllName, CallingConvention = CallingConvention.Cdecl)]
660 
ExportMenuControl_AddItem__name(IntPtr _native, [MarshalAs(UnmanagedType.LPWStr)] string _name)661 		private static extern IntPtr ExportMenuControl_AddItem__name(IntPtr _native,
662 			[MarshalAs(UnmanagedType.LPWStr)] string _name);
663 
AddItem( string _name)664 		public MenuItem AddItem(
665 			string _name)
666 		{
667 			return (MenuItem)BaseWidget.GetByNative(ExportMenuControl_AddItem__name(Native,
668 				_name));
669 		}
670 
671 		#endregion
672 		#region Method InsertItemAt
673 
674 		[DllImport(DllName.m_dllName, CallingConvention = CallingConvention.Cdecl)]
675 
ExportMenuControl_InsertItemAt__index__name__type__id(IntPtr _native, uint _index, [MarshalAs(UnmanagedType.LPWStr)] string _name, [MarshalAs(UnmanagedType.I4)] MenuItemType _type, [MarshalAs(UnmanagedType.LPStr)] string _id)676 		private static extern IntPtr ExportMenuControl_InsertItemAt__index__name__type__id(IntPtr _native,
677 			uint _index,
678 			[MarshalAs(UnmanagedType.LPWStr)] string _name,
679 			[MarshalAs(UnmanagedType.I4)] MenuItemType _type,
680 			[MarshalAs(UnmanagedType.LPStr)] string _id);
681 
InsertItemAt( uint _index, string _name, MenuItemType _type, string _id)682 		public MenuItem InsertItemAt(
683 			uint _index,
684 			string _name,
685 			MenuItemType _type,
686 			string _id)
687 		{
688 			return (MenuItem)BaseWidget.GetByNative(ExportMenuControl_InsertItemAt__index__name__type__id(Native,
689 				_index,
690 				_name,
691 				_type,
692 				_id));
693 		}
694 
695 		[DllImport(DllName.m_dllName, CallingConvention = CallingConvention.Cdecl)]
696 
ExportMenuControl_InsertItemAt__index__name__type(IntPtr _native, uint _index, [MarshalAs(UnmanagedType.LPWStr)] string _name, [MarshalAs(UnmanagedType.I4)] MenuItemType _type)697 		private static extern IntPtr ExportMenuControl_InsertItemAt__index__name__type(IntPtr _native,
698 			uint _index,
699 			[MarshalAs(UnmanagedType.LPWStr)] string _name,
700 			[MarshalAs(UnmanagedType.I4)] MenuItemType _type);
701 
InsertItemAt( uint _index, string _name, MenuItemType _type)702 		public MenuItem InsertItemAt(
703 			uint _index,
704 			string _name,
705 			MenuItemType _type)
706 		{
707 			return (MenuItem)BaseWidget.GetByNative(ExportMenuControl_InsertItemAt__index__name__type(Native,
708 				_index,
709 				_name,
710 				_type));
711 		}
712 
713 		[DllImport(DllName.m_dllName, CallingConvention = CallingConvention.Cdecl)]
714 
ExportMenuControl_InsertItemAt__index__name(IntPtr _native, uint _index, [MarshalAs(UnmanagedType.LPWStr)] string _name)715 		private static extern IntPtr ExportMenuControl_InsertItemAt__index__name(IntPtr _native,
716 			uint _index,
717 			[MarshalAs(UnmanagedType.LPWStr)] string _name);
718 
InsertItemAt( uint _index, string _name)719 		public MenuItem InsertItemAt(
720 			uint _index,
721 			string _name)
722 		{
723 			return (MenuItem)BaseWidget.GetByNative(ExportMenuControl_InsertItemAt__index__name(Native,
724 				_index,
725 				_name));
726 		}
727 
728 		#endregion
729 		#region Method SetVisibleSmooth
730 
731 		[DllImport(DllName.m_dllName, CallingConvention = CallingConvention.Cdecl)]
ExportMenuControl_SetVisibleSmooth__value(IntPtr _native, [MarshalAs(UnmanagedType.U1)] bool _value)732 		private static extern void ExportMenuControl_SetVisibleSmooth__value(IntPtr _native,
733 			[MarshalAs(UnmanagedType.U1)] bool _value);
734 
SetVisibleSmooth( bool _value)735 		public void SetVisibleSmooth(
736 			bool _value)
737 		{
738 			ExportMenuControl_SetVisibleSmooth__value(Native,
739 				_value);
740 		}
741 
742 		#endregion
743 		#region Property VerticalAlignment
744 
745 		[DllImport(DllName.m_dllName, CallingConvention = CallingConvention.Cdecl)]
746 
ExportMenuControl_GetVerticalAlignment(IntPtr _widget)747 		private static extern bool ExportMenuControl_GetVerticalAlignment(IntPtr _widget);
748 		[DllImport(DllName.m_dllName, CallingConvention = CallingConvention.Cdecl)]
ExportMenuControl_SetVerticalAlignment(IntPtr _widget, [MarshalAs(UnmanagedType.U1)] bool _value)749 		private static extern void ExportMenuControl_SetVerticalAlignment(IntPtr _widget, [MarshalAs(UnmanagedType.U1)] bool _value);
750 
751 		public bool VerticalAlignment
752 		{
753 			get { return ExportMenuControl_GetVerticalAlignment(Native); }
754 			set { ExportMenuControl_SetVerticalAlignment(Native, value); }
755 		}
756 
757 		#endregion
758 		#region Property MenuItemParent
759 
760 		[DllImport(DllName.m_dllName, CallingConvention = CallingConvention.Cdecl)]
761 
ExportMenuControl_GetMenuItemParent(IntPtr _native)762 		private static extern IntPtr ExportMenuControl_GetMenuItemParent(IntPtr _native);
763 
764 		public MenuItem MenuItemParent
765 		{
766 			get { return (MenuItem)BaseWidget.GetByNative(ExportMenuControl_GetMenuItemParent(Native)); }
767 		}
768 
769 		#endregion
770 		#region Property PopupAccept
771 
772 		[DllImport(DllName.m_dllName, CallingConvention = CallingConvention.Cdecl)]
773 
ExportMenuControl_GetPopupAccept(IntPtr _widget)774 		private static extern bool ExportMenuControl_GetPopupAccept(IntPtr _widget);
775 		[DllImport(DllName.m_dllName, CallingConvention = CallingConvention.Cdecl)]
ExportMenuControl_SetPopupAccept(IntPtr _widget, [MarshalAs(UnmanagedType.U1)] bool _value)776 		private static extern void ExportMenuControl_SetPopupAccept(IntPtr _widget, [MarshalAs(UnmanagedType.U1)] bool _value);
777 
778 		public bool PopupAccept
779 		{
780 			get { return ExportMenuControl_GetPopupAccept(Native); }
781 			set { ExportMenuControl_SetPopupAccept(Native, value); }
782 		}
783 
784 		#endregion
785 		#region Property ItemCount
786 
787 		[DllImport(DllName.m_dllName, CallingConvention = CallingConvention.Cdecl)]
788 
ExportMenuControl_GetItemCount(IntPtr _native)789 		private static extern uint ExportMenuControl_GetItemCount(IntPtr _native);
790 
791 		public uint ItemCount
792 		{
793 			get { return ExportMenuControl_GetItemCount(Native); }
794 		}
795 
796 		#endregion
797 
798     }
799 }
800