[dali_1.2.40] Merge branch 'devel/master'
[platform/core/uifw/dali-toolkit.git] / plugins / dali-swig / SWIG / gestures / key.i
1 %rename(Key) Dali::KeyEvent;
2 %rename(StateType) Dali::KeyEvent::State;
3
4 %csmethodmodifiers Dali::KeyEvent::keyPressedName "private";
5 %csmethodmodifiers Dali::KeyEvent::keyPressed "private";
6 %csmethodmodifiers Dali::KeyEvent::keyCode "private";
7 %csmethodmodifiers Dali::KeyEvent::keyModifier "private";
8 %csmethodmodifiers Dali::KeyEvent::time "private";
9 %csmethodmodifiers Dali::KeyEvent::state "private";
10
11 %csmethodmodifiers Dali::DevelKeyEvent::GetDeviceName "private";
12 %csmethodmodifiers Dali::DevelKeyEvent::SetDeviceName "private";
13
14 %typemap(cscode) Dali::KeyEvent %{
15   public static Key GetKeyFromPtr(global::System.IntPtr cPtr) {
16     Key ret = new Key(cPtr, false);
17     if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
18     return ret;
19   }
20
21   public string DeviceName
22   {
23     get
24     {
25       string ret = NDalicPINVOKE.GetDeviceName(swigCPtr);
26       if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
27       return ret;
28     }
29   }
30
31   public string KeyPressedName
32   {
33     get
34     {
35       return keyPressedName;
36     }
37   }
38
39   public string KeyPressed
40   {
41     get
42     {
43       return keyPressed;
44     }
45   }
46
47   public int KeyCode
48   {
49     get
50     {
51       return keyCode;
52     }
53   }
54
55   public int KeyModifier
56   {
57     get
58     {
59       return keyModifier;
60     }
61   }
62
63   public uint Time
64   {
65     get
66     {
67       return time;
68     }
69   }
70
71   public Key.StateType State
72   {
73     get
74     {
75       return state;
76     }
77   }
78 %}