tizen 2.4 release accepted/tizen_2.4_mobile accepted/tizen/2.4/mobile/20151029.041816 submit/tizen_2.4/20151028.062508 tizen_2.4_mobile_release
authorjk7744.park <jk7744.park@samsung.com>
Sat, 24 Oct 2015 06:32:04 +0000 (15:32 +0900)
committerjk7744.park <jk7744.park@samsung.com>
Sat, 24 Oct 2015 06:32:04 +0000 (15:32 +0900)
115 files changed:
CMakeLists.txt [new file with mode: 0644]
LICENSE [new file with mode: 0644]
attach-panel.manifest [new file with mode: 0644]
attach-panel.pc.in [new file with mode: 0644]
doc/attach_panel_doc.h [new file with mode: 0644]
include/attach_bundle.h [new file with mode: 0644]
include/attach_panel.h [new file with mode: 0644]
include/attach_panel_internal.h [new file with mode: 0644]
include/conf.h [new file with mode: 0644]
include/content_list.h [new file with mode: 0644]
include/gesture.h [new file with mode: 0644]
include/grid.h [new file with mode: 0644]
include/list.h [new file with mode: 0644]
include/log.h [new file with mode: 0644]
include/page.h [new file with mode: 0644]
include/scroller.h [new file with mode: 0644]
include/toolbar.h [new file with mode: 0644]
include/ug.h [new file with mode: 0644]
include/ui_manager.h [new file with mode: 0644]
packaging/attach-panel.spec [new file with mode: 0755]
po/CMakeLists.txt [new file with mode: 0755]
po/ar.po [new file with mode: 0755]
po/az.po [new file with mode: 0755]
po/bg.po [new file with mode: 0755]
po/bn.po [new file with mode: 0755]
po/ca.po [new file with mode: 0755]
po/cs.po [new file with mode: 0755]
po/da.po [new file with mode: 0755]
po/de.po [new file with mode: 0755]
po/de_DE.po [new file with mode: 0755]
po/el_GR.po [new file with mode: 0755]
po/en.po [new file with mode: 0755]
po/en_PH.po [new file with mode: 0755]
po/en_US.po [new file with mode: 0755]
po/es_ES.po [new file with mode: 0755]
po/es_MX.po [new file with mode: 0755]
po/es_US.po [new file with mode: 0755]
po/et.po [new file with mode: 0755]
po/eu.po [new file with mode: 0755]
po/fa.po [new file with mode: 0755]
po/fi.po [new file with mode: 0755]
po/fr.po [new file with mode: 0755]
po/fr_CA.po [new file with mode: 0755]
po/fr_FR.po [new file with mode: 0755]
po/ga.po [new file with mode: 0755]
po/gl.po [new file with mode: 0755]
po/gu.po [new file with mode: 0755]
po/he.po [new file with mode: 0755]
po/hi.po [new file with mode: 0755]
po/hr.po [new file with mode: 0755]
po/hu.po [new file with mode: 0755]
po/hy.po [new file with mode: 0755]
po/is.po [new file with mode: 0755]
po/it_IT.po [new file with mode: 0755]
po/ja_JP.po [new file with mode: 0755]
po/ka.po [new file with mode: 0755]
po/kk.po [new file with mode: 0755]
po/kn.po [new file with mode: 0755]
po/ko_KR.po [new file with mode: 0755]
po/lt.po [new file with mode: 0755]
po/lv.po [new file with mode: 0755]
po/mk.po [new file with mode: 0755]
po/ml.po [new file with mode: 0755]
po/mn_MN.po [new file with mode: 0755]
po/nb.po [new file with mode: 0755]
po/nl.po [new file with mode: 0755]
po/nl_NL.po [new file with mode: 0755]
po/pl.po [new file with mode: 0755]
po/pt_BR.po [new file with mode: 0755]
po/pt_PT.po [new file with mode: 0755]
po/ro.po [new file with mode: 0755]
po/ru_RU.po [new file with mode: 0755]
po/si.po [new file with mode: 0755]
po/sk.po [new file with mode: 0755]
po/sl.po [new file with mode: 0755]
po/sr.po [new file with mode: 0755]
po/sv.po [new file with mode: 0755]
po/ta.po [new file with mode: 0755]
po/te.po [new file with mode: 0755]
po/th.po [new file with mode: 0755]
po/tr_TR.po [new file with mode: 0755]
po/uk.po [new file with mode: 0755]
po/ur.po [new file with mode: 0755]
po/uz.po [new file with mode: 0755]
po/zh_CN.po [new file with mode: 0755]
po/zh_HK.po [new file with mode: 0755]
po/zh_SG.po [new file with mode: 0755]
po/zh_TW.po [new file with mode: 0755]
res/CMakeLists.txt [new file with mode: 0644]
res/edje/CMakeLists.txt [new file with mode: 0755]
res/edje/conf.h [new symlink]
res/edje/layout.edc [new file with mode: 0644]
res/edje/page.edc [new file with mode: 0644]
res/images/A01-1_icon_Menu.png [new file with mode: 0755]
res/images/CMakeLists.txt [new file with mode: 0644]
res/images/calendar.png [new file with mode: 0755]
res/images/contact.png [new file with mode: 0755]
res/images/music.png [new file with mode: 0755]
res/images/my_files.png [new file with mode: 0755]
res/images/video.png [new file with mode: 0755]
sample/CMakeLists.txt [new file with mode: 0644]
sample/sample.c [new file with mode: 0644]
sample/sample.edc [new file with mode: 0644]
sample/sample.h [new file with mode: 0644]
src/attach_bundle.c [new file with mode: 0644]
src/attach_panel.c [new file with mode: 0644]
src/content_list.c [new file with mode: 0644]
src/gesture.c [new file with mode: 0644]
src/grid.c [new file with mode: 0644]
src/list.c [new file with mode: 0644]
src/page.c [new file with mode: 0644]
src/scroller.c [new file with mode: 0644]
src/toolbar.c [new file with mode: 0644]
src/ug.c [new file with mode: 0644]
src/ui_manager.c [new file with mode: 0644]

diff --git a/CMakeLists.txt b/CMakeLists.txt
new file mode 100644 (file)
index 0000000..970f382
--- /dev/null
@@ -0,0 +1,86 @@
+CMAKE_MINIMUM_REQUIRED(VERSION 2.6)
+
+PROJECT(attach-panel C)
+
+SET(VERSION 0.1.0)
+
+SET(PREFIX ${CMAKE_INSTALL_PREFIX})
+SET(INCLUDEDIR "${PREFIX}/include/${PROJECT_NAME}")
+
+SET(LIBDIR "${LIB_INSTALL_DIR}")
+SET(SHAREDIR "${PREFIX}/share")
+
+SET(ICONDIR "${SHAREDIR}/icons")
+SET(PANELDIR "${SHAREDIR}/${PROJECT_NAME}")
+
+SET(EDJEDIR "${PANELDIR}/edje")
+SET(IMAGEDIR "${PANELDIR}/images")
+SET(LOCALEDIR "${PANELDIR}/locale")
+SET(SAMPLEDIR "${PANELDIR}/sample")
+
+SET(INSTALL_HEADERS_DEVEL
+       attach_panel.h
+)
+
+SET(SRCS
+       src/attach_panel.c
+       src/attach_bundle.c
+       src/content_list.c
+       src/gesture.c
+       src/grid.c
+       src/page.c
+       src/scroller.c
+       src/toolbar.c
+       src/ug.c
+       src/ui_manager.c
+       src/list.c
+)
+
+INCLUDE_DIRECTORIES(${CMAKE_CURRENT_SOURCE_DIR}/include)
+INCLUDE(FindPkgConfig)
+pkg_check_modules(pkgs REQUIRED
+       aul
+       capi-base-common
+       capi-system-info
+       bundle
+       dlog
+       efl-extension
+       elementary
+       evas
+       feedback
+       isf
+       security-privilege-checker
+       ui-gadget-1
+       rua
+)
+
+FOREACH(flag ${pkgs_CFLAGS})
+       SET(EXTRA_CFLAGS "${EXTRA_CFLAGS} ${flag}")
+ENDFOREACH(flag)
+
+SET(EXTRA_CFLAGS "${EXTRA_CFLAGS} -fvisibility=hidden -g -Wall -O2")
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${EXTRA_CFLAGS}")
+
+ADD_DEFINITIONS("-DPREFIX=\"${CMAKE_INSTALL_PREFIX}\"")
+ADD_DEFINITIONS("-DEDJEDIR=\"${EDJEDIR}\"")
+ADD_DEFINITIONS("-DLOCALEDIR=\"${LOCALEDIR}\"")
+ADD_DEFINITIONS("-DPACKAGE=\"${PROJECT_NAME}\"")
+
+ADD_LIBRARY(${PROJECT_NAME} SHARED ${SRCS})
+SET_TARGET_PROPERTIES(${PROJECT_NAME} PROPERTIES SOVERSION 0.1.0)
+TARGET_LINK_LIBRARIES(${PROJECT_NAME} ${pkgs_LDFLAGS})
+
+INSTALL(TARGETS ${PROJECT_NAME} DESTINATION ${LIBDIR})
+
+CONFIGURE_FILE(${PROJECT_NAME}.pc.in ${PROJECT_NAME}.pc @ONLY)
+SET_DIRECTORY_PROPERTIES(PROPERTIES ADDITIONAL_MAKE_CLEAN_FILES "${PROJECT_NAME}.pc")
+INSTALL(FILES ${CMAKE_CURRENT_BINARY_DIR}/${PROJECT_NAME}.pc DESTINATION ${LIBDIR}/pkgconfig)
+
+FOREACH(hfile ${INSTALL_HEADERS_DEVEL})
+       INSTALL(FILES ${CMAKE_SOURCE_DIR}/include/${hfile} DESTINATION include/${PROJECT_NAME})
+ENDFOREACH(hfile)
+
+# subdir
+ADD_SUBDIRECTORY(res)
+ADD_SUBDIRECTORY(po)
+ADD_SUBDIRECTORY(sample)
diff --git a/LICENSE b/LICENSE
new file mode 100644 (file)
index 0000000..d645695
--- /dev/null
+++ b/LICENSE
@@ -0,0 +1,202 @@
+
+                                 Apache License
+                           Version 2.0, January 2004
+                        http://www.apache.org/licenses/
+
+   TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
+
+   1. Definitions.
+
+      "License" shall mean the terms and conditions for use, reproduction,
+      and distribution as defined by Sections 1 through 9 of this document.
+
+      "Licensor" shall mean the copyright owner or entity authorized by
+      the copyright owner that is granting the License.
+
+      "Legal Entity" shall mean the union of the acting entity and all
+      other entities that control, are controlled by, or are under common
+      control with that entity. For the purposes of this definition,
+      "control" means (i) the power, direct or indirect, to cause the
+      direction or management of such entity, whether by contract or
+      otherwise, or (ii) ownership of fifty percent (50%) or more of the
+      outstanding shares, or (iii) beneficial ownership of such entity.
+
+      "You" (or "Your") shall mean an individual or Legal Entity
+      exercising permissions granted by this License.
+
+      "Source" form shall mean the preferred form for making modifications,
+      including but not limited to software source code, documentation
+      source, and configuration files.
+
+      "Object" form shall mean any form resulting from mechanical
+      transformation or translation of a Source form, including but
+      not limited to compiled object code, generated documentation,
+      and conversions to other media types.
+
+      "Work" shall mean the work of authorship, whether in Source or
+      Object form, made available under the License, as indicated by a
+      copyright notice that is included in or attached to the work
+      (an example is provided in the Appendix below).
+
+      "Derivative Works" shall mean any work, whether in Source or Object
+      form, that is based on (or derived from) the Work and for which the
+      editorial revisions, annotations, elaborations, or other modifications
+      represent, as a whole, an original work of authorship. For the purposes
+      of this License, Derivative Works shall not include works that remain
+      separable from, or merely link (or bind by name) to the interfaces of,
+      the Work and Derivative Works thereof.
+
+      "Contribution" shall mean any work of authorship, including
+      the original version of the Work and any modifications or additions
+      to that Work or Derivative Works thereof, that is intentionally
+      submitted to Licensor for inclusion in the Work by the copyright owner
+      or by an individual or Legal Entity authorized to submit on behalf of
+      the copyright owner. For the purposes of this definition, "submitted"
+      means any form of electronic, verbal, or written communication sent
+      to the Licensor or its representatives, including but not limited to
+      communication on electronic mailing lists, source code control systems,
+      and issue tracking systems that are managed by, or on behalf of, the
+      Licensor for the purpose of discussing and improving the Work, but
+      excluding communication that is conspicuously marked or otherwise
+      designated in writing by the copyright owner as "Not a Contribution."
+
+      "Contributor" shall mean Licensor and any individual or Legal Entity
+      on behalf of whom a Contribution has been received by Licensor and
+      subsequently incorporated within the Work.
+
+   2. Grant of Copyright License. Subject to the terms and conditions of
+      this License, each Contributor hereby grants to You a perpetual,
+      worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+      copyright license to reproduce, prepare Derivative Works of,
+      publicly display, publicly perform, sublicense, and distribute the
+      Work and such Derivative Works in Source or Object form.
+
+   3. Grant of Patent License. Subject to the terms and conditions of
+      this License, each Contributor hereby grants to You a perpetual,
+      worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+      (except as stated in this section) patent license to make, have made,
+      use, offer to sell, sell, import, and otherwise transfer the Work,
+      where such license applies only to those patent claims licensable
+      by such Contributor that are necessarily infringed by their
+      Contribution(s) alone or by combination of their Contribution(s)
+      with the Work to which such Contribution(s) was submitted. If You
+      institute patent litigation against any entity (including a
+      cross-claim or counterclaim in a lawsuit) alleging that the Work
+      or a Contribution incorporated within the Work constitutes direct
+      or contributory patent infringement, then any patent licenses
+      granted to You under this License for that Work shall terminate
+      as of the date such litigation is filed.
+
+   4. Redistribution. You may reproduce and distribute copies of the
+      Work or Derivative Works thereof in any medium, with or without
+      modifications, and in Source or Object form, provided that You
+      meet the following conditions:
+
+      (a) You must give any other recipients of the Work or
+          Derivative Works a copy of this License; and
+
+      (b) You must cause any modified files to carry prominent notices
+          stating that You changed the files; and
+
+      (c) You must retain, in the Source form of any Derivative Works
+          that You distribute, all copyright, patent, trademark, and
+          attribution notices from the Source form of the Work,
+          excluding those notices that do not pertain to any part of
+          the Derivative Works; and
+
+      (d) If the Work includes a "NOTICE" text file as part of its
+          distribution, then any Derivative Works that You distribute must
+          include a readable copy of the attribution notices contained
+          within such NOTICE file, excluding those notices that do not
+          pertain to any part of the Derivative Works, in at least one
+          of the following places: within a NOTICE text file distributed
+          as part of the Derivative Works; within the Source form or
+          documentation, if provided along with the Derivative Works; or,
+          within a display generated by the Derivative Works, if and
+          wherever such third-party notices normally appear. The contents
+          of the NOTICE file are for informational purposes only and
+          do not modify the License. You may add Your own attribution
+          notices within Derivative Works that You distribute, alongside
+          or as an addendum to the NOTICE text from the Work, provided
+          that such additional attribution notices cannot be construed
+          as modifying the License.
+
+      You may add Your own copyright statement to Your modifications and
+      may provide additional or different license terms and conditions
+      for use, reproduction, or distribution of Your modifications, or
+      for any such Derivative Works as a whole, provided Your use,
+      reproduction, and distribution of the Work otherwise complies with
+      the conditions stated in this License.
+
+   5. Submission of Contributions. Unless You explicitly state otherwise,
+      any Contribution intentionally submitted for inclusion in the Work
+      by You to the Licensor shall be under the terms and conditions of
+      this License, without any additional terms or conditions.
+      Notwithstanding the above, nothing herein shall supersede or modify
+      the terms of any separate license agreement you may have executed
+      with Licensor regarding such Contributions.
+
+   6. Trademarks. This License does not grant permission to use the trade
+      names, trademarks, service marks, or product names of the Licensor,
+      except as required for reasonable and customary use in describing the
+      origin of the Work and reproducing the content of the NOTICE file.
+
+   7. Disclaimer of Warranty. Unless required by applicable law or
+      agreed to in writing, Licensor provides the Work (and each
+      Contributor provides its Contributions) on an "AS IS" BASIS,
+      WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+      implied, including, without limitation, any warranties or conditions
+      of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
+      PARTICULAR PURPOSE. You are solely responsible for determining the
+      appropriateness of using or redistributing the Work and assume any
+      risks associated with Your exercise of permissions under this License.
+
+   8. Limitation of Liability. In no event and under no legal theory,
+      whether in tort (including negligence), contract, or otherwise,
+      unless required by applicable law (such as deliberate and grossly
+      negligent acts) or agreed to in writing, shall any Contributor be
+      liable to You for damages, including any direct, indirect, special,
+      incidental, or consequential damages of any character arising as a
+      result of this License or out of the use or inability to use the
+      Work (including but not limited to damages for loss of goodwill,
+      work stoppage, computer failure or malfunction, or any and all
+      other commercial damages or losses), even if such Contributor
+      has been advised of the possibility of such damages.
+
+   9. Accepting Warranty or Additional Liability. While redistributing
+      the Work or Derivative Works thereof, You may choose to offer,
+      and charge a fee for, acceptance of support, warranty, indemnity,
+      or other liability obligations and/or rights consistent with this
+      License. However, in accepting such obligations, You may act only
+      on Your own behalf and on Your sole responsibility, not on behalf
+      of any other Contributor, and only if You agree to indemnify,
+      defend, and hold each Contributor harmless for any liability
+      incurred by, or claims asserted against, such Contributor by reason
+      of your accepting any such warranty or additional liability.
+
+   END OF TERMS AND CONDITIONS
+
+   APPENDIX: How to apply the Apache License to your work.
+
+      To apply the Apache License to your work, attach the following
+      boilerplate notice, with the fields enclosed by brackets "[]"
+      replaced with your own identifying information. (Don't include
+      the brackets!)  The text should be enclosed in the appropriate
+      comment syntax for the file format. We also recommend that a
+      file or class name and description of purpose be included on the
+      same "printed page" as the copyright notice for easier
+      identification within third-party archives.
+
+   Copyright [yyyy] [name of copyright owner]
+
+   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.
diff --git a/attach-panel.manifest b/attach-panel.manifest
new file mode 100644 (file)
index 0000000..7d10c61
--- /dev/null
@@ -0,0 +1,8 @@
+<manifest>
+       <request>
+               <domain name="_"/>
+       </request>
+       <assign>
+               <filesystem path="/usr/share/attach-panel/sample/sample" exec_label="none" />
+       </assign>
+</manifest>
diff --git a/attach-panel.pc.in b/attach-panel.pc.in
new file mode 100644 (file)
index 0000000..1281b95
--- /dev/null
@@ -0,0 +1,9 @@
+libdir=@LIBDIR@
+includedir=@INCLUDEDIR@
+
+Name: attach-panel
+Description: attach-panel supporting library
+Version: @VERSION@
+Requires: ui-gadget-1 capi-base-common
+Libs: -L${libdir} -lattach-panel
+Cflags: -I${includedir}
diff --git a/doc/attach_panel_doc.h b/doc/attach_panel_doc.h
new file mode 100644 (file)
index 0000000..b0aaff4
--- /dev/null
@@ -0,0 +1,49 @@
+/*
+ * Copyright (c) 2015 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * 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.
+ */
+
+#ifndef __TIZEN_ATTACH_PANEL_DOC_H__
+#define __TIZEN_ATTACH_PANEL_DOC_H__
+
+/**
+ * @ingroup CAPI_APPLICATION_FRAMEWORK
+ * @defgroup CAPI_PANEL_ATTACH_MODULE Attach panel
+ * @brief Attach panel provides functions to attach images, voices, contacts, events and files. Users can attach images, take pictures, record voice and select files to attach into the caller app
+ *
+ * @section CAPI_PANEL_ATTACH_MODULE_HEADER Required Header
+ *   \#include <attach_panel.h>
+ *
+ * @section CAPI_PANEL_ATTACH_MODULE_OVERVIEW Overview
+ * - It provides functions for adding an attach panel (attach_panel_create()) and deleting it (attach_panel_destroy()) in an app.\n
+ * - Content categories can be added (attach_panel_add_content_category()) or removed (attach_panel_remove_content_category()).\n
+ * - Dynamic configurations can be handled with (attach_panel_set_extra_data()). This is used with a content category.
+ * - Results can be returned into the result callback that is set (attach_panel_set_result_cb()) or unset (attach_panel_unset_result_cb()).\n
+ * - Events are delivered into the event callback that is set with (attach_panel_set_event_cb()) or unset with (attach_panel_unset_event_cb()).\n
+ * - The panel can be shown with (attach_panel_show()) and hidden with (attach_panel_hide()).\n
+ * - You can get the state of the panel with (attach_panel_get_visibility()).\n
+ *
+ * @section CAPI_PANEL_ATTACH_MODULE_FEATURE Related Features
+ * This API is related with the following features:\n
+ *  - %http://tizen.org/feature/camera\n
+ *  - %http://tizen.org/feature/microphone\n
+ *
+ * It is recommended to design feature related codes in your application for reliability.\n
+ * You can check if a device supports the related features for this API by using @ref CAPI_SYSTEM_SYSTEM_INFO_MODULE, thereby controlling the procedure of your application.\n
+ * To ensure your application is only running on the device with specific features, please define the features in your manifest file using the manifest editor in the SDK.\n
+ * More details on featuring your application can be found from <a href="https://developer.tizen.org/development/tools/native-tools/manifest-text-editor#feature"><b>Feature Element</b>.</a>
+ */
+
+
+#endif
diff --git a/include/attach_bundle.h b/include/attach_bundle.h
new file mode 100644 (file)
index 0000000..6351730
--- /dev/null
@@ -0,0 +1,26 @@
+/*
+ * Copyright (c) 2015 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * 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.
+ */
+
+#ifndef __ATTACH_PANEL_BUNDLE_H__
+#define __ATTACH_PANEL_BUNDLE_H__
+
+
+
+int _bundle_add_to_app_control(bundle *b, app_control_h app_control);
+int _bundle_add_to_bundle(bundle *origin, bundle *replace);
+
+
+#endif
diff --git a/include/attach_panel.h b/include/attach_panel.h
new file mode 100644 (file)
index 0000000..83e5026
--- /dev/null
@@ -0,0 +1,1416 @@
+/*
+ * Copyright (c) 2015 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * 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.
+ */
+
+#ifndef __TIZEN_ATTACH_PANEL_H__
+#define __TIZEN_ATTACH_PANEL_H__
+
+#include <Elementary.h>
+#include <tizen_error.h>
+#include <app_control.h>
+#include <stdbool.h>
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+/**
+ * @file attach_panel.h
+ * @brief Declares the API of the libattach-panel library.
+ */
+
+/**
+ * @addtogroup CAPI_PANEL_ATTACH_MODULE
+ * @{
+ */
+
+/**
+ * @brief Enumeration for content categories
+ * @since_tizen 2.4
+ * @see attach_panel_add_content_category()
+ * @see attach_panel_remove_content_category()
+ */
+typedef enum attach_panel_content_category {
+       ATTACH_PANEL_CONTENT_CATEGORY_IMAGE = 1, /**< Attaching images from the gallery */
+       ATTACH_PANEL_CONTENT_CATEGORY_CAMERA, /**< Taking pictures to attach */
+       ATTACH_PANEL_CONTENT_CATEGORY_VOICE, /**< Taking a voice clip to attach */
+       ATTACH_PANEL_CONTENT_CATEGORY_VIDEO, /**< Attaching video from the gallery */
+       ATTACH_PANEL_CONTENT_CATEGORY_AUDIO, /**< Attaching audio from my files */
+       ATTACH_PANEL_CONTENT_CATEGORY_CALENDAR, /**< Attaching calendar data from the calendar */
+       ATTACH_PANEL_CONTENT_CATEGORY_CONTACT, /**< Attaching contact data from the contacts */
+       ATTACH_PANEL_CONTENT_CATEGORY_MYFILES, /**< Attaching files data from my files */
+       ATTACH_PANEL_CONTENT_CATEGORY_VIDEO_RECORDER, /**< Taking a video clip to attach */
+} attach_panel_content_category_e;
+
+/**
+ * @brief Enumeration for events
+ * @since_tizen 2.4
+ * @see attach_panel_set_event_cb()
+ * @see attach_panel_unset_event_cb()
+ */
+typedef enum attach_panel_event {
+       ATTACH_PANEL_EVENT_SHOW_START = 1, /**< Attach panel starts the effect to show */
+       ATTACH_PANEL_EVENT_SHOW_FINISH, /**< Attach panel finishes the effect to show */
+       ATTACH_PANEL_EVENT_HIDE_START, /**< Attach panel starts the effect to hide the panel */
+       ATTACH_PANEL_EVENT_HIDE_FINISH, /**< Attach panel finishes the effect to hide the panel */
+} attach_panel_event_e;
+
+/**
+ * @brief Attach panel handle.
+ * @since_tizen 2.4
+ */
+typedef struct _attach_panel *attach_panel_h;
+
+/**
+ * @brief Called when an user selects and confirms something to attach on the caller app.
+ *
+ * @since_tizen 2.4
+ * @param[in] attach_panel Attach panel handler
+ * @param[in] content_category results are from the content category
+ * @param[in] result app_control handler.\n
+ *                   The caller app has to use app_control_get_extra_data_array() to get received data.\n
+ *                   http://tizen.org/appcontrol/data/selected\n
+ * @param[in] result_code result of app_control
+ * @param[in] user_data user data
+ * @pre The callback must be registered using attach_panel_set_result_cb()\n
+ * attach_panel_add_content_category() and attach_panel_show() must be called to invoke this callback.
+ *
+ * @see @ref CAPI_APP_CONTROL_MODULE API app_control_get_extra_data_array()
+ * @see        attach_panel_set_result_cb()
+ * @see        attach_panel_unset_result_cb()
+ */
+typedef void (*attach_panel_result_cb)(attach_panel_h attach_panel, attach_panel_content_category_e content_category, app_control_h result, app_control_result_e result_code, void *user_data);
+
+/**
+ * @brief Called when reserved events are published from the panel-side.
+ *
+ * @since_tizen 2.4
+ * @param[in] attach_panel Attach panel handler
+ * @param[in] event Attach panel event
+ * @param[in] event_info additional event information.\n
+ *                       This can be NULL if there are no necessary information.
+ * @param[in] user_data user data
+ * @pre The callback must be registered using attach_panel_set_event_cb()
+ *
+ * @see        attach_panel_set_event_cb()
+ * @see        attach_panel_unset_event_cb()
+ */
+typedef void (*attach_panel_event_cb)(attach_panel_h attach_panel, attach_panel_event_e event, void *event_info, void *user_data);
+
+/**
+ * @brief Enumeration for values of attach-panel response types.
+ * @since_tizen 2.4
+ */
+typedef enum attach_panel_error {
+       ATTACH_PANEL_ERROR_NONE = TIZEN_ERROR_NONE, /**< Successfully handled */
+       ATTACH_PANEL_ERROR_INVALID_PARAMETER = TIZEN_ERROR_INVALID_PARAMETER, /**< Request is not valid, invalid parameter or invalid argument value */
+       ATTACH_PANEL_ERROR_OUT_OF_MEMORY = TIZEN_ERROR_OUT_OF_MEMORY, /**< Memory is not enough to handle a new request */
+       ATTACH_PANEL_ERROR_PERMISSION_DENIED = TIZEN_ERROR_PERMISSION_DENIED, /**< Has no permission to attach contents */
+       ATTACH_PANEL_ERROR_ALREADY_EXISTS = TIZEN_ERROR_PANEL | 0x01, /**< There is already a panel in the conformant */
+       ATTACH_PANEL_ERROR_NOT_INITIALIZED = TIZEN_ERROR_PANEL | 0x02, /**< The panel is not initialized yet */
+       ATTACH_PANEL_ERROR_UNSUPPORTED_CONTENT_CATEGORY = TIZEN_ERROR_PANEL | 0x03, /**< Not supported content category */
+       ATTACH_PANEL_ERROR_ALREADY_DESTROYED = TIZEN_ERROR_PANEL | 0x05, /**< The panel is already removed */
+} attach_panel_error_e;
+
+/**
+ * @brief Creates an attach panel.
+ * @since_tizen 2.4
+ * @remarks The caller app has to check the return value of this function.\n
+ *          A conformant object can have only one @a attach_panel_h.\n
+ *          If a caller app try to add more than one attach-panel, it fails to add it.
+ *
+ * @param[in] conformant The caller's conformant
+ * @param[out] attach_panel Attach panel handler
+ * @return #ATTACH_PANEL_ERROR_NONE on success,
+ *         otherwise a negative error value
+ * @retval #ATTACH_PANEL_ERROR_NONE Successful
+ * @retval #ATTACH_PANEL_ERROR_INVALID_PARAMETER Invalid parameter
+ * @retval #ATTACH_PANEL_ERROR_OUT_OF_MEMORY Out of memory
+ * @retval #ATTACH_PANEL_ERROR_ALREADY_EXISTS Already exists
+ *
+ * @see attach_panel_destroy()
+ * @see attach_panel_add_content_category()
+ * @see attach_panel_remove_content_category()
+ * @see attach_panel_set_extra_data()
+ * @see attach_panel_set_result_cb()
+ * @see attach_panel_unset_result_cb()
+ * @see attach_panel_set_event_cb()
+ * @see attach_panel_unset_event_cb()
+ * @see attach_panel_show()
+ * @see attach_panel_hide()
+ * @see attach_panel_get_visibility()
+ *
+ * @par Example
+ * @code
+ * #include <attach_panel.h>
+ *
+ * struct appdata {
+ *   Evas_Object *attach_panel;
+ *   Evas_Object *conformant;
+ * };
+ *
+ * static void _result_cb(attach_panel_h attach_panel, attach_panel_content_category_e content_category, app_control_h result, app_control_result_e result_code, void *data)
+ * {
+ *   char **select = NULL;
+ *   int i = 0;
+ *   int length = 0;
+ *   int ret = APP_CONTROL_ERROR_NONE;
+ *
+ *   if (!result) {
+ *     // Error handling
+ *   }
+ *
+ *   if (APP_CONTROL_RESULT_SUCCEEDED != result_code) {
+ *     // Error handling
+ *   }
+ *
+ *   ret = app_control_get_extra_data_array(result, "http://tizen.org/appcontrol/data/selected", &select, &length);
+ *   if (APP_CONTROL_ERROR_NONE != ret || !select) {
+ *     // Error handling
+ *   }
+ *
+ *   for (; i < length; i++) {
+ *      printf("path is %s, %d\n", select[i], length);
+ *      free(select[i]);
+ *   }
+ *
+ *   free(select);
+ * }
+ *
+ * static int app_control(void *data)
+ * {
+ *   struct appdata *ad = data;
+ *   bundle *extra_data = NULL;
+ *   int ret = ATTACH_PANEL_ERROR_NONE;
+ *
+ *   if (!ad) {
+ *     // Error handling
+ *   }
+ *
+ *   if (!ad->conformant) {
+ *     // Error handling
+ *   }
+ *
+ *   ret = attach_panel_create(ad->conformant, &ad->attach_panel);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *
+ *   extra_data = bundle_create();
+ *   if (!extra_data) {
+ *      // Error handling
+ *   }
+ *
+ *   bundle_add_str(extra_data, "http://tizen.org/appcontrol/data/total_count", "3");
+ *   bundle_add_str(extra_data, "http://tizen.org/appcontrol/data/total_size", "10240000");
+ *
+ *   ret = attach_panel_add_content_category(ad->attach_panel, ATTACH_PANEL_CONTENT_CATEGORY_IMAGE, extra_data);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *
+ *   ret = attach_panel_add_content_category(ad->attach_panel, ATTACH_PANEL_CONTENT_CATEGORY_CAMERA, extra_data);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *
+ *   ret = attach_panel_add_content_category(ad->attach_panel, ATTACH_PANEL_CONTENT_CATEGORY_VOICE, extra_data);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *
+ *   ret = attach_panel_set_result_cb(ad->attach_panel, _result_cb, NULL);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *
+ *   ret = attach_panel_show(ad->attach_panel);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *
+ *   bundle_free(extra_data);
+ *
+ *      return 0;
+ * }
+ *
+ * @endcode
+ */
+int attach_panel_create(Evas_Object *conformant, attach_panel_h *attach_panel);
+
+/**
+ * @brief Destroys the attach panel.
+ * @since_tizen 2.4
+ * @remarks The caller app has to check the return value of this function.\n
+ *
+ * @param[in] attach_panel Attach panel handler
+ * @return #ATTACH_PANEL_ERROR_NONE on success,
+ *         otherwise a negative error value
+ * @retval #ATTACH_PANEL_ERROR_NONE Successful
+ * @retval #ATTACH_PANEL_ERROR_INVALID_PARAMETER Invalid parameter
+ * @retval #ATTACH_PANEL_ERROR_ALREADY_DESTROYED already removed
+ *
+ * @see attach_panel_create()
+ * @see attach_panel_add_content_category()
+ * @see attach_panel_remove_content_category()
+ * @see attach_panel_set_extra_data()
+ * @see attach_panel_set_result_cb()
+ * @see attach_panel_unset_result_cb()
+ * @see attach_panel_set_event_cb()
+ * @see attach_panel_unset_event_cb()
+ * @see attach_panel_show()
+ * @see attach_panel_hide()
+ * @see attach_panel_get_visibility()
+ *
+ * @par Example
+ * @code
+ * #include <attach_panel.h>
+ *
+ * struct appdata {
+ *   Evas_Object *attach_panel;
+ *   Evas_Object *conformant;
+ * };
+ *
+ * static int app_terminate(void *data)
+ * {
+ *   struct appdata *ad = data;
+ *   int ret = 0;
+ *
+ *   if (!ad) {
+ *     // Error handling
+ *   }
+ *
+ *   if (!ad->attach_panel) {
+ *     // Error handling
+ *   }
+ *
+ *   ret = attach_panel_hide(ad->attach_panel);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *
+ *   ret = attach_panel_remove_content_category(ad->attach_panel, ATTACH_PANEL_CONTENT_CATEGORY_IMAGE);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *
+ *   ret = attach_panel_remove_content_category(ad->attach_panel, ATTACH_PANEL_CONTENT_CATEGORY_CAMERA);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *
+ *   ret = attach_panel_remove_content_category(ad->attach_panel, ATTACH_PANEL_CONTENT_CATEGORY_VOICE);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *
+ *   ret = attach_panel_unset_result_cb(ad->attach_panel);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *
+ *   ret = attach_panel_destroy(ad->attach_panel);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *   ad->attach_panel = NULL;
+ *
+ *      return 0;
+ * }
+ *
+ * @endcode
+ */
+int attach_panel_destroy(attach_panel_h attach_panel);
+
+/**
+ * @brief Adds a content category in the attach panel.
+ * @since_tizen 2.4
+ * @privlevel public
+ * @privilege %http://tizen.org/privilege/mediastorage
+ * @privilege %http://tizen.org/privilege/camera
+ * @privilege %http://tizen.org/privilege/recorder
+ * @privilege %http://tizen.org/privilege/appmanager.launch
+ * @remarks The caller app has to check the return value of this function.\n
+ *          Content categories will be shown as the sequence of using @a attach_panel_add_content_category.\n
+ *          Some contents need time to load it all.\n
+ *          So, it is needed to use this before the mainloop of attach_panel_show().\n
+ *          Privileges,\n
+ *          %http://tizen.org/privilege/mediastorage, for using ATTACH_PANEL_CONTENT_CATEGORY_IMAGE or ATTACH_PANEL_CONTENT_CATEGORY_CAMERA\n
+ *          %http://tizen.org/privilege/camera, for using ATTACH_PANEL_CONTENT_CATEGORY_CAMERA\n
+ *          %http://tizen.org/privilege/recorder, for using ATTACH_PANEL_CONTENT_CATEGORY_VOICE\n
+ *          %http://tizen.org/privilege/appmanager.launch, for adding content categories on the More tab\n
+ *          Deliver more information to the callee with a bundle if you need.\n
+ *          %http://tizen.org/appcontrol/data/total_count\n
+ *          %http://tizen.org/appcontrol/data/total_size
+ *
+ * @param[in] attach_panel Attach panel handler
+ * @param[in] content_category The content_category to be added in the @a attach_panel.
+ * @param[in] extra_data The attach panel send some information using @a bundle.
+ * @return #ATTACH_PANEL_ERROR_NONE on success,
+ *         otherwise a negative error value
+ * @retval #ATTACH_PANEL_ERROR_NONE Successful
+ * @retval #ATTACH_PANEL_ERROR_INVALID_PARAMETER Invalid parameter
+ * @retval #ATTACH_PANEL_ERROR_PERMISSION_DENIED permission denied
+ * @retval #ATTACH_PANEL_ERROR_NOT_INITIALIZED not initialized
+ * @retval #ATTACH_PANEL_ERROR_UNSUPPORTED_CONTENT_CATEGORY not supported content category
+ * @retval #ATTACH_PANEL_ERROR_ALREADY_DESTROYED already removed
+ *
+ * @pre Call attach_panel_create() before calling this function.
+ * @see attach_panel_create()
+ * @see attach_panel_destroy()
+ * @see attach_panel_remove_content_category()
+ * @see attach_panel_set_result_cb()
+ * @see attach_panel_unset_result_cb()
+ * @see attach_panel_show()
+ * @see attach_panel_hide()
+ * @see attach_panel_get_visibility()
+ * @see ATTACH_PANEL_CONTENT_CATEGORY_IMAGE
+ * @see ATTACH_PANEL_CONTENT_CATEGORY_CAMERA
+ * @see ATTACH_PANEL_CONTENT_CATEGORY_VOICE
+ * @see ATTACH_PANEL_CONTENT_CATEGORY_VIDEO
+ * @see ATTACH_PANEL_CONTENT_CATEGORY_AUDIO
+ * @see ATTACH_PANEL_CONTENT_CATEGORY_CALENDAR
+ * @see ATTACH_PANEL_CONTENT_CATEGORY_CONTACT
+ * @see ATTACH_PANEL_CONTENT_CATEGORY_MYFILES
+ *
+ * @par Example
+ * @code
+ * #include <attach_panel.h>
+ *
+ * struct appdata {
+ *   Evas_Object *attach_panel;
+ *   Evas_Object *conformant;
+ * };
+ *
+ * static void _result_cb(attach_panel_h attach_panel, attach_panel_content_category_e content_category, app_control_h result, app_control_result_e result_code, void *data)
+ * {
+ *   char **select = NULL;
+ *   int i = 0;
+ *   int length = 0;
+ *   int ret = APP_CONTROL_ERROR_NONE;
+ *
+ *   if (!result) {
+ *     // Error handling
+ *   }
+ *
+ *   if (APP_CONTROL_RESULT_SUCCEEDED != result_code) {
+ *     // Error handling
+ *   }
+ *
+ *   ret = app_control_get_extra_data_array(result, "http://tizen.org/appcontrol/data/selected", &select, &length);
+ *   if (APP_CONTROL_ERROR_NONE != ret || !select) {
+ *     // Error handling
+ *   }
+ *
+ *   for (; i < length; i++) {
+ *      printf("path is %s, %d\n", select[i], length);
+ *      free(select[i]);
+ *   }
+ *
+ *   free(select);
+ * }
+ *
+ * static int app_control(void *data)
+ * {
+ *   struct appdata *ad = data;
+ *   bundle *extra_data = NULL;
+ *   int ret = ATTACH_PANEL_ERROR_NONE;
+ *
+ *   if (!ad) {
+ *     // Error handling
+ *   }
+ *
+ *   if (!ad->conformant) {
+ *     // Error handling
+ *   }
+ *
+ *   ret = attach_panel_create(ad->conformant, &ad->attach_panel);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *
+ *   extra_data = bundle_create();
+ *   if (!extra_data) {
+ *      // Error handling
+ *   }
+ *
+ *   bundle_add_str(extra_data, "http://tizen.org/appcontrol/data/total_count", "3");
+ *   bundle_add_str(extra_data, "http://tizen.org/appcontrol/data/total_size", "10240000");
+ *
+ *   ret = attach_panel_add_content_category(ad->attach_panel, ATTACH_PANEL_CONTENT_CATEGORY_IMAGE, extra_data);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *
+ *   ret = attach_panel_add_content_category(ad->attach_panel, ATTACH_PANEL_CONTENT_CATEGORY_CAMERA, extra_data);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *
+ *   ret = attach_panel_add_content_category(ad->attach_panel, ATTACH_PANEL_CONTENT_CATEGORY_VOICE, extra_data);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *
+ *   ret = attach_panel_set_result_cb(ad->attach_panel, _result_cb, NULL);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *
+ *   ret = attach_panel_show(ad->attach_panel);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *
+ *   bundle_free(extra_data);
+ *
+ *      return 0;
+ * }
+ *
+ * @endcode
+ */
+int attach_panel_add_content_category(attach_panel_h attach_panel, attach_panel_content_category_e content_category, bundle *extra_data);
+
+/**
+ * @brief Removes the content category from the attach panel.
+ * @since_tizen 2.4
+ * @remarks The caller app has to check the return value of this function.\n
+ *
+ * @param[in] attach_panel Attach panel handler
+ * @param[in] content_category The content_category adding in the @a attach_panel.
+ * @return #ATTACH_PANEL_ERROR_NONE on success,
+ *         otherwise a negative error value
+ * @retval #ATTACH_PANEL_ERROR_NONE Successful
+ * @retval #ATTACH_PANEL_ERROR_INVALID_PARAMETER Invalid parameter
+ * @retval #ATTACH_PANEL_ERROR_NOT_INITIALIZED not initialized
+ * @retval #ATTACH_PANEL_ERROR_ALREADY_DESTROYED already removed
+ *
+ * @pre Call attach_panel_create() before calling this function.
+ * @see attach_panel_create()
+ * @see attach_panel_destroy()
+ * @see attach_panel_add_content_category()
+ * @see attach_panel_set_extra_data()
+ * @see attach_panel_set_result_cb()
+ * @see attach_panel_unset_result_cb()
+ * @see attach_panel_show()
+ * @see attach_panel_hide()
+ * @see attach_panel_get_visibility()
+ * @see ATTACH_PANEL_CONTENT_CATEGORY_IMAGE
+ * @see ATTACH_PANEL_CONTENT_CATEGORY_CAMERA
+ * @see ATTACH_PANEL_CONTENT_CATEGORY_VOICE
+ * @see ATTACH_PANEL_CONTENT_CATEGORY_VIDEO
+ * @see ATTACH_PANEL_CONTENT_CATEGORY_AUDIO
+ * @see ATTACH_PANEL_CONTENT_CATEGORY_CALENDAR
+ * @see ATTACH_PANEL_CONTENT_CATEGORY_CONTACT
+ * @see ATTACH_PANEL_CONTENT_CATEGORY_MYFILES
+ *
+ * @par Example
+ * @code
+ * #include <attach_panel.h>
+ *
+ * struct appdata {
+ *   Evas_Object *attach_panel;
+ *   Evas_Object *conformant;
+ * };
+ *
+ * static int app_terminate(void *data)
+ * {
+ *   struct appdata *ad = data;
+ *   int ret = 0;
+ *
+ *   if (!ad) {
+ *     // Error handling
+ *   }
+ *
+ *   if (!ad->attach_panel) {
+ *     // Error handling
+ *   }
+ *
+ *   ret = attach_panel_hide(ad->attach_panel);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *
+ *   ret = attach_panel_remove_content_category(ad->attach_panel, ATTACH_PANEL_CONTENT_CATEGORY_IMAGE);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *
+ *   ret = attach_panel_remove_content_category(ad->attach_panel, ATTACH_PANEL_CONTENT_CATEGORY_CAMERA);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *
+ *   ret = attach_panel_remove_content_category(ad->attach_panel, ATTACH_PANEL_CONTENT_CATEGORY_VOICE);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *
+ *   ret = attach_panel_unset_result_cb(ad->attach_panel);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *
+ *   ret = attach_panel_destroy(ad->attach_panel);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *   ad->attach_panel = NULL;
+ *
+ *   return 0;
+ * }
+ *
+ * @endcode
+ */
+int attach_panel_remove_content_category(attach_panel_h attach_panel, attach_panel_content_category_e content_category);
+
+/**
+ * @brief Sets extra data to send to the content category using a bundle.
+ * @since_tizen 2.4
+ * @privlevel public
+ * @remarks The caller app has to check the return value of this function.\n
+ *          extra data will be changed using @a attach_panel_set_extra_data.\n
+ *          %http://tizen.org/appcontrol/data/total_count\n
+ *          %http://tizen.org/appcontrol/data/total_size
+ *
+ * @param[in] attach_panel Attach panel handler
+ * @param[in] content_category The content_category to be set the some information in the @a attach_panel.
+ * @param[in] extra_data The attach panel set some information using @a bundle.
+ * @return #ATTACH_PANEL_ERROR_NONE on success,
+ *         otherwise a negative error value
+ * @retval #ATTACH_PANEL_ERROR_NONE Successful
+ * @retval #ATTACH_PANEL_ERROR_INVALID_PARAMETER Invalid parameter
+ * @retval #ATTACH_PANEL_ERROR_ALREADY_DESTROYED already removed
+ * @retval #ATTACH_PANEL_ERROR_OUT_OF_MEMORY Fail to set the extra data
+ *
+ * @pre Call attach_panel_create() before calling this function.
+ * @see attach_panel_create()
+ * @see attach_panel_destroy()
+ * @see attach_panel_add_content_category()
+ * @see attach_panel_remove_content_category()
+ * @see attach_panel_set_result_cb()
+ * @see attach_panel_unset_result_cb()
+ * @see attach_panel_show()
+ * @see attach_panel_hide()
+ * @see attach_panel_get_visibility()
+ * @see ATTACH_PANEL_CONTENT_CATEGORY_IMAGE
+ * @see ATTACH_PANEL_CONTENT_CATEGORY_CAMERA
+ * @see ATTACH_PANEL_CONTENT_CATEGORY_VOICE
+ * @see ATTACH_PANEL_CONTENT_CATEGORY_VIDEO
+ * @see ATTACH_PANEL_CONTENT_CATEGORY_AUDIO
+ * @see ATTACH_PANEL_CONTENT_CATEGORY_CALENDAR
+ * @see ATTACH_PANEL_CONTENT_CATEGORY_CONTACT
+ * @see ATTACH_PANEL_CONTENT_CATEGORY_MYFILES
+ *
+ * @par Example
+ * @code
+ * #include <attach_panel.h>
+ *
+ * struct appdata {
+ *   Evas_Object *attach_panel;
+ *   Evas_Object *conformant;
+ * };
+ *
+ * static void _result_cb(attach_panel_h attach_panel, attach_panel_content_category_e content_category, app_control_h result, app_control_result_e result_code, void *data)
+ * {
+ *   char **select = NULL;
+ *   int i = 0;
+ *   int length = 0;
+ *   int ret = APP_CONTROL_ERROR_NONE;
+ *
+ *   if (!result) {
+ *     // Error handling
+ *   }
+ *
+ *   if (APP_CONTROL_RESULT_SUCCEEDED != result_code) {
+ *     // Error handling
+ *   }
+ *
+ *   ret = app_control_get_extra_data_array(result, "http://tizen.org/appcontrol/data/selected", &select, &length);
+ *   if (APP_CONTROL_ERROR_NONE != ret || !select) {
+ *     // Error handling
+ *   }
+ *
+ *   for (; i < length; i++) {
+ *      printf("path is %s, %d\n", select[i], length);
+ *      free(select[i]);
+ *   }
+ *
+ *   free(select);
+ * }
+ *
+ * static void _reset_bundle_cb(void *data, Evas *e, Evas_Object *obj, void *event_info)
+ * {
+ *   struct appdata *ad = data;
+ *   bundle *extra_data = NULL;
+ *   int ret = APP_CONTROL_ERROR_NONE;
+ *
+ *   if (!ad) {
+ *     // Error handling
+ *   }
+ *
+ *   extra_data = bundle_create();
+ *   if (!extra_data) {
+ *      // Error handling
+ *   }
+ *
+ *   bundle_add_str(extra_data, "http://tizen.org/appcontrol/data/total_count", "5");
+ *   bundle_add_str(extra_data, "http://tizen.org/appcontrol/data/total_size", "20480000");
+ *
+ *   ret = attach_panel_set_extra_data(ad->attach_panel, ATTACH_PANEL_CONTENT_CATEGORY_IMAGE, extra_data);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *
+ *   ret = attach_panel_set_extra_data(ad->attach_panel, ATTACH_PANEL_CONTENT_CATEGORY_CAMERA, extra_data);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *
+ *   ret = attach_panel_set_extra_data(ad->attach_panel, ATTACH_PANEL_CONTENT_CATEGORY_VOICE, extra_data);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *
+ *   bundle_free(extra_data);
+ * }
+ *
+ * static int app_control(void *data)
+ * {
+ *   struct appdata *ad = data;
+ *   bundle *extra_data = NULL;
+ *   int ret = ATTACH_PANEL_ERROR_NONE;
+ *
+ *   if (!ad) {
+ *     // Error handling
+ *   }
+ *
+ *   if (!ad->conformant) {
+ *     // Error handling
+ *   }
+ *
+ *   ret = attach_panel_create(ad->conformant, &ad->attach_panel);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *
+ *   extra_data = bundle_create();
+ *   if (!extra_data) {
+ *      // Error handling
+ *   }
+ *
+ *   bundle_add_str(extra_data, "http://tizen.org/appcontrol/data/total_count", "3");
+ *   bundle_add_str(extra_data, "http://tizen.org/appcontrol/data/total_size", "10240000");
+ *
+ *   ret = attach_panel_add_content_category(ad->attach_panel, ATTACH_PANEL_CONTENT_CATEGORY_IMAGE, extra_data);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *
+ *   ret = attach_panel_add_content_category(ad->attach_panel, ATTACH_PANEL_CONTENT_CATEGORY_CAMERA, extra_data);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *
+ *   ret = attach_panel_add_content_category(ad->attach_panel, ATTACH_PANEL_CONTENT_CATEGORY_VOICE, extra_data);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *
+ *   ret = attach_panel_set_result_cb(ad->attach_panel, _result_cb, NULL);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *
+ *   ret = attach_panel_show(ad->attach_panel);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *
+ *   bundle_free(extra_data);
+ *
+ *      return 0;
+ * }
+ *
+ * @endcode
+ */
+int attach_panel_set_extra_data(attach_panel_h attach_panel, attach_panel_content_category_e content_category, bundle *extra_data);
+
+/**
+ * @brief Sets the result callback that will be called when an user selects and confirms something to attach in the attach panel.
+ * @since_tizen 2.4
+ * @remarks The caller app has to check the return value of this function.\n
+ *          We can set only one callback function with this API.\n
+ *          If you set multiple callbacks with this API,\n
+ *          the last one is registered only.
+ *
+ * @param[in] attach_panel Attach panel handler
+ * @param[in] result_cb Attach panel result callback
+ * @param[in] user_data User data
+ * @return #ATTACH_PANEL_ERROR_NONE on success,
+ *         otherwise a negative error value
+ * @retval #ATTACH_PANEL_ERROR_NONE Successful
+ * @retval #ATTACH_PANEL_ERROR_INVALID_PARAMETER Invalid parameter
+ * @retval #ATTACH_PANEL_ERROR_ALREADY_DESTROYED already removed
+ *
+ * @pre Call attach_panel_create() before calling this function.
+ * @post The result_cb set with attach_panel_set_result_cb() will be called after an user select something to attach.
+ * @see attach_panel_create()
+ * @see attach_panel_destroy()
+ * @see attach_panel_add_content_category()
+ * @see attach_panel_remove_content_category()
+ * @see attach_panel_set_extra_data()
+ * @see attach_panel_unset_result_cb()
+ * @see attach_panel_show()
+ * @see attach_panel_hide()
+ * @see attach_panel_get_visibility()
+ * @see attach_panel_result_cb
+ *
+ * @par Example
+ * @code
+ * #include <attach_panel.h>
+ *
+ * struct appdata {
+ *   Evas_Object *attach_panel;
+ *   Evas_Object *conformant;
+ * };
+ *
+ * static void _result_cb(attach_panel_h attach_panel, attach_panel_content_category_e content_category, app_control_h result, app_control_result_e result_code, void *data)
+ * {
+ *   char **select = NULL;
+ *   int i = 0;
+ *   int length = 0;
+ *   int ret = APP_CONTROL_ERROR_NONE;
+ *
+ *   if (!result) {
+ *     // Error handling
+ *   }
+ *
+ *   if (APP_CONTROL_RESULT_SUCCEEDED != result_code) {
+ *     // Error handling
+ *   }
+ *
+ *   ret = app_control_get_extra_data_array(result, "http://tizen.org/appcontrol/data/selected", &select, &length);
+ *   if (APP_CONTROL_ERROR_NONE != ret || !select) {
+ *     // Error handling
+ *   }
+ *
+ *   for (; i < length; i++) {
+ *      printf("path is %s, %d\n", select[i], length);
+ *      free(select[i]);
+ *   }
+ *
+ *   free(select);
+ * }
+ *
+ * static int app_control(void *data)
+ * {
+ *   struct appdata *ad = data;
+ *   bundle *extra_data = NULL;
+ *   int ret = ATTACH_PANEL_ERROR_NONE;
+ *
+ *   if (!ad) {
+ *     // Error handling
+ *   }
+ *
+ *   if (!ad->conformant) {
+ *     // Error handling
+ *   }
+ *
+ *   ret = attach_panel_create(ad->conformant, &ad->attach_panel);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *
+ *   extra_data = bundle_create();
+ *   if (!extra_data) {
+ *      // Error handling
+ *   }
+ *
+ *   bundle_add_str(extra_data, "http://tizen.org/appcontrol/data/total_count", "3");
+ *   bundle_add_str(extra_data, "http://tizen.org/appcontrol/data/total_size", "10240000");
+ *
+ *   ret = attach_panel_add_content_category(ad->attach_panel, ATTACH_PANEL_CONTENT_CATEGORY_IMAGE, extra_data);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *
+ *   ret = attach_panel_add_content_category(ad->attach_panel, ATTACH_PANEL_CONTENT_CATEGORY_CAMERA, extra_data);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *
+ *   ret = attach_panel_add_content_category(ad->attach_panel, ATTACH_PANEL_CONTENT_CATEGORY_VOICE, extra_data);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *
+ *   ret = attach_panel_set_result_cb(ad->attach_panel, _result_cb, NULL);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *
+ *   ret = attach_panel_show(ad->attach_panel);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *
+ *   bundle_free(extra_data);
+ *
+ *      return 0;
+ * }
+ *
+ * @endcode
+ */
+int attach_panel_set_result_cb(attach_panel_h attach_panel, attach_panel_result_cb result_cb, void *user_data);
+
+/**
+ * @brief Unsets the result callback that will be called when an user selects and confirms something to attach in the attach panel.
+ * @since_tizen 2.4
+ * @remarks The caller app has to check the return value of this function.\n
+ *
+ * @param[in] attach_panel Attach panel handler
+ * @return #ATTACH_PANEL_ERROR_NONE on success,
+ *         otherwise a negative error value
+ * @retval #ATTACH_PANEL_ERROR_NONE Successful
+ * @retval #ATTACH_PANEL_ERROR_INVALID_PARAMETER Invalid parameter
+ * @retval #ATTACH_PANEL_ERROR_ALREADY_DESTROYED already removed
+ *
+ * @pre Call attach_panel_create() before calling this function.
+ * @see attach_panel_create()
+ * @see attach_panel_destroy()
+ * @see attach_panel_add_content_category()
+ * @see attach_panel_remove_content_category()
+ * @see attach_panel_set_extra_data()
+ * @see attach_panel_set_result_cb()
+ * @see attach_panel_show()
+ * @see attach_panel_hide()
+ * @see attach_panel_get_visibility()
+ *
+ * @par Example
+ * @code
+ * #include <attach_panel.h>
+ *
+ * struct appdata {
+ *   Evas_Object *attach_panel;
+ *   Evas_Object *conformant;
+ * };
+ *
+ * static int app_terminate(void *data)
+ * {
+ *   struct appdata *ad = data;
+ *   int ret = 0;
+ *
+ *   if (!ad) {
+ *     // Error handling
+ *   }
+ *
+ *   if (!ad->attach_panel) {
+ *     // Error handling
+ *   }
+ *
+ *   ret = attach_panel_hide(ad->attach_panel);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *
+ *   ret = attach_panel_remove_content_category(ad->attach_panel, ATTACH_PANEL_CONTENT_CATEGORY_IMAGE);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *
+ *   ret = attach_panel_remove_content_category(ad->attach_panel, ATTACH_PANEL_CONTENT_CATEGORY_CAMERA);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *
+ *   ret = attach_panel_remove_content_category(ad->attach_panel, ATTACH_PANEL_CONTENT_CATEGORY_VOICE);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *
+ *   ret = attach_panel_unset_result_cb(ad->attach_panel);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *
+ *   ret = attach_panel_destroy(ad->attach_panel);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *   ad->attach_panel = NULL;
+ *
+ *      return 0;
+ * }
+ *
+ * @endcode
+ */
+int attach_panel_unset_result_cb(attach_panel_h attach_panel);
+
+/**
+ * @brief Sets the event callback that will be called when reserved events are published from the panel-side.
+ * @since_tizen 2.4
+ * @remarks The caller app has to check the return value of this function.\n
+ *          We can set only one callback function with this API.\n
+ *          If you set multiple callbacks with this API,\n
+ *          the last one is registered only.
+ *
+ * @param[in] attach_panel Attach panel handler
+ * @param[in] panel_event_cb Attach panel event callback
+ * @param[in] user_data User data
+ * @return #ATTACH_PANEL_ERROR_NONE on success,
+ *         otherwise a negative error value
+ * @retval #ATTACH_PANEL_ERROR_NONE Successful
+ * @retval #ATTACH_PANEL_ERROR_INVALID_PARAMETER Invalid parameter
+ * @retval #ATTACH_PANEL_ERROR_ALREADY_DESTROYED already removed
+ *
+ * @pre Call attach_panel_create() before calling this function.
+ * @post The event_cb set with attach_panel_set_event_cb() will be called after publishing reserved events.
+ * @see attach_panel_create()
+ * @see attach_panel_destroy()
+ * @see attach_panel_show()
+ * @see attach_panel_hide()
+ * @see attach_panel_get_visibility()
+ * @see attach_panel_unset_event_cb()
+ * @see attach_panel_event_cb
+ *
+ * @par Example
+ * @code
+ * #include <attach_panel.h>
+ *
+ * struct appdata {
+ *   Evas_Object *attach_panel;
+ *   Evas_Object *conformant;
+ * };
+ *
+ * static void _event_cb(attach_panel_h attach_panel, attach_panel_event_e event, void *event_info, void *data)
+ * {
+ *   switch (event) {
+ *   case ATTACH_PANEL_EVENT_SHOW_START:
+ *     // event handling
+ *     break;
+ *   case ATTACH_PANEL_EVENT_SHOW_FINISH:
+ *     // event handling
+ *     break;
+ *   case ATTACH_PANEL_EVENT_HIDE_START:
+ *     // event handling
+ *     break;
+ *   case ATTACH_PANEL_EVENT_HIDE_FINISH:
+ *     // event handling
+ *     break;
+ *   default:
+ *     // error handling
+ *     break;
+ *   }
+ * }
+ *
+ * static int app_control(void *data)
+ * {
+ *   struct appdata *ad = data;
+ *   int ret = ATTACH_PANEL_ERROR_NONE;
+ *
+ *   if (!ad) {
+ *     // Error handling
+ *   }
+ *
+ *   if (!ad->conformant) {
+ *     // Error handling
+ *   }
+ *
+ *   ret = attach_panel_create(ad->conformant, &ad->attach_panel);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *
+ *   ret = attach_panel_set_event_cb(ad->attach_panel, _event_cb, ad);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *
+ *   // other routines
+ *
+ *      return 0;
+ * }
+ *
+ * @endcode
+ */
+int attach_panel_set_event_cb(attach_panel_h attach_panel, attach_panel_event_cb panel_event_cb, void *user_data);
+
+/**
+ * @brief Unsets the event callback
+ * @since_tizen 2.4
+ * @remarks The caller app has to check the return value of this function.
+ *
+ * @param[in] attach_panel Attach panel handler
+ * @param[in] result_cb Attach panel result callback
+ * @return #ATTACH_PANEL_ERROR_NONE on success,
+ *         otherwise a negative error value
+ * @retval #ATTACH_PANEL_ERROR_NONE Successful
+ * @retval #ATTACH_PANEL_ERROR_INVALID_PARAMETER Invalid parameter
+ * @retval #ATTACH_PANEL_ERROR_ALREADY_DESTROYED already removed
+ *
+ * @pre Call attach_panel_create() before calling this function.
+ * @see attach_panel_create()
+ * @see attach_panel_destroy()
+ * @see attach_panel_show()
+ * @see attach_panel_hide()
+ * @see attach_panel_get_visibility()
+ * @see attach_panel_set_event_cb()
+ *
+ * @par Example
+ * @code
+ * #include <attach_panel.h>
+ *
+ * struct appdata {
+ *   Evas_Object *attach_panel;
+ *   Evas_Object *conformant;
+ * };
+ *
+ * static int app_terminate(void *data)
+ * {
+ *   struct appdata *ad = data;
+ *   int ret = 0;
+ *
+ *   if (!ad) {
+ *     // Error handling
+ *   }
+ *
+ *   if (!ad->attach_panel) {
+ *     // Error handling
+ *   }
+ *
+ *   ret = attach_panel_unset_event_cb(ad->attach_panel);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *
+ *   ret = attach_panel_destroy(ad->attach_panel);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *   ad->attach_panel = NULL;
+ *
+ *      return 0;
+ * }
+ *
+ * @endcode
+ */
+int attach_panel_unset_event_cb(attach_panel_h attach_panel);
+
+/**
+ * @brief Shows the attach panel, asynchronously.
+ * @since_tizen 2.4
+ * @remarks The caller app has to check the return value of this function.\n
+ *
+ * @param[in] attach_panel Attach panel handler
+ * @return #ATTACH_PANEL_ERROR_NONE on success,
+ *         otherwise a negative error value
+ * @retval #ATTACH_PANEL_ERROR_NONE Successful
+ * @retval #ATTACH_PANEL_ERROR_INVALID_PARAMETER Invalid parameter
+ * @retval #ATTACH_PANEL_ERROR_ALREADY_DESTROYED already removed
+ *
+ * @pre Call attach_panel_create() before calling this function.
+ * @see attach_panel_create()
+ * @see attach_panel_destroy()
+ * @see attach_panel_add_content_category()
+ * @see attach_panel_remove_content_category()
+ * @see attach_panel_set_extra_data()
+ * @see attach_panel_set_result_cb()
+ * @see attach_panel_unset_result_cb()
+ * @see attach_panel_hide()
+ * @see attach_panel_get_visibility()
+ *
+ * @par Example
+ * @code
+ * #include <attach_panel.h>
+ *
+ * struct appdata {
+ *   Evas_Object *attach_panel;
+ *   Evas_Object *conformant;
+ * };
+ *
+ * static void _result_cb(attach_panel_h attach_panel, attach_panel_content_category_e content_category, app_control_h result, app_control_result_e result_code, void *data)
+ * {
+ *   char **select = NULL;
+ *   int i = 0;
+ *   int length = 0;
+ *   int ret = APP_CONTROL_ERROR_NONE;
+ *
+ *   if (!result) {
+ *     // Error handling
+ *   }
+ *
+ *   if (APP_CONTROL_RESULT_SUCCEEDED != result_code) {
+ *     // Error handling
+ *   }
+ *
+ *   ret = app_control_get_extra_data_array(result, "http://tizen.org/appcontrol/data/selected", &select, &length);
+ *   if (APP_CONTROL_ERROR_NONE != ret || !select) {
+ *     // Error handling
+ *   }
+ *
+ *   for (; i < length; i++) {
+ *      printf("path is %s, %d\n", select[i], length);
+ *      free(select[i]);
+ *   }
+ *
+ *   free(select);
+ * }
+ *
+ * static int app_control(void *data)
+ * {
+ *   struct appdata *ad = data;
+ *   bundle *extra_data = NULL;
+ *   int ret = ATTACH_PANEL_ERROR_NONE;
+ *
+ *   if (!ad) {
+ *     // Error handling
+ *   }
+ *
+ *   if (!ad->conformant) {
+ *     // Error handling
+ *   }
+ *
+ *   ret = attach_panel_create(ad->conformant, &ad->attach_panel);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *
+ *   extra_data = bundle_create();
+ *   if (!extra_data) {
+ *      // Error handling
+ *   }
+ *
+ *   bundle_add_str(extra_data, "http://tizen.org/appcontrol/data/total_count", "3");
+ *   bundle_add_str(extra_data, "http://tizen.org/appcontrol/data/total_size", "10240000");
+ *
+ *   ret = attach_panel_add_content_category(ad->attach_panel, ATTACH_PANEL_CONTENT_CATEGORY_IMAGE, extra_data);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *
+ *   ret = attach_panel_add_content_category(ad->attach_panel, ATTACH_PANEL_CONTENT_CATEGORY_CAMERA, extra_data);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *
+ *   ret = attach_panel_add_content_category(ad->attach_panel, ATTACH_PANEL_CONTENT_CATEGORY_VOICE, extra_data);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *
+ *   ret = attach_panel_set_result_cb(ad->attach_panel, _result_cb, NULL);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *
+ *   ret = attach_panel_show(ad->attach_panel);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *
+ *   bundle_free(extra_data);
+ *
+ *      return 0;
+ * }
+ *
+ * @endcode
+ */
+int attach_panel_show(attach_panel_h attach_panel);
+
+/**
+ * @brief Hides the attach panel, asynchronously.
+ * @since_tizen 2.4
+ * @remarks The caller app has to check the return value of this function.\n
+ *
+ * @param[in] attach_panel Attach panel handler
+ * @return #ATTACH_PANEL_ERROR_NONE on success,
+ *         otherwise a negative error value
+ * @retval #ATTACH_PANEL_ERROR_NONE Successful
+ * @retval #ATTACH_PANEL_ERROR_INVALID_PARAMETER Invalid parameter
+ * @retval #ATTACH_PANEL_ERROR_ALREADY_DESTROYED already removed
+ *
+ * @pre Call attach_panel_create() before calling this function.
+ * @see attach_panel_create()
+ * @see attach_panel_destroy()
+ * @see attach_panel_add_content_category()
+ * @see attach_panel_remove_content_category()
+ * @see attach_panel_set_extra_data()
+ * @see attach_panel_set_result_cb()
+ * @see attach_panel_unset_result_cb()
+ * @see attach_panel_show()
+ * @see attach_panel_get_visibility()
+ *
+ * @par Example
+ * @code
+ * #include <attach_panel.h>
+ *
+ * struct appdata {
+ *   Evas_Object *attach_panel;
+ *   Evas_Object *conformant;
+ * };
+ *
+ * static int app_terminate(void *data)
+ * {
+ *   struct appdata *ad = data;
+ *   int ret = 0;
+ *
+ *   if (!ad) {
+ *     // Error handling
+ *   }
+ *
+ *   if (!ad->attach_panel) {
+ *     // Error handling
+ *   }
+ *
+ *   ret = attach_panel_hide(ad->attach_panel);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *
+ *   ret = attach_panel_remove_content_category(ad->attach_panel, ATTACH_PANEL_CONTENT_CATEGORY_IMAGE);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *
+ *   ret = attach_panel_remove_content_category(ad->attach_panel, ATTACH_PANEL_CONTENT_CATEGORY_CAMERA);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *
+ *   ret = attach_panel_remove_content_category(ad->attach_panel, ATTACH_PANEL_CONTENT_CATEGORY_VOICE);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *
+ *   ret = attach_panel_unset_result_cb(ad->attach_panel);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *
+ *   ret = attach_panel_destroy(ad->attach_panel);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *   ad->attach_panel = NULL;
+ *
+ *      return 0;
+ * }
+ *
+ * @endcode
+ */
+int attach_panel_hide(attach_panel_h attach_panel);
+
+/**
+ * @brief Gets a value that indicates whether the attach_panel is visible.
+ * @since_tizen 2.4
+ * @remarks The caller app has to check the return value of this function.\n
+ *
+ * @param[in] attach_panel Attach panel handler
+ * @param[out] visible value of attach_panel state
+ * @return #ATTACH_PANEL_ERROR_NONE on success,
+ *         otherwise a negative error value
+ * @retval #ATTACH_PANEL_ERROR_NONE Successful
+ * @retval #ATTACH_PANEL_ERROR_INVALID_PARAMETER Invalid parameter
+ * @retval #ATTACH_PANEL_ERROR_ALREADY_DESTROYED already removed
+ *
+ * @pre Call attach_panel_create() before calling this function.
+ * @see attach_panel_create()
+ * @see attach_panel_destroy()
+ * @see attach_panel_add_content_category()
+ * @see attach_panel_remove_content_category()
+ * @see attach_panel_set_extra_data()
+ * @see attach_panel_set_result_cb()
+ * @see attach_panel_unset_result_cb()
+ * @see attach_panel_show()
+ * @see attach_panel_hide()
+ *
+ * @par Example
+ * @code
+ * #include <attach_panel.h>
+ *
+ * struct appdata {
+ *   Evas_Object *attach_panel;
+ *   Evas_Object *conformant;
+ * };
+ *
+ * static int app_terminate(void *data)
+ * {
+ *   struct appdata *ad = data;
+ *   bool vislble = false;
+ *   int ret = 0;
+ *
+ *   if (!ad) {
+ *     // Error handling
+ *   }
+ *
+ *   if (!ad->attach_panel) {
+ *     // Error handling
+ *   }
+ *
+ *   ret = attach_panel_get_visibility(ad->attach_panel, &visible);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *
+ *   if (visible) {
+ *      ret = attach_panel_hide(ad->attach_panel);
+ *      if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *         // Error handling
+ *      }
+ *   }
+ *
+ *   ret = attach_panel_remove_content_category(ad->attach_panel, ATTACH_PANEL_CONTENT_CATEGORY_IMAGE);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *
+ *   ret = attach_panel_remove_content_category(ad->attach_panel, ATTACH_PANEL_CONTENT_CATEGORY_CAMERA);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *
+ *   ret = attach_panel_remove_content_category(ad->attach_panel, ATTACH_PANEL_CONTENT_CATEGORY_VOICE);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *
+ *   ret = attach_panel_unset_result_cb(ad->attach_panel);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *
+ *   ret = attach_panel_destroy(ad->attach_panel);
+ *   if (ATTACH_PANEL_ERROR_NONE != ret) {
+ *      // Error handling
+ *   }
+ *   ad->attach_panel = NULL;
+ *
+ *      return 0;
+ * }
+ *
+ * @endcode
+ */
+int attach_panel_get_visibility(attach_panel_h attach_panel, bool *visible);
+
+/**
+ * @}
+ */
+
+#ifdef __cplusplus
+}
+#endif
+#endif // __TIZEN_ATTACH_PANEL_H__
+
diff --git a/include/attach_panel_internal.h b/include/attach_panel_internal.h
new file mode 100644 (file)
index 0000000..34eb1bd
--- /dev/null
@@ -0,0 +1,288 @@
+/*
+ * Copyright (c) 2015 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * 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.
+ */
+
+#ifndef __TIZEN_ATTACH_PANEL_INTERNAL_H__
+#define __TIZEN_ATTACH_PANEL_INTERNAL_H__
+
+#include <Elementary.h>
+#include <app_control.h>
+
+#define DATA_KEY_ATTACH_PANEL "__dkap__"
+#define DATA_KEY_ATTACH_PANEL_INFO "__dkapi__"
+#define DATA_KEY_EDGE_TOP "__dket__"
+#define DATA_KEY_PAGE "__dkpg__"
+#define DATA_KEY_UG "__dkug__"
+
+#define SELECTION_MODE_SINGLE "single"
+#define SELECTION_MODE_MULTIPLE "multiple"
+
+#define MODE_ENABLE "enable"
+#define MODE_DISABLE "disable"
+#define MODE_TRUE "true"
+#define MODE_FALSE "false"
+
+#define TABBAR_NAME_MORE "More"
+#define BUF_SIZE 128
+
+/*
+ * attach-panel(Caller) <-> UGs & Apps operations
+ *
+ * - ATTACH_PANEL_CONTENT_CATEGORY_IMAGE
+ *   appid : "attach-panel-gallery"
+ *   operation : APP_CONTROL_OPERATION_PICK
+ *   mime : "image/(asterisk)"
+ *   extra_data : See below
+ *   1) APP_CONTROL_DATA_SELECTION_MODE : "single"
+ *   2) "http://tizen.org/appcontrol/data/total_count" : any numbers
+ *   3) "http://tizen.org/appcontrol/data/total_size" : any bytes
+ *   return data : See below
+ *   1) "http://tizen.org/appcontrol/data/selected"
+ *
+ * - ATTACH_PANEL_CONTENT_CATEGORY_CAMERA
+ *   appid : "attach-panel-camera"
+ *   operation : APP_CONTROL_OPERATION_CREATE_CONTENT
+ *   mime : NULL
+ *   extra_data : See below
+ *   1) APP_CONTROL_DATA_SELECTION_MODE : "single"
+ *   2) "http://tizen.org/appcontrol/data/total_size" : any bytes
+ *   return data : See below
+ *   1) "http://tizen.org/appcontrol/data/selected"
+ *
+ * - ATTACH_PANEL_CONTENT_CATEGORY_VOICE
+ *   appid : "attach-panel-voicerecorder"
+ *   operation : APP_CONTROL_OPERATION_CREATE_CONTENT
+ *   mime : NULL
+ *   extra_data : See below
+ *   1) APP_CONTROL_DATA_SELECTION_MODE : "single"
+ *   2) "http://tizen.org/appcontrol/data/total_size" : any bytes
+ *   return data : See below
+ *   1) "http://tizen.org/appcontrol/data/selected"
+ *
+ * - ATTACH_PANEL_CONTENT_CATEGORY_VIDEO
+ *   appid : NULL
+ *   operation : APP_CONTROL_OPERATION_PICK
+ *   mime : "video/(asterisk)"
+ *   extra_data : See below
+ *   1) APP_CONTROL_DATA_SELECTION_MODE : "multiple"
+ *   2) "http://tizen.org/appcontrol/data/total_count" : any numbers
+ *   3) "http://tizen.org/appcontrol/data/total_size" : any bytes
+ *   return data : See below
+ *   1) "http://tizen.org/appcontrol/data/selected"
+ *
+ * - ATTACH_PANEL_CONTENT_CATEGORY_AUDIO
+ *   appid : NULL
+ *   operation : APP_CONTROL_OPERATION_PICK
+ *   mime : "audio/(asterisk)"
+ *   extra_data : See below
+ *   1) APP_CONTROL_DATA_SELECTION_MODE : "multiple"
+ *   2) "http://tizen.org/appcontrol/data/total_count" : any numbers
+ *   3) "http://tizen.org/appcontrol/data/total_size" : any bytes
+ *   return data : See below
+ *   1) "http://tizen.org/appcontrol/data/selected"
+ *
+ * - ATTACH_PANEL_CONTENT_CATEGORY_CALENDAR
+ *   appid : NULL
+ *   operation : APP_CONTROL_OPERATION_PICK
+ *   mime : "application/vnd.tizen.calendar"
+ *   extra_data : See below
+ *   1) APP_CONTROL_DATA_SELECTION_MODE : "multiple"
+ *   2) "http://tizen.org/appcontrol/data/mode" : 1
+ *   3) "http://tizen.org/appcontrol/data/type" : "vcs"
+ *   4) "http://tizen.org/appcontrol/data/total_count" : any numbers
+ *   return data : See below
+ *   1) "http://tizen.org/appcontrol/data/selected"
+ *
+ * - ATTACH_PANEL_CONTENT_CATEGORY_CONTACT
+ *   appid : NULL
+ *   operation : APP_CONTROL_OPERATION_PICK
+ *   mime : "application/vnd.tizen.contact"
+ *   extra_data : See below
+ *   1) APP_CONTROL_DATA_SELECTION_MODE : "multiple"
+ *   2) "http://tizen.org/appcontrol/data/type" : "vcf"
+ *   return data : See below
+ *   1) "http://tizen.org/appcontrol/data/selected"
+ *
+ * - ATTACH_PANEL_CONTENT_CATEGORY_MYFILES
+ *   appid : NULL
+ *   operation : APP_CONTROL_OPERATION_PICK
+ *   mime : NULL
+ *   extra_data : See below
+ *   1) APP_CONTROL_DATA_SELECTION_MODE : "multiple"
+ *   2) "http://tizen.org/appcontrol/data/total_count" : any numbers
+ *   3) "http://tizen.org/appcontrol/data/total_size" : any bytes
+ *   return data : See below
+ *   1) "http://tizen.org/appcontrol/data/selected"
+ *
+ * - ATTACH_PANEL_CONTENT_CATEGORY_VIDEO_RECORDER
+ *   appid : NULL
+ *   operation : APP_CONTROL_OPERATION_CREATE_CONTENT
+ *   mime : "video/3gp"
+ *   extra_data : See below
+ *   1) APP_CONTROL_DATA_SELECTION_MODE : "single"
+ *   2) "http://tizen.org/appcontrol/data/total_count" : any numbers
+ *   3) "http://tizen.org/appcontrol/data/total_size" : any bytes
+ *   return data : See below
+ *   1) "http://tizen.org/appcontrol/data/selected"
+
+ */
+
+
+/*
+ * attach-panel(Caller) <-> ui-gadgets(Callee) protocol
+ *
+ * - Caller send
+ *   key : "__CALLER_PANEL__"
+ *   value : "attach-panel"
+ *   when : ug_create()
+ *
+ *   key : APP_CONTROL_DATA_SELECTION_MODE
+ *   value : SELECTION_MODE_MULTIPLE
+ *   when : full mode
+ *   how : ug_send_message()
+ *
+ *   key : APP_CONTROL_DATA_SELECTION_MODE
+ *   value : SELECTION_MODE_SINGLE
+ *   when : half mode
+ *   how : ug_send_message()
+ *
+ *   key : "__ATTACH_PANEL_INITIALIZE__"
+ *   value : "enable"
+ *   when : attach_panel_show()
+ *   how : ug_send_message()
+ *
+ *   key : "__ATTACH_PANEL_SHOW_CONTENT_CATEGORY__"
+ *   value : "true" or "false"
+ *   when : set as true when the content category is shown, and false when it is hidden.
+ *   how : ug_send_message()
+ *
+ * - Callee send
+ *   key : "__ATTACH_PANEL_FLICK_DOWN__"
+ *   value : "enable" or "disable"
+ *   when : ug is full, then ug has events.
+ *   how : ug_send_result()
+ *
+ *   key : "__ATTACH_PANEL_FULL_MODE__"
+ *   value : "enable"
+ *   when : ug needs to be shown on the full mode
+ *   how : ug_send_result()
+ *
+ *   key : "__ATTACH_PANEL_SHOW_TOOLBAR__"
+ *   value : "true" or "false"
+ *   when : set as true when the panel's tabbar needs to be shown, and false when it needs to be hidden.
+ *   how : ug_send_result()
+ *
+ *   key : "__ATTACH_PANEL_SHOW_PANEL__"
+ *   value : "true" or "false"
+ *   when : set as true when the panel it needs to be shown, and false when it needs to be hidden.
+ *   how : ug_send_result()
+ */
+
+
+
+enum {
+       ATTACH_PANEL_CONTENT_CATEGORY_APP = 0,
+       ATTACH_PANEL_CONTENT_CATEGORY_UG,
+};
+
+
+
+typedef enum {
+       ATTACH_PANEL_STATE_HIDE,
+       ATTACH_PANEL_STATE_HALF,
+       ATTACH_PANEL_STATE_FULL,
+} attach_panel_state_e;
+
+
+
+struct _attach_panel {
+       Evas_Object *win;
+       Evas_Object *attach_panel_rect;
+       Evas_Object *conformant;
+       Evas_Object *ui_manager;
+       Evas_Object *toolbar;
+       Evas_Object *scroller;
+       Evas_Object *gesture;
+       Evas_Object *grid;
+       Evas_Object *grid_page;
+       Elm_Object_Item *grid_tabbar_item;
+
+       Eina_List *content_list;
+
+       Ecore_Idler *append_idler;
+
+       attach_panel_state_e attach_panel_port_state;
+       attach_panel_state_e attach_panel_land_state;
+       attach_panel_result_cb result_cb;
+       void *result_data;
+       attach_panel_event_cb event_cb;
+       void *event_data;
+
+       Evas_Coord transit_width;
+       Evas_Coord transit_height;
+
+       Eina_Bool is_delete;
+       Eina_Bool rotate;
+       Eina_Bool flick;
+       int cur_page_no;
+       int cur_event_state;
+       int magic_no;
+};
+typedef struct _attach_panel attach_panel_s;
+
+
+
+struct _innate_content {
+       /* default information */
+       const char *appid;
+       const char *name;
+       const char *icon;
+       const char *tabbar_name;
+       int content_category;
+       int is_ug;
+
+       /* launching features */
+       const char *operation;
+       const char *type;
+       const char *item_type;
+       const char *selection_mode;
+       const char *mime;
+       int mode;
+       int max;
+};
+typedef struct _innate_content innate_content_s;
+
+
+
+struct _content {
+       attach_panel_s *attach_panel;
+       innate_content_s *innate_content_info;
+       Elm_Object_Item *tabbar_item;
+       Elm_Object_Item *grid_item;
+       Evas_Object *content;
+       Evas_Object *page;
+       bundle *extra_data;
+       int index;
+       int order;
+};
+typedef struct _content content_s;
+
+
+
+extern void _attach_panel_del(attach_panel_s *attach_panel);
+
+
+
+#endif // __TIZEN_ATTACH_PANEL_INTERNAL_H__
diff --git a/include/conf.h b/include/conf.h
new file mode 100644 (file)
index 0000000..c0cb907
--- /dev/null
@@ -0,0 +1,28 @@
+/*
+ * Copyright (c) 2015 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * 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.
+ */
+
+#ifndef __ATTACH_PANEL_CONF_H__
+#define __ATTACH_PANEL_CONF_H__
+
+#define TOOLBAR_HEIGHT (54)
+#define BASE_TRANSIT_HEIGHT_REL 0.34
+#define GRID_ROW_COUNT 4
+#define GRID_ITEM_HEIGHT_REL 1.15
+#define GRID_ICON_SIZE_REL 0.5
+#define ORDER_MAX 99
+
+
+#endif
diff --git a/include/content_list.h b/include/content_list.h
new file mode 100644 (file)
index 0000000..7abd204
--- /dev/null
@@ -0,0 +1,30 @@
+/*
+ * Copyright (c) 2015 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * 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.
+ */
+
+#ifndef __TIZEN_ATTACH_PANEL_CONTENT_LIST_H__
+#define __TIZEN_ATTACH_PANEL_CONTENT_LIST_H__
+
+#include <Elementary.h>
+
+
+
+void _content_list_send_message(Eina_List *list, const char *key, const char *value, int is_ug);
+void _content_list_send_message_to_content(Eina_List *list, const char *key, const char *value, int cur_page_no);
+void _content_list_set_pause(Eina_List *list, int is_ug);
+void _content_list_set_resume(Eina_List *list, int is_ug);
+
+
+#endif
diff --git a/include/gesture.h b/include/gesture.h
new file mode 100644 (file)
index 0000000..5fd1247
--- /dev/null
@@ -0,0 +1,35 @@
+/*
+ * Copyright (c) 2015 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * 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.
+ */
+
+#ifndef __TIZEN_ATTACH_PANEL_GESTURE_H__
+#define __TIZEN_ATTACH_PANEL_GESTURE_H__
+
+#include <Elementary.h>
+
+
+
+extern void _gesture_show(attach_panel_h attach_panel);
+extern void _gesture_hide(attach_panel_h attach_panel);
+
+extern void _gesture_set_full_mode(attach_panel_h attach_panel);
+extern attach_panel_state_e _gesture_get_state(void);
+extern void _gesture_set_state(attach_panel_state_e state);
+
+extern Evas_Object *_gesture_create(attach_panel_h attach_panel);
+extern void _gesture_destroy(attach_panel_h attach_panel);
+
+
+#endif
diff --git a/include/grid.h b/include/grid.h
new file mode 100644 (file)
index 0000000..7c122f3
--- /dev/null
@@ -0,0 +1,32 @@
+/*
+ * Copyright (c) 2015 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * 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.
+ */
+
+#ifndef __ATTACH_PANEL_GRID_H__
+#define __ATTACH_PANEL_GRID_H__
+
+#include <Elementary.h>
+
+extern Evas_Object *_grid_create(Evas_Object *page, attach_panel_h attach_panel);
+extern void _grid_destroy(Evas_Object *grid);
+extern void _grid_refresh(Evas_Object *grid);
+
+extern Elm_Object_Item *_grid_append_item(Evas_Object *grid, content_s *content_info);
+extern void _grid_remove_item(Evas_Object *grid, content_s *content_info);
+
+extern int _grid_count_item(Evas_Object *grid);
+extern Eina_Bool _grid_can_flick(attach_panel_h attach_panel);
+
+#endif /* __ATTACH_PANEL_GRID_H__ */
diff --git a/include/list.h b/include/list.h
new file mode 100644 (file)
index 0000000..69eddc5
--- /dev/null
@@ -0,0 +1,22 @@
+/*
+ * Copyright (c) 2015 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * 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.
+ */
+
+#ifndef __ATTACH_PANEL_LIST_H__
+#define __ATTACH_PANEL_LIST_H__
+
+extern Eina_List *_list_sort_by_rua(Eina_List *content_list);
+
+#endif
diff --git a/include/log.h b/include/log.h
new file mode 100644 (file)
index 0000000..8d7bfeb
--- /dev/null
@@ -0,0 +1,89 @@
+/*
+ * Copyright (c) 2015 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * 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.
+ */
+
+#ifndef __ATTACH_PANEL_LOG_H__
+#define __ATTACH_PANEL_LOG_H__
+
+#include <dlog.h>
+
+#undef LOG_TAG
+#define LOG_TAG "ATTACH_PANEL"
+
+#if defined(D_)
+#undef D_
+#endif
+#define D_(str) dgettext(PACKAGE, str)
+
+#if !defined(_D)
+#define _D(fmt, arg...) LOGD(fmt"\n", ##arg)
+#endif
+
+#if !defined(_W)
+#define _W(fmt, arg...) LOGW(fmt"\n", ##arg)
+#endif
+
+#if !defined(_E)
+#define _E(fmt, arg...) LOGE(fmt"\n", ##arg)
+#endif
+
+#if !defined(_SD)
+#define _SD(fmt, arg...) SECURE_LOGD(fmt"\n", ##arg)
+#endif
+
+#if !defined(_SW)
+#define _SW(fmt, arg...) SECURE_LOGW(fmt"\n", ##arg)
+#endif
+
+#if !defined(_SE)
+#define _SE(fmt, arg...) SECURE_LOGE(fmt"\n", ##arg)
+#endif
+
+#define retv_if(expr, val) do { \
+       if(expr) { \
+               _E("(%s) -> %s() return", #expr, __FUNCTION__); \
+               return (val); \
+       } \
+} while (0)
+
+#define ret_if(expr) do { \
+       if(expr) { \
+               _E("(%s) -> %s() return", #expr, __FUNCTION__); \
+               return; \
+       } \
+} while (0)
+
+#define goto_if(expr, val) do { \
+       if(expr) { \
+               _E("(%s) -> goto", #expr); \
+               goto val; \
+       } \
+} while (0)
+
+#define break_if(expr) { \
+       if(expr) { \
+               _E("(%s) -> break", #expr); \
+               break; \
+       } \
+}
+
+#define continue_if(expr) { \
+       if(expr) { \
+               _E("(%s) -> continue", #expr); \
+               continue; \
+       } \
+}
+
+#endif /* __ATTACH_PANEL_LOG_H__ */
diff --git a/include/page.h b/include/page.h
new file mode 100644 (file)
index 0000000..3e9f9ad
--- /dev/null
@@ -0,0 +1,27 @@
+/*
+ * Copyright (c) 2015 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * 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.
+ */
+
+#ifndef __ATTACH_PANEL_PAGE_H__
+#define __ATTACH_PANEL_PAGE_H__
+
+#include <Elementary.h>
+
+extern Evas_Object *_page_create(attach_panel_h attach_panel, int width, int height);
+extern void _page_destroy(Evas_Object *page);
+
+extern void _page_resize(Evas_Object *page, int width, int height);
+
+#endif /* __ATTACH_PANEL_PAGE_H__ */
diff --git a/include/scroller.h b/include/scroller.h
new file mode 100644 (file)
index 0000000..a9938d4
--- /dev/null
@@ -0,0 +1,42 @@
+/*
+ * Copyright (c) 2015 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * 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.
+ */
+
+#ifndef __ATTACH_PANEL_SCROLLER_H__
+#define __ATTACH_PANEL_SCROLLER_H__
+
+#include <Elementary.h>
+
+typedef enum {
+       SCROLLER_EVENT_TYPE_INVALID = 0,
+       SCROLLER_EVENT_TYPE_SCROLL,
+       SCROLLER_EVENT_TYPE_MAX,
+} scroller_event_type_e;
+
+extern Evas_Object *_scroller_create(Evas_Object *ui_manager, attach_panel_h attach_panel);
+extern void _scroller_destroy(Evas_Object *scroller);
+
+extern void _scroller_append_page(Evas_Object *scroller, Evas_Object *page);
+extern void _scroller_remove_page(Evas_Object *scroller, Evas_Object *page);
+
+extern void _scroller_bring_in_page(Evas_Object *scroller, Evas_Object *page, int *cur_page_no);
+
+extern int _scroller_is_scrolling(Evas_Object *scroller);
+extern void _scroller_resize(Evas_Object *scroller, int width, int height);
+
+extern int _scroller_register_event_cb(Evas_Object *scroller, int event_type, void (*event_cb)(Evas_Object *scroller, int event_type, void *event_info, void *data), void *data);
+extern int _scroller_unregister_event_cb(Evas_Object *scroller, int event_type, void (*event_cb)(Evas_Object *scroller, int event_type, void *event_info, void *data));
+
+#endif /* __ATTACH_PANEL_SCROLLER_H__ */
diff --git a/include/toolbar.h b/include/toolbar.h
new file mode 100644 (file)
index 0000000..5fa8924
--- /dev/null
@@ -0,0 +1,41 @@
+/*
+ * Copyright (c) 2015 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * 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.
+ */
+
+#ifndef __ATTACH_PANEL_TOOLBAR_H__
+#define __ATTACH_PANEL_TOOLBAR_H__
+
+#include <Elementary.h>
+
+typedef enum {
+       TOOLBAR_EVENT_TYPE_INVALID = 0,
+       TOOLBAR_EVENT_TYPE_CHANGE_TAB,
+       TOOLBAR_EVENT_TYPE_MAX,
+} toolbar_event_type_e;
+
+extern Evas_Object *_toolbar_create(Evas_Object *ui_manager, attach_panel_h attach_panel);
+extern void _toolbar_destroy(Evas_Object *toolbar);
+
+extern Elm_Object_Item *_toolbar_append_item(Evas_Object *toolbar, const char *tab_name, Evas_Object *page);
+extern void _toolbar_remove_item(Evas_Object *toolbar, Elm_Object_Item *tabbar_item);
+
+extern void _toolbar_bring_in(Evas_Object *toolbar, Elm_Object_Item *tabbar_item);
+extern unsigned int _toolbar_count_item(Evas_Object *toolbar);
+
+
+extern int _toolbar_register_event_cb(Evas_Object *toolbar, int event_type, void (*event_cb)(Evas_Object *toolbar, int event_type, void *event_info, void *data), void *data);
+extern int _toolbar_unregister_event_cb(Evas_Object *toolbar, int event_type, void (*event_cb)(Evas_Object *toolbar, int event_type, void *event_info, void *data));
+
+#endif /* __ATTACH_PANEL_TOOLBAR_H__ */
diff --git a/include/ug.h b/include/ug.h
new file mode 100644 (file)
index 0000000..a39b84f
--- /dev/null
@@ -0,0 +1,25 @@
+/*
+ * Copyright (c) 2015 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * 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.
+ */
+
+#ifndef __TIZEN_ATTACH_PANEL_UG_H__
+#define __TIZEN_ATTACH_PANEL_UG_H__
+
+#include <Elementary.h>
+
+extern Evas_Object *_ug_create(const char *appid, const char *operation, const char *selection_mode, const char *mime, bundle *bundle, content_s *content_info);
+extern void _ug_destroy(Evas_Object *ug_layout);
+
+#endif /* __TIZEN_ATTACH_PANEL_UG_H__ */
diff --git a/include/ui_manager.h b/include/ui_manager.h
new file mode 100644 (file)
index 0000000..fc71378
--- /dev/null
@@ -0,0 +1,30 @@
+/*
+ * Copyright (c) 2015 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * 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.
+ */
+
+#ifndef __TIZEN_ATTACH_PANEL_UI_MANAGER_H__
+#define __TIZEN_ATTACH_PANEL_UI_MANAGER_H__
+
+#include <Elementary.h>
+
+extern int _ui_manager_append_content_category(Evas_Object *ui_manager, innate_content_s *innate_content_info, bundle *extra_data);
+extern void _ui_manager_remove_content_category(Evas_Object *ui_manager, content_s *content_info);
+
+extern Evas_Object *_ui_manager_create(attach_panel_h attach_panel);
+extern void _ui_manager_destroy(Evas_Object *ui_manager);
+extern Evas_Object *_ui_manager_create_content(Evas_Object *page, content_s *content_info, attach_panel_h attach_panel);
+extern void _ui_manager_destroy_content(content_s *content_info, attach_panel_h attach_panel);
+
+#endif /* __TIZEN_ATTACH_PANEL_UI_MANAGER_H__ */
diff --git a/packaging/attach-panel.spec b/packaging/attach-panel.spec
new file mode 100755 (executable)
index 0000000..f970f50
--- /dev/null
@@ -0,0 +1,79 @@
+Name:       attach-panel
+Summary:    Attach Panel
+Version:    0.1.0
+Release:    0
+Group:      Application
+License:    Apache-2.0
+Source0:    %{name}-%{version}.tar.gz
+
+%if "%{?tizen_profile_name}" == "wearable"
+ExcludeArch: %{arm} %ix86 x86_64
+%endif
+
+BuildRequires: cmake
+BuildRequires: edje-tools
+BuildRequires: gettext-tools
+
+BuildRequires: pkgconfig(appcore-efl)
+BuildRequires: pkgconfig(aul)
+BuildRequires: pkgconfig(bundle)
+BuildRequires: pkgconfig(capi-base-common)
+BuildRequires: pkgconfig(capi-system-info)
+BuildRequires: pkgconfig(dlog)
+BuildRequires: pkgconfig(ecore)
+BuildRequires: pkgconfig(edje)
+BuildRequires: pkgconfig(efl-extension)
+BuildRequires: pkgconfig(elementary)
+BuildRequires: pkgconfig(evas)
+BuildRequires: pkgconfig(feedback)
+BuildRequires: pkgconfig(isf)
+BuildRequires: pkgconfig(security-privilege-checker)
+BuildRequires: pkgconfig(ui-gadget-1)
+BuildRequires: pkgconfig(rua)
+
+%description
+Description: Attach Panel
+
+%prep
+%setup -q
+
+%package devel
+Summary:    Attach panel library (devel)
+Group:      Application
+Requires:   %{name} = %{version}-%{release}
+
+%description devel
+Development files needed to build software that needs Attach panel.
+
+%build
+export CFLAGS="$CFLAGS -DTIZEN_DEBUG_ENABLE"
+export CXXFLAGS="$CXXFLAGS -DTIZEN_DEBUG_ENABLE"
+export FFLAGS="$FFLAGS -DTIZEN_DEBUG_ENABLE"
+
+%if 0%{?tizen_build_binary_release_type_eng}
+export CFLAGS="$CFLAGS -DTIZEN_ENGINEER_MODE"
+export CXXFLAGS="$CXXFLAGS -DTIZEN_ENGINEER_MODE"
+export FFLAGS="$FFLAGS -DTIZEN_ENGINEER_MODE"
+%endif
+
+%cmake . -DCMAKE_INSTALL_PREFIX=%{_prefix}
+make %{?jobs:-j%jobs}
+
+%install
+rm -rf %{buildroot}
+%make_install
+
+%post
+
+%files
+%manifest %{name}.manifest
+%{_prefix}/lib/*.so*
+%{_datadir}/attach-panel/edje/*.edj
+%{_datadir}/attach-panel/sample/*
+%{_datadir}/icons/*.png
+%{_prefix}/ug/res/locale/*/LC_MESSAGES/*
+
+%files devel
+%defattr(-,root,root,-)
+%{_includedir}/attach-panel/attach_panel.h
+%{_libdir}/pkgconfig/%{name}.pc
diff --git a/po/CMakeLists.txt b/po/CMakeLists.txt
new file mode 100755 (executable)
index 0000000..c15ddcc
--- /dev/null
@@ -0,0 +1,92 @@
+# for i18n
+
+SET(POFILES
+       ar.po
+       az.po
+       bg.po
+       bn.po
+       ca.po
+       cs.po
+       da.po
+       de.po
+       de_DE.po
+       el_GR.po
+       en.po
+       en_PH.po
+       en_US.po
+       es_ES.po
+       es_MX.po
+       es_US.po
+       et.po
+       eu.po
+       fa.po
+       fi.po
+       fr.po
+       fr_CA.po
+       fr_FR.po
+       ga.po
+       gl.po
+       gu.po
+       he.po
+       hi.po
+       hr.po
+       hu.po
+       hy.po
+       is.po
+       it_IT.po
+       ja_JP.po
+       ka.po
+       kk.po
+       kn.po
+       ko_KR.po
+       lt.po
+       lv.po
+       mk.po
+       ml.po
+       mn_MN.po
+       nb.po
+       nl.po
+       nl_NL.po
+       pl.po
+       pt_BR.po
+       pt_PT.po
+       ro.po
+       ru_RU.po
+       si.po
+       sk.po
+       sl.po
+       sr.po
+       sv.po
+       ta.po
+       te.po
+       th.po
+       tr_TR.po
+       uk.po
+       ur.po
+       uz.po
+       zh_CN.po
+       zh_HK.po
+       zh_SG.po
+       zh_TW.po
+)
+
+SET(MSGFMT "/usr/bin/msgfmt")
+
+FOREACH(pofile ${POFILES})
+       SET(pofile ${CMAKE_CURRENT_SOURCE_DIR}/${pofile})
+       MESSAGE("PO: ${pofile}")
+       GET_FILENAME_COMPONENT(absPofile ${pofile} ABSOLUTE)
+       GET_FILENAME_COMPONENT(lang ${absPofile} NAME_WE)
+       SET(moFile ${CMAKE_CURRENT_BINARY_DIR}/${lang}.mo)
+       ADD_CUSTOM_COMMAND(
+               OUTPUT ${moFile}
+               COMMAND ${MSGFMT} -o ${moFile} ${absPofile}
+               DEPENDS ${absPofile}
+       )
+
+       INSTALL(FILES ${moFile} DESTINATION /usr/ug/res/locale/${lang}/LC_MESSAGES RENAME ${PROJECT_NAME}.mo)
+       SET(moFiles ${moFiles} ${moFile})
+ENDFOREACH(pofile)
+
+MESSAGE(".mo files: ${moFiles}")
+ADD_CUSTOM_TARGET(po ALL DEPENDS ${moFiles})
diff --git a/po/ar.po b/po/ar.po
new file mode 100755 (executable)
index 0000000..081bcfe
--- /dev/null
+++ b/po/ar.po
@@ -0,0 +1,30 @@
+msgid "IDS_EMAIL_BUTTON2_CALENDAR"
+msgstr "التقويم"
+
+msgid "IDS_COM_TAB4_IMAGES_ABB2"
+msgstr "الصور"
+
+msgid "IDS_COM_TAB4_CAMERA"
+msgstr "الكاميرا"
+
+msgid "IDS_COM_TAB4_VOICE"
+msgstr "الصوت"
+
+msgid "IDS_COM_TAB4_MORE_ABB"
+msgstr "المزيد"
+
+msgid "IDS_COM_BUTTON2_VIDEOS"
+msgstr "مقاطع فيديو"
+
+msgid "IDS_COM_BUTTON2_AUDIO_FILES"
+msgstr "ملفات الصوت"
+
+msgid "IDS_COM_BUTTON2_CONTACTS"
+msgstr "جهات الاتصال"
+
+msgid "IDS_COM_BUTTON_MY_FILES_ABB"
+msgstr "ملفاتي"
+
+msgid "IDS_IDLE_BUTTON2_RECORD_NVIDEO_ABB"
+msgstr "تسجيل\nفيديو"
+
diff --git a/po/az.po b/po/az.po
new file mode 100755 (executable)
index 0000000..55f574e
--- /dev/null
+++ b/po/az.po
@@ -0,0 +1,30 @@
+msgid "IDS_EMAIL_BUTTON2_CALENDAR"
+msgstr "Təqvim"
+
+msgid "IDS_COM_TAB4_IMAGES_ABB2"
+msgstr "Şəkil"
+
+msgid "IDS_COM_TAB4_CAMERA"
+msgstr "Kamera"
+
+msgid "IDS_COM_TAB4_VOICE"
+msgstr "Səs"
+
+msgid "IDS_COM_TAB4_MORE_ABB"
+msgstr "Dh çx"
+
+msgid "IDS_COM_BUTTON2_VIDEOS"
+msgstr "Videolar"
+
+msgid "IDS_COM_BUTTON2_AUDIO_FILES"
+msgstr "Audio fayllar"
+
+msgid "IDS_COM_BUTTON2_CONTACTS"
+msgstr "Əlaqələr"
+
+msgid "IDS_COM_BUTTON_MY_FILES_ABB"
+msgstr "Fayllarım"
+
+msgid "IDS_IDLE_BUTTON2_RECORD_NVIDEO_ABB"
+msgstr "Video\nyaz"
+
diff --git a/po/bg.po b/po/bg.po
new file mode 100755 (executable)
index 0000000..52b7ae7
--- /dev/null
+++ b/po/bg.po
@@ -0,0 +1,30 @@
+msgid "IDS_EMAIL_BUTTON2_CALENDAR"
+msgstr "Календар"
+
+msgid "IDS_COM_TAB4_IMAGES_ABB2"
+msgstr "Изобр."
+
+msgid "IDS_COM_TAB4_CAMERA"
+msgstr "Камера"
+
+msgid "IDS_COM_TAB4_VOICE"
+msgstr "Глас"
+
+msgid "IDS_COM_TAB4_MORE_ABB"
+msgstr "Още"
+
+msgid "IDS_COM_BUTTON2_VIDEOS"
+msgstr "Видеоклипове"
+
+msgid "IDS_COM_BUTTON2_AUDIO_FILES"
+msgstr "Аудиофайлове"
+
+msgid "IDS_COM_BUTTON2_CONTACTS"
+msgstr "Контакти"
+
+msgid "IDS_COM_BUTTON_MY_FILES_ABB"
+msgstr "Моите файлове"
+
+msgid "IDS_IDLE_BUTTON2_RECORD_NVIDEO_ABB"
+msgstr "Запис\nвидео"
+
diff --git a/po/bn.po b/po/bn.po
new file mode 100755 (executable)
index 0000000..3cd66b9
--- /dev/null
+++ b/po/bn.po
@@ -0,0 +1,30 @@
+msgid "IDS_EMAIL_BUTTON2_CALENDAR"
+msgstr "ক্যালেন্ডার"
+
+msgid "IDS_COM_TAB4_IMAGES_ABB2"
+msgstr "চিত্র"
+
+msgid "IDS_COM_TAB4_CAMERA"
+msgstr "ক্যামেরা"
+
+msgid "IDS_COM_TAB4_VOICE"
+msgstr "ভয়েস"
+
+msgid "IDS_COM_TAB4_MORE_ABB"
+msgstr "আরও"
+
+msgid "IDS_COM_BUTTON2_VIDEOS"
+msgstr "ভিডিওগুলি"
+
+msgid "IDS_COM_BUTTON2_AUDIO_FILES"
+msgstr "অডিও ফাইলগুলি"
+
+msgid "IDS_COM_BUTTON2_CONTACTS"
+msgstr "পরিচিতিগুলি"
+
+msgid "IDS_COM_BUTTON_MY_FILES_ABB"
+msgstr "আমার ফাইলগুলি"
+
+msgid "IDS_IDLE_BUTTON2_RECORD_NVIDEO_ABB"
+msgstr "ভিডিও\nরেকর্ড করুন"
+
diff --git a/po/ca.po b/po/ca.po
new file mode 100755 (executable)
index 0000000..9005227
--- /dev/null
+++ b/po/ca.po
@@ -0,0 +1,30 @@
+msgid "IDS_EMAIL_BUTTON2_CALENDAR"
+msgstr "Calendari"
+
+msgid "IDS_COM_TAB4_IMAGES_ABB2"
+msgstr "Imatge"
+
+msgid "IDS_COM_TAB4_CAMERA"
+msgstr "Càmera"
+
+msgid "IDS_COM_TAB4_VOICE"
+msgstr "Veu"
+
+msgid "IDS_COM_TAB4_MORE_ABB"
+msgstr "Més"
+
+msgid "IDS_COM_BUTTON2_VIDEOS"
+msgstr "Vídeos"
+
+msgid "IDS_COM_BUTTON2_AUDIO_FILES"
+msgstr "Fitxers d'àudio"
+
+msgid "IDS_COM_BUTTON2_CONTACTS"
+msgstr "Contactes"
+
+msgid "IDS_COM_BUTTON_MY_FILES_ABB"
+msgstr "Meus fitx"
+
+msgid "IDS_IDLE_BUTTON2_RECORD_NVIDEO_ABB"
+msgstr "Gravar\nvídeo"
+
diff --git a/po/cs.po b/po/cs.po
new file mode 100755 (executable)
index 0000000..fc2943b
--- /dev/null
+++ b/po/cs.po
@@ -0,0 +1,30 @@
+msgid "IDS_EMAIL_BUTTON2_CALENDAR"
+msgstr "Kalendář"
+
+msgid "IDS_COM_TAB4_IMAGES_ABB2"
+msgstr "Obráz."
+
+msgid "IDS_COM_TAB4_CAMERA"
+msgstr "Fotoap"
+
+msgid "IDS_COM_TAB4_VOICE"
+msgstr "Hlas"
+
+msgid "IDS_COM_TAB4_MORE_ABB"
+msgstr "Další"
+
+msgid "IDS_COM_BUTTON2_VIDEOS"
+msgstr "Videa"
+
+msgid "IDS_COM_BUTTON2_AUDIO_FILES"
+msgstr "Zvukové soubory"
+
+msgid "IDS_COM_BUTTON2_CONTACTS"
+msgstr "Kontakty"
+
+msgid "IDS_COM_BUTTON_MY_FILES_ABB"
+msgstr "Moje soubory"
+
+msgid "IDS_IDLE_BUTTON2_RECORD_NVIDEO_ABB"
+msgstr "Nahrát\nvideo"
+
diff --git a/po/da.po b/po/da.po
new file mode 100755 (executable)
index 0000000..7e0de72
--- /dev/null
+++ b/po/da.po
@@ -0,0 +1,30 @@
+msgid "IDS_EMAIL_BUTTON2_CALENDAR"
+msgstr "Kalender"
+
+msgid "IDS_COM_TAB4_IMAGES_ABB2"
+msgstr "Bldr."
+
+msgid "IDS_COM_TAB4_CAMERA"
+msgstr "Kamera"
+
+msgid "IDS_COM_TAB4_VOICE"
+msgstr "Stemme"
+
+msgid "IDS_COM_TAB4_MORE_ABB"
+msgstr "Mere"
+
+msgid "IDS_COM_BUTTON2_VIDEOS"
+msgstr "Videoer"
+
+msgid "IDS_COM_BUTTON2_AUDIO_FILES"
+msgstr "Lydfiler"
+
+msgid "IDS_COM_BUTTON2_CONTACTS"
+msgstr "Kontakter"
+
+msgid "IDS_COM_BUTTON_MY_FILES_ABB"
+msgstr "Mine filer"
+
+msgid "IDS_IDLE_BUTTON2_RECORD_NVIDEO_ABB"
+msgstr "Optag\nvideo"
+
diff --git a/po/de.po b/po/de.po
new file mode 100755 (executable)
index 0000000..996368b
--- /dev/null
+++ b/po/de.po
@@ -0,0 +1,30 @@
+msgid "IDS_EMAIL_BUTTON2_CALENDAR"
+msgstr "Kalender"
+
+msgid "IDS_COM_TAB4_IMAGES_ABB2"
+msgstr "Bilder"
+
+msgid "IDS_COM_TAB4_CAMERA"
+msgstr "Kamera"
+
+msgid "IDS_COM_TAB4_VOICE"
+msgstr "Ton"
+
+msgid "IDS_COM_TAB4_MORE_ABB"
+msgstr "Mehr"
+
+msgid "IDS_COM_BUTTON2_VIDEOS"
+msgstr "Videos"
+
+msgid "IDS_COM_BUTTON2_AUDIO_FILES"
+msgstr "Audiodateien"
+
+msgid "IDS_COM_BUTTON2_CONTACTS"
+msgstr "Kontakte"
+
+msgid "IDS_COM_BUTTON_MY_FILES_ABB"
+msgstr "Eigene Dateien"
+
+msgid "IDS_IDLE_BUTTON2_RECORD_NVIDEO_ABB"
+msgstr "Video\naufnehmen"
+
diff --git a/po/de_DE.po b/po/de_DE.po
new file mode 100755 (executable)
index 0000000..d403a4a
--- /dev/null
@@ -0,0 +1,90 @@
+msgid "IDS_ST_MBODY_HOME_SCREEN_WALLPAPER"
+msgstr "Hintergrund (Startbildschirm)"
+
+msgid "IDS_ST_BODY_GALLERY"
+msgstr "Galerie"
+
+msgid "IDS_COM_HEADER_NOTIFICATION"
+msgstr "Benachrichtigung"
+
+msgid "IDS_ST_HEADER_HOME_SCREEN_ABB"
+msgstr "Startbildschirm"
+
+msgid "IDS_ST_BODY_WALLPAPER"
+msgstr "Hintergrundbild"
+
+msgid "IDS_ST_BODY_HOME_SCREEN_SETTINGS"
+msgstr "Startseiten-Einstellungen"
+
+msgid "IDS_ST_BODY_HOME_SCREEN_TYPE"
+msgstr "Startanzeige-Typ"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "Abbruch"
+
+msgid "IDS_ST_HEADER_HOME_SCREEN"
+msgstr "Startbildschirm"
+
+msgid "IDS_ST_BODY_DEFAULT_HOME_SCREEN"
+msgstr "Klassicher Modus"
+
+msgid "IDS_ST_BUTTON2_SET_AS_HOME"
+msgstr "Home-Taste"
+
+msgid "IDS_ST_BODY_SELECT_APPLICATION"
+msgstr "Anwendung auswählen"
+
+msgid "IDS_ST_BODY_EASY_MODE"
+msgstr "Einfacher Modus"
+
+msgid "IDS_ST_BODY_THE_OVERALL_LAYOUT_OF_THE_HOME_SCREEN_WILL_BE_SIMPLIFIED"
+msgstr "Das generelle Layout des Startbildschirms wird vereinfacht."
+
+msgid "IDS_ST_BODY_HOME_SCREEN_STYLE"
+msgstr "Stil des Startbildschirms"
+
+msgid "IDS_LCKSCN_BODY_WALLPAPERS"
+msgstr "Hintergrund"
+
+msgid "IDS_SCR_POP_SCREEN_READER_IS_NOT_SUPPORTED_BY_PS_PRESS_THE_BACK_KEY_TO_RETURN_TO_THE_PREVIOUS_SCREEN"
+msgstr "Das Bildschirmleseprogramm wird von %s nicht unterstützt. Drücken Sie die Zurück-Taste, um zum vorherigen Bildschirm zurückzukehren."
+
+msgid "IDS_HELP_BODY_SELECT_AN_OPTION"
+msgstr "Option auswählen."
+
+msgid "IDS_COM_BODY_MENU_ABB"
+msgstr "Menü"
+
+msgid "IDS_HS_OPT_SPIRAL"
+msgstr "Spirale"
+
+msgid "IDS_HS_OPT_INNER_CUBE"
+msgstr "Innerer Kubus"
+
+msgid "IDS_HS_OPT_OUTER_CUBE"
+msgstr "Äußerer Kubus"
+
+msgid "IDS_HS_OPT_CAROUSEL"
+msgstr "Karussell"
+
+msgid "IDS_HS_HEADER_PAGE_NAVIGATION_EFFECT"
+msgstr "Effekt für Seitennavigation"
+
+msgid "IDS_ST_HEADER_SELECT_WALLPAPER_FROM_ABB"
+msgstr "Hintergrund auswählen aus"
+
+msgid "IDS_HS_POP_EASY_MODE_CAN_BE_DISABLED_IN_SETTINGS"
+msgstr "Der einfache Modus kann in den Einstellungen deaktiviert werden."
+
+msgid "IDS_ST_BODY_3D_ROTATION_M_EFFECT"
+msgstr "3D-Drehung"
+
+msgid "IDS_ST_BODY_LOADING_ING"
+msgstr "Lädt..."
+
+msgid "IDS_ST_POP_THE_FONT_SIZE_CAN_BE_INCREASED_TO_MAKE_TEXT_EASIER_TO_READ_CHANGE_THE_FONT_SIZE_NOW_Q"
+msgstr "Die Schrift kann vergrößert werden, damit Text leichter lesbar ist. Schriftgröße jetzt ändern?"
+
+msgid "IDS_ST_SK_CHANGE"
+msgstr "Ändern"
+
diff --git a/po/el_GR.po b/po/el_GR.po
new file mode 100755 (executable)
index 0000000..e00207a
--- /dev/null
@@ -0,0 +1,30 @@
+msgid "IDS_EMAIL_BUTTON2_CALENDAR"
+msgstr "Ημερολόγιο"
+
+msgid "IDS_COM_TAB4_IMAGES_ABB2"
+msgstr "Εικόν."
+
+msgid "IDS_COM_TAB4_CAMERA"
+msgstr "Κάμερα"
+
+msgid "IDS_COM_TAB4_VOICE"
+msgstr "Φωνή"
+
+msgid "IDS_COM_TAB4_MORE_ABB"
+msgstr "Περισ."
+
+msgid "IDS_COM_BUTTON2_VIDEOS"
+msgstr "Βίντεο"
+
+msgid "IDS_COM_BUTTON2_AUDIO_FILES"
+msgstr "Αρχεία ήχου"
+
+msgid "IDS_COM_BUTTON2_CONTACTS"
+msgstr "Επαφές"
+
+msgid "IDS_COM_BUTTON_MY_FILES_ABB"
+msgstr "Τα Αρχεία Μου"
+
+msgid "IDS_IDLE_BUTTON2_RECORD_NVIDEO_ABB"
+msgstr "Εγγραφή\nβίντεο"
+
diff --git a/po/en.po b/po/en.po
new file mode 100755 (executable)
index 0000000..5dab7a8
--- /dev/null
+++ b/po/en.po
@@ -0,0 +1,30 @@
+msgid "IDS_EMAIL_BUTTON2_CALENDAR"
+msgstr "Calendar"
+
+msgid "IDS_COM_TAB4_IMAGES_ABB2"
+msgstr "Images"
+
+msgid "IDS_COM_TAB4_CAMERA"
+msgstr "Camera"
+
+msgid "IDS_COM_TAB4_VOICE"
+msgstr "Voice"
+
+msgid "IDS_COM_TAB4_MORE_ABB"
+msgstr "More"
+
+msgid "IDS_COM_BUTTON2_VIDEOS"
+msgstr "Videos"
+
+msgid "IDS_COM_BUTTON2_AUDIO_FILES"
+msgstr "Audio files"
+
+msgid "IDS_COM_BUTTON2_CONTACTS"
+msgstr "Contacts"
+
+msgid "IDS_COM_BUTTON_MY_FILES_ABB"
+msgstr "My Files"
+
+msgid "IDS_IDLE_BUTTON2_RECORD_NVIDEO_ABB"
+msgstr "Record\nvideo"
+
diff --git a/po/en_PH.po b/po/en_PH.po
new file mode 100755 (executable)
index 0000000..5dab7a8
--- /dev/null
@@ -0,0 +1,30 @@
+msgid "IDS_EMAIL_BUTTON2_CALENDAR"
+msgstr "Calendar"
+
+msgid "IDS_COM_TAB4_IMAGES_ABB2"
+msgstr "Images"
+
+msgid "IDS_COM_TAB4_CAMERA"
+msgstr "Camera"
+
+msgid "IDS_COM_TAB4_VOICE"
+msgstr "Voice"
+
+msgid "IDS_COM_TAB4_MORE_ABB"
+msgstr "More"
+
+msgid "IDS_COM_BUTTON2_VIDEOS"
+msgstr "Videos"
+
+msgid "IDS_COM_BUTTON2_AUDIO_FILES"
+msgstr "Audio files"
+
+msgid "IDS_COM_BUTTON2_CONTACTS"
+msgstr "Contacts"
+
+msgid "IDS_COM_BUTTON_MY_FILES_ABB"
+msgstr "My Files"
+
+msgid "IDS_IDLE_BUTTON2_RECORD_NVIDEO_ABB"
+msgstr "Record\nvideo"
+
diff --git a/po/en_US.po b/po/en_US.po
new file mode 100755 (executable)
index 0000000..5dab7a8
--- /dev/null
@@ -0,0 +1,30 @@
+msgid "IDS_EMAIL_BUTTON2_CALENDAR"
+msgstr "Calendar"
+
+msgid "IDS_COM_TAB4_IMAGES_ABB2"
+msgstr "Images"
+
+msgid "IDS_COM_TAB4_CAMERA"
+msgstr "Camera"
+
+msgid "IDS_COM_TAB4_VOICE"
+msgstr "Voice"
+
+msgid "IDS_COM_TAB4_MORE_ABB"
+msgstr "More"
+
+msgid "IDS_COM_BUTTON2_VIDEOS"
+msgstr "Videos"
+
+msgid "IDS_COM_BUTTON2_AUDIO_FILES"
+msgstr "Audio files"
+
+msgid "IDS_COM_BUTTON2_CONTACTS"
+msgstr "Contacts"
+
+msgid "IDS_COM_BUTTON_MY_FILES_ABB"
+msgstr "My Files"
+
+msgid "IDS_IDLE_BUTTON2_RECORD_NVIDEO_ABB"
+msgstr "Record\nvideo"
+
diff --git a/po/es_ES.po b/po/es_ES.po
new file mode 100755 (executable)
index 0000000..a0fdd56
--- /dev/null
@@ -0,0 +1,30 @@
+msgid "IDS_EMAIL_BUTTON2_CALENDAR"
+msgstr "Calendario"
+
+msgid "IDS_COM_TAB4_IMAGES_ABB2"
+msgstr "Imagen"
+
+msgid "IDS_COM_TAB4_CAMERA"
+msgstr "Cámara"
+
+msgid "IDS_COM_TAB4_VOICE"
+msgstr "Voz"
+
+msgid "IDS_COM_TAB4_MORE_ABB"
+msgstr "Más"
+
+msgid "IDS_COM_BUTTON2_VIDEOS"
+msgstr "Vídeos"
+
+msgid "IDS_COM_BUTTON2_AUDIO_FILES"
+msgstr "Archivos de audio"
+
+msgid "IDS_COM_BUTTON2_CONTACTS"
+msgstr "Contactos"
+
+msgid "IDS_COM_BUTTON_MY_FILES_ABB"
+msgstr "Mis archivos"
+
+msgid "IDS_IDLE_BUTTON2_RECORD_NVIDEO_ABB"
+msgstr "Grabar\nvídeo"
+
diff --git a/po/es_MX.po b/po/es_MX.po
new file mode 100755 (executable)
index 0000000..d7c53be
--- /dev/null
@@ -0,0 +1,90 @@
+msgid "IDS_ST_MBODY_HOME_SCREEN_WALLPAPER"
+msgstr "Fondo de pantalla de inicio"
+
+msgid "IDS_ST_BODY_GALLERY"
+msgstr "Galería"
+
+msgid "IDS_COM_HEADER_NOTIFICATION"
+msgstr "Notificación"
+
+msgid "IDS_ST_HEADER_HOME_SCREEN_ABB"
+msgstr "Pantalla de inicio"
+
+msgid "IDS_ST_BODY_WALLPAPER"
+msgstr "Fondo de pantalla"
+
+msgid "IDS_ST_BODY_HOME_SCREEN_SETTINGS"
+msgstr "Configuración de pantalla de inicio"
+
+msgid "IDS_ST_BODY_HOME_SCREEN_TYPE"
+msgstr "Tipo de pantalla de inicio"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "Cancelar"
+
+msgid "IDS_ST_HEADER_HOME_SCREEN"
+msgstr "Pantalla de inicio"
+
+msgid "IDS_ST_BODY_DEFAULT_HOME_SCREEN"
+msgstr "Pantalla de inicio predeterminada"
+
+msgid "IDS_ST_BUTTON2_SET_AS_HOME"
+msgstr "Def. inicio"
+
+msgid "IDS_ST_BODY_SELECT_APPLICATION"
+msgstr "Seleccionar aplicación"
+
+msgid "IDS_ST_BODY_EASY_MODE"
+msgstr "Modo fácil"
+
+msgid "IDS_ST_BODY_THE_OVERALL_LAYOUT_OF_THE_HOME_SCREEN_WILL_BE_SIMPLIFIED"
+msgstr "Se simplificará el diseño general de la pantalla de inicio."
+
+msgid "IDS_ST_BODY_HOME_SCREEN_STYLE"
+msgstr "Estilo de pantalla de inicio"
+
+msgid "IDS_LCKSCN_BODY_WALLPAPERS"
+msgstr "Fondos de pantalla"
+
+msgid "IDS_SCR_POP_SCREEN_READER_IS_NOT_SUPPORTED_BY_PS_PRESS_THE_BACK_KEY_TO_RETURN_TO_THE_PREVIOUS_SCREEN"
+msgstr "El Lector de pantalla no es compatible con %s. Presione la tecla Atrás para regresar a la pantalla anterior."
+
+msgid "IDS_HELP_BODY_SELECT_AN_OPTION"
+msgstr "Seleccione una opción"
+
+msgid "IDS_COM_BODY_MENU_ABB"
+msgstr "Menú"
+
+msgid "IDS_HS_OPT_SPIRAL"
+msgstr "Espiral"
+
+msgid "IDS_HS_OPT_INNER_CUBE"
+msgstr "Cubo interior"
+
+msgid "IDS_HS_OPT_OUTER_CUBE"
+msgstr "Cubo exterior"
+
+msgid "IDS_HS_OPT_CAROUSEL"
+msgstr "Carrusel"
+
+msgid "IDS_HS_HEADER_PAGE_NAVIGATION_EFFECT"
+msgstr "Efecto de navegación de página"
+
+msgid "IDS_ST_HEADER_SELECT_WALLPAPER_FROM_ABB"
+msgstr "Selec. fondo de pantalla de"
+
+msgid "IDS_HS_POP_EASY_MODE_CAN_BE_DISABLED_IN_SETTINGS"
+msgstr "El modo fácil se puede desactivar en Configuración"
+
+msgid "IDS_ST_BODY_3D_ROTATION_M_EFFECT"
+msgstr "Rotación 3D"
+
+msgid "IDS_ST_BODY_LOADING_ING"
+msgstr "Cargando..."
+
+msgid "IDS_ST_POP_THE_FONT_SIZE_CAN_BE_INCREASED_TO_MAKE_TEXT_EASIER_TO_READ_CHANGE_THE_FONT_SIZE_NOW_Q"
+msgstr "El tamaño de la fuente se puede aumentar para poder leer el texto con más facilidad. ¿Cambiar el tamaño de la fuente ahora?"
+
+msgid "IDS_ST_SK_CHANGE"
+msgstr "Cambiar"
+
diff --git a/po/es_US.po b/po/es_US.po
new file mode 100755 (executable)
index 0000000..07fd95f
--- /dev/null
@@ -0,0 +1,30 @@
+msgid "IDS_EMAIL_BUTTON2_CALENDAR"
+msgstr "Calendario"
+
+msgid "IDS_COM_TAB4_IMAGES_ABB2"
+msgstr "Imagen"
+
+msgid "IDS_COM_TAB4_CAMERA"
+msgstr "Cámara"
+
+msgid "IDS_COM_TAB4_VOICE"
+msgstr "Voz"
+
+msgid "IDS_COM_TAB4_MORE_ABB"
+msgstr "Más"
+
+msgid "IDS_COM_BUTTON2_VIDEOS"
+msgstr "Videos"
+
+msgid "IDS_COM_BUTTON2_AUDIO_FILES"
+msgstr "Archivos de audio"
+
+msgid "IDS_COM_BUTTON2_CONTACTS"
+msgstr "Contactos"
+
+msgid "IDS_COM_BUTTON_MY_FILES_ABB"
+msgstr "Mis archivos"
+
+msgid "IDS_IDLE_BUTTON2_RECORD_NVIDEO_ABB"
+msgstr "Grabar\nvideo"
+
diff --git a/po/et.po b/po/et.po
new file mode 100755 (executable)
index 0000000..db3907a
--- /dev/null
+++ b/po/et.po
@@ -0,0 +1,30 @@
+msgid "IDS_EMAIL_BUTTON2_CALENDAR"
+msgstr "Kalender"
+
+msgid "IDS_COM_TAB4_IMAGES_ABB2"
+msgstr "Pildid"
+
+msgid "IDS_COM_TAB4_CAMERA"
+msgstr "Kaam."
+
+msgid "IDS_COM_TAB4_VOICE"
+msgstr "Hääl"
+
+msgid "IDS_COM_TAB4_MORE_ABB"
+msgstr "Veel"
+
+msgid "IDS_COM_BUTTON2_VIDEOS"
+msgstr "Videod"
+
+msgid "IDS_COM_BUTTON2_AUDIO_FILES"
+msgstr "Helifailid"
+
+msgid "IDS_COM_BUTTON2_CONTACTS"
+msgstr "Kontaktid"
+
+msgid "IDS_COM_BUTTON_MY_FILES_ABB"
+msgstr "Minu failid"
+
+msgid "IDS_IDLE_BUTTON2_RECORD_NVIDEO_ABB"
+msgstr "Salvesta\nvideo"
+
diff --git a/po/eu.po b/po/eu.po
new file mode 100755 (executable)
index 0000000..dd6bc36
--- /dev/null
+++ b/po/eu.po
@@ -0,0 +1,30 @@
+msgid "IDS_EMAIL_BUTTON2_CALENDAR"
+msgstr "Egutegia"
+
+msgid "IDS_COM_TAB4_IMAGES_ABB2"
+msgstr "Irudiak"
+
+msgid "IDS_COM_TAB4_CAMERA"
+msgstr "Kamera"
+
+msgid "IDS_COM_TAB4_VOICE"
+msgstr "Ahotsa"
+
+msgid "IDS_COM_TAB4_MORE_ABB"
+msgstr "Gehia."
+
+msgid "IDS_COM_BUTTON2_VIDEOS"
+msgstr "Bideoak"
+
+msgid "IDS_COM_BUTTON2_AUDIO_FILES"
+msgstr "Audio fitxategiak"
+
+msgid "IDS_COM_BUTTON2_CONTACTS"
+msgstr "Kontaktuak"
+
+msgid "IDS_COM_BUTTON_MY_FILES_ABB"
+msgstr "Nire fitxat."
+
+msgid "IDS_IDLE_BUTTON2_RECORD_NVIDEO_ABB"
+msgstr "Grabatu\nbideoa"
+
diff --git a/po/fa.po b/po/fa.po
new file mode 100755 (executable)
index 0000000..cc320a1
--- /dev/null
+++ b/po/fa.po
@@ -0,0 +1,30 @@
+msgid "IDS_EMAIL_BUTTON2_CALENDAR"
+msgstr "تقویم"
+
+msgid "IDS_COM_TAB4_IMAGES_ABB2"
+msgstr "تصاویر"
+
+msgid "IDS_COM_TAB4_CAMERA"
+msgstr "دوربين"
+
+msgid "IDS_COM_TAB4_VOICE"
+msgstr "صدا"
+
+msgid "IDS_COM_TAB4_MORE_ABB"
+msgstr "بیشتر"
+
+msgid "IDS_COM_BUTTON2_VIDEOS"
+msgstr "ویدیوها"
+
+msgid "IDS_COM_BUTTON2_AUDIO_FILES"
+msgstr "فایل‌های صوتی"
+
+msgid "IDS_COM_BUTTON2_CONTACTS"
+msgstr "مخاطبين"
+
+msgid "IDS_COM_BUTTON_MY_FILES_ABB"
+msgstr "فایل‌های من"
+
+msgid "IDS_IDLE_BUTTON2_RECORD_NVIDEO_ABB"
+msgstr "ضبط\nویدیو"
+
diff --git a/po/fi.po b/po/fi.po
new file mode 100755 (executable)
index 0000000..dee19b2
--- /dev/null
+++ b/po/fi.po
@@ -0,0 +1,30 @@
+msgid "IDS_EMAIL_BUTTON2_CALENDAR"
+msgstr "Kalenteri"
+
+msgid "IDS_COM_TAB4_IMAGES_ABB2"
+msgstr "Kuvat"
+
+msgid "IDS_COM_TAB4_CAMERA"
+msgstr "Kamera"
+
+msgid "IDS_COM_TAB4_VOICE"
+msgstr "Puhe"
+
+msgid "IDS_COM_TAB4_MORE_ABB"
+msgstr "Lisää"
+
+msgid "IDS_COM_BUTTON2_VIDEOS"
+msgstr "Videot"
+
+msgid "IDS_COM_BUTTON2_AUDIO_FILES"
+msgstr "Ääni-\ntiedostot"
+
+msgid "IDS_COM_BUTTON2_CONTACTS"
+msgstr "Yhteystiedot"
+
+msgid "IDS_COM_BUTTON_MY_FILES_ABB"
+msgstr "Omat tied."
+
+msgid "IDS_IDLE_BUTTON2_RECORD_NVIDEO_ABB"
+msgstr "Tallenna\nvideota"
+
diff --git a/po/fr.po b/po/fr.po
new file mode 100755 (executable)
index 0000000..b756122
--- /dev/null
+++ b/po/fr.po
@@ -0,0 +1,30 @@
+msgid "IDS_EMAIL_BUTTON2_CALENDAR"
+msgstr "Calendrier"
+
+msgid "IDS_COM_TAB4_IMAGES_ABB2"
+msgstr "Images"
+
+msgid "IDS_COM_TAB4_CAMERA"
+msgstr "Photo"
+
+msgid "IDS_COM_TAB4_VOICE"
+msgstr "Voix"
+
+msgid "IDS_COM_TAB4_MORE_ABB"
+msgstr "Plus"
+
+msgid "IDS_COM_BUTTON2_VIDEOS"
+msgstr "Vidéos"
+
+msgid "IDS_COM_BUTTON2_AUDIO_FILES"
+msgstr "Fichiers audio"
+
+msgid "IDS_COM_BUTTON2_CONTACTS"
+msgstr "Contacts"
+
+msgid "IDS_COM_BUTTON_MY_FILES_ABB"
+msgstr "Mes fichiers"
+
+msgid "IDS_IDLE_BUTTON2_RECORD_NVIDEO_ABB"
+msgstr "Enreg.\nvidéo"
+
diff --git a/po/fr_CA.po b/po/fr_CA.po
new file mode 100755 (executable)
index 0000000..7375cf8
--- /dev/null
@@ -0,0 +1,30 @@
+msgid "IDS_EMAIL_BUTTON2_CALENDAR"
+msgstr "Calendrier"
+
+msgid "IDS_COM_TAB4_IMAGES_ABB2"
+msgstr "Images"
+
+msgid "IDS_COM_TAB4_CAMERA"
+msgstr "Photo"
+
+msgid "IDS_COM_TAB4_VOICE"
+msgstr "Voix"
+
+msgid "IDS_COM_TAB4_MORE_ABB"
+msgstr "Plus"
+
+msgid "IDS_COM_BUTTON2_VIDEOS"
+msgstr "Vidéos"
+
+msgid "IDS_COM_BUTTON2_AUDIO_FILES"
+msgstr "Fichiers audios"
+
+msgid "IDS_COM_BUTTON2_CONTACTS"
+msgstr "Contacts"
+
+msgid "IDS_COM_BUTTON_MY_FILES_ABB"
+msgstr "Mes fichiers"
+
+msgid "IDS_IDLE_BUTTON2_RECORD_NVIDEO_ABB"
+msgstr "Enreg.\nvidéo"
+
diff --git a/po/fr_FR.po b/po/fr_FR.po
new file mode 100755 (executable)
index 0000000..81d70be
--- /dev/null
@@ -0,0 +1,90 @@
+msgid "IDS_ST_MBODY_HOME_SCREEN_WALLPAPER"
+msgstr "Fond d'écran d'accueil"
+
+msgid "IDS_ST_BODY_GALLERY"
+msgstr "Galerie"
+
+msgid "IDS_COM_HEADER_NOTIFICATION"
+msgstr "Notification"
+
+msgid "IDS_ST_HEADER_HOME_SCREEN_ABB"
+msgstr "Écran d'accueil"
+
+msgid "IDS_ST_BODY_WALLPAPER"
+msgstr "Fond d'écran"
+
+msgid "IDS_ST_BODY_HOME_SCREEN_SETTINGS"
+msgstr "Paramètres de l'écran d'accueil"
+
+msgid "IDS_ST_BODY_HOME_SCREEN_TYPE"
+msgstr "Type d'écran d'accueil"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "Annuler"
+
+msgid "IDS_ST_HEADER_HOME_SCREEN"
+msgstr "Écran d'accueil"
+
+msgid "IDS_ST_BODY_DEFAULT_HOME_SCREEN"
+msgstr "Écran d'accueil par déf."
+
+msgid "IDS_ST_BUTTON2_SET_AS_HOME"
+msgstr "Accueil"
+
+msgid "IDS_ST_BODY_SELECT_APPLICATION"
+msgstr "Sélectionnez une application"
+
+msgid "IDS_ST_BODY_EASY_MODE"
+msgstr "Mode simplifié"
+
+msgid "IDS_ST_BODY_THE_OVERALL_LAYOUT_OF_THE_HOME_SCREEN_WILL_BE_SIMPLIFIED"
+msgstr "La disposition générale de l'écran d'accueil sera simplifiée."
+
+msgid "IDS_ST_BODY_HOME_SCREEN_STYLE"
+msgstr "Style d'écran d'accueil"
+
+msgid "IDS_LCKSCN_BODY_WALLPAPERS"
+msgstr "Fonds d'écran"
+
+msgid "IDS_SCR_POP_SCREEN_READER_IS_NOT_SUPPORTED_BY_PS_PRESS_THE_BACK_KEY_TO_RETURN_TO_THE_PREVIOUS_SCREEN"
+msgstr "Le lecteur d'écran n'est pas pris en charge par %s. Appuyez sur la touche Retour pour revenir à l'écran d'accueil."
+
+msgid "IDS_HELP_BODY_SELECT_AN_OPTION"
+msgstr "Sélectionnez une option."
+
+msgid "IDS_COM_BODY_MENU_ABB"
+msgstr "Menu"
+
+msgid "IDS_HS_OPT_SPIRAL"
+msgstr "Spirale"
+
+msgid "IDS_HS_OPT_INNER_CUBE"
+msgstr "Cube intérieur"
+
+msgid "IDS_HS_OPT_OUTER_CUBE"
+msgstr "Cube extérieur"
+
+msgid "IDS_HS_OPT_CAROUSEL"
+msgstr "Manège"
+
+msgid "IDS_HS_HEADER_PAGE_NAVIGATION_EFFECT"
+msgstr "Effet de navigation sur la page"
+
+msgid "IDS_ST_HEADER_SELECT_WALLPAPER_FROM_ABB"
+msgstr "Sélec. fond écran depuis"
+
+msgid "IDS_HS_POP_EASY_MODE_CAN_BE_DISABLED_IN_SETTINGS"
+msgstr "Le mode facile peut être désactivé dans Paramètres"
+
+msgid "IDS_ST_BODY_3D_ROTATION_M_EFFECT"
+msgstr "Rotation 3D"
+
+msgid "IDS_ST_BODY_LOADING_ING"
+msgstr "Chargement en cours."
+
+msgid "IDS_ST_POP_THE_FONT_SIZE_CAN_BE_INCREASED_TO_MAKE_TEXT_EASIER_TO_READ_CHANGE_THE_FONT_SIZE_NOW_Q"
+msgstr "Vous pouvez augmenter la taille de la police pour faciliter la lecture du texte. Changer la taille de la police maintenant ?"
+
+msgid "IDS_ST_SK_CHANGE"
+msgstr "Modifier"
+
diff --git a/po/ga.po b/po/ga.po
new file mode 100755 (executable)
index 0000000..a89db5a
--- /dev/null
+++ b/po/ga.po
@@ -0,0 +1,30 @@
+msgid "IDS_EMAIL_BUTTON2_CALENDAR"
+msgstr "Féilire"
+
+msgid "IDS_COM_TAB4_IMAGES_ABB2"
+msgstr "Íomhánna"
+
+msgid "IDS_COM_TAB4_CAMERA"
+msgstr "Ceam."
+
+msgid "IDS_COM_TAB4_VOICE"
+msgstr "Guth"
+
+msgid "IDS_COM_TAB4_MORE_ABB"
+msgstr "Tuill."
+
+msgid "IDS_COM_BUTTON2_VIDEOS"
+msgstr "Físeáin"
+
+msgid "IDS_COM_BUTTON2_AUDIO_FILES"
+msgstr "Comhaid fuaime"
+
+msgid "IDS_COM_BUTTON2_CONTACTS"
+msgstr "Teagmhálaithe"
+
+msgid "IDS_COM_BUTTON_MY_FILES_ABB"
+msgstr "Mo Chomhaid"
+
+msgid "IDS_IDLE_BUTTON2_RECORD_NVIDEO_ABB"
+msgstr "Taifead\nfíseán"
+
diff --git a/po/gl.po b/po/gl.po
new file mode 100755 (executable)
index 0000000..86b21e5
--- /dev/null
+++ b/po/gl.po
@@ -0,0 +1,30 @@
+msgid "IDS_EMAIL_BUTTON2_CALENDAR"
+msgstr "Calendario"
+
+msgid "IDS_COM_TAB4_IMAGES_ABB2"
+msgstr "Imaxes"
+
+msgid "IDS_COM_TAB4_CAMERA"
+msgstr "Cámara"
+
+msgid "IDS_COM_TAB4_VOICE"
+msgstr "Voz"
+
+msgid "IDS_COM_TAB4_MORE_ABB"
+msgstr "Máis"
+
+msgid "IDS_COM_BUTTON2_VIDEOS"
+msgstr "Vídeos"
+
+msgid "IDS_COM_BUTTON2_AUDIO_FILES"
+msgstr "Arquivos de son"
+
+msgid "IDS_COM_BUTTON2_CONTACTS"
+msgstr "Contactos"
+
+msgid "IDS_COM_BUTTON_MY_FILES_ABB"
+msgstr "Os meus arqu."
+
+msgid "IDS_IDLE_BUTTON2_RECORD_NVIDEO_ABB"
+msgstr "Gravar\nvídeo"
+
diff --git a/po/gu.po b/po/gu.po
new file mode 100755 (executable)
index 0000000..11bae67
--- /dev/null
+++ b/po/gu.po
@@ -0,0 +1,30 @@
+msgid "IDS_EMAIL_BUTTON2_CALENDAR"
+msgstr "કૅલેન્ડર"
+
+msgid "IDS_COM_TAB4_IMAGES_ABB2"
+msgstr "છબીઓ"
+
+msgid "IDS_COM_TAB4_CAMERA"
+msgstr "કૅમેરા"
+
+msgid "IDS_COM_TAB4_VOICE"
+msgstr "અવાજ"
+
+msgid "IDS_COM_TAB4_MORE_ABB"
+msgstr "વધુ"
+
+msgid "IDS_COM_BUTTON2_VIDEOS"
+msgstr "વિડિયોઝ"
+
+msgid "IDS_COM_BUTTON2_AUDIO_FILES"
+msgstr "ઓડિયો ફાઇલ્સ"
+
+msgid "IDS_COM_BUTTON2_CONTACTS"
+msgstr "સંપર્કો"
+
+msgid "IDS_COM_BUTTON_MY_FILES_ABB"
+msgstr "મારી ફાઇલ્સ"
+
+msgid "IDS_IDLE_BUTTON2_RECORD_NVIDEO_ABB"
+msgstr "વિડિયો\nરેકોર્ડ કરો"
+
diff --git a/po/he.po b/po/he.po
new file mode 100755 (executable)
index 0000000..758ddcf
--- /dev/null
+++ b/po/he.po
@@ -0,0 +1,30 @@
+msgid "IDS_EMAIL_BUTTON2_CALENDAR"
+msgstr "לוח שנה"
+
+msgid "IDS_COM_TAB4_IMAGES_ABB2"
+msgstr "תמונות"
+
+msgid "IDS_COM_TAB4_CAMERA"
+msgstr "מצלמה"
+
+msgid "IDS_COM_TAB4_VOICE"
+msgstr "קול"
+
+msgid "IDS_COM_TAB4_MORE_ABB"
+msgstr "עוד"
+
+msgid "IDS_COM_BUTTON2_VIDEOS"
+msgstr "סרטונים"
+
+msgid "IDS_COM_BUTTON2_AUDIO_FILES"
+msgstr "קובצי שמע"
+
+msgid "IDS_COM_BUTTON2_CONTACTS"
+msgstr "אנשי קשר"
+
+msgid "IDS_COM_BUTTON_MY_FILES_ABB"
+msgstr "הקבצים שלי"
+
+msgid "IDS_IDLE_BUTTON2_RECORD_NVIDEO_ABB"
+msgstr "צלם\nוידאו"
+
diff --git a/po/hi.po b/po/hi.po
new file mode 100755 (executable)
index 0000000..73f99cd
--- /dev/null
+++ b/po/hi.po
@@ -0,0 +1,30 @@
+msgid "IDS_EMAIL_BUTTON2_CALENDAR"
+msgstr "कैलेंडर"
+
+msgid "IDS_COM_TAB4_IMAGES_ABB2"
+msgstr "छवियाँ"
+
+msgid "IDS_COM_TAB4_CAMERA"
+msgstr "कैमरा"
+
+msgid "IDS_COM_TAB4_VOICE"
+msgstr "वॉइस"
+
+msgid "IDS_COM_TAB4_MORE_ABB"
+msgstr "अधिक"
+
+msgid "IDS_COM_BUTTON2_VIDEOS"
+msgstr "वीडियोज"
+
+msgid "IDS_COM_BUTTON2_AUDIO_FILES"
+msgstr "ऑडियो फाइलें"
+
+msgid "IDS_COM_BUTTON2_CONTACTS"
+msgstr "संपर्क"
+
+msgid "IDS_COM_BUTTON_MY_FILES_ABB"
+msgstr "मेरी फाइलें"
+
+msgid "IDS_IDLE_BUTTON2_RECORD_NVIDEO_ABB"
+msgstr "वीडियो\nरिकॉर्ड करे"
+
diff --git a/po/hr.po b/po/hr.po
new file mode 100755 (executable)
index 0000000..90431db
--- /dev/null
+++ b/po/hr.po
@@ -0,0 +1,30 @@
+msgid "IDS_EMAIL_BUTTON2_CALENDAR"
+msgstr "Kalendar"
+
+msgid "IDS_COM_TAB4_IMAGES_ABB2"
+msgstr "Slike"
+
+msgid "IDS_COM_TAB4_CAMERA"
+msgstr "Kamera"
+
+msgid "IDS_COM_TAB4_VOICE"
+msgstr "Glas"
+
+msgid "IDS_COM_TAB4_MORE_ABB"
+msgstr "Više"
+
+msgid "IDS_COM_BUTTON2_VIDEOS"
+msgstr "Videozapisi"
+
+msgid "IDS_COM_BUTTON2_AUDIO_FILES"
+msgstr "Audio datoteke"
+
+msgid "IDS_COM_BUTTON2_CONTACTS"
+msgstr "Imenik"
+
+msgid "IDS_COM_BUTTON_MY_FILES_ABB"
+msgstr "Moje datoteke"
+
+msgid "IDS_IDLE_BUTTON2_RECORD_NVIDEO_ABB"
+msgstr "Snimi\nvideo."
+
diff --git a/po/hu.po b/po/hu.po
new file mode 100755 (executable)
index 0000000..c8d400a
--- /dev/null
+++ b/po/hu.po
@@ -0,0 +1,30 @@
+msgid "IDS_EMAIL_BUTTON2_CALENDAR"
+msgstr "Naptár"
+
+msgid "IDS_COM_TAB4_IMAGES_ABB2"
+msgstr "Képek"
+
+msgid "IDS_COM_TAB4_CAMERA"
+msgstr "Kamera"
+
+msgid "IDS_COM_TAB4_VOICE"
+msgstr "Hang"
+
+msgid "IDS_COM_TAB4_MORE_ABB"
+msgstr "Egyéb"
+
+msgid "IDS_COM_BUTTON2_VIDEOS"
+msgstr "Videók"
+
+msgid "IDS_COM_BUTTON2_AUDIO_FILES"
+msgstr "Hangfájlok"
+
+msgid "IDS_COM_BUTTON2_CONTACTS"
+msgstr "Névjegyzék"
+
+msgid "IDS_COM_BUTTON_MY_FILES_ABB"
+msgstr "Saját fájlok"
+
+msgid "IDS_IDLE_BUTTON2_RECORD_NVIDEO_ABB"
+msgstr "Videó-\nrögzítés"
+
diff --git a/po/hy.po b/po/hy.po
new file mode 100755 (executable)
index 0000000..9c43710
--- /dev/null
+++ b/po/hy.po
@@ -0,0 +1,30 @@
+msgid "IDS_EMAIL_BUTTON2_CALENDAR"
+msgstr "Օրացույց"
+
+msgid "IDS_COM_TAB4_IMAGES_ABB2"
+msgstr "Պատկեր"
+
+msgid "IDS_COM_TAB4_CAMERA"
+msgstr "Խցիկ"
+
+msgid "IDS_COM_TAB4_VOICE"
+msgstr "Ձայն"
+
+msgid "IDS_COM_TAB4_MORE_ABB"
+msgstr "Ավելին"
+
+msgid "IDS_COM_BUTTON2_VIDEOS"
+msgstr "Տեսանյութեր"
+
+msgid "IDS_COM_BUTTON2_AUDIO_FILES"
+msgstr "Ձայնաֆայլեր"
+
+msgid "IDS_COM_BUTTON2_CONTACTS"
+msgstr "Կոնտակտներ"
+
+msgid "IDS_COM_BUTTON_MY_FILES_ABB"
+msgstr "Իմ Ֆայլերը"
+
+msgid "IDS_IDLE_BUTTON2_RECORD_NVIDEO_ABB"
+msgstr "Տեսագրել"
+
diff --git a/po/is.po b/po/is.po
new file mode 100755 (executable)
index 0000000..d4871e1
--- /dev/null
+++ b/po/is.po
@@ -0,0 +1,30 @@
+msgid "IDS_EMAIL_BUTTON2_CALENDAR"
+msgstr "Dagatal"
+
+msgid "IDS_COM_TAB4_IMAGES_ABB2"
+msgstr "Myndir"
+
+msgid "IDS_COM_TAB4_CAMERA"
+msgstr "Taka"
+
+msgid "IDS_COM_TAB4_VOICE"
+msgstr "Rödd"
+
+msgid "IDS_COM_TAB4_MORE_ABB"
+msgstr "Meira"
+
+msgid "IDS_COM_BUTTON2_VIDEOS"
+msgstr "Myndskeið"
+
+msgid "IDS_COM_BUTTON2_AUDIO_FILES"
+msgstr "Hljóðskrár"
+
+msgid "IDS_COM_BUTTON2_CONTACTS"
+msgstr "Tengiliðir"
+
+msgid "IDS_COM_BUTTON_MY_FILES_ABB"
+msgstr "Skrár"
+
+msgid "IDS_IDLE_BUTTON2_RECORD_NVIDEO_ABB"
+msgstr "Taka\nmyndskeið"
+
diff --git a/po/it_IT.po b/po/it_IT.po
new file mode 100755 (executable)
index 0000000..96350b9
--- /dev/null
@@ -0,0 +1,30 @@
+msgid "IDS_EMAIL_BUTTON2_CALENDAR"
+msgstr "Calendario"
+
+msgid "IDS_COM_TAB4_IMAGES_ABB2"
+msgstr "Immagini"
+
+msgid "IDS_COM_TAB4_CAMERA"
+msgstr "Camera"
+
+msgid "IDS_COM_TAB4_VOICE"
+msgstr "Voce"
+
+msgid "IDS_COM_TAB4_MORE_ABB"
+msgstr "Altro"
+
+msgid "IDS_COM_BUTTON2_VIDEOS"
+msgstr "Video"
+
+msgid "IDS_COM_BUTTON2_AUDIO_FILES"
+msgstr "File audio"
+
+msgid "IDS_COM_BUTTON2_CONTACTS"
+msgstr "Rubrica"
+
+msgid "IDS_COM_BUTTON_MY_FILES_ABB"
+msgstr "Archivio"
+
+msgid "IDS_IDLE_BUTTON2_RECORD_NVIDEO_ABB"
+msgstr "Registra\nvideo"
+
diff --git a/po/ja_JP.po b/po/ja_JP.po
new file mode 100755 (executable)
index 0000000..870054c
--- /dev/null
@@ -0,0 +1,30 @@
+msgid "IDS_EMAIL_BUTTON2_CALENDAR"
+msgstr "カレンダー"
+
+msgid "IDS_COM_TAB4_IMAGES_ABB2"
+msgstr "画像"
+
+msgid "IDS_COM_TAB4_CAMERA"
+msgstr "カメラ"
+
+msgid "IDS_COM_TAB4_VOICE"
+msgstr "音声"
+
+msgid "IDS_COM_TAB4_MORE_ABB"
+msgstr "その他"
+
+msgid "IDS_COM_BUTTON2_VIDEOS"
+msgstr "動画"
+
+msgid "IDS_COM_BUTTON2_AUDIO_FILES"
+msgstr "オーディオファイル"
+
+msgid "IDS_COM_BUTTON2_CONTACTS"
+msgstr "連絡先"
+
+msgid "IDS_COM_BUTTON_MY_FILES_ABB"
+msgstr "マイファイル"
+
+msgid "IDS_IDLE_BUTTON2_RECORD_NVIDEO_ABB"
+msgstr "録画"
+
diff --git a/po/ka.po b/po/ka.po
new file mode 100755 (executable)
index 0000000..b78df59
--- /dev/null
+++ b/po/ka.po
@@ -0,0 +1,30 @@
+msgid "IDS_EMAIL_BUTTON2_CALENDAR"
+msgstr "კალენდარი"
+
+msgid "IDS_COM_TAB4_IMAGES_ABB2"
+msgstr "სურათი"
+
+msgid "IDS_COM_TAB4_CAMERA"
+msgstr "კამერა"
+
+msgid "IDS_COM_TAB4_VOICE"
+msgstr "ხმა"
+
+msgid "IDS_COM_TAB4_MORE_ABB"
+msgstr "სხვა"
+
+msgid "IDS_COM_BUTTON2_VIDEOS"
+msgstr "ვიდეოები"
+
+msgid "IDS_COM_BUTTON2_AUDIO_FILES"
+msgstr "აუდიოფაილები"
+
+msgid "IDS_COM_BUTTON2_CONTACTS"
+msgstr "კონტაქტები"
+
+msgid "IDS_COM_BUTTON_MY_FILES_ABB"
+msgstr "ჩემი ფაილები"
+
+msgid "IDS_IDLE_BUTTON2_RECORD_NVIDEO_ABB"
+msgstr "ვიდეოს\nჩაწერა"
+
diff --git a/po/kk.po b/po/kk.po
new file mode 100755 (executable)
index 0000000..b287346
--- /dev/null
+++ b/po/kk.po
@@ -0,0 +1,30 @@
+msgid "IDS_EMAIL_BUTTON2_CALENDAR"
+msgstr "Күнтізбе"
+
+msgid "IDS_COM_TAB4_IMAGES_ABB2"
+msgstr "Сурет"
+
+msgid "IDS_COM_TAB4_CAMERA"
+msgstr "Камера"
+
+msgid "IDS_COM_TAB4_VOICE"
+msgstr "Дауыс"
+
+msgid "IDS_COM_TAB4_MORE_ABB"
+msgstr "Тағы"
+
+msgid "IDS_COM_BUTTON2_VIDEOS"
+msgstr "Бейнелер"
+
+msgid "IDS_COM_BUTTON2_AUDIO_FILES"
+msgstr "Аудио файлдар"
+
+msgid "IDS_COM_BUTTON2_CONTACTS"
+msgstr "Контактілер"
+
+msgid "IDS_COM_BUTTON_MY_FILES_ABB"
+msgstr "Файлдарым"
+
+msgid "IDS_IDLE_BUTTON2_RECORD_NVIDEO_ABB"
+msgstr "Бейне\nжазу"
+
diff --git a/po/kn.po b/po/kn.po
new file mode 100755 (executable)
index 0000000..f7a4cd3
--- /dev/null
+++ b/po/kn.po
@@ -0,0 +1,30 @@
+msgid "IDS_EMAIL_BUTTON2_CALENDAR"
+msgstr "ಕ್ಯಾಲೆಂಡರ್"
+
+msgid "IDS_COM_TAB4_IMAGES_ABB2"
+msgstr "ಚಿತ್ರಗಳು"
+
+msgid "IDS_COM_TAB4_CAMERA"
+msgstr "ಕ್ಯಾಮರಾ"
+
+msgid "IDS_COM_TAB4_VOICE"
+msgstr "ಧ್ವನಿ"
+
+msgid "IDS_COM_TAB4_MORE_ABB"
+msgstr "ಹೆಚ್ಚು"
+
+msgid "IDS_COM_BUTTON2_VIDEOS"
+msgstr "ವೀಡಿಯೊಗಳು"
+
+msgid "IDS_COM_BUTTON2_AUDIO_FILES"
+msgstr "ಆಡಿಯೋ ಫೈಲ್‌ಗಳು"
+
+msgid "IDS_COM_BUTTON2_CONTACTS"
+msgstr "ಸಂಪರ್ಕಗಳು"
+
+msgid "IDS_COM_BUTTON_MY_FILES_ABB"
+msgstr "ನನ್ನ ಫೈಲ್‌ಗಳು"
+
+msgid "IDS_IDLE_BUTTON2_RECORD_NVIDEO_ABB"
+msgstr "ವೀಡಿಯೊ\nರೆಕಾರ್ಡ್"
+
diff --git a/po/ko_KR.po b/po/ko_KR.po
new file mode 100755 (executable)
index 0000000..e0a407e
--- /dev/null
@@ -0,0 +1,30 @@
+msgid "IDS_EMAIL_BUTTON2_CALENDAR"
+msgstr "캘린더"
+
+msgid "IDS_COM_TAB4_IMAGES_ABB2"
+msgstr "이미지"
+
+msgid "IDS_COM_TAB4_CAMERA"
+msgstr "카메라"
+
+msgid "IDS_COM_TAB4_VOICE"
+msgstr "음성"
+
+msgid "IDS_COM_TAB4_MORE_ABB"
+msgstr "더보기"
+
+msgid "IDS_COM_BUTTON2_VIDEOS"
+msgstr "동영상"
+
+msgid "IDS_COM_BUTTON2_AUDIO_FILES"
+msgstr "오디오 파일"
+
+msgid "IDS_COM_BUTTON2_CONTACTS"
+msgstr "연락처"
+
+msgid "IDS_COM_BUTTON_MY_FILES_ABB"
+msgstr "내 파일"
+
+msgid "IDS_IDLE_BUTTON2_RECORD_NVIDEO_ABB"
+msgstr "동영상\n촬영"
+
diff --git a/po/lt.po b/po/lt.po
new file mode 100755 (executable)
index 0000000..ae70361
--- /dev/null
+++ b/po/lt.po
@@ -0,0 +1,30 @@
+msgid "IDS_EMAIL_BUTTON2_CALENDAR"
+msgstr "Kalendorius"
+
+msgid "IDS_COM_TAB4_IMAGES_ABB2"
+msgstr "Vaizd."
+
+msgid "IDS_COM_TAB4_CAMERA"
+msgstr "Fot."
+
+msgid "IDS_COM_TAB4_VOICE"
+msgstr "Balsas"
+
+msgid "IDS_COM_TAB4_MORE_ABB"
+msgstr "Daug."
+
+msgid "IDS_COM_BUTTON2_VIDEOS"
+msgstr "Vaizdo\nįrašai"
+
+msgid "IDS_COM_BUTTON2_AUDIO_FILES"
+msgstr "Garso failai"
+
+msgid "IDS_COM_BUTTON2_CONTACTS"
+msgstr "Adresatai"
+
+msgid "IDS_COM_BUTTON_MY_FILES_ABB"
+msgstr "Mano failai"
+
+msgid "IDS_IDLE_BUTTON2_RECORD_NVIDEO_ABB"
+msgstr "Įraš.\nvaiz.įr."
+
diff --git a/po/lv.po b/po/lv.po
new file mode 100755 (executable)
index 0000000..aee4b57
--- /dev/null
+++ b/po/lv.po
@@ -0,0 +1,30 @@
+msgid "IDS_EMAIL_BUTTON2_CALENDAR"
+msgstr "Kalendārs"
+
+msgid "IDS_COM_TAB4_IMAGES_ABB2"
+msgstr "Attēli"
+
+msgid "IDS_COM_TAB4_CAMERA"
+msgstr "Kamera"
+
+msgid "IDS_COM_TAB4_VOICE"
+msgstr "Balss"
+
+msgid "IDS_COM_TAB4_MORE_ABB"
+msgstr "Vēl"
+
+msgid "IDS_COM_BUTTON2_VIDEOS"
+msgstr "Videoklipi"
+
+msgid "IDS_COM_BUTTON2_AUDIO_FILES"
+msgstr "Audio faili"
+
+msgid "IDS_COM_BUTTON2_CONTACTS"
+msgstr "Kontakti"
+
+msgid "IDS_COM_BUTTON_MY_FILES_ABB"
+msgstr "Mani faili"
+
+msgid "IDS_IDLE_BUTTON2_RECORD_NVIDEO_ABB"
+msgstr "Ierakst.\nvideo"
+
diff --git a/po/mk.po b/po/mk.po
new file mode 100755 (executable)
index 0000000..182168a
--- /dev/null
+++ b/po/mk.po
@@ -0,0 +1,30 @@
+msgid "IDS_EMAIL_BUTTON2_CALENDAR"
+msgstr "Календар"
+
+msgid "IDS_COM_TAB4_IMAGES_ABB2"
+msgstr "Слики"
+
+msgid "IDS_COM_TAB4_CAMERA"
+msgstr "Камера"
+
+msgid "IDS_COM_TAB4_VOICE"
+msgstr "Глас"
+
+msgid "IDS_COM_TAB4_MORE_ABB"
+msgstr "Повеќе"
+
+msgid "IDS_COM_BUTTON2_VIDEOS"
+msgstr "Видеа"
+
+msgid "IDS_COM_BUTTON2_AUDIO_FILES"
+msgstr "Звучни датотеки"
+
+msgid "IDS_COM_BUTTON2_CONTACTS"
+msgstr "Контакти"
+
+msgid "IDS_COM_BUTTON_MY_FILES_ABB"
+msgstr "Мои датотеки"
+
+msgid "IDS_IDLE_BUTTON2_RECORD_NVIDEO_ABB"
+msgstr "Снимање\nвидео"
+
diff --git a/po/ml.po b/po/ml.po
new file mode 100755 (executable)
index 0000000..76911ed
--- /dev/null
+++ b/po/ml.po
@@ -0,0 +1,30 @@
+msgid "IDS_EMAIL_BUTTON2_CALENDAR"
+msgstr "കലണ്ടർ"
+
+msgid "IDS_COM_TAB4_IMAGES_ABB2"
+msgstr "ചിത്ര."
+
+msgid "IDS_COM_TAB4_CAMERA"
+msgstr "ക്യാമറ"
+
+msgid "IDS_COM_TAB4_VOICE"
+msgstr "ശബ്ദം"
+
+msgid "IDS_COM_TAB4_MORE_ABB"
+msgstr "കൂടുതൽ"
+
+msgid "IDS_COM_BUTTON2_VIDEOS"
+msgstr "വീഡിയോകൾ"
+
+msgid "IDS_COM_BUTTON2_AUDIO_FILES"
+msgstr "ഓഡിയോ ഫയലുകൾ"
+
+msgid "IDS_COM_BUTTON2_CONTACTS"
+msgstr "കോൺടാക്ടുകള്‍"
+
+msgid "IDS_COM_BUTTON_MY_FILES_ABB"
+msgstr "എന്‍റെ ഫയലുകൾ"
+
+msgid "IDS_IDLE_BUTTON2_RECORD_NVIDEO_ABB"
+msgstr "വീഡിയോ\nറെക്കോർഡ് ചെയ്യുക"
+
diff --git a/po/mn_MN.po b/po/mn_MN.po
new file mode 100755 (executable)
index 0000000..78afc9b
--- /dev/null
@@ -0,0 +1,132 @@
+msgid "IDS_COM_SK_CANCEL"
+msgstr "Цуцлах"
+
+msgid "IDS_ST_MBODY_HOME_SCREEN_WALLPAPER"
+msgstr "Эхлэл дэлгэцийн зураг"
+
+msgid "IDS_ST_BODY_GALLERY"
+msgstr "Галерей"
+
+msgid "IDS_COM_HEADER_NOTIFICATION"
+msgstr "Мэдэгдэл"
+
+msgid "IDS_ST_HEADER_HOME_SCREEN_ABB"
+msgstr "Эхлэл дэлгэц"
+
+msgid "IDS_ST_HEADER_LOCK_SCREEN"
+msgstr "Түгжих дэлгэц"
+
+msgid "IDS_ST_BODY_WALLPAPER"
+msgstr "Ханын цаас"
+
+msgid "IDS_ST_BODY_HOME_AND_LOCK_SCREEN"
+msgstr "Эхлэл ба түгжих дэлгэц"
+
+msgid "IDS_ST_BODY_HOME_SCREEN_SETTINGS"
+msgstr "Эхлэл дэлгэцийн тохиргоо"
+
+msgid "IDS_ST_BODY_HOME_SCREEN_TYPE"
+msgstr "Эхлэл дэлгэцийн төрөл"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "Цуцлах"
+
+msgid "IDS_ST_HEADER_HOME_SCREEN"
+msgstr "Эх дэлгэц"
+
+msgid "IDS_ST_BODY_DEFAULT_HOME_SCREEN"
+msgstr "Өгөгдмөл эхлэл дэлгэц"
+
+msgid "IDS_ST_BUTTON2_SET_AS_HOME"
+msgstr "Үндсэн болгож тогтоох"
+
+msgid "IDS_ST_BODY_SELECT_APPLICATION"
+msgstr "Програм сонгох"
+
+msgid "IDS_ST_BODY_EASY_MODE"
+msgstr "Хялбар горим"
+
+msgid "IDS_ST_BODY_THE_OVERALL_LAYOUT_OF_THE_HOME_SCREEN_WILL_BE_SIMPLIFIED"
+msgstr "Эхлэл дэлгэцийн ерөнхий байрлалыг хялбаршуулна"
+
+msgid "IDS_ST_BODY_HOME_SCREEN_STYLE"
+msgstr "Эхлэл дэлгэцийн хэв маяг"
+
+msgid "IDS_LCKSCN_BODY_WALLPAPERS"
+msgstr "Ханын цааснууд"
+
+msgid "IDS_SCR_POP_SCREEN_READER_IS_NOT_SUPPORTED_BY_PS_PRESS_THE_BACK_KEY_TO_RETURN_TO_THE_PREVIOUS_SCREEN"
+msgstr "Дэлгэц уншигчийг %s дэмждэггүй. Өмнөх дэлгэц рүү буцахын тулд буцах товчлуурыг дар"
+
+msgid "IDS_HELP_BODY_SELECT_AN_OPTION"
+msgstr "Аль нэг сонголтыг идэвхжүүлнэ."
+
+msgid "IDS_COM_BODY_MENU_ABB"
+msgstr "Цэс"
+
+msgid "IDS_HS_OPT_SPIRAL"
+msgstr "Эргүүлэг"
+
+msgid "IDS_HS_OPT_INNER_CUBE"
+msgstr "Дотоод шоо"
+
+msgid "IDS_HS_OPT_OUTER_CUBE"
+msgstr "Гадна шоо"
+
+msgid "IDS_HS_OPT_CAROUSEL"
+msgstr "Морин тойруулга"
+
+msgid "IDS_HS_HEADER_PAGE_NAVIGATION_EFFECT"
+msgstr "Хуудас удирдах эффект"
+
+msgid "IDS_ST_HEADER_SELECT_WALLPAPER_FROM_ABB"
+msgstr "Дэлгэцийн зураг сонгох"
+
+msgid "IDS_HS_POP_EASY_MODE_CAN_BE_DISABLED_IN_SETTINGS"
+msgstr "Хялбар горимыг Тохиргоонд идэвхгүй болгож болно"
+
+msgid "IDS_HS_OPT_DISABLE_EASY_MODE"
+msgstr "Хялбар горим идэвхгүй болгох"
+
+msgid "IDS_ST_BODY_3D_ROTATION_M_EFFECT"
+msgstr "3D эргэлт"
+
+msgid "IDS_ST_BODY_LOADING_ING"
+msgstr "Ачаалж байна..."
+
+msgid "IDS_ST_POP_THE_FONT_SIZE_CAN_BE_INCREASED_TO_MAKE_TEXT_EASIER_TO_READ_CHANGE_THE_FONT_SIZE_NOW_Q"
+msgstr "Бичвэрийг уншихад амар болгохын тулд үсгийн хэмжээг өсгөж болно. Үсгийн хэмжээг одоо өөрчлөх үү?"
+
+msgid "IDS_ST_SK_CHANGE"
+msgstr "Өөрчлөх"
+
+msgid "IDS_ST_ACHEADER2_HOME_SCREEN_STYLE"
+msgstr "ЭХЛЭЛ ДЭЛГЭЦИЙН ХЭВ МАЯГ"
+
+msgid "IDS_HS_ACHEADER2_HOME_SCREEN"
+msgstr "ЭХЛЭЛ ДЭЛГЭЦ"
+
+msgid "IDS_COM_HEADER_SELECT_WALLPAPER"
+msgstr "Select wallpaper"
+
+msgid "IDS_ST_BODY_SLIDE"
+msgstr "Слайд хийх"
+
+msgid "IDS_ST_BUTTON2_DEFAULT_WALLPAPERS_ABB"
+msgstr "Өгөгдмөл ханын цаас"
+
+msgid "IDS_HS_BUTTON_DISABLE_ABB"
+msgstr "Идэвхгүй болг"
+
+msgid "IDS_STRAVEL_OPT_TRAVEL_WALLPAPER_ABB"
+msgstr "Аяллын ханын цаас"
+
+msgid "IDS_HS_POP_DISABLE_EASY_MODE_Q"
+msgstr "Хялбар горим идэвхгүй болгох уу?"
+
+msgid "IDS_ST_HEADER_CHANGE_FONT_SIZE_ABB"
+msgstr "Үсгийн хэмжээг өөрчлөх"
+
+msgid "IDS_HELP_BODY_CUBE"
+msgstr "Шоо"
+
diff --git a/po/nb.po b/po/nb.po
new file mode 100755 (executable)
index 0000000..eda1f7f
--- /dev/null
+++ b/po/nb.po
@@ -0,0 +1,30 @@
+msgid "IDS_EMAIL_BUTTON2_CALENDAR"
+msgstr "Kalender"
+
+msgid "IDS_COM_TAB4_IMAGES_ABB2"
+msgstr "Bilder"
+
+msgid "IDS_COM_TAB4_CAMERA"
+msgstr "Kamera"
+
+msgid "IDS_COM_TAB4_VOICE"
+msgstr "Tale"
+
+msgid "IDS_COM_TAB4_MORE_ABB"
+msgstr "Mer"
+
+msgid "IDS_COM_BUTTON2_VIDEOS"
+msgstr "Videoer"
+
+msgid "IDS_COM_BUTTON2_AUDIO_FILES"
+msgstr "Lydfiler"
+
+msgid "IDS_COM_BUTTON2_CONTACTS"
+msgstr "Kontakter"
+
+msgid "IDS_COM_BUTTON_MY_FILES_ABB"
+msgstr "Mine filer"
+
+msgid "IDS_IDLE_BUTTON2_RECORD_NVIDEO_ABB"
+msgstr "Ta opp\nvideo"
+
diff --git a/po/nl.po b/po/nl.po
new file mode 100755 (executable)
index 0000000..90b30c5
--- /dev/null
+++ b/po/nl.po
@@ -0,0 +1,30 @@
+msgid "IDS_EMAIL_BUTTON2_CALENDAR"
+msgstr "Agenda"
+
+msgid "IDS_COM_TAB4_IMAGES_ABB2"
+msgstr "Afbld."
+
+msgid "IDS_COM_TAB4_CAMERA"
+msgstr "Camera"
+
+msgid "IDS_COM_TAB4_VOICE"
+msgstr "Spraak"
+
+msgid "IDS_COM_TAB4_MORE_ABB"
+msgstr "Meer"
+
+msgid "IDS_COM_BUTTON2_VIDEOS"
+msgstr "Video's"
+
+msgid "IDS_COM_BUTTON2_AUDIO_FILES"
+msgstr "Audio-\nbestanden"
+
+msgid "IDS_COM_BUTTON2_CONTACTS"
+msgstr "Contacten"
+
+msgid "IDS_COM_BUTTON_MY_FILES_ABB"
+msgstr "Mijn bestanden"
+
+msgid "IDS_IDLE_BUTTON2_RECORD_NVIDEO_ABB"
+msgstr "Video\nopnemen"
+
diff --git a/po/nl_NL.po b/po/nl_NL.po
new file mode 100755 (executable)
index 0000000..6139c46
--- /dev/null
@@ -0,0 +1,90 @@
+msgid "IDS_ST_MBODY_HOME_SCREEN_WALLPAPER"
+msgstr "Achtergrond startscherm"
+
+msgid "IDS_ST_BODY_GALLERY"
+msgstr "Galerij"
+
+msgid "IDS_COM_HEADER_NOTIFICATION"
+msgstr "Melding"
+
+msgid "IDS_ST_HEADER_HOME_SCREEN_ABB"
+msgstr "Startscherm"
+
+msgid "IDS_ST_BODY_WALLPAPER"
+msgstr "Achtergrond"
+
+msgid "IDS_ST_BODY_HOME_SCREEN_SETTINGS"
+msgstr "Instellingen startscherm"
+
+msgid "IDS_ST_BODY_HOME_SCREEN_TYPE"
+msgstr "Type startscherm"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "Annuleer"
+
+msgid "IDS_ST_HEADER_HOME_SCREEN"
+msgstr "Startscherm"
+
+msgid "IDS_ST_BODY_DEFAULT_HOME_SCREEN"
+msgstr "Standaard startscherm"
+
+msgid "IDS_ST_BUTTON2_SET_AS_HOME"
+msgstr "Startpagina"
+
+msgid "IDS_ST_BODY_SELECT_APPLICATION"
+msgstr "Applicatie selecteren"
+
+msgid "IDS_ST_BODY_EASY_MODE"
+msgstr "Eenvoudige stand"
+
+msgid "IDS_ST_BODY_THE_OVERALL_LAYOUT_OF_THE_HOME_SCREEN_WILL_BE_SIMPLIFIED"
+msgstr "De algemene indeling van het startscherm wordt vereenvoudigd."
+
+msgid "IDS_ST_BODY_HOME_SCREEN_STYLE"
+msgstr "Stijl startscherm"
+
+msgid "IDS_LCKSCN_BODY_WALLPAPERS"
+msgstr "Achtergronden"
+
+msgid "IDS_SCR_POP_SCREEN_READER_IS_NOT_SUPPORTED_BY_PS_PRESS_THE_BACK_KEY_TO_RETURN_TO_THE_PREVIOUS_SCREEN"
+msgstr "Schermlezer wordt niet ondersteund door %s. Druk op de toets Terug om terug te gaan naar het vorige scherm."
+
+msgid "IDS_HELP_BODY_SELECT_AN_OPTION"
+msgstr "Selecteer een optie."
+
+msgid "IDS_COM_BODY_MENU_ABB"
+msgstr "Menu"
+
+msgid "IDS_HS_OPT_SPIRAL"
+msgstr "Spiraal"
+
+msgid "IDS_HS_OPT_INNER_CUBE"
+msgstr "Binnenste kubus"
+
+msgid "IDS_HS_OPT_OUTER_CUBE"
+msgstr "Buitenste kubus"
+
+msgid "IDS_HS_OPT_CAROUSEL"
+msgstr "Carrousel"
+
+msgid "IDS_HS_HEADER_PAGE_NAVIGATION_EFFECT"
+msgstr "Effect paginanavigatie"
+
+msgid "IDS_ST_HEADER_SELECT_WALLPAPER_FROM_ABB"
+msgstr "Achtergrond selecteren uit"
+
+msgid "IDS_HS_POP_EASY_MODE_CAN_BE_DISABLED_IN_SETTINGS"
+msgstr "Eenvoudige stand kan worden uitgeschakeld in Instellingen"
+
+msgid "IDS_ST_BODY_3D_ROTATION_M_EFFECT"
+msgstr "3D rotatie"
+
+msgid "IDS_ST_BODY_LOADING_ING"
+msgstr "Laden..."
+
+msgid "IDS_ST_POP_THE_FONT_SIZE_CAN_BE_INCREASED_TO_MAKE_TEXT_EASIER_TO_READ_CHANGE_THE_FONT_SIZE_NOW_Q"
+msgstr "Het lettertype kan worden vergroot om de tekst leesbaarder te maken. Tekstgrootte nu wijzigen?"
+
+msgid "IDS_ST_SK_CHANGE"
+msgstr "Wijzigen"
+
diff --git a/po/pl.po b/po/pl.po
new file mode 100755 (executable)
index 0000000..b6c9a2e
--- /dev/null
+++ b/po/pl.po
@@ -0,0 +1,30 @@
+msgid "IDS_EMAIL_BUTTON2_CALENDAR"
+msgstr "Kalendarz"
+
+msgid "IDS_COM_TAB4_IMAGES_ABB2"
+msgstr "Obrazy"
+
+msgid "IDS_COM_TAB4_CAMERA"
+msgstr "Aparat"
+
+msgid "IDS_COM_TAB4_VOICE"
+msgstr "Głos"
+
+msgid "IDS_COM_TAB4_MORE_ABB"
+msgstr "Więcej"
+
+msgid "IDS_COM_BUTTON2_VIDEOS"
+msgstr "Filmy"
+
+msgid "IDS_COM_BUTTON2_AUDIO_FILES"
+msgstr "Pliki audio"
+
+msgid "IDS_COM_BUTTON2_CONTACTS"
+msgstr "Kontakty"
+
+msgid "IDS_COM_BUTTON_MY_FILES_ABB"
+msgstr "Moje pliki"
+
+msgid "IDS_IDLE_BUTTON2_RECORD_NVIDEO_ABB"
+msgstr "Nagraj\nwideo"
+
diff --git a/po/pt_BR.po b/po/pt_BR.po
new file mode 100755 (executable)
index 0000000..bee0a39
--- /dev/null
@@ -0,0 +1,30 @@
+msgid "IDS_EMAIL_BUTTON2_CALENDAR"
+msgstr "Calendário"
+
+msgid "IDS_COM_TAB4_IMAGES_ABB2"
+msgstr "Imag."
+
+msgid "IDS_COM_TAB4_CAMERA"
+msgstr "Câmera"
+
+msgid "IDS_COM_TAB4_VOICE"
+msgstr "Voz"
+
+msgid "IDS_COM_TAB4_MORE_ABB"
+msgstr "Mais"
+
+msgid "IDS_COM_BUTTON2_VIDEOS"
+msgstr "Vídeos"
+
+msgid "IDS_COM_BUTTON2_AUDIO_FILES"
+msgstr "Arquivos de áudio"
+
+msgid "IDS_COM_BUTTON2_CONTACTS"
+msgstr "Contatos"
+
+msgid "IDS_COM_BUTTON_MY_FILES_ABB"
+msgstr "Meus Arquivos"
+
+msgid "IDS_IDLE_BUTTON2_RECORD_NVIDEO_ABB"
+msgstr "Gravar\nvídeo"
+
diff --git a/po/pt_PT.po b/po/pt_PT.po
new file mode 100755 (executable)
index 0000000..a9cadb9
--- /dev/null
@@ -0,0 +1,30 @@
+msgid "IDS_EMAIL_BUTTON2_CALENDAR"
+msgstr "Agenda"
+
+msgid "IDS_COM_TAB4_IMAGES_ABB2"
+msgstr "Imagens"
+
+msgid "IDS_COM_TAB4_CAMERA"
+msgstr "Câmara"
+
+msgid "IDS_COM_TAB4_VOICE"
+msgstr "Voz"
+
+msgid "IDS_COM_TAB4_MORE_ABB"
+msgstr "Mais"
+
+msgid "IDS_COM_BUTTON2_VIDEOS"
+msgstr "Vídeos"
+
+msgid "IDS_COM_BUTTON2_AUDIO_FILES"
+msgstr "Ficheiros áudio"
+
+msgid "IDS_COM_BUTTON2_CONTACTS"
+msgstr "Contactos"
+
+msgid "IDS_COM_BUTTON_MY_FILES_ABB"
+msgstr "Meus Ficheiros"
+
+msgid "IDS_IDLE_BUTTON2_RECORD_NVIDEO_ABB"
+msgstr "Gravar\nvídeo"
+
diff --git a/po/ro.po b/po/ro.po
new file mode 100755 (executable)
index 0000000..b658796
--- /dev/null
+++ b/po/ro.po
@@ -0,0 +1,30 @@
+msgid "IDS_EMAIL_BUTTON2_CALENDAR"
+msgstr "Calendar"
+
+msgid "IDS_COM_TAB4_IMAGES_ABB2"
+msgstr "Imag."
+
+msgid "IDS_COM_TAB4_CAMERA"
+msgstr "Cameră"
+
+msgid "IDS_COM_TAB4_VOICE"
+msgstr "Voce"
+
+msgid "IDS_COM_TAB4_MORE_ABB"
+msgstr "M. multe"
+
+msgid "IDS_COM_BUTTON2_VIDEOS"
+msgstr "Videoclipuri"
+
+msgid "IDS_COM_BUTTON2_AUDIO_FILES"
+msgstr "Fişiere audio"
+
+msgid "IDS_COM_BUTTON2_CONTACTS"
+msgstr "Contacte"
+
+msgid "IDS_COM_BUTTON_MY_FILES_ABB"
+msgstr "Fiş. mele"
+
+msgid "IDS_IDLE_BUTTON2_RECORD_NVIDEO_ABB"
+msgstr "Înreg.\nvideo"
+
diff --git a/po/ru_RU.po b/po/ru_RU.po
new file mode 100755 (executable)
index 0000000..0caeb18
--- /dev/null
@@ -0,0 +1,30 @@
+msgid "IDS_EMAIL_BUTTON2_CALENDAR"
+msgstr "Календарь"
+
+msgid "IDS_COM_TAB4_IMAGES_ABB2"
+msgstr "Изобр."
+
+msgid "IDS_COM_TAB4_CAMERA"
+msgstr "Камера"
+
+msgid "IDS_COM_TAB4_VOICE"
+msgstr "Голос"
+
+msgid "IDS_COM_TAB4_MORE_ABB"
+msgstr "Еще"
+
+msgid "IDS_COM_BUTTON2_VIDEOS"
+msgstr "Видео"
+
+msgid "IDS_COM_BUTTON2_AUDIO_FILES"
+msgstr "Аудиофайлы"
+
+msgid "IDS_COM_BUTTON2_CONTACTS"
+msgstr "Контакты"
+
+msgid "IDS_COM_BUTTON_MY_FILES_ABB"
+msgstr "Мои файлы"
+
+msgid "IDS_IDLE_BUTTON2_RECORD_NVIDEO_ABB"
+msgstr "Запись\nвидео"
+
diff --git a/po/si.po b/po/si.po
new file mode 100755 (executable)
index 0000000..eaed724
--- /dev/null
+++ b/po/si.po
@@ -0,0 +1,30 @@
+msgid "IDS_EMAIL_BUTTON2_CALENDAR"
+msgstr "දින දසුන"
+
+msgid "IDS_COM_TAB4_IMAGES_ABB2"
+msgstr "අනුරූ"
+
+msgid "IDS_COM_TAB4_CAMERA"
+msgstr "කැමරාව"
+
+msgid "IDS_COM_TAB4_VOICE"
+msgstr "හඬ"
+
+msgid "IDS_COM_TAB4_MORE_ABB"
+msgstr "වැඩිදුර"
+
+msgid "IDS_COM_BUTTON2_VIDEOS"
+msgstr "වීඩියෝ"
+
+msgid "IDS_COM_BUTTON2_AUDIO_FILES"
+msgstr "ශ්‍රව්‍ය ගොනු"
+
+msgid "IDS_COM_BUTTON2_CONTACTS"
+msgstr "සබඳතා"
+
+msgid "IDS_COM_BUTTON_MY_FILES_ABB"
+msgstr "මගේ ගොනු"
+
+msgid "IDS_IDLE_BUTTON2_RECORD_NVIDEO_ABB"
+msgstr "වීඩියෝ\nපටිගත ක."
+
diff --git a/po/sk.po b/po/sk.po
new file mode 100755 (executable)
index 0000000..6e6020c
--- /dev/null
+++ b/po/sk.po
@@ -0,0 +1,30 @@
+msgid "IDS_EMAIL_BUTTON2_CALENDAR"
+msgstr "Kalendár"
+
+msgid "IDS_COM_TAB4_IMAGES_ABB2"
+msgstr "Fotogr."
+
+msgid "IDS_COM_TAB4_CAMERA"
+msgstr "Fotoap."
+
+msgid "IDS_COM_TAB4_VOICE"
+msgstr "Hlas"
+
+msgid "IDS_COM_TAB4_MORE_ABB"
+msgstr "Ďalšie"
+
+msgid "IDS_COM_BUTTON2_VIDEOS"
+msgstr "Videá"
+
+msgid "IDS_COM_BUTTON2_AUDIO_FILES"
+msgstr "Zvukové súbory"
+
+msgid "IDS_COM_BUTTON2_CONTACTS"
+msgstr "Kontakty"
+
+msgid "IDS_COM_BUTTON_MY_FILES_ABB"
+msgstr "Moje súbory"
+
+msgid "IDS_IDLE_BUTTON2_RECORD_NVIDEO_ABB"
+msgstr "Nahrať\nvideo"
+
diff --git a/po/sl.po b/po/sl.po
new file mode 100755 (executable)
index 0000000..15498cc
--- /dev/null
+++ b/po/sl.po
@@ -0,0 +1,30 @@
+msgid "IDS_EMAIL_BUTTON2_CALENDAR"
+msgstr "Koledar"
+
+msgid "IDS_COM_TAB4_IMAGES_ABB2"
+msgstr "Slike"
+
+msgid "IDS_COM_TAB4_CAMERA"
+msgstr "Fot."
+
+msgid "IDS_COM_TAB4_VOICE"
+msgstr "Glas"
+
+msgid "IDS_COM_TAB4_MORE_ABB"
+msgstr "Več"
+
+msgid "IDS_COM_BUTTON2_VIDEOS"
+msgstr "Videi"
+
+msgid "IDS_COM_BUTTON2_AUDIO_FILES"
+msgstr "Zvočne datoteke"
+
+msgid "IDS_COM_BUTTON2_CONTACTS"
+msgstr "Stiki"
+
+msgid "IDS_COM_BUTTON_MY_FILES_ABB"
+msgstr "Moje datoteke"
+
+msgid "IDS_IDLE_BUTTON2_RECORD_NVIDEO_ABB"
+msgstr "Snemaj\nvideo"
+
diff --git a/po/sr.po b/po/sr.po
new file mode 100755 (executable)
index 0000000..300122e
--- /dev/null
+++ b/po/sr.po
@@ -0,0 +1,30 @@
+msgid "IDS_EMAIL_BUTTON2_CALENDAR"
+msgstr "Kalendar"
+
+msgid "IDS_COM_TAB4_IMAGES_ABB2"
+msgstr "Slike"
+
+msgid "IDS_COM_TAB4_CAMERA"
+msgstr "Kamera"
+
+msgid "IDS_COM_TAB4_VOICE"
+msgstr "Govor"
+
+msgid "IDS_COM_TAB4_MORE_ABB"
+msgstr "Još"
+
+msgid "IDS_COM_BUTTON2_VIDEOS"
+msgstr "Video zapisi"
+
+msgid "IDS_COM_BUTTON2_AUDIO_FILES"
+msgstr "Audio fajlovi"
+
+msgid "IDS_COM_BUTTON2_CONTACTS"
+msgstr "Kontakti"
+
+msgid "IDS_COM_BUTTON_MY_FILES_ABB"
+msgstr "Moji fajlovi"
+
+msgid "IDS_IDLE_BUTTON2_RECORD_NVIDEO_ABB"
+msgstr "Snimi\nvideo"
+
diff --git a/po/sv.po b/po/sv.po
new file mode 100755 (executable)
index 0000000..d05cb8a
--- /dev/null
+++ b/po/sv.po
@@ -0,0 +1,30 @@
+msgid "IDS_EMAIL_BUTTON2_CALENDAR"
+msgstr "Kalender"
+
+msgid "IDS_COM_TAB4_IMAGES_ABB2"
+msgstr "Bilder"
+
+msgid "IDS_COM_TAB4_CAMERA"
+msgstr "Kamera"
+
+msgid "IDS_COM_TAB4_VOICE"
+msgstr "Röst"
+
+msgid "IDS_COM_TAB4_MORE_ABB"
+msgstr "Mer"
+
+msgid "IDS_COM_BUTTON2_VIDEOS"
+msgstr "Videor"
+
+msgid "IDS_COM_BUTTON2_AUDIO_FILES"
+msgstr "Ljudfiler"
+
+msgid "IDS_COM_BUTTON2_CONTACTS"
+msgstr "Kontakter"
+
+msgid "IDS_COM_BUTTON_MY_FILES_ABB"
+msgstr "Mina filer"
+
+msgid "IDS_IDLE_BUTTON2_RECORD_NVIDEO_ABB"
+msgstr "Spela in\nvideo"
+
diff --git a/po/ta.po b/po/ta.po
new file mode 100755 (executable)
index 0000000..2d09ac8
--- /dev/null
+++ b/po/ta.po
@@ -0,0 +1,30 @@
+msgid "IDS_EMAIL_BUTTON2_CALENDAR"
+msgstr "நாட்காட்டி"
+
+msgid "IDS_COM_TAB4_IMAGES_ABB2"
+msgstr "படிமம்"
+
+msgid "IDS_COM_TAB4_CAMERA"
+msgstr "கேமரா"
+
+msgid "IDS_COM_TAB4_VOICE"
+msgstr "குரல்"
+
+msgid "IDS_COM_TAB4_MORE_ABB"
+msgstr "மேலும்"
+
+msgid "IDS_COM_BUTTON2_VIDEOS"
+msgstr "நிகழ்படங்கள்"
+
+msgid "IDS_COM_BUTTON2_AUDIO_FILES"
+msgstr "கேட்பொலி கோப்புகள்"
+
+msgid "IDS_COM_BUTTON2_CONTACTS"
+msgstr "தொடர்புகள்"
+
+msgid "IDS_COM_BUTTON_MY_FILES_ABB"
+msgstr "எ. கோப்புகள்"
+
+msgid "IDS_IDLE_BUTTON2_RECORD_NVIDEO_ABB"
+msgstr "நிகழ்படத்தை\nபதிவுசெய்."
+
diff --git a/po/te.po b/po/te.po
new file mode 100755 (executable)
index 0000000..15b9091
--- /dev/null
+++ b/po/te.po
@@ -0,0 +1,30 @@
+msgid "IDS_EMAIL_BUTTON2_CALENDAR"
+msgstr "క్యాలెండర్"
+
+msgid "IDS_COM_TAB4_IMAGES_ABB2"
+msgstr "చిత్రాలు"
+
+msgid "IDS_COM_TAB4_CAMERA"
+msgstr "కెమెరా"
+
+msgid "IDS_COM_TAB4_VOICE"
+msgstr "వాయిస్"
+
+msgid "IDS_COM_TAB4_MORE_ABB"
+msgstr "మరింత"
+
+msgid "IDS_COM_BUTTON2_VIDEOS"
+msgstr "వీడియోలు"
+
+msgid "IDS_COM_BUTTON2_AUDIO_FILES"
+msgstr "ఆడియో ఫైల్‌లు"
+
+msgid "IDS_COM_BUTTON2_CONTACTS"
+msgstr "పరిచయాలు"
+
+msgid "IDS_COM_BUTTON_MY_FILES_ABB"
+msgstr "నా ఫైల్‌లు"
+
+msgid "IDS_IDLE_BUTTON2_RECORD_NVIDEO_ABB"
+msgstr "వీడియో\nరికార్డ్ చేయి"
+
diff --git a/po/th.po b/po/th.po
new file mode 100755 (executable)
index 0000000..e73a69c
--- /dev/null
+++ b/po/th.po
@@ -0,0 +1,30 @@
+msgid "IDS_EMAIL_BUTTON2_CALENDAR"
+msgstr "ปฏิทิน"
+
+msgid "IDS_COM_TAB4_IMAGES_ABB2"
+msgstr "รูปภาพ"
+
+msgid "IDS_COM_TAB4_CAMERA"
+msgstr "กล้องถ่ายรูป"
+
+msgid "IDS_COM_TAB4_VOICE"
+msgstr "เสียง"
+
+msgid "IDS_COM_TAB4_MORE_ABB"
+msgstr "เพิ่ม"
+
+msgid "IDS_COM_BUTTON2_VIDEOS"
+msgstr "วิดี​โอ"
+
+msgid "IDS_COM_BUTTON2_AUDIO_FILES"
+msgstr "ไฟล์เสียง"
+
+msgid "IDS_COM_BUTTON2_CONTACTS"
+msgstr "รายชื่อ"
+
+msgid "IDS_COM_BUTTON_MY_FILES_ABB"
+msgstr "ไฟล์ส่วนตัว"
+
+msgid "IDS_IDLE_BUTTON2_RECORD_NVIDEO_ABB"
+msgstr "บันทึก\nวิดีโอ"
+
diff --git a/po/tr_TR.po b/po/tr_TR.po
new file mode 100755 (executable)
index 0000000..7b18ed2
--- /dev/null
@@ -0,0 +1,30 @@
+msgid "IDS_EMAIL_BUTTON2_CALENDAR"
+msgstr "Takvim"
+
+msgid "IDS_COM_TAB4_IMAGES_ABB2"
+msgstr "Resmlr"
+
+msgid "IDS_COM_TAB4_CAMERA"
+msgstr "Kamera"
+
+msgid "IDS_COM_TAB4_VOICE"
+msgstr "Ses"
+
+msgid "IDS_COM_TAB4_MORE_ABB"
+msgstr "Dha çk"
+
+msgid "IDS_COM_BUTTON2_VIDEOS"
+msgstr "Videolar"
+
+msgid "IDS_COM_BUTTON2_AUDIO_FILES"
+msgstr "Ses dosyaları"
+
+msgid "IDS_COM_BUTTON2_CONTACTS"
+msgstr "Kişiler"
+
+msgid "IDS_COM_BUTTON_MY_FILES_ABB"
+msgstr "Dosyalarım"
+
+msgid "IDS_IDLE_BUTTON2_RECORD_NVIDEO_ABB"
+msgstr "Video\nkaydı"
+
diff --git a/po/uk.po b/po/uk.po
new file mode 100755 (executable)
index 0000000..2c2cd16
--- /dev/null
+++ b/po/uk.po
@@ -0,0 +1,30 @@
+msgid "IDS_EMAIL_BUTTON2_CALENDAR"
+msgstr "Календар"
+
+msgid "IDS_COM_TAB4_IMAGES_ABB2"
+msgstr "Зобр."
+
+msgid "IDS_COM_TAB4_CAMERA"
+msgstr "Камера"
+
+msgid "IDS_COM_TAB4_VOICE"
+msgstr "Голос"
+
+msgid "IDS_COM_TAB4_MORE_ABB"
+msgstr "Iнше"
+
+msgid "IDS_COM_BUTTON2_VIDEOS"
+msgstr "Відео"
+
+msgid "IDS_COM_BUTTON2_AUDIO_FILES"
+msgstr "Аудіофайли"
+
+msgid "IDS_COM_BUTTON2_CONTACTS"
+msgstr "Контакти"
+
+msgid "IDS_COM_BUTTON_MY_FILES_ABB"
+msgstr "Мої файли"
+
+msgid "IDS_IDLE_BUTTON2_RECORD_NVIDEO_ABB"
+msgstr "Запис\nвідео"
+
diff --git a/po/ur.po b/po/ur.po
new file mode 100755 (executable)
index 0000000..bde4466
--- /dev/null
+++ b/po/ur.po
@@ -0,0 +1,30 @@
+msgid "IDS_EMAIL_BUTTON2_CALENDAR"
+msgstr "کیلنڈر"
+
+msgid "IDS_COM_TAB4_IMAGES_ABB2"
+msgstr "تصاویر"
+
+msgid "IDS_COM_TAB4_CAMERA"
+msgstr "کیمرہ"
+
+msgid "IDS_COM_TAB4_VOICE"
+msgstr "آواز"
+
+msgid "IDS_COM_TAB4_MORE_ABB"
+msgstr "مزید"
+
+msgid "IDS_COM_BUTTON2_VIDEOS"
+msgstr "ویڈیوز"
+
+msgid "IDS_COM_BUTTON2_AUDIO_FILES"
+msgstr "آڈیو فائلیں"
+
+msgid "IDS_COM_BUTTON2_CONTACTS"
+msgstr "رابطے"
+
+msgid "IDS_COM_BUTTON_MY_FILES_ABB"
+msgstr "میری فائلیں"
+
+msgid "IDS_IDLE_BUTTON2_RECORD_NVIDEO_ABB"
+msgstr "ریکارڈ\nویڈیو"
+
diff --git a/po/uz.po b/po/uz.po
new file mode 100755 (executable)
index 0000000..1ad0f5c
--- /dev/null
+++ b/po/uz.po
@@ -0,0 +1,30 @@
+msgid "IDS_EMAIL_BUTTON2_CALENDAR"
+msgstr "Kalendar"
+
+msgid "IDS_COM_TAB4_IMAGES_ABB2"
+msgstr "Tasvir"
+
+msgid "IDS_COM_TAB4_CAMERA"
+msgstr "Kamera"
+
+msgid "IDS_COM_TAB4_VOICE"
+msgstr "Ovoz"
+
+msgid "IDS_COM_TAB4_MORE_ABB"
+msgstr "Yana"
+
+msgid "IDS_COM_BUTTON2_VIDEOS"
+msgstr "Videolar"
+
+msgid "IDS_COM_BUTTON2_AUDIO_FILES"
+msgstr "Audio fayllar"
+
+msgid "IDS_COM_BUTTON2_CONTACTS"
+msgstr "Kontaktlar"
+
+msgid "IDS_COM_BUTTON_MY_FILES_ABB"
+msgstr "Fayllarim"
+
+msgid "IDS_IDLE_BUTTON2_RECORD_NVIDEO_ABB"
+msgstr "Video\nyozish"
+
diff --git a/po/zh_CN.po b/po/zh_CN.po
new file mode 100755 (executable)
index 0000000..898a70d
--- /dev/null
@@ -0,0 +1,30 @@
+msgid "IDS_EMAIL_BUTTON2_CALENDAR"
+msgstr "日历"
+
+msgid "IDS_COM_TAB4_IMAGES_ABB2"
+msgstr "图片"
+
+msgid "IDS_COM_TAB4_CAMERA"
+msgstr "照相机"
+
+msgid "IDS_COM_TAB4_VOICE"
+msgstr "语音"
+
+msgid "IDS_COM_TAB4_MORE_ABB"
+msgstr "更多"
+
+msgid "IDS_COM_BUTTON2_VIDEOS"
+msgstr "视频"
+
+msgid "IDS_COM_BUTTON2_AUDIO_FILES"
+msgstr "音频文件"
+
+msgid "IDS_COM_BUTTON2_CONTACTS"
+msgstr "联系人"
+
+msgid "IDS_COM_BUTTON_MY_FILES_ABB"
+msgstr "我的文件"
+
+msgid "IDS_IDLE_BUTTON2_RECORD_NVIDEO_ABB"
+msgstr "录制\n视频"
+
diff --git a/po/zh_HK.po b/po/zh_HK.po
new file mode 100755 (executable)
index 0000000..9c1816e
--- /dev/null
@@ -0,0 +1,30 @@
+msgid "IDS_EMAIL_BUTTON2_CALENDAR"
+msgstr "日曆"
+
+msgid "IDS_COM_TAB4_IMAGES_ABB2"
+msgstr "圖像"
+
+msgid "IDS_COM_TAB4_CAMERA"
+msgstr "相機"
+
+msgid "IDS_COM_TAB4_VOICE"
+msgstr "語音"
+
+msgid "IDS_COM_TAB4_MORE_ABB"
+msgstr "更多"
+
+msgid "IDS_COM_BUTTON2_VIDEOS"
+msgstr "影片"
+
+msgid "IDS_COM_BUTTON2_AUDIO_FILES"
+msgstr "音訊檔案"
+
+msgid "IDS_COM_BUTTON2_CONTACTS"
+msgstr "聯絡人"
+
+msgid "IDS_COM_BUTTON_MY_FILES_ABB"
+msgstr "我的檔案"
+
+msgid "IDS_IDLE_BUTTON2_RECORD_NVIDEO_ABB"
+msgstr "錄製\n影片"
+
diff --git a/po/zh_SG.po b/po/zh_SG.po
new file mode 100755 (executable)
index 0000000..e8e6b36
--- /dev/null
@@ -0,0 +1,72 @@
+msgid "IDS_ST_MBODY_HOME_SCREEN_WALLPAPER"
+msgstr "主屏墙纸"
+
+msgid "IDS_ST_BODY_GALLERY"
+msgstr "画廊"
+
+msgid "IDS_COM_HEADER_NOTIFICATION"
+msgstr "通知"
+
+msgid "IDS_ST_HEADER_HOME_SCREEN_ABB"
+msgstr "主屏"
+
+msgid "IDS_ST_BODY_WALLPAPER"
+msgstr "墙纸"
+
+msgid "IDS_ST_BODY_HOME_SCREEN_SETTINGS"
+msgstr "主屏设置"
+
+msgid "IDS_ST_BODY_HOME_SCREEN_TYPE"
+msgstr "主屏类型"
+
+msgid "IDS_COM_BUTTON_CANCEL"
+msgstr "取消"
+
+msgid "IDS_ST_HEADER_HOME_SCREEN"
+msgstr "主屏"
+
+msgid "IDS_ST_BODY_DEFAULT_HOME_SCREEN"
+msgstr "默认主屏"
+
+msgid "IDS_ST_BUTTON2_SET_AS_HOME"
+msgstr "设置为首页"
+
+msgid "IDS_ST_BODY_SELECT_APPLICATION"
+msgstr "选择应用程序"
+
+msgid "IDS_ST_BODY_EASY_MODE"
+msgstr "简易模式"
+
+msgid "IDS_ST_BODY_THE_OVERALL_LAYOUT_OF_THE_HOME_SCREEN_WILL_BE_SIMPLIFIED"
+msgstr "主屏的总布局将简化"
+
+msgid "IDS_ST_BODY_HOME_SCREEN_STYLE"
+msgstr "主屏风格"
+
+msgid "IDS_SCR_POP_SCREEN_READER_IS_NOT_SUPPORTED_BY_PS_PRESS_THE_BACK_KEY_TO_RETURN_TO_THE_PREVIOUS_SCREEN"
+msgstr "%s 不支援屏幕阅读器。请按下返回键以回到前一个屏幕"
+
+msgid "IDS_HELP_BODY_SELECT_AN_OPTION"
+msgstr "选择一个选项。"
+
+msgid "IDS_COM_BODY_MENU_ABB"
+msgstr "菜单"
+
+msgid "IDS_HS_OPT_SPIRAL"
+msgstr "螺旋"
+
+msgid "IDS_HS_OPT_INNER_CUBE"
+msgstr "内立方"
+
+msgid "IDS_HS_OPT_OUTER_CUBE"
+msgstr "外立方"
+
+msgid "IDS_HS_OPT_CAROUSEL"
+msgstr "旋转木马轮播"
+
+msgid "IDS_HS_HEADER_PAGE_NAVIGATION_EFFECT"
+msgstr "页面导航效果"
+
+msgid "IDS_ST_HEADER_SELECT_WALLPAPER_FROM_ABB"
+msgstr "选择墙纸来源"
+
diff --git a/po/zh_TW.po b/po/zh_TW.po
new file mode 100755 (executable)
index 0000000..0dddbb5
--- /dev/null
@@ -0,0 +1,30 @@
+msgid "IDS_EMAIL_BUTTON2_CALENDAR"
+msgstr "日曆"
+
+msgid "IDS_COM_TAB4_IMAGES_ABB2"
+msgstr "圖像"
+
+msgid "IDS_COM_TAB4_CAMERA"
+msgstr "相機"
+
+msgid "IDS_COM_TAB4_VOICE"
+msgstr "語音"
+
+msgid "IDS_COM_TAB4_MORE_ABB"
+msgstr "更多"
+
+msgid "IDS_COM_BUTTON2_VIDEOS"
+msgstr "影片"
+
+msgid "IDS_COM_BUTTON2_AUDIO_FILES"
+msgstr "音訊檔案"
+
+msgid "IDS_COM_BUTTON2_CONTACTS"
+msgstr "聯絡人"
+
+msgid "IDS_COM_BUTTON_MY_FILES_ABB"
+msgstr "我的檔案"
+
+msgid "IDS_IDLE_BUTTON2_RECORD_NVIDEO_ABB"
+msgstr "錄影"
+
diff --git a/res/CMakeLists.txt b/res/CMakeLists.txt
new file mode 100644 (file)
index 0000000..3c0315b
--- /dev/null
@@ -0,0 +1,2 @@
+ADD_SUBDIRECTORY(edje)
+ADD_SUBDIRECTORY(images)
diff --git a/res/edje/CMakeLists.txt b/res/edje/CMakeLists.txt
new file mode 100755 (executable)
index 0000000..692667f
--- /dev/null
@@ -0,0 +1,15 @@
+FILE(GLOB edc_files ${CMAKE_CURRENT_SOURCE_DIR}/*.edc)
+FOREACH(edc_file ${edc_files})
+        GET_FILENAME_COMPONENT( FName ${edc_file} NAME_WE )
+        MESSAGE("${FName}")
+        ADD_CUSTOM_COMMAND(OUTPUT ${CMAKE_CURRENT_SOURCE_DIR}/${FName}.edj
+                        COMMAND edje_cc -id ${CMAKE_CURRENT_SOURCE_DIR}/../images
+                        ${CMAKE_CURRENT_SOURCE_DIR}/${FName}.edc ${FName}.edj ${EDJE_CFLAGS}
+                        DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/${FName}.edc
+        )
+        ADD_CUSTOM_TARGET(${FName}.edj DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/${FName}.edj)
+        ADD_DEPENDENCIES(${PROJECT_NAME} ${FName}.edj)
+ENDFOREACH(edc_file)
+
+# install edc files
+INSTALL(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/ DESTINATION ${EDJEDIR} FILES_MATCHING PATTERN "*.edj")
diff --git a/res/edje/conf.h b/res/edje/conf.h
new file mode 120000 (symlink)
index 0000000..de97229
--- /dev/null
@@ -0,0 +1 @@
+../../include/conf.h
\ No newline at end of file
diff --git a/res/edje/layout.edc b/res/edje/layout.edc
new file mode 100644 (file)
index 0000000..805da51
--- /dev/null
@@ -0,0 +1,141 @@
+/*
+ * Copyright (c) 2015 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * 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.
+ */
+
+#include "conf.h"
+
+collections {
+       base_scale: 1.7;
+       group {
+               name: "layout";
+               parts {
+                       part {
+                               name: "bg";
+                               type: RECT;
+                               scale: 1;
+                               mouse_events: 0;
+                               description {
+                                       state: "default" 0.0;
+                                       rel1 { relative: 0.0 0.0; }
+                                       rel2 { relative: 1.0 1.0; }
+                                       color: 150 154 158 255;
+                                       visible: 1;
+                               }
+                       }
+                       part {
+                               name: "toolbar,clip";
+                               type: RECT;
+                               scale: 1;
+                               description {
+                                       state: "default" 0.0;
+                                       rel1 { relative: 0.0 0.0; to: "bg"; }
+                                       rel2 { relative: 1.0 0.0; to: "bg"; }
+                                       min: 0 TOOLBAR_HEIGHT;
+                                       fixed: 0 1;
+                                       align: 0.5 0.0;
+                                       visible: 1;
+                               }
+                               description {
+                                       state: "hide" 0.0;
+                                       inherit: "default" 0.0;
+                                       min: 0 0;
+                               }
+                       }
+                       part {
+                               name: "toolbar";
+                               type: SWALLOW;
+                               clip_to: "toolbar,clip";
+                               scale: 1;
+                               mouse_events: 1;
+                               description {
+                                       state: "default" 0.0;
+                                       rel1 { relative: 0.0 0.0; to: "toolbar,clip"; }
+                                       rel2 { relative: 1.0 1.0; to: "toolbar,clip"; }
+                                       fixed: 0 1;
+                                       align: 0.5 0.5;
+                                       visible: 1;
+                               }
+                       }
+                       part {
+                               name: "scroller";
+                               type: SWALLOW;
+                               scale: 1;
+                               mouse_events: 1;
+                               description {
+                                       state: "default" 0.0;
+                                       rel1 { relative: 0.0 1.0; to: "toolbar,clip"; }
+                                       rel2 { relative: 1.0 1.0; to: "bg"; }
+                                       align: 0.5 1.0;
+                                       fixed: 1 1;
+                                       visible: 1;
+                               }
+                       }
+               }
+               programs {
+                       program {
+                               name: "toolbar,show";
+                               signal: "toolbar,show";
+                               source: "toolbar";
+                               action: STATE_SET "default" 0.0;
+                               target: "toolbar,clip";
+                               transition: LINEAR 0.2;
+                       }
+                       program {
+                               name: "toolbar,hide";
+                               signal: "toolbar,hide";
+                               source: "toolbar";
+                               action: STATE_SET "hide" 0.0;
+                               target: "toolbar,clip";
+                               transition: LINEAR 0.2;
+                       }
+               }
+       } // group
+       group {
+               name: "grid,icon";
+               parts {
+                       part {
+                               name: "bg";
+                               type: RECT;
+                               scale: 1;
+                               mouse_events: 0;
+                               description {
+                                       state: "default" 0.0;
+                                       rel1 { relative: 0.0 0.0; }
+                                       rel2 { relative: 1.0 1.0; }
+                                       color: 255 255 255 0;
+                                       visible: 1;
+                               }
+                       }
+                       part {
+                               name: "icon";
+                               type: SWALLOW;
+                               scale: 1;
+                               mouse_events: 1;
+                               description {
+                                       state: "default" 0.0;
+                                       rel1 { relative: 0.5 0.55; to: "bg"; }
+                                       rel2 { relative: 0.5 0.55; to: "bg"; }
+                                       fixed: 1 1;
+                                       align: 0.5 0.5;
+                                       visible: 1;
+                               }
+                       }
+               }
+       }
+} // collections
+
+
+
+// End of file
diff --git a/res/edje/page.edc b/res/edje/page.edc
new file mode 100644 (file)
index 0000000..c96b315
--- /dev/null
@@ -0,0 +1,53 @@
+/*
+ * Copyright (c) 2015 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * 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.
+ */
+
+collections {
+       base_scale: 1.7;
+       group {
+               name: "page";
+               parts {
+                       part {
+                               name: "bg";
+                               type: SWALLOW;
+                               scale: 1;
+                               mouse_events: 0;
+                               description {
+                                       state: "default" 0.0;
+                                       rel1 { relative: 0.0 0.0; }
+                                       rel2 { relative: 1.0 1.0; }
+                                       visible: 1;
+                               }
+                       }
+                       part {
+                               name: "content";
+                               type: SWALLOW;
+                               scale: 1;
+                               mouse_events: 1;
+                               description {
+                                       state: "default" 0.0;
+                                       rel1 { relative: 0.0 0.0; to, "bg"; }
+                                       rel2 { relative: 1.0 1.0; to, "bg"; }
+                                       fixed: 1 1;
+                                       visible: 1;
+                               }
+                       }
+               }
+       } // group
+} // collections
+
+
+
+// End of file
diff --git a/res/images/A01-1_icon_Menu.png b/res/images/A01-1_icon_Menu.png
new file mode 100755 (executable)
index 0000000..962f4cb
Binary files /dev/null and b/res/images/A01-1_icon_Menu.png differ
diff --git a/res/images/CMakeLists.txt b/res/images/CMakeLists.txt
new file mode 100644 (file)
index 0000000..f2448b9
--- /dev/null
@@ -0,0 +1,6 @@
+INSTALL(FILES ${CMAKE_SOURCE_DIR}/res/images/A01-1_icon_Menu.png DESTINATION ${ICONDIR})
+INSTALL(FILES ${CMAKE_SOURCE_DIR}/res/images/contact.png DESTINATION ${ICONDIR})
+INSTALL(FILES ${CMAKE_SOURCE_DIR}/res/images/calendar.png DESTINATION ${ICONDIR})
+INSTALL(FILES ${CMAKE_SOURCE_DIR}/res/images/music.png DESTINATION ${ICONDIR})
+INSTALL(FILES ${CMAKE_SOURCE_DIR}/res/images/my_files.png DESTINATION ${ICONDIR})
+INSTALL(FILES ${CMAKE_SOURCE_DIR}/res/images/video.png DESTINATION ${ICONDIR})
diff --git a/res/images/calendar.png b/res/images/calendar.png
new file mode 100755 (executable)
index 0000000..0dc61a7
Binary files /dev/null and b/res/images/calendar.png differ
diff --git a/res/images/contact.png b/res/images/contact.png
new file mode 100755 (executable)
index 0000000..c5ca5ae
Binary files /dev/null and b/res/images/contact.png differ
diff --git a/res/images/music.png b/res/images/music.png
new file mode 100755 (executable)
index 0000000..6db6507
Binary files /dev/null and b/res/images/music.png differ
diff --git a/res/images/my_files.png b/res/images/my_files.png
new file mode 100755 (executable)
index 0000000..5761fa3
Binary files /dev/null and b/res/images/my_files.png differ
diff --git a/res/images/video.png b/res/images/video.png
new file mode 100755 (executable)
index 0000000..edec770
Binary files /dev/null and b/res/images/video.png differ
diff --git a/sample/CMakeLists.txt b/sample/CMakeLists.txt
new file mode 100644 (file)
index 0000000..a681b1d
--- /dev/null
@@ -0,0 +1,29 @@
+SET(SAMPLE "sample")
+
+INCLUDE(FindPkgConfig)
+pkg_check_modules(sample_pkgs REQUIRED
+       dlog
+       elementary
+       appcore-efl
+)
+
+FOREACH(sample_flag ${sample_pkgs_CFLAGS})
+       SET(SAMPLE_EXTRA_CFLAGS "${SAMPLE_EXTRA_CFLAGS} ${sample_flag}")
+ENDFOREACH(sample_flag)
+
+SET(SAMPLE_EXTRA_CFLAGS, "${SAMPLE_EXTRA_CFALGS} -DPREFIX=\"${CMAKE_INSTALL_PREFIX}\"")
+
+ADD_EXECUTABLE(${SAMPLE} sample.c)
+
+TARGET_LINK_LIBRARIES(${SAMPLE} ${PROJECT_NAME} ${sample_pkgs_LDFLAGS} ${SAMPLE_EXTRA_LDFLAGS})
+
+# install edj
+ADD_CUSTOM_TARGET(sample.edj
+               COMMAND edje_cc ${CMAKE_CURRENT_SOURCE_DIR}/sample.edc sample.edj
+               DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/sample.edc
+)
+ADD_DEPENDENCIES(${SAMPLE} sample.edj)
+
+INSTALL(TARGETS ${SAMPLE} DESTINATION ${SAMPLEDIR})
+INSTALL(FILES sample.edj DESTINATION ${SAMPLEDIR})
+
diff --git a/sample/sample.c b/sample/sample.c
new file mode 100644 (file)
index 0000000..3837274
--- /dev/null
@@ -0,0 +1,508 @@
+/*
+ * Samsung API
+ * Copyright (c) 2015 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/license/
+ *
+ * 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.
+ */
+
+#include <app.h>
+#include <app_control.h>
+#include <Elementary.h>
+#include <efl_extension.h>
+
+#include "attach_panel.h"
+#include "log.h"
+
+
+
+const char *const KEY_BACK = "XF86Back";
+const char *const LAYOUT = "/usr/share/attach-panel/sample/sample.edj";
+
+
+
+static struct {
+       Evas_Object *win;
+       Evas_Object *layout;
+       Evas_Object *bg;
+       Evas_Object *conformant;
+       attach_panel_h attach_panel;
+
+       int root_w;
+       int root_h;
+} sample_info = {
+       .win = NULL,
+       .layout = NULL,
+       .bg = NULL,
+       .conformant = NULL,
+       .attach_panel = NULL,
+
+       .root_w = 0,
+       .root_h = 0,
+};
+
+
+
+static void _rotate_cb(void *data, Evas_Object *obj, void *event)
+{
+       ret_if(!obj);
+
+       int angle = 0;
+
+       angle = elm_win_rotation_get(obj);
+
+       _D("Angle is %d degree", angle);
+
+       switch (angle) {
+       case 0:
+       case 180:
+               evas_object_size_hint_min_set(obj, sample_info.root_w, sample_info.root_h);
+               evas_object_resize(obj, sample_info.root_w, sample_info.root_h);
+               evas_object_move(obj, 0, 0);
+               break;
+       case 90:
+       case 270:
+               evas_object_size_hint_min_set(obj, sample_info.root_h, sample_info.root_w);
+               evas_object_resize(obj, sample_info.root_h, sample_info.root_w);
+               evas_object_move(obj, 0, 0);
+               break;
+       default:
+               _E("cannot reach here");
+       }
+}
+
+
+
+static void _result_cb(attach_panel_h attach_panel, attach_panel_content_category_e content_category, app_control_h result, app_control_result_e result_code, void *user_data)
+{
+       char **select = NULL;
+       int i = 0;
+       int length = 0;
+       int ret = APP_CONTROL_ERROR_NONE;
+
+       ret_if(!result);
+
+       ret = app_control_get_extra_data_array(result, "http://tizen.org/appcontrol/data/selected", &select, &length);
+       if (APP_CONTROL_ERROR_NONE == ret) {
+               for (i = 0; i < length; i++) {
+                       _D("file_path is %s[%d]", select[i], i);
+                       elm_object_part_text_set(sample_info.layout, "result", select[i]);
+                       free(select[i]);
+               }
+       }
+
+       free(select);
+}
+
+
+
+static void _event_cb(attach_panel_h attach_panel, attach_panel_event_e event, void *event_info, void *data)
+{
+       ret_if(!attach_panel);
+
+       switch (event) {
+       case ATTACH_PANEL_EVENT_SHOW_START:
+               _D("attach panel : show start");
+               break;
+       case ATTACH_PANEL_EVENT_SHOW_FINISH:
+               _D("attach panel : show finish");
+               break;
+       case ATTACH_PANEL_EVENT_HIDE_START:
+               _D("attach panel : hide start");
+               break;
+       case ATTACH_PANEL_EVENT_HIDE_FINISH:
+               _D("attach panel : hide finish");
+               break;
+       }
+}
+
+
+
+static void _win_back_key_cb(void *data, Evas_Object *obj, void *event_info)
+{
+       bool visible = false;
+
+       if (sample_info.attach_panel) {
+               if (attach_panel_get_visibility(sample_info.attach_panel, &visible) != ATTACH_PANEL_ERROR_NONE) {
+                       _E("Fail to get visible of attach panel");
+                       return;
+               }
+               if (visible) {
+                       _D("attach panel state : show->hide");
+                       attach_panel_hide(sample_info.attach_panel);
+               } else {
+                       attach_panel_remove_content_category(sample_info.attach_panel, ATTACH_PANEL_CONTENT_CATEGORY_IMAGE);
+                       attach_panel_remove_content_category(sample_info.attach_panel, ATTACH_PANEL_CONTENT_CATEGORY_CAMERA);
+                       attach_panel_remove_content_category(sample_info.attach_panel, ATTACH_PANEL_CONTENT_CATEGORY_VOICE);
+                       attach_panel_remove_content_category(sample_info.attach_panel, ATTACH_PANEL_CONTENT_CATEGORY_VIDEO);
+                       attach_panel_remove_content_category(sample_info.attach_panel, ATTACH_PANEL_CONTENT_CATEGORY_AUDIO);
+                       attach_panel_remove_content_category(sample_info.attach_panel, ATTACH_PANEL_CONTENT_CATEGORY_CALENDAR);
+                       attach_panel_remove_content_category(sample_info.attach_panel, ATTACH_PANEL_CONTENT_CATEGORY_CONTACT);
+                       attach_panel_remove_content_category(sample_info.attach_panel, ATTACH_PANEL_CONTENT_CATEGORY_MYFILES);
+                       attach_panel_remove_content_category(sample_info.attach_panel, ATTACH_PANEL_CONTENT_CATEGORY_VIDEO_RECORDER);
+
+                       attach_panel_unset_result_cb(sample_info.attach_panel);
+                       attach_panel_unset_event_cb(sample_info.attach_panel);
+
+                       attach_panel_destroy(sample_info.attach_panel);
+                       sample_info.attach_panel = NULL;
+               }
+       } else {
+               ui_app_exit();
+       }
+}
+
+
+
+static void _attach_panel_cancel_cb(void *data, Evas_Object *obj, const char *emission, const char *source)
+{
+       _D("");
+
+       if (sample_info.attach_panel) {
+               attach_panel_remove_content_category(sample_info.attach_panel, ATTACH_PANEL_CONTENT_CATEGORY_IMAGE);
+               attach_panel_remove_content_category(sample_info.attach_panel, ATTACH_PANEL_CONTENT_CATEGORY_CAMERA);
+               attach_panel_remove_content_category(sample_info.attach_panel, ATTACH_PANEL_CONTENT_CATEGORY_VOICE);
+               attach_panel_remove_content_category(sample_info.attach_panel, ATTACH_PANEL_CONTENT_CATEGORY_VIDEO);
+               attach_panel_remove_content_category(sample_info.attach_panel, ATTACH_PANEL_CONTENT_CATEGORY_AUDIO);
+               attach_panel_remove_content_category(sample_info.attach_panel, ATTACH_PANEL_CONTENT_CATEGORY_CALENDAR);
+               attach_panel_remove_content_category(sample_info.attach_panel, ATTACH_PANEL_CONTENT_CATEGORY_CONTACT);
+               attach_panel_remove_content_category(sample_info.attach_panel, ATTACH_PANEL_CONTENT_CATEGORY_MYFILES);
+               attach_panel_remove_content_category(sample_info.attach_panel, ATTACH_PANEL_CONTENT_CATEGORY_VIDEO_RECORDER);
+
+               attach_panel_hide(sample_info.attach_panel);
+               attach_panel_unset_result_cb(sample_info.attach_panel);
+               attach_panel_unset_event_cb(sample_info.attach_panel);
+
+               attach_panel_destroy(sample_info.attach_panel);
+               sample_info.attach_panel = NULL;
+       }
+}
+
+
+
+static void _attach_panel_create_cb(void *data, Evas_Object *obj, void *event_info)
+{
+       attach_panel_h attach_panel = NULL;
+       int ret = ATTACH_PANEL_ERROR_NONE;
+       bool visible = false;
+
+       if (sample_info.attach_panel) {
+               _D("attach panel already existed");
+               if (attach_panel_get_visibility(sample_info.attach_panel, &visible) != ATTACH_PANEL_ERROR_NONE) {
+                       _E("Fail to get visible of attach panel");
+                       return;
+               }
+               if (!visible) {
+                       _D("attach panel state : hide->show");
+                       attach_panel_show(sample_info.attach_panel);
+               }
+               return;
+       }
+
+       ret = attach_panel_create(sample_info.conformant, &attach_panel);
+       ret_if(ATTACH_PANEL_ERROR_NONE != ret);
+
+       attach_panel_add_content_category(attach_panel, ATTACH_PANEL_CONTENT_CATEGORY_IMAGE, NULL);
+       attach_panel_add_content_category(attach_panel, ATTACH_PANEL_CONTENT_CATEGORY_CAMERA, NULL);
+       attach_panel_add_content_category(attach_panel, ATTACH_PANEL_CONTENT_CATEGORY_VOICE, NULL);
+       attach_panel_add_content_category(attach_panel, ATTACH_PANEL_CONTENT_CATEGORY_VIDEO, NULL);
+       attach_panel_add_content_category(attach_panel, ATTACH_PANEL_CONTENT_CATEGORY_AUDIO, NULL);
+       attach_panel_add_content_category(attach_panel, ATTACH_PANEL_CONTENT_CATEGORY_CALENDAR, NULL);
+       attach_panel_add_content_category(attach_panel, ATTACH_PANEL_CONTENT_CATEGORY_CONTACT, NULL);
+       attach_panel_add_content_category(attach_panel, ATTACH_PANEL_CONTENT_CATEGORY_MYFILES, NULL);
+       attach_panel_add_content_category(attach_panel, ATTACH_PANEL_CONTENT_CATEGORY_VIDEO_RECORDER, NULL);
+       attach_panel_set_result_cb(attach_panel, _result_cb, NULL);
+       attach_panel_set_event_cb(attach_panel, _event_cb, NULL);
+
+       attach_panel_show(attach_panel);
+
+       sample_info.attach_panel = attach_panel;
+}
+
+
+
+static Evas_Object *_create_entry(Evas_Object *layout)
+{
+       Evas_Object *entry = NULL;
+
+       retv_if(!layout, NULL);
+
+       entry = elm_entry_add(layout);
+       retv_if(!entry, NULL);
+
+       elm_entry_scrollable_set(entry, EINA_TRUE);
+       elm_object_part_text_set(entry, "elm.guide", "search");
+
+       elm_object_part_content_set(layout, "entry", entry);
+
+       elm_entry_cnp_mode_set(entry, ELM_CNP_MODE_PLAINTEXT);
+       elm_entry_input_panel_layout_set(entry, ELM_INPUT_PANEL_LAYOUT_NORMAL);
+       elm_entry_prediction_allow_set(entry, EINA_FALSE);
+       elm_entry_autocapital_type_set(entry, ELM_AUTOCAPITAL_TYPE_NONE);
+       elm_entry_input_panel_return_key_type_set(entry, ELM_INPUT_PANEL_RETURN_KEY_TYPE_DONE);
+       elm_entry_input_panel_return_key_disabled_set(entry, EINA_FALSE);
+
+       evas_object_show(entry);
+
+       return entry;
+}
+
+
+
+static void _destroy_entry(Evas_Object *layout)
+{
+       Evas_Object *entry = NULL;
+       _D("");
+
+       entry = elm_object_part_content_unset(layout, "entry");
+       if (!entry) {
+               return;
+       }
+       evas_object_del(entry);
+}
+
+
+
+static Evas_Object *_create_button(Evas_Object *layout)
+{
+       Evas_Object *button = NULL;
+
+       retv_if(!layout, NULL);
+
+       button = elm_button_add(layout);
+       retv_if(!button, NULL);
+
+       elm_object_text_set(button, "attach");
+       elm_object_part_content_set(layout, "button", button);
+       evas_object_size_hint_weight_set(button, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
+       evas_object_show(button);
+
+       evas_object_smart_callback_add(button, "clicked", _attach_panel_create_cb, NULL);
+
+       return button;
+}
+
+
+
+static void _destroy_button(Evas_Object *layout)
+{
+       Evas_Object *button = NULL;
+
+       button = elm_object_part_content_unset(layout, "button");
+       if (!button) {
+               return;
+       }
+
+       evas_object_smart_callback_del(button, "clicked", _attach_panel_create_cb);
+       evas_object_del(button);
+}
+
+
+
+static void _destroy_layout(void)
+{
+       ret_if(!sample_info.layout);
+
+       _destroy_button(sample_info.layout);
+       _destroy_entry(sample_info.layout);
+
+       elm_object_signal_callback_del(sample_info.layout, "bg,up", "bg", _attach_panel_cancel_cb);
+
+       if (sample_info.conformant) {
+               elm_object_content_unset(sample_info.conformant);
+       }
+       evas_object_del(sample_info.layout);
+       sample_info.layout = NULL;
+}
+
+
+
+static Evas_Object *_create_layout(Evas_Object *parent)
+{
+       Evas_Object *layout = NULL;
+       Eina_Bool ret = EINA_FALSE;
+
+       retv_if(!parent, NULL);
+
+       layout = elm_layout_add(parent);
+       goto_if(!layout, ERROR);
+
+       ret = elm_layout_file_set(layout, LAYOUT, "layout");
+       goto_if(EINA_FALSE == ret, ERROR);
+
+       evas_object_size_hint_weight_set(layout, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
+       evas_object_size_hint_align_set(layout, EVAS_HINT_FILL, EVAS_HINT_FILL);
+       evas_object_show(layout);
+       elm_object_signal_callback_add(layout, "bg,up", "bg", _attach_panel_cancel_cb, NULL);
+
+       goto_if(!_create_entry(layout), ERROR);
+       goto_if(!_create_button(layout), ERROR);
+
+       elm_object_content_set(parent, layout);
+
+       return layout;
+
+
+ERROR:
+       _destroy_layout();
+       return NULL;
+}
+
+
+
+static Evas_Object *_create_bg(Evas_Object *parent)
+{
+       Evas_Object *bg = NULL;
+       retv_if(!parent, NULL);
+
+       bg = elm_bg_add(parent);
+       retv_if(!bg, NULL);
+       evas_object_size_hint_weight_set(bg,  EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
+       elm_win_resize_object_add(parent, bg);
+
+       evas_object_show(bg);
+
+       return bg;
+}
+
+
+
+static void _destroy_bg(void)
+{
+       ret_if(!sample_info.bg);
+       evas_object_del(sample_info.bg);
+       sample_info.bg = NULL;
+}
+
+
+
+static void _destroy_conformant(void)
+{
+       ret_if(!sample_info.conformant);
+       evas_object_del(sample_info.conformant);
+       sample_info.conformant = NULL;
+}
+
+
+
+static Evas_Object *_create_conformant(Evas_Object *parent)
+{
+       Evas_Object *conformant = NULL;
+       retv_if(!parent, NULL);
+
+       conformant = elm_conformant_add(parent);
+       retv_if(!conformant, NULL);
+
+       elm_win_indicator_mode_set(parent, ELM_WIN_INDICATOR_SHOW);
+       elm_win_indicator_opacity_set(parent, ELM_WIN_INDICATOR_OPAQUE);
+       evas_object_size_hint_weight_set(conformant,  EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
+       elm_win_resize_object_add(parent, conformant);
+       elm_win_conformant_set(parent, EINA_TRUE);
+
+       evas_object_show(conformant);
+
+       return conformant;
+}
+
+
+
+static void _create_cb(void)
+{
+       Evas_Object *layout = NULL;
+       Evas_Object *conformant = NULL;
+       Evas_Object *bg = NULL;
+
+       sample_info.win = elm_win_add(NULL, "Attach Panel Sample", ELM_WIN_BASIC);
+       ret_if(!sample_info.win);
+
+       elm_app_base_scale_set(1.7);
+
+       elm_win_title_set(sample_info.win, "Attach Panel");
+       elm_win_alpha_set(sample_info.win, EINA_FALSE);
+       elm_win_borderless_set(sample_info.win, EINA_TRUE);
+       elm_win_autodel_set(sample_info.win, EINA_TRUE);
+       elm_win_raise(sample_info.win);
+
+       evas_object_show(sample_info.win);
+
+       elm_win_screen_size_get(sample_info.win, NULL, NULL, &sample_info.root_w, &sample_info.root_h);
+       _D("screen size is (%d, %d)", sample_info.root_w, sample_info.root_h);
+
+
+       if (elm_win_wm_rotation_supported_get(sample_info.win)) {
+               int rots[4] = { 0, 90, 180, 270 };
+               elm_win_wm_rotation_available_rotations_set(sample_info.win, rots, 4);
+       }
+
+       eext_object_event_callback_add(sample_info.win, EEXT_CALLBACK_BACK, _win_back_key_cb, NULL);
+       evas_object_smart_callback_add(sample_info.win, "wm,rotation,changed", _rotate_cb, NULL);
+
+       bg = _create_bg(sample_info.win);
+       goto_if(!bg, ERROR);
+
+       conformant = _create_conformant(sample_info.win);
+       goto_if(!conformant, ERROR);
+
+       layout = _create_layout(conformant);
+       goto_if(!layout, ERROR);
+
+       sample_info.layout = layout;
+       sample_info.conformant = conformant;
+       sample_info.bg = bg;
+
+       return;
+
+ERROR:
+       _D("there is some error");
+       if (conformant) {
+               _destroy_conformant();
+       }
+       if (bg) {
+               _destroy_bg();
+       }
+
+       if (sample_info.win) {
+               evas_object_del(sample_info.win);
+               eext_object_event_callback_del(sample_info.win, EEXT_CALLBACK_BACK, _win_back_key_cb);
+               sample_info.win = NULL;
+       }
+}
+
+
+
+static void _terminate_cb(void)
+{
+       _D("");
+
+       _destroy_layout();
+       _destroy_conformant();
+       _destroy_bg();
+
+       if (sample_info.win) {
+               eext_object_event_callback_del(sample_info.win, EEXT_CALLBACK_BACK, _win_back_key_cb);
+               evas_object_del(sample_info.win);
+               sample_info.win = NULL;
+       }
+}
+
+
+
+int main(int argc, char **argv)
+{
+       elm_init(argc, argv);
+       _create_cb();
+       elm_run();
+       _terminate_cb();
+       elm_shutdown();
+
+       return 0;
+}
diff --git a/sample/sample.edc b/sample/sample.edc
new file mode 100644 (file)
index 0000000..86910f0
--- /dev/null
@@ -0,0 +1,109 @@
+/*
+ * Samsung API
+ * Copyright (c) 2015 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/license/
+ *
+ * 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.
+ */
+
+
+
+styles {
+       style {
+               name: "text_style";
+               base: "font=Tizen:style=Bold font_size=24 color=#ffffff align=center style=shadow shadow_color=#000000bf wrap=mixed";
+               tag:  "br" "\n";
+               tag:  "hilight" "+ font_weight=Bold";
+               tag:  "b" "+ font_weight=Bold";
+               tag:  "tab" "\t";
+       }
+}
+
+collections {
+       group {
+               name: "layout";
+               parts {
+                       part {
+                               name: "bg";
+                               type: RECT;
+                               scale: 1;
+                               description {
+                                       state: "default" 0.0;
+                                       rel1 { relative: 0.0 0.0; }
+                                       rel2 { relative: 1.0 1.0; }
+                                       color: 255 255 255 255;
+                                       visible: 1;
+                               }
+                       }
+                       part {
+                               name: "entry";
+                               type: SWALLOW;
+                               description {
+                                       state: "default" 0.0;
+                                       rel1 { relative: 0.05 0.1; }
+                                       rel2 { relative: 0.6 0.2; }
+                                       align: 0.5 0.5;
+                                       fixed: 1 1;
+                                       visible: 1;
+                               }
+                       }
+                       part {
+                               name: "button_bg";
+                               type: RECT;
+                               description {
+                                       state: "default" 0.0;
+                                       rel1.to: "button";
+                                       rel2.to: "button";
+                                       visible: 1;
+                                       color: 200 200 200 200;
+                               }
+                       }
+                       part {
+                               name: "button";
+                               type: SWALLOW;
+                               description {
+                                       state: "default" 0.0;
+                                       rel1 { relative: 0.65 0.1; }
+                                       rel2 { relative: 0.95 0.2; }
+                                       align: 0.5 1.0;
+                                       fixed: 1 1;
+                                       visible: 1;
+                               }
+                       }
+                       part {
+                               name: "result";
+                               type: TEXTBLOCK;
+                               description {
+                                       state: "default" 0.0;
+                                       rel1 { relative: 0.0 1.0; to: "entry"; }
+                                       rel2 { relative: 0.95 1.0; to: "bg"; }
+                                       align: 0.5 1.0;
+                                       color: 0 0 0 255;
+                                       text {
+                                               text: " ";
+                                               style: "text_style";
+                                               align: 0.5 0.5;
+                                       }
+                                       visible: 1;
+                               }
+                       }
+               } //parts
+               programs {
+                       program {
+                               name: "bg,up";
+                               signal: "mouse,up,1";
+                               source: "bg";
+                               action: SIGNAL_EMIT "bg,up" "bg";
+                       }
+               }
+       } //group
+} //collections
diff --git a/sample/sample.h b/sample/sample.h
new file mode 100644 (file)
index 0000000..5bc7735
--- /dev/null
@@ -0,0 +1,64 @@
+/*
+ * Samsung API
+ * Copyright (c) 2015 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/license/
+ *
+ * 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.
+ */
+
+
+#ifndef __ATTACK_PANEL_SAMPLE_H__
+#define __ATTACK_PANEL_SAMPLE_H__
+
+#include <dlog.h>
+
+
+#define BASE_WIDTH 1280
+#define BASE_HEIGHT 720
+
+
+//log
+#if !defined(_D)
+#define _D(fmt, arg...) LOGD(fmt"\n", ##arg)
+#endif
+
+#if !defined(_W)
+#define _W(fmt, arg...) LOGW(fmt"\n", ##arg)
+#endif
+
+#if !defined(_E)
+#define _E(fmt, arg...) LOGE(fmt"\n", ##arg)
+#endif
+
+#define retv_if(expr, val) do { \
+       if(expr) { \
+               _E("(%s) -> %s() return", #expr, __FUNCTION__); \
+               return (val); \
+       } \
+} while (0)
+
+#define ret_if(expr) do { \
+       if(expr) { \
+               _E("(%s) -> %s() return", #expr, __FUNCTION__); \
+               return; \
+       } \
+} while (0)
+
+#define goto_if(expr, val) do { \
+       if(expr) { \
+               _E("(%s) -> goto", #expr); \
+               goto val; \
+       } \
+} while (0)
+
+
+#endif
diff --git a/src/attach_bundle.c b/src/attach_bundle.c
new file mode 100644 (file)
index 0000000..209a22d
--- /dev/null
@@ -0,0 +1,183 @@
+/*
+ * Copyright (c) 2015 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * 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.
+ */
+
+#include <app_control.h>
+#include <bundle.h>
+#include <Elementary.h>
+#include <ui-gadget.h>
+#include <tizen.h>
+
+#include "attach_panel.h"
+#include "attach_panel_internal.h"
+#include "log.h"
+
+
+
+static void __foreach_bundle_to_add_cb(const char *key, const int type, bundle_keyval_t *kv, void *data)
+{
+       app_control_h app_control = data;
+       char *basic_val = NULL;
+       void **arr = NULL;
+
+       size_t size = 0;
+       size_t *array_element_size = NULL;
+       unsigned int array_length = 0;
+       int ret = BUNDLE_ERROR_NONE;
+
+       ret_if(!key);
+       ret_if(!app_control);
+
+       _D("key: %s", key);
+
+       switch(type) {
+       case BUNDLE_TYPE_STR:
+               ret = bundle_keyval_get_basic_val(kv, (void *) &basic_val, &size);
+               ret_if(ret != BUNDLE_ERROR_NONE);
+               ret_if(!basic_val);
+
+               ret = app_control_add_extra_data(app_control, key, basic_val);
+               ret_if(ret != APP_CONTROL_ERROR_NONE);
+               break;
+
+       case BUNDLE_TYPE_STR_ARRAY:
+               ret = bundle_keyval_get_array_val(kv, &arr, &array_length, &array_element_size);
+               ret_if(ret != BUNDLE_ERROR_NONE);
+               ret_if(!arr);
+
+               ret = app_control_add_extra_data_array(app_control, key, (const char **) arr, array_length);
+               ret_if(ret != APP_CONTROL_ERROR_NONE);
+               break;
+
+       case BUNDLE_TYPE_BYTE:
+               ret = bundle_keyval_get_basic_val(kv, (void *) &basic_val, &size);
+               ret_if(ret != BUNDLE_ERROR_NONE);
+               ret_if(!basic_val);
+
+               ret = app_control_add_extra_data(app_control, key, basic_val);
+               ret_if(ret != APP_CONTROL_ERROR_NONE);
+               break;
+
+       case BUNDLE_TYPE_BYTE_ARRAY:
+               ret = bundle_keyval_get_array_val(kv, &arr, &array_length, &array_element_size);
+               ret_if(ret != BUNDLE_ERROR_NONE);
+               ret_if(!arr);
+
+               ret = app_control_add_extra_data_array(app_control, key, (const char **) arr, array_length);
+               ret_if(ret != APP_CONTROL_ERROR_NONE);
+               break;
+
+       default:
+               _E("There is wrong type");
+               break;
+       }
+}
+
+
+
+int _bundle_add_to_app_control(bundle *b, app_control_h app_control)
+{
+       retv_if(!b, ATTACH_PANEL_ERROR_INVALID_PARAMETER);
+       retv_if(!app_control, ATTACH_PANEL_ERROR_INVALID_PARAMETER);
+
+       bundle_foreach(b, (void *) __foreach_bundle_to_add_cb, app_control);
+       retv_if(get_last_result() != BUNDLE_ERROR_NONE, ATTACH_PANEL_ERROR_OUT_OF_MEMORY);
+
+       return ATTACH_PANEL_ERROR_NONE;
+}
+
+
+
+static void __foreach_bundle_to_change_cb(const char *key, const int type, bundle_keyval_t *kv, void *data)
+{
+       bundle *origin = data;
+       char *basic_val = NULL;
+       void **arr = NULL;
+
+       size_t size;
+       size_t *array_element_size = NULL;
+       unsigned int array_length = 0;
+       int ret = BUNDLE_ERROR_NONE;
+
+       ret_if(!key);
+       ret_if(!origin);
+
+       switch(type) {
+       case BUNDLE_TYPE_STR:
+               ret = bundle_keyval_get_basic_val(kv, (void *) &basic_val, &size);
+               ret_if(ret != BUNDLE_ERROR_NONE);
+               ret_if(!basic_val);
+
+               ret = bundle_del(origin, key);
+               ret_if(ret != BUNDLE_ERROR_NONE && ret != BUNDLE_ERROR_KEY_NOT_AVAILABLE);
+
+               ret = bundle_add_str(origin, key, basic_val);
+               ret_if(ret != BUNDLE_ERROR_NONE);
+               break;
+
+       case BUNDLE_TYPE_STR_ARRAY:
+               ret = bundle_keyval_get_array_val(kv, &arr, &array_length, &array_element_size);
+               ret_if(ret != BUNDLE_ERROR_NONE);
+               ret_if(!arr);
+
+               ret = bundle_del(origin, key);
+               ret_if(ret != BUNDLE_ERROR_NONE && ret != BUNDLE_ERROR_KEY_NOT_AVAILABLE);
+
+               ret = bundle_add_str_array(origin, key, (const char **) arr, array_length);
+               ret_if(ret != BUNDLE_ERROR_NONE);
+               break;
+
+       case BUNDLE_TYPE_BYTE:
+               ret = bundle_keyval_get_basic_val(kv, (void *) &basic_val, &size);
+               ret_if(ret != BUNDLE_ERROR_NONE);
+               ret_if(!basic_val);
+
+               ret = bundle_del(origin, key);
+               ret_if(ret != BUNDLE_ERROR_NONE && ret != BUNDLE_ERROR_KEY_NOT_AVAILABLE);
+
+               ret = bundle_add_byte(origin, key, basic_val, size);
+               ret_if(ret != BUNDLE_ERROR_NONE);
+               break;
+
+       case BUNDLE_TYPE_BYTE_ARRAY:
+               ret = bundle_keyval_get_array_val(kv, &arr, &array_length, &array_element_size);
+               ret_if(ret != BUNDLE_ERROR_NONE);
+               ret_if(!arr);
+
+               ret = bundle_del(origin, key);
+               ret_if(ret != BUNDLE_ERROR_NONE && ret != BUNDLE_ERROR_KEY_NOT_AVAILABLE);
+
+               ret = bundle_add_str_array(origin, key, (const char **) arr, array_length);
+               ret_if(ret != BUNDLE_ERROR_NONE);
+               break;
+
+       default:
+               _E("There is wrong type");
+               break;
+       }
+}
+
+
+
+int _bundle_add_to_bundle(bundle *origin, bundle *replace)
+{
+       retv_if(!origin, ATTACH_PANEL_ERROR_INVALID_PARAMETER);
+       retv_if(!replace, ATTACH_PANEL_ERROR_INVALID_PARAMETER);
+
+       bundle_foreach(replace, (void *) __foreach_bundle_to_change_cb, origin);
+       retv_if(get_last_result() != BUNDLE_ERROR_NONE, ATTACH_PANEL_ERROR_OUT_OF_MEMORY);
+
+       return ATTACH_PANEL_ERROR_NONE;
+}
diff --git a/src/attach_panel.c b/src/attach_panel.c
new file mode 100644 (file)
index 0000000..314420b
--- /dev/null
@@ -0,0 +1,766 @@
+/*
+ * Copyright (c) 2015 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * 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.
+ */
+
+#include <app_control.h>
+#include <bundle.h>
+#include <Elementary.h>
+#include <ui-gadget-module.h>
+#include <isf_control.h>
+#include <system_info.h>
+#include <tizen.h>
+#include <privilege_checker.h>
+#include <ui-gadget.h>
+
+#include "attach_panel.h"
+#include "attach_panel_internal.h"
+#include "attach_bundle.h"
+#include "conf.h"
+#include "content_list.h"
+#include "gesture.h"
+#include "grid.h"
+#include "ui_manager.h"
+#include "list.h"
+#include "log.h"
+#include "scroller.h"
+#include "toolbar.h"
+
+static const char *const ATTACH_PANEL_DOMAIN = "attach-panel";
+static const char *const PLATFORM_FEATURE_CAMERA = "tizen.org/feature/camera";
+static const char *const PLATFORM_FEATURE_MICROPHONE = "tizen.org/feature/microphone";
+
+
+
+innate_content_s innate_content_info[ATTACH_PANEL_CONTENT_CATEGORY_VIDEO_RECORDER] = {
+       {
+               .appid = "attach-panel-gallery",
+               .name = "IDS_COM_TAB4_IMAGES_ABB2",
+               .operation = APP_CONTROL_OPERATION_PICK,
+               .selection_mode = "single",
+               .tabbar_name = "IDS_COM_TAB4_IMAGES_ABB2",
+               .mime = "image/*",
+               .content_category = ATTACH_PANEL_CONTENT_CATEGORY_IMAGE,
+               .is_ug = ATTACH_PANEL_CONTENT_CATEGORY_UG,
+       },
+       {
+               .appid = "attach-panel-camera",
+               .name = "IDS_COM_TAB4_CAMERA",
+               .operation = APP_CONTROL_OPERATION_CREATE_CONTENT,
+               .selection_mode = "single",
+               .tabbar_name = "IDS_COM_TAB4_CAMERA",
+               .content_category = ATTACH_PANEL_CONTENT_CATEGORY_CAMERA,
+               .is_ug = ATTACH_PANEL_CONTENT_CATEGORY_UG,
+       },
+       {
+               .appid = "attach-panel-voicerecorder",
+               .name = "IDS_COM_TAB4_VOICE",
+               .operation = APP_CONTROL_OPERATION_CREATE_CONTENT,
+               .selection_mode = "single",
+               .tabbar_name = "IDS_COM_TAB4_VOICE",
+               .content_category = ATTACH_PANEL_CONTENT_CATEGORY_VOICE,
+               .is_ug = ATTACH_PANEL_CONTENT_CATEGORY_UG,
+       },
+       {
+               .appid = "videos",
+               .name = "IDS_COM_BUTTON2_VIDEOS",
+               .operation = APP_CONTROL_OPERATION_PICK,
+               .icon = "/usr/share/icons/video.png",
+               .selection_mode = "multiple",
+               .tabbar_name = "IDS_COM_TAB4_MORE_ABB",
+               .mime = "video/*",
+               .content_category = ATTACH_PANEL_CONTENT_CATEGORY_VIDEO,
+               .is_ug = ATTACH_PANEL_CONTENT_CATEGORY_APP,
+       },
+       {
+               .appid = "audio",
+               .name = "IDS_COM_BUTTON2_AUDIO_FILES",
+               .operation = APP_CONTROL_OPERATION_PICK,
+               .icon = "/usr/share/icons/music.png",
+               .selection_mode = "multiple",
+               .tabbar_name = "IDS_COM_TAB4_MORE_ABB",
+               .mime = "audio/*",
+               .content_category = ATTACH_PANEL_CONTENT_CATEGORY_AUDIO,
+               .is_ug = ATTACH_PANEL_CONTENT_CATEGORY_APP,
+       },
+       {
+               .appid = "calendar",
+               .name = "IDS_EMAIL_BUTTON2_CALENDAR",
+               .operation = APP_CONTROL_OPERATION_PICK,
+               .icon = "/usr/share/icons/calendar.png",
+               .tabbar_name = "IDS_COM_TAB4_MORE_ABB",
+               .mode = 1,
+               .type = "vcs",
+               .selection_mode = "multiple",
+               .mime = "application/vnd.tizen.calendar",
+               .max = 1,
+               .content_category = ATTACH_PANEL_CONTENT_CATEGORY_CALENDAR,
+               .is_ug = ATTACH_PANEL_CONTENT_CATEGORY_APP,
+       },
+       {
+               .appid = "contacts",
+               .name = "IDS_COM_BUTTON2_CONTACTS",
+               .operation = APP_CONTROL_OPERATION_PICK,
+               .icon = "/usr/share/icons/contact.png",
+               .tabbar_name = "IDS_COM_TAB4_MORE_ABB",
+               .type = "vcf",
+               .item_type = "person",
+               .selection_mode = "multiple",
+               .mime = "application/vnd.tizen.contact",
+               .content_category = ATTACH_PANEL_CONTENT_CATEGORY_CONTACT,
+               .is_ug = ATTACH_PANEL_CONTENT_CATEGORY_APP,
+       },
+       {
+               .appid = "myfiles",
+               .name = "IDS_COM_BUTTON_MY_FILES_ABB",
+               .operation = APP_CONTROL_OPERATION_PICK,
+               .tabbar_name = "IDS_COM_TAB4_MORE_ABB",
+               .icon = "/usr/share/icons/my_files.png",
+               .selection_mode = "multiple",
+               .content_category = ATTACH_PANEL_CONTENT_CATEGORY_MYFILES,
+               .is_ug = ATTACH_PANEL_CONTENT_CATEGORY_APP,
+       },
+       {
+               .appid = "record_video",
+               .name = "IDS_IDLE_BUTTON2_RECORD_NVIDEO_ABB",
+               .operation = APP_CONTROL_OPERATION_CREATE_CONTENT,
+               .icon = "/usr/share/icons/default.png",
+               .tabbar_name = "IDS_COM_TAB4_MORE_ABB",
+               .selection_mode = "single",
+               .mime = "video/3gp",
+               .content_category = ATTACH_PANEL_CONTENT_CATEGORY_VIDEO_RECORDER,
+               .is_ug = ATTACH_PANEL_CONTENT_CATEGORY_APP,
+       },
+};
+
+
+
+static Evas_Object *__attach_panel_rect_add(Evas_Object *conformant, int height)
+{
+       Evas_Object *rect = NULL;
+
+       retv_if(!conformant, NULL);
+
+       _D("attach panel rect create, height : %d", height);
+
+       rect = evas_object_rectangle_add(evas_object_evas_get(conformant));
+       retv_if(!rect, NULL);
+
+       evas_object_size_hint_weight_set(rect, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
+       evas_object_size_hint_align_set(rect, EVAS_HINT_FILL, 1.0);
+       evas_object_size_hint_min_set(rect, 0, height);
+       evas_object_color_set(rect, 0, 0, 0, 0);
+       evas_object_show(rect);
+
+       return rect;
+}
+
+
+
+static void __attach_panel_rect_del(Evas_Object *rect)
+{
+       ret_if(!rect);
+       evas_object_del(rect);
+}
+
+
+
+static void __rotate_cb(void *data, Evas_Object *obj, void *event)
+{
+       Evas_Object *win = obj;
+       attach_panel_h attach_panel = data;
+
+       int w, h;
+       int angle = 0;
+
+       ret_if(!attach_panel);
+       ret_if(!attach_panel->conformant);
+
+       angle = elm_win_rotation_get(win);
+       elm_win_screen_size_get(win, NULL, NULL, &w, &h);
+       _D("Angle is %d degree, win size is %d, %d", angle, w, h);
+
+       switch(angle) {
+       case 90:
+       case 270:
+               _D("resize the attach-panel to land(%d)", angle);
+               if (90 == angle)
+                       ug_send_event(UG_EVENT_ROTATE_LANDSCAPE_UPSIDEDOWN);
+               else
+                       ug_send_event(UG_EVENT_ROTATE_LANDSCAPE);
+
+               w = h;
+               attach_panel->rotate = EINA_TRUE;
+
+               if (ATTACH_PANEL_STATE_HIDE == attach_panel->attach_panel_port_state) {
+                       attach_panel->attach_panel_land_state = ATTACH_PANEL_STATE_HIDE;
+               } else if (ATTACH_PANEL_STATE_HALF == attach_panel->attach_panel_port_state) {
+                       attach_panel->attach_panel_land_state = ATTACH_PANEL_STATE_FULL;
+                       _gesture_set_state(ATTACH_PANEL_STATE_FULL);
+                       _content_list_send_message(attach_panel->content_list, APP_CONTROL_DATA_SELECTION_MODE, SELECTION_MODE_MULTIPLE, ATTACH_PANEL_CONTENT_CATEGORY_UG);
+                       elm_object_signal_emit(attach_panel->conformant, "elm,state,attach_panel,show,full", "");
+               } else {
+                       attach_panel->attach_panel_land_state = ATTACH_PANEL_STATE_FULL;
+                       _gesture_set_state(ATTACH_PANEL_STATE_FULL);
+               }
+               break;
+       case 0:
+       case 180:
+               _D("resize the attach-panel to port(%d)", angle);
+               if (0 == angle)
+                       ug_send_event(UG_EVENT_ROTATE_PORTRAIT);
+               else
+                       ug_send_event(UG_EVENT_ROTATE_PORTRAIT_UPSIDEDOWN);
+
+               attach_panel->rotate = EINA_FALSE;
+
+               if (ATTACH_PANEL_STATE_HIDE == attach_panel->attach_panel_land_state) {
+                       attach_panel->attach_panel_port_state = ATTACH_PANEL_STATE_HIDE;
+               } else {
+                       if (ATTACH_PANEL_STATE_HALF == attach_panel->attach_panel_port_state) {
+                               _gesture_set_state(ATTACH_PANEL_STATE_HALF);
+                               _content_list_send_message(attach_panel->content_list, APP_CONTROL_DATA_SELECTION_MODE, SELECTION_MODE_SINGLE, ATTACH_PANEL_CONTENT_CATEGORY_UG);
+                               elm_object_signal_emit(attach_panel->conformant, "elm,state,attach_panel,show,half", "");
+                       } else {
+                               attach_panel->attach_panel_port_state = ATTACH_PANEL_STATE_FULL;
+                               _gesture_set_state(ATTACH_PANEL_STATE_FULL);
+                       }
+               }
+               break;
+       default:
+               _E("cannot reach here");
+               break;
+       }
+
+       _scroller_resize(attach_panel->scroller, w, 0);
+       elm_scroller_page_show(attach_panel->scroller, attach_panel->cur_page_no, 0);
+}
+
+
+
+EXPORT_API int attach_panel_create(Evas_Object *conformant, attach_panel_h *attach_panel)
+{
+       Evas_Object *old_panel = NULL;
+       attach_panel_h panel = NULL;
+       const char *type = NULL;
+       int width = 0;
+       int height = 0;
+       int base_height = 0;
+
+       retv_if(!attach_panel, ATTACH_PANEL_ERROR_INVALID_PARAMETER);
+       retv_if(!conformant, ATTACH_PANEL_ERROR_INVALID_PARAMETER);
+
+       old_panel = elm_object_part_content_get(conformant, "elm.swallow.attach_panel");
+       retv_if(old_panel, ATTACH_PANEL_ERROR_ALREADY_EXISTS);
+
+       type = elm_object_widget_type_get(conformant);
+       retv_if(!type, ATTACH_PANEL_ERROR_INVALID_PARAMETER);
+
+       if (strcmp(type, "Elm_Conformant")) {
+               _E("This is not a conformant, %s", type);
+               return ATTACH_PANEL_ERROR_INVALID_PARAMETER;
+       }
+
+       bindtextdomain(ATTACH_PANEL_DOMAIN, "/usr/ug/res/locale");
+
+       panel = calloc(1, sizeof(attach_panel_s));
+       retv_if(!panel, ATTACH_PANEL_ERROR_OUT_OF_MEMORY);
+       panel->conformant = conformant;
+
+       evas_object_geometry_get(conformant, NULL, NULL, &width, &base_height);
+       panel->transit_width = width;
+
+       if (width > base_height) {
+               base_height = width * BASE_TRANSIT_HEIGHT_REL;
+       } else {
+               base_height = base_height * BASE_TRANSIT_HEIGHT_REL;
+       }
+
+       isf_control_get_recent_ime_geometry(NULL, NULL, NULL, &height);
+       if (!height || height < base_height) {
+               _E("Fail to get the recent ime height");
+               height = base_height;
+       }
+       panel->transit_height = height;
+
+       panel->attach_panel_rect = __attach_panel_rect_add(conformant, height);
+       goto_if(!panel->attach_panel_rect, ERROR);
+       elm_object_part_content_set(conformant, "elm.swallow.attach_panel_base", panel->attach_panel_rect);
+
+       panel->ui_manager = _ui_manager_create(panel);
+       goto_if(!panel->ui_manager, ERROR);
+       elm_object_part_content_set(conformant, "elm.swallow.attach_panel", panel->ui_manager);
+       panel->is_delete = EINA_FALSE;
+       panel->rotate = EINA_FALSE;
+       panel->flick = EINA_TRUE;
+       panel->cur_page_no = 0;
+       panel->magic_no = 0x1024;
+
+       panel->gesture = _gesture_create(panel);
+       goto_if(!panel->gesture, ERROR);
+
+       evas_object_smart_callback_add(panel->win, "wm,rotation,changed", __rotate_cb, panel);
+       elm_scroller_movement_block_set(panel->scroller, ELM_SCROLLER_MOVEMENT_BLOCK_HORIZONTAL);
+       __rotate_cb(panel, panel->win, NULL);
+       *attach_panel = panel;
+
+       return ATTACH_PANEL_ERROR_NONE;
+
+ERROR:
+       if (panel->ui_manager) {
+               elm_object_part_content_unset(conformant, "elm.swallow.attach_panel");
+               _ui_manager_destroy(panel->ui_manager);
+       }
+
+       if (panel->attach_panel_rect) {
+               elm_object_part_content_unset(conformant, "elm.swallow.attach_panel_base");
+               __attach_panel_rect_del(panel->attach_panel_rect);
+       }
+       free(panel);
+
+       return ATTACH_PANEL_ERROR_NOT_INITIALIZED;
+}
+
+
+
+extern void _attach_panel_del(attach_panel_h attach_panel)
+{
+       content_s *content_info = NULL;
+       Eina_List *l = NULL;
+
+       ret_if(!attach_panel);
+       _D("%s : attach panel is destroyed", __func__);
+
+       if (0x1024 != attach_panel->magic_no) {
+               _D("attach panel is already destroyed");
+               return;
+       }
+
+       attach_panel->magic_no = 0;
+
+       _gesture_destroy(attach_panel);
+
+       evas_object_smart_callback_del(attach_panel->win, "wm,rotation,changed", __rotate_cb);
+       elm_object_part_content_unset(attach_panel->conformant, "elm.swallow.attach_panel_base");
+       __attach_panel_rect_del(attach_panel->attach_panel_rect);
+
+       EINA_LIST_FOREACH(attach_panel->content_list, l, content_info) {
+               if (content_info->extra_data) {
+                       bundle_free(content_info->extra_data);
+                       content_info->extra_data = NULL;
+               }
+       }
+
+       elm_object_part_content_unset(attach_panel->conformant, "elm.swallow.attach_panel");
+       _ui_manager_destroy(attach_panel->ui_manager);
+
+       free(attach_panel);
+}
+
+
+
+EXPORT_API int attach_panel_destroy(attach_panel_h attach_panel)
+{
+       retv_if(!attach_panel, ATTACH_PANEL_ERROR_INVALID_PARAMETER);
+       _D("%s : attach panel will be destroyed", __func__);
+
+       if (EINA_TRUE == attach_panel->is_delete) {
+               _E("Attach panel is already removed");
+               return ATTACH_PANEL_ERROR_ALREADY_DESTROYED;
+       }
+
+       attach_panel->is_delete = EINA_TRUE;
+       if (ATTACH_PANEL_STATE_HIDE == _gesture_get_state()) {
+               _attach_panel_del(attach_panel);
+       } else {
+               attach_panel_hide(attach_panel);
+       }
+
+       return ATTACH_PANEL_ERROR_NONE;
+}
+
+
+
+static void __iter_cb(const char *key, const int type, bundle_keyval_t *kv, void *user_data)
+{
+       int *bundle_is_op = user_data;
+
+       ret_if(!key);
+       ret_if(!bundle_is_op);
+
+       if (!strncmp("__APP_SVC_", key, 10))
+               *bundle_is_op = 1;
+}
+
+
+
+static const char *const PRIVILEGE_CAMERA = "http://tizen.org/privilege/camera";
+static const char *const PRIVILEGE_RECORDER = "http://tizen.org/privilege/recorder";
+static const char *const PRIVILEGE_APPMANAGER_LAUNCH = "http://tizen.org/privilege/appmanager.launch";
+EXPORT_API int attach_panel_add_content_category(attach_panel_h attach_panel, attach_panel_content_category_e content_category, bundle *extra_data)
+{
+       content_s *content_info = NULL;
+       bundle *dup_bundle = NULL;
+       Eina_List *l = NULL;
+       int ret = SYSTEM_INFO_ERROR_NONE;
+       bool value = false;
+
+       retv_if(!attach_panel, ATTACH_PANEL_ERROR_INVALID_PARAMETER);
+       retv_if(!attach_panel->ui_manager, ATTACH_PANEL_ERROR_NOT_INITIALIZED);
+       retv_if(content_category < ATTACH_PANEL_CONTENT_CATEGORY_IMAGE, ATTACH_PANEL_ERROR_INVALID_PARAMETER);
+       retv_if(content_category > ATTACH_PANEL_CONTENT_CATEGORY_VIDEO_RECORDER, ATTACH_PANEL_ERROR_INVALID_PARAMETER);
+
+       if (EINA_TRUE == attach_panel->is_delete) {
+               _E("Attach panel is already removed");
+               return ATTACH_PANEL_ERROR_ALREADY_DESTROYED;
+       }
+
+       switch (content_category) {
+       case ATTACH_PANEL_CONTENT_CATEGORY_CAMERA:
+               ret = system_info_get_platform_bool(PLATFORM_FEATURE_CAMERA, &value);
+               break_if(SYSTEM_INFO_ERROR_NONE != ret);
+               retv_if(false == value, ATTACH_PANEL_ERROR_UNSUPPORTED_CONTENT_CATEGORY);
+
+               ret = privilege_checker_check_privilege(PRIVILEGE_CAMERA);
+               retv_if(PRIVILEGE_CHECKER_ERR_UNDECLARED_PRIVILEGE == ret, ATTACH_PANEL_ERROR_PERMISSION_DENIED);
+               break_if(PRIVILEGE_CHECKER_ERR_NONE != ret);
+               break;
+       case ATTACH_PANEL_CONTENT_CATEGORY_VOICE:
+               ret = system_info_get_platform_bool(PLATFORM_FEATURE_MICROPHONE, &value);
+               break_if(SYSTEM_INFO_ERROR_NONE != ret);
+               retv_if(false == value, ATTACH_PANEL_ERROR_UNSUPPORTED_CONTENT_CATEGORY);
+
+               ret = privilege_checker_check_privilege(PRIVILEGE_RECORDER);
+               retv_if(PRIVILEGE_CHECKER_ERR_UNDECLARED_PRIVILEGE == ret, ATTACH_PANEL_ERROR_PERMISSION_DENIED);
+               break_if(PRIVILEGE_CHECKER_ERR_NONE != ret);
+               break;
+       case ATTACH_PANEL_CONTENT_CATEGORY_VIDEO:
+       case ATTACH_PANEL_CONTENT_CATEGORY_AUDIO:
+       case ATTACH_PANEL_CONTENT_CATEGORY_CALENDAR:
+       case ATTACH_PANEL_CONTENT_CATEGORY_CONTACT:
+       case ATTACH_PANEL_CONTENT_CATEGORY_MYFILES:
+               ret = privilege_checker_check_privilege(PRIVILEGE_APPMANAGER_LAUNCH);
+               retv_if(PRIVILEGE_CHECKER_ERR_UNDECLARED_PRIVILEGE == ret, ATTACH_PANEL_ERROR_PERMISSION_DENIED);
+               break_if(PRIVILEGE_CHECKER_ERR_NONE != ret);
+               break;
+       default:
+               break;
+       }
+
+       EINA_LIST_FOREACH(attach_panel->content_list, l, content_info) {
+               if (content_info->innate_content_info->content_category == content_category) {
+                       _E("The content category[%d] already exists in the panel", content_category);
+                       return ATTACH_PANEL_ERROR_ALREADY_EXISTS;
+               }
+       }
+
+       if (extra_data) {
+               int bundle_is_op = 0;
+
+               bundle_foreach(extra_data, (void *) __iter_cb, &bundle_is_op);
+
+               if (bundle_is_op) {
+                       _E("bundle key is invalid value");
+                       return ATTACH_PANEL_ERROR_INVALID_PARAMETER;
+               }
+
+               dup_bundle = bundle_dup(extra_data);
+               retv_if(!dup_bundle, ATTACH_PANEL_ERROR_INVALID_PARAMETER);
+       }
+
+       _ui_manager_append_content_category(attach_panel->ui_manager, &innate_content_info[content_category-1], dup_bundle);
+
+       return ATTACH_PANEL_ERROR_NONE;
+}
+
+
+
+EXPORT_API int attach_panel_remove_content_category(attach_panel_h attach_panel, attach_panel_content_category_e content_category)
+{
+       content_s *content_info = NULL;
+       Eina_List *l = NULL;
+
+       retv_if(!attach_panel, ATTACH_PANEL_ERROR_INVALID_PARAMETER);
+       retv_if(!attach_panel->ui_manager, ATTACH_PANEL_ERROR_NOT_INITIALIZED);
+       retv_if(content_category < ATTACH_PANEL_CONTENT_CATEGORY_IMAGE, ATTACH_PANEL_ERROR_INVALID_PARAMETER);
+       retv_if(content_category > ATTACH_PANEL_CONTENT_CATEGORY_VIDEO_RECORDER, ATTACH_PANEL_ERROR_INVALID_PARAMETER);
+
+       if (EINA_TRUE == attach_panel->is_delete) {
+               _E("Attach panel is already removed");
+               return ATTACH_PANEL_ERROR_ALREADY_DESTROYED;
+       }
+
+       EINA_LIST_FOREACH(attach_panel->content_list, l, content_info) {
+               if (content_info->innate_content_info->content_category != content_category) {
+                       continue;
+               }
+               bundle_free(content_info->extra_data);
+               content_info->extra_data = NULL;
+               _ui_manager_remove_content_category(attach_panel->ui_manager, content_info);
+               break;
+       }
+
+       return ATTACH_PANEL_ERROR_NONE;
+}
+
+
+
+EXPORT_API int attach_panel_set_extra_data(attach_panel_h attach_panel, attach_panel_content_category_e content_category, bundle *extra_data)
+{
+       app_control_h app_control = NULL;
+       ui_gadget_h ui_gadget = NULL;
+       content_s *content_info = NULL;
+       Eina_List *l = NULL;
+
+       int ret = ATTACH_PANEL_ERROR_NONE;
+       int bundle_is_op = 0;
+
+       retv_if(!attach_panel, ATTACH_PANEL_ERROR_INVALID_PARAMETER);
+       retv_if(!attach_panel->ui_manager, ATTACH_PANEL_ERROR_NOT_INITIALIZED);
+       retv_if(content_category < ATTACH_PANEL_CONTENT_CATEGORY_IMAGE, ATTACH_PANEL_ERROR_INVALID_PARAMETER);
+       retv_if(content_category > ATTACH_PANEL_CONTENT_CATEGORY_VIDEO_RECORDER, ATTACH_PANEL_ERROR_INVALID_PARAMETER);
+       retv_if(!extra_data, ATTACH_PANEL_ERROR_INVALID_PARAMETER);
+
+       bundle_foreach(extra_data, (void *) __iter_cb, &bundle_is_op);
+
+       if (bundle_is_op) {
+               _E("bundle key is invalid value");
+               return ATTACH_PANEL_ERROR_INVALID_PARAMETER;
+       }
+
+       EINA_LIST_FOREACH(attach_panel->content_list, l, content_info) {
+               if (content_info->innate_content_info->content_category == content_category) {
+                       _D("add the data in %d content category", content_category);
+                       break;
+               }
+       }
+
+       if (content_info->extra_data) {
+               ret = _bundle_add_to_bundle(content_info->extra_data, extra_data);
+               retv_if(ret != ATTACH_PANEL_ERROR_NONE, ATTACH_PANEL_ERROR_OUT_OF_MEMORY);
+       } else {
+               bundle *dup_bundle = NULL;
+
+               dup_bundle = bundle_dup(extra_data);
+               retv_if(!dup_bundle, ATTACH_PANEL_ERROR_OUT_OF_MEMORY);
+
+               content_info->extra_data = dup_bundle;
+       }
+
+       if (innate_content_info[content_category-1].is_ug) {
+               if (!content_info->content) {
+                       _D("Create ug because ug is not created yet");
+                       content_info->content = _ui_manager_create_content(content_info->page, content_info, attach_panel);
+                       retv_if(!content_info->content, ATTACH_PANEL_ERROR_OUT_OF_MEMORY);
+                       if (ATTACH_PANEL_STATE_FULL == _gesture_get_state()) {
+                               _content_list_send_message(attach_panel->content_list, APP_CONTROL_DATA_SELECTION_MODE, SELECTION_MODE_MULTIPLE, ATTACH_PANEL_CONTENT_CATEGORY_UG);
+                       } else {
+                               _content_list_send_message(attach_panel->content_list, APP_CONTROL_DATA_SELECTION_MODE, SELECTION_MODE_SINGLE, ATTACH_PANEL_CONTENT_CATEGORY_UG);
+                       }
+               }
+
+               ret = app_control_create(&app_control);
+               retv_if(APP_CONTROL_ERROR_NONE != ret, ATTACH_PANEL_ERROR_OUT_OF_MEMORY);
+
+               ui_gadget = evas_object_data_get(content_info->content, DATA_KEY_UG);
+               if (!ui_gadget) {
+                       _E("Fail to get the ui gadget from content_info");
+                       app_control_destroy(app_control);
+                       return ATTACH_PANEL_ERROR_OUT_OF_MEMORY;
+
+               }
+               ug_send_message(ui_gadget, app_control);
+               ret = app_control_destroy(app_control);
+               retv_if(APP_CONTROL_ERROR_NONE != ret, ATTACH_PANEL_ERROR_OUT_OF_MEMORY);
+       } else {
+               // In case of app, bundle is not used imediately.
+               // when app is launching, bundle is used.
+       }
+
+       return ATTACH_PANEL_ERROR_NONE;
+}
+
+
+
+EXPORT_API int attach_panel_set_result_cb(attach_panel_h attach_panel, attach_panel_result_cb result_cb, void *user_data)
+{
+       retv_if(!attach_panel, ATTACH_PANEL_ERROR_INVALID_PARAMETER);
+       retv_if(!result_cb, ATTACH_PANEL_ERROR_INVALID_PARAMETER);
+
+       if (EINA_TRUE == attach_panel->is_delete) {
+               _E("Attach panel is already removed");
+               return ATTACH_PANEL_ERROR_ALREADY_DESTROYED;
+       }
+
+       attach_panel->result_cb = result_cb;
+       attach_panel->result_data = user_data;
+
+       return ATTACH_PANEL_ERROR_NONE;
+}
+
+
+
+EXPORT_API int attach_panel_unset_result_cb(attach_panel_h attach_panel)
+{
+       retv_if(!attach_panel, ATTACH_PANEL_ERROR_INVALID_PARAMETER);
+
+       if (EINA_TRUE == attach_panel->is_delete) {
+               _E("Attach panel is already removed");
+               return ATTACH_PANEL_ERROR_ALREADY_DESTROYED;
+       }
+
+       attach_panel->result_cb = NULL;
+       attach_panel->result_data = NULL;
+
+       return ATTACH_PANEL_ERROR_NONE;
+}
+
+
+
+EXPORT_API int attach_panel_set_event_cb(attach_panel_h attach_panel, attach_panel_event_cb event_cb, void *user_data)
+{
+       retv_if(!attach_panel, ATTACH_PANEL_ERROR_INVALID_PARAMETER);
+       retv_if(!event_cb, ATTACH_PANEL_ERROR_INVALID_PARAMETER);
+
+       if (EINA_TRUE == attach_panel->is_delete) {
+               _E("Attach panel is already removed");
+               return ATTACH_PANEL_ERROR_ALREADY_DESTROYED;
+       }
+
+       attach_panel->event_cb = event_cb;
+       attach_panel->event_data = user_data;
+
+       return ATTACH_PANEL_ERROR_NONE;
+}
+
+
+
+EXPORT_API int attach_panel_unset_event_cb(attach_panel_h attach_panel)
+{
+       retv_if(!attach_panel, ATTACH_PANEL_ERROR_INVALID_PARAMETER);
+
+       if (EINA_TRUE == attach_panel->is_delete) {
+               _E("Attach panel is already removed");
+               return ATTACH_PANEL_ERROR_ALREADY_DESTROYED;
+       }
+
+       attach_panel->event_cb = NULL;
+       attach_panel->event_data = NULL;
+
+       return ATTACH_PANEL_ERROR_NONE;
+}
+
+
+
+EXPORT_API int attach_panel_show(attach_panel_h attach_panel)
+{
+       Elm_Object_Item *first_it;
+       content_s *content_info = NULL;
+       int height = 0;
+
+       retv_if(!attach_panel, ATTACH_PANEL_ERROR_INVALID_PARAMETER);
+       retv_if(!attach_panel->ui_manager, ATTACH_PANEL_ERROR_INVALID_PARAMETER);
+
+       if (EINA_TRUE == attach_panel->is_delete) {
+               _E("Attach panel is already removed");
+               return ATTACH_PANEL_ERROR_ALREADY_DESTROYED;
+       }
+
+       if (ATTACH_PANEL_STATE_HIDE != _gesture_get_state()) {
+               _D("Attach panel is already shown");
+               return ATTACH_PANEL_ERROR_NONE;
+       }
+
+       isf_control_get_recent_ime_geometry(NULL, NULL, NULL, &height);
+       if (height && height > attach_panel->transit_height) {
+               _D("change the attach-panel's height(%d)", height);
+               evas_object_size_hint_min_set(attach_panel->attach_panel_rect, 0, height);
+               attach_panel->transit_height = height;
+       }
+
+       content_info = eina_list_nth(attach_panel->content_list, attach_panel->cur_page_no);
+       retv_if(!content_info, ATTACH_PANEL_ERROR_OUT_OF_MEMORY);
+
+       _toolbar_bring_in(attach_panel->toolbar, content_info->tabbar_item);
+
+       if (content_info->content) {
+               elm_scroller_page_show(attach_panel->scroller, attach_panel->cur_page_no, 0);
+       } else {
+               content_info->content = _ui_manager_create_content(content_info->page, content_info, attach_panel);
+               retv_if(!content_info->content, ATTACH_PANEL_ERROR_OUT_OF_MEMORY);
+       }
+
+       _content_list_set_resume(attach_panel->content_list, ATTACH_PANEL_CONTENT_CATEGORY_UG);
+       _content_list_send_message(attach_panel->content_list, "__ATTACH_PANEL_INITIALIZE__", MODE_ENABLE, ATTACH_PANEL_CONTENT_CATEGORY_UG);
+       evas_object_show(attach_panel->ui_manager);
+
+       _gesture_show(attach_panel);
+
+       attach_panel->content_list = _list_sort_by_rua(attach_panel->content_list);
+       _grid_refresh(attach_panel->grid);
+
+       first_it = elm_gengrid_first_item_get(attach_panel->grid);
+       if (first_it) {
+               elm_gengrid_item_show(first_it, ELM_GENGRID_ITEM_SCROLLTO_TOP);
+       }
+
+       return ATTACH_PANEL_ERROR_NONE;
+}
+
+
+
+EXPORT_API int attach_panel_hide(attach_panel_h attach_panel)
+{
+       retv_if(!attach_panel, ATTACH_PANEL_ERROR_INVALID_PARAMETER);
+       retv_if(!attach_panel->ui_manager, ATTACH_PANEL_ERROR_INVALID_PARAMETER);
+
+       if (EINA_TRUE == attach_panel->is_delete) {
+               _E("Attach panel is already removed");
+               return ATTACH_PANEL_ERROR_ALREADY_DESTROYED;
+       }
+
+       _content_list_set_pause(attach_panel->content_list, ATTACH_PANEL_CONTENT_CATEGORY_UG);
+       _gesture_hide(attach_panel);
+
+       return ATTACH_PANEL_ERROR_NONE;
+}
+
+
+
+EXPORT_API int attach_panel_get_visibility(attach_panel_h attach_panel, bool *visible)
+{
+       retv_if(!attach_panel, ATTACH_PANEL_ERROR_INVALID_PARAMETER);
+       retv_if(!visible, ATTACH_PANEL_ERROR_INVALID_PARAMETER);
+
+       if (EINA_TRUE == attach_panel->is_delete) {
+               _E("Attach panel is already removed");
+               return ATTACH_PANEL_ERROR_ALREADY_DESTROYED;
+       }
+
+       if (attach_panel->rotate) {
+               if (ATTACH_PANEL_STATE_HIDE == attach_panel->attach_panel_land_state) {
+                       *visible = false;
+               } else {
+                       *visible = true;
+               }
+       } else {
+               if (ATTACH_PANEL_STATE_HIDE == attach_panel->attach_panel_port_state) {
+                       *visible = false;
+               } else {
+                       *visible = true;
+               }
+       }
+
+       return ATTACH_PANEL_ERROR_NONE;
+}
diff --git a/src/content_list.c b/src/content_list.c
new file mode 100644 (file)
index 0000000..982a299
--- /dev/null
@@ -0,0 +1,185 @@
+/*
+ * Copyright (c) 2015 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * 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.
+ */
+
+#include <app_control.h>
+#include <Elementary.h>
+#include <tizen.h>
+#include <ui-gadget.h>
+
+#include "attach_panel.h"
+#include "attach_panel_internal.h"
+#include "conf.h"
+#include "content_list.h"
+#include "log.h"
+
+
+
+void _content_list_send_message(Eina_List *list, const char *key, const char *value, int is_ug)
+{
+       content_s *content_info = NULL;
+       app_control_h app_control = NULL;
+       const Eina_List *l = NULL;
+
+       int ret = APP_CONTROL_ERROR_NONE;
+
+       ret_if(!list);
+       ret_if(!key);
+       ret_if(!value);
+
+       ret = app_control_create(&app_control);
+       ret_if(APP_CONTROL_ERROR_NONE != ret);
+
+       ret = app_control_add_extra_data(app_control, "__CALLER_PANEL__", "attach-panel");
+       if (APP_CONTROL_ERROR_NONE != ret) {
+               _E("Fail to add extra data(__CALLER_PANEL__)");
+               app_control_destroy(app_control);
+               return;
+       }
+
+       ret = app_control_add_extra_data(app_control, key, value);
+       if (APP_CONTROL_ERROR_NONE != ret) {
+               _E("Fail to add extra data(%s)", key);
+               app_control_destroy(app_control);
+               return;
+       }
+
+       EINA_LIST_FOREACH(list, l, content_info) {
+               continue_if(!content_info);
+               if (!content_info->content) {
+                       _D("ug is not created yet");
+                       continue;
+               }
+               innate_content_s *innate_content_info = content_info->innate_content_info;
+               continue_if(!innate_content_info);
+
+               if (is_ug == innate_content_info->is_ug) {
+                       ui_gadget_h ui_gadget = NULL;
+
+                       ui_gadget = evas_object_data_get(content_info->content, DATA_KEY_UG);
+                       if (!ui_gadget) {
+                               _D("Fail to get the ui gadget");
+                               continue;
+                       }
+                       ug_send_message(ui_gadget, app_control);
+               }
+       }
+
+       ret = app_control_destroy(app_control);
+       ret_if(APP_CONTROL_ERROR_NONE != ret);
+}
+
+
+
+void _content_list_send_message_to_content(Eina_List *list, const char *key, const char *value, int cur_page_no)
+{
+       content_s *content_info = NULL;
+       app_control_h app_control = NULL;
+       ui_gadget_h ui_gadget = NULL;
+
+       int ret = APP_CONTROL_ERROR_NONE;
+
+       ret_if(!list);
+       ret_if(!key);
+       ret_if(!value);
+
+       content_info = eina_list_nth(list, cur_page_no);
+       ret_if(!content_info);
+
+       if (!content_info->innate_content_info->is_ug) {
+               _D("this page did not need to send message");
+               return;
+       }
+
+       ret = app_control_create(&app_control);
+       ret_if(APP_CONTROL_ERROR_NONE != ret);
+
+       ret = app_control_add_extra_data(app_control, "__CALLER_PANEL__", "attach-panel");
+       if (APP_CONTROL_ERROR_NONE != ret) {
+               _E("Fail to add extra data(__CALLER_PANEL__)");
+               app_control_destroy(app_control);
+               return;
+       }
+
+       ret = app_control_add_extra_data(app_control, key, value);
+       if (APP_CONTROL_ERROR_NONE != ret) {
+               _E("Fail to add extra data(%s)", key);
+               app_control_destroy(app_control);
+               return;
+       }
+
+       ui_gadget = evas_object_data_get(content_info->content, DATA_KEY_UG);
+       if (!ui_gadget) {
+               _D("Fail to get the ui gadget");
+               app_control_destroy(app_control);
+               return;
+       }
+       ug_send_message(ui_gadget, app_control);
+
+       ret = app_control_destroy(app_control);
+       ret_if(APP_CONTROL_ERROR_NONE != ret);
+}
+
+
+
+void _content_list_set_pause(Eina_List *list, int is_ug)
+{
+       content_s *content_info = NULL;
+       const Eina_List *l = NULL;
+
+       ret_if(!list);
+
+       EINA_LIST_FOREACH(list, l, content_info) {
+               continue_if(!content_info);
+               innate_content_s *innate_content_info = content_info->innate_content_info;
+               continue_if(!innate_content_info);
+               if (is_ug == innate_content_info->is_ug) {
+                       ui_gadget_h ui_gadget = NULL;
+
+                       ui_gadget = evas_object_data_get(content_info->content, DATA_KEY_UG);
+                       if (!ui_gadget) {
+                               _D("Fail to get the ui gadget");
+                               continue;
+                       }
+                       ug_pause_ug(ui_gadget);
+               }
+       }
+}
+
+
+
+void _content_list_set_resume(Eina_List *list, int is_ug)
+{
+       content_s *content_info = NULL;
+       const Eina_List *l = NULL;
+
+       ret_if(!list);
+
+       EINA_LIST_FOREACH(list, l, content_info) {
+               continue_if(!content_info);
+               innate_content_s *innate_content_info = content_info->innate_content_info;
+               continue_if(!innate_content_info);
+               if (is_ug == innate_content_info->is_ug) {
+                       ui_gadget_h ui_gadget = NULL;
+
+                       ui_gadget = evas_object_data_get(content_info->content, DATA_KEY_UG);
+                       if (!ui_gadget) {
+                               _D("Fail to get the ui gadget");
+                               continue;
+                       }
+                       ug_resume_ug(ui_gadget);
+               }
+       }
+}
diff --git a/src/gesture.c b/src/gesture.c
new file mode 100644 (file)
index 0000000..1555b8c
--- /dev/null
@@ -0,0 +1,347 @@
+/*
+ * Copyright (c) 2015 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * 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.
+ */
+
+#include <app_control.h>
+#include <Elementary.h>
+#include <tizen.h>
+
+#include "attach_panel.h"
+#include "attach_panel_internal.h"
+#include "conf.h"
+#include "content_list.h"
+#include "grid.h"
+#include "log.h"
+#include "page.h"
+#include "scroller.h"
+
+#define TRANSIT_DURATION 0.2f
+
+
+static struct {
+       Elm_Transit *transit;
+       attach_panel_state_e attach_panel_state;
+} gesture_info_s = {
+       .transit = NULL,
+       .attach_panel_state = ATTACH_PANEL_STATE_HIDE,
+};
+
+typedef struct custom_effect {
+       Evas_Coord from_h;
+       Evas_Coord to_h;
+} custom_effect_s;
+
+
+
+attach_panel_state_e _gesture_get_state(void)
+{
+       return gesture_info_s.attach_panel_state;
+}
+
+
+
+void _gesture_set_state(attach_panel_state_e state)
+{
+       gesture_info_s.attach_panel_state = state;
+}
+
+
+
+static Elm_Transit_Effect *__custom_effect_new(Evas_Coord from_h, Evas_Coord to_h)
+{
+       custom_effect_s *custom_effect = calloc(1, sizeof(custom_effect_s));
+       if (!custom_effect) return NULL;
+       _D("%s, from_h : %d to_h: %d", __func__, from_h, to_h);
+       custom_effect->from_h = from_h;
+       custom_effect->to_h = to_h;
+
+       return custom_effect;
+}
+
+
+
+static void __custom_effect_op(Elm_Transit_Effect *effect, Elm_Transit *transit, double progress)
+{
+       custom_effect_s *custom_effect = effect;
+       const Eina_List *list = NULL;
+       const Eina_List *objs = NULL;
+       Evas_Object *obj = NULL;
+       Evas_Coord h = 0;
+
+       if (!effect) {
+               _D("effect is alrealy exist");
+               return;
+       }
+
+       objs = elm_transit_objects_get(transit);
+
+       h = (Evas_Coord) ((custom_effect->from_h * (1.0 - progress)) + (custom_effect->to_h * progress));
+
+       _D("change the attach-panel height : %d(progress: %f)", h, progress);
+       EINA_LIST_FOREACH(objs, list, obj) {
+               evas_object_size_hint_min_set(obj, -1, h);
+               evas_object_size_hint_max_set(obj, -1, h);
+       }
+}
+
+
+
+static void __custom_effect_free(Elm_Transit_Effect *effect, Elm_Transit *transit)
+{
+       _D("");
+       free(effect);
+}
+
+
+
+static void __attach_panel_transit_del_cb(void *data, Elm_Transit *transit)
+{
+       attach_panel_h attach_panel = data;
+       _D("%s : transit is ended", __func__);
+
+       gesture_info_s.transit = NULL;
+       if (gesture_info_s.attach_panel_state == ATTACH_PANEL_STATE_HIDE) {
+               elm_object_signal_emit(attach_panel->conformant, "elm,state,attach_panel,hide,finished", "");
+               if (attach_panel->event_cb) {
+                       attach_panel->event_cb(attach_panel, ATTACH_PANEL_EVENT_HIDE_FINISH, NULL, attach_panel->event_data);
+               }
+               if (attach_panel->is_delete) {
+                       _attach_panel_del(attach_panel);
+               }
+       } else {
+               elm_object_signal_emit(attach_panel->conformant, "elm,state,attach_panel,show,finished", "");
+               if (attach_panel->event_cb) {
+                       attach_panel->event_cb(attach_panel, ATTACH_PANEL_EVENT_SHOW_FINISH, NULL, attach_panel->event_data);
+               }
+       }
+}
+
+
+
+static void __attach_panel_transit_set(attach_panel_h attach_panel, Evas_Coord from_h, Evas_Coord to_h, double duration)
+{
+       Elm_Transit_Effect *custom_effect = NULL;
+
+       if (gesture_info_s.transit) {
+               _E("Transit is already activating");
+               if (attach_panel->cur_event_state == ATTACH_PANEL_EVENT_HIDE_START) {
+                       if (gesture_info_s.attach_panel_state != ATTACH_PANEL_STATE_HIDE) {
+                               if (attach_panel->event_cb) {
+                                       attach_panel->event_cb(attach_panel, ATTACH_PANEL_EVENT_HIDE_FINISH, NULL, attach_panel->event_data);
+                                       attach_panel->event_cb(attach_panel, ATTACH_PANEL_EVENT_SHOW_START, NULL, attach_panel->event_data);
+                               }
+                       }
+               } else {
+                       if (gesture_info_s.attach_panel_state == ATTACH_PANEL_STATE_HIDE) {
+                               if (attach_panel->event_cb) {
+                                       attach_panel->event_cb(attach_panel, ATTACH_PANEL_EVENT_SHOW_FINISH, NULL, attach_panel->event_data);
+                                       attach_panel->event_cb(attach_panel, ATTACH_PANEL_EVENT_HIDE_START, NULL, attach_panel->event_data);
+                               }
+                       }
+               }
+               return;
+       }
+
+       custom_effect = __custom_effect_new(from_h, to_h);
+       ret_if(!custom_effect);
+
+       if (gesture_info_s.attach_panel_state == ATTACH_PANEL_STATE_HIDE) {
+               elm_object_signal_emit(attach_panel->conformant, "elm,state,attach_panel,hide,started", "");
+               attach_panel->cur_event_state = ATTACH_PANEL_EVENT_HIDE_START;
+               if (attach_panel->event_cb) {
+                       attach_panel->event_cb(attach_panel, ATTACH_PANEL_EVENT_HIDE_START, NULL, attach_panel->event_data);
+               }
+       } else {
+               elm_object_signal_emit(attach_panel->conformant, "elm,state,attach_panel,show,started", "");
+               attach_panel->cur_event_state = ATTACH_PANEL_EVENT_SHOW_START;
+               if (attach_panel->event_cb) {
+                       attach_panel->event_cb(attach_panel, ATTACH_PANEL_EVENT_SHOW_START, NULL, attach_panel->event_data);
+               }
+       }
+
+       gesture_info_s.transit = elm_transit_add();
+       if (!gesture_info_s.transit) {
+               _E("Fail to create transit");
+               __custom_effect_free(custom_effect, NULL);
+               return;
+       }
+       elm_transit_del_cb_set(gesture_info_s.transit, __attach_panel_transit_del_cb, attach_panel);
+       elm_transit_object_add(gesture_info_s.transit, attach_panel->attach_panel_rect);
+       elm_transit_tween_mode_set(gesture_info_s.transit, ELM_TRANSIT_TWEEN_MODE_DECELERATE);
+       elm_transit_smooth_set(gesture_info_s.transit, EINA_FALSE);
+       elm_transit_effect_add(gesture_info_s.transit, __custom_effect_op, custom_effect, __custom_effect_free);
+       elm_transit_duration_set(gesture_info_s.transit, duration);
+       elm_transit_go(gesture_info_s.transit);
+}
+
+
+
+void _gesture_show(attach_panel_h attach_panel)
+{
+       gesture_info_s.attach_panel_state = ATTACH_PANEL_STATE_HALF;
+       _D("gesture show start");
+
+       if (attach_panel->rotate) {
+               _content_list_send_message(attach_panel->content_list, APP_CONTROL_DATA_SELECTION_MODE, SELECTION_MODE_MULTIPLE, ATTACH_PANEL_CONTENT_CATEGORY_UG);
+               attach_panel->attach_panel_land_state = ATTACH_PANEL_STATE_FULL;
+               gesture_info_s.attach_panel_state = ATTACH_PANEL_STATE_FULL;
+               __attach_panel_transit_set(attach_panel, 0, attach_panel->transit_height, TRANSIT_DURATION);
+               elm_object_signal_emit(attach_panel->conformant, "elm,state,attach_panel,show,full", "");
+
+
+       } else {
+               _content_list_send_message(attach_panel->content_list, APP_CONTROL_DATA_SELECTION_MODE, SELECTION_MODE_SINGLE, ATTACH_PANEL_CONTENT_CATEGORY_UG);
+               elm_scroller_movement_block_set(attach_panel->grid, ELM_SCROLLER_MOVEMENT_BLOCK_VERTICAL);
+               attach_panel->attach_panel_port_state = ATTACH_PANEL_STATE_HALF;
+               gesture_info_s.attach_panel_state = ATTACH_PANEL_STATE_HALF;
+               __attach_panel_transit_set(attach_panel, 0, attach_panel->transit_height, TRANSIT_DURATION);
+       }
+}
+
+
+
+void _gesture_hide(attach_panel_h attach_panel)
+{
+       _D("gestrue hide start");
+       if (attach_panel->rotate) {
+               attach_panel->attach_panel_land_state = ATTACH_PANEL_STATE_HIDE;
+               elm_object_signal_emit(attach_panel->conformant, "elm,state,attach_panel,show,half", "");
+       } else {
+               if (ATTACH_PANEL_STATE_FULL == attach_panel->attach_panel_port_state) {
+                       elm_object_signal_emit(attach_panel->conformant, "elm,state,attach_panel,show,half", "");
+               }
+               attach_panel->attach_panel_port_state = ATTACH_PANEL_STATE_HIDE;
+       }
+       gesture_info_s.attach_panel_state = ATTACH_PANEL_STATE_HIDE;
+       attach_panel->flick = EINA_TRUE;
+       __attach_panel_transit_set(attach_panel, attach_panel->transit_height, 0, TRANSIT_DURATION);
+}
+
+
+
+void _gesture_set_full_mode(attach_panel_h attach_panel)
+{
+       if (attach_panel->rotate) {
+               return;
+       }
+       if (attach_panel->attach_panel_port_state == ATTACH_PANEL_STATE_HALF) {
+               attach_panel->attach_panel_port_state = ATTACH_PANEL_STATE_FULL;
+               gesture_info_s.attach_panel_state = ATTACH_PANEL_STATE_FULL;
+               elm_scroller_movement_block_set(attach_panel->grid, ELM_SCROLLER_MOVEMENT_NO_BLOCK);
+               elm_object_signal_emit(attach_panel->conformant, "elm,state,attach_panel,show,full", "");
+               _content_list_send_message(attach_panel->content_list, APP_CONTROL_DATA_SELECTION_MODE, SELECTION_MODE_MULTIPLE, ATTACH_PANEL_CONTENT_CATEGORY_UG);
+       }
+}
+
+
+
+static Evas_Event_Flags __flick_end_cb(void *data, void *event_info)
+{
+       attach_panel_h attach_panel = data;
+       Elm_Gesture_Line_Info *line_info = (Elm_Gesture_Line_Info *) event_info;
+
+       retv_if(!attach_panel, EVAS_EVENT_FLAG_ON_HOLD);
+       _D("flick end event");
+
+       if (EINA_TRUE == attach_panel->is_delete) {
+               _E("Attach panel is already removed");
+               return EVAS_EVENT_FLAG_ON_HOLD;
+       }
+
+       if (_scroller_is_scrolling(attach_panel->scroller)) {
+               return EVAS_EVENT_FLAG_ON_HOLD;
+       }
+       if (!_grid_can_flick(attach_panel)) {
+               return EVAS_EVENT_FLAG_ON_HOLD;
+       }
+
+       if (!attach_panel->flick) {
+               _D("attach_panel flick is disable");
+               return EVAS_EVENT_FLAG_ON_HOLD;
+       }
+
+       if ((line_info->angle > 45 && line_info->angle < 135) || (line_info->angle > 225 && line_info->angle < 315)) {
+               _D("it is not flick event");
+               return EVAS_EVENT_FLAG_ON_HOLD;
+       }
+
+       /* Flick Up */
+       if (line_info->momentum.my < 0) {
+               if (attach_panel->rotate) {
+                       return EVAS_EVENT_FLAG_ON_HOLD;
+               }
+               if (attach_panel->attach_panel_port_state == ATTACH_PANEL_STATE_HALF) {
+                       attach_panel->attach_panel_port_state = ATTACH_PANEL_STATE_FULL;
+                       gesture_info_s.attach_panel_state = ATTACH_PANEL_STATE_FULL;
+                       elm_scroller_movement_block_set(attach_panel->grid, ELM_SCROLLER_MOVEMENT_NO_BLOCK);
+                       elm_object_signal_emit(attach_panel->conformant, "elm,state,attach_panel,show,full", "");
+                       _content_list_send_message(attach_panel->content_list, APP_CONTROL_DATA_SELECTION_MODE, SELECTION_MODE_MULTIPLE, ATTACH_PANEL_CONTENT_CATEGORY_UG);
+               }
+       }
+       /* Flick Down */
+       else {
+               if (attach_panel->rotate) {
+                       if (attach_panel->attach_panel_land_state == ATTACH_PANEL_STATE_FULL) {
+                               _gesture_hide(attach_panel);
+                       }
+               } else {
+                       if (attach_panel->attach_panel_port_state == ATTACH_PANEL_STATE_FULL) {
+                               attach_panel->attach_panel_port_state = ATTACH_PANEL_STATE_HALF;
+                               gesture_info_s.attach_panel_state = ATTACH_PANEL_STATE_HALF;
+                               elm_scroller_movement_block_set(attach_panel->grid, ELM_SCROLLER_MOVEMENT_BLOCK_VERTICAL);
+                               elm_object_signal_emit(attach_panel->conformant, "elm,state,attach_panel,show,half", "");
+                               _content_list_send_message(attach_panel->content_list, APP_CONTROL_DATA_SELECTION_MODE, SELECTION_MODE_SINGLE, ATTACH_PANEL_CONTENT_CATEGORY_UG);
+                       } else if (attach_panel->attach_panel_port_state == ATTACH_PANEL_STATE_HALF) {
+                               _gesture_hide(attach_panel);
+                               _content_list_send_message(attach_panel->content_list, APP_CONTROL_DATA_SELECTION_MODE, SELECTION_MODE_SINGLE, ATTACH_PANEL_CONTENT_CATEGORY_UG);
+                       }
+               }
+       }
+
+       return EVAS_EVENT_FLAG_ON_HOLD;
+}
+
+
+
+Evas_Object *_gesture_create(attach_panel_h attach_panel)
+{
+       Evas_Object *gesture_layer = NULL;
+
+       retv_if(!attach_panel, NULL);
+       retv_if(!attach_panel->ui_manager, NULL);
+
+       _D("gesture create");
+
+       gesture_layer = elm_gesture_layer_add(attach_panel->scroller);
+       retv_if(!gesture_layer, NULL);
+       elm_gesture_layer_attach(gesture_layer, attach_panel->scroller);
+       evas_object_show(gesture_layer);
+
+       elm_gesture_layer_cb_set(gesture_layer, ELM_GESTURE_N_FLICKS, ELM_GESTURE_STATE_END, __flick_end_cb, attach_panel);
+
+       return gesture_layer;
+
+}
+
+
+
+void _gesture_destroy(attach_panel_h attach_panel)
+{
+       ret_if(!attach_panel);
+       ret_if(!attach_panel->gesture);
+
+       evas_object_del(attach_panel->gesture);
+       attach_panel->gesture = NULL;
+}
diff --git a/src/grid.c b/src/grid.c
new file mode 100644 (file)
index 0000000..d0bfcf4
--- /dev/null
@@ -0,0 +1,583 @@
+/*
+ * Copyright (c) 2015 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * 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.
+ */
+
+#include <aul.h>
+#include <app_control.h>
+#include <Elementary.h>
+#include <rua.h>
+
+#include "attach_panel.h"
+#include "attach_panel_internal.h"
+#include "attach_bundle.h"
+#include "conf.h"
+#include "content_list.h"
+#include "gesture.h"
+#include "grid.h"
+#include "log.h"
+
+
+
+static const char *const FILE_LAYOUT_EDJ = EDJEDIR"/layout.edj";
+static const char *const PRIVATE_DATA_KEY_GRID_LIST = "p_g_lt";
+static const char *const PRIVATE_DATA_KEY_GIC = "p_gic";
+static const char *const PRIVATE_DATA_KEY_LIST_INDEX = "p_lt_ix";
+static const char *const PRIVATE_DATA_KEY_ICON_WIDTH = "p_ic_w";
+static const char *const PRIVATE_DATA_KEY_ICON_HEIGHT = "p_ic_h";
+static const char *const PRIVATE_DATA_KEY_ITEM_WIDTH = "p_it_w";
+static const char *const PRIVATE_DATA_KEY_ITEM_HEIGHT = "p_it_h";
+static const char *const PRIVATE_DATA_KEY_ANIMATOR = "p_tm";
+static const char *const DEFAULT_ICON = "/usr/share/icons/A01-1_icon_Menu.png";
+
+
+
+Eina_Bool _grid_can_flick(attach_panel_h attach_panel)
+{
+       content_s *current_content_info = NULL;
+       int content_h, grid_h;
+
+       if (attach_panel->rotate) {
+               if (ATTACH_PANEL_STATE_FULL != attach_panel->attach_panel_land_state) {
+                       _D("panel is not full state(land mode)");
+                       return EINA_TRUE;
+               }
+       } else {
+               if (ATTACH_PANEL_STATE_FULL != attach_panel->attach_panel_port_state) {
+                       _D("panel is not full state(port mode)");
+                       evas_object_data_set(attach_panel->grid, DATA_KEY_EDGE_TOP, (void *) 1);
+                       return EINA_TRUE;
+               }
+       }
+
+       current_content_info = eina_list_nth(attach_panel->content_list, attach_panel->cur_page_no);
+       retv_if(!current_content_info, EINA_TRUE);
+
+       if (attach_panel->grid != current_content_info->content) {
+               _D("current page is ug page");
+               return EINA_TRUE;
+       }
+
+       elm_scroller_child_size_get(attach_panel->grid, NULL, &content_h);
+       evas_object_geometry_get(attach_panel->grid, NULL, NULL, NULL, &grid_h);
+
+       if (content_h < grid_h) {
+               _D("scrolling is not exist(grid size : %d, content size : %d", grid_h, content_h);
+               return EINA_TRUE;
+       }
+
+       if (!evas_object_data_del(attach_panel->grid, DATA_KEY_EDGE_TOP)) {
+               _D("grid can not reach the edge top");
+               return EINA_FALSE;
+       }
+
+       return EINA_TRUE;
+}
+
+
+
+static char *__text_get(void *data, Evas_Object *obj, const char *part)
+{
+       content_s *info = data;
+       innate_content_s *innate_content_info = NULL;
+       char *buf = NULL;
+       retv_if(!info, NULL);
+
+       innate_content_info = info->innate_content_info;
+       retv_if(!innate_content_info, NULL);
+       if (!strcmp(part, "elm.text")) {
+               buf = elm_entry_utf8_to_markup(D_(innate_content_info->name));
+               return buf;
+       }
+
+       return NULL;
+}
+
+
+
+static Evas_Object *__add_icon(Evas_Object *parent, const char *file)
+{
+       const char *real_icon_file = NULL;
+       Evas_Object *icon = NULL;
+       Evas_Object *icon_layout = NULL;
+       int w, h;
+
+       real_icon_file = file;
+       if (access(real_icon_file, R_OK) != 0) {
+               _E("Failed to access an icon(%s)", real_icon_file);
+               real_icon_file = DEFAULT_ICON;
+       }
+
+       icon = elm_icon_add(parent);
+       retv_if(!icon, NULL);
+
+       if (elm_image_file_set(icon, real_icon_file, NULL) == EINA_FALSE) {
+               _E("Icon file is not accessible (%s)", real_icon_file);
+               evas_object_del(icon);
+               return NULL;
+       }
+
+       w = (int) evas_object_data_get(parent, PRIVATE_DATA_KEY_ICON_WIDTH);
+       h = (int) evas_object_data_get(parent, PRIVATE_DATA_KEY_ICON_HEIGHT);
+       evas_object_size_hint_min_set(icon, w, h);
+
+       elm_image_preload_disabled_set(icon, EINA_TRUE);
+       elm_image_smooth_set(icon, EINA_TRUE);
+       elm_image_no_scale_set(icon, EINA_FALSE);
+       evas_object_show(icon);
+
+       icon_layout = elm_layout_add(parent);
+       retv_if(!icon_layout, NULL);
+
+       elm_layout_file_set(icon_layout, FILE_LAYOUT_EDJ, "grid,icon");
+       evas_object_size_hint_weight_set(icon_layout, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
+       evas_object_size_hint_align_set(icon_layout, EVAS_HINT_FILL, EVAS_HINT_FILL);
+       evas_object_show(icon_layout);
+
+       elm_object_part_content_set(icon_layout, "icon", icon);
+
+       return icon_layout;
+}
+
+
+
+static Evas_Object *__content_get(void *data, Evas_Object *obj, const char *part)
+{
+       content_s *info = data;
+       innate_content_s *innate_content_info = NULL;
+
+       retv_if(!info, NULL);
+       innate_content_info = info->innate_content_info;
+       retv_if(!innate_content_info, NULL);
+
+       if (!strcmp(part, "elm.swallow.end")) {
+               Evas_Object *bg = evas_object_rectangle_add(evas_object_evas_get(obj));
+               retv_if(!bg, NULL);
+               int w, h;
+
+               w = (int) evas_object_data_get(obj, PRIVATE_DATA_KEY_ITEM_WIDTH);
+               h = (int) evas_object_data_get(obj, PRIVATE_DATA_KEY_ITEM_HEIGHT);
+
+               evas_object_size_hint_min_set(bg, w, h);
+               evas_object_color_set(bg, 0, 0, 0, 0);
+               evas_object_show(bg);
+               return bg;
+       } else if (!strcmp(part, "elm.swallow.icon")) {
+               retv_if(!innate_content_info->icon, NULL);
+               return __add_icon(obj, innate_content_info->icon);
+       } else if (!strcmp(part, "selected")) {
+
+       }
+       return NULL;
+}
+
+
+
+static void __del(void *data, Evas_Object *obj)
+{
+       ret_if(NULL == data);
+}
+
+
+
+static void __reply_cb(app_control_h request, app_control_h reply, app_control_result_e result, void *user_data)
+{
+       content_s *content_info = user_data;
+       char **select = NULL;
+       int i = 0;
+       int length = 0;
+       int ret = APP_CONTROL_ERROR_NONE;
+
+       ret_if(!content_info);
+       ret_if(!content_info->attach_panel);
+
+       /* This is just for protocol log */
+       _D("relay callback is called");
+       ret = app_control_get_extra_data_array(reply, "http://tizen.org/appcontrol/data/selected", &select, &length);
+       if (APP_CONTROL_ERROR_NONE == ret && select) {
+               for (i = 0; i < length; i++) {
+                       _D("selected is %s[%d]", select[i], i);
+               }
+       }
+
+       ret = app_control_get_extra_data_array(reply, "http://tizen.org/appcontrol/data/path", &select, &length);
+       if (APP_CONTROL_ERROR_NONE == ret && select) {
+               for (i = 0; i < length; i++) {
+                       _D("path is %s[%d]", select[i], i);
+               }
+       }
+
+       if (content_info->attach_panel->result_cb) {
+               content_info->attach_panel->result_cb(content_info->attach_panel
+                               , content_info->innate_content_info->content_category
+                               , reply
+                               , result
+                               , content_info->attach_panel->result_data);
+
+               if (ATTACH_PANEL_STATE_FULL == _gesture_get_state()) {
+                       /* This is same with attach_panel_hide() */
+                       _content_list_set_pause(content_info->attach_panel->content_list, ATTACH_PANEL_CONTENT_CATEGORY_UG);
+                       _gesture_hide(content_info->attach_panel);
+               }
+       } else {
+               _D("content_info->attach_panel->result_cb is NULL");
+       }
+}
+
+
+
+static void __launch_app(content_s *content_info)
+{
+       app_control_h app_control = NULL;
+       innate_content_s *innate_content_info = NULL;
+       char value[BUF_SIZE] = {0, };
+       int ret;
+
+       ret_if(!content_info);
+
+       innate_content_info = content_info->innate_content_info;
+       ret_if(!innate_content_info);
+
+       ret = app_control_create(&app_control);
+       ret_if(APP_CONTROL_ERROR_NONE != ret);
+
+       if (content_info->innate_content_info->operation) {
+               ret = app_control_set_operation(app_control, content_info->innate_content_info->operation);
+               if (APP_CONTROL_ERROR_NONE != ret)
+                       _E("Fail to set operation");
+       }
+
+       if (content_info->innate_content_info->mode) {
+               snprintf(value, sizeof(value), "%d", content_info->innate_content_info->mode);
+               ret = app_control_add_extra_data(app_control, "http://tizen.org/appcontrol/data/mode", value);
+               if (APP_CONTROL_ERROR_NONE != ret)
+                       _E("Fail to add 'http://tizen.org/appcontrol/data/mode'");
+       }
+
+       if (content_info->innate_content_info->type) {
+               ret = app_control_add_extra_data(app_control, "http://tizen.org/appcontrol/data/type", content_info->innate_content_info->type);
+               if (APP_CONTROL_ERROR_NONE != ret)
+                       _E("Fail to add 'http://tizen.org/appcontrol/data/type'");
+       }
+
+       if (content_info->innate_content_info->item_type) {
+               ret = app_control_add_extra_data(app_control, "http://tizen.org/appcontrol/data/item_type", content_info->innate_content_info->item_type);
+               if (APP_CONTROL_ERROR_NONE != ret)
+                       _E("Fail to add 'http://tizen.org/appcontrol/data/item_type'");
+       }
+
+       if (content_info->innate_content_info->selection_mode) {
+               ret = app_control_add_extra_data(app_control, APP_CONTROL_DATA_SELECTION_MODE, content_info->innate_content_info->selection_mode);
+               if (APP_CONTROL_ERROR_NONE != ret)
+                       _E("Fail to add APP_CONTROL_DATA_SELECTION_MODE");
+       }
+
+       if (content_info->innate_content_info->mime) {
+               ret = app_control_set_mime(app_control, content_info->innate_content_info->mime);
+               if (APP_CONTROL_ERROR_NONE != ret)
+                       _E("Fail to set mime");
+       }
+
+       if (content_info->innate_content_info->max) {
+               snprintf(value, sizeof(value), "%d", content_info->innate_content_info->max);
+               ret = app_control_add_extra_data(app_control, "http://tizen.org/appcontrol/data/max", value);
+               if (APP_CONTROL_ERROR_NONE != ret)
+                       _E("Fail to add 'http://tizen.org/appcontrol/data/max'");
+       }
+
+       if (content_info->extra_data) {
+               _D("app control add the extra data for app");
+               _bundle_add_to_app_control(content_info->extra_data, app_control);
+       }
+
+       ret = app_control_add_extra_data(app_control, AUL_SVC_K_RUA_STAT_CALLER, "attach-panel");
+       if (APP_CONTROL_ERROR_NONE != ret)
+               _E("Fail to add 'AUL_SVC_K_RUA_STAT_CALLER'");
+
+       ret = app_control_add_extra_data(app_control, AUL_SVC_K_RUA_STAT_TAG, content_info->innate_content_info->appid);
+       if (APP_CONTROL_ERROR_NONE != ret)
+               _E("Fail to add 'AUL_SVC_K_RUA_STAT_TAG'");
+
+       ret = app_control_add_extra_data(app_control, "__CALLER_PANEL__", "attach-panel");
+       if (APP_CONTROL_ERROR_NONE != ret)
+               _E("Fail to add '__CALLER_PANEL__'");
+
+       ret = app_control_set_launch_mode(app_control, APP_CONTROL_LAUNCH_MODE_GROUP);
+       if (APP_CONTROL_ERROR_NONE != ret)
+               _E("Fail to set launch mode");
+
+       ret = app_control_send_launch_request(app_control, __reply_cb, content_info);
+       if (APP_CONTROL_ERROR_NONE != ret)
+               _E("Fail to send launch request");
+
+       app_control_destroy(app_control);
+}
+
+
+
+static void __item_selected(void *data, Evas_Object *obj, void *event_info)
+{
+       content_s *info = data;
+       innate_content_s *innate_content_info = NULL;
+       Elm_Object_Item *selected_item = NULL;
+
+       ret_if(!info);
+       innate_content_info = info->innate_content_info;
+       ret_if(!innate_content_info);
+
+       selected_item = elm_gengrid_selected_item_get(obj);
+       ret_if(!selected_item);
+       elm_gengrid_item_selected_set(selected_item, EINA_FALSE);
+
+       _D("Selected an item[%s]", innate_content_info->operation);
+
+       __launch_app(info);
+}
+
+
+
+Eina_Bool __animator_cb(void *data)
+{
+       Evas_Object *grid = data;
+       Elm_Gengrid_Item_Class *gic = NULL;
+       Eina_List *list = NULL;
+       content_s *info = NULL;
+
+       int index = 0;
+       int count = 0;
+
+       retv_if(!grid, ECORE_CALLBACK_CANCEL);
+
+       list = evas_object_data_get(grid, PRIVATE_DATA_KEY_GRID_LIST);
+       retv_if(!list, ECORE_CALLBACK_CANCEL);
+
+       gic = evas_object_data_get(grid, PRIVATE_DATA_KEY_GIC);
+       retv_if(!gic, ECORE_CALLBACK_CANCEL);
+
+       index = (int) evas_object_data_get(grid, PRIVATE_DATA_KEY_LIST_INDEX);
+
+       count = eina_list_count(list);
+       if (index == count) goto OUT;
+       info = eina_list_nth(list, index);
+       if (info && info->innate_content_info) {
+               if (!info->innate_content_info->is_ug) {
+                       elm_gengrid_item_append(grid, gic, info, __item_selected, info);
+               }
+       }
+       index++;
+       if (index == count) goto OUT;
+       evas_object_data_set(grid, PRIVATE_DATA_KEY_LIST_INDEX, (void *) index);
+
+       return ECORE_CALLBACK_RENEW;
+
+OUT:
+       _D("Loading apps is done");
+
+       Elm_Object_Item *first_it = elm_gengrid_first_item_get(grid);
+       if (first_it) {
+               elm_gengrid_item_bring_in(first_it, ELM_GENGRID_ITEM_SCROLLTO_TOP);
+       }
+       evas_object_data_del(grid, PRIVATE_DATA_KEY_LIST_INDEX);
+       evas_object_data_del(grid, PRIVATE_DATA_KEY_ANIMATOR);
+
+       return ECORE_CALLBACK_CANCEL;
+}
+
+
+
+void _grid_refresh(Evas_Object *grid)
+{
+       Ecore_Animator *anim = NULL;
+
+       ret_if(!grid);
+
+       elm_gengrid_clear(grid);
+
+       anim = evas_object_data_del(grid, PRIVATE_DATA_KEY_ANIMATOR);
+       if (anim) {
+               ecore_animator_del(anim);
+       }
+       anim = ecore_animator_add(__animator_cb, grid);
+       ret_if(!anim);
+
+       evas_object_data_set(grid, PRIVATE_DATA_KEY_ANIMATOR, anim);
+}
+
+
+
+static void __edge_top_cb(void *data, Evas_Object *grid, void *event_info)
+{
+       ret_if(!grid);
+       _D("grid reach the edge top");
+       evas_object_data_set(grid, DATA_KEY_EDGE_TOP, (void *) 1);
+}
+
+
+
+static void __scroll_cb(void *data, Evas_Object *grid, void *event_info)
+{
+       ret_if(!grid);
+       evas_object_data_del(grid, DATA_KEY_EDGE_TOP);
+}
+
+
+
+static void __lang_changed_cb(void *data, Evas_Object *grid, void *event_info)
+{
+       ret_if(!grid);
+       elm_gengrid_realized_items_update(grid);
+}
+
+
+
+Evas_Object *_grid_create(Evas_Object *page, attach_panel_h attach_panel)
+{
+       Evas_Object *grid = NULL;
+       Elm_Gengrid_Item_Class *gic = NULL;
+
+       int item_w = 0, item_h = 0, icon_size = 0;
+       int w, h;
+
+       retv_if(!attach_panel, NULL);
+
+       grid = elm_gengrid_add(page);
+       goto_if(!grid, ERROR);
+
+       evas_object_size_hint_weight_set(grid, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
+       evas_object_size_hint_align_set(grid, EVAS_HINT_FILL, EVAS_HINT_FILL);
+
+       evas_object_geometry_get(attach_panel->conformant, NULL, NULL, &w, &h);
+
+       if (w < h) {
+               item_w = w / GRID_ROW_COUNT;
+       } else {
+               item_w = h / GRID_ROW_COUNT;
+       }
+       item_h = item_w * GRID_ITEM_HEIGHT_REL;
+       icon_size = item_h * GRID_ICON_SIZE_REL;
+       _D("item_size : %d, %d, icon_size : %d", item_w, item_h, icon_size);
+
+       evas_object_data_set(grid, PRIVATE_DATA_KEY_ITEM_WIDTH, (void *) item_w);
+       evas_object_data_set(grid, PRIVATE_DATA_KEY_ITEM_HEIGHT, (void *) item_h);
+       evas_object_data_set(grid, PRIVATE_DATA_KEY_ICON_WIDTH, (void *) icon_size);
+       evas_object_data_set(grid, PRIVATE_DATA_KEY_ICON_HEIGHT, (void *) icon_size);
+
+       elm_gengrid_item_size_set(grid, item_w, item_h);
+       elm_gengrid_align_set(grid, 0.0, 0.0);
+       elm_gengrid_horizontal_set(grid, EINA_FALSE);
+       elm_gengrid_multi_select_set(grid, EINA_FALSE);
+       elm_object_style_set(grid, "popup");
+
+       gic = elm_gengrid_item_class_new();
+       goto_if(!gic, ERROR);
+       gic->func.text_get = __text_get;
+       gic->func.content_get = __content_get;
+       gic->func.state_get = NULL;
+       gic->func.del = __del;
+       gic->item_style = "default";
+
+       evas_object_data_set(grid, PRIVATE_DATA_KEY_GRID_LIST, attach_panel->content_list);
+       evas_object_data_set(grid, PRIVATE_DATA_KEY_GIC, gic);
+       evas_object_data_set(grid, PRIVATE_DATA_KEY_LIST_INDEX, NULL);
+       evas_object_data_set(grid, DATA_KEY_EDGE_TOP, (void *)1);
+       evas_object_smart_callback_add(grid, "edge,top", __edge_top_cb, NULL);
+       evas_object_smart_callback_add(grid, "scroll", __scroll_cb, NULL);
+       evas_object_smart_callback_add(grid, "language,changed", __lang_changed_cb, NULL);
+
+       elm_scroller_movement_block_set(grid, ELM_SCROLLER_MOVEMENT_BLOCK_VERTICAL);
+
+       evas_object_show(grid);
+
+       return grid;
+
+ERROR:
+       _grid_destroy(grid);
+       return NULL;
+}
+
+
+
+void _grid_destroy(Evas_Object *grid)
+{
+       ret_if(!grid);
+
+       Ecore_Animator *animator = NULL;
+
+       evas_object_data_del(grid, PRIVATE_DATA_KEY_GRID_LIST);
+       evas_object_data_del(grid, PRIVATE_DATA_KEY_LIST_INDEX);
+       evas_object_data_del(grid, PRIVATE_DATA_KEY_ICON_WIDTH);
+       evas_object_data_del(grid, PRIVATE_DATA_KEY_ICON_HEIGHT);
+       evas_object_data_del(grid, PRIVATE_DATA_KEY_ITEM_WIDTH);
+       evas_object_data_del(grid, PRIVATE_DATA_KEY_ITEM_HEIGHT);
+       evas_object_data_del(grid, DATA_KEY_EDGE_TOP);
+
+       evas_object_data_del(grid, PRIVATE_DATA_KEY_GIC);
+
+       animator = evas_object_data_del(grid, PRIVATE_DATA_KEY_ANIMATOR);
+       if (animator) {
+               ecore_animator_del(animator);
+               animator = NULL;
+       }
+
+       evas_object_del(grid);
+}
+
+
+
+Elm_Object_Item *_grid_append_item(Evas_Object *grid, content_s *content_info)
+{
+       Elm_Gengrid_Item_Class *gic = NULL;
+       Elm_Object_Item *item = NULL;
+
+       retv_if(!grid, NULL);
+       retv_if(!content_info, NULL);
+
+       gic = evas_object_data_get(grid, PRIVATE_DATA_KEY_GIC);
+       retv_if(!gic, NULL);
+
+       item = elm_gengrid_item_append(grid, gic, content_info, __item_selected, content_info);
+       retv_if(!item, NULL);
+       _D("grid append item : %s", content_info->innate_content_info->name);
+       content_info->grid_item = item;
+
+       return item;
+}
+
+
+
+void _grid_remove_item(Evas_Object *grid, content_s *content_info)
+{
+       Elm_Object_Item *item = NULL;
+
+       ret_if(!grid);
+       ret_if(!content_info);
+
+       item = content_info->grid_item;
+       ret_if(!item);
+       elm_object_item_del(item);
+       content_info->grid_item = NULL;
+}
+
+
+
+int _grid_count_item(Evas_Object *grid)
+{
+       int count = 0;
+
+       retv_if(!grid, 0);
+
+       count = elm_gengrid_items_count(grid);
+
+       return count;
+}
diff --git a/src/list.c b/src/list.c
new file mode 100644 (file)
index 0000000..12928ad
--- /dev/null
@@ -0,0 +1,99 @@
+/*
+ * Copyright (c) 2015 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * 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.
+ */
+
+#include <aul.h>
+#include <Elementary.h>
+#include <tizen.h>
+#include <rua.h>
+#include <rua_stat.h>
+
+#include "attach_panel.h"
+#include "attach_panel_internal.h"
+#include "conf.h"
+#include "log.h"
+
+
+
+static struct {
+       int ordering;
+} list_info = {
+       .ordering = 1,
+};
+
+static int __rua_stat_tag_iter_cb(const char *rua_stat_tag, void *data)
+{
+       Eina_List *content_list = data;
+       Eina_List *l = NULL;
+       Eina_List *ln = NULL;
+       content_s *content_info = NULL;
+
+       retv_if(!content_list, -1);
+       retv_if(!rua_stat_tag, -1);
+
+       _D("[Rua] %d : %s", list_info.ordering, rua_stat_tag);
+       EINA_LIST_FOREACH_SAFE(content_list, l, ln, content_info) {
+               continue_if(!content_info);
+               continue_if(!content_info->innate_content_info);
+               if (!strcmp(rua_stat_tag, content_info->innate_content_info->appid)) {
+                       content_info->order = list_info.ordering;
+                       list_info.ordering ++;
+               }
+       }
+
+       return 0;
+}
+
+
+
+static int __sort_cb(const void *d1, const void *d2)
+{
+       content_s *content_info1 = (content_s *) d1;
+       content_s *content_info2 = (content_s *) d2;
+
+       if (!content_info1 || !content_info1->innate_content_info) {
+               return 1;
+       }
+       if (!content_info2 || !content_info2->innate_content_info) {
+               return -1;
+       }
+       if (content_info1->innate_content_info->is_ug || content_info2->innate_content_info->is_ug) {
+               return -1;
+       }
+       if (content_info1->order < content_info2->order) {
+               return -1;
+       } else if (content_info1->order > content_info2->order) {
+               return 1;
+       } else {
+               return (strcmp(content_info1->innate_content_info->appid, content_info2->innate_content_info->appid));
+       }
+}
+
+
+
+Eina_List * _list_sort_by_rua(Eina_List *content_list)
+{
+       int ret = 0;
+
+       retv_if(!content_list, NULL);
+
+       list_info.ordering = 1;
+       ret = rua_stat_get_stat_tags("attach-panel", __rua_stat_tag_iter_cb, content_list);
+       retv_if(0 != ret, NULL);
+
+       content_list = eina_list_sort(content_list, eina_list_count(content_list), __sort_cb);
+
+       return content_list;
+}
diff --git a/src/page.c b/src/page.c
new file mode 100644 (file)
index 0000000..84e0c98
--- /dev/null
@@ -0,0 +1,94 @@
+/*
+ * Copyright (c) 2015 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * 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.
+ */
+
+#include <Elementary.h>
+
+#include "attach_panel.h"
+#include "attach_panel_internal.h"
+#include "conf.h"
+#include "log.h"
+#include "page.h"
+
+
+
+static const char *const PAGE_EDJE_FILE = EDJEDIR"/page.edj";
+
+
+
+Evas_Object *_page_create(attach_panel_h attach_panel, int width, int height)
+{
+       Evas_Object *page = NULL;
+       Evas_Object *page_bg = NULL;
+       Evas *e = NULL;
+
+       page = elm_layout_add(attach_panel->scroller);
+       retv_if(!page, NULL);
+       elm_layout_file_set(page, PAGE_EDJE_FILE, "page");
+
+       evas_object_size_hint_weight_set(page, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
+       evas_object_size_hint_align_set(page, EVAS_HINT_FILL, EVAS_HINT_FILL);
+
+       e = evas_object_evas_get(attach_panel->scroller);
+       goto_if(!e, ERROR);
+
+       page_bg = evas_object_rectangle_add(e);
+       goto_if(!page_bg, ERROR);
+       evas_object_size_hint_weight_set(page_bg, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
+       evas_object_size_hint_align_set(page_bg, EVAS_HINT_FILL, EVAS_HINT_FILL);
+       evas_object_size_hint_min_set(page_bg, width, height);
+       evas_object_color_set(page_bg, 0, 0, 0, 0);
+       evas_object_repeat_events_set(page_bg, EINA_TRUE);
+       evas_object_show(page_bg);
+       elm_object_part_content_set(page, "bg", page_bg);
+
+       evas_object_show(page);
+       return page;
+
+ERROR:
+       _page_destroy(page);
+       return NULL;
+}
+
+
+
+void _page_destroy(Evas_Object *page)
+{
+       Evas_Object *bg = NULL;
+
+       ret_if(!page);
+
+       bg = elm_object_part_content_unset(page, "bg");
+       if (bg) {
+               evas_object_del(bg);
+       }
+
+       evas_object_del(page);
+}
+
+
+
+void _page_resize(Evas_Object *page, int width, int height)
+{
+       Evas_Object *bg = NULL;
+
+       ret_if(!page);
+
+       bg = elm_object_part_content_get(page, "bg");
+       ret_if(!bg);
+
+       evas_object_size_hint_min_set(bg, width, height);
+       evas_object_size_hint_max_set(bg, width, height);
+}
diff --git a/src/scroller.c b/src/scroller.c
new file mode 100644 (file)
index 0000000..1af8cf1
--- /dev/null
@@ -0,0 +1,411 @@
+/*
+ * Copyright (c) 2015 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * 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.
+ */
+
+#include <Elementary.h>
+
+#include "attach_panel.h"
+#include "attach_panel_internal.h"
+#include "conf.h"
+#include "content_list.h"
+#include "log.h"
+#include "page.h"
+#include "scroller.h"
+
+
+
+static const char *const PRIVATE_DATA_KEY_SCROLLER_IS_SCROLLING = "p_is_sc";
+static const char *const PRIVATE_DATA_KEY_SCROLLER_DRAG_START = "p_dg_st";
+static const char *const PRIVATE_DATA_KEY_EVENT_CALLBACK_LIST = "pdkec";
+
+
+
+struct _event_cb {
+       int event_type;
+       void (*event_cb)(Evas_Object *scroller, int event_type, void *event_info, void *user_data);
+       void *user_data;
+};
+typedef struct _event_cb event_cb_s;
+
+
+
+int _scroller_is_scrolling(Evas_Object *scroller)
+{
+       retv_if(!scroller, 0);
+       return (int)evas_object_data_get(scroller, PRIVATE_DATA_KEY_SCROLLER_IS_SCROLLING);
+}
+
+
+
+static void __anim_start_cb(void *data, Evas_Object *scroller, void *event_info)
+{
+       _D("start the scroller(%p) animation", scroller);
+       evas_object_data_set(scroller, PRIVATE_DATA_KEY_SCROLLER_IS_SCROLLING, (void *)1);
+}
+
+
+
+static void __anim_stop_cb(void *data, Evas_Object *scroller, void *event_info)
+{
+       attach_panel_h attach_panel = data;
+
+       int index = 0;
+       int x = 0;
+       int page_w = 0;
+
+       ret_if(!attach_panel);
+       ret_if(!scroller);
+
+       _D("stop the scroller(%p) animation", scroller);
+       evas_object_data_del(scroller, PRIVATE_DATA_KEY_SCROLLER_IS_SCROLLING);
+       evas_object_data_del(scroller, PRIVATE_DATA_KEY_SCROLLER_DRAG_START);
+
+       elm_scroller_region_get(scroller, &x, NULL, NULL, NULL);
+       elm_scroller_page_size_get(scroller, &page_w, NULL);
+       ret_if(!page_w);
+
+       index = x / page_w;
+       x = x % page_w;
+       if (x != 0) {
+               return;
+       }
+
+       if (attach_panel->cur_page_no != index) {
+               _content_list_send_message_to_content(attach_panel->content_list, "__ATTACH_PANEL_SHOW_CONTENT_CATEGORY__", "false", attach_panel->cur_page_no);
+               _content_list_send_message_to_content(attach_panel->content_list, "__ATTACH_PANEL_SHOW_CONTENT_CATEGORY__", "true", index);
+               attach_panel->cur_page_no = index;
+               _D("change the show page : %d", index);
+       }
+}
+
+
+
+static void __drag_start_cb(void *data, Evas_Object *scroller, void *event_info)
+{
+       _D("start to drag the scroller(%p)", scroller);
+       evas_object_data_set(scroller, PRIVATE_DATA_KEY_SCROLLER_DRAG_START, (void *)1);
+}
+
+
+
+static void __drag_stop_cb(void *data, Evas_Object *scroller, void *event_info)
+{
+       _D("stop to drag the scroller(%p)", scroller);
+}
+
+
+
+static void __scroll_cb(void *data, Evas_Object *scroller, void *event_info)
+{
+       attach_panel_h attach_panel = data;
+       Elm_Object_Item *tabbar_item = NULL;
+       Eina_List *event_cb_list = NULL;
+       const Eina_List *l = NULL;
+       const Eina_List *ln = NULL;
+       content_s *info = NULL;
+       event_cb_s *event_cb_info = NULL;
+
+       int index = 0;
+       int i = 0;
+       int x = 0;
+       int page_w = 0;
+
+       ret_if(!attach_panel);
+       ret_if(!scroller);
+
+       if (!evas_object_data_get(scroller, PRIVATE_DATA_KEY_SCROLLER_DRAG_START))
+               return;
+
+       event_cb_list = evas_object_data_get(scroller, PRIVATE_DATA_KEY_EVENT_CALLBACK_LIST);
+       ret_if(!event_cb_list);
+
+       elm_scroller_region_get(scroller, &x, NULL, NULL, NULL);
+       elm_scroller_page_size_get(scroller, &page_w, NULL);
+       ret_if(!page_w);
+
+       index = x / page_w;
+       x = x % page_w;
+       if (x > (page_w / 2))
+               index++;
+
+       EINA_LIST_FOREACH(attach_panel->content_list, l, info) {
+               if (index == i) {
+                       tabbar_item = info->tabbar_item;
+                       attach_panel->cur_page_no = i;
+                       break;
+               }
+               i++;
+       }
+       ret_if(!tabbar_item);
+
+       EINA_LIST_FOREACH_SAFE(event_cb_list, l, ln, event_cb_info) {
+               if (SCROLLER_EVENT_TYPE_SCROLL == event_cb_info->event_type) {
+                       if (event_cb_info->event_cb) {
+                               event_cb_info->event_cb(scroller, SCROLLER_EVENT_TYPE_SCROLL, tabbar_item, event_cb_info->user_data);
+                       }
+               }
+       }
+}
+
+
+
+static void __resize_cb(void *data, Evas *e, Evas_Object *obj, void *event_info)
+{
+       Evas_Object *scroller = obj;
+       attach_panel_h attach_panel = data;
+
+       int x, y, w, h;
+       int screen_w = 0, screen_h = 0;
+
+       ret_if(!scroller);
+       ret_if(!attach_panel);
+
+       elm_win_screen_size_get(attach_panel->win, NULL, NULL, &screen_w, &screen_h);
+
+       evas_object_geometry_get(scroller, &x, &y, &w, &h);
+       _D("scroller resize(%d, %d, %d, %d)", x, y, w, h);
+
+       if (w == screen_w || w == screen_h) {
+               _D("screen size(%d, %d)", screen_w, screen_h);
+               elm_scroller_page_show(scroller, attach_panel->cur_page_no, 0);
+       }
+}
+
+
+
+Evas_Object *_scroller_create(Evas_Object *ui_manager, attach_panel_h attach_panel)
+{
+       Evas_Object *box = NULL;
+       Evas_Object *scroller = NULL;
+
+       retv_if(!ui_manager, NULL);
+       retv_if(!attach_panel, NULL);
+
+       scroller = elm_scroller_add(ui_manager);
+       retv_if(!scroller, NULL);
+
+       elm_scroller_bounce_set(scroller, EINA_TRUE, EINA_FALSE);
+       elm_scroller_policy_set(scroller, ELM_SCROLLER_POLICY_OFF, ELM_SCROLLER_POLICY_OFF);
+       elm_scroller_page_scroll_limit_set(scroller, 1, 1);
+       elm_scroller_content_min_limit(scroller, EINA_FALSE, EINA_TRUE);
+       elm_scroller_single_direction_set(scroller, ELM_SCROLLER_SINGLE_DIRECTION_HARD);
+
+       elm_scroller_page_size_set(scroller, attach_panel->transit_width, attach_panel->transit_height);
+       evas_object_size_hint_weight_set(scroller, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
+       evas_object_size_hint_min_set(scroller, 0, 0);
+
+       elm_object_style_set(scroller, "effect");
+       evas_object_show(scroller);
+       elm_object_scroll_lock_y_set(scroller, EINA_TRUE);
+
+       evas_object_smart_callback_add(scroller, "scroll,anim,start", __anim_start_cb, NULL);
+       evas_object_smart_callback_add(scroller, "scroll,anim,stop", __anim_stop_cb, attach_panel);
+       evas_object_smart_callback_add(scroller, "scroll,drag,start", __drag_start_cb, NULL);
+       evas_object_smart_callback_add(scroller, "scroll,drag,stop", __drag_stop_cb, NULL);
+       evas_object_smart_callback_add(scroller, "scroll", __scroll_cb, attach_panel);
+       evas_object_event_callback_add(scroller, EVAS_CALLBACK_RESIZE, __resize_cb, attach_panel);
+
+       box = elm_box_add(scroller);
+       goto_if(!box, ERROR);
+
+       elm_box_horizontal_set(box, EINA_TRUE);
+       elm_box_align_set(box, 0.5, 0.0);
+       evas_object_size_hint_weight_set(box, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
+       evas_object_show(box);
+
+       elm_object_content_set(scroller, box);
+       attach_panel->cur_page_no = 0;
+
+       return scroller;
+
+ERROR:
+       if (scroller) {
+               evas_object_del(scroller);
+       }
+       return NULL;
+}
+
+
+
+void _scroller_destroy(Evas_Object *scroller)
+{
+       Evas_Object *box = NULL;
+       ret_if(!scroller);
+
+       evas_object_event_callback_del(scroller, EVAS_CALLBACK_RESIZE, __resize_cb);
+       box = elm_object_content_unset(scroller);
+       if (box) {
+               evas_object_del(box);
+       }
+
+       evas_object_del(scroller);
+}
+
+
+
+void _scroller_append_page(Evas_Object *scroller, Evas_Object *page)
+{
+       Evas_Object *box = NULL;
+
+       box = elm_object_content_get(scroller);
+       ret_if(!box);
+
+       elm_box_pack_end(box, page);
+}
+
+
+
+void _scroller_remove_page(Evas_Object *scroller, Evas_Object *page)
+{
+       Evas_Object *box = NULL;
+       Evas_Object *tmp = NULL;
+       Eina_List *list = NULL;
+
+       int is_page_exist = 0;
+
+       box = elm_object_content_get(scroller);
+       ret_if(!box);
+
+       list = elm_box_children_get(box);
+       EINA_LIST_FREE(list, tmp) {
+               continue_if(!tmp);
+               if (page == tmp) {
+                       is_page_exist = 1;
+               }
+       }
+
+       if (!is_page_exist) {
+               _D("No page to remove");
+               return;
+       }
+
+       elm_box_unpack(box, page);
+}
+
+
+
+void _scroller_bring_in_page(Evas_Object *scroller, Evas_Object *page, int *cur_page_no)
+{
+       Evas_Object *box = NULL;
+       Evas_Object *tmp = NULL;
+       Eina_List *list = NULL;
+       int index = 0;
+       int exist = 1;
+
+       ret_if(!scroller);
+       ret_if(!page);
+
+       box = elm_object_content_get(scroller);
+       ret_if(!box);
+
+       list = elm_box_children_get(box);
+       ret_if(!list);
+
+       EINA_LIST_FREE(list, tmp) {
+               continue_if(!tmp);
+               if (page == tmp) {
+                       exist = 0;
+               }
+               index += exist;
+       }
+
+       if (exist) {
+               index = 0;
+       }
+
+       *cur_page_no = index;
+
+       elm_scroller_page_bring_in(scroller, index, 0);
+}
+
+
+
+void _scroller_resize(Evas_Object *scroller, int width, int height)
+{
+       Evas_Object *box = NULL;
+       Evas_Object *page = NULL;
+       Eina_List *list = NULL;
+
+       ret_if(!scroller);
+
+       elm_scroller_page_size_set(scroller, width, height);
+
+       box = elm_object_content_get(scroller);
+       ret_if(!box);
+
+       list = elm_box_children_get(box);
+       ret_if(!list);
+
+       EINA_LIST_FREE(list, page) {
+               _page_resize(page, width, height);
+       }
+       elm_box_recalculate(box);
+}
+
+
+
+int _scroller_register_event_cb(Evas_Object *scroller, int event_type, void (*event_cb)(Evas_Object *scroller, int event_type, void *event_info, void *user_data), void *user_data)
+{
+       Eina_List *event_cb_list = NULL;
+       event_cb_s *event_cb_info = NULL;
+
+       retv_if(!scroller, ATTACH_PANEL_ERROR_INVALID_PARAMETER);
+       retv_if(event_type <= SCROLLER_EVENT_TYPE_INVALID, ATTACH_PANEL_ERROR_INVALID_PARAMETER);
+       retv_if(event_type >= SCROLLER_EVENT_TYPE_MAX, ATTACH_PANEL_ERROR_INVALID_PARAMETER);
+       retv_if(!event_cb, ATTACH_PANEL_ERROR_INVALID_PARAMETER);
+
+       event_cb_info = calloc(1, sizeof(event_cb_s));
+       retv_if(!event_cb_info, ATTACH_PANEL_ERROR_OUT_OF_MEMORY);
+
+       event_cb_info->event_type = event_type;
+       event_cb_info->event_cb = event_cb;
+       event_cb_info->user_data = user_data;
+
+       event_cb_list = evas_object_data_get(scroller, PRIVATE_DATA_KEY_EVENT_CALLBACK_LIST);
+       event_cb_list = eina_list_append(event_cb_list, event_cb_info);
+       evas_object_data_set(scroller, PRIVATE_DATA_KEY_EVENT_CALLBACK_LIST, event_cb_list);
+
+       return ATTACH_PANEL_ERROR_NONE;
+}
+
+
+
+int _scroller_unregister_event_cb(Evas_Object *scroller, int event_type, void (*event_cb)(Evas_Object *scroller, int event_type, void *event_info, void *user_data))
+{
+       Eina_List *event_cb_list = NULL;
+       const Eina_List *l = NULL;
+       const Eina_List *ln = NULL;
+       event_cb_s *event_cb_info = NULL;
+
+       retv_if(!scroller, ATTACH_PANEL_ERROR_INVALID_PARAMETER);
+       retv_if(event_type <= SCROLLER_EVENT_TYPE_INVALID, ATTACH_PANEL_ERROR_INVALID_PARAMETER);
+       retv_if(event_type >= SCROLLER_EVENT_TYPE_MAX, ATTACH_PANEL_ERROR_INVALID_PARAMETER);
+       retv_if(!event_cb, ATTACH_PANEL_ERROR_INVALID_PARAMETER);
+
+       event_cb_list = evas_object_data_get(scroller, PRIVATE_DATA_KEY_EVENT_CALLBACK_LIST);
+       retv_if(!event_cb_list, ATTACH_PANEL_ERROR_NOT_INITIALIZED);
+
+       EINA_LIST_FOREACH_SAFE(event_cb_list, l, ln, event_cb_info) {
+               if (event_cb_info->event_type == event_type
+                       && event_cb_info->event_cb == event_cb) {
+                       event_cb_list = eina_list_remove(event_cb_list, event_cb_info);
+                       break;
+               }
+       }
+
+       evas_object_data_set(scroller, PRIVATE_DATA_KEY_EVENT_CALLBACK_LIST, event_cb_list);
+
+       return ATTACH_PANEL_ERROR_NONE;
+}
diff --git a/src/toolbar.c b/src/toolbar.c
new file mode 100644 (file)
index 0000000..173073e
--- /dev/null
@@ -0,0 +1,234 @@
+/*
+ * Copyright (c) 2015 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * 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.
+ */
+
+#include <Elementary.h>
+
+#include "attach_panel.h"
+#include "attach_panel_internal.h"
+#include "conf.h"
+#include "log.h"
+#include "toolbar.h"
+
+
+
+static const char *const PRIVATE_DATA_KEY_EVENT_CALLBACK_LIST = "pdkec";
+
+
+
+struct _event_cb {
+       int event_type;
+       void (*event_cb)(Evas_Object *toolbar, int event_type, void *event_info, void *user_data);
+       void *user_data;
+};
+typedef struct _event_cb event_cb_s;
+
+
+
+static void __resize_cb(void *data, Evas *e, Evas_Object *obj, void *event_info)
+{
+       Evas_Object *toolbar = obj;
+
+       int x, y, w, h;
+
+       ret_if(!toolbar);
+
+       evas_object_geometry_get(toolbar, &x, &y, &w, &h);
+       _D("toolbar resize(%d, %d, %d, %d)", x, y, w, h);
+}
+
+
+
+Evas_Object *_toolbar_create(Evas_Object *ui_manager, attach_panel_h attach_panel)
+{
+       Evas_Object *toolbar = NULL;
+
+       retv_if(!ui_manager, NULL);
+       retv_if(!attach_panel, NULL);
+
+       toolbar = elm_toolbar_add(ui_manager);
+       goto_if(!toolbar, ERROR);
+
+       /* This will expand the transverse(horizontal) length of items according to the length of toolbar */
+       elm_toolbar_transverse_expanded_set(toolbar, EINA_TRUE);
+       elm_toolbar_shrink_mode_set(toolbar, ELM_TOOLBAR_SHRINK_EXPAND);
+       elm_toolbar_homogeneous_set(toolbar, EINA_FALSE);
+       elm_toolbar_select_mode_set(toolbar, ELM_OBJECT_SELECT_MODE_ALWAYS);
+       elm_object_style_set(toolbar, "light_view");
+       elm_object_focus_set(toolbar, EINA_TRUE);
+
+       evas_object_show(toolbar);
+       evas_object_data_set(toolbar, DATA_KEY_ATTACH_PANEL_INFO, attach_panel);
+
+       evas_object_event_callback_add(toolbar, EVAS_CALLBACK_RESIZE, __resize_cb, NULL);
+
+       return toolbar;
+
+ERROR:
+       _toolbar_destroy(toolbar);
+       return NULL;
+}
+
+
+
+void _toolbar_destroy(Evas_Object *toolbar)
+{
+       attach_panel_h attach_panel = NULL;
+
+       ret_if(!toolbar);
+
+       attach_panel = evas_object_data_del(toolbar, DATA_KEY_ATTACH_PANEL_INFO);
+       ret_if(!attach_panel);
+
+       evas_object_event_callback_del(toolbar, EVAS_CALLBACK_RESIZE, __resize_cb);
+       evas_object_del(toolbar);
+}
+
+
+
+static void __view_changed_cb(void *user_data, Evas_Object *obj, void *event_info)
+{
+       Evas_Object *toolbar = obj;
+       Evas_Object *page = user_data;
+       Eina_List *event_cb_list = NULL;
+       const Eina_List *l = NULL;
+       const Eina_List *ln = NULL;
+       event_cb_s *event_cb_info = NULL;
+
+       ret_if(!toolbar);
+       ret_if(!page);
+
+       event_cb_list = evas_object_data_get(toolbar, PRIVATE_DATA_KEY_EVENT_CALLBACK_LIST);
+       ret_if(!event_cb_list);
+
+       EINA_LIST_FOREACH_SAFE(event_cb_list, l, ln, event_cb_info) {
+               if (TOOLBAR_EVENT_TYPE_CHANGE_TAB == event_cb_info->event_type) {
+                       if (event_cb_info->event_cb) {
+                               event_cb_info->event_cb(toolbar, TOOLBAR_EVENT_TYPE_CHANGE_TAB, page, event_cb_info->user_data);
+                       }
+               }
+       }
+}
+
+
+
+Elm_Object_Item *_toolbar_append_item(Evas_Object *toolbar, const char *tab_name, Evas_Object *page)
+{
+       Elm_Object_Item *tab_item = NULL;
+
+       retv_if(!toolbar, NULL);
+       retv_if(!tab_name, NULL);
+
+       tab_item = elm_toolbar_item_append(toolbar, NULL, tab_name, __view_changed_cb, page);
+       elm_object_item_domain_text_translatable_set(tab_item, PACKAGE, EINA_TRUE);
+       retv_if(!tab_item, NULL);
+
+       return tab_item;
+}
+
+
+
+void _toolbar_remove_item(Evas_Object *toolbar, Elm_Object_Item *tabbar_item)
+{
+       ret_if(!toolbar);
+       ret_if(!tabbar_item);
+
+       elm_object_item_del(tabbar_item);
+
+       /* If the selected item is removed, we have to activate the current */
+}
+
+
+
+void _toolbar_bring_in(Evas_Object *toolbar, Elm_Object_Item *tabbar_item)
+{
+       Elm_Object_Item *selected_item = NULL;
+
+       ret_if(!toolbar);
+       ret_if(!tabbar_item);
+
+       selected_item = elm_toolbar_selected_item_get(toolbar);
+       if (selected_item && selected_item == tabbar_item) {
+               return;
+       }
+
+       elm_toolbar_item_selected_set(tabbar_item, EINA_TRUE);
+       elm_object_focus_set(toolbar, EINA_TRUE);
+}
+
+
+
+unsigned int _toolbar_count_item(Evas_Object *toolbar)
+{
+       retv_if(!toolbar, 0);
+
+       return elm_toolbar_items_count(toolbar);
+}
+
+
+
+int _toolbar_register_event_cb(Evas_Object *toolbar, int event_type, void (*event_cb)(Evas_Object *toolbar, int event_type, void *event_info, void *user_data), void *user_data)
+{
+       Eina_List *event_cb_list = NULL;
+       event_cb_s *event_cb_info = NULL;
+
+       retv_if(!toolbar, ATTACH_PANEL_ERROR_INVALID_PARAMETER);
+       retv_if(event_type <= TOOLBAR_EVENT_TYPE_INVALID, ATTACH_PANEL_ERROR_INVALID_PARAMETER);
+       retv_if(event_type >= TOOLBAR_EVENT_TYPE_MAX, ATTACH_PANEL_ERROR_INVALID_PARAMETER);
+       retv_if(!event_cb, ATTACH_PANEL_ERROR_INVALID_PARAMETER);
+
+       event_cb_info = calloc(1, sizeof(event_cb_s));
+       retv_if(!event_cb_info, ATTACH_PANEL_ERROR_OUT_OF_MEMORY);
+
+       event_cb_info->event_type = event_type;
+       event_cb_info->event_cb = event_cb;
+       event_cb_info->user_data = user_data;
+
+       event_cb_list = evas_object_data_get(toolbar, PRIVATE_DATA_KEY_EVENT_CALLBACK_LIST);
+       event_cb_list = eina_list_append(event_cb_list, event_cb_info);
+       evas_object_data_set(toolbar, PRIVATE_DATA_KEY_EVENT_CALLBACK_LIST, event_cb_list);
+
+       return ATTACH_PANEL_ERROR_NONE;
+}
+
+
+
+int _toolbar_unregister_event_cb(Evas_Object *toolbar, int event_type, void (*event_cb)(Evas_Object *toolbar, int event_type, void *event_info, void *user_data))
+{
+       Eina_List *event_cb_list = NULL;
+       const Eina_List *l = NULL;
+       const Eina_List *ln = NULL;
+       event_cb_s *event_cb_info = NULL;
+
+       retv_if(!toolbar, ATTACH_PANEL_ERROR_INVALID_PARAMETER);
+       retv_if(event_type <= TOOLBAR_EVENT_TYPE_INVALID, ATTACH_PANEL_ERROR_INVALID_PARAMETER);
+       retv_if(event_type >= TOOLBAR_EVENT_TYPE_MAX, ATTACH_PANEL_ERROR_INVALID_PARAMETER);
+       retv_if(!event_cb, ATTACH_PANEL_ERROR_INVALID_PARAMETER);
+
+       event_cb_list = evas_object_data_get(toolbar, PRIVATE_DATA_KEY_EVENT_CALLBACK_LIST);
+       retv_if(!event_cb_list, ATTACH_PANEL_ERROR_NOT_INITIALIZED);
+
+       EINA_LIST_FOREACH_SAFE(event_cb_list, l, ln, event_cb_info) {
+               if (event_cb_info->event_type == event_type
+                       && event_cb_info->event_cb == event_cb) {
+                       event_cb_list = eina_list_remove(event_cb_list, event_cb_info);
+                       break;
+               }
+       }
+
+       evas_object_data_set(toolbar, PRIVATE_DATA_KEY_EVENT_CALLBACK_LIST, event_cb_list);
+
+       return ATTACH_PANEL_ERROR_NONE;
+}
diff --git a/src/ug.c b/src/ug.c
new file mode 100644 (file)
index 0000000..ddebc99
--- /dev/null
+++ b/src/ug.c
@@ -0,0 +1,237 @@
+/*
+ * Copyright (c) 2015 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * 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.
+ */
+
+#include <app_control.h>
+#include <bundle.h>
+#include <Elementary.h>
+#include <ui-gadget.h>
+
+#include "attach_panel.h"
+#include "attach_panel_internal.h"
+#include "attach_bundle.h"
+#include "content_list.h"
+#include "gesture.h"
+#include "log.h"
+
+
+
+static void __result_cb(ui_gadget_h ui_gadget, app_control_h result, void *priv)
+{
+       content_s *content_info = priv;
+       char *enable = NULL;
+       char **select = NULL;
+
+       int i = 0;
+       int length = 0;
+       int ret = 0;
+
+       ret_if(!content_info);
+
+       if (ATTACH_PANEL_STATE_HIDE == _gesture_get_state())
+               return;
+
+       ret = app_control_get_extra_data(result, "__ATTACH_PANEL_FLICK_DOWN__", &enable);
+       if (APP_CONTROL_ERROR_NONE == ret) {
+               ret_if(!enable);
+
+               _D("attach panel flick %s", enable);
+               if (!strcmp(enable, MODE_ENABLE)) {
+                       content_info->attach_panel->flick = EINA_TRUE;
+               } else if (!strcmp(enable, MODE_DISABLE)) {
+                       content_info->attach_panel->flick = EINA_FALSE;
+               } else {
+                       _E("__ATTACH_PANEL_FLICK_DOWN__ value is wrong type(%s)", enable);
+                       content_info->attach_panel->flick = EINA_TRUE;
+               }
+               return;
+       }
+
+       ret = app_control_get_extra_data(result, "__ATTACH_PANEL_FULL_MODE__", &enable);
+       if (APP_CONTROL_ERROR_NONE == ret) {
+               ret_if(!enable);
+
+               _D("attach panel full mode %s", enable);
+               if (!strcmp(enable, MODE_ENABLE)) {
+                       _gesture_set_full_mode(content_info->attach_panel);
+               } else {
+                       _E("__ATTACH_PANEL_FULL_MODE__ value is wrong type(%s)", enable);
+               }
+               return;
+       }
+
+       /* This can be called by clicking the 'Cancel' button on the UGs */
+       ret = app_control_get_extra_data(result, "__ATTACH_PANEL_SHOW_PANEL__", &enable);
+       if (APP_CONTROL_ERROR_NONE == ret) {
+               ret_if(!enable);
+
+               _D("attach panel show panel %s", enable);
+               if (!strcmp(enable, MODE_TRUE)) {
+                       if (ATTACH_PANEL_STATE_HIDE == _gesture_get_state()) {
+                               /* This is same with attach_panel_show() */
+                               _content_list_set_resume(content_info->attach_panel->content_list, ATTACH_PANEL_CONTENT_CATEGORY_UG);
+                               _content_list_send_message(content_info->attach_panel->content_list, "__ATTACH_PANEL_INITIALIZE__", MODE_ENABLE, ATTACH_PANEL_CONTENT_CATEGORY_UG);
+                               _gesture_show(content_info->attach_panel);
+                       }
+               } else {
+                       if (ATTACH_PANEL_STATE_HIDE != _gesture_get_state()) {
+                               /* This is same with attach_panel_hide() */
+                               _content_list_set_pause(content_info->attach_panel->content_list, ATTACH_PANEL_CONTENT_CATEGORY_UG);
+                               _gesture_hide(content_info->attach_panel);
+                       }
+               }
+               return;
+       }
+
+       /* This can be called on the state of recording video. */
+       ret = app_control_get_extra_data(result, "__ATTACH_PANEL_SHOW_TOOLBAR__", &enable);
+       if (APP_CONTROL_ERROR_NONE == ret) {
+               ret_if(!enable);
+
+               _D("attach panel show toolbar %s", enable);
+               if (!strcmp(enable, MODE_TRUE)) {
+                       elm_object_signal_emit(content_info->attach_panel->ui_manager, "toolbar,show", "toolbar");
+               } else {
+                       elm_object_signal_emit(content_info->attach_panel->ui_manager, "toolbar,hide", "toolbar");
+               }
+               return;
+       }
+
+       _D("The core of the panel sends the results to the caller");
+
+       /* This is just for protocol log */
+       _D("relay callback is called");
+       ret = app_control_get_extra_data_array(result, "http://tizen.org/appcontrol/data/selected", &select, &length);
+       if (APP_CONTROL_ERROR_NONE == ret && select) {
+               for (i = 0; i < length; i++) {
+                       _D("selected is %s[%d]", select[i], i);
+               }
+       }
+
+       ret = app_control_get_extra_data_array(result, "http://tizen.org/appcontrol/data/path", &select, &length);
+       if (APP_CONTROL_ERROR_NONE == ret && select) {
+               for (i = 0; i < length; i++) {
+                       _D("path is %s[%d]", select[i], i);
+               }
+       }
+
+       if (content_info->attach_panel->result_cb) {
+               content_info->attach_panel->result_cb(content_info->attach_panel
+                               , content_info->innate_content_info->content_category
+                               , result
+                               , APP_CONTROL_RESULT_SUCCEEDED
+                               , content_info->attach_panel->result_data);
+
+               if (ATTACH_PANEL_STATE_FULL == _gesture_get_state()) {
+                       /* This is same with attach_panel_hide() */
+                       _content_list_set_pause(content_info->attach_panel->content_list, ATTACH_PANEL_CONTENT_CATEGORY_UG);
+                       _gesture_hide(content_info->attach_panel);
+               }
+       } else {
+               _D("content_info->attach_panel->result_cb is NULL");
+       }
+}
+
+
+
+static void __resize_cb(void *data, Evas *e, Evas_Object *obj, void *event_info)
+{
+       Evas_Object *ui_manager = obj;
+
+       int x, y, w, h;
+
+       ret_if(!ui_manager);
+
+       evas_object_geometry_get(ui_manager, &x, &y, &w, &h);
+       _D("%s resize(%d, %d, %d, %d)", data, x, y, w, h);
+}
+
+
+
+Evas_Object *_ug_create(const char *appid, const char *operation, const char *selection_mode, const char *mime, bundle *b, content_s *content_info)
+{
+       app_control_h app_control = NULL;
+       ui_gadget_h ui_gadget = NULL;
+       Evas_Object *ug = NULL;
+       struct ug_cbs cbs = {
+               .layout_cb = NULL,
+               .result_cb = __result_cb,
+               .destroy_cb = NULL,
+               .priv = content_info,
+       };
+       int ret = APP_CONTROL_ERROR_NONE;
+
+       ret = app_control_create(&app_control);
+       goto_if(APP_CONTROL_ERROR_NONE != ret, ERROR);
+
+       ret = app_control_set_operation(app_control, operation);
+       goto_if(APP_CONTROL_ERROR_NONE != ret, ERROR);
+
+       ret = app_control_add_extra_data(app_control, "__CALLER_PANEL__", "attach-panel");
+       goto_if(APP_CONTROL_ERROR_NONE != ret, ERROR);
+
+       ret = app_control_add_extra_data(app_control, APP_CONTROL_DATA_SELECTION_MODE, selection_mode);
+       goto_if(APP_CONTROL_ERROR_NONE != ret, ERROR);
+
+       if (mime) {
+               ret = app_control_set_mime(app_control, mime);
+               goto_if(APP_CONTROL_ERROR_NONE != ret, ERROR);
+       }
+
+       if (b) {
+               _D("app control add the extra data for ug");
+               _bundle_add_to_app_control(b, app_control);
+       }
+
+       ui_gadget = ug_create(NULL, appid, UG_MODE_FRAMEVIEW, app_control, &cbs);
+       if (!ui_gadget) {
+               _E("The UG of %s is failed to launch", appid);
+               goto ERROR;
+       }
+
+       ug = ug_get_layout(ui_gadget);
+       goto_if(!ug, ERROR);
+
+       evas_object_show(ug);
+       evas_object_data_set(ug, DATA_KEY_UG, ui_gadget);
+       evas_object_event_callback_add(ug, EVAS_CALLBACK_RESIZE, __resize_cb, "ug");
+
+       ret = app_control_destroy(app_control);
+       if (APP_CONTROL_ERROR_NONE != ret) {
+               _E("cannot destroy app_control");
+       }
+
+       return ug;
+
+ERROR:
+       if (app_control) app_control_destroy(app_control);
+
+       return NULL;
+}
+
+
+
+void _ug_destroy(Evas_Object *ug)
+{
+       ui_gadget_h ui_gadget = NULL;
+
+       ret_if(!ug);
+
+       evas_object_event_callback_del(ug, EVAS_CALLBACK_RESIZE, __resize_cb);
+       ui_gadget = evas_object_data_del(ug, DATA_KEY_UG);
+       ret_if(!ui_gadget);
+
+       ug_destroy(ui_gadget);
+}
diff --git a/src/ui_manager.c b/src/ui_manager.c
new file mode 100644 (file)
index 0000000..1a24276
--- /dev/null
@@ -0,0 +1,531 @@
+/*
+ * Copyright (c) 2015 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * 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.
+ */
+
+#include <Elementary.h>
+#include <bundle.h>
+#include <efl_extension.h>
+#include <ui-gadget.h>
+#include <ui-gadget-module.h>
+
+#include "attach_panel.h"
+#include "attach_panel_internal.h"
+#include "conf.h"
+#include "content_list.h"
+#include "gesture.h"
+#include "list.h"
+#include "log.h"
+#include "page.h"
+#include "scroller.h"
+#include "toolbar.h"
+#include "ug.h"
+#include "grid.h"
+
+
+
+static const char *const FILE_LAYOUT_EDJ = EDJEDIR"/layout.edj";
+static const char *const GROUP_LAYOUT = "layout";
+
+
+
+Evas_Object *_ui_manager_create_content(Evas_Object *page, content_s *content_info, attach_panel_h attach_panel)
+{
+       Evas_Object *content = NULL;
+       Elm_Object_Item *item = NULL;
+
+       retv_if(!page, NULL);
+       retv_if(!content_info, NULL);
+       retv_if(!attach_panel, NULL);
+
+       switch (content_info->innate_content_info->content_category) {
+       case ATTACH_PANEL_CONTENT_CATEGORY_IMAGE:
+       case ATTACH_PANEL_CONTENT_CATEGORY_CAMERA:
+       case ATTACH_PANEL_CONTENT_CATEGORY_VOICE:
+               content = _ug_create(content_info->innate_content_info->appid
+                                               , content_info->innate_content_info->operation
+                                               , content_info->innate_content_info->selection_mode
+                                               , content_info->innate_content_info->mime
+                                               , content_info->extra_data
+                                               , content_info);
+               evas_object_show(content);
+               content_info->grid_item = NULL;
+               break;
+       default:
+               /* This function can return NULL, if there is already a grid content */
+               if (attach_panel->grid) {
+                       content = attach_panel->grid;
+               } else {
+                       content = _grid_create(page, attach_panel);
+                       attach_panel->grid = content;
+               }
+
+               item = _grid_append_item(attach_panel->grid, content_info);
+               break_if(!item);
+
+               break;
+       }
+
+       evas_object_size_hint_weight_set(content, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
+       elm_object_part_content_set(page, "content", content);
+
+       evas_object_data_set(content, DATA_KEY_PAGE, page);
+
+       return content;
+}
+
+
+
+void _ui_manager_destroy_content(content_s *content_info, attach_panel_h attach_panel)
+{
+       ret_if(!content_info->content);
+       ret_if(!attach_panel);
+
+       evas_object_data_del(content_info->content, DATA_KEY_PAGE);
+
+       switch (content_info->innate_content_info->content_category) {
+       case ATTACH_PANEL_CONTENT_CATEGORY_IMAGE:
+       case ATTACH_PANEL_CONTENT_CATEGORY_CAMERA:
+       case ATTACH_PANEL_CONTENT_CATEGORY_VOICE:
+               _ug_destroy(content_info->content);
+               break;
+       default:
+               _grid_remove_item(attach_panel->grid, content_info);
+
+               if (!_grid_count_item(attach_panel->grid)) {
+                       _grid_destroy(attach_panel->grid);
+                       attach_panel->grid = NULL;
+               }
+
+               break;
+       }
+}
+
+
+
+int _ui_manager_append_content_category(Evas_Object *ui_manager, innate_content_s *innate_content_info, bundle *extra_data)
+{
+       attach_panel_h attach_panel = NULL;
+       content_s *content_info = NULL;
+       Evas_Object *page = NULL;
+
+       retv_if(!ui_manager, ATTACH_PANEL_ERROR_INVALID_PARAMETER);
+       retv_if(!innate_content_info, ATTACH_PANEL_ERROR_INVALID_PARAMETER);
+
+       attach_panel = evas_object_data_get(ui_manager, DATA_KEY_ATTACH_PANEL_INFO);
+       retv_if(!attach_panel, ATTACH_PANEL_ERROR_INVALID_PARAMETER);
+
+       content_info = calloc(1, sizeof(content_s));
+       retv_if(!content_info, ATTACH_PANEL_ERROR_OUT_OF_MEMORY);
+       content_info->attach_panel = attach_panel;
+       content_info->innate_content_info = innate_content_info;
+       content_info->extra_data = extra_data;
+       content_info->order = ORDER_MAX;
+
+       if (innate_content_info->is_ug) {
+               /* UG side */
+               page = _page_create(attach_panel, attach_panel->transit_width, 0);
+               goto_if(!page, ERROR);
+               _scroller_append_page(attach_panel->scroller, page);
+
+               content_info->tabbar_item =
+                       _toolbar_append_item(attach_panel->toolbar, innate_content_info->name, page);
+               goto_if(!content_info->tabbar_item, ERROR);
+               content_info->content = NULL;
+               content_info->order = 0;
+       } else {
+               /* App side */
+               if (attach_panel->grid) {
+                       /* Grid */
+                       page = attach_panel->grid_page;
+                       content_info->tabbar_item = attach_panel->grid_tabbar_item;
+               } else {
+                       /* No grid */
+                       Evas_Object *page_bg = NULL;
+                       page = _page_create(attach_panel, attach_panel->transit_width, 0);
+                       page_bg = elm_object_part_content_get(page, "bg");
+                       if (page_bg) {
+                               evas_object_color_set(page_bg, 250, 250, 250, 255);
+                       }
+                       attach_panel->grid_page = page;
+                       goto_if(!page, ERROR);
+                       _scroller_append_page(attach_panel->scroller, page);
+
+                       content_info->tabbar_item = _toolbar_append_item(attach_panel->toolbar, content_info->innate_content_info->tabbar_name, page);
+                       attach_panel->grid_tabbar_item = content_info->tabbar_item;
+                       goto_if(!content_info->tabbar_item, ERROR);
+               }
+               content_info->content = _ui_manager_create_content(page, content_info, attach_panel);
+               goto_if(!content_info->content, ERROR);
+               elm_object_part_content_set(page, "content", content_info->content);
+       }
+
+       content_info->page = page;
+
+       if (1 == _toolbar_count_item(attach_panel->toolbar)) {
+               _toolbar_bring_in(attach_panel->toolbar, content_info->tabbar_item);
+       }
+
+       attach_panel->content_list = eina_list_append(attach_panel->content_list, content_info);
+       content_info->index = eina_list_count(attach_panel->content_list) - 1;
+
+       return ATTACH_PANEL_ERROR_NONE;
+
+ERROR:
+       if (content_info->tabbar_item) _toolbar_remove_item(attach_panel->toolbar, content_info->tabbar_item);
+       if (content_info->content) _ui_manager_destroy_content(content_info, attach_panel);
+       if (page) _page_destroy(page);
+       free(content_info);
+
+       return ATTACH_PANEL_ERROR_NOT_INITIALIZED;
+}
+
+
+
+void _ui_manager_remove_content_category(Evas_Object *ui_manager, content_s *content_info)
+{
+       attach_panel_h attach_panel = NULL;
+
+       ret_if(!ui_manager);
+       ret_if(!content_info);
+
+       attach_panel = evas_object_data_get(ui_manager, DATA_KEY_ATTACH_PANEL_INFO);
+       ret_if(!attach_panel);
+
+       _ui_manager_destroy_content(content_info, attach_panel);
+
+       if (content_info->innate_content_info->is_ug
+               || !attach_panel->grid) {
+               Evas_Object *page = evas_object_data_get(content_info->content, DATA_KEY_PAGE);
+               if (page) {
+                       _page_destroy(page);
+               }
+               _toolbar_remove_item(attach_panel->toolbar, content_info->tabbar_item);
+       }
+
+       attach_panel->content_list = eina_list_remove(attach_panel->content_list, content_info);
+       free(content_info);
+}
+
+
+
+static void __remove_content_categories(Evas_Object *ui_manager)
+{
+       attach_panel_h attach_panel = NULL;
+       content_s *content_info = NULL;
+
+       ret_if(!ui_manager);
+
+       attach_panel = evas_object_data_get(ui_manager, DATA_KEY_ATTACH_PANEL_INFO);
+       ret_if(!attach_panel);
+
+       EINA_LIST_FREE(attach_panel->content_list, content_info) {
+               Evas_Object *page = NULL;
+
+               _ui_manager_destroy_content(content_info, attach_panel);
+               page= evas_object_data_get(content_info->content, DATA_KEY_PAGE);
+               if (page) {
+                       elm_object_part_content_unset(page, "content");
+                       _page_destroy(page);
+               }
+               _toolbar_remove_item(attach_panel->toolbar, content_info->tabbar_item);
+               free(content_info);
+       }
+}
+
+
+
+static void __resize_cb(void *data, Evas *e, Evas_Object *obj, void *event_info)
+{
+       Evas_Object *ui_manager = obj;
+       Evas_Coord x = 0;
+       Evas_Coord y = 0;
+       Evas_Coord w = 0;
+       Evas_Coord h = 0;
+
+       ret_if(!ui_manager);
+
+       evas_object_geometry_get(ui_manager, &x, &y, &w, &h);
+       _D("ui_manager resize(%d, %d, %d, %d)", x, y, w, h);
+}
+
+
+
+static void _change_tab_cb(Evas_Object *toolbar, int event_type, void *event_info, void *data)
+{
+       attach_panel_h attach_panel = data;
+       Evas_Object *page = event_info;
+       content_s *content_info = NULL;
+
+       ret_if(!attach_panel);
+       ret_if(!attach_panel->toolbar);
+       ret_if(!attach_panel->scroller);
+       ret_if(!page);
+
+       content_info = eina_list_nth(attach_panel->content_list, attach_panel->cur_page_no);
+       ret_if(!content_info);
+       ret_if(!content_info->innate_content_info);
+
+       if (EINA_TRUE == attach_panel->is_delete) {
+               _D("This is attach_panel_destroy");
+               return;
+       }
+
+       if (page == content_info->page) {
+               _D("Tab the same page");
+               return;
+       }
+
+       if (ATTACH_PANEL_STATE_HIDE == _gesture_get_state()) {
+               _D("state of attach_panel is hide state");
+               return;
+       }
+
+       /* TODO : destroy the ug when page is not shown
+
+       if (content_info->innate_content_info->is_ug) {
+               _ui_manager_destroy_content(content_info, attach_panel);
+               content_info->content = NULL;
+       } */
+
+       _scroller_bring_in_page(attach_panel->scroller, page, &attach_panel->cur_page_no);
+       content_info = eina_list_nth(attach_panel->content_list, attach_panel->cur_page_no);
+       ret_if(!content_info);
+       ret_if(!content_info->innate_content_info);
+
+       if (!content_info->innate_content_info->is_ug) {
+               return;
+       }
+
+       if (content_info->content) {
+               return;
+       }
+
+       _D("change tab for create ug (%s)", content_info->innate_content_info->appid);
+
+       content_info->content = _ui_manager_create_content(content_info->page, content_info, attach_panel);
+       ret_if(!content_info->content);
+       if (ATTACH_PANEL_STATE_FULL == _gesture_get_state()) {
+               _content_list_send_message(attach_panel->content_list, APP_CONTROL_DATA_SELECTION_MODE, SELECTION_MODE_MULTIPLE, ATTACH_PANEL_CONTENT_CATEGORY_UG);
+       } else {
+               _content_list_send_message(attach_panel->content_list, APP_CONTROL_DATA_SELECTION_MODE, SELECTION_MODE_SINGLE, ATTACH_PANEL_CONTENT_CATEGORY_UG);
+       }
+}
+
+
+
+static void _scroll_cb(Evas_Object *scroller, int event_type, void *event_info, void *data)
+{
+       attach_panel_h attach_panel = data;
+       Elm_Object_Item *tabbar_item = event_info;
+
+       ret_if(!attach_panel);
+       ret_if(!attach_panel->toolbar);
+       ret_if(!tabbar_item);
+
+       _toolbar_bring_in(attach_panel->toolbar, tabbar_item);
+}
+
+
+
+static void __window_resume_cb(void *data, Evas_Object *scroller, void *event_info)
+{
+       attach_panel_h attach_panel = data;
+       ret_if(!attach_panel);
+
+       if (ATTACH_PANEL_STATE_HIDE == _gesture_get_state()) {
+               _D("attach panel is already hide");
+               return;
+       }
+
+       _D("caller window is resumed");
+       _content_list_set_resume(attach_panel->content_list, ATTACH_PANEL_CONTENT_CATEGORY_UG);
+
+       attach_panel->content_list = _list_sort_by_rua(attach_panel->content_list);
+       _grid_refresh(attach_panel->grid);
+}
+
+
+
+static void __window_pause_cb(void *data, Evas_Object *scroller, void *event_info)
+{
+       attach_panel_h attach_panel = data;
+       ret_if(!attach_panel);
+
+       if (ATTACH_PANEL_STATE_HIDE == _gesture_get_state()) {
+               _D("attach panel is already hide");
+               return;
+       }
+
+       _D("caller window is paused");
+       _content_list_set_pause(attach_panel->content_list, ATTACH_PANEL_CONTENT_CATEGORY_UG);
+}
+
+
+
+static void __lang_changed_cb(void *data, Evas_Object *obj, void *event_info)
+{
+       _D("language changed");
+       ug_send_event(UG_EVENT_LANG_CHANGE);
+}
+
+
+
+static void __keypad_on_cb(void *data, Evas_Object *obj, void *event_info)
+{
+       attach_panel_h attach_panel = data;
+       ret_if(!attach_panel);
+
+       _D("keypad state on");
+
+       if (ATTACH_PANEL_STATE_HIDE == _gesture_get_state()) {
+               _D("attach panel is already hide");
+               return;
+       }
+       /* This is same with attach_panel_hide */
+       _content_list_set_pause(attach_panel->content_list, ATTACH_PANEL_CONTENT_CATEGORY_UG);
+       _gesture_hide(attach_panel);
+}
+
+
+
+static void __key_back_cb(void *data, Evas_Object *obj, void *event_info)
+{
+       attach_panel_h attach_panel = data;
+       ret_if(!attach_panel);
+
+       if (ATTACH_PANEL_STATE_HIDE == _gesture_get_state()) {
+               _D("attach panel is already hide");
+               return;
+       }
+       /* This is same with attach_panel_hide() */
+       _content_list_set_pause(attach_panel->content_list, ATTACH_PANEL_CONTENT_CATEGORY_UG);
+       _gesture_hide(attach_panel);
+}
+
+
+
+Evas_Object *_ui_manager_create(attach_panel_h attach_panel)
+{
+       Evas_Object *ui_manager = NULL;
+       Evas_Object *parent = NULL;
+       int ret = ATTACH_PANEL_ERROR_NONE;
+
+       retv_if(!attach_panel, NULL);
+       retv_if(!attach_panel->conformant, NULL);
+
+       ui_manager = elm_layout_add(attach_panel->conformant);
+       retv_if(!ui_manager, NULL);
+       elm_layout_file_set(ui_manager, FILE_LAYOUT_EDJ, GROUP_LAYOUT);
+       evas_object_size_hint_weight_set(ui_manager, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
+       evas_object_size_hint_align_set(ui_manager, EVAS_HINT_FILL, 1.0);
+       evas_object_show(ui_manager);
+
+       evas_object_data_set(ui_manager, DATA_KEY_ATTACH_PANEL_INFO, attach_panel);
+       evas_object_event_callback_add(ui_manager, EVAS_CALLBACK_RESIZE, __resize_cb, NULL);
+
+       attach_panel->toolbar = _toolbar_create(ui_manager, attach_panel);
+       goto_if(!attach_panel->toolbar, ERROR);
+       elm_object_part_content_set(ui_manager, "toolbar", attach_panel->toolbar);
+
+       ret = _toolbar_register_event_cb(attach_panel->toolbar, TOOLBAR_EVENT_TYPE_CHANGE_TAB, _change_tab_cb, attach_panel);
+       goto_if(ATTACH_PANEL_ERROR_NONE != ret, ERROR);
+
+       attach_panel->scroller = _scroller_create(ui_manager, attach_panel);
+       goto_if(!attach_panel->scroller, ERROR);
+       elm_object_part_content_set(ui_manager, "scroller", attach_panel->scroller);
+
+       ret = _scroller_register_event_cb(attach_panel->scroller, SCROLLER_EVENT_TYPE_SCROLL, _scroll_cb, attach_panel);
+       goto_if(ATTACH_PANEL_ERROR_NONE != ret, ERROR);
+
+       parent = attach_panel->conformant;
+       do {
+               const char *type = NULL;
+
+               parent = elm_object_parent_widget_get(parent);
+               break_if(!parent);
+
+               type = elm_object_widget_type_get(parent);
+               continue_if(!type);
+               if (!strcmp(type, "Elm_Win")) {
+                       UG_INIT_EFL(parent, UG_OPT_INDICATOR_DISABLE);
+                       attach_panel->win = parent;
+                       break;
+               }
+       } while (parent);
+
+       evas_object_smart_callback_add(parent, "normal", __window_resume_cb, attach_panel);
+       evas_object_smart_callback_add(parent, "iconified", __window_pause_cb, attach_panel);
+       evas_object_smart_callback_add(attach_panel->conformant, "language,changed", __lang_changed_cb, NULL);
+       evas_object_smart_callback_add(attach_panel->conformant, "virtualkeypad,state,on", __keypad_on_cb, attach_panel);
+       eext_object_event_callback_add(ui_manager, EEXT_CALLBACK_BACK, __key_back_cb, attach_panel);
+
+       return ui_manager;
+
+ERROR:
+       if (attach_panel->toolbar) {
+               _toolbar_destroy(attach_panel->toolbar);
+       }
+
+       if (ui_manager) {
+               evas_object_del(ui_manager);
+       }
+
+       return NULL;
+}
+
+
+
+void _ui_manager_destroy(Evas_Object *ui_manager)
+{
+       attach_panel_h attach_panel = NULL;
+       int ret = ATTACH_PANEL_ERROR_NONE;
+
+       __remove_content_categories(ui_manager);
+
+       /* attach_panel_h is used in the __remove_content_categories */
+       attach_panel = evas_object_data_del(ui_manager, DATA_KEY_ATTACH_PANEL_INFO);
+       ret_if(!attach_panel);
+
+       eext_object_event_callback_del(ui_manager, EEXT_CALLBACK_BACK, __key_back_cb);
+       evas_object_smart_callback_del(attach_panel->conformant, "virtualkeypad,state,on", __keypad_on_cb);
+       evas_object_smart_callback_del(attach_panel->conformant, "language,changed", __lang_changed_cb);
+       evas_object_event_callback_del(ui_manager, EVAS_CALLBACK_RESIZE, __resize_cb);
+       if (attach_panel->win) {
+               evas_object_smart_callback_del(attach_panel->win, "normal", __window_resume_cb);
+               evas_object_smart_callback_del(attach_panel->win, "iconified", __window_pause_cb);
+       }
+
+       if (attach_panel->scroller) {
+               ret = _scroller_unregister_event_cb(attach_panel->scroller, SCROLLER_EVENT_TYPE_SCROLL, _scroll_cb);
+               if (ATTACH_PANEL_ERROR_NONE != ret) {
+                       _E("cannot unregiter event_cb for scroller");
+               }
+               elm_object_part_content_unset(ui_manager, "scroller");
+               _scroller_destroy(attach_panel->scroller);
+       }
+
+       if (attach_panel->toolbar) {
+               ret = _toolbar_unregister_event_cb(attach_panel->toolbar, TOOLBAR_EVENT_TYPE_CHANGE_TAB, _change_tab_cb);
+               if (ATTACH_PANEL_ERROR_NONE != ret) {
+                       _E("cannot unregiter event_cb for toolbar");
+               }
+               elm_object_part_content_unset(ui_manager, "toolbar");
+               _toolbar_destroy(attach_panel->toolbar);
+       }
+
+       if (attach_panel->ui_manager) {
+               evas_object_del(ui_manager);
+       }
+}