[NUI] Change all CallingConvention to `Cdecl`
[platform/core/csapi/tizenfx.git] / src / Tizen.NUI / src / public / Accessibility / AccessibilityManagerEvent.cs
1 /*
2  * Copyright(c) 2021 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 System.Runtime.InteropServices;
21
22 namespace Tizen.NUI.Accessibility
23 {
24     public partial class AccessibilityManager
25     {
26         [UnmanagedFunctionPointer(CallingConvention.Cdecl)]
27         private delegate bool StatusChangedEventCallbackDelegate(IntPtr accessibilityManager);
28         private ReturnTypeEventHandler<object, EventArgs, bool> accessibilityManagerStatusChangedEventHandler;
29         private StatusChangedEventCallbackDelegate accessibilityManagerStatusChangedEventCallbackDelegate;
30
31         [UnmanagedFunctionPointer(CallingConvention.Cdecl)]
32         private delegate bool ActionNextEventCallbackDelegate(IntPtr accessibilityManager);
33         private ReturnTypeEventHandler<object, EventArgs, bool> accessibilityManagerActionNextEventHandler;
34         private ActionNextEventCallbackDelegate accessibilityManagerActionNextEventCallbackDelegate;
35
36         [UnmanagedFunctionPointer(CallingConvention.Cdecl)]
37         private delegate bool ActionPreviousEventCallbackDelegate(IntPtr accessibilityManager);
38         private ReturnTypeEventHandler<object, EventArgs, bool> accessibilityManagerActionPreviousEventHandler;
39         private ActionPreviousEventCallbackDelegate accessibilityManagerActionPreviousEventCallbackDelegate;
40
41         [UnmanagedFunctionPointer(CallingConvention.Cdecl)]
42         private delegate bool ActionActivateEventCallbackDelegate(IntPtr accessibilityManager);
43         private ReturnTypeEventHandler<object, EventArgs, bool> accessibilityManagerActionActivateEventHandler;
44         private ActionActivateEventCallbackDelegate accessibilityManagerActionActivateEventCallbackDelegate;
45
46         [UnmanagedFunctionPointer(CallingConvention.Cdecl)]
47         private delegate bool ActionReadEventCallbackDelegate(IntPtr accessibilityManager);
48         private ReturnTypeEventHandler<object, EventArgs, bool> accessibilityManagerActionReadEventHandler;
49         private ActionReadEventCallbackDelegate accessibilityManagerActionReadEventCallbackDelegate;
50
51         [UnmanagedFunctionPointer(CallingConvention.Cdecl)]
52         private delegate bool ActionOverEventCallbackDelegate(IntPtr accessibilityManager);
53         private ReturnTypeEventHandler<object, EventArgs, bool> accessibilityManagerActionOverEventHandler;
54         private ActionOverEventCallbackDelegate accessibilityManagerActionOverEventCallbackDelegate;
55
56         [UnmanagedFunctionPointer(CallingConvention.Cdecl)]
57         private delegate bool ActionReadNextEventCallbackDelegate(IntPtr accessibilityManager);
58         private ReturnTypeEventHandler<object, EventArgs, bool> accessibilityManagerActionReadNextEventHandler;
59         private ActionReadNextEventCallbackDelegate accessibilityManagerActionReadNextEventCallbackDelegate;
60
61         [UnmanagedFunctionPointer(CallingConvention.Cdecl)]
62         private delegate bool ActionReadPreviousEventCallbackDelegate(IntPtr accessibilityManager);
63         private ReturnTypeEventHandler<object, EventArgs, bool> accessibilityManagerActionReadPreviousEventHandler;
64         private ActionReadPreviousEventCallbackDelegate accessibilityManagerActionReadPreviousEventCallbackDelegate;
65
66         [UnmanagedFunctionPointer(CallingConvention.Cdecl)]
67         private delegate bool ActionUpEventCallbackDelegate(IntPtr accessibilityManager);
68         private ReturnTypeEventHandler<object, EventArgs, bool> accessibilityManagerActionUpEventHandler;
69         private ActionUpEventCallbackDelegate accessibilityManagerActionUpEventCallbackDelegate;
70
71         [UnmanagedFunctionPointer(CallingConvention.Cdecl)]
72         private delegate bool ActionDownEventCallbackDelegate(IntPtr accessibilityManager);
73         private ReturnTypeEventHandler<object, EventArgs, bool> accessibilityManagerActionDownEventHandler;
74         private ActionDownEventCallbackDelegate accessibilityManagerActionDownEventCallbackDelegate;
75
76         [UnmanagedFunctionPointer(CallingConvention.Cdecl)]
77         private delegate bool ActionClearFocusEventCallbackDelegate(IntPtr accessibilityManager);
78         private ReturnTypeEventHandler<object, EventArgs, bool> accessibilityManagerActionClearFocusEventHandler;
79         private ActionClearFocusEventCallbackDelegate accessibilityManagerActionClearFocusEventCallbackDelegate;
80
81         [UnmanagedFunctionPointer(CallingConvention.Cdecl)]
82         private delegate bool ActionBackEventCallbackDelegate(IntPtr accessibilityManager);
83         private ReturnTypeEventHandler<object, EventArgs, bool> accessibilityManagerActionBackEventHandler;
84         private ActionBackEventCallbackDelegate accessibilityManagerActionBackEventCallbackDelegate;
85
86         [UnmanagedFunctionPointer(CallingConvention.Cdecl)]
87         private delegate bool ActionScrollUpEventCallbackDelegate(IntPtr accessibilityManager);
88         private ReturnTypeEventHandler<object, EventArgs, bool> accessibilityManagerActionScrollUpEventHandler;
89         private ActionScrollUpEventCallbackDelegate accessibilityManagerActionScrollUpEventCallbackDelegate;
90
91         [UnmanagedFunctionPointer(CallingConvention.Cdecl)]
92         private delegate bool ActionScrollDownEventCallbackDelegate(IntPtr accessibilityManager);
93         private ReturnTypeEventHandler<object, EventArgs, bool> accessibilityManagerActionScrollDownEventHandler;
94         private ActionScrollDownEventCallbackDelegate accessibilityManagerActionScrollDownEventCallbackDelegate;
95
96         [UnmanagedFunctionPointer(CallingConvention.Cdecl)]
97         private delegate bool ActionPageLeftEventCallbackDelegate(IntPtr accessibilityManager);
98         private ReturnTypeEventHandler<object, EventArgs, bool> accessibilityManagerActionPageLeftEventHandler;
99         private ActionPageLeftEventCallbackDelegate accessibilityManagerActionPageLeftEventCallbackDelegate;
100
101         [UnmanagedFunctionPointer(CallingConvention.Cdecl)]
102         private delegate bool ActionPageRightEventCallbackDelegate(IntPtr accessibilityManager);
103         private ReturnTypeEventHandler<object, EventArgs, bool> accessibilityManagerActionPageRightEventHandler;
104         private ActionPageRightEventCallbackDelegate accessibilityManagerActionPageRightEventCallbackDelegate;
105
106         [UnmanagedFunctionPointer(CallingConvention.Cdecl)]
107         private delegate bool ActionPageUpEventCallbackDelegate(IntPtr accessibilityManager);
108         private ReturnTypeEventHandler<object, EventArgs, bool> accessibilityManagerActionPageUpEventHandler;
109         private ActionPageUpEventCallbackDelegate accessibilityManagerActionPageUpEventCallbackDelegate;
110
111         [UnmanagedFunctionPointer(CallingConvention.Cdecl)]
112         private delegate bool ActionPageDownEventCallbackDelegate(IntPtr accessibilityManager);
113         private ReturnTypeEventHandler<object, EventArgs, bool> accessibilityManagerActionPageDownEventHandler;
114         private ActionPageDownEventCallbackDelegate accessibilityManagerActionPageDownEventCallbackDelegate;
115
116         [UnmanagedFunctionPointer(CallingConvention.Cdecl)]
117         private delegate bool ActionMoveToFirstEventCallbackDelegate(IntPtr accessibilityManager);
118         private ReturnTypeEventHandler<object, EventArgs, bool> accessibilityManagerActionMoveToFirstEventHandler;
119         private ActionMoveToFirstEventCallbackDelegate accessibilityManagerActionMoveToFirstEventCallbackDelegate;
120
121         [UnmanagedFunctionPointer(CallingConvention.Cdecl)]
122         private delegate bool ActionMoveToLastEventCallbackDelegate(IntPtr accessibilityManager);
123         private ReturnTypeEventHandler<object, EventArgs, bool> accessibilityManagerActionMoveToLastEventHandler;
124         private ActionMoveToLastEventCallbackDelegate accessibilityManagerActionMoveToLastEventCallbackDelegate;
125
126         [UnmanagedFunctionPointer(CallingConvention.Cdecl)]
127         private delegate bool ActionReadFromTopEventCallbackDelegate(IntPtr accessibilityManager);
128         private ReturnTypeEventHandler<object, EventArgs, bool> accessibilityManagerActionReadFromTopEventHandler;
129         private ActionReadFromTopEventCallbackDelegate accessibilityManagerActionReadFromTopEventCallbackDelegate;
130
131         [UnmanagedFunctionPointer(CallingConvention.Cdecl)]
132         private delegate bool ActionReadFromNextEventCallbackDelegate(IntPtr accessibilityManager);
133         private ReturnTypeEventHandler<object, EventArgs, bool> accessibilityManagerActionReadFromNextEventHandler;
134         private ActionReadFromNextEventCallbackDelegate accessibilityManagerActionReadFromNextEventCallbackDelegate;
135
136         [UnmanagedFunctionPointer(CallingConvention.Cdecl)]
137         private delegate bool ActionZoomEventCallbackDelegate(IntPtr accessibilityManager);
138         private ReturnTypeEventHandler<object, EventArgs, bool> accessibilityManagerActionZoomEventHandler;
139         private ActionZoomEventCallbackDelegate accessibilityManagerActionZoomEventCallbackDelegate;
140
141         [UnmanagedFunctionPointer(CallingConvention.Cdecl)]
142         private delegate bool ActionReadPauseResumeEventCallbackDelegate(IntPtr accessibilityManager);
143         private ReturnTypeEventHandler<object, EventArgs, bool> accessibilityManagerActionReadPauseResumeEventHandler;
144         private ActionReadPauseResumeEventCallbackDelegate accessibilityManagerActionReadPauseResumeEventCallbackDelegate;
145
146         [UnmanagedFunctionPointer(CallingConvention.Cdecl)]
147         private delegate bool ActionStartStopEventCallbackDelegate(IntPtr accessibilityManager);
148         private ReturnTypeEventHandler<object, EventArgs, bool> accessibilityManagerActionStartStopEventHandler;
149         private ActionStartStopEventCallbackDelegate accessibilityManagerActionStartStopEventCallbackDelegate;
150
151         [UnmanagedFunctionPointer(CallingConvention.Cdecl)]
152         private delegate void FocusChangedEventCallbackDelegate(IntPtr view1, IntPtr view2);
153         private EventHandler<FocusChangedEventArgs> accessibilityManagerFocusChangedEventHandler;
154         private FocusChangedEventCallbackDelegate accessibilityManagerFocusChangedEventCallbackDelegate;
155
156         [UnmanagedFunctionPointer(CallingConvention.Cdecl)]
157         private delegate void FocusedViewActivatedEventCallbackDelegate(IntPtr view);
158         private EventHandler<FocusedViewActivatedEventArgs> accessibilityManagerFocusedViewActivatedEventHandler;
159         private FocusedViewActivatedEventCallbackDelegate accessibilityManagerFocusedViewActivatedEventCallbackDelegate;
160
161         [UnmanagedFunctionPointer(CallingConvention.Cdecl)]
162         private delegate void FocusOvershotEventCallbackDelegate(IntPtr currentFocusedView, AccessibilityManager.FocusOvershotDirection direction);
163         private EventHandler<FocusOvershotEventArgs> accessibilityManagerFocusOvershotEventHandler;
164         private FocusOvershotEventCallbackDelegate accessibilityManagerFocusOvershotEventCallbackDelegate;
165
166         // Accessibility action signals
167
168         /// <summary>
169         /// This is emitted when accessibility(screen-reader) feature turned on or off.
170         /// </summary>
171         /// <returns> The signal to connect to </returns>
172         /// <since_tizen> 6 </since_tizen>
173         /// This will be public opened in tizen_6.0 after ACR done. Before ACR, need to be hidden as inhouse API.
174         [EditorBrowsable(EditorBrowsableState.Never)]
175         public event ReturnTypeEventHandler<object, EventArgs, bool> StatusChanged
176         {
177             add
178             {
179                 // Restricted to only one listener
180                 if (accessibilityManagerStatusChangedEventHandler == null)
181                 {
182                     accessibilityManagerStatusChangedEventCallbackDelegate = new StatusChangedEventCallbackDelegate(OnStatusChanged);
183                     this.StatusChangedSignal().Connect(accessibilityManagerStatusChangedEventCallbackDelegate);
184                 }
185
186                 accessibilityManagerStatusChangedEventHandler += value;
187             }
188
189             remove
190             {
191                 accessibilityManagerStatusChangedEventHandler -= value;
192
193                 if (accessibilityManagerStatusChangedEventHandler == null && StatusChangedSignal().Empty() == false)
194                 {
195                     this.StatusChangedSignal().Disconnect(accessibilityManagerStatusChangedEventCallbackDelegate);
196                 }
197
198             }
199         }
200
201         /// <summary>
202         /// This is emitted when accessibility action is received to move focus to the next focusable view (by one finger flick down).
203         /// </summary>
204         /// <returns> The signal to connect to </returns>
205         /// <since_tizen> 6 </since_tizen>
206         /// This will be public opened in tizen_6.0 after ACR done. Before ACR, need to be hidden as inhouse API.
207         [EditorBrowsable(EditorBrowsableState.Never)]
208         public event ReturnTypeEventHandler<object, EventArgs, bool> ActionNext
209         {
210             add
211             {
212                 // Restricted to only one listener
213                 if (accessibilityManagerActionNextEventHandler == null)
214                 {
215                     accessibilityManagerActionNextEventCallbackDelegate = new ActionNextEventCallbackDelegate(OnActionNext);
216                     this.ActionNextSignal().Connect(accessibilityManagerActionNextEventCallbackDelegate);
217                 }
218
219                 accessibilityManagerActionNextEventHandler += value;
220             }
221
222             remove
223             {
224                 accessibilityManagerActionNextEventHandler -= value;
225
226                 if (accessibilityManagerActionNextEventHandler == null && ActionNextSignal().Empty() == false)
227                 {
228                     this.ActionNextSignal().Disconnect(accessibilityManagerActionNextEventCallbackDelegate);
229                 }
230             }
231         }
232
233         /// <summary>
234         /// This is emitted when accessibility action is received to move focus to the previous focusable view (by one finger flick up).
235         /// </summary>
236         /// <returns> The signal to connect to </returns>
237         /// <since_tizen> 6 </since_tizen>
238         /// This will be public opened in tizen_6.0 after ACR done. Before ACR, need to be hidden as inhouse API.
239         [EditorBrowsable(EditorBrowsableState.Never)]
240         public event ReturnTypeEventHandler<object, EventArgs, bool> ActionPrevious
241         {
242             add
243             {
244                 // Restricted to only one listener
245                 if (accessibilityManagerActionPreviousEventHandler == null)
246                 {
247                     accessibilityManagerActionPreviousEventCallbackDelegate = new ActionPreviousEventCallbackDelegate(OnActionPrevious);
248                     this.ActionPreviousSignal().Connect(accessibilityManagerActionPreviousEventCallbackDelegate);
249                 }
250
251                 accessibilityManagerActionPreviousEventHandler += value;
252             }
253
254             remove
255             {
256                 accessibilityManagerActionPreviousEventHandler -= value;
257
258                 if (accessibilityManagerActionPreviousEventHandler == null && ActionPreviousSignal().Empty() == false)
259                 {
260                     this.ActionPreviousSignal().Disconnect(accessibilityManagerActionPreviousEventCallbackDelegate);
261                 }
262             }
263         }
264
265         /// <summary>
266         /// This is emitted when accessibility action is received to activate the current focused view (by one finger double tap).
267         /// </summary>
268         /// <returns> The signal to connect to </returns>
269         /// <since_tizen> 6 </since_tizen>
270         /// This will be public opened in tizen_6.0 after ACR done. Before ACR, need to be hidden as inhouse API.
271         [EditorBrowsable(EditorBrowsableState.Never)]
272         public event ReturnTypeEventHandler<object, EventArgs, bool> ActionActivate
273         {
274             add
275             {
276                 // Restricted to only one listener
277                 if (accessibilityManagerActionActivateEventHandler == null)
278                 {
279                     accessibilityManagerActionActivateEventCallbackDelegate = new ActionActivateEventCallbackDelegate(OnActionActivate);
280                     this.ActionActivateSignal().Connect(accessibilityManagerActionActivateEventCallbackDelegate);
281                 }
282
283                 accessibilityManagerActionActivateEventHandler += value;
284             }
285
286             remove
287             {
288                 accessibilityManagerActionActivateEventHandler -= value;
289
290                 if (accessibilityManagerActionActivateEventHandler == null && ActionActivateSignal().Empty() == false)
291                 {
292                     this.ActionActivateSignal().Disconnect(accessibilityManagerActionActivateEventCallbackDelegate);
293                 }
294             }
295         }
296
297         /// <summary>
298         /// This is emitted when accessibility action is received to focus and read the view (by one finger tap).
299         /// </summary>
300         /// <returns> The signal to connect to </returns>
301         /// <since_tizen> 6 </since_tizen>
302         /// This will be public opened in tizen_6.0 after ACR done. Before ACR, need to be hidden as inhouse API.
303         [EditorBrowsable(EditorBrowsableState.Never)]
304         public event ReturnTypeEventHandler<object, EventArgs, bool> ActionRead
305         {
306             add
307             {
308                 // Restricted to only one listener
309                 if (accessibilityManagerActionReadEventHandler == null)
310                 {
311                     accessibilityManagerActionReadEventCallbackDelegate = new ActionReadEventCallbackDelegate(OnActionRead);
312                     this.ActionReadSignal().Connect(accessibilityManagerActionReadEventCallbackDelegate);
313                 }
314
315                 accessibilityManagerActionReadEventHandler += value;
316             }
317
318             remove
319             {
320                 accessibilityManagerActionReadEventHandler -= value;
321
322                 if (accessibilityManagerActionReadEventHandler == null && ActionReadSignal().Empty() == false)
323                 {
324                     this.ActionReadSignal().Disconnect(accessibilityManagerActionReadEventCallbackDelegate);
325                 }
326             }
327         }
328
329         /// <summary>
330         /// This is emitted when accessibility action is received to focus and read the view  (by one finger move).
331         /// </summary>
332         /// <returns> The signal to connect to </returns>
333         /// <since_tizen> 6 </since_tizen>
334         /// This will be public opened in tizen_6.0 after ACR done. Before ACR, need to be hidden as inhouse API.
335         [EditorBrowsable(EditorBrowsableState.Never)]
336         public event ReturnTypeEventHandler<object, EventArgs, bool> ActionOver
337         {
338             add
339             {
340                 // Restricted to only one listener
341                 if (accessibilityManagerActionOverEventHandler == null)
342                 {
343                     accessibilityManagerActionOverEventCallbackDelegate = new ActionOverEventCallbackDelegate(OnActionOver);
344                     this.ActionOverSignal().Connect(accessibilityManagerActionOverEventCallbackDelegate);
345                 }
346
347                 accessibilityManagerActionOverEventHandler += value;
348             }
349
350             remove
351             {
352                 accessibilityManagerActionOverEventHandler -= value;
353
354                 if (accessibilityManagerActionOverEventHandler == null && ActionOverSignal().Empty() == false)
355                 {
356                     this.ActionOverSignal().Disconnect(accessibilityManagerActionOverEventCallbackDelegate);
357                 }
358
359             }
360         }
361
362         /// <summary>
363         /// This is emitted when accessibility action is received to move focus to the next focusable view (by one finger flick right).
364         /// </summary>
365         /// <returns> The signal to connect to </returns>
366         /// <since_tizen> 6 </since_tizen>
367         /// This will be public opened in tizen_6.0 after ACR done. Before ACR, need to be hidden as inhouse API.
368         [EditorBrowsable(EditorBrowsableState.Never)]
369         public event ReturnTypeEventHandler<object, EventArgs, bool> ActionReadNext
370         {
371             add
372             {
373                 // Restricted to only one listener
374                 if (accessibilityManagerActionReadNextEventHandler == null)
375                 {
376                     accessibilityManagerActionReadNextEventCallbackDelegate = new ActionReadNextEventCallbackDelegate(OnActionReadNext);
377                     this.ActionReadNextSignal().Connect(accessibilityManagerActionReadNextEventCallbackDelegate);
378                 }
379
380                 accessibilityManagerActionReadNextEventHandler += value;
381             }
382
383             remove
384             {
385                 accessibilityManagerActionReadNextEventHandler -= value;
386
387                 if (accessibilityManagerActionReadNextEventHandler == null && ActionReadNextSignal().Empty() == false)
388                 {
389                     this.ActionReadNextSignal().Disconnect(accessibilityManagerActionReadNextEventCallbackDelegate);
390                 }
391             }
392         }
393
394         /// <summary>
395         /// This is emitted when accessibility action is received to move focus to the previous focusable view (by one finger flick left).
396         /// </summary>
397         /// <returns> The signal to connect to </returns>
398         /// <since_tizen> 6 </since_tizen>
399         /// This will be public opened in tizen_6.0 after ACR done. Before ACR, need to be hidden as inhouse API.
400         [EditorBrowsable(EditorBrowsableState.Never)]
401         public event ReturnTypeEventHandler<object, EventArgs, bool> ActionReadPrevious
402         {
403             add
404             {
405                 // Restricted to only one listener
406                 if (accessibilityManagerActionReadPreviousEventHandler == null)
407                 {
408                     accessibilityManagerActionReadPreviousEventCallbackDelegate = new ActionReadPreviousEventCallbackDelegate(OnActionReadPrevious);
409                     this.ActionReadPreviousSignal().Connect(accessibilityManagerActionReadPreviousEventCallbackDelegate);
410                 }
411
412                 accessibilityManagerActionReadPreviousEventHandler += value;
413             }
414
415             remove
416             {
417                 accessibilityManagerActionReadPreviousEventHandler -= value;
418
419                 if (accessibilityManagerActionReadPreviousEventHandler == null && ActionReadPreviousSignal().Empty() == false)
420                 {
421                     this.ActionReadPreviousSignal().Disconnect(accessibilityManagerActionReadPreviousEventCallbackDelegate);
422                 }
423             }
424         }
425
426         /// <summary>
427         /// This is emitted when accessibility action is received to change the value when the current focused view is a slider
428         /// (by double finger down and move up and right).
429         /// </summary>
430         /// <returns> The signal to connect to </returns>
431         /// <since_tizen> 6 </since_tizen>
432         /// This will be public opened in tizen_6.0 after ACR done. Before ACR, need to be hidden as inhouse API.
433         [EditorBrowsable(EditorBrowsableState.Never)]
434         public event ReturnTypeEventHandler<object, EventArgs, bool> ActionUp
435         {
436             add
437             {
438                 // Restricted to only one listener
439                 if (accessibilityManagerActionUpEventHandler == null)
440                 {
441                     accessibilityManagerActionUpEventCallbackDelegate = new ActionUpEventCallbackDelegate(OnActionUp);
442                     this.ActionUpSignal().Connect(accessibilityManagerActionUpEventCallbackDelegate);
443                 }
444
445                 accessibilityManagerActionUpEventHandler += value;
446             }
447
448             remove
449             {
450                 accessibilityManagerActionUpEventHandler -= value;
451
452                 if (accessibilityManagerActionUpEventHandler == null && ActionUpSignal().Empty() == false)
453                 {
454                     this.ActionUpSignal().Disconnect(accessibilityManagerActionUpEventCallbackDelegate);
455                 }
456             }
457         }
458
459         /// <summary>
460         /// This is emitted when accessibility action is received to change the value when the current focused view is a slider
461         /// (by double finger down and move down and left).
462         /// </summary>
463         /// <returns> The signal to connect to </returns>
464         /// <since_tizen> 6 </since_tizen>
465         /// This will be public opened in tizen_6.0 after ACR done. Before ACR, need to be hidden as inhouse API.
466         [EditorBrowsable(EditorBrowsableState.Never)]
467         public event ReturnTypeEventHandler<object, EventArgs, bool> ActionDown
468         {
469             add
470             {
471                 // Restricted to only one listener
472                 if (accessibilityManagerActionDownEventHandler == null)
473                 {
474                     accessibilityManagerActionDownEventCallbackDelegate = new ActionDownEventCallbackDelegate(OnActionDown);
475                     this.ActionDownSignal().Connect(accessibilityManagerActionDownEventCallbackDelegate);
476                 }
477
478                 accessibilityManagerActionDownEventHandler += value;
479             }
480
481             remove
482             {
483                 accessibilityManagerActionDownEventHandler -= value;
484
485                 if (accessibilityManagerActionDownEventHandler == null && ActionDownSignal().Empty() == false)
486                 {
487                     this.ActionDownSignal().Disconnect(accessibilityManagerActionDownEventCallbackDelegate);
488                 }
489             }
490         }
491
492         /// <summary>
493         /// This is emitted when accessibility action is received to clear the focus from the current focused view
494         /// if any, so that no view is focused in the focus chain.
495         /// </summary>
496         /// <returns> The signal to connect to </returns>
497         /// <since_tizen> 6 </since_tizen>
498         /// This will be public opened in tizen_6.0 after ACR done. Before ACR, need to be hidden as inhouse API.
499         [EditorBrowsable(EditorBrowsableState.Never)]
500         public event ReturnTypeEventHandler<object, EventArgs, bool> ActionClearFocus
501         {
502             add
503             {
504                 // Restricted to only one listener
505                 if (accessibilityManagerActionClearFocusEventHandler == null)
506                 {
507                     accessibilityManagerActionClearFocusEventCallbackDelegate = new ActionClearFocusEventCallbackDelegate(OnActionClearFocus);
508                     this.ActionClearFocusSignal().Connect(accessibilityManagerActionClearFocusEventCallbackDelegate);
509                 }
510
511                 accessibilityManagerActionClearFocusEventHandler += value;
512             }
513
514             remove
515             {
516                 accessibilityManagerActionClearFocusEventHandler -= value;
517
518                 if (accessibilityManagerActionClearFocusEventHandler == null && ActionClearFocusSignal().Empty() == false)
519                 {
520                     this.ActionClearFocusSignal().Disconnect(accessibilityManagerActionClearFocusEventCallbackDelegate);
521                 }
522             }
523         }
524
525         /// <summary>
526         /// This is emitted when accessibility action is received to navigate back (by two fingers circle draw).
527         /// </summary>
528         /// <returns> The signal to connect to </returns>
529         /// <since_tizen> 6 </since_tizen>
530         /// This will be public opened in tizen_6.0 after ACR done. Before ACR, need to be hidden as inhouse API.
531         [EditorBrowsable(EditorBrowsableState.Never)]
532         public event ReturnTypeEventHandler<object, EventArgs, bool> ActionBack
533         {
534             add
535             {
536                 // Restricted to only one listener
537                 if (accessibilityManagerActionBackEventHandler == null)
538                 {
539                     accessibilityManagerActionBackEventCallbackDelegate = new ActionBackEventCallbackDelegate(OnActionBack);
540                     this.ActionBackSignal().Connect(accessibilityManagerActionBackEventCallbackDelegate);
541                 }
542
543                 accessibilityManagerActionBackEventHandler += value;
544             }
545
546             remove
547             {
548                 accessibilityManagerActionBackEventHandler -= value;
549
550                 if (accessibilityManagerActionBackEventHandler == null && ActionBackSignal().Empty() == false)
551                 {
552                     this.ActionBackSignal().Disconnect(accessibilityManagerActionBackEventCallbackDelegate);
553                 }
554             }
555         }
556
557         /// <summary>
558         /// This is emitted when accessibility action is received to scroll up the list (by two finger swipe up).
559         /// </summary>
560         /// <returns> The signal to connect to </returns>
561         /// <since_tizen> 6 </since_tizen>
562         /// This will be public opened in tizen_6.0 after ACR done. Before ACR, need to be hidden as inhouse API.
563         [EditorBrowsable(EditorBrowsableState.Never)]
564         public event ReturnTypeEventHandler<object, EventArgs, bool> ActionScrollUp
565         {
566             add
567             {
568                 // Restricted to only one listener
569                 if (accessibilityManagerActionScrollUpEventHandler == null)
570                 {
571                     accessibilityManagerActionScrollUpEventCallbackDelegate = new ActionScrollUpEventCallbackDelegate(OnActionScrollUp);
572                     this.ActionScrollUpSignal().Connect(accessibilityManagerActionScrollUpEventCallbackDelegate);
573                 }
574
575                 accessibilityManagerActionScrollUpEventHandler += value;
576             }
577
578             remove
579             {
580                 accessibilityManagerActionScrollUpEventHandler -= value;
581
582                 if (accessibilityManagerActionScrollUpEventHandler == null && ActionScrollUpSignal().Empty() == false)
583                 {
584                     this.ActionScrollUpSignal().Disconnect(accessibilityManagerActionScrollUpEventCallbackDelegate);
585                 }
586             }
587         }
588
589         /// <summary>
590         /// This is emitted when accessibility action is received to scroll down the list (by two finger swipe down).
591         /// </summary>
592         /// <returns> The signal to connect to </returns>
593         /// <since_tizen> 6 </since_tizen>
594         /// This will be public opened in tizen_6.0 after ACR done. Before ACR, need to be hidden as inhouse API.
595         [EditorBrowsable(EditorBrowsableState.Never)]
596         public event ReturnTypeEventHandler<object, EventArgs, bool> ActionScrollDown
597         {
598             add
599             {
600                 // Restricted to only one listener
601                 if (accessibilityManagerActionScrollDownEventHandler == null)
602                 {
603                     accessibilityManagerActionScrollDownEventCallbackDelegate = new ActionScrollDownEventCallbackDelegate(OnActionScrollDown);
604                     this.ActionScrollDownSignal().Connect(accessibilityManagerActionScrollDownEventCallbackDelegate);
605                 }
606
607                 accessibilityManagerActionScrollDownEventHandler += value;
608             }
609
610             remove
611             {
612                 accessibilityManagerActionScrollDownEventHandler -= value;
613
614                 if (accessibilityManagerActionScrollDownEventHandler == null && ActionScrollDownSignal().Empty() == false)
615                 {
616                     this.ActionScrollDownSignal().Disconnect(accessibilityManagerActionScrollDownEventCallbackDelegate);
617                 }
618             }
619         }
620
621         /// <summary>
622         /// This is emitted when accessibility action is received to scroll left to the previous page (by two finger swipe left).
623         /// </summary>
624         /// <returns> The signal to connect to </returns>
625         /// <since_tizen> 6 </since_tizen>
626         /// This will be public opened in tizen_6.0 after ACR done. Before ACR, need to be hidden as inhouse API.
627         [EditorBrowsable(EditorBrowsableState.Never)]
628         public event ReturnTypeEventHandler<object, EventArgs, bool> ActionPageLeft
629         {
630             add
631             {
632                 // Restricted to only one listener
633                 if (accessibilityManagerActionPageLeftEventHandler == null)
634                 {
635                     accessibilityManagerActionPageLeftEventCallbackDelegate = new ActionPageLeftEventCallbackDelegate(OnActionPageLeft);
636                     this.ActionPageLeftSignal().Connect(accessibilityManagerActionPageLeftEventCallbackDelegate);
637                 }
638
639                 accessibilityManagerActionPageLeftEventHandler += value;
640             }
641
642             remove
643             {
644                 accessibilityManagerActionPageLeftEventHandler -= value;
645
646                 if (accessibilityManagerActionPageLeftEventHandler == null && ActionPageLeftSignal().Empty() == false)
647                 {
648                     this.ActionPageLeftSignal().Disconnect(accessibilityManagerActionPageLeftEventCallbackDelegate);
649                 }
650             }
651         }
652
653         /// <summary>
654         /// This is emitted when accessibility action is received to scroll right to the next page (by two finger swipe right).
655         /// </summary>
656         /// <returns> The signal to connect to </returns>
657         /// <since_tizen> 6 </since_tizen>
658         /// This will be public opened in tizen_6.0 after ACR done. Before ACR, need to be hidden as inhouse API.
659         [EditorBrowsable(EditorBrowsableState.Never)]
660         public event ReturnTypeEventHandler<object, EventArgs, bool> ActionPageRight
661         {
662             add
663             {
664                 // Restricted to only one listener
665                 if (accessibilityManagerActionPageRightEventHandler == null)
666                 {
667                     accessibilityManagerActionPageRightEventCallbackDelegate = new ActionPageRightEventCallbackDelegate(OnActionPageRight);
668                     this.ActionPageRightSignal().Connect(accessibilityManagerActionPageRightEventCallbackDelegate);
669                 }
670
671                 accessibilityManagerActionPageRightEventHandler += value;
672             }
673
674             remove
675             {
676                 accessibilityManagerActionPageRightEventHandler -= value;
677
678                 if (accessibilityManagerActionPageRightEventHandler == null && ActionPageRightSignal().Empty() == false)
679                 {
680                     this.ActionPageRightSignal().Disconnect(accessibilityManagerActionPageRightEventCallbackDelegate);
681                 }
682             }
683         }
684
685         /// <summary>
686         /// This is emitted when accessibility action is received to scroll up to the previous page (by one finger swipe left and right).
687         /// </summary>
688         /// <returns> The signal to connect to </returns>
689         /// <since_tizen> 6 </since_tizen>
690         /// This will be public opened in tizen_6.0 after ACR done. Before ACR, need to be hidden as inhouse API.
691         [EditorBrowsable(EditorBrowsableState.Never)]
692         public event ReturnTypeEventHandler<object, EventArgs, bool> ActionPageUp
693         {
694             add
695             {
696                 // Restricted to only one listener
697                 if (accessibilityManagerActionPageUpEventHandler == null)
698                 {
699                     accessibilityManagerActionPageUpEventCallbackDelegate = new ActionPageUpEventCallbackDelegate(OnActionPageUp);
700                     this.ActionPageUpSignal().Connect(accessibilityManagerActionPageUpEventCallbackDelegate);
701                 }
702
703                 accessibilityManagerActionPageUpEventHandler += value;
704             }
705
706             remove
707             {
708                 accessibilityManagerActionPageUpEventHandler -= value;
709
710                 if (accessibilityManagerActionPageUpEventHandler == null && ActionPageUpSignal().Empty() == false)
711                 {
712                     this.ActionPageUpSignal().Disconnect(accessibilityManagerActionPageUpEventCallbackDelegate);
713                 }
714             }
715         }
716
717         /// <summary>
718         /// This is emitted when accessibility action is received to scroll down to the next page (by one finger swipe right and left).
719         /// </summary>
720         /// <returns> The signal to connect to </returns>
721         /// <since_tizen> 6 </since_tizen>
722         /// This will be public opened in tizen_6.0 after ACR done. Before ACR, need to be hidden as inhouse API.
723         [EditorBrowsable(EditorBrowsableState.Never)]
724         public event ReturnTypeEventHandler<object, EventArgs, bool> ActionPageDown
725         {
726             add
727             {
728                 // Restricted to only one listener
729                 if (accessibilityManagerActionPageDownEventHandler == null)
730                 {
731                     accessibilityManagerActionPageDownEventCallbackDelegate = new ActionPageDownEventCallbackDelegate(OnActionPageDown);
732                     this.ActionPageDownSignal().Connect(accessibilityManagerActionPageDownEventCallbackDelegate);
733                 }
734
735                 accessibilityManagerActionPageDownEventHandler += value;
736             }
737
738             remove
739             {
740                 accessibilityManagerActionPageDownEventHandler -= value;
741
742                 if (accessibilityManagerActionPageDownEventHandler == null && ActionPageDownSignal().Empty() == false)
743                 {
744                     this.ActionPageDownSignal().Disconnect(accessibilityManagerActionPageDownEventCallbackDelegate);
745                 }
746             }
747         }
748
749         /// <summary>
750         /// This is emitted when accessibility action is received to move the focus to the first item on the screen
751         /// (by one finger swipe up and down).
752         /// </summary>
753         /// <returns> The signal to connect to </returns>
754         /// <since_tizen> 6 </since_tizen>
755         /// This will be public opened in tizen_6.0 after ACR done. Before ACR, need to be hidden as inhouse API.
756         [EditorBrowsable(EditorBrowsableState.Never)]
757         public event ReturnTypeEventHandler<object, EventArgs, bool> ActionMoveToFirst
758         {
759             add
760             {
761                 // Restricted to only one listener
762                 if (accessibilityManagerActionMoveToFirstEventHandler == null)
763                 {
764                     accessibilityManagerActionMoveToFirstEventCallbackDelegate = new ActionMoveToFirstEventCallbackDelegate(OnActionMoveToFirst);
765                     this.ActionMoveToFirstSignal().Connect(accessibilityManagerActionMoveToFirstEventCallbackDelegate);
766                 }
767
768                 accessibilityManagerActionMoveToFirstEventHandler += value;
769             }
770
771             remove
772             {
773                 accessibilityManagerActionMoveToFirstEventHandler -= value;
774
775                 if (accessibilityManagerActionMoveToFirstEventHandler == null && ActionMoveToFirstSignal().Empty() == false)
776                 {
777                     this.ActionMoveToFirstSignal().Disconnect(accessibilityManagerActionMoveToFirstEventCallbackDelegate);
778                 }
779             }
780         }
781
782         /// <summary>
783         /// This is emitted when accessibility action is received to move the focus to the last item on the screen
784         /// (by one finger swipe down and up).
785         /// </summary>
786         /// <returns> The signal to connect to </returns>
787         /// <since_tizen> 6 </since_tizen>
788         /// This will be public opened in tizen_6.0 after ACR done. Before ACR, need to be hidden as inhouse API.
789         [EditorBrowsable(EditorBrowsableState.Never)]
790         public event ReturnTypeEventHandler<object, EventArgs, bool> ActionMoveToLast
791         {
792             add
793             {
794                 // Restricted to only one listener
795                 if (accessibilityManagerActionMoveToLastEventHandler == null)
796                 {
797                     accessibilityManagerActionMoveToLastEventCallbackDelegate = new ActionMoveToLastEventCallbackDelegate(OnActionMoveToLast);
798                     this.ActionMoveToLastSignal().Connect(accessibilityManagerActionMoveToLastEventCallbackDelegate);
799                 }
800
801                 accessibilityManagerActionMoveToLastEventHandler += value;
802             }
803
804             remove
805             {
806                 accessibilityManagerActionMoveToLastEventHandler -= value;
807
808                 if (accessibilityManagerActionMoveToLastEventHandler == null && ActionMoveToLastSignal().Empty() == false)
809                 {
810                     this.ActionMoveToLastSignal().Disconnect(accessibilityManagerActionMoveToLastEventCallbackDelegate);
811                 }
812             }
813         }
814
815         /// <summary>
816         /// This is emitted when accessibility action is received to focus and read from the first item on the top continuously
817         /// (by three fingers single tap).
818         /// </summary>
819         /// <returns> The signal to connect to </returns>
820         /// <since_tizen> 6 </since_tizen>
821         /// This will be public opened in tizen_6.0 after ACR done. Before ACR, need to be hidden as inhouse API.
822         [EditorBrowsable(EditorBrowsableState.Never)]
823         public event ReturnTypeEventHandler<object, EventArgs, bool> ActionReadFromTop
824         {
825             add
826             {
827                 // Restricted to only one listener
828                 if (accessibilityManagerActionReadFromTopEventHandler == null)
829                 {
830                     accessibilityManagerActionReadFromTopEventCallbackDelegate = new ActionReadFromTopEventCallbackDelegate(OnActionReadFromTop);
831                     this.ActionReadFromTopSignal().Connect(accessibilityManagerActionReadFromTopEventCallbackDelegate);
832                 }
833
834                 accessibilityManagerActionReadFromTopEventHandler += value;
835             }
836
837             remove
838             {
839                 accessibilityManagerActionReadFromTopEventHandler -= value;
840
841                 if (accessibilityManagerActionReadFromTopEventHandler == null && ActionReadFromTopSignal().Empty() == false)
842                 {
843                     this.ActionReadFromTopSignal().Disconnect(accessibilityManagerActionReadFromTopEventCallbackDelegate);
844                 }
845             }
846         }
847
848         /// <summary>
849         /// This is emitted when accessibility action is received to move the focus to and read from the next item continuously
850         /// (by three fingers double tap).
851         /// </summary>
852         /// <returns> The signal to connect to </returns>
853         /// <since_tizen> 6 </since_tizen>
854         /// This will be public opened in tizen_6.0 after ACR done. Before ACR, need to be hidden as inhouse API.
855         [EditorBrowsable(EditorBrowsableState.Never)]
856         public event ReturnTypeEventHandler<object, EventArgs, bool> ActionReadFromNext
857         {
858             add
859             {
860                 // Restricted to only one listener
861                 if (accessibilityManagerActionReadFromNextEventHandler == null)
862                 {
863                     accessibilityManagerActionReadFromNextEventCallbackDelegate = new ActionReadFromNextEventCallbackDelegate(OnActionReadFromNext);
864                     this.ActionReadFromNextSignal().Connect(accessibilityManagerActionReadFromNextEventCallbackDelegate);
865                 }
866
867                 accessibilityManagerActionReadFromNextEventHandler += value;
868             }
869
870             remove
871             {
872                 accessibilityManagerActionReadFromNextEventHandler -= value;
873
874                 if (accessibilityManagerActionReadFromNextEventHandler == null && ActionReadFromNextSignal().Empty() == false)
875                 {
876                     this.ActionReadFromNextSignal().Disconnect(accessibilityManagerActionReadFromNextEventCallbackDelegate);
877                 }
878             }
879         }
880
881         /// <summary>
882         /// This is emitted when accessibility action is received to zoom (by one finger triple tap)
883         /// </summary>
884         /// <returns> The signal to connect to </returns>
885         /// <since_tizen> 6 </since_tizen>
886         /// This will be public opened in tizen_6.0 after ACR done. Before ACR, need to be hidden as inhouse API.
887         [EditorBrowsable(EditorBrowsableState.Never)]
888         public event ReturnTypeEventHandler<object, EventArgs, bool> ActionZoom
889         {
890             add
891             {
892                 // Restricted to only one listener
893                 if (accessibilityManagerActionZoomEventHandler == null)
894                 {
895                     accessibilityManagerActionZoomEventCallbackDelegate = new ActionZoomEventCallbackDelegate(OnActionZoom);
896                     this.ActionZoomSignal().Connect(accessibilityManagerActionZoomEventCallbackDelegate);
897                 }
898
899                 accessibilityManagerActionZoomEventHandler += value;
900             }
901
902             remove
903             {
904                 accessibilityManagerActionZoomEventHandler -= value;
905
906                 if (accessibilityManagerActionZoomEventHandler == null && ActionZoomSignal().Empty() == false)
907                 {
908                     this.ActionZoomSignal().Disconnect(accessibilityManagerActionZoomEventCallbackDelegate);
909                 }
910             }
911         }
912
913         /// <summary>
914         /// This is emitted when accessibility action is received to pause/resume the current speech (by two fingers single tap).
915         /// </summary>
916         /// <returns> The signal to connect to </returns>
917         /// <since_tizen> 6 </since_tizen>
918         /// This will be public opened in tizen_6.0 after ACR done. Before ACR, need to be hidden as inhouse API.
919         [EditorBrowsable(EditorBrowsableState.Never)]
920         public event ReturnTypeEventHandler<object, EventArgs, bool> ActionReadPauseResume
921         {
922             add
923             {
924                 // Restricted to only one listener
925                 if (accessibilityManagerActionReadPauseResumeEventHandler == null)
926                 {
927                     accessibilityManagerActionReadPauseResumeEventCallbackDelegate = new ActionReadPauseResumeEventCallbackDelegate(OnActionReadPauseResume);
928                     this.ActionReadPauseResumeSignal().Connect(accessibilityManagerActionReadPauseResumeEventCallbackDelegate);
929                 }
930
931                 accessibilityManagerActionReadPauseResumeEventHandler += value;
932             }
933
934             remove
935             {
936                 accessibilityManagerActionReadPauseResumeEventHandler -= value;
937
938                 if (accessibilityManagerActionReadPauseResumeEventHandler == null && ActionReadPauseResumeSignal().Empty() == false)
939                 {
940                     this.ActionReadPauseResumeSignal().Disconnect(accessibilityManagerActionReadPauseResumeEventCallbackDelegate);
941                 }
942             }
943         }
944
945         /// <summary>
946         /// This is emitted when accessibility action is received to start/stop the current action (by two fingers double tap).
947         /// </summary>
948         /// <returns> The signal to connect to </returns>
949         /// <since_tizen> 6 </since_tizen>
950         /// This will be public opened in tizen_6.0 after ACR done. Before ACR, need to be hidden as inhouse API.
951         [EditorBrowsable(EditorBrowsableState.Never)]
952         public event ReturnTypeEventHandler<object, EventArgs, bool> ActionStartStop
953         {
954             add
955             {
956                 // Restricted to only one listener
957                 if (accessibilityManagerActionStartStopEventHandler == null)
958                 {
959                     accessibilityManagerActionStartStopEventCallbackDelegate = new ActionStartStopEventCallbackDelegate(OnActionStartStop);
960                     this.ActionStartStopSignal().Connect(accessibilityManagerActionStartStopEventCallbackDelegate);
961                 }
962
963                 accessibilityManagerActionStartStopEventHandler += value;
964             }
965
966             remove
967             {
968                 accessibilityManagerActionStartStopEventHandler -= value;
969
970                 if (accessibilityManagerActionStartStopEventHandler == null && ActionStartStopSignal().Empty() == false)
971                 {
972                     this.ActionStartStopSignal().Disconnect(accessibilityManagerActionStartStopEventCallbackDelegate);
973                 }
974             }
975         }
976
977         /*
978             // To be replaced by a new event that takes Touch
979             public event DaliEventHandlerWithReturnType<object,ActionScrollEventArgs,bool> ActionScroll
980             {
981               add
982               {
983                 lock(this)
984                 {
985                   // Restricted to only one listener
986                   if (_accessibilityManagerActionScrollEventHandler == null)
987                   {
988                     _accessibilityManagerActionScrollEventHandler += value;
989
990                     _accessibilityManagerActionScrollEventCallbackDelegate = new ActionScrollEventCallbackDelegate(OnActionScroll);
991                     this.ActionScrollSignal().Connect(_accessibilityManagerActionScrollEventCallbackDelegate);
992                   }
993                 }
994               }
995
996               remove
997               {
998                 lock(this)
999                 {
1000                   if (_accessibilityManagerActionScrollEventHandler != null)
1001                   {
1002                     this.ActionScrollSignal().Disconnect(_accessibilityManagerActionScrollEventCallbackDelegate);
1003                   }
1004
1005                   _accessibilityManagerActionScrollEventHandler -= value;
1006                 }
1007               }
1008             }
1009
1010             // Callback for AccessibilityManager ActionScrollSignal
1011             private bool OnActionScroll(IntPtr accessibilityManager, IntPtr touchEvent)
1012             {
1013               ActionScrollEventArgs e = new ActionScrollEventArgs();
1014
1015               // Populate all members of "e" (ActionScrollEventArgs) with real data
1016               e.AccessibilityManager = AccessibilityManager.GetAccessibilityManagerFromPtr(accessibilityManager);
1017               e.TouchEvent = TouchEvent.GetTouchEventFromPtr(touchEvent);
1018
1019               if (_accessibilityManagerActionScrollEventHandler != null)
1020               {
1021                 //here we send all data to user event handlers
1022                 return _accessibilityManagerActionScrollEventHandler(this, e);
1023               }
1024               return false;
1025             }
1026         */
1027
1028         // Common Signals
1029
1030         /// <summary>
1031         /// This signal is emitted when the current focused view is changed.
1032         /// </summary>
1033         /// <returns> The signal to connect to </returns>
1034         /// <since_tizen> 6 </since_tizen>
1035         /// This will be public opened in tizen_6.0 after ACR done. Before ACR, need to be hidden as inhouse API.
1036         [EditorBrowsable(EditorBrowsableState.Never)]
1037         public event EventHandler<FocusChangedEventArgs> FocusChanged
1038         {
1039             add
1040             {
1041                 // Restricted to only one listener
1042                 if (accessibilityManagerFocusChangedEventHandler == null)
1043                 {
1044                     accessibilityManagerFocusChangedEventCallbackDelegate = new FocusChangedEventCallbackDelegate(OnFocusChanged);
1045                     this.FocusChangedSignal().Connect(accessibilityManagerFocusChangedEventCallbackDelegate);
1046                 }
1047
1048                 accessibilityManagerFocusChangedEventHandler += value;
1049             }
1050
1051             remove
1052             {
1053                 accessibilityManagerFocusChangedEventHandler -= value;
1054
1055                 if (accessibilityManagerFocusChangedEventHandler == null && FocusChangedSignal().Empty() == false)
1056                 {
1057                     this.FocusChangedSignal().Disconnect(accessibilityManagerFocusChangedEventCallbackDelegate);
1058                 }
1059             }
1060         }
1061
1062         /// <summary>
1063         /// This signal is emitted when the current focused view is activated.
1064         /// </summary>
1065         /// <returns> The signal to connect to </returns>
1066         /// <since_tizen> 6 </since_tizen>
1067         /// This will be public opened in tizen_6.0 after ACR done. Before ACR, need to be hidden as inhouse API.
1068         [EditorBrowsable(EditorBrowsableState.Never)]
1069         public event EventHandler<FocusedViewActivatedEventArgs> FocusedViewActivated
1070         {
1071             add
1072             {
1073                 // Restricted to only one listener
1074                 if (accessibilityManagerFocusedViewActivatedEventHandler == null)
1075                 {
1076                     accessibilityManagerFocusedViewActivatedEventCallbackDelegate = new FocusedViewActivatedEventCallbackDelegate(OnFocusedViewActivated);
1077                     Interop.AccessibilityManager.FocusedActorActivatedSignalConnect(SwigCPtr, accessibilityManagerFocusedViewActivatedEventCallbackDelegate.ToHandleRef(this));
1078                     NDalicPINVOKE.ThrowExceptionIfExists();
1079                 }
1080
1081                 accessibilityManagerFocusedViewActivatedEventHandler += value;
1082             }
1083
1084             remove
1085             {
1086                 accessibilityManagerFocusedViewActivatedEventHandler -= value;
1087
1088                 if (accessibilityManagerFocusedViewActivatedEventHandler == null && accessibilityManagerFocusedViewActivatedEventCallbackDelegate != null)
1089                 {
1090                     Interop.AccessibilityManager.FocusedActorActivatedSignalDisconnect(SwigCPtr, accessibilityManagerFocusedViewActivatedEventCallbackDelegate.ToHandleRef(this));
1091                     NDalicPINVOKE.ThrowExceptionIfExists();
1092                     accessibilityManagerFocusedViewActivatedEventCallbackDelegate = null;
1093                 }
1094             }
1095         }
1096
1097         /// <summary>
1098         /// This signal is emitted when there is no way to move focus further.
1099         /// </summary>
1100         /// <returns> The signal to connect to </returns>
1101         /// <since_tizen> 6 </since_tizen>
1102         /// This will be public opened in tizen_6.0 after ACR done. Before ACR, need to be hidden as inhouse API.
1103         [EditorBrowsable(EditorBrowsableState.Never)]
1104         public event EventHandler<FocusOvershotEventArgs> FocusOvershot
1105         {
1106             add
1107             {
1108                 // Restricted to only one listener
1109                 if (accessibilityManagerFocusOvershotEventHandler == null)
1110                 {
1111                     accessibilityManagerFocusOvershotEventCallbackDelegate = new FocusOvershotEventCallbackDelegate(OnFocusOvershot);
1112                     this.FocusOvershotSignal().Connect(accessibilityManagerFocusOvershotEventCallbackDelegate);
1113                 }
1114
1115                 accessibilityManagerFocusOvershotEventHandler += value;
1116             }
1117
1118             remove
1119             {
1120                 accessibilityManagerFocusOvershotEventHandler -= value;
1121
1122                 if (accessibilityManagerFocusOvershotEventHandler == null && FocusOvershotSignal().Empty() == false)
1123                 {
1124                     this.FocusOvershotSignal().Disconnect(accessibilityManagerFocusOvershotEventCallbackDelegate);
1125                 }
1126             }
1127         }
1128     }
1129 }