3 // Copyright (c) 2012 Samsung Electronics Co., Ltd.
\r
5 // Licensed under the Flora License, Version 1.0 (the License);
\r
6 // you may not use this file except in compliance with the License.
\r
7 // You may obtain a copy of the License at
\r
9 // http://floralicense.org/license/
\r
11 // Unless required by applicable law or agreed to in writing, software
\r
12 // distributed under the License is distributed on an AS IS BASIS,
\r
13 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
\r
14 // See the License for the specific language governing permissions and
\r
15 // limitations under the License.
\r
18 /*@file: IntCommonLib.h
\r
19 *@brief: To define the common method of Internet application
\r
22 #ifndef _INT_COMMON_LIB_H_
\r
23 #define _INT_COMMON_LIB_H_
\r
25 #include <FGraphics.h>
\r
28 * @struct CommonBitmapTable
\r
30 * Defines the table to store a bitmap
\r
33 struct CommonBitmapTable
\r
35 Tizen::Graphics::Bitmap* ptr;
\r
37 Tizen::Base::String filename;
\r
43 * @enum CommonBitmapId
\r
45 * Defines a ID for a Bitmap path
\r
55 * @brief This file declares common methods to be used
\r
62 * Returns a pointer to a bitmap value using ID
\r
64 * @return Pointer to a bitmap value
\r
65 * @param[in] CommonBitmapId The ID of the Bitmap
\r
66 * @remarks To work properly, the existing CommonBitmapId has to be passed.
\r
68 static Tizen::Graphics::Bitmap* GetBitmap(uint id);
\r
71 * Returns a pointer to a bitmap value using bitmap path, bitmap width and bitmap height
\r
73 * @return Pointer to a bitmap value
\r
74 * @param[in] strPath The path of the existing bitmap stored in res folder
\r
75 * @param[in] width The width of the existing bitmap stored in res folder
\r
76 * @param[in] height The height of the existing bitmap stored in res folder
\r
77 * @remarks To work properly, the existing strPath, its width and height has to be passed.
\r
79 static Tizen::Graphics::Bitmap* GetBitmapN(const Tizen::Base::String& strPath, const int width, const int height);
\r
82 * Gets a bitmap using ID assigned to it.
\r
88 * @remarks Releases all the bitmaps stored
\r
90 static Tizen::Graphics::Bitmap* GetNinepatchedBitmapN(const Tizen::Base::String& strPath, const int width, const int height);
\r
93 * Returns the string value using ID
\r
96 * @param[in] resourceId The ID of the resource string
\r
97 * @remarks To work properly, the existing resourceId has to be passed.
\r
99 static Tizen::Base::String GetString(const Tizen::Base::String& resourceId);
\r
103 static CommonBitmapTable __commonBitmapTable[];
\r
106 #endif //_INT_COMMON_LIB_H_
\r