d50c96b7e73cc17bd9d81363f7357e31481d38f9
[platform/core/csapi/tizenfx.git] / src / Tizen.NUI / src / public / Window / DefaultBorder.cs
1 /*
2  * Copyright(c) 2022 Samsung Electronics Co., Ltd.
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  * http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  *
16  */
17
18 using System;
19 using System.ComponentModel;
20 using Tizen.NUI.BaseComponents;
21
22 namespace Tizen.NUI
23 {
24     /// <summary>
25     /// This class creates a border UI.
26     /// </summary>
27     [EditorBrowsable(EditorBrowsableState.Never)]
28     public class DefaultBorder : IBorderInterface
29     {
30         #region Constant Fields
31         private static readonly string ResourcePath = FrameworkInformation.ResourcePath;
32         private static readonly string MinimalizeIcon = ResourcePath + "minimalize.png";
33         private static readonly string MaximalizeIcon = ResourcePath + "maximalize.png";
34         private static readonly string CloseIcon = ResourcePath + "close.png";
35         private static readonly string LeftCornerIcon = ResourcePath + "leftCorner.png";
36         private static readonly string RightCornerIcon = ResourcePath + "rightCorner.png";
37
38         private static readonly string DarkMinimalizeIcon = ResourcePath + "dark_minimalize.png";
39         private static readonly string DarkPreviousIcon = ResourcePath + "dark_smallwindow.png";
40         private static readonly string DarkCloseIcon = ResourcePath + "dark_close.png";
41         private static readonly string DarkLeftCornerIcon = ResourcePath + "dark_leftCorner.png";
42         private static readonly string DarkRightCornerIcon = ResourcePath + "dark_rightCorner.png";
43
44
45         private const uint DefaultHeight = 50;
46         private const uint DefaultLineThickness = 5;
47         private const uint DefaultTouchThickness = 20;
48         private static readonly Color DefaultBackgroundColor = new Color(1, 1, 1, 0.3f);
49         private static readonly Color DefaultClickedBackgroundColor = new Color(1, 1, 1, 0.4f);
50         private static readonly Size2D DefaultMinSize = new Size2D(100, 0);
51         #endregion //Constant Fields
52
53
54         #region Fields
55         private Color backgroundColor;
56         private View borderView;
57
58         private ImageView minimalizeIcon;
59         private ImageView maximalizeIcon;
60         private ImageView closeIcon;
61         private ImageView leftCornerIcon;
62         private ImageView rightCornerIcon;
63
64         private Window.BorderDirection direction = Window.BorderDirection.None;
65         private float preScale = 0;
66
67         private View windowView = null;
68         private bool isWinGestures = false;
69         private Timer timer;
70
71         private CurrentGesture currentGesture = CurrentGesture.None;
72         private bool disposed = false;
73         #endregion //Fields
74
75         #region Events
76         private PanGestureDetector borderPanGestureDetector;
77         private PinchGestureDetector borderPinchGestureDetector;
78         private PanGestureDetector winPanGestureDetector;
79         private TapGestureDetector winTapGestureDetector;
80         #endregion //Events
81
82         #region Enums
83         private enum CurrentGesture
84         {
85           None = 0,
86           TapGesture = 1,
87           PanGesture = 2,
88           PinchGesture = 3,
89         }
90         #endregion //Enums
91
92         #region Methods
93
94         /// <summary>
95         /// The thickness of the border.
96         /// </summary>
97         [EditorBrowsable(EditorBrowsableState.Never)]
98         public uint BorderLineThickness {get; set;}
99
100         /// <summary>
101         /// The thickness of the border's touch area.
102         /// </summary>
103         [EditorBrowsable(EditorBrowsableState.Never)]
104         public uint TouchThickness {get; set;}
105
106         /// <summary>
107         /// The height of the border.
108         /// </summary>
109         [EditorBrowsable(EditorBrowsableState.Never)]
110         public uint BorderHeight {get; set;}
111
112         /// <summary>
113         /// The minimum size by which the window will small.
114         /// </summary>
115         [EditorBrowsable(EditorBrowsableState.Never)]
116         public Size2D MinSize {get; set;}
117
118         /// <summary>
119         /// The maximum size by which the window will big.
120         /// </summary>
121         [EditorBrowsable(EditorBrowsableState.Never)]
122         public Size2D MaxSize {get; set;}
123
124         /// <summary>
125         /// The window with borders added.
126         /// </summary>
127         [EditorBrowsable(EditorBrowsableState.Never)]
128         public Window BorderWindow {get; set;}
129
130         /// <summary>
131         /// Whether overlay mode.
132         /// If overlay mode is true, the border area is hidden when the window is maximized.
133         /// And if you touched at screen, the border area is shown on the screen.
134         /// Default value is false;
135         /// </summary>
136         [EditorBrowsable(EditorBrowsableState.Never)]
137         public bool OverlayMode {get; set;}
138
139
140         /// <summary>
141         /// Creates a default border
142         /// </summary>
143         [EditorBrowsable(EditorBrowsableState.Never)]
144         public DefaultBorder()
145         {
146             BorderLineThickness = DefaultLineThickness;
147             TouchThickness = DefaultTouchThickness;
148             BorderHeight = DefaultHeight;
149             MinSize = DefaultMinSize;
150             OverlayMode = false;
151         }
152
153         /// <summary>
154         /// Create top border UI. User can override this method to draw top border UI.
155         /// </summary>
156         /// <param name="topView">The top view on which the border.</param>
157         [EditorBrowsable(EditorBrowsableState.Never)]
158         public virtual bool CreateTopBorderView(View topView)
159         {
160             return false;
161         }
162
163         /// <summary>
164         /// Create bottom border UI. User can override this method to draw bottom border UI.
165         /// </summary>
166         /// <param name="bottomView">The bottom view on which the border.</param>
167         [EditorBrowsable(EditorBrowsableState.Never)]
168         public virtual bool CreateBottomBorderView(View bottomView)
169         {
170             if (bottomView == null)
171             {
172                 return false;
173             }
174             bottomView.Layout = new RelativeLayout();
175
176             minimalizeIcon = new ImageView()
177             {
178                 ResourceUrl = MinimalizeIcon,
179             };
180
181             maximalizeIcon = new ImageView()
182             {
183                 ResourceUrl = MaximalizeIcon,
184             };
185
186             closeIcon = new ImageView()
187             {
188                 ResourceUrl = CloseIcon,
189             };
190
191             leftCornerIcon = new ImageView()
192             {
193                 ResourceUrl = LeftCornerIcon,
194             };
195
196             rightCornerIcon = new ImageView()
197             {
198               ResourceUrl = RightCornerIcon,
199             };
200
201             RelativeLayout.SetRightTarget(minimalizeIcon, maximalizeIcon);
202             RelativeLayout.SetRightRelativeOffset(minimalizeIcon, 0.0f);
203             RelativeLayout.SetHorizontalAlignment(minimalizeIcon, RelativeLayout.Alignment.End);
204             RelativeLayout.SetRightTarget(maximalizeIcon, closeIcon);
205             RelativeLayout.SetRightRelativeOffset(maximalizeIcon, 0.0f);
206             RelativeLayout.SetHorizontalAlignment(maximalizeIcon, RelativeLayout.Alignment.End);
207             RelativeLayout.SetRightTarget(closeIcon, rightCornerIcon);
208             RelativeLayout.SetRightRelativeOffset(closeIcon, 0.0f);
209             RelativeLayout.SetHorizontalAlignment(closeIcon, RelativeLayout.Alignment.End);
210             RelativeLayout.SetRightRelativeOffset(rightCornerIcon, 1.0f);
211             RelativeLayout.SetHorizontalAlignment(rightCornerIcon, RelativeLayout.Alignment.End);
212             bottomView.Add(leftCornerIcon);
213             bottomView.Add(minimalizeIcon);
214             bottomView.Add(maximalizeIcon);
215             bottomView.Add(closeIcon);
216             bottomView.Add(rightCornerIcon);
217
218
219             minimalizeIcon.TouchEvent += OnMinimizeIconTouched;
220             maximalizeIcon.TouchEvent += OnMaximizeIconTouched;
221             closeIcon.TouchEvent += OnCloseIconTouched;
222             leftCornerIcon.TouchEvent += OnLeftBottomCornerIconTouched;
223             rightCornerIcon.TouchEvent += OnRightBottomCornerIconTouched;
224             return true;
225         }
226
227
228         /// <summary>
229         /// Create border UI. User can override this method to draw border UI.
230         /// A top border and a bottom border are added to this view.
231         /// </summary>
232         /// <param name="borderView">The root view on which the border.</param>
233         [EditorBrowsable(EditorBrowsableState.Never)]
234         public virtual void CreateBorderView(View borderView)
235         {
236             if (borderView == null)
237             {
238                 return;
239             }
240             this.borderView = borderView;
241             borderView.BackgroundColor = DefaultBackgroundColor;
242             borderView.CornerRadius = new Vector4(0.03f, 0.03f, 0.03f, 0.03f);
243             borderView.CornerRadiusPolicy = VisualTransformPolicyType.Relative;
244         }
245
246         /// Determines the behavior of pinch gesture.
247         private void OnPinchGestureDetected(object source, PinchGestureDetector.DetectedEventArgs e)
248         {
249             if (e == null)
250             {
251                 return;
252             }
253             if (e.PinchGesture.State == Gesture.StateType.Started)
254             {
255                 preScale = e.PinchGesture.Scale;
256             }
257             else if (e.PinchGesture.State == Gesture.StateType.Finished || e.PinchGesture.State == Gesture.StateType.Cancelled)
258             {
259                 if (preScale > e.PinchGesture.Scale)
260                 {
261                     if (BorderWindow.IsMaximized())
262                     {
263                         BorderWindow.Maximize(false);
264                     }
265                     else
266                     {
267                         BorderWindow.Minimize(true);
268                     }
269                 }
270                 else
271                 {
272                     BorderWindow.Maximize(true);
273                 }
274             }
275         }
276
277         /// Determines the behavior of borders.
278         private void OnPanGestureDetected(object source, PanGestureDetector.DetectedEventArgs e)
279         {
280             if (e == null)
281             {
282                 return;
283             }
284             PanGesture panGesture = e.PanGesture;
285
286             if (panGesture.State == Gesture.StateType.Started && panGesture.Position != null)
287             {
288                 direction = BorderWindow.GetDirection(panGesture.Position.X, panGesture.Position.Y);
289
290                 if (direction == Window.BorderDirection.Move)
291                 {
292                     if (BorderWindow.IsMaximized() == true)
293                     {
294                         BorderWindow.Maximize(false);
295                     }
296                     else
297                     {
298                         BorderWindow.RequestMoveToServer();
299                     }
300                 }
301                 else if (direction != Window.BorderDirection.None)
302                 {
303                     OnRequestResize();
304                     BorderWindow.RequestResizeToServer((Window.ResizeDirection)direction);
305                 }
306             }
307             else if (panGesture.State == Gesture.StateType.Finished || panGesture.State == Gesture.StateType.Cancelled)
308             {
309                 direction = Window.BorderDirection.None;
310                 ClearWindowGesture();
311             }
312         }
313
314         /// <summary>
315         /// This is an event callback when the left top corner icon is touched.
316         /// </summary>
317         [EditorBrowsable(EditorBrowsableState.Never)]
318         public virtual bool OnLeftTopCornerIconTouched(object sender, View.TouchEventArgs e)
319         {
320             if (e == null)
321             {
322                 return false;
323             }
324             if (e.Touch.GetState(0) == PointStateType.Down)
325             {
326               ClearWindowGesture();
327               OnRequestResize();
328               BorderWindow.RequestResizeToServer(Window.ResizeDirection.TopLeft);
329             }
330             return true;
331         }
332
333         /// <summary>
334         ///This is an event callback when the right bottom corner icon is touched.
335         /// </summary>
336         [EditorBrowsable(EditorBrowsableState.Never)]
337         public virtual bool OnRightTopCornerIconTouched(object sender, View.TouchEventArgs e)
338         {
339             if (e == null)
340             {
341                 return false;
342             }
343             if (e.Touch.GetState(0) == PointStateType.Down)
344             {
345               ClearWindowGesture();
346               OnRequestResize();
347               BorderWindow.RequestResizeToServer(Window.ResizeDirection.TopRight);
348             }
349             return true;
350         }
351
352
353         /// <summary>
354         /// This is an event callback when the left bottom corner icon is touched.
355         /// </summary>
356         [EditorBrowsable(EditorBrowsableState.Never)]
357         public virtual bool OnLeftBottomCornerIconTouched(object sender, View.TouchEventArgs e)
358         {
359             if (e == null)
360             {
361                 return false;
362             }
363             if (e.Touch.GetState(0) == PointStateType.Down)
364             {
365               ClearWindowGesture();
366               OnRequestResize();
367               BorderWindow.RequestResizeToServer(Window.ResizeDirection.BottomLeft);
368             }
369             return true;
370         }
371
372         /// <summary>
373         ///This is an event callback when the right bottom corner icon is touched.
374         /// </summary>
375         [EditorBrowsable(EditorBrowsableState.Never)]
376         public virtual bool OnRightBottomCornerIconTouched(object sender, View.TouchEventArgs e)
377         {
378             if (e == null)
379             {
380                 return false;
381             }
382             if (e.Touch.GetState(0) == PointStateType.Down)
383             {
384               ClearWindowGesture();
385               OnRequestResize();
386               BorderWindow.RequestResizeToServer(Window.ResizeDirection.BottomRight);
387             }
388             return true;
389         }
390
391
392         /// <summary>
393         /// This is an event callback when the minimize icon is touched.
394         /// </summary>
395         [EditorBrowsable(EditorBrowsableState.Never)]
396         public virtual bool OnMinimizeIconTouched(object sender, View.TouchEventArgs e)
397         {
398             if (e == null)
399             {
400                 return false;
401             }
402             if (e.Touch.GetState(0) == PointStateType.Up)
403             {
404                 ClearWindowGesture();
405                 BorderWindow.Minimize(true);
406             }
407             return true;
408         }
409
410         /// <summary>
411         /// This is an event callback when the maximum icon is touched.
412         /// </summary>
413         [EditorBrowsable(EditorBrowsableState.Never)]
414         public virtual bool OnMaximizeIconTouched(object sender, View.TouchEventArgs e)
415         {
416             if (e == null)
417             {
418                 return false;
419             }
420             if (e.Touch.GetState(0) == PointStateType.Up)
421             {
422                 ClearWindowGesture();
423                 if (BorderWindow.IsMaximized())
424                 {
425                   BorderWindow.Maximize(false);
426                 }
427                 else
428                 {
429                   BorderWindow.Maximize(true);
430                 }
431             }
432             return true;
433         }
434
435         /// <summary>
436         /// This is an event callback when the close icon is touched.
437         /// </summary>
438         [EditorBrowsable(EditorBrowsableState.Never)]
439         public virtual bool OnCloseIconTouched(object sender, View.TouchEventArgs e)
440         {
441             if (e == null)
442             {
443                 return false;
444             }
445             if (e.Touch.GetState(0) == PointStateType.Up)
446             {
447                 BorderWindow.Destroy();
448                 BorderWindow = null;
449             }
450             return true;
451         }
452
453
454         private void UpdateIcons()
455         {
456             if (BorderWindow != null && borderView != null)
457             {
458                 if (BorderWindow.IsMaximized() == true)
459                 {
460                     if (maximalizeIcon != null)
461                     {
462                         maximalizeIcon.ResourceUrl = DarkPreviousIcon;
463                     }
464                     if (minimalizeIcon != null)
465                     {
466                         minimalizeIcon.ResourceUrl = DarkMinimalizeIcon;
467                     }
468                     if (closeIcon != null)
469                     {
470                         closeIcon.ResourceUrl = DarkCloseIcon;
471                     }
472                     if (leftCornerIcon != null)
473                     {
474                         leftCornerIcon.ResourceUrl = DarkLeftCornerIcon;
475                     }
476                     if (rightCornerIcon != null)
477                     {
478                         rightCornerIcon.ResourceUrl = DarkRightCornerIcon;
479                     }
480                     borderView.CornerRadius = new Vector4(0, 0, 0, 0);
481                     borderView.CornerRadiusPolicy = VisualTransformPolicyType.Relative;
482                     BorderWindow.SetTransparency(false);
483                 }
484                 else
485                 {
486                     if (maximalizeIcon != null)
487                     {
488                         maximalizeIcon.ResourceUrl = MaximalizeIcon;
489                     }
490                     if (minimalizeIcon != null)
491                     {
492                         minimalizeIcon.ResourceUrl = MinimalizeIcon;
493                     }
494                     if (closeIcon != null)
495                     {
496                         closeIcon.ResourceUrl = CloseIcon;
497                     }
498                     if (leftCornerIcon != null)
499                     {
500                         leftCornerIcon.ResourceUrl = LeftCornerIcon;
501                     }
502                     if (rightCornerIcon != null)
503                     {
504                         rightCornerIcon.ResourceUrl = RightCornerIcon;
505                     }
506                     borderView.CornerRadius = new Vector4(0.03f, 0.03f, 0.03f, 0.03f);
507                     borderView.CornerRadiusPolicy = VisualTransformPolicyType.Relative;
508                     BorderWindow.SetTransparency(true);
509                 }
510             }
511         }
512
513
514         /// <summary>
515         /// Called after the border UI is created.
516         /// </summary>
517         /// <param name="borderView">The border view on which the border.</param>
518         [EditorBrowsable(EditorBrowsableState.Never)]
519         public virtual void OnCreated(View borderView)
520         {
521             if (borderView == null)
522             {
523                 return;
524             }
525             // Register to resize and move through pan gestures.
526             borderPanGestureDetector = new PanGestureDetector();
527             borderPanGestureDetector.Attach(borderView);
528             borderPanGestureDetector.Detected += OnPanGestureDetected;
529
530             // Register touch event for effect when border is touched.
531             borderView.LeaveRequired = true;
532             borderView.TouchEvent += (s, e) =>
533             {
534                 if (e.Touch.GetState(0) == PointStateType.Started)
535                 {
536                     if (BorderWindow.IsMaximized() == false)
537                     {
538                         BorderWindow.Raise();
539                     }
540                     backgroundColor = new Color(borderView.BackgroundColor);
541                     borderView.BackgroundColor = DefaultClickedBackgroundColor;
542                 }
543                 else if (e.Touch.GetState(0) == PointStateType.Finished ||
544                          e.Touch.GetState(0) == PointStateType.Leave ||
545                          e.Touch.GetState(0) == PointStateType.Interrupted)
546                 {
547                     borderView.BackgroundColor = backgroundColor;
548                 }
549                 return true;
550             };
551
552             borderPinchGestureDetector = new PinchGestureDetector();
553             borderPinchGestureDetector.Attach(borderView);
554             borderPinchGestureDetector.Detected += OnPinchGestureDetected;
555
556             AddInterceptGesture();
557
558             UpdateIcons();
559         }
560
561
562         // Register an intercept touch event on the window.
563         private void AddInterceptGesture()
564         {
565             isWinGestures = false;
566             BorderWindow.InterceptTouchEvent += OnWinInterceptedTouch;
567         }
568
569         // Intercept touch on window.
570         private bool OnWinInterceptedTouch(object sender, Window.TouchEventArgs e)
571         {
572             if (e.Touch.GetState(0) == PointStateType.Stationary && e.Touch.GetPointCount() == 2)
573             {
574                 if (isWinGestures == false && timer == null)
575                 {
576                     timer = new Timer(300);
577                     timer.Tick += OnTick;
578                     timer.Start();
579                 }
580             }
581             else
582             {
583                 currentGesture = CurrentGesture.None;
584                 if (timer != null)
585                 {
586                     timer.Stop();
587                     timer.Dispose();
588                     timer = null;
589                 }
590             }
591             return false;
592         }
593
594         // If two finger long press is done, create a windowView.
595         // then, Register a gesture on the windowView to do a resize or move.
596         private bool OnTick(object o, Timer.TickEventArgs e)
597         {
598             windowView = new View()
599             {
600                 WidthResizePolicy = ResizePolicyType.FillToParent,
601                 HeightResizePolicy = ResizePolicyType.FillToParent,
602                 BackgroundColor = new Color(1, 1, 1, 0.5f),
603             };
604             windowView.TouchEvent += (s, e) =>
605             {
606                 return true;
607             };
608             BorderWindow.Add(windowView);
609
610             winTapGestureDetector = new TapGestureDetector();
611             winTapGestureDetector.Attach(windowView);
612             winTapGestureDetector.SetMaximumTapsRequired(3);
613             winTapGestureDetector.Detected += OnWinTapGestureDetected;
614
615             winPanGestureDetector = new PanGestureDetector();
616             winPanGestureDetector.Attach(windowView);
617             winPanGestureDetector.Detected += OnWinPanGestureDetected;
618
619             BorderWindow.InterceptTouchEvent -= OnWinInterceptedTouch;
620             isWinGestures = true;
621             return false;
622         }
623
624         // Behavior when the window is tapped.
625         private void OnWinTapGestureDetected(object source, TapGestureDetector.DetectedEventArgs e)
626         {
627           if (currentGesture <= CurrentGesture.TapGesture)
628           {
629               currentGesture = CurrentGesture.TapGesture;
630               if (e.TapGesture.NumberOfTaps == 2)
631               {
632                   if (BorderWindow.IsMaximized() == false)
633                   {
634                     BorderWindow.Maximize(true);
635                   }
636                   else
637                   {
638                     BorderWindow.Maximize(false);
639                   }
640               }
641               else
642               {
643                   ClearWindowGesture();
644               }
645           }
646         }
647
648         // Window moves through pan gestures.
649         private void OnWinPanGestureDetected(object source, PanGestureDetector.DetectedEventArgs e)
650         {
651             if (currentGesture <= CurrentGesture.PanGesture /*&& panGesture.NumberOfTouches == 1*/)
652             {
653                 PanGesture panGesture = e.PanGesture;
654
655                 if (panGesture.State == Gesture.StateType.Started)
656                 {
657                     currentGesture = CurrentGesture.PanGesture;
658                     if (BorderWindow.IsMaximized() == true)
659                     {
660                         BorderWindow.Maximize(false);
661                     }
662                     else
663                     {
664                         BorderWindow.RequestMoveToServer();
665                     }
666                 }
667                 else if (panGesture.State == Gesture.StateType.Finished || panGesture.State == Gesture.StateType.Cancelled)
668                 {
669                     currentGesture = CurrentGesture.None;
670                     ClearWindowGesture();
671                 }
672             }
673         }
674
675         private void ClearWindowGesture()
676         {
677             if (isWinGestures)
678             {
679                 winPanGestureDetector.Dispose();
680                 winTapGestureDetector.Dispose();
681
682                 isWinGestures = false;
683                 BorderWindow.Remove(windowView);
684                 BorderWindow.InterceptTouchEvent += OnWinInterceptedTouch;
685             }
686         }
687
688         /// <summary>
689         /// Called when requesting a resize
690         /// </summary>
691         [EditorBrowsable(EditorBrowsableState.Never)]
692         public virtual void OnRequestResize() {}
693
694         /// <summary>
695         /// Called when the window is resized.
696         /// </summary>
697         /// <param name="width">The width of the resized window</param>
698         /// <param name="height">The height of the resized window</param>
699         [EditorBrowsable(EditorBrowsableState.Never)]
700         public virtual void OnResized(int width, int height)
701         {
702             UpdateIcons();
703         }
704
705         [EditorBrowsable(EditorBrowsableState.Never)]
706         protected virtual void Dispose(bool disposing)
707         {
708             if (disposed)
709             {
710                 return;
711             }
712             if (disposing)
713             {
714                 ClearWindowGesture();
715
716                 if (BorderWindow != null)
717                 {
718                     BorderWindow.InterceptTouchEvent -= OnWinInterceptedTouch;
719                 }
720
721                 borderPanGestureDetector?.Dispose();
722                 borderPinchGestureDetector?.Dispose();
723                 backgroundColor?.Dispose();
724                 minimalizeIcon?.Dispose();
725                 maximalizeIcon?.Dispose();
726                 closeIcon?.Dispose();
727                 leftCornerIcon?.Dispose();
728                 rightCornerIcon?.Dispose();
729                 timer?.Dispose();
730                 windowView?.Dispose();
731                 borderView?.Dispose();
732             }
733             disposed = true;
734         }
735
736         /// <summary>
737         /// Dispose
738         /// </summary>
739         [EditorBrowsable(EditorBrowsableState.Never)]
740         public void Dispose()
741         {
742             Dispose(true);
743             global::System.GC.SuppressFinalize(this);
744         }
745         #endregion //Methods
746
747     }
748 }