[Tizen] Add codes for Dali Windows Backend
[platform/core/uifw/dali-adaptor.git] / dali / internal / system / windows / file-closer-win.cpp
1 /*\r
2  * Copyright (c) 2018 Samsung Electronics Co., Ltd.\r
3  *\r
4  * Licensed under the Apache License, Version 2.0 (the "License");\r
5  * you may not use this file except in compliance with the License.\r
6  * You may obtain a copy of the License at\r
7  *\r
8  * http://www.apache.org/licenses/LICENSE-2.0\r
9  *\r
10  * Unless required by applicable law or agreed to in writing, software\r
11  * distributed under the License is distributed on an "AS IS" BASIS,\r
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\r
13  * See the License for the specific language governing permissions and\r
14  * limitations under the License.\r
15  *\r
16  */\r
17 \r
18 #include <dali/integration-api/debug.h>\r
19 #include <dali/public-api/common/dali-vector.h>\r
20 #include <dali/internal/system/common/file-closer.h>\r
21 \r
22 #include <CustomFile.h>\r
23 \r
24 namespace Dali\r
25 {\r
26 namespace Internal\r
27 {\r
28 namespace Platform\r
29 {\r
30 namespace InternalFile\r
31 {\r
32 FILE *fmemopen( void *__s, size_t __len, const char *__modes )\r
33 {\r
34   FILE *ret = (FILE*)CustomFile::fmemopen( __s, __len, __modes );\r
35   return ret;\r
36 }\r
37 \r
38 size_t fread( void*  _Buffer, size_t _ElementSize, size_t _ElementCount, FILE*  _Stream )\r
39 {\r
40   return CustomFile::fread( _Buffer, _ElementSize, _ElementCount, _Stream );\r
41 }\r
42 \r
43 int fclose( FILE *__stream )\r
44 {\r
45   return CustomFile::fclose( __stream );\r
46 }\r
47 \r
48 void fwrite( void *buf, int size, int count, FILE *fp )\r
49 {\r
50   CustomFile::fwrite( buf, size * count, fp );\r
51 }\r
52 \r
53 int fseek( FILE *fp, int offset, int origin )\r
54 {\r
55   return CustomFile::fseek( fp, offset, origin );\r
56 }\r
57 \r
58 int ftell( FILE *fp )\r
59 {\r
60   return CustomFile::ftell( fp );\r
61 }\r
62 \r
63 bool feof( FILE *fp )\r
64 {\r
65   return CustomFile::feof( fp );\r
66 }\r
67 } //InternalFile\r
68 } //Platform\r
69 } //Internal\r
70 } //Dali\r