[Tizen] Add codes for Dali Windows Backend
[platform/core/uifw/dali-adaptor.git] / dali-windows-backend / ExInclude / ToolKitPreDefine.h
1 #ifndef _TOOLKIT_PREDEFINE_INCLUDE_\r
2 #define _TOOLKIT_PREDEFINE_INCLUDE_\r
3 \r
4 #ifdef __cplusplus\r
5 #include <cctype>\r
6 \r
7 static unsigned int abs(unsigned int x)\r
8 {\r
9   return (x)>=0?x:-x;\r
10 }\r
11 \r
12 #include <random>\r
13 static unsigned int _seed = -1;\r
14 \r
15 static int rand_r(unsigned int *seed)\r
16 {\r
17   if (*seed != _seed)\r
18   {\r
19     _seed = *seed;\r
20         srand(_seed);\r
21   }\r
22   \r
23   return rand();\r
24 }\r
25 \r
26 #endif\r
27 \r
28 #endif