/
DaliEnumConstants.cs
executable file
·251 lines (239 loc) · 9.62 KB
/
DaliEnumConstants.cs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
/*
* Copyright (c) 2018 Samsung Electronics Co., Ltd.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*
*/
using System;
using System.Reflection;
using System.Diagnostics;
using System.Runtime.CompilerServices;
namespace Tizen.NUI
{
namespace Constants
{
/// <summary>
/// Enumeration for texture types.
/// </summary>
/// <since_tizen> 3 </since_tizen>
public enum TextureType
{
/// <summary>
/// One 2D image
/// </summary>
/// <since_tizen> 3 </since_tizen>
Texture2D = Tizen.NUI.TextureType.TEXTURE_2D,
/// <summary>
/// Six 2D images arranged in a cube-shape
/// </summary>
/// <since_tizen> 3 </since_tizen>
TextureCube = Tizen.NUI.TextureType.TEXTURE_CUBE
}
/// <summary>
/// Enumeration for the direction
/// </summary>
/// <since_tizen> 3 </since_tizen>
public struct Direction
{
/// <summary>
/// Enumeration for the Direction types.
/// </summary>
/// <since_tizen> 3 </since_tizen>
public enum Type
{
/// <summary>
/// from Left to Right
/// </summary>
/// <since_tizen> 3 </since_tizen>
LeftToRight = Tizen.NUI.DirectionType.LEFT_TO_RIGHT,
/// <summary>
/// from Right to Left
/// </summary>
/// <since_tizen> 3 </since_tizen>
RightToLeft = Tizen.NUI.DirectionType.RIGHT_TO_LEFT
}
}
/// <summary>
/// ToolTip
/// </summary>
/// <since_tizen> 3 </since_tizen>
public struct Tooltip
{
/// <summary>
/// The properties used for a Tooltip.
/// </summary>
/// <since_tizen> 3 </since_tizen>
public struct Property
{
/// <summary>
/// The content to display.
/// </summary>
/// <since_tizen> 3 </since_tizen>
public static readonly int Content = NDalic.TOOLTIP_CONTENT;
/// <summary>
/// The layout of the content.
/// </summary>\
/// <since_tizen> 3 </since_tizen>
public static readonly int Layout = NDalic.TOOLTIP_LAYOUT;
/// <summary>
/// Time to wait in seconds before a tooltip is shown while the is movement is within the allowed threshold.
/// </summary>
/// <since_tizen> 3 </since_tizen>
public static readonly int WaitTime = NDalic.TOOLTIP_WAIT_TIME;
/// <summary>
/// The background of the tooltip.
/// </summary>
/// <since_tizen> 3 </since_tizen>
public static readonly int Background = NDalic.TOOLTIP_BACKGROUND;
/// <summary>
/// The tail used by the tooltip.
/// </summary>
/// <since_tizen> 3 </since_tizen>
public static readonly int Tail = NDalic.TOOLTIP_TAIL;
/// <summary>
/// The position of the tooltip in relation to the control.
/// </summary>
/// <since_tizen> 3 </since_tizen>
public static readonly int Position = NDalic.TOOLTIP_POSITION;
/// <summary>
/// If Tooltip::Position::HOVER_POINT is used for the POSITION, then this is the offset the tooltip is displayed at from the hover point.
/// </summary>
/// <since_tizen> 3 </since_tizen>
public static readonly int HoverPointOffset = NDalic.TOOLTIP_HOVER_POINT_OFFSET;
/// <summary>
/// The movement threshold allowed before showing (or hiding a popup).
/// </summary>
/// <since_tizen> 3 </since_tizen>
public static readonly int MovementThreshold = NDalic.TOOLTIP_MOVEMENT_THRESHOLD;
/// <summary>
/// If true, the tooltip will disappear after hover movement beyond a certain distance.
/// </summary>
/// <since_tizen> 3 </since_tizen>
public static readonly int DisappearOnMovement = NDalic.TOOLTIP_DISAPPEAR_ON_MOVEMENT;
}
/// <summary>
/// Background Property
/// </summary>
/// <since_tizen> 3 </since_tizen>
public struct BackgroundProperty
{
/// <summary>
/// The image to use as the background.
/// </summary>
/// <since_tizen> 3 </since_tizen>
public static readonly int Visual = NDalic.TOOLTIP_BACKGROUND_VISUAL;
/// <summary>
/// The size of the borders in the order: left, right, bottom, top.
/// </summary>
/// <since_tizen> 3 </since_tizen>
public static readonly int Border = NDalic.TOOLTIP_BACKGROUND_BORDER;
}
/// <summary>
/// The properties of the tail used by the tooltip.
/// </summary>
/// <since_tizen> 3 </since_tizen>
public struct TailProperty
{
/// <summary>
/// Whether to show the tail or not.
/// </summary>
/// <since_tizen> 3 </since_tizen>
public static readonly int Visibility = NDalic.TOOLTIP_TAIL_VISIBILITY;
/// <summary>
/// The image used for the tail if it is above the tooltip.
/// </summary>
/// <since_tizen> 3 </since_tizen>
public static readonly int AboveVisual = NDalic.TOOLTIP_TAIL_ABOVE_VISUAL;
/// <summary>
/// The image used for the tail if it is below the tooltip.
/// </summary>
/// <since_tizen> 3 </since_tizen>
public static readonly int BelowVisual = NDalic.TOOLTIP_TAIL_BELOW_VISUAL;
}
}
/// <summary>
/// Enumeration for stereoscopic view modes.
/// </summary>
/// <since_tizen> 3 </since_tizen>
/// <remarks>
/// Deprecated.(API Level 6) Not used.
/// </remarks>
[Obsolete("Please do not use this ViewMode(Deprecated).")]
public enum ViewMode
{
/// <summary>
/// Monoscopic (single camera). This is the default.
/// </summary>
/// <since_tizen> 3 </since_tizen>
/// <remarks>
/// Deprecated.(API Level 6) Not used.
/// </remarks>
[Obsolete("Please do not use this ViewMode.Mono(Deprecated).")]
Mono,
/// <summary>
/// Stereoscopic. Frame buffer is split horizontally with the left and right camera views in their respective sides.
/// </summary>
/// <since_tizen> 3 </since_tizen>
/// <remarks>
/// Deprecated.(API Level 6) Not used.
/// </remarks>
[Obsolete("Please do not use this ViewMode.StereoHorizontal(Deprecated).")]
StereoHorizontal,
/// <summary>
/// Stereoscopic. Frame buffer is split vertically with the left camera view at the top and the right camera view at the bottom.
/// </summary>
/// <since_tizen> 3 </since_tizen>
/// <remarks>
/// Deprecated.(API Level 6) Not used.
/// </remarks>
[Obsolete("Please do not use this ViewMode.StereoVertical(Deprecated).")]
StereoVertical,
/// <summary>
/// Stereoscopic. Left/Right camera views are rendered into the framebuffer on alternate frames.
/// </summary>
/// <since_tizen> 3 </since_tizen>
/// <remarks>
/// Deprecated.(API Level 6) Not used.
/// </remarks>
[Obsolete("Please do not use this ViewMode.StereoInterlaced(Deprecated).")]
StereoInterlaced
}
} // namespace Constants
internal class NUILog
{
[Conditional("NUI_DEBUG_ON")]
public static void Debug(string msg,
[CallerLineNumber] int lineNum = 0,
[CallerMemberName] string caller = null,
[CallerFilePath] string file = null
)
{
Tizen.Log.Fatal("NUI", $"{msg} (at line {lineNum} of {caller} in {file})");
}
public static void Error(string msg,
[CallerLineNumber] int lineNum = 0,
[CallerMemberName] string caller = null,
[CallerFilePath] string file = null
)
{
Tizen.Log.Fatal("NUI", $"[ERROR] {msg} (at line {lineNum} of {caller} in {file})");
}
}
#if !(NUI_DEBUG_ON)
internal class tlog
{
internal static void Fatal(string tag, string msg) { }
internal static void Error(string tag, string msg) { }
}
#endif
}