summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKim Kibum <kb0929.kim@samsung.com>2012-06-08 05:54:17 (GMT)
committerKim Kibum <kb0929.kim@samsung.com>2012-06-08 05:54:17 (GMT)
commitd14111b6d5b7914cc0742d1d5dcc415cd95c7bb1 (patch)
treefc8a938536667eb8bfb8d56fb524e2e077d3bf89
parent664bf974ba4e7c3ed0b9dbd16eab4e14f813d6a4 (diff)
downloadug-myfile-efl-d14111b6d5b7914cc0742d1d5dcc415cd95c7bb1.zip
ug-myfile-efl-d14111b6d5b7914cc0742d1d5dcc415cd95c7bb1.tar.gz
ug-myfile-efl-d14111b6d5b7914cc0742d1d5dcc415cd95c7bb1.tar.bz2
apply FSL(Flora Software License)
-rw-r--r--CMakeLists.txt99
-rw-r--r--LICENSE75
-rwxr-xr-xNOTICE1
-rw-r--r--debian/changelog7
-rw-r--r--debian/compat1
-rw-r--r--debian/control31
-rw-r--r--debian/copyright0
-rw-r--r--debian/libug-myfile-efl.install.in3
-rwxr-xr-xdebian/rules127
-rw-r--r--icons/01_myfile_add_icon.pngbin0 -> 256 bytes
-rw-r--r--icons/06_myfiles_list_folder.pngbin0 -> 1729 bytes
-rw-r--r--icons/34_control_pause.pngbin0 -> 3013 bytes
-rw-r--r--icons/34_control_play.pngbin0 -> 3032 bytes
-rw-r--r--icons/47_myfiles_icon_excel.pngbin0 -> 5986 bytes
-rw-r--r--icons/47_myfiles_icon_folder.pngbin0 -> 4067 bytes
-rw-r--r--icons/47_myfiles_icon_folder_created.pngbin0 -> 4170 bytes
-rw-r--r--icons/47_myfiles_icon_folder_sinced.pngbin0 -> 4525 bytes
-rw-r--r--icons/47_myfiles_icon_html.pngbin0 -> 6416 bytes
-rw-r--r--icons/47_myfiles_icon_music.pngbin0 -> 7531 bytes
-rw-r--r--icons/47_myfiles_icon_pause_focus.pngbin0 -> 2908 bytes
-rw-r--r--icons/47_myfiles_icon_pdf.pngbin0 -> 4794 bytes
-rw-r--r--icons/47_myfiles_icon_play_focus.pngbin0 -> 3179 bytes
-rw-r--r--icons/47_myfiles_icon_ppt.pngbin0 -> 5417 bytes
-rw-r--r--icons/47_myfiles_icon_ring_tone.pngbin0 -> 8576 bytes
-rw-r--r--icons/47_myfiles_icon_rss.pngbin0 -> 5082 bytes
-rw-r--r--icons/47_myfiles_icon_swf.pngbin0 -> 5653 bytes
-rw-r--r--icons/47_myfiles_icon_text.pngbin0 -> 4023 bytes
-rw-r--r--icons/47_myfiles_icon_upper_folder_black_theme.pngbin0 -> 3197 bytes
-rw-r--r--icons/47_myfiles_icon_upper_folder_focus.pngbin0 -> 3134 bytes
-rw-r--r--icons/47_myfiles_icon_upper_folder_white_theme.pngbin0 -> 348 bytes
-rw-r--r--icons/47_myfiles_icon_video.pngbin0 -> 8062 bytes
-rw-r--r--icons/47_myfiles_icon_word.pngbin0 -> 5865 bytes
-rw-r--r--icons/60_myfiles_file_amr.pngbin0 -> 2022 bytes
-rw-r--r--icons/60_myfiles_file_etc.pngbin0 -> 1292 bytes
-rw-r--r--icons/60_myfiles_icon_images.pngbin0 -> 1454 bytes
-rw-r--r--icons/60_myfiles_icon_java.pngbin0 -> 3005 bytes
-rw-r--r--icons/60_myfiles_icon_music_default.pngbin0 -> 1770 bytes
-rw-r--r--icons/60_myfiles_icon_vText.pngbin0 -> 1350 bytes
-rw-r--r--icons/60_myfiles_icon_vcalender.pngbin0 -> 1706 bytes
-rw-r--r--icons/60_myfiles_icon_vcard.pngbin0 -> 1606 bytes
-rw-r--r--icons/60_myfiles_memorycard.pngbin0 -> 3006 bytes
-rw-r--r--icons/60_myfiles_memorycard_sub.pngbin0 -> 691 bytes
-rw-r--r--icons/60_myfiles_phone.pngbin0 -> 3028 bytes
-rw-r--r--icons/U01_icon_USB.pngbin0 -> 3891 bytes
-rw-r--r--icons/myfile_icon_add.pngbin0 -> 2999 bytes
-rw-r--r--packaging/ug-myfile-efl.spec47
-rw-r--r--po/CMakeLists.txt24
-rw-r--r--po/POTFILES.in17
-rw-r--r--po/de.po120
-rw-r--r--po/de_DE.po158
-rw-r--r--po/el.po120
-rw-r--r--po/el_GR.po159
-rw-r--r--po/en.po159
-rw-r--r--po/en_GB.po46
-rw-r--r--po/en_US.po94
-rw-r--r--po/es.po120
-rw-r--r--po/es_ES.po158
-rw-r--r--po/fr.po120
-rw-r--r--po/fr_FR.po158
-rw-r--r--po/it.po120
-rw-r--r--po/it_IT.po158
-rw-r--r--po/ja.po137
-rw-r--r--po/ja_JP.po159
-rw-r--r--po/ko.po155
-rw-r--r--po/ko_KR.po158
-rw-r--r--po/nl.po120
-rw-r--r--po/nl_NL.po158
-rw-r--r--po/pt.po120
-rw-r--r--po/pt_PT.po158
-rw-r--r--po/ru.po120
-rw-r--r--po/ru_RU.po158
-rw-r--r--po/tk.po120
-rw-r--r--po/tr_TR.po159
-rw-r--r--po/ug-myfile-efl.pot94
-rw-r--r--po/update-po.sh57
-rw-r--r--po/zh_CN.po158
-rw-r--r--po/zh_HK.po158
-rw-r--r--po/zh_TW.po158
-rwxr-xr-xsrc/common/file-system/mf-ug-file-attr.c1072
-rwxr-xr-xsrc/common/file-system/mf-ug-fs-oper.c381
-rwxr-xr-xsrc/common/mf-ug-cb.c1052
-rwxr-xr-xsrc/common/mf-ug-fm-svc-wapper.c547
-rwxr-xr-xsrc/common/mf-ug-inotify-handle.c348
-rwxr-xr-xsrc/common/mf-ug-list-play.c989
-rwxr-xr-xsrc/common/mf-ug-util.c729
-rwxr-xr-xsrc/include/mf-ug-cb.h50
-rwxr-xr-xsrc/include/mf-ug-conf.h79
-rwxr-xr-xsrc/include/mf-ug-dlog.h84
-rwxr-xr-xsrc/include/mf-ug-fm-svc-wrapper.h41
-rwxr-xr-xsrc/include/mf-ug-fs-util.h257
-rwxr-xr-xsrc/include/mf-ug-inotify-handle.h44
-rwxr-xr-xsrc/include/mf-ug-main.h147
-rwxr-xr-xsrc/include/mf-ug-resource.h41
-rwxr-xr-xsrc/include/mf-ug-util.h201
-rwxr-xr-xsrc/include/mf-ug-winset.h129
-rwxr-xr-xsrc/mf-ug-main.c1137
-rwxr-xr-xsrc/widget/mf-ug-ctrl-bar.c277
-rwxr-xr-xsrc/widget/mf-ug-genlist.c1365
-rwxr-xr-xsrc/widget/mf-ug-navi-bar.c794
-rwxr-xr-xsrc/widget/mf-ug-popup.c95
-rwxr-xr-xsrc/widget/mf-ug-tab-bar.c251
-rwxr-xr-xug_navibar_layout.edc448
102 files changed, 15027 insertions, 0 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
new file mode 100644
index 0000000..136fb81
--- /dev/null
+++ b/CMakeLists.txt
@@ -0,0 +1,99 @@
+CMAKE_MINIMUM_REQUIRED(VERSION 2.6)
+PROJECT(ug-myfile-efl C)
+
+
+####################################
+########## SET Directory ###########
+####################################
+SET(MFUGNAME ug-myfile-efl)
+SET(UGINCLUDE ${CMAKE_CURRENT_SOURCE_DIR}/src/include)
+
+SET(UG-SRC-DIR ${CMAKE_CURRENT_SOURCE_DIR}/src)
+SET(UG-UTILITY-DIR ${UG-SRC-DIR}/common)
+SET(UG-FS-DIR ${UG-UTILITY-DIR}/file-system)
+SET(UG-WIDGET-DIR ${UG-SRC-DIR}/widget)
+
+SET(PREFIX "/opt/ug")
+SET(LIBDIR "${PREFIX}/lib")
+SET(RESDIR "${PREFIX}/res")
+SET(LOCALEDIR "${RESDIR}/locale")
+SET(IMAGEDIR "${RESDIR}/images/${MFUGNAME}")
+SET(EDJDIR "${RESDIR}/edje/${MFUGNAME}")
+
+
+SET(SRCS
+ ${UG-SRC-DIR}/mf-ug-main.c
+ ${UG-UTILITY-DIR}/mf-ug-util.c
+ ${UG-UTILITY-DIR}/mf-ug-cb.c
+ ${UG-UTILITY-DIR}/mf-ug-fm-svc-wapper.c
+ ${UG-UTILITY-DIR}/mf-ug-inotify-handle.c
+ ${UG-UTILITY-DIR}/mf-ug-list-play.c
+########### winset wrap ##########
+ ${UG-WIDGET-DIR}/mf-ug-navi-bar.c
+ ${UG-WIDGET-DIR}/mf-ug-genlist.c
+ ${UG-WIDGET-DIR}/mf-ug-popup.c
+ ${UG-WIDGET-DIR}/mf-ug-ctrl-bar.c
+ ${UG-WIDGET-DIR}/mf-ug-tab-bar.c
+################ file system #########
+ ${UG-FS-DIR}/mf-ug-file-attr.c
+ ${UG-FS-DIR}/mf-ug-fs-oper.c
+ )
+
+INCLUDE_DIRECTORIES(${UGINCLUDE})
+
+INCLUDE(FindPkgConfig)
+pkg_check_modules(ug_pkgs REQUIRED
+ecore-x ecore-evas
+elementary
+vconf
+glib-2.0
+mm-common
+mm-sound
+mm-player
+ui-gadget
+libmedia-service
+aul
+dlog
+)
+
+FOREACH(flag ${ug_pkgs_CFLAGS})
+ SET(EXTRA_CFLAGS "${EXTRA_CFLAGS} ${flag}")
+ENDFOREACH(flag)
+
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${EXTRA_CFLAGS}")
+
+ADD_DEFINITIONS("-DPREFIX=\"${CMAKE_INSTALL_PREFIX}\"")
+ADD_DEFINITIONS("-DFACTORYFS=\"$ENV{FACTORYFS}\"")
+
+
+ADD_DEFINITIONS("-DLIST_PLAY_SUPPORT")
+ADD_DEFINITIONS("-DUG_THUMB_REAL_TIME_UPDATE")
+ADD_DEFINITIONS("-DUG_LAUNCH_AT_MASS_STORAGE_MODE")
+ADD_DEFINITIONS("-DMF_UG_FEATURE_NEW_UX")
+
+ADD_LIBRARY(${MFUGNAME} SHARED ${SRCS})
+TARGET_LINK_LIBRARIES(${MFUGNAME} ${ug_pkgs_LDFLAGS} dl)
+
+INSTALL(TARGETS ${MFUGNAME} LIBRARY DESTINATION ${LIBDIR})
+
+
+# edje
+ADD_CUSTOM_TARGET(ug_navibar_layout.edj
+ COMMAND edje_cc -id ${CMAKE_CURRENT_SOURCE_DIR}
+ ${CMAKE_SOURCE_DIR}/ug_navibar_layout.edc
+ ${CMAKE_BINARY_DIR}/ug_navibar_layout.edj
+ DEPENDS ${CMAKE_SOURCE_DIR}/ug_navibar_layout.edc
+)
+
+ADD_DEPENDENCIES(${PROJECT_NAME} ug_navibar_layout.edj)
+
+INSTALL(FILES ${CMAKE_BINARY_DIR}/ug_navibar_layout.edj DESTINATION ${EDJDIR})
+
+
+# images
+INSTALL(DIRECTORY ${CMAKE_SOURCE_DIR}/icons/ DESTINATION ${IMAGEDIR} FILES_MATCHING PATTERN "*.png"
+PERMISSIONS OWNER_READ OWNER_WRITE OWNER_EXECUTE GROUP_READ GROUP_WRITE GROUP_EXECUTE WORLD_READ WORLD_WRITE WORLD_EXECUTE)
+
+# i18n
+ADD_SUBDIRECTORY(po)
+
diff --git a/LICENSE b/LICENSE
new file mode 100644
index 0000000..7ccb5b5
--- /dev/null
+++ b/LICENSE
@@ -0,0 +1,75 @@
+Flora License
+
+Version 1.0, May, 2012
+
+http://www.tizenopensource.org/license
+
+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.
+
+"Tizen Certified Platform" shall mean a software platform that complies with the standards set forth in the Compatibility Definition Document and passes the Compatibility Test Suite as defined from time to time by the Tizen Technical Steering Group and certified by the Tizen Association or its designated agent.
+
+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 solely as incorporated into a Tizen Certified Platform, 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 solely as incorporated into a Tizen Certified Platform 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 pursuant to the copyright license above, in any medium, with or without modifications, and in Source or Object form, provided that You meet the following conditions:
+
+ 1. You must give any other recipients of the Work or Derivative Works a copy of this License; and
+
+ 2. You must cause any modified files to carry prominent notices stating that You changed the files; and
+
+ 3. 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
+
+ 4. 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 Flora License to your work
+
+To apply the Flora 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 Flora License, Version 1.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.tizenopensource.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.
diff --git a/NOTICE b/NOTICE
new file mode 100755
index 0000000..8b13789
--- /dev/null
+++ b/NOTICE
@@ -0,0 +1 @@
+
diff --git a/debian/changelog b/debian/changelog
new file mode 100644
index 0000000..e57f0d9
--- /dev/null
+++ b/debian/changelog
@@ -0,0 +1,7 @@
+ug-myfile-efl (0.0.1-62) unstable; urgency=low
+
+ * inital version
+ * Git: pkgs/u/ug-myfile-efl
+ * Tag: ug-myfile-efl_0.0.1-62
+
+ -- Guangliang Wang <gliang.wang@samsung.com> Mon, 23 Apr 2012 20:34:18 +0800
diff --git a/debian/compat b/debian/compat
new file mode 100644
index 0000000..7ed6ff8
--- /dev/null
+++ b/debian/compat
@@ -0,0 +1 @@
+5
diff --git a/debian/control b/debian/control
new file mode 100644
index 0000000..30ea80d
--- /dev/null
+++ b/debian/control
@@ -0,0 +1,31 @@
+Source: ug-myfile-efl
+Section: libs
+Priority: extra
+Maintainer: Aram Kim <aramie.kim@samsung.com>, Liu Ruichao <ruichao.liu@samsung.com>, Guangliang Wang <gliang.wang@samsung.com>, Tang Feng <feng.tang@samsung.com>, Hyungmin Kim <hm2007.kim@samsung.com>
+Uploaders: Liu RuiChao <ruichao.liu@samsung.com>, Tang Feng <feng.tang@samsung.com>, Guangliang Wang <gliang.wang@samsung.com>
+Build-Depends: debhelper (>= 5),
+ libelm-dev,
+ libmm-player-dev,
+ libmm-sound-dev,
+ dlog-dev,
+ libui-gadget-dev,
+ libmedia-service-dev,
+ libslp-setting-dev,
+ libeina-dev,
+ libedbus-dev,
+ libdbus-glib-1-dev,
+ libdbus-1-dev,
+ libecore-dev,
+Standards-Version: 0.1.0
+
+Package: libug-myfile-efl
+Section: libs
+Architecture: any
+Depends: ${shlibs:Depends}, ${misc:Depends}
+Description: Myfile UI Gadget (EFL)
+
+Package: libug-myfile-efl-dbg
+Section: debug
+Architecture: any
+Depends: ${misc:Depends}, libug-myfile-efl (= ${Source-Version})
+Description: Myfile UI Gadget(unstripped) \ No newline at end of file
diff --git a/debian/copyright b/debian/copyright
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/debian/copyright
diff --git a/debian/libug-myfile-efl.install.in b/debian/libug-myfile-efl.install.in
new file mode 100644
index 0000000..cdb492b
--- /dev/null
+++ b/debian/libug-myfile-efl.install.in
@@ -0,0 +1,3 @@
+/opt/ug/lib/*
+/opt/ug/res/*
+
diff --git a/debian/rules b/debian/rules
new file mode 100755
index 0000000..a8c5062
--- /dev/null
+++ b/debian/rules
@@ -0,0 +1,127 @@
+#!/usr/bin/make -f
+# -*- makefile -*-
+# Sample debian/rules that uses debhelper.
+# This file was originally written by Joey Hess and Craig Small.
+# As a special exception, when this file is copied by dh-make into a
+# dh-make output file, you may use that output file without restriction.
+# This special exception was added by Craig Small in version 0.37 of dh-make.
+
+# Uncomment this to turn on verbose mode.
+#export DH_VERBOSE=1
+
+CFLAGS ?= -Wall -g
+CXXFLAGS ?= -Wall -g
+LDFLAGS ?=
+PREFIX ?= /usr
+DATADIR ?= /opt
+
+ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS)))
+ CFLAGS += -O0
+ CXXFLAGS += -O0
+else
+ CFLAGS += -O2
+ CXXFLAGS += -O2
+endif
+
+CFLAGS += -fpie
+LDFLAGS += -Wl,--rpath=$(PREFIX)/lib -Wl,--as-needed,--hash-style=both -pie
+
+configure: configure-stamp
+configure-stamp:
+ dh_testdir
+ # Add here commands to configure the package.
+ CFLAGS="$(CFLAGS)" CXXFLAGS="$(CXXFLAGS)" LDFLAGS="$(LDFLAGS)" cmake . -DCMAKE_INSTALL_PREFIX=$(PREFIX)
+
+ touch configure-stamp
+
+build: build-stamp
+
+build-stamp: configure-stamp
+ dh_testdir
+
+ # Add here commands to compile the package.
+ $(MAKE)
+ #docbook-to-man debian/wavplayer.sgml > wavplayer.1
+
+ for f in `find $(CURDIR)/debian/ -name "*.in"`; do \
+ cat $$f > $${f%.in}; \
+ sed -i -e "s#@PREFIX@#$(PREFIX)#g" $${f%.in}; \
+ sed -i -e "s#@DATADIR@#$(DATADIR)#g" $${f%.in}; \
+ done
+
+
+ touch $@
+
+clean:
+ dh_testdir
+ dh_testroot
+ rm -f build-stamp configure-stamp
+
+ # Add here commands to clean up after the build process.
+ -$(MAKE) clean
+ rm -rf CMakeCache.txt
+ rm -rf CMakeFiles
+ rm -rf cmake_install.cmake
+ rm -rf Makefile
+ rm -rf install_manifest.txt
+ rm -rf po/CMakeFiles/
+ rm -rf po/cmake_install.cmake
+ rm -rf po/Makefile
+ rm -rf *.so
+ rm -rf debian/*.install
+ rm -rf *.edj
+
+ for f in `find $(CURDIR)/debian/ -name "*.in"`; do \
+ rm -f $${f%.in}; \
+ done
+
+ dh_clean
+
+install: build
+ dh_testdir
+ dh_testroot
+ dh_clean -k
+ dh_installdirs
+
+ # Add here commands to install the package into debian/wavplayer.
+ $(MAKE) DESTDIR=$(CURDIR)/debian/tmp install
+
+
+# Build architecture-independent files here.
+binary-indep: build install
+# We have nothing to do by default.
+
+# Build architecture-dependent files here.
+binary-arch: build install
+ dh_testdir
+ dh_testroot
+ dh_installchangelogs
+ dh_installdocs
+ dh_installexamples
+ dh_install --sourcedir=debian/tmp
+# dh_installmenu
+# dh_installdebconf
+# dh_installlogrotate
+# dh_installemacsen
+# dh_installpam
+# dh_installmime
+# dh_python
+# dh_installinit
+# dh_installcron
+# dh_installinfo
+ dh_installman
+ dh_link
+ dh_strip
+ dh_strip --dbg-package=libug-myfile-efl-dbg
+ dh_compress
+ dh_fixperms
+# dh_perl
+# dh_makeshlibs
+ dh_installdeb
+ dh_shlibdeps
+ dh_gencontrol
+ dh_md5sums
+ dh_builddeb
+
+binary: binary-indep binary-arch
+.PHONY: build clean binary-indep binary-arch binary install configure
diff --git a/icons/01_myfile_add_icon.png b/icons/01_myfile_add_icon.png
new file mode 100644
index 0000000..290e2a5
--- /dev/null
+++ b/icons/01_myfile_add_icon.png
Binary files differ
diff --git a/icons/06_myfiles_list_folder.png b/icons/06_myfiles_list_folder.png
new file mode 100644
index 0000000..52b77ba
--- /dev/null
+++ b/icons/06_myfiles_list_folder.png
Binary files differ
diff --git a/icons/34_control_pause.png b/icons/34_control_pause.png
new file mode 100644
index 0000000..56943c0
--- /dev/null
+++ b/icons/34_control_pause.png
Binary files differ
diff --git a/icons/34_control_play.png b/icons/34_control_play.png
new file mode 100644
index 0000000..e5d7928
--- /dev/null
+++ b/icons/34_control_play.png
Binary files differ
diff --git a/icons/47_myfiles_icon_excel.png b/icons/47_myfiles_icon_excel.png
new file mode 100644
index 0000000..109b7de
--- /dev/null
+++ b/icons/47_myfiles_icon_excel.png
Binary files differ
diff --git a/icons/47_myfiles_icon_folder.png b/icons/47_myfiles_icon_folder.png
new file mode 100644
index 0000000..f425327
--- /dev/null
+++ b/icons/47_myfiles_icon_folder.png
Binary files differ
diff --git a/icons/47_myfiles_icon_folder_created.png b/icons/47_myfiles_icon_folder_created.png
new file mode 100644
index 0000000..5c24399
--- /dev/null
+++ b/icons/47_myfiles_icon_folder_created.png
Binary files differ
diff --git a/icons/47_myfiles_icon_folder_sinced.png b/icons/47_myfiles_icon_folder_sinced.png
new file mode 100644
index 0000000..8027943
--- /dev/null
+++ b/icons/47_myfiles_icon_folder_sinced.png
Binary files differ
diff --git a/icons/47_myfiles_icon_html.png b/icons/47_myfiles_icon_html.png
new file mode 100644
index 0000000..78646b4
--- /dev/null
+++ b/icons/47_myfiles_icon_html.png
Binary files differ
diff --git a/icons/47_myfiles_icon_music.png b/icons/47_myfiles_icon_music.png
new file mode 100644
index 0000000..43d7798
--- /dev/null
+++ b/icons/47_myfiles_icon_music.png
Binary files differ
diff --git a/icons/47_myfiles_icon_pause_focus.png b/icons/47_myfiles_icon_pause_focus.png
new file mode 100644
index 0000000..fd1c6a2
--- /dev/null
+++ b/icons/47_myfiles_icon_pause_focus.png
Binary files differ
diff --git a/icons/47_myfiles_icon_pdf.png b/icons/47_myfiles_icon_pdf.png
new file mode 100644
index 0000000..2480d81
--- /dev/null
+++ b/icons/47_myfiles_icon_pdf.png
Binary files differ
diff --git a/icons/47_myfiles_icon_play_focus.png b/icons/47_myfiles_icon_play_focus.png
new file mode 100644
index 0000000..88575c1
--- /dev/null
+++ b/icons/47_myfiles_icon_play_focus.png
Binary files differ
diff --git a/icons/47_myfiles_icon_ppt.png b/icons/47_myfiles_icon_ppt.png
new file mode 100644
index 0000000..42c1100
--- /dev/null
+++ b/icons/47_myfiles_icon_ppt.png
Binary files differ
diff --git a/icons/47_myfiles_icon_ring_tone.png b/icons/47_myfiles_icon_ring_tone.png
new file mode 100644
index 0000000..5e6d2c5
--- /dev/null
+++ b/icons/47_myfiles_icon_ring_tone.png
Binary files differ
diff --git a/icons/47_myfiles_icon_rss.png b/icons/47_myfiles_icon_rss.png
new file mode 100644
index 0000000..1b566e2
--- /dev/null
+++ b/icons/47_myfiles_icon_rss.png
Binary files differ
diff --git a/icons/47_myfiles_icon_swf.png b/icons/47_myfiles_icon_swf.png
new file mode 100644
index 0000000..ee50e85
--- /dev/null
+++ b/icons/47_myfiles_icon_swf.png
Binary files differ
diff --git a/icons/47_myfiles_icon_text.png b/icons/47_myfiles_icon_text.png
new file mode 100644
index 0000000..c937ef8
--- /dev/null
+++ b/icons/47_myfiles_icon_text.png
Binary files differ
diff --git a/icons/47_myfiles_icon_upper_folder_black_theme.png b/icons/47_myfiles_icon_upper_folder_black_theme.png
new file mode 100644
index 0000000..050c295
--- /dev/null
+++ b/icons/47_myfiles_icon_upper_folder_black_theme.png
Binary files differ
diff --git a/icons/47_myfiles_icon_upper_folder_focus.png b/icons/47_myfiles_icon_upper_folder_focus.png
new file mode 100644
index 0000000..d8dd048
--- /dev/null
+++ b/icons/47_myfiles_icon_upper_folder_focus.png
Binary files differ
diff --git a/icons/47_myfiles_icon_upper_folder_white_theme.png b/icons/47_myfiles_icon_upper_folder_white_theme.png
new file mode 100644
index 0000000..e3853c1
--- /dev/null
+++ b/icons/47_myfiles_icon_upper_folder_white_theme.png
Binary files differ
diff --git a/icons/47_myfiles_icon_video.png b/icons/47_myfiles_icon_video.png
new file mode 100644
index 0000000..a8e832a
--- /dev/null
+++ b/icons/47_myfiles_icon_video.png
Binary files differ
diff --git a/icons/47_myfiles_icon_word.png b/icons/47_myfiles_icon_word.png
new file mode 100644
index 0000000..b399bad
--- /dev/null
+++ b/icons/47_myfiles_icon_word.png
Binary files differ
diff --git a/icons/60_myfiles_file_amr.png b/icons/60_myfiles_file_amr.png
new file mode 100644
index 0000000..93c66f3
--- /dev/null
+++ b/icons/60_myfiles_file_amr.png
Binary files differ
diff --git a/icons/60_myfiles_file_etc.png b/icons/60_myfiles_file_etc.png
new file mode 100644
index 0000000..26748d8
--- /dev/null
+++ b/icons/60_myfiles_file_etc.png
Binary files differ
diff --git a/icons/60_myfiles_icon_images.png b/icons/60_myfiles_icon_images.png
new file mode 100644
index 0000000..4dd3be3
--- /dev/null
+++ b/icons/60_myfiles_icon_images.png
Binary files differ
diff --git a/icons/60_myfiles_icon_java.png b/icons/60_myfiles_icon_java.png
new file mode 100644
index 0000000..a083ee6
--- /dev/null
+++ b/icons/60_myfiles_icon_java.png
Binary files differ
diff --git a/icons/60_myfiles_icon_music_default.png b/icons/60_myfiles_icon_music_default.png
new file mode 100644
index 0000000..5f001a2
--- /dev/null
+++ b/icons/60_myfiles_icon_music_default.png
Binary files differ
diff --git a/icons/60_myfiles_icon_vText.png b/icons/60_myfiles_icon_vText.png
new file mode 100644
index 0000000..97b5a62
--- /dev/null
+++ b/icons/60_myfiles_icon_vText.png
Binary files differ
diff --git a/icons/60_myfiles_icon_vcalender.png b/icons/60_myfiles_icon_vcalender.png
new file mode 100644
index 0000000..5bc9826
--- /dev/null
+++ b/icons/60_myfiles_icon_vcalender.png
Binary files differ
diff --git a/icons/60_myfiles_icon_vcard.png b/icons/60_myfiles_icon_vcard.png
new file mode 100644
index 0000000..4ed5743
--- /dev/null
+++ b/icons/60_myfiles_icon_vcard.png
Binary files differ
diff --git a/icons/60_myfiles_memorycard.png b/icons/60_myfiles_memorycard.png
new file mode 100644
index 0000000..f486674
--- /dev/null
+++ b/icons/60_myfiles_memorycard.png
Binary files differ
diff --git a/icons/60_myfiles_memorycard_sub.png b/icons/60_myfiles_memorycard_sub.png
new file mode 100644
index 0000000..faced52
--- /dev/null
+++ b/icons/60_myfiles_memorycard_sub.png
Binary files differ
diff --git a/icons/60_myfiles_phone.png b/icons/60_myfiles_phone.png
new file mode 100644
index 0000000..1c92369
--- /dev/null
+++ b/icons/60_myfiles_phone.png
Binary files differ
diff --git a/icons/U01_icon_USB.png b/icons/U01_icon_USB.png
new file mode 100644
index 0000000..bf4dc00
--- /dev/null
+++ b/icons/U01_icon_USB.png
Binary files differ
diff --git a/icons/myfile_icon_add.png b/icons/myfile_icon_add.png
new file mode 100644
index 0000000..43c4984
--- /dev/null
+++ b/icons/myfile_icon_add.png
Binary files differ
diff --git a/packaging/ug-myfile-efl.spec b/packaging/ug-myfile-efl.spec
new file mode 100644
index 0000000..156e858
--- /dev/null
+++ b/packaging/ug-myfile-efl.spec
@@ -0,0 +1,47 @@
+%define _optdir /opt
+%define _ugdir %{_optdir}/ug
+
+
+Name: ug-myfile-efl
+Summary: Myfile UI-Gadget (EFL)
+Version: 0.0.1
+Release: 2.1
+Group: TO_BE/FILLED_IN
+License: Flora Software License
+Source0: %{name}-%{version}.tar.gz
+BuildRequires: cmake
+BuildRequires: gettext-tools
+BuildRequires: pkgconfig(aul)
+BuildRequires: pkgconfig(dlog)
+BuildRequires: pkgconfig(ecore-evas)
+BuildRequires: pkgconfig(ecore-x)
+BuildRequires: pkgconfig(elementary)
+BuildRequires: pkgconfig(glib-2.0)
+BuildRequires: pkgconfig(libmedia-service)
+BuildRequires: pkgconfig(mm-common)
+BuildRequires: pkgconfig(mm-player)
+BuildRequires: pkgconfig(mm-sound)
+BuildRequires: pkgconfig(ui-gadget)
+BuildRequires: pkgconfig(vconf)
+BuildRequires: pkgconfig(icu-uc)
+BuildRequires: edje-tools
+
+%description
+Description: Myfile Detail UI-Gadget (EFL)
+
+%prep
+%setup -q
+
+%build
+cmake . -DCMAKE_INSTALL_PREFIX=%{_prefix}
+
+make %{?jobs:-j%jobs}
+
+%install
+%make_install
+
+%find_lang ug-myfile-efl
+%files -f ug-myfile-efl.lang
+/opt/ug/lib/libug-myfile-efl.so
+/opt/ug/res/edje/ug-myfile-efl/ug_navibar_layout.edj
+/opt/ug/res/images/ug-myfile-efl/*
diff --git a/po/CMakeLists.txt b/po/CMakeLists.txt
new file mode 100644
index 0000000..1bc70f4
--- /dev/null
+++ b/po/CMakeLists.txt
@@ -0,0 +1,24 @@
+# for i18n
+
+SET(POFILES de_DE.po el_GR.po en.po es_ES.po fr_FR.po it_IT.po ja_JP.po ko_KR.po nl_NL.po pt_PT.po ru_RU.po tr_TR.po zh_CN.po zh_HK.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 /opt/ug/res/locale/${lang}/LC_MESSAGES RENAME ${MFUGNAME}.mo)
+ SET(moFiles ${moFiles} ${moFile})
+ENDFOREACH(pofile)
+
+MESSAGE(".mo files: ${moFiles}")
+ADD_CUSTOM_TARGET(po ALL DEPENDS ${moFiles})
diff --git a/po/POTFILES.in b/po/POTFILES.in
new file mode 100644
index 0000000..92bd4d0
--- /dev/null
+++ b/po/POTFILES.in
@@ -0,0 +1,17 @@
+# List of source files containing translatable strings.
+src_ug/myfile_sg_lib.c
+src_ug/ug/myfile_lib_ug.c
+src_ug/ug/myfileCallBack.c
+src_ug/ug/myfileUtil.c
+src_ug/libraries/platform-wrapper/myfile_filemanagerservice_wrapper.c
+src_ug/libraries/winset-wrapper/myfileContent.c
+src_ug/libraries/winset-wrapper/myfileContextPopup.c
+src_ug/libraries/winset-wrapper/myfileControlBar.c
+src_ug/libraries/winset-wrapper/myfileInput.c
+src_ug/libraries/winset-wrapper/myfileLayout.c
+src_ug/libraries/winset-wrapper/myfileListPlay.c
+src_ug/libraries/winset-wrapper/myfileListView.c
+src_ug/libraries/winset-wrapper/myfileNavigationBar.c
+src_ug/libraries/winset-wrapper/myfilePopup.c
+src_ug/launch/myfileGadgetImageViewer.c
+src_ug/launch/myfileLaunch.c
diff --git a/po/de.po b/po/de.po
new file mode 100644
index 0000000..0de8783
--- /dev/null
+++ b/po/de.po
@@ -0,0 +1,120 @@
+msgid "IDS_MF_BODY_ANY"
+msgstr "Jede"
+
+msgid "IDS_MF_BODY_AVAILABLE_USES"
+msgstr "Verfügbare Nutzungen"
+
+msgid "IDS_MF_BODY_CREATE_FOLDER"
+msgstr "Ordner erstellen"
+
+msgid "IDS_MF_BODY_DATE"
+msgstr "Datum"
+
+msgid "IDS_MF_BODY_DONE"
+msgstr "OK"
+
+msgid "IDS_MF_BODY_EXECUTE"
+msgstr "Ausführen"
+
+msgid "IDS_MF_BODY_FORWARDING"
+msgstr "Weiterleitung"
+
+msgid "IDS_MF_BODY_IMAGES"
+msgstr "Bilder"
+
+msgid "IDS_MF_BODY_IMPOSSIBLE"
+msgstr "Nicht möglich"
+
+msgid "IDS_MF_BODY_MMC_DATA_IS_INITIALIZING_ING"
+msgstr "MMC-Daten werden initialisiert..."
+
+msgid "IDS_MF_BODY_OTHERS"
+msgstr "Sonstiges"
+
+msgid "IDS_MF_BODY_POSSIBLE"
+msgstr "Möglich"
+
+msgid "IDS_MF_BODY_PRINT"
+msgstr "Drucken"
+
+msgid "IDS_MF_BODY_SIZE"
+msgstr "Größe"
+
+msgid "IDS_MF_BODY_SOUNDS"
+msgstr "Töne"
+
+msgid "IDS_MF_BODY_VALIDITY"
+msgstr "Gültigkeit"
+
+msgid "IDS_MF_BODY_VIDEOS"
+msgstr "Videos"
+
+msgid "IDS_MF_HEADER_NEW_FOLDER"
+msgstr "Neuer Ordner"
+
+msgid "IDS_MF_HEADER_PHONE"
+msgstr "Telefon"
+
+msgid "IDS_MF_HEADER_RENAME"
+msgstr "Umbenennen"
+
+msgid "IDS_MF_OPT_COPY"
+msgstr "Kopieren"
+
+msgid "IDS_MF_OPT_DETAILS"
+msgstr "Details"
+
+msgid "IDS_MF_OPT_EDIT"
+msgstr "Bearbeiten"
+
+msgid "IDS_MF_OPT_LISTBY_TYPE"
+msgstr "Typ"
+
+msgid "IDS_MF_OPT_LIST_BY"
+msgstr "Sortieren nach"
+
+msgid "IDS_MF_OPT_MOVE"
+msgstr "Verschieben"
+
+msgid "IDS_MF_OPT_MOVE_HERE"
+msgstr "Hierher verschieben"
+
+msgid "IDS_MF_OPT_RINGTONE"
+msgstr "Klingelton"
+
+msgid "IDS_MF_OPT_WALLPAPER"
+msgstr "Hintergrundbild"
+
+msgid "IDS_MF_POP_CLOSE"
+msgstr "Schließen"
+
+msgid "IDS_MF_POP_CONTINUE"
+msgstr "Weiter"
+
+msgid "IDS_MF_POP_COPYING"
+msgstr "Wird kopiert..."
+
+msgid "IDS_MF_POP_DELETING_ING"
+msgstr "Löschen..."
+
+msgid "IDS_MF_POP_DO_YOU_WANT_TO_UNLOCK_IT_NOW_Q"
+msgstr "Jetzt freigeben?"
+
+msgid "IDS_MF_POP_MOVING"
+msgstr "Verschiebevorgang aktiv..."
+
+msgid "IDS_MF_POP_PASTE_HERE"
+msgstr "Hier einfügen"
+
+msgid "IDS_MF_POP_SELECT_ALL"
+msgstr "Alle auswählen"
+
+msgid "IDS_MF_POP_UNSUPPORTED_FILE_TYPE"
+msgstr "Nicht unterstützter Dateityp"
+
+msgid "IDS_MF_SK_ADD"
+msgstr "Hinzufügen"
+
+msgid "IDS_MF_SK_CANCEL"
+msgstr "Abbrechen"
+
diff --git a/po/de_DE.po b/po/de_DE.po
new file mode 100644
index 0000000..d75d2a4
--- /dev/null
+++ b/po/de_DE.po
@@ -0,0 +1,158 @@
+msgid "IDS_MF_TAB_UP"
+msgstr "Hoch"
+
+msgid "IDS_MF_BUTTON_HOME"
+msgstr "Home"
+msgid "IDS_MF_BODY_ALERTS"
+msgstr "Signale"
+
+msgid "IDS_MF_BODY_WALLPAPERS"
+msgstr "Hintergrund"
+
+msgid "IDS_MF_BODY_ACCESS_MORE_MY_ALBUM"
+msgstr "Eigenes Album"
+
+msgid "IDS_MF_BODY_MY_VIDEO_CLIPS"
+msgstr "Eigene Videos"
+
+msgid "IDS_MF_BODY_RIGHT_STATUS"
+msgstr "Copyright-Status"
+
+msgid "IDS_MF_BODY_VENDOR"
+msgstr "Anbieter"
+
+msgid "IDS_MF_HEADER_COUNT"
+msgstr "Anzahl"
+
+msgid "IDS_MF_BODY_CONTAINS"
+msgstr "Enthält"
+
+msgid "IDS_MF_BODY_INDIVIDUAL"
+msgstr "Individuell"
+
+msgid "IDS_MF_BODY_INTERVAL"
+msgstr "Intervall"
+
+msgid "IDS_MF_BODY_RENAME_ABB"
+msgstr "Umben."
+
+msgid "IDS_MF_BODY_TIME"
+msgstr "Zeit"
+
+msgid "IDS_MF_BODY_TIMED_COUNT"
+msgstr "Zeitzählung"
+
+msgid "IDS_MF_BODY_TYPE"
+msgstr "Typ"
+
+msgid "IDS_MF_BODY_UNLIMITED"
+msgstr "Unbegrenzt"
+
+msgid "IDS_MF_BUTTON_REPLACE_ABB"
+msgstr "Ersetzen"
+
+msgid "IDS_MF_OPT_CALLER_RINGTONE"
+msgstr "Anruferklingelton"
+
+msgid "IDS_MF_OPT_LISTBY_NAME"
+msgstr "Name"
+
+msgid "IDS_MF_POP_COPIED"
+msgstr "Kopiert"
+
+msgid "IDS_MF_POP_MOVED"
+msgstr "Verschoben"
+
+msgid "IDS_MF_POP_NOTHING_SELECTED"
+msgstr "Nichts ausgewählt"
+
+msgid "IDS_MF_POP_NOT_ENOUGH_HEAP_MEMORY"
+msgstr "Nicht genügend dynamischer Speicher"
+
+msgid "IDS_MF_POP_NOT_ENOUGH_MEMORY_DELETE_SOME_ITEMS"
+msgstr "Nicht genügend Speicher. Löschen Sie einige Elemente"
+
+msgid "IDS_MF_BODY_CREATED_DATE"
+msgstr "Erstellungsdatum"
+
+msgid "IDS_MF_BODY_GPS_INFORMATION"
+msgstr "GPS-Informationen"
+
+msgid "IDS_MF_BODY_GPS_LATITUDE"
+msgstr "GPS-Breite"
+
+msgid "IDS_MF_BODY_GPS_LONGITUDE"
+msgstr "GPS-Länge"
+
+msgid "IDS_MF_BODY_GPS_VERSION"
+msgstr "GPS-Version"
+
+msgid "IDS_MF_BODY_NAME"
+msgstr "Name"
+
+msgid "IDS_MF_SK_DETAILS"
+msgstr "Details"
+
+msgid "IDS_MF_BODY_ANY"
+msgstr "Jede"
+
+msgid "IDS_MF_BODY_AVAILABLE_USES"
+msgstr "Verfügbare Nutzungen"
+
+msgid "IDS_MF_BODY_EXECUTE"
+msgstr "Ausführen"
+
+msgid "IDS_MF_BODY_FORWARDING"
+msgstr "Weiterleitung"
+
+msgid "IDS_MF_BODY_IMPOSSIBLE"
+msgstr "Nicht möglich"
+
+msgid "IDS_MF_BODY_MMC_DATA_IS_INITIALIZING_ING"
+msgstr "MMC-Daten werden initialisiert..."
+
+msgid "IDS_MF_BODY_POSSIBLE"
+msgstr "Möglich"
+
+msgid "IDS_MF_BODY_PRINT"
+msgstr "Drucken"
+
+msgid "IDS_MF_BODY_VALIDITY"
+msgstr "Gültigkeit"
+
+msgid "IDS_MF_HEADER_NEW_FOLDER"
+msgstr "Neuer Ordner"
+
+msgid "IDS_MF_OPT_EDIT"
+msgstr "Bearbeiten"
+
+msgid "IDS_MF_OPT_LIST_BY"
+msgstr "Sortieren"
+
+msgid "IDS_MF_OPT_MOVE_HERE"
+msgstr "Hierher verschieben"
+
+msgid "IDS_MF_POP_CONTINUE"
+msgstr "Weiter"
+
+msgid "IDS_MF_POP_COPYING"
+msgstr "Wird kopiert..."
+
+msgid "IDS_MF_POP_MOVING"
+msgstr "Verschiebevorgang aktiv..."
+
+msgid "IDS_MF_POP_PASTE_HERE"
+msgstr "Hier einfügen"
+
+msgid "IDS_MF_POP_UNSUPPORTED_FILE_TYPE"
+msgstr "Nicht unterstützter Dateityp"
+
+msgid "IDS_MF_OPT_DETAIL_VIEW"
+msgstr "Detailansicht"
+
+msgid "IDS_MF_POP_ASCENDING"
+msgstr "Aufsteigend"
+
+msgid "IDS_MF_POP_DESCENDING"
+msgstr "Absteigend"
+
diff --git a/po/el.po b/po/el.po
new file mode 100644
index 0000000..0a45315
--- /dev/null
+++ b/po/el.po
@@ -0,0 +1,120 @@
+msgid "IDS_MF_BODY_ANY"
+msgstr "Οποιοδήποτε"
+
+msgid "IDS_MF_BODY_AVAILABLE_USES"
+msgstr "Διαθέσιμες χρήσεις"
+
+msgid "IDS_MF_BODY_CREATE_FOLDER"
+msgstr "Δημ/ργία φακέλου"
+
+msgid "IDS_MF_BODY_DATE"
+msgstr "Ημερομηνία"
+
+msgid "IDS_MF_BODY_DONE"
+msgstr "Τέλος"
+
+msgid "IDS_MF_BODY_EXECUTE"
+msgstr "Εκτέλεση"
+
+msgid "IDS_MF_BODY_FORWARDING"
+msgstr "Προώθηση"
+
+msgid "IDS_MF_BODY_IMAGES"
+msgstr "Εικόνες"
+
+msgid "IDS_MF_BODY_IMPOSSIBLE"
+msgstr "Αδύνατο"
+
+msgid "IDS_MF_BODY_MMC_DATA_IS_INITIALIZING_ING"
+msgstr "Inizializzazione dati MMC..."
+
+msgid "IDS_MF_BODY_OTHERS"
+msgstr "Άλλα"
+
+msgid "IDS_MF_BODY_POSSIBLE"
+msgstr "Δυνατό"
+
+msgid "IDS_MF_BODY_PRINT"
+msgstr "Εκτύπωση"
+
+msgid "IDS_MF_BODY_SIZE"
+msgstr "Μέγεθος"
+
+msgid "IDS_MF_BODY_SOUNDS"
+msgstr "Ήχοι"
+
+msgid "IDS_MF_BODY_VALIDITY"
+msgstr "Ισχύς"
+
+msgid "IDS_MF_BODY_VIDEOS"
+msgstr "Βίντεο"
+
+msgid "IDS_MF_HEADER_NEW_FOLDER"
+msgstr "Νέος φάκελος"
+
+msgid "IDS_MF_HEADER_PHONE"
+msgstr "Τηλέφωνο"
+
+msgid "IDS_MF_HEADER_RENAME"
+msgstr "Μετονομασία"
+
+msgid "IDS_MF_OPT_COPY"
+msgstr "Αντιγραφή"
+
+msgid "IDS_MF_OPT_DETAILS"
+msgstr "Λεπτομέρειες"
+
+msgid "IDS_MF_OPT_EDIT"
+msgstr "Επεξεργασία"
+
+msgid "IDS_MF_OPT_LISTBY_TYPE"
+msgstr "Τύπος"
+
+msgid "IDS_MF_OPT_LIST_BY"
+msgstr "Εμφάνιση ανά"
+
+msgid "IDS_MF_OPT_MOVE"
+msgstr "Μετακίνηση"
+
+msgid "IDS_MF_OPT_MOVE_HERE"
+msgstr "Μετακίνηση εδώ"
+
+msgid "IDS_MF_OPT_RINGTONE"
+msgstr "Ήχος κλήσης"
+
+msgid "IDS_MF_OPT_WALLPAPER"
+msgstr "Φόντο"
+
+msgid "IDS_MF_POP_CLOSE"
+msgstr "Κλείσιμο"
+
+msgid "IDS_MF_POP_CONTINUE"
+msgstr "Συνέχεια;"
+
+msgid "IDS_MF_POP_COPYING"
+msgstr "Αντιγραφή..."
+
+msgid "IDS_MF_POP_DELETING_ING"
+msgstr "Διαγραφή..."
+
+msgid "IDS_MF_POP_DO_YOU_WANT_TO_UNLOCK_IT_NOW_Q"
+msgstr "Θέλετε να το ξεκλειδώσετε τώρα;"
+
+msgid "IDS_MF_POP_MOVING"
+msgstr "Μετακίνηση..."
+
+msgid "IDS_MF_POP_PASTE_HERE"
+msgstr "Επικόλληση εδώ"
+
+msgid "IDS_MF_POP_SELECT_ALL"
+msgstr "Επιλογή όλων"
+
+msgid "IDS_MF_POP_UNSUPPORTED_FILE_TYPE"
+msgstr "Μη υποστηριζόμενος τύπος αρχείου"
+
+msgid "IDS_MF_SK_ADD"
+msgstr "Προσθήκη"
+
+msgid "IDS_MF_SK_CANCEL"
+msgstr "Άκυρο"
+
diff --git a/po/el_GR.po b/po/el_GR.po
new file mode 100644
index 0000000..a54eacf
--- /dev/null
+++ b/po/el_GR.po
@@ -0,0 +1,159 @@
+msgid "IDS_MF_TAB_UP"
+msgstr "Πάνω"
+
+msgid "IDS_MF_BUTTON_HOME"
+msgstr "Σπίτι"
+
+msgid "IDS_MF_BODY_ALERTS"
+msgstr "Ειδοποιήσεις"
+
+msgid "IDS_MF_BODY_WALLPAPERS"
+msgstr "Θέματα φόντου"
+
+msgid "IDS_MF_BODY_ACCESS_MORE_MY_ALBUM"
+msgstr "Το άλμπουμ μου"
+
+msgid "IDS_MF_BODY_MY_VIDEO_CLIPS"
+msgstr "Τα βίντεο κλιπ μου"
+
+msgid "IDS_MF_BODY_RIGHT_STATUS"
+msgstr "Κατάσταση δικαιώματος"
+
+msgid "IDS_MF_BODY_VENDOR"
+msgstr "Προμηθευτής"
+
+msgid "IDS_MF_HEADER_COUNT"
+msgstr "Πλήθος αρχείων"
+
+msgid "IDS_MF_BODY_CONTAINS"
+msgstr "Περιέχει"
+
+msgid "IDS_MF_BODY_INDIVIDUAL"
+msgstr "Μεμονωμένο"
+
+msgid "IDS_MF_BODY_INTERVAL"
+msgstr "Διάστημα"
+
+msgid "IDS_MF_BODY_RENAME_ABB"
+msgstr "Μετον."
+
+msgid "IDS_MF_BODY_TIME"
+msgstr "Ώρα"
+
+msgid "IDS_MF_BODY_TIMED_COUNT"
+msgstr "Χρονομετρημένη μέτρηση"
+
+msgid "IDS_MF_BODY_TYPE"
+msgstr "Τύπος"
+
+msgid "IDS_MF_BODY_UNLIMITED"
+msgstr "Απεριόριστες"
+
+msgid "IDS_MF_BUTTON_REPLACE_ABB"
+msgstr "Αντικατ."
+
+msgid "IDS_MF_OPT_CALLER_RINGTONE"
+msgstr "Ήχος κλήσης καλούντος"
+
+msgid "IDS_MF_OPT_LISTBY_NAME"
+msgstr "Όνομα"
+
+msgid "IDS_MF_POP_COPIED"
+msgstr "Αντιγράφηκε"
+
+msgid "IDS_MF_POP_MOVED"
+msgstr "Μετακινήθηκε"
+
+msgid "IDS_MF_POP_NOTHING_SELECTED"
+msgstr "Δεν έχει γίνει καμία επιλογή"
+
+msgid "IDS_MF_POP_NOT_ENOUGH_HEAP_MEMORY"
+msgstr "Ο σωρός μνήμης δεν επαρκεί"
+
+msgid "IDS_MF_POP_NOT_ENOUGH_MEMORY_DELETE_SOME_ITEMS"
+msgstr "Δεν υπάρχει αρκετή μνήμη. Διαγράψτε ορισμένα στοιχεία"
+
+msgid "IDS_MF_BODY_CREATED_DATE"
+msgstr "Ημερομηνία δημιουργίας"
+
+msgid "IDS_MF_BODY_GPS_INFORMATION"
+msgstr "Πληροφορίες GPS"
+
+msgid "IDS_MF_BODY_GPS_LATITUDE"
+msgstr "Γεωγραφικό πλάτος GPS"
+
+msgid "IDS_MF_BODY_GPS_LONGITUDE"
+msgstr "Γεωγραφικό μήκος GPS"
+
+msgid "IDS_MF_BODY_GPS_VERSION"
+msgstr "Έκδοση GPS"
+
+msgid "IDS_MF_BODY_NAME"
+msgstr "Όνομα"
+
+msgid "IDS_MF_SK_DETAILS"
+msgstr "Λεπτομ."
+
+msgid "IDS_MF_BODY_ANY"
+msgstr "Οποιοδήποτε"
+
+msgid "IDS_MF_BODY_AVAILABLE_USES"
+msgstr "Διαθέσιμες χρήσεις"
+
+msgid "IDS_MF_BODY_EXECUTE"
+msgstr "Εκτέλεση"
+
+msgid "IDS_MF_BODY_FORWARDING"
+msgstr "Προώθηση"
+
+msgid "IDS_MF_BODY_IMPOSSIBLE"
+msgstr "Αδύνατο"
+
+msgid "IDS_MF_BODY_MMC_DATA_IS_INITIALIZING_ING"
+msgstr "Προετοιμασία των δεδομένων MMC..."
+
+msgid "IDS_MF_BODY_POSSIBLE"
+msgstr "Δυνατό"
+
+msgid "IDS_MF_BODY_PRINT"
+msgstr "Εκτύπωση"
+
+msgid "IDS_MF_BODY_VALIDITY"
+msgstr "Ισχύς"
+
+msgid "IDS_MF_HEADER_NEW_FOLDER"
+msgstr "Νέος φάκελος"
+
+msgid "IDS_MF_OPT_EDIT"
+msgstr "Επεξεργασία"
+
+msgid "IDS_MF_OPT_LIST_BY"
+msgstr "Εμφάνιση ανά"
+
+msgid "IDS_MF_OPT_MOVE_HERE"
+msgstr "Μετακίνηση εδώ"
+
+msgid "IDS_MF_POP_CONTINUE"
+msgstr "Συνέχεια;"
+
+msgid "IDS_MF_POP_COPYING"
+msgstr "Αντιγραφή..."
+
+msgid "IDS_MF_POP_MOVING"
+msgstr "Μετακίνηση..."
+
+msgid "IDS_MF_POP_PASTE_HERE"
+msgstr "Επικόλληση εδώ"
+
+msgid "IDS_MF_POP_UNSUPPORTED_FILE_TYPE"
+msgstr "Μη υποστηριζόμενος τύπος αρχείου"
+
+msgid "IDS_MF_OPT_DETAIL_VIEW"
+msgstr "Προβολή λεπτομερειών"
+
+msgid "IDS_MF_POP_ASCENDING"
+msgstr "Αύξουσα"
+
+msgid "IDS_MF_POP_DESCENDING"
+msgstr "Φθίνουσα"
+
diff --git a/po/en.po b/po/en.po
new file mode 100644
index 0000000..8a6531f
--- /dev/null
+++ b/po/en.po
@@ -0,0 +1,159 @@
+msgid "IDS_MF_TAB_UP"
+msgstr "Up"
+
+msgid "IDS_MF_BUTTON_HOME"
+msgstr "Home"
+
+msgid "IDS_MF_BODY_ALERTS"
+msgstr "Alerts"
+
+msgid "IDS_MF_BODY_WALLPAPERS"
+msgstr "Wallpapers"
+
+msgid "IDS_MF_BODY_ACCESS_MORE_MY_ALBUM"
+msgstr "My album"
+
+msgid "IDS_MF_BODY_MY_VIDEO_CLIPS"
+msgstr "My video clips"
+
+msgid "IDS_MF_BODY_RIGHT_STATUS"
+msgstr "Right status"
+
+msgid "IDS_MF_BODY_VENDOR"
+msgstr "Vendor"
+
+msgid "IDS_MF_HEADER_COUNT"
+msgstr "Count"
+
+msgid "IDS_MF_BODY_CONTAINS"
+msgstr "Contains"
+
+msgid "IDS_MF_BODY_INDIVIDUAL"
+msgstr "Individual"
+
+msgid "IDS_MF_BODY_INTERVAL"
+msgstr "Interval"
+
+msgid "IDS_MF_BODY_RENAME_ABB"
+msgstr "Rename"
+
+msgid "IDS_MF_BODY_TIME"
+msgstr "Time"
+
+msgid "IDS_MF_BODY_TIMED_COUNT"
+msgstr "Timed count"
+
+msgid "IDS_MF_BODY_TYPE"
+msgstr "Type"
+
+msgid "IDS_MF_BODY_UNLIMITED"
+msgstr "Unlimited"
+
+msgid "IDS_MF_BUTTON_REPLACE_ABB"
+msgstr "Replace"
+
+msgid "IDS_MF_OPT_CALLER_RINGTONE"
+msgstr "Caller ringtone"
+
+msgid "IDS_MF_OPT_LISTBY_NAME"
+msgstr "Name"
+
+msgid "IDS_MF_POP_COPIED"
+msgstr "Copied"
+
+msgid "IDS_MF_POP_MOVED"
+msgstr "Moved"
+
+msgid "IDS_MF_POP_NOTHING_SELECTED"
+msgstr "Nothing selected"
+
+msgid "IDS_MF_POP_NOT_ENOUGH_HEAP_MEMORY"
+msgstr "Not enough heap memory"
+
+msgid "IDS_MF_POP_NOT_ENOUGH_MEMORY_DELETE_SOME_ITEMS"
+msgstr "Not enough memory. Delete some items"
+
+msgid "IDS_MF_BODY_CREATED_DATE"
+msgstr "Created date"
+
+msgid "IDS_MF_BODY_GPS_INFORMATION"
+msgstr "GPS information"
+
+msgid "IDS_MF_BODY_GPS_LATITUDE"
+msgstr "GPS latitude"
+
+msgid "IDS_MF_BODY_GPS_LONGITUDE"
+msgstr "GPS longitude"
+
+msgid "IDS_MF_BODY_GPS_VERSION"
+msgstr "GPS version"
+
+msgid "IDS_MF_BODY_NAME"
+msgstr "Name"
+
+msgid "IDS_MF_SK_DETAILS"
+msgstr "Details"
+
+msgid "IDS_MF_BODY_ANY"
+msgstr "Any"
+
+msgid "IDS_MF_BODY_AVAILABLE_USES"
+msgstr "Available uses"
+
+msgid "IDS_MF_BODY_EXECUTE"
+msgstr "Execute"
+
+msgid "IDS_MF_BODY_FORWARDING"
+msgstr "Forwarding"
+
+msgid "IDS_MF_BODY_IMPOSSIBLE"
+msgstr "Impossible"
+
+msgid "IDS_MF_BODY_MMC_DATA_IS_INITIALIZING_ING"
+msgstr "MMC data is initialising..."
+
+msgid "IDS_MF_BODY_POSSIBLE"
+msgstr "Possible"
+
+msgid "IDS_MF_BODY_PRINT"
+msgstr "Print"
+
+msgid "IDS_MF_BODY_VALIDITY"
+msgstr "Validity"
+
+msgid "IDS_MF_HEADER_NEW_FOLDER"
+msgstr "New folder"
+
+msgid "IDS_MF_OPT_EDIT"
+msgstr "Edit"
+
+msgid "IDS_MF_OPT_LIST_BY"
+msgstr "List by"
+
+msgid "IDS_MF_OPT_MOVE_HERE"
+msgstr "Move here"
+
+msgid "IDS_MF_POP_CONTINUE"
+msgstr "Continue"
+
+msgid "IDS_MF_POP_COPYING"
+msgstr "Copying..."
+
+msgid "IDS_MF_POP_MOVING"
+msgstr "Moving..."
+
+msgid "IDS_MF_POP_PASTE_HERE"
+msgstr "Paste here"
+
+msgid "IDS_MF_POP_UNSUPPORTED_FILE_TYPE"
+msgstr "Unsupported file type"
+
+msgid "IDS_MF_OPT_DETAIL_VIEW"
+msgstr "Detail view"
+
+msgid "IDS_MF_POP_ASCENDING"
+msgstr "Ascending"
+
+msgid "IDS_MF_POP_DESCENDING"
+msgstr "Descending"
+
diff --git a/po/en_GB.po b/po/en_GB.po
new file mode 100644
index 0000000..f9959ca
--- /dev/null
+++ b/po/en_GB.po
@@ -0,0 +1,46 @@
+# SOME DESCRIPTIVE TITLE.
+# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
+# This file is distributed under the same license as the PACKAGE package.
+# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
+#
+#, fuzzy
+msgid ""
+msgstr ""
+"Project-Id-Version: PACKAGE VERSION\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2010-06-16 18:18+0900\n"
+"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
+"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
+"Language-Team: LANGUAGE <LL@li.org>\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=UTF-8\n"
+"Content-Transfer-Encoding: 8bit\n"
+
+#: libraries/winset-wrapper/myfileListView.c:75
+msgid "IDS_MF_BODY_IMAGES"
+msgstr "Images"
+
+#: libraries/winset-wrapper/myfileListView.c:77
+#msgid "Videos"
+#msgstr ""
+
+#: libraries/winset-wrapper/myfileListView.c:78
+msgid "IDS_MF_BODY_VIDEOS"
+msgstr "Videos"
+
+#: libraries/winset-wrapper/myfileListView.c:80
+#msgid "Sounds"
+#msgstr ""
+
+#: libraries/winset-wrapper/myfileListView.c:81
+msgid "IDS_MF_BODY_SOUNDS"
+msgstr "Sounds"
+
+#: libraries/winset-wrapper/myfileListView.c:83
+#msgid "Others"
+#msgstr ""
+
+#: libraries/winset-wrapper/myfileListView.c:84
+msgid "IDS_MF_BODY_OTHERS"
+msgstr "Others"
+
diff --git a/po/en_US.po b/po/en_US.po
new file mode 100644
index 0000000..862dc57
--- /dev/null
+++ b/po/en_US.po
@@ -0,0 +1,94 @@
+# SOME DESCRIPTIVE TITLE.
+# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
+# This file is distributed under the same license as the PACKAGE package.
+# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
+#
+#, fuzzy
+msgid ""
+msgstr ""
+"Project-Id-Version: PACKAGE VERSION\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2010-06-16 18:18+0900\n"
+"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
+"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
+"Language-Team: LANGUAGE <LL@li.org>\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=UTF-8\n"
+"Content-Transfer-Encoding: 8bit\n"
+
+#: src_sg/myfile_sg_lib.c:98 src_sg/myfile_sg_lib.c:482
+#: src_sg/myfile_sg_lib.c:518 src_sg/myfile_sg_lib.c:901
+msgid "IDS_COM_SK_OK"
+msgstr "OK"
+
+#: src_sg/myfile_sg_lib.c:478 src_sg/myfile_sg_lib.c:894
+msgid "IDS_COM_BODY_BACK"
+msgstr "Back"
+
+#: src_sg/myfile_sg_lib.c:504 src_sg/myfile_sg_lib.c:897
+#: src_sg/myfile_sg_lib.c:942
+msgid "IDS_COM_BODY_DELETE"
+msgstr "Delete"
+
+#: src_sg/myfile_sg_lib.c:517
+msgid "Select at least one item"
+msgstr ""
+
+#. supporting multi-lang for default folders
+#: source/libraries/winset-wrapper/main/titlebar.c:24
+msgid "Images"
+msgstr ""
+
+#: source/libraries/winset-wrapper/main/titlebar.c:25
+msgid "IDS_MF_BODY_IMAGES"
+msgstr "Images"
+
+#: source/libraries/winset-wrapper/main/titlebar.c:27
+msgid "Videos"
+msgstr ""
+
+#: source/libraries/winset-wrapper/main/titlebar.c:28
+msgid "IDS_MF_BODY_VIDEOS"
+msgstr "Videos"
+
+#: source/libraries/winset-wrapper/main/titlebar.c:30
+msgid "Sounds"
+msgstr ""
+
+#: source/libraries/winset-wrapper/main/titlebar.c:31
+msgid "IDS_MF_BODY_SOUNDS"
+msgstr "Sounds"
+
+#: source/libraries/winset-wrapper/main/titlebar.c:33
+msgid "Others"
+msgstr ""
+
+#: source/libraries/winset-wrapper/main/titlebar.c:34
+msgid "IDS_MF_BODY_OTHERS"
+msgstr "Others"
+
+#: source/libraries/winset-wrapper/main/tab.c:16
+#: source/libraries/winset-wrapper/main/tab.c:79
+#: source/libraries/winset-wrapper/main/tab.c:102
+#: source/libraries/winset-wrapper/main/popup.c:291
+msgid "IDS_COM_BODY_PHONE"
+msgstr "Phone"
+
+#: source/libraries/winset-wrapper/main/tab.c:26
+#: source/libraries/winset-wrapper/main/tab.c:80
+#: source/libraries/winset-wrapper/main/tab.c:103
+#: source/libraries/winset-wrapper/main/popup.c:297
+msgid "IDS_COM_BODY_MEMORY_CARD"
+msgstr "Memory card"
+
+#: source/libraries/winset-wrapper/main/tab.c:28
+msgid "IDS_COM_BODY_ALL"
+msgstr "All"
+
+#: source/libraries/winset-wrapper/main/tab.c:52
+msgid "FONT_NAME"
+msgstr ""
+
+#: source/libraries/winset-wrapper/main/popup.c:346
+msgid "IDS_COM_SK_CANCEL"
+msgstr "CANCEL"
diff --git a/po/es.po b/po/es.po
new file mode 100644
index 0000000..ce73e46
--- /dev/null
+++ b/po/es.po
@@ -0,0 +1,120 @@
+msgid "IDS_MF_BODY_ANY"
+msgstr "Cualquiera"
+
+msgid "IDS_MF_BODY_AVAILABLE_USES"
+msgstr "Usos disponibles"
+
+msgid "IDS_MF_BODY_CREATE_FOLDER"
+msgstr "Crear carpeta"
+
+msgid "IDS_MF_BODY_DATE"
+msgstr "Fecha"
+
+msgid "IDS_MF_BODY_DONE"
+msgstr "Finalizado"
+
+msgid "IDS_MF_BODY_EXECUTE"
+msgstr "Ejecutar"
+
+msgid "IDS_MF_BODY_FORWARDING"
+msgstr "Reenviando"
+
+msgid "IDS_MF_BODY_IMAGES"
+msgstr "Imágenes"
+
+msgid "IDS_MF_BODY_IMPOSSIBLE"
+msgstr "Imposible"
+
+msgid "IDS_MF_BODY_MMC_DATA_IS_INITIALIZING_ING"
+msgstr "Προετοιμασία των δεδομένων MMC..."
+
+msgid "IDS_MF_BODY_OTHERS"
+msgstr "Otros"
+
+msgid "IDS_MF_BODY_POSSIBLE"
+msgstr "Posible"
+
+msgid "IDS_MF_BODY_PRINT"
+msgstr "Imprimir"
+
+msgid "IDS_MF_BODY_SIZE"
+msgstr "Tamaño"
+
+msgid "IDS_MF_BODY_SOUNDS"
+msgstr "Sonidos"
+
+msgid "IDS_MF_BODY_VALIDITY"
+msgstr "Validez"
+
+msgid "IDS_MF_BODY_VIDEOS"
+msgstr "Vídeos"
+
+msgid "IDS_MF_HEADER_NEW_FOLDER"
+msgstr "Nueva carpeta"
+
+msgid "IDS_MF_HEADER_PHONE"
+msgstr "Teléfono"
+
+msgid "IDS_MF_HEADER_RENAME"
+msgstr "Cambiar nombre"
+
+msgid "IDS_MF_OPT_COPY"
+msgstr "Copiar"
+
+msgid "IDS_MF_OPT_DETAILS"
+msgstr "Detalles"
+
+msgid "IDS_MF_OPT_EDIT"
+msgstr "Editar"
+
+msgid "IDS_MF_OPT_LISTBY_TYPE"
+msgstr "Tipo"
+
+msgid "IDS_MF_OPT_LIST_BY"
+msgstr "Ordenar por"
+
+msgid "IDS_MF_OPT_MOVE"
+msgstr "Mover"
+
+msgid "IDS_MF_OPT_MOVE_HERE"
+msgstr "Mover aquí"
+
+msgid "IDS_MF_OPT_RINGTONE"
+msgstr "Melodía"
+
+msgid "IDS_MF_OPT_WALLPAPER"
+msgstr "Fondos"
+
+msgid "IDS_MF_POP_CLOSE"
+msgstr "Cerrar"
+
+msgid "IDS_MF_POP_CONTINUE"
+msgstr "Continuar"
+
+msgid "IDS_MF_POP_COPYING"
+msgstr "Copiando..."
+
+msgid "IDS_MF_POP_DELETING_ING"
+msgstr "Eliminando..."
+
+msgid "IDS_MF_POP_DO_YOU_WANT_TO_UNLOCK_IT_NOW_Q"
+msgstr "¿Desea desbloquearlo ahora?"
+
+msgid "IDS_MF_POP_MOVING"
+msgstr "Moviendo..."
+
+msgid "IDS_MF_POP_PASTE_HERE"
+msgstr "Pegar aquí"
+
+msgid "IDS_MF_POP_SELECT_ALL"
+msgstr "Seleccionar todo"
+
+msgid "IDS_MF_POP_UNSUPPORTED_FILE_TYPE"
+msgstr "Tipo de archivo no admitido"
+
+msgid "IDS_MF_SK_ADD"
+msgstr "Añadir"
+
+msgid "IDS_MF_SK_CANCEL"
+msgstr "Cancelar"
+
diff --git a/po/es_ES.po b/po/es_ES.po
new file mode 100644
index 0000000..1d09824
--- /dev/null
+++ b/po/es_ES.po
@@ -0,0 +1,158 @@
+msgid "IDS_MF_TAB_UP"
+msgstr "Arriba"
+
+msgid "IDS_MF_BUTTON_HOME"
+msgstr "Inicio"
+msgid "IDS_MF_BODY_ALERTS"
+msgstr "Alertas"
+
+msgid "IDS_MF_BODY_WALLPAPERS"
+msgstr "Fondos de pantalla"
+
+msgid "IDS_MF_BODY_ACCESS_MORE_MY_ALBUM"
+msgstr "Mi álbum"
+
+msgid "IDS_MF_BODY_MY_VIDEO_CLIPS"
+msgstr "Mis clips de vídeo"
+
+msgid "IDS_MF_BODY_RIGHT_STATUS"
+msgstr "Estado correcto"
+
+msgid "IDS_MF_BODY_VENDOR"
+msgstr "Proveedor"
+
+msgid "IDS_MF_HEADER_COUNT"
+msgstr "Contar"
+
+msgid "IDS_MF_BODY_CONTAINS"
+msgstr "Contiene"
+
+msgid "IDS_MF_BODY_INDIVIDUAL"
+msgstr "Individual"
+
+msgid "IDS_MF_BODY_INTERVAL"
+msgstr "Intervalo"
+
+msgid "IDS_MF_BODY_RENAME_ABB"
+msgstr "Renomb"
+
+msgid "IDS_MF_BODY_TIME"
+msgstr "Hora"
+
+msgid "IDS_MF_BODY_TIMED_COUNT"
+msgstr "Recuento de tiempo"
+
+msgid "IDS_MF_BODY_TYPE"
+msgstr "Tipo"
+
+msgid "IDS_MF_BODY_UNLIMITED"
+msgstr "Ilimitado"
+
+msgid "IDS_MF_BUTTON_REPLACE_ABB"
+msgstr "Reempl"
+
+msgid "IDS_MF_OPT_CALLER_RINGTONE"
+msgstr "Melodía del llamante"
+
+msgid "IDS_MF_OPT_LISTBY_NAME"
+msgstr "Nombre"
+
+msgid "IDS_MF_POP_COPIED"
+msgstr "Copiado"
+
+msgid "IDS_MF_POP_MOVED"
+msgstr "Movido"
+
+msgid "IDS_MF_POP_NOTHING_SELECTED"
+msgstr "No se ha seleccionado nada"
+
+msgid "IDS_MF_POP_NOT_ENOUGH_HEAP_MEMORY"
+msgstr "No hay memoria de ejecución suficiente"
+
+msgid "IDS_MF_POP_NOT_ENOUGH_MEMORY_DELETE_SOME_ITEMS"
+msgstr "No hay memoria suficiente. Elimine algunos elementos"
+
+msgid "IDS_MF_BODY_CREATED_DATE"
+msgstr "Fecha creada"
+
+msgid "IDS_MF_BODY_GPS_INFORMATION"
+msgstr "Información de GPS"
+
+msgid "IDS_MF_BODY_GPS_LATITUDE"
+msgstr "Latitud GPS"
+
+msgid "IDS_MF_BODY_GPS_LONGITUDE"
+msgstr "Longitud GPS"
+
+msgid "IDS_MF_BODY_GPS_VERSION"
+msgstr "Versión GPS"
+
+msgid "IDS_MF_BODY_NAME"
+msgstr "Nombre"
+
+msgid "IDS_MF_SK_DETAILS"
+msgstr "Detalles"
+
+msgid "IDS_MF_BODY_ANY"
+msgstr "Cualquiera"
+
+msgid "IDS_MF_BODY_AVAILABLE_USES"
+msgstr "Usos disponibles"
+
+msgid "IDS_MF_BODY_EXECUTE"
+msgstr "Ejecutar"
+
+msgid "IDS_MF_BODY_FORWARDING"
+msgstr "Reenviando"
+
+msgid "IDS_MF_BODY_IMPOSSIBLE"
+msgstr "Imposible"
+
+msgid "IDS_MF_BODY_MMC_DATA_IS_INITIALIZING_ING"
+msgstr "Los datos MMC se están inicializando..."
+
+msgid "IDS_MF_BODY_POSSIBLE"
+msgstr "Posible"
+
+msgid "IDS_MF_BODY_PRINT"
+msgstr "Imprimir"
+
+msgid "IDS_MF_BODY_VALIDITY"
+msgstr "Validez"
+
+msgid "IDS_MF_HEADER_NEW_FOLDER"
+msgstr "Nueva carpeta"
+
+msgid "IDS_MF_OPT_EDIT"
+msgstr "Editar"
+
+msgid "IDS_MF_OPT_LIST_BY"
+msgstr "Mostrar por"
+
+msgid "IDS_MF_OPT_MOVE_HERE"
+msgstr "Mover aquí"
+
+msgid "IDS_MF_POP_CONTINUE"
+msgstr "Continuar"
+
+msgid "IDS_MF_POP_COPYING"
+msgstr "Copiando..."
+
+msgid "IDS_MF_POP_MOVING"
+msgstr "Moviendo..."
+
+msgid "IDS_MF_POP_PASTE_HERE"
+msgstr "Pegar aquí"
+
+msgid "IDS_MF_POP_UNSUPPORTED_FILE_TYPE"
+msgstr "Tipo de archivo no admitido"
+
+msgid "IDS_MF_OPT_DETAIL_VIEW"
+msgstr "Vista de detalle"
+
+msgid "IDS_MF_POP_ASCENDING"
+msgstr "Ascendente"
+
+msgid "IDS_MF_POP_DESCENDING"
+msgstr "Descendente"
+
diff --git a/po/fr.po b/po/fr.po
new file mode 100644
index 0000000..109bf21
--- /dev/null
+++ b/po/fr.po
@@ -0,0 +1,120 @@
+msgid "IDS_MF_BODY_ANY"
+msgstr "N'importe"
+
+msgid "IDS_MF_BODY_AVAILABLE_USES"
+msgstr "Utilisations disponibles"
+
+msgid "IDS_MF_BODY_CREATE_FOLDER"
+msgstr "Créer dossier"
+
+msgid "IDS_MF_BODY_DATE"
+msgstr "Date"
+
+msgid "IDS_MF_BODY_DONE"
+msgstr "OK"
+
+msgid "IDS_MF_BODY_EXECUTE"
+msgstr "Exécuter"
+
+msgid "IDS_MF_BODY_FORWARDING"
+msgstr "Transfert"
+
+msgid "IDS_MF_BODY_IMAGES"
+msgstr "Images"
+
+msgid "IDS_MF_BODY_IMPOSSIBLE"
+msgstr "Impossible"
+
+msgid "IDS_MF_BODY_MMC_DATA_IS_INITIALIZING_ING"
+msgstr ""
+
+msgid "IDS_MF_BODY_OTHERS"
+msgstr "Autres"
+
+msgid "IDS_MF_BODY_POSSIBLE"
+msgstr "Possible"
+
+msgid "IDS_MF_BODY_PRINT"
+msgstr "Imprimer"
+
+msgid "IDS_MF_BODY_SIZE"
+msgstr "Taille"
+
+msgid "IDS_MF_BODY_SOUNDS"
+msgstr "Sons"
+
+msgid "IDS_MF_BODY_VALIDITY"
+msgstr "Validité"
+
+msgid "IDS_MF_BODY_VIDEOS"
+msgstr "Vidéos"
+
+msgid "IDS_MF_HEADER_NEW_FOLDER"
+msgstr "Nouveau dossier"
+
+msgid "IDS_MF_HEADER_PHONE"
+msgstr "Téléphone"
+
+msgid "IDS_MF_HEADER_RENAME"
+msgstr "Renommer"
+
+msgid "IDS_MF_OPT_COPY"
+msgstr "Copier"
+
+msgid "IDS_MF_OPT_DETAILS"
+msgstr "Détails"
+
+msgid "IDS_MF_OPT_EDIT"
+msgstr "Modifier"
+
+msgid "IDS_MF_OPT_LISTBY_TYPE"
+msgstr "Type"
+
+msgid "IDS_MF_OPT_LIST_BY"
+msgstr "Trier par"
+
+msgid "IDS_MF_OPT_MOVE"
+msgstr "Déplacer"
+
+msgid "IDS_MF_OPT_MOVE_HERE"
+msgstr "Déplacer ici"
+
+msgid "IDS_MF_OPT_RINGTONE"
+msgstr "Sonnerie"
+
+msgid "IDS_MF_OPT_WALLPAPER"
+msgstr "Fond d'écran"
+
+msgid "IDS_MF_POP_CLOSE"
+msgstr "Fermer"
+
+msgid "IDS_MF_POP_CONTINUE"
+msgstr "Continuer"
+
+msgid "IDS_MF_POP_COPYING"
+msgstr "Copie ..."
+
+msgid "IDS_MF_POP_DELETING_ING"
+msgstr "Suppression ..."
+
+msgid "IDS_MF_POP_DO_YOU_WANT_TO_UNLOCK_IT_NOW_Q"
+msgstr "Voulez-vous le déverrouiller maintenant ?"
+
+msgid "IDS_MF_POP_MOVING"
+msgstr "Déplacement..."
+
+msgid "IDS_MF_POP_PASTE_HERE"
+msgstr "Coller ici"
+
+msgid "IDS_MF_POP_SELECT_ALL"
+msgstr "Sélectionner tout"
+
+msgid "IDS_MF_POP_UNSUPPORTED_FILE_TYPE"
+msgstr "Type de fichier non pris en charge"
+
+msgid "IDS_MF_SK_ADD"
+msgstr "Ajouter"
+
+msgid "IDS_MF_SK_CANCEL"
+msgstr "Annuler"
+
diff --git a/po/fr_FR.po b/po/fr_FR.po
new file mode 100644
index 0000000..bb7cc9c
--- /dev/null
+++ b/po/fr_FR.po
@@ -0,0 +1,158 @@
+msgid "IDS_MF_TAB_UP"
+msgstr "Haut"
+
+msgid "IDS_MF_BUTTON_HOME"
+msgstr "Accueil"
+msgid "IDS_MF_BODY_ALERTS"
+msgstr "Alertes"
+
+msgid "IDS_MF_BODY_WALLPAPERS"
+msgstr "Fonds d'écran"
+
+msgid "IDS_MF_BODY_ACCESS_MORE_MY_ALBUM"
+msgstr "Mon album"
+
+msgid "IDS_MF_BODY_MY_VIDEO_CLIPS"
+msgstr "Mes clips vidéo"
+
+msgid "IDS_MF_BODY_RIGHT_STATUS"
+msgstr "Information sur les droits"
+
+msgid "IDS_MF_BODY_VENDOR"
+msgstr "Fournisseur"
+
+msgid "IDS_MF_HEADER_COUNT"
+msgstr "Compte"
+
+msgid "IDS_MF_BODY_CONTAINS"
+msgstr "Contient"
+
+msgid "IDS_MF_BODY_INDIVIDUAL"
+msgstr "Individuel"
+
+msgid "IDS_MF_BODY_INTERVAL"
+msgstr "Intervalle"
+
+msgid "IDS_MF_BODY_RENAME_ABB"
+msgstr "Nv nom"
+
+msgid "IDS_MF_BODY_TIME"
+msgstr "Heure"
+
+msgid "IDS_MF_BODY_TIMED_COUNT"
+msgstr "Temps restant"
+
+msgid "IDS_MF_BODY_TYPE"
+msgstr "Type"
+
+msgid "IDS_MF_BODY_UNLIMITED"
+msgstr "Illimité"
+
+msgid "IDS_MF_BUTTON_REPLACE_ABB"
+msgstr "Rempl."
+
+msgid "IDS_MF_OPT_CALLER_RINGTONE"
+msgstr "Sonnerie personnalisée"
+
+msgid "IDS_MF_OPT_LISTBY_NAME"
+msgstr "Nom"
+
+msgid "IDS_MF_POP_COPIED"
+msgstr "Copié(s)"
+
+msgid "IDS_MF_POP_MOVED"
+msgstr "Déplacé"
+
+msgid "IDS_MF_POP_NOTHING_SELECTED"
+msgstr "Aucune sélection"
+
+msgid "IDS_MF_POP_NOT_ENOUGH_HEAP_MEMORY"
+msgstr "Mémoire de la pile insuffisante"
+
+msgid "IDS_MF_POP_NOT_ENOUGH_MEMORY_DELETE_SOME_ITEMS"
+msgstr "Mémoire insuffisante. Supprimez certains éléments"
+
+msgid "IDS_MF_BODY_CREATED_DATE"
+msgstr "Date de création"
+
+msgid "IDS_MF_BODY_GPS_INFORMATION"
+msgstr "Informations GPS"
+
+msgid "IDS_MF_BODY_GPS_LATITUDE"
+msgstr "Latitude GPS"
+
+msgid "IDS_MF_BODY_GPS_LONGITUDE"
+msgstr "Longitude GPS"
+
+msgid "IDS_MF_BODY_GPS_VERSION"
+msgstr "Version GPS"
+
+msgid "IDS_MF_BODY_NAME"
+msgstr "Nom"
+
+msgid "IDS_MF_SK_DETAILS"
+msgstr "Détails"
+
+msgid "IDS_MF_BODY_ANY"
+msgstr "N'importe"
+
+msgid "IDS_MF_BODY_AVAILABLE_USES"
+msgstr "Utilisations disponibles"
+
+msgid "IDS_MF_BODY_EXECUTE"
+msgstr "Exécuter"
+
+msgid "IDS_MF_BODY_FORWARDING"
+msgstr "Transfert"
+
+msgid "IDS_MF_BODY_IMPOSSIBLE"
+msgstr "Impossible"
+
+msgid "IDS_MF_BODY_MMC_DATA_IS_INITIALIZING_ING"
+msgstr "Données MMC en cours d'initialisation..."
+
+msgid "IDS_MF_BODY_POSSIBLE"
+msgstr "Possible"
+
+msgid "IDS_MF_BODY_PRINT"
+msgstr "Imprimer"
+
+msgid "IDS_MF_BODY_VALIDITY"
+msgstr "Validité"
+
+msgid "IDS_MF_HEADER_NEW_FOLDER"
+msgstr "Nouveau dossier"
+
+msgid "IDS_MF_OPT_EDIT"
+msgstr "Modifier"
+
+msgid "IDS_MF_OPT_LIST_BY"
+msgstr "Trier par"
+
+msgid "IDS_MF_OPT_MOVE_HERE"
+msgstr "Déplacer ici"
+
+msgid "IDS_MF_POP_CONTINUE"
+msgstr "Continuer"
+
+msgid "IDS_MF_POP_COPYING"
+msgstr "Copie ..."
+
+msgid "IDS_MF_POP_MOVING"
+msgstr "Déplacement..."
+
+msgid "IDS_MF_POP_PASTE_HERE"
+msgstr "Coller ici"
+
+msgid "IDS_MF_POP_UNSUPPORTED_FILE_TYPE"
+msgstr "Type de fichier non pris en charge"
+
+msgid "IDS_MF_OPT_DETAIL_VIEW"
+msgstr "Affichage détaillé"
+
+msgid "IDS_MF_POP_ASCENDING"
+msgstr "Croissant"
+
+msgid "IDS_MF_POP_DESCENDING"
+msgstr "Décroissant"
+
diff --git a/po/it.po b/po/it.po
new file mode 100644
index 0000000..15a979b
--- /dev/null
+++ b/po/it.po
@@ -0,0 +1,120 @@
+msgid "IDS_MF_BODY_ANY"
+msgstr "Qualsiasi"
+
+msgid "IDS_MF_BODY_AVAILABLE_USES"
+msgstr "Usi disponibili"
+
+msgid "IDS_MF_BODY_CREATE_FOLDER"
+msgstr "Crea cartella"
+
+msgid "IDS_MF_BODY_DATE"
+msgstr "Data"
+
+msgid "IDS_MF_BODY_DONE"
+msgstr "Fatto"
+
+msgid "IDS_MF_BODY_EXECUTE"
+msgstr "Esegui"
+
+msgid "IDS_MF_BODY_FORWARDING"
+msgstr "Inoltro"
+
+msgid "IDS_MF_BODY_IMAGES"
+msgstr "Immagini"
+
+msgid "IDS_MF_BODY_IMPOSSIBLE"
+msgstr "Impossibile"
+
+msgid "IDS_MF_BODY_MMC_DATA_IS_INITIALIZING_ING"
+msgstr "MMC verileri başlatılıyor..."
+
+msgid "IDS_MF_BODY_OTHERS"
+msgstr "Altro"
+
+msgid "IDS_MF_BODY_POSSIBLE"
+msgstr "Possibile"
+
+msgid "IDS_MF_BODY_PRINT"
+msgstr "Stampa"
+
+msgid "IDS_MF_BODY_SIZE"
+msgstr "Dimensioni"
+
+msgid "IDS_MF_BODY_SOUNDS"
+msgstr "Suoni"
+
+msgid "IDS_MF_BODY_VALIDITY"
+msgstr "Validità"
+
+msgid "IDS_MF_BODY_VIDEOS"
+msgstr "Video"
+
+msgid "IDS_MF_HEADER_NEW_FOLDER"
+msgstr "Nuova cartella"
+
+msgid "IDS_MF_HEADER_PHONE"
+msgstr "Telefono"
+
+msgid "IDS_MF_HEADER_RENAME"
+msgstr "Rinomina"
+
+msgid "IDS_MF_OPT_COPY"
+msgstr "Copia"
+
+msgid "IDS_MF_OPT_DETAILS"
+msgstr "Dettagli"
+
+msgid "IDS_MF_OPT_EDIT"
+msgstr "Modifica"
+
+msgid "IDS_MF_OPT_LISTBY_TYPE"
+msgstr "Tipo"
+
+msgid "IDS_MF_OPT_LIST_BY"
+msgstr "Elenca per"
+
+msgid "IDS_MF_OPT_MOVE"
+msgstr "Sposta"
+
+msgid "IDS_MF_OPT_MOVE_HERE"
+msgstr "Sposta qui"
+
+msgid "IDS_MF_OPT_RINGTONE"
+msgstr "Suoneria"
+
+msgid "IDS_MF_OPT_WALLPAPER"
+msgstr "Sfondo"
+
+msgid "IDS_MF_POP_CLOSE"
+msgstr "Chiudi"
+
+msgid "IDS_MF_POP_CONTINUE"
+msgstr "Continua"
+
+msgid "IDS_MF_POP_COPYING"
+msgstr "Copia in corso..."
+
+msgid "IDS_MF_POP_DELETING_ING"
+msgstr "Eliminazione..."
+
+msgid "IDS_MF_POP_DO_YOU_WANT_TO_UNLOCK_IT_NOW_Q"
+msgstr "Sbloccarlo adesso?"
+
+msgid "IDS_MF_POP_MOVING"
+msgstr "Spostamento..."
+
+msgid "IDS_MF_POP_PASTE_HERE"
+msgstr "Incolla qui"
+
+msgid "IDS_MF_POP_SELECT_ALL"
+msgstr "Seleziona tutto"
+
+msgid "IDS_MF_POP_UNSUPPORTED_FILE_TYPE"
+msgstr "Tipo file non supportato"
+
+msgid "IDS_MF_SK_ADD"
+msgstr "Aggiungi"
+
+msgid "IDS_MF_SK_CANCEL"
+msgstr "Annulla"
+
diff --git a/po/it_IT.po b/po/it_IT.po
new file mode 100644
index 0000000..f80ad57
--- /dev/null
+++ b/po/it_IT.po
@@ -0,0 +1,158 @@
+msgid "IDS_MF_TAB_UP"
+msgstr "Su"
+
+msgid "IDS_MF_BUTTON_HOME"
+msgstr "Home"
+msgid "IDS_MF_BODY_ALERTS"
+msgstr "Avvisi"
+
+msgid "IDS_MF_BODY_WALLPAPERS"
+msgstr "Sfondi"
+
+msgid "IDS_MF_BODY_ACCESS_MORE_MY_ALBUM"
+msgstr "Album"
+
+msgid "IDS_MF_BODY_MY_VIDEO_CLIPS"
+msgstr "Video personali"
+
+msgid "IDS_MF_BODY_RIGHT_STATUS"
+msgstr "Stato diritti"
+
+msgid "IDS_MF_BODY_VENDOR"
+msgstr "Fornitore"
+
+msgid "IDS_MF_HEADER_COUNT"
+msgstr "Conteggio"
+
+msgid "IDS_MF_BODY_CONTAINS"
+msgstr "Contiene"
+
+msgid "IDS_MF_BODY_INDIVIDUAL"
+msgstr "Individuale"
+
+msgid "IDS_MF_BODY_INTERVAL"
+msgstr "Intervallo"
+
+msgid "IDS_MF_BODY_RENAME_ABB"
+msgstr "Rinom."
+
+msgid "IDS_MF_BODY_TIME"
+msgstr "Ora"
+
+msgid "IDS_MF_BODY_TIMED_COUNT"
+msgstr "A termine"
+
+msgid "IDS_MF_BODY_TYPE"
+msgstr "Tipo"
+
+msgid "IDS_MF_BODY_UNLIMITED"
+msgstr "Senza limitazioni"
+
+msgid "IDS_MF_BUTTON_REPLACE_ABB"
+msgstr "Sostit."
+
+msgid "IDS_MF_OPT_CALLER_RINGTONE"
+msgstr "Suoneria chiamante"
+
+msgid "IDS_MF_OPT_LISTBY_NAME"
+msgstr "Nome"
+
+msgid "IDS_MF_POP_COPIED"
+msgstr "Copiato"
+
+msgid "IDS_MF_POP_MOVED"
+msgstr "Spostato"
+
+msgid "IDS_MF_POP_NOTHING_SELECTED"
+msgstr "Nessun elemento selezionato"
+
+msgid "IDS_MF_POP_NOT_ENOUGH_HEAP_MEMORY"
+msgstr "Memoria heap insufficiente"
+
+msgid "IDS_MF_POP_NOT_ENOUGH_MEMORY_DELETE_SOME_ITEMS"
+msgstr "Memoria insufficiente. Eliminare alcuni elementi"
+
+msgid "IDS_MF_BODY_CREATED_DATE"
+msgstr "Data creazione"
+
+msgid "IDS_MF_BODY_GPS_INFORMATION"
+msgstr "Informaz. GPS"
+
+msgid "IDS_MF_BODY_GPS_LATITUDE"
+msgstr "Latitudine GPS"
+
+msgid "IDS_MF_BODY_GPS_LONGITUDE"
+msgstr "Longitudine GPS"
+
+msgid "IDS_MF_BODY_GPS_VERSION"
+msgstr "Versione GPS"
+
+msgid "IDS_MF_BODY_NAME"
+msgstr "Nome"
+
+msgid "IDS_MF_SK_DETAILS"
+msgstr "Dettagli"
+
+msgid "IDS_MF_BODY_ANY"
+msgstr "Qualsiasi"
+
+msgid "IDS_MF_BODY_AVAILABLE_USES"
+msgstr "Usi disponibili"
+
+msgid "IDS_MF_BODY_EXECUTE"
+msgstr "Esegui"
+
+msgid "IDS_MF_BODY_FORWARDING"
+msgstr "Inoltro"
+
+msgid "IDS_MF_BODY_IMPOSSIBLE"
+msgstr "Impossibile"
+
+msgid "IDS_MF_BODY_MMC_DATA_IS_INITIALIZING_ING"
+msgstr "Inizializzazione dati MMC..."
+
+msgid "IDS_MF_BODY_POSSIBLE"
+msgstr "Possibile"
+
+msgid "IDS_MF_BODY_PRINT"
+msgstr "Stampa"
+
+msgid "IDS_MF_BODY_VALIDITY"
+msgstr "Validità"
+
+msgid "IDS_MF_HEADER_NEW_FOLDER"
+msgstr "Nuova cartella"
+
+msgid "IDS_MF_OPT_EDIT"
+msgstr "Modifica"
+
+msgid "IDS_MF_OPT_LIST_BY"
+msgstr "Elenca per"
+
+msgid "IDS_MF_OPT_MOVE_HERE"
+msgstr "Sposta qui"
+
+msgid "IDS_MF_POP_CONTINUE"
+msgstr "Continua"
+
+msgid "IDS_MF_POP_COPYING"
+msgstr "Copia in corso..."
+
+msgid "IDS_MF_POP_MOVING"
+msgstr "Spostamento..."
+
+msgid "IDS_MF_POP_PASTE_HERE"
+msgstr "Incolla qui"
+
+msgid "IDS_MF_POP_UNSUPPORTED_FILE_TYPE"
+msgstr "Tipo file non supportato"
+
+msgid "IDS_MF_OPT_DETAIL_VIEW"
+msgstr "Vista dettagli"
+
+msgid "IDS_MF_POP_ASCENDING"
+msgstr "Crescente"
+
+msgid "IDS_MF_POP_DESCENDING"
+msgstr "Decrescente"
+
diff --git a/po/ja.po b/po/ja.po
new file mode 100644
index 0000000..170b593
--- /dev/null
+++ b/po/ja.po
@@ -0,0 +1,137 @@
+# SOME DESCRIPTIVE TITLE.
+# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
+# This file is distributed under the same license as the PACKAGE package.
+# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
+#
+#, fuzzy
+msgid ""
+msgstr ""
+"Project-Id-Version: PACKAGE VERSION\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2010-06-16 18:18+0900\n"
+"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
+"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
+"Language-Team: LANGUAGE <LL@li.org>\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=UTF-8\n"
+"Content-Transfer-Encoding: 8bit\n"
+
+msgid "IDS_MF_BODY_ANY"
+msgstr "どれか"
+
+msgid "IDS_MF_BODY_AVAILABLE_USES"
+msgstr "使用​可能"
+
+msgid "IDS_MF_BODY_CREATE_FOLDER"
+msgstr "フォルダ作成"
+
+msgid "IDS_MF_BODY_DATE"
+msgstr "日付"
+
+msgid "IDS_MF_BODY_DONE"
+msgstr "完了"
+
+msgid "IDS_MF_BODY_EXECUTE"
+msgstr "実行"
+
+msgid "IDS_MF_BODY_FORWARDING"
+msgstr "外部転送"
+
+msgid "IDS_MF_BODY_IMAGES"
+msgstr "画像"
+
+msgid "IDS_MF_BODY_IMPOSSIBLE"
+msgstr "不可"
+
+msgid "IDS_MF_BODY_MMC_DATA_IS_INITIALIZING_ING"
+msgstr "Los datos MMC se están inicializando..."
+
+msgid "IDS_MF_BODY_OTHERS"
+msgstr "その他"
+
+msgid "IDS_MF_BODY_POSSIBLE"
+msgstr "可能"
+
+msgid "IDS_MF_BODY_PRINT"
+msgstr "印刷"
+
+msgid "IDS_MF_BODY_SIZE"
+msgstr "サイズ"
+
+msgid "IDS_MF_BODY_SOUNDS"
+msgstr "サウンド"
+
+msgid "IDS_MF_BODY_VALIDITY"
+msgstr "有効性"
+
+msgid "IDS_MF_BODY_VIDEOS"
+msgstr "ムービー"
+
+msgid "IDS_MF_HEADER_NEW_FOLDER"
+msgstr "新​フォルダ"
+
+msgid "IDS_MF_HEADER_PHONE"
+msgstr "本体"
+
+msgid "IDS_MF_HEADER_RENAME"
+msgstr "ファイル名変更"
+
+msgid "IDS_MF_OPT_COPY"
+msgstr "コピー"
+
+msgid "IDS_MF_OPT_DETAILS"
+msgstr "詳細"
+
+msgid "IDS_MF_OPT_EDIT"
+msgstr "編集​"
+
+msgid "IDS_MF_OPT_LISTBY_TYPE"
+msgstr "種類"
+
+msgid "IDS_MF_OPT_LIST_BY"
+msgstr "ソート"
+
+msgid "IDS_MF_OPT_MOVE"
+msgstr "移動"
+
+msgid "IDS_MF_OPT_MOVE_HERE"
+msgstr "ここに​移動"
+
+msgid "IDS_MF_OPT_RINGTONE"
+msgstr "着信音"
+
+msgid "IDS_MF_OPT_WALLPAPER"
+msgstr "壁紙"
+
+msgid "IDS_MF_POP_CLOSE"
+msgstr "閉じる"
+
+msgid "IDS_MF_POP_CONTINUE"
+msgstr "次へ"
+
+msgid "IDS_MF_POP_COPYING"
+msgstr "コピー中..."
+
+msgid "IDS_MF_POP_DELETING_ING"
+msgstr "削除中..."
+
+msgid "IDS_MF_POP_DO_YOU_WANT_TO_UNLOCK_IT_NOW_Q"
+msgstr "今すぐ​ロック​解除​しますか?"
+
+msgid "IDS_MF_POP_MOVING"
+msgstr "移動中..."
+
+msgid "IDS_MF_POP_PASTE_HERE"
+msgstr "ここにコピー"
+
+msgid "IDS_MF_POP_SELECT_ALL"
+msgstr "全て選択"
+
+msgid "IDS_MF_POP_UNSUPPORTED_FILE_TYPE"
+msgstr "非対応のファイルです"
+
+msgid "IDS_MF_SK_ADD"
+msgstr "追加"
+
+msgid "IDS_MF_SK_CANCEL"
+msgstr "キャンセル"
diff --git a/po/ja_JP.po b/po/ja_JP.po
new file mode 100644
index 0000000..c760088
--- /dev/null
+++ b/po/ja_JP.po
@@ -0,0 +1,159 @@
+msgid "IDS_MF_TAB_UP"
+msgstr "上"
+
+msgid "IDS_MF_BUTTON_HOME"
+msgstr "ホーム"
+
+msgid "IDS_MF_BODY_ALERTS"
+msgstr "アラート"
+
+msgid "IDS_MF_BODY_WALLPAPERS"
+msgstr "壁紙"
+
+msgid "IDS_MF_BODY_ACCESS_MORE_MY_ALBUM"
+msgstr "マイ​アルバム"
+
+msgid "IDS_MF_BODY_MY_VIDEO_CLIPS"
+msgstr "マイ​ビデオ​クリップ"
+
+msgid "IDS_MF_BODY_RIGHT_STATUS"
+msgstr "右​ステータス"
+
+msgid "IDS_MF_BODY_VENDOR"
+msgstr "提供元順"
+
+msgid "IDS_MF_HEADER_COUNT"
+msgstr "カウント"
+
+msgid "IDS_MF_BODY_CONTAINS"
+msgstr "含む"
+
+msgid "IDS_MF_BODY_INDIVIDUAL"
+msgstr "個人"
+
+msgid "IDS_MF_BODY_INTERVAL"
+msgstr "間隔"
+
+msgid "IDS_MF_BODY_RENAME_ABB"
+msgstr "名称変更"
+
+msgid "IDS_MF_BODY_TIME"
+msgstr "時刻"
+
+msgid "IDS_MF_BODY_TIMED_COUNT"
+msgstr "時間​カウント"
+
+msgid "IDS_MF_BODY_TYPE"
+msgstr "種類"
+
+msgid "IDS_MF_BODY_UNLIMITED"
+msgstr "無制限"
+
+msgid "IDS_MF_BUTTON_REPLACE_ABB"
+msgstr "上書き"
+
+msgid "IDS_MF_OPT_CALLER_RINGTONE"
+msgstr "個別​着信音"
+
+msgid "IDS_MF_OPT_LISTBY_NAME"
+msgstr "名前"
+
+msgid "IDS_MF_POP_COPIED"
+msgstr "コピーしました。"
+
+msgid "IDS_MF_POP_MOVED"
+msgstr "移動しました。"
+
+msgid "IDS_MF_POP_NOTHING_SELECTED"
+msgstr "何も​選択​されて​いません"
+
+msgid "IDS_MF_POP_NOT_ENOUGH_HEAP_MEMORY"
+msgstr "ヒープメモリ不足です"
+
+msgid "IDS_MF_POP_NOT_ENOUGH_MEMORY_DELETE_SOME_ITEMS"
+msgstr "メモリが不足しています。いくつかのアイテムを削除してください"
+
+msgid "IDS_MF_BODY_CREATED_DATE"
+msgstr "作成​された​データ"
+
+msgid "IDS_MF_BODY_GPS_INFORMATION"
+msgstr "GPS情報"
+
+msgid "IDS_MF_BODY_GPS_LATITUDE"
+msgstr "GPS​緯度"
+
+msgid "IDS_MF_BODY_GPS_LONGITUDE"
+msgstr "GPS​経度"
+
+msgid "IDS_MF_BODY_GPS_VERSION"
+msgstr "GPS​バージョン"
+
+msgid "IDS_MF_BODY_NAME"
+msgstr "名前"
+
+msgid "IDS_MF_SK_DETAILS"
+msgstr "詳細"
+
+msgid "IDS_MF_BODY_ANY"
+msgstr "どれか"
+
+msgid "IDS_MF_BODY_AVAILABLE_USES"
+msgstr "使用​可能"
+
+msgid "IDS_MF_BODY_EXECUTE"
+msgstr "実行"
+
+msgid "IDS_MF_BODY_FORWARDING"
+msgstr "転送"
+
+msgid "IDS_MF_BODY_IMPOSSIBLE"
+msgstr "不可"
+
+msgid "IDS_MF_BODY_MMC_DATA_IS_INITIALIZING_ING"
+msgstr "MMC​データ​を​インストール中..."
+
+msgid "IDS_MF_BODY_POSSIBLE"
+msgstr "可能"
+
+msgid "IDS_MF_BODY_PRINT"
+msgstr "印刷"
+
+msgid "IDS_MF_BODY_VALIDITY"
+msgstr "有効性"
+
+msgid "IDS_MF_HEADER_NEW_FOLDER"
+msgstr "新規フォルダー"
+
+msgid "IDS_MF_OPT_EDIT"
+msgstr "編集"
+
+msgid "IDS_MF_OPT_LIST_BY"
+msgstr "ソート"
+
+msgid "IDS_MF_OPT_MOVE_HERE"
+msgstr "ここに​移動"
+
+msgid "IDS_MF_POP_CONTINUE"
+msgstr "次へ"
+
+msgid "IDS_MF_POP_COPYING"
+msgstr "コピー中..."
+
+msgid "IDS_MF_POP_MOVING"
+msgstr "移動中..."
+
+msgid "IDS_MF_POP_PASTE_HERE"
+msgstr "ここにコピー"
+
+msgid "IDS_MF_POP_UNSUPPORTED_FILE_TYPE"
+msgstr "未対応のファイルです"
+
+msgid "IDS_MF_OPT_DETAIL_VIEW"
+msgstr "詳細​表示"
+
+msgid "IDS_MF_POP_ASCENDING"
+msgstr "昇順"
+
+msgid "IDS_MF_POP_DESCENDING"
+msgstr "降順"
+
diff --git a/po/ko.po b/po/ko.po
new file mode 100644
index 0000000..5be8a5c
--- /dev/null
+++ b/po/ko.po
@@ -0,0 +1,155 @@
+# SOME DESCRIPTIVE TITLE.
+# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
+# This file is distributed under the same license as the PACKAGE package.
+# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
+#
+#, fuzzy
+msgid ""
+msgstr ""
+"Project-Id-Version: PACKAGE VERSION\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2010-06-16 18:18+0900\n"
+"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
+"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
+"Language-Team: LANGUAGE <LL@li.org>\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=UTF-8\n"
+"Content-Transfer-Encoding: 8bit\n"
+
+#: src_sg/myfile_sg_lib.c:98 src_sg/myfile_sg_lib.c:482
+#: src_sg/myfile_sg_lib.c:518 src_sg/myfile_sg_lib.c:901
+msgid "IDS_COM_SK_OK"
+msgstr "확인"
+
+#: src_sg/myfile_sg_lib.c:478 src_sg/myfile_sg_lib.c:894
+msgid "IDS_COM_BODY_BACK"
+msgstr "이전"
+
+#: src_sg/myfile_sg_lib.c:504 src_sg/myfile_sg_lib.c:897
+#: src_sg/myfile_sg_lib.c:942
+msgid "IDS_COM_BODY_DELETE"
+msgstr "삭제"
+
+#: src_sg/myfile_sg_lib.c:517
+msgid "Select at least one item"
+msgstr ""
+
+msgid "IDS_MF_BODY_ANY"
+msgstr "모든 종류"
+
+msgid "IDS_MF_BODY_AVAILABLE_USES"
+msgstr "사용 가능"
+
+msgid "IDS_MF_BODY_CREATE_FOLDER"
+msgstr "폴더 추가"
+
+msgid "IDS_MF_BODY_DATE"
+msgstr "날짜"
+
+msgid "IDS_MF_BODY_DONE"
+msgstr "완료"
+
+msgid "IDS_MF_BODY_EXECUTE"
+msgstr "실행"
+
+msgid "IDS_MF_BODY_FORWARDING"
+msgstr "전송"
+
+msgid "IDS_MF_BODY_IMAGES"
+msgstr "이미지"
+
+msgid "IDS_MF_BODY_IMPOSSIBLE"
+msgstr "불가능"
+
+msgid "IDS_MF_BODY_MMC_DATA_IS_INITIALIZING_ING"
+msgstr "외장메모리 데이터 읽어오는 중…"
+
+msgid "IDS_MF_BODY_OTHERS"
+msgstr "기타"
+
+msgid "IDS_MF_BODY_POSSIBLE"
+msgstr "가능"
+
+msgid "IDS_MF_BODY_PRINT"
+msgstr "인쇄"
+
+msgid "IDS_MF_BODY_SIZE"
+msgstr "크기"
+
+msgid "IDS_MF_BODY_SOUNDS"
+msgstr "사운드"
+
+msgid "IDS_MF_BODY_VALIDITY"
+msgstr "유효 횟수"
+
+msgid "IDS_MF_BODY_VIDEOS"
+msgstr "동영상"
+
+msgid "IDS_MF_HEADER_NEW_FOLDER"
+msgstr "폴더 추가"
+
+msgid "IDS_MF_HEADER_PHONE"
+msgstr "휴대폰"
+
+msgid "IDS_MF_HEADER_RENAME"
+msgstr "이름 변경"
+
+msgid "IDS_MF_OPT_COPY"
+msgstr "복사"
+
+msgid "IDS_MF_OPT_DETAILS"
+msgstr "상세정보"
+
+msgid "IDS_MF_OPT_EDIT"
+msgstr "편집"
+
+msgid "IDS_MF_OPT_LISTBY_TYPE"
+msgstr "형식"
+
+msgid "IDS_MF_OPT_LIST_BY"
+msgstr "정렬"
+
+msgid "IDS_MF_OPT_MOVE"
+msgstr "이동"
+
+msgid "IDS_MF_OPT_MOVE_HERE"
+msgstr "여기로 이동"
+
+msgid "IDS_MF_OPT_RINGTONE"
+msgstr "벨소리"
+
+msgid "IDS_MF_OPT_WALLPAPER"
+msgstr "배경화면"
+
+msgid "IDS_MF_POP_CLOSE"
+msgstr "닫기"
+
+msgid "IDS_MF_POP_CONTINUE"
+msgstr "계속"
+
+msgid "IDS_MF_POP_COPYING"
+msgstr "복사 중..."
+
+msgid "IDS_MF_POP_DELETING_ING"
+msgstr "삭제 중..."
+
+msgid "IDS_MF_POP_DO_YOU_WANT_TO_UNLOCK_IT_NOW_Q"
+msgstr "지금 해제할까요?"
+
+msgid "IDS_MF_POP_MOVING"
+msgstr "이동 중..."
+
+msgid "IDS_MF_POP_PASTE_HERE"
+msgstr "여기로 복사"
+
+msgid "IDS_MF_POP_SELECT_ALL"
+msgstr "모두 선택"
+
+msgid "IDS_MF_POP_UNSUPPORTED_FILE_TYPE"
+msgstr "지원되지 않는 파일 형식입니다"
+
+msgid "IDS_MF_SK_ADD"
+msgstr "추가"
+
+msgid "IDS_MF_SK_CANCEL"
+msgstr "취소"
diff --git a/po/ko_KR.po b/po/ko_KR.po
new file mode 100644
index 0000000..e3ae9f6
--- /dev/null
+++ b/po/ko_KR.po
@@ -0,0 +1,158 @@
+msgid "IDS_MF_TAB_UP"
+msgstr "위로"
+
+msgid "IDS_MF_BUTTON_HOME"
+msgstr "홈"
+msgid "IDS_MF_BODY_ALERTS"
+msgstr "알림"
+
+msgid "IDS_MF_BODY_WALLPAPERS"
+msgstr "배경화면"
+
+msgid "IDS_MF_BODY_ACCESS_MORE_MY_ALBUM"
+msgstr "내 앨범"
+
+msgid "IDS_MF_BODY_MY_VIDEO_CLIPS"
+msgstr "내 동영상"
+
+msgid "IDS_MF_BODY_RIGHT_STATUS"
+msgstr "권한 유효 상태"
+
+msgid "IDS_MF_BODY_VENDOR"
+msgstr "판매자"
+
+msgid "IDS_MF_HEADER_COUNT"
+msgstr "횟수"
+
+msgid "IDS_MF_BODY_CONTAINS"
+msgstr "포함"
+
+msgid "IDS_MF_BODY_INDIVIDUAL"
+msgstr "개인"
+
+msgid "IDS_MF_BODY_INTERVAL"
+msgstr "간격"
+
+msgid "IDS_MF_BODY_RENAME_ABB"
+msgstr "이름 변경"
+
+msgid "IDS_MF_BODY_TIME"
+msgstr "시간"
+
+msgid "IDS_MF_BODY_TIMED_COUNT"
+msgstr "시간 경과 후 횟수 계산"
+
+msgid "IDS_MF_BODY_TYPE"
+msgstr "형식"
+
+msgid "IDS_MF_BODY_UNLIMITED"
+msgstr "제한 없음"
+
+msgid "IDS_MF_BUTTON_REPLACE_ABB"
+msgstr "교체"
+
+msgid "IDS_MF_OPT_CALLER_RINGTONE"
+msgstr "개인 벨소리"
+
+msgid "IDS_MF_OPT_LISTBY_NAME"
+msgstr "이름"
+
+msgid "IDS_MF_POP_COPIED"
+msgstr "복사되었습니다"
+
+msgid "IDS_MF_POP_MOVED"
+msgstr "이동되었습니다"
+
+msgid "IDS_MF_POP_NOTHING_SELECTED"
+msgstr "선택된 것이 없습니다"
+
+msgid "IDS_MF_POP_NOT_ENOUGH_HEAP_MEMORY"
+msgstr "힙메모리가 부족합니다"
+
+msgid "IDS_MF_POP_NOT_ENOUGH_MEMORY_DELETE_SOME_ITEMS"
+msgstr "저장 공간이 없습니다. 필요 없는 파일을 삭제하세요"
+
+msgid "IDS_MF_BODY_CREATED_DATE"
+msgstr "생성 날짜"
+
+msgid "IDS_MF_BODY_GPS_INFORMATION"
+msgstr "GPS 정보"
+
+msgid "IDS_MF_BODY_GPS_LATITUDE"
+msgstr "GPS 위도"
+
+msgid "IDS_MF_BODY_GPS_LONGITUDE"
+msgstr "GPS 경도"
+
+msgid "IDS_MF_BODY_GPS_VERSION"
+msgstr "GPS 버전"
+
+msgid "IDS_MF_BODY_NAME"
+msgstr "이름"
+
+msgid "IDS_MF_SK_DETAILS"
+msgstr "상세 정보"
+
+msgid "IDS_MF_BODY_ANY"
+msgstr "모든 종류"
+
+msgid "IDS_MF_BODY_AVAILABLE_USES"
+msgstr "사용 가능"
+
+msgid "IDS_MF_BODY_EXECUTE"
+msgstr "실행"
+
+msgid "IDS_MF_BODY_FORWARDING"
+msgstr "전송"
+
+msgid "IDS_MF_BODY_IMPOSSIBLE"
+msgstr "불가능"
+
+msgid "IDS_MF_BODY_MMC_DATA_IS_INITIALIZING_ING"
+msgstr "메모리 카드 데이터 초기화 중…"
+
+msgid "IDS_MF_BODY_POSSIBLE"
+msgstr "가능"
+
+msgid "IDS_MF_BODY_PRINT"
+msgstr "인쇄"
+
+msgid "IDS_MF_BODY_VALIDITY"
+msgstr "유효 횟수"
+
+msgid "IDS_MF_HEADER_NEW_FOLDER"
+msgstr "새 폴더"
+
+msgid "IDS_MF_OPT_EDIT"
+msgstr "편집"
+
+msgid "IDS_MF_OPT_LIST_BY"
+msgstr "정렬"
+
+msgid "IDS_MF_OPT_MOVE_HERE"
+msgstr "여기로 이동"
+
+msgid "IDS_MF_POP_CONTINUE"
+msgstr "계속"
+
+msgid "IDS_MF_POP_COPYING"
+msgstr "복사 중..."
+
+msgid "IDS_MF_POP_MOVING"
+msgstr "이동 중..."
+
+msgid "IDS_MF_POP_PASTE_HERE"
+msgstr "여기로 복사"
+
+msgid "IDS_MF_POP_UNSUPPORTED_FILE_TYPE"
+msgstr "지원되지 않는 파일 형식입니다"
+
+msgid "IDS_MF_OPT_DETAIL_VIEW"
+msgstr "상세정보 보기"
+
+msgid "IDS_MF_POP_ASCENDING"
+msgstr "오름차순"
+
+msgid "IDS_MF_POP_DESCENDING"
+msgstr "내림차순"
+
diff --git a/po/nl.po b/po/nl.po
new file mode 100644
index 0000000..1be7c74
--- /dev/null
+++ b/po/nl.po
@@ -0,0 +1,120 @@
+msgid "IDS_MF_BODY_ANY"
+msgstr "Alle"
+
+msgid "IDS_MF_BODY_AVAILABLE_USES"
+msgstr "Aantal keer dat het gebruikt mag worden"
+
+msgid "IDS_MF_BODY_CREATE_FOLDER"
+msgstr "Map maken"
+
+msgid "IDS_MF_BODY_DATE"
+msgstr "Datum"
+
+msgid "IDS_MF_BODY_DONE"
+msgstr "Gereed"
+
+msgid "IDS_MF_BODY_EXECUTE"
+msgstr "Uitvoeren"
+
+msgid "IDS_MF_BODY_FORWARDING"
+msgstr "Doorsturen"
+
+msgid "IDS_MF_BODY_IMAGES"
+msgstr "Afbeeldingen"
+
+msgid "IDS_MF_BODY_IMPOSSIBLE"
+msgstr "Niet mogelijk"
+
+msgid "IDS_MF_BODY_MMC_DATA_IS_INITIALIZING_ING"
+msgstr "MMC-gegevens worden geïnitialiseerd..."
+
+msgid "IDS_MF_BODY_OTHERS"
+msgstr "Overige"
+
+msgid "IDS_MF_BODY_POSSIBLE"
+msgstr "Mogelijk"
+
+msgid "IDS_MF_BODY_PRINT"
+msgstr "Afdrukken"
+
+msgid "IDS_MF_BODY_SIZE"
+msgstr "Grootte"
+
+msgid "IDS_MF_BODY_SOUNDS"
+msgstr "Geluiden"
+
+msgid "IDS_MF_BODY_VALIDITY"
+msgstr "Geldigheid"
+
+msgid "IDS_MF_BODY_VIDEOS"
+msgstr "Video's"
+
+msgid "IDS_MF_HEADER_NEW_FOLDER"
+msgstr "Nieuwe map"
+
+msgid "IDS_MF_HEADER_PHONE"
+msgstr "Telefoon"
+
+msgid "IDS_MF_HEADER_RENAME"
+msgstr "Naam wijzigen"
+
+msgid "IDS_MF_OPT_COPY"
+msgstr "Kopiëren"
+
+msgid "IDS_MF_OPT_DETAILS"
+msgstr "Details"
+
+msgid "IDS_MF_OPT_EDIT"
+msgstr "Wijzigen"
+
+msgid "IDS_MF_OPT_LISTBY_TYPE"
+msgstr "Type"
+
+msgid "IDS_MF_OPT_LIST_BY"
+msgstr "Sorteren op"
+
+msgid "IDS_MF_OPT_MOVE"
+msgstr "Verplaatsen"
+
+msgid "IDS_MF_OPT_MOVE_HERE"
+msgstr "Hier plaatsen"
+
+msgid "IDS_MF_OPT_RINGTONE"
+msgstr "Beltoon"
+
+msgid "IDS_MF_OPT_WALLPAPER"
+msgstr "Achtergrond"
+
+msgid "IDS_MF_POP_CLOSE"
+msgstr "Dichtbij"
+
+msgid "IDS_MF_POP_CONTINUE"
+msgstr "Doorgaan"
+
+msgid "IDS_MF_POP_COPYING"
+msgstr "Kopiëren..."
+
+msgid "IDS_MF_POP_DELETING_ING"
+msgstr "Wissen..."
+
+msgid "IDS_MF_POP_DO_YOU_WANT_TO_UNLOCK_IT_NOW_Q"
+msgstr "Wilt u het apparaat nu ontgrendelen?"
+
+msgid "IDS_MF_POP_MOVING"
+msgstr "Verplaatsen..."
+
+msgid "IDS_MF_POP_PASTE_HERE"
+msgstr "Hier kopiëren"
+
+msgid "IDS_MF_POP_SELECT_ALL"
+msgstr "Alles selecteren"
+
+msgid "IDS_MF_POP_UNSUPPORTED_FILE_TYPE"
+msgstr "Niet-ondersteund bestandstype"
+
+msgid "IDS_MF_SK_ADD"
+msgstr "Voeg toe"
+
+msgid "IDS_MF_SK_CANCEL"
+msgstr "Annul."
+
diff --git a/po/nl_NL.po b/po/nl_NL.po
new file mode 100644
index 0000000..e8621b2
--- /dev/null
+++ b/po/nl_NL.po
@@ -0,0 +1,158 @@
+msgid "IDS_MF_TAB_UP"
+msgstr "Omhoog"
+
+msgid "IDS_MF_BUTTON_HOME"
+msgstr "Startpagina"
+msgid "IDS_MF_BODY_ALERTS"
+msgstr "Waarschuwingen"
+
+msgid "IDS_MF_BODY_WALLPAPERS"
+msgstr "Achtergronden"
+
+msgid "IDS_MF_BODY_ACCESS_MORE_MY_ALBUM"
+msgstr "Mijn album"
+
+msgid "IDS_MF_BODY_MY_VIDEO_CLIPS"
+msgstr "Mijn videoclips"
+
+msgid "IDS_MF_BODY_RIGHT_STATUS"
+msgstr "Status rechten"
+
+msgid "IDS_MF_BODY_VENDOR"
+msgstr "Leverancier"
+
+msgid "IDS_MF_HEADER_COUNT"
+msgstr "Aantal"
+
+msgid "IDS_MF_BODY_CONTAINS"
+msgstr "Bevat"
+
+msgid "IDS_MF_BODY_INDIVIDUAL"
+msgstr "Individueel"
+
+msgid "IDS_MF_BODY_INTERVAL"
+msgstr "Interval"
+
+msgid "IDS_MF_BODY_RENAME_ABB"
+msgstr "Wijzig"
+
+msgid "IDS_MF_BODY_TIME"
+msgstr "Tijd"
+
+msgid "IDS_MF_BODY_TIMED_COUNT"
+msgstr "Speelduur"
+
+msgid "IDS_MF_BODY_TYPE"
+msgstr "Type"
+
+msgid "IDS_MF_BODY_UNLIMITED"
+msgstr "Onbeperkt"
+
+msgid "IDS_MF_BUTTON_REPLACE_ABB"
+msgstr "Vervang"
+
+msgid "IDS_MF_OPT_CALLER_RINGTONE"
+msgstr "Beltoon beller"
+
+msgid "IDS_MF_OPT_LISTBY_NAME"
+msgstr "Naam"
+
+msgid "IDS_MF_POP_COPIED"
+msgstr "Gekopieerd"
+
+msgid "IDS_MF_POP_MOVED"
+msgstr "Verplaatst"
+
+msgid "IDS_MF_POP_NOTHING_SELECTED"
+msgstr "Niets geselecteerd"
+
+msgid "IDS_MF_POP_NOT_ENOUGH_HEAP_MEMORY"
+msgstr "Onvoldoende heap-geheugen"
+
+msgid "IDS_MF_POP_NOT_ENOUGH_MEMORY_DELETE_SOME_ITEMS"
+msgstr "Onvoldoende geheugen. Wis een aantal items"
+
+msgid "IDS_MF_BODY_CREATED_DATE"
+msgstr "Aanmaakdatum"
+
+msgid "IDS_MF_BODY_GPS_INFORMATION"
+msgstr "GPS informatie"
+
+msgid "IDS_MF_BODY_GPS_LATITUDE"
+msgstr "GPS-breedtegraad"
+
+msgid "IDS_MF_BODY_GPS_LONGITUDE"
+msgstr "GPS-lengtegraad"
+
+msgid "IDS_MF_BODY_GPS_VERSION"
+msgstr "GPS-versie"
+
+msgid "IDS_MF_BODY_NAME"
+msgstr "Naam"
+
+msgid "IDS_MF_SK_DETAILS"
+msgstr "Details"
+
+msgid "IDS_MF_BODY_ANY"
+msgstr "Alle"
+
+msgid "IDS_MF_BODY_AVAILABLE_USES"
+msgstr "Aantal keer dat het gebruikt mag worden"
+
+msgid "IDS_MF_BODY_EXECUTE"
+msgstr "Uitvoeren"
+
+msgid "IDS_MF_BODY_FORWARDING"
+msgstr "Doorsturen"
+
+msgid "IDS_MF_BODY_IMPOSSIBLE"
+msgstr "Niet mogelijk"
+
+msgid "IDS_MF_BODY_MMC_DATA_IS_INITIALIZING_ING"
+msgstr "MMC-gegevens worden geïnitialiseerd..."
+
+msgid "IDS_MF_BODY_POSSIBLE"
+msgstr "Mogelijk"
+
+msgid "IDS_MF_BODY_PRINT"
+msgstr "Afdrukken"
+
+msgid "IDS_MF_BODY_VALIDITY"
+msgstr "Geldigheid"
+
+msgid "IDS_MF_HEADER_NEW_FOLDER"
+msgstr "Nieuwe map"
+
+msgid "IDS_MF_OPT_EDIT"
+msgstr "Wijzigen"
+
+msgid "IDS_MF_OPT_LIST_BY"
+msgstr "Sorteren op"
+
+msgid "IDS_MF_OPT_MOVE_HERE"
+msgstr "Hier plaatsen"
+
+msgid "IDS_MF_POP_CONTINUE"
+msgstr "Doorgaan"
+
+msgid "IDS_MF_POP_COPYING"
+msgstr "Kopiëren..."
+
+msgid "IDS_MF_POP_MOVING"
+msgstr "Verplaatsen..."
+
+msgid "IDS_MF_POP_PASTE_HERE"
+msgstr "Hier kopiëren"
+
+msgid "IDS_MF_POP_UNSUPPORTED_FILE_TYPE"
+msgstr "Niet-ondersteund bestandstype"
+
+msgid "IDS_MF_OPT_DETAIL_VIEW"
+msgstr "Detailweergave"
+
+msgid "IDS_MF_POP_ASCENDING"
+msgstr "Oplopend"
+
+msgid "IDS_MF_POP_DESCENDING"
+msgstr "Aflopend"
+
diff --git a/po/pt.po b/po/pt.po
new file mode 100644
index 0000000..4ed2697
--- /dev/null
+++ b/po/pt.po
@@ -0,0 +1,120 @@
+msgid "IDS_MF_BODY_ANY"
+msgstr "Qualquer"
+
+msgid "IDS_MF_BODY_AVAILABLE_USES"
+msgstr "Utilizações disponíveis"
+
+msgid "IDS_MF_BODY_CREATE_FOLDER"
+msgstr "Criar pasta"
+
+msgid "IDS_MF_BODY_DATE"
+msgstr "Data"
+
+msgid "IDS_MF_BODY_DONE"
+msgstr "Concluído"
+
+msgid "IDS_MF_BODY_EXECUTE"
+msgstr "Executar"
+
+msgid "IDS_MF_BODY_FORWARDING"
+msgstr "A reencaminhar"
+
+msgid "IDS_MF_BODY_IMAGES"
+msgstr "Imagens"
+
+msgid "IDS_MF_BODY_IMPOSSIBLE"
+msgstr "Impossível"
+
+msgid "IDS_MF_BODY_MMC_DATA_IS_INITIALIZING_ING"
+msgstr "Données MMC en cours d'initialisation..."
+
+msgid "IDS_MF_BODY_OTHERS"
+msgstr "Outros"
+
+msgid "IDS_MF_BODY_POSSIBLE"
+msgstr "Possível"
+
+msgid "IDS_MF_BODY_PRINT"
+msgstr "Imprimir"
+
+msgid "IDS_MF_BODY_SIZE"
+msgstr "Tamanho"
+
+msgid "IDS_MF_BODY_SOUNDS"
+msgstr "Sons"
+
+msgid "IDS_MF_BODY_VALIDITY"
+msgstr "Validade"
+
+msgid "IDS_MF_BODY_VIDEOS"
+msgstr "Vídeos"
+
+msgid "IDS_MF_HEADER_NEW_FOLDER"
+msgstr "Nova pasta"
+
+msgid "IDS_MF_HEADER_PHONE"
+msgstr "Telefone"
+
+msgid "IDS_MF_HEADER_RENAME"
+msgstr "Mudar nome"
+
+msgid "IDS_MF_OPT_COPY"
+msgstr "Copiar"
+
+msgid "IDS_MF_OPT_DETAILS"
+msgstr "Detalhes"
+
+msgid "IDS_MF_OPT_EDIT"
+msgstr "Editar"
+
+msgid "IDS_MF_OPT_LISTBY_TYPE"
+msgstr "Tipo"
+
+msgid "IDS_MF_OPT_LIST_BY"
+msgstr "Listar por"
+
+msgid "IDS_MF_OPT_MOVE"
+msgstr "Mover"
+
+msgid "IDS_MF_OPT_MOVE_HERE"
+msgstr "Mover para aqui"
+
+msgid "IDS_MF_OPT_RINGTONE"
+msgstr "Tom de toque"
+
+msgid "IDS_MF_OPT_WALLPAPER"
+msgstr "Fundo"
+
+msgid "IDS_MF_POP_CLOSE"
+msgstr "Fechar"
+
+msgid "IDS_MF_POP_CONTINUE"
+msgstr "Continuar"
+
+msgid "IDS_MF_POP_COPYING"
+msgstr "A copiar..."
+
+msgid "IDS_MF_POP_DELETING_ING"
+msgstr "A eliminar..."
+
+msgid "IDS_MF_POP_DO_YOU_WANT_TO_UNLOCK_IT_NOW_Q"
+msgstr "Quer desbloquear agora?"
+
+msgid "IDS_MF_POP_MOVING"
+msgstr "A mover..."
+
+msgid "IDS_MF_POP_PASTE_HERE"
+msgstr "Colar aqui"
+
+msgid "IDS_MF_POP_SELECT_ALL"
+msgstr "Seleccionar tudo"
+
+msgid "IDS_MF_POP_UNSUPPORTED_FILE_TYPE"
+msgstr "Tipo de ficheiro não suportado"
+
+msgid "IDS_MF_SK_ADD"
+msgstr "Adicionar"
+
+msgid "IDS_MF_SK_CANCEL"
+msgstr "Cancelar"
+
diff --git a/po/pt_PT.po b/po/pt_PT.po
new file mode 100644
index 0000000..8f34ed8
--- /dev/null
+++ b/po/pt_PT.po
@@ -0,0 +1,158 @@
+msgid "IDS_MF_TAB_UP"
+msgstr "Para cima"
+
+msgid "IDS_MF_BUTTON_HOME"
+msgstr "Início"
+msgid "IDS_MF_BODY_ALERTS"
+msgstr "Alertas"
+
+msgid "IDS_MF_BODY_WALLPAPERS"
+msgstr "Fundos"
+
+msgid "IDS_MF_BODY_ACCESS_MORE_MY_ALBUM"
+msgstr "O meu álbum"
+
+msgid "IDS_MF_BODY_MY_VIDEO_CLIPS"
+msgstr "Os meus clips de vídeo"
+
+msgid "IDS_MF_BODY_RIGHT_STATUS"
+msgstr "Estado dos direitos"
+
+msgid "IDS_MF_BODY_VENDOR"
+msgstr "Representante"
+
+msgid "IDS_MF_HEADER_COUNT"
+msgstr "Contagem"
+
+msgid "IDS_MF_BODY_CONTAINS"
+msgstr "Conteúdo"
+
+msgid "IDS_MF_BODY_INDIVIDUAL"
+msgstr "Individual"
+
+msgid "IDS_MF_BODY_INTERVAL"
+msgstr "Intervalo"
+
+msgid "IDS_MF_BODY_RENAME_ABB"
+msgstr "M. nm."
+
+msgid "IDS_MF_BODY_TIME"
+msgstr "Data"
+
+msgid "IDS_MF_BODY_TIMED_COUNT"
+msgstr "Contagem temporizada"
+
+msgid "IDS_MF_BODY_TYPE"
+msgstr "Tipo"
+
+msgid "IDS_MF_BODY_UNLIMITED"
+msgstr "Ilimitado"
+
+msgid "IDS_MF_BUTTON_REPLACE_ABB"
+msgstr "Subs."
+
+msgid "IDS_MF_OPT_CALLER_RINGTONE"
+msgstr "Toque do chamador"
+
+msgid "IDS_MF_OPT_LISTBY_NAME"
+msgstr "Nome"
+
+msgid "IDS_MF_POP_COPIED"
+msgstr "Copiado"
+
+msgid "IDS_MF_POP_MOVED"
+msgstr "Movido"
+
+msgid "IDS_MF_POP_NOTHING_SELECTED"
+msgstr "Nada seleccionado"
+
+msgid "IDS_MF_POP_NOT_ENOUGH_HEAP_MEMORY"
+msgstr "Memória de pilha insuficiente"
+
+msgid "IDS_MF_POP_NOT_ENOUGH_MEMORY_DELETE_SOME_ITEMS"
+msgstr "Memória insuficiente. Apague alguns itens"
+
+msgid "IDS_MF_BODY_CREATED_DATE"
+msgstr "Criado na data"
+
+msgid "IDS_MF_BODY_GPS_INFORMATION"
+msgstr "Informações de GPS"
+
+msgid "IDS_MF_BODY_GPS_LATITUDE"
+msgstr "Latitude GPS"
+
+msgid "IDS_MF_BODY_GPS_LONGITUDE"
+msgstr "Longitude GPS"
+
+msgid "IDS_MF_BODY_GPS_VERSION"
+msgstr "Versão GPS"
+
+msgid "IDS_MF_BODY_NAME"
+msgstr "Nome"
+
+msgid "IDS_MF_SK_DETAILS"
+msgstr "Detalhes"
+
+msgid "IDS_MF_BODY_ANY"
+msgstr "Qualquer"
+
+msgid "IDS_MF_BODY_AVAILABLE_USES"
+msgstr "Utilizações disponíveis"
+
+msgid "IDS_MF_BODY_EXECUTE"
+msgstr "Executar"
+
+msgid "IDS_MF_BODY_FORWARDING"
+msgstr "Reencaminhar"
+
+msgid "IDS_MF_BODY_IMPOSSIBLE"
+msgstr "Impossível"
+
+msgid "IDS_MF_BODY_MMC_DATA_IS_INITIALIZING_ING"
+msgstr "Os dados MMC estão a ser iniciados..."
+
+msgid "IDS_MF_BODY_POSSIBLE"
+msgstr "Possível"
+
+msgid "IDS_MF_BODY_PRINT"
+msgstr "Imprimir"
+
+msgid "IDS_MF_BODY_VALIDITY"
+msgstr "Validade"
+
+msgid "IDS_MF_HEADER_NEW_FOLDER"
+msgstr "Nova pasta"
+
+msgid "IDS_MF_OPT_EDIT"
+msgstr "Editar"
+
+msgid "IDS_MF_OPT_LIST_BY"
+msgstr "Listar por"
+
+msgid "IDS_MF_OPT_MOVE_HERE"
+msgstr "Mover para aqui"
+
+msgid "IDS_MF_POP_CONTINUE"
+msgstr "Continuar"
+
+msgid "IDS_MF_POP_COPYING"
+msgstr "A copiar..."
+
+msgid "IDS_MF_POP_MOVING"
+msgstr "A mover..."
+
+msgid "IDS_MF_POP_PASTE_HERE"
+msgstr "Colar aqui"
+
+msgid "IDS_MF_POP_UNSUPPORTED_FILE_TYPE"
+msgstr "Tipo de ficheiro não suportado"
+
+msgid "IDS_MF_OPT_DETAIL_VIEW"
+msgstr "Vista de detalhes"
+
+msgid "IDS_MF_POP_ASCENDING"
+msgstr "Ascendente"
+
+msgid "IDS_MF_POP_DESCENDING"
+msgstr "Descendente"
+
diff --git a/po/ru.po b/po/ru.po
new file mode 100644
index 0000000..4eb84d6
--- /dev/null
+++ b/po/ru.po
@@ -0,0 +1,120 @@
+msgid "IDS_MF_BODY_ANY"
+msgstr "Любой"
+
+msgid "IDS_MF_BODY_AVAILABLE_USES"
+msgstr "Доступно"
+
+msgid "IDS_MF_BODY_CREATE_FOLDER"
+msgstr "Создать папку"
+
+msgid "IDS_MF_BODY_DATE"
+msgstr "Дата"
+
+msgid "IDS_MF_BODY_DONE"
+msgstr "Готово"
+
+msgid "IDS_MF_BODY_EXECUTE"
+msgstr "Запуск"
+
+msgid "IDS_MF_BODY_FORWARDING"
+msgstr "Пересылка"
+
+msgid "IDS_MF_BODY_IMAGES"
+msgstr "Картинки"
+
+msgid "IDS_MF_BODY_IMPOSSIBLE"
+msgstr "Невозможно"
+
+msgid "IDS_MF_BODY_MMC_DATA_IS_INITIALIZING_ING"
+msgstr "Инициализация данных MMC..."
+
+msgid "IDS_MF_BODY_OTHERS"
+msgstr "Прочее"
+
+msgid "IDS_MF_BODY_POSSIBLE"
+msgstr "Возможно"
+
+msgid "IDS_MF_BODY_PRINT"
+msgstr "Печать"
+
+msgid "IDS_MF_BODY_SIZE"
+msgstr "Размер"
+
+msgid "IDS_MF_BODY_SOUNDS"
+msgstr "Звуки"
+
+msgid "IDS_MF_BODY_VALIDITY"
+msgstr "Период действия"
+
+msgid "IDS_MF_BODY_VIDEOS"
+msgstr "Видео"
+
+msgid "IDS_MF_HEADER_NEW_FOLDER"
+msgstr "Новая папка"
+
+msgid "IDS_MF_HEADER_PHONE"
+msgstr "Телефон"
+
+msgid "IDS_MF_HEADER_RENAME"
+msgstr "Переименовать"
+
+msgid "IDS_MF_OPT_COPY"
+msgstr "Копировать"
+
+msgid "IDS_MF_OPT_DETAILS"
+msgstr "Свойства"
+
+msgid "IDS_MF_OPT_EDIT"
+msgstr "Изменить"
+
+msgid "IDS_MF_OPT_LISTBY_TYPE"
+msgstr "Тип"
+
+msgid "IDS_MF_OPT_LIST_BY"
+msgstr "Сортировка по"
+
+msgid "IDS_MF_OPT_MOVE"
+msgstr "Переместить"
+
+msgid "IDS_MF_OPT_MOVE_HERE"
+msgstr "Переместить сюда"
+
+msgid "IDS_MF_OPT_RINGTONE"
+msgstr "Мелодия звонка"
+
+msgid "IDS_MF_OPT_WALLPAPER"
+msgstr "Обои"
+
+msgid "IDS_MF_POP_CLOSE"
+msgstr "Закрыть"
+
+msgid "IDS_MF_POP_CONTINUE"
+msgstr "Продолжить"
+
+msgid "IDS_MF_POP_COPYING"
+msgstr "Копирование..."
+
+msgid "IDS_MF_POP_DELETING_ING"
+msgstr "Удаление..."
+
+msgid "IDS_MF_POP_DO_YOU_WANT_TO_UNLOCK_IT_NOW_Q"
+msgstr "Разблокировать элемент?"
+
+msgid "IDS_MF_POP_MOVING"
+msgstr "Перемещение..."
+
+msgid "IDS_MF_POP_PASTE_HERE"
+msgstr "Вставить сюда"
+
+msgid "IDS_MF_POP_SELECT_ALL"
+msgstr "Выбрать все"
+
+msgid "IDS_MF_POP_UNSUPPORTED_FILE_TYPE"
+msgstr "Неподдерживаемый тип файла"
+
+msgid "IDS_MF_SK_ADD"
+msgstr "Добавить"
+
+msgid "IDS_MF_SK_CANCEL"
+msgstr "Отмена"
+
diff --git a/po/ru_RU.po b/po/ru_RU.po
new file mode 100644
index 0000000..9f0fefb
--- /dev/null
+++ b/po/ru_RU.po
@@ -0,0 +1,158 @@
+msgid "IDS_MF_TAB_UP"
+msgstr "Вверх"
+
+msgid "IDS_MF_BUTTON_HOME"
+msgstr "Домой"
+msgid "IDS_MF_BODY_ALERTS"
+msgstr "Оповещения"
+
+msgid "IDS_MF_BODY_WALLPAPERS"
+msgstr "Обои"
+
+msgid "IDS_MF_BODY_ACCESS_MORE_MY_ALBUM"
+msgstr "Мой альбом"
+
+msgid "IDS_MF_BODY_MY_VIDEO_CLIPS"
+msgstr "Мои видеоклипы"
+
+msgid "IDS_MF_BODY_RIGHT_STATUS"
+msgstr "Состояние прав"
+
+msgid "IDS_MF_BODY_VENDOR"
+msgstr "Поставщик"
+
+msgid "IDS_MF_HEADER_COUNT"
+msgstr "Количество"
+
+msgid "IDS_MF_BODY_CONTAINS"
+msgstr "Содержит"
+
+msgid "IDS_MF_BODY_INDIVIDUAL"
+msgstr "Индивидуальный"
+
+msgid "IDS_MF_BODY_INTERVAL"
+msgstr "Интервал"
+
+msgid "IDS_MF_BODY_RENAME_ABB"
+msgstr "Переим."
+
+msgid "IDS_MF_BODY_TIME"
+msgstr "Время"
+
+msgid "IDS_MF_BODY_TIMED_COUNT"
+msgstr "Счетчик"
+
+msgid "IDS_MF_BODY_TYPE"
+msgstr "Тип"
+
+msgid "IDS_MF_BODY_UNLIMITED"
+msgstr "Неограниченно"
+
+msgid "IDS_MF_BUTTON_REPLACE_ABB"
+msgstr "Заменить"
+
+msgid "IDS_MF_OPT_CALLER_RINGTONE"
+msgstr "Мелодия контакта"
+
+msgid "IDS_MF_OPT_LISTBY_NAME"
+msgstr "Имя"
+
+msgid "IDS_MF_POP_COPIED"
+msgstr "Скопировано"
+
+msgid "IDS_MF_POP_MOVED"
+msgstr "Перемещено"
+
+msgid "IDS_MF_POP_NOTHING_SELECTED"
+msgstr "Ничего не выбрано"
+
+msgid "IDS_MF_POP_NOT_ENOUGH_HEAP_MEMORY"
+msgstr "Недостаточно динамической памяти"
+
+msgid "IDS_MF_POP_NOT_ENOUGH_MEMORY_DELETE_SOME_ITEMS"
+msgstr "Недостаточно памяти. Удалите некоторые элементы"
+
+msgid "IDS_MF_BODY_CREATED_DATE"
+msgstr "Дата создания"
+
+msgid "IDS_MF_BODY_GPS_INFORMATION"
+msgstr "Информация GPS"
+
+msgid "IDS_MF_BODY_GPS_LATITUDE"
+msgstr "Широта по GPS"
+
+msgid "IDS_MF_BODY_GPS_LONGITUDE"
+msgstr "Долгота по GPS"
+
+msgid "IDS_MF_BODY_GPS_VERSION"
+msgstr "Версия GPS"
+
+msgid "IDS_MF_BODY_NAME"
+msgstr "Имя"
+
+msgid "IDS_MF_SK_DETAILS"
+msgstr "Сведения"
+
+msgid "IDS_MF_BODY_ANY"
+msgstr "Любой"
+
+msgid "IDS_MF_BODY_AVAILABLE_USES"
+msgstr "Доступно"
+
+msgid "IDS_MF_BODY_EXECUTE"
+msgstr "Запуск"
+
+msgid "IDS_MF_BODY_FORWARDING"
+msgstr "Пересылка"
+
+msgid "IDS_MF_BODY_IMPOSSIBLE"
+msgstr "Невозможно"
+
+msgid "IDS_MF_BODY_MMC_DATA_IS_INITIALIZING_ING"
+msgstr "Инициализация данных MMC..."
+
+msgid "IDS_MF_BODY_POSSIBLE"
+msgstr "Возможно"
+
+msgid "IDS_MF_BODY_PRINT"
+msgstr "Печать"
+
+msgid "IDS_MF_BODY_VALIDITY"
+msgstr "Период действия"
+
+msgid "IDS_MF_HEADER_NEW_FOLDER"
+msgstr "Новая папка"
+
+msgid "IDS_MF_OPT_EDIT"
+msgstr "Изменить"
+
+msgid "IDS_MF_OPT_LIST_BY"
+msgstr "Сортировка по"
+
+msgid "IDS_MF_OPT_MOVE_HERE"
+msgstr "Переместить сюда"
+
+msgid "IDS_MF_POP_CONTINUE"
+msgstr "Продолжить"
+
+msgid "IDS_MF_POP_COPYING"
+msgstr "Копирование..."
+
+msgid "IDS_MF_POP_MOVING"
+msgstr "Перемещение..."
+
+msgid "IDS_MF_POP_PASTE_HERE"
+msgstr "Вставить сюда"
+
+msgid "IDS_MF_POP_UNSUPPORTED_FILE_TYPE"
+msgstr "Неподдерживаемый тип файла"
+
+msgid "IDS_MF_OPT_DETAIL_VIEW"
+msgstr "Просмотр сведений"
+
+msgid "IDS_MF_POP_ASCENDING"
+msgstr "По возрастанию"
+
+msgid "IDS_MF_POP_DESCENDING"
+msgstr "По убыванию"
+
diff --git a/po/tk.po b/po/tk.po
new file mode 100644
index 0000000..826304e
--- /dev/null
+++ b/po/tk.po
@@ -0,0 +1,120 @@
+msgid "IDS_MF_BODY_ANY"
+msgstr "Herhangi"
+
+msgid "IDS_MF_BODY_AVAILABLE_USES"
+msgstr "Mevcut kullanımlar"
+
+msgid "IDS_MF_BODY_CREATE_FOLDER"
+msgstr "Klasör oluştur"
+
+msgid "IDS_MF_BODY_DATE"
+msgstr "Tarih"
+
+msgid "IDS_MF_BODY_DONE"
+msgstr "Kaydet"
+
+msgid "IDS_MF_BODY_EXECUTE"
+msgstr "Uygulama"
+
+msgid "IDS_MF_BODY_FORWARDING"
+msgstr "İletme"
+
+msgid "IDS_MF_BODY_IMAGES"
+msgstr "Resimler"
+
+msgid "IDS_MF_BODY_IMPOSSIBLE"
+msgstr "İmkansız"
+
+msgid "IDS_MF_BODY_MMC_DATA_IS_INITIALIZING_ING"
+msgstr "Os dados MMC estão a ser iniciados..."
+
+msgid "IDS_MF_BODY_OTHERS"
+msgstr "Diğerleri"
+
+msgid "IDS_MF_BODY_POSSIBLE"
+msgstr "Mümkün"
+
+msgid "IDS_MF_BODY_PRINT"
+msgstr "Yazdır"
+
+msgid "IDS_MF_BODY_SIZE"
+msgstr "Boyut"
+
+msgid "IDS_MF_BODY_SOUNDS"
+msgstr "Seslerim"
+
+msgid "IDS_MF_BODY_VALIDITY"
+msgstr "Geçerlilik"
+
+msgid "IDS_MF_BODY_VIDEOS"
+msgstr "Videolar"
+
+msgid "IDS_MF_HEADER_NEW_FOLDER"
+msgstr "Yeni klasör"
+
+msgid "IDS_MF_HEADER_PHONE"
+msgstr "Telefon"
+
+msgid "IDS_MF_HEADER_RENAME"
+msgstr "Yeniden adlandır"
+
+msgid "IDS_MF_OPT_COPY"
+msgstr "Kopyala"
+
+msgid "IDS_MF_OPT_DETAILS"
+msgstr "Ayrıntılar"
+
+msgid "IDS_MF_OPT_EDIT"
+msgstr "Düzenle"
+
+msgid "IDS_MF_OPT_LISTBY_TYPE"
+msgstr "Tür"
+
+msgid "IDS_MF_OPT_LIST_BY"
+msgstr "Listele"
+
+msgid "IDS_MF_OPT_MOVE"
+msgstr "Taşı"
+
+msgid "IDS_MF_OPT_MOVE_HERE"
+msgstr "Buraya taşı"
+
+msgid "IDS_MF_OPT_RINGTONE"
+msgstr "Zil sesi"
+
+msgid "IDS_MF_OPT_WALLPAPER"
+msgstr "Duvar kağıdı"
+
+msgid "IDS_MF_POP_CLOSE"
+msgstr "Kapat"
+
+msgid "IDS_MF_POP_CONTINUE"
+msgstr "Devam"
+
+msgid "IDS_MF_POP_COPYING"
+msgstr "Kopyalanıyor..."
+
+msgid "IDS_MF_POP_DELETING_ING"
+msgstr "Siliniyor..."
+
+msgid "IDS_MF_POP_DO_YOU_WANT_TO_UNLOCK_IT_NOW_Q"
+msgstr "Kilidi kaldırmak istiyor musunuz?"
+
+msgid "IDS_MF_POP_MOVING"
+msgstr "Taşıyor..."
+
+msgid "IDS_MF_POP_PASTE_HERE"
+msgstr "Buraya yapıştır"
+
+msgid "IDS_MF_POP_SELECT_ALL"
+msgstr "Hepsini seç"
+
+msgid "IDS_MF_POP_UNSUPPORTED_FILE_TYPE"
+msgstr "Desteklenmeyen dosya türü"
+
+msgid "IDS_MF_SK_ADD"
+msgstr "Ekle"
+
+msgid "IDS_MF_SK_CANCEL"
+msgstr "İptal"
+
diff --git a/po/tr_TR.po b/po/tr_TR.po
new file mode 100644
index 0000000..e77dfaf
--- /dev/null
+++ b/po/tr_TR.po
@@ -0,0 +1,159 @@
+msgid "IDS_MF_TAB_UP"
+msgstr "Yukarı"
+
+msgid "IDS_MF_BUTTON_HOME"
+msgstr "A.Syf"
+
+msgid "IDS_MF_BODY_ALERTS"
+msgstr "Uyarılar"
+
+msgid "IDS_MF_BODY_WALLPAPERS"
+msgstr "Duvar kağıtları"
+
+msgid "IDS_MF_BODY_ACCESS_MORE_MY_ALBUM"
+msgstr "Albümüm"
+
+msgid "IDS_MF_BODY_MY_VIDEO_CLIPS"
+msgstr "Video kliplerim"
+
+msgid "IDS_MF_BODY_RIGHT_STATUS"
+msgstr "Hak durumu"
+
+msgid "IDS_MF_BODY_VENDOR"
+msgstr "Sağlayıcı"
+
+msgid "IDS_MF_HEADER_COUNT"
+msgstr "sayım"
+
+msgid "IDS_MF_BODY_CONTAINS"
+msgstr "İçindekiler"
+
+msgid "IDS_MF_BODY_INDIVIDUAL"
+msgstr "Kişisel"
+
+msgid "IDS_MF_BODY_INTERVAL"
+msgstr "Aralık"
+
+msgid "IDS_MF_BODY_RENAME_ABB"
+msgstr "Y. adl"
+
+msgid "IDS_MF_BODY_TIME"
+msgstr "Saat"
+
+msgid "IDS_MF_BODY_TIMED_COUNT"
+msgstr "Zamanlı sayım"
+
+msgid "IDS_MF_BODY_TYPE"
+msgstr "Tür"
+
+msgid "IDS_MF_BODY_UNLIMITED"
+msgstr "Sınırsız"
+
+msgid "IDS_MF_BUTTON_REPLACE_ABB"
+msgstr "Değiştir"
+
+msgid "IDS_MF_OPT_CALLER_RINGTONE"
+msgstr "Arayan zil sesi tonu"
+
+msgid "IDS_MF_OPT_LISTBY_NAME"
+msgstr "İsim"
+
+msgid "IDS_MF_POP_COPIED"
+msgstr "Kopyalandı"
+
+msgid "IDS_MF_POP_MOVED"
+msgstr "Taşındı"
+
+msgid "IDS_MF_POP_NOTHING_SELECTED"
+msgstr "Bir şey seçilmedi"
+
+msgid "IDS_MF_POP_NOT_ENOUGH_HEAP_MEMORY"
+msgstr "Yeterli küme hafızası yok"
+
+msgid "IDS_MF_POP_NOT_ENOUGH_MEMORY_DELETE_SOME_ITEMS"
+msgstr "Yeterli hafıza yok. Bazı öğeleri silin."
+
+msgid "IDS_MF_BODY_CREATED_DATE"
+msgstr "Oluşturulma tarihi"
+
+msgid "IDS_MF_BODY_GPS_INFORMATION"
+msgstr "GPS bilgileri"
+
+msgid "IDS_MF_BODY_GPS_LATITUDE"
+msgstr "GPS enlem"
+
+msgid "IDS_MF_BODY_GPS_LONGITUDE"
+msgstr "GPS boylam"
+
+msgid "IDS_MF_BODY_GPS_VERSION"
+msgstr "GPS versiyonu"
+
+msgid "IDS_MF_BODY_NAME"
+msgstr "İsim"
+
+msgid "IDS_MF_SK_DETAILS"
+msgstr "Ayrıntılar"
+
+msgid "IDS_MF_BODY_ANY"
+msgstr "Herhangi"
+
+msgid "IDS_MF_BODY_AVAILABLE_USES"
+msgstr "Mevcut kullanımlar"
+
+msgid "IDS_MF_BODY_EXECUTE"
+msgstr "Uygulama"
+
+msgid "IDS_MF_BODY_FORWARDING"
+msgstr "İletme"
+
+msgid "IDS_MF_BODY_IMPOSSIBLE"
+msgstr "İmkansız"
+
+msgid "IDS_MF_BODY_MMC_DATA_IS_INITIALIZING_ING"
+msgstr "MMC verileri başlatılıyor..."
+
+msgid "IDS_MF_BODY_POSSIBLE"
+msgstr "Mümkün"
+
+msgid "IDS_MF_BODY_PRINT"
+msgstr "Yazdır"
+
+msgid "IDS_MF_BODY_VALIDITY"
+msgstr "Geçerlilik"
+
+msgid "IDS_MF_HEADER_NEW_FOLDER"
+msgstr "Yeni klasör"
+
+msgid "IDS_MF_OPT_EDIT"
+msgstr "Düzenle"
+
+msgid "IDS_MF_OPT_LIST_BY"
+msgstr "Listele"
+
+msgid "IDS_MF_OPT_MOVE_HERE"
+msgstr "Buraya taşı"
+
+msgid "IDS_MF_POP_CONTINUE"
+msgstr "Devam"
+
+msgid "IDS_MF_POP_COPYING"
+msgstr "Kopyalanıyor..."
+
+msgid "IDS_MF_POP_MOVING"
+msgstr "Taşıyor..."
+
+msgid "IDS_MF_POP_PASTE_HERE"
+msgstr "Buraya yapıştır"
+
+msgid "IDS_MF_POP_UNSUPPORTED_FILE_TYPE"
+msgstr "Desteklenmeyen dosya türü"
+
+msgid "IDS_MF_OPT_DETAIL_VIEW"
+msgstr "Ayrıntılı görünüm"
+
+msgid "IDS_MF_POP_ASCENDING"
+msgstr "Artan"
+
+msgid "IDS_MF_POP_DESCENDING"
+msgstr "Azalan"
+
diff --git a/po/ug-myfile-efl.pot b/po/ug-myfile-efl.pot
new file mode 100644
index 0000000..c89d2ef
--- /dev/null
+++ b/po/ug-myfile-efl.pot
@@ -0,0 +1,94 @@
+# SOME DESCRIPTIVE TITLE.
+# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
+# This file is distributed under the same license as the PACKAGE package.
+# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
+#
+#, fuzzy
+msgid ""
+msgstr ""
+"Project-Id-Version: PACKAGE VERSION\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2010-06-16 18:18+0900\n"
+"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
+"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
+"Language-Team: LANGUAGE <LL@li.org>\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=CHARSET\n"
+"Content-Transfer-Encoding: 8bit\n"
+
+#: src_sg/myfile_sg_lib.c:98 src_sg/myfile_sg_lib.c:482
+#: src_sg/myfile_sg_lib.c:518 src_sg/myfile_sg_lib.c:901
+msgid "IDS_COM_SK_OK"
+msgstr ""
+
+#: src_sg/myfile_sg_lib.c:478 src_sg/myfile_sg_lib.c:894
+msgid "IDS_COM_BODY_BACK"
+msgstr ""
+
+#: src_sg/myfile_sg_lib.c:504 src_sg/myfile_sg_lib.c:897
+#: src_sg/myfile_sg_lib.c:942
+msgid "IDS_COM_BODY_DELETE"
+msgstr ""
+
+#: src_sg/myfile_sg_lib.c:517
+msgid "Select at least one item"
+msgstr ""
+
+#. supporting multi-lang for default folders
+#: source/libraries/winset-wrapper/main/titlebar.c:24
+msgid "Images"
+msgstr ""
+
+#: source/libraries/winset-wrapper/main/titlebar.c:25
+msgid "IDS_MF_BODY_IMAGES"
+msgstr ""
+
+#: source/libraries/winset-wrapper/main/titlebar.c:27
+msgid "Videos"
+msgstr ""
+
+#: source/libraries/winset-wrapper/main/titlebar.c:28
+msgid "IDS_MF_BODY_VIDEOS"
+msgstr ""
+
+#: source/libraries/winset-wrapper/main/titlebar.c:30
+msgid "Sounds"
+msgstr ""
+
+#: source/libraries/winset-wrapper/main/titlebar.c:31
+msgid "IDS_MF_BODY_SOUNDS"
+msgstr ""
+
+#: source/libraries/winset-wrapper/main/titlebar.c:33
+msgid "Others"
+msgstr ""
+
+#: source/libraries/winset-wrapper/main/titlebar.c:34
+msgid "IDS_MF_BODY_OTHERS"
+msgstr ""
+
+#: source/libraries/winset-wrapper/main/tab.c:16
+#: source/libraries/winset-wrapper/main/tab.c:79
+#: source/libraries/winset-wrapper/main/tab.c:102
+#: source/libraries/winset-wrapper/main/popup.c:291
+msgid "IDS_COM_BODY_PHONE"
+msgstr ""
+
+#: source/libraries/winset-wrapper/main/tab.c:26
+#: source/libraries/winset-wrapper/main/tab.c:80
+#: source/libraries/winset-wrapper/main/tab.c:103
+#: source/libraries/winset-wrapper/main/popup.c:297
+msgid "IDS_COM_BODY_MEMORY_CARD"
+msgstr ""
+
+#: source/libraries/winset-wrapper/main/tab.c:28
+msgid "IDS_COM_BODY_ALL"
+msgstr ""
+
+#: source/libraries/winset-wrapper/main/tab.c:52
+msgid "FONT_NAME"
+msgstr ""
+
+#: source/libraries/winset-wrapper/main/popup.c:346
+msgid "IDS_COM_SK_CANCEL"
+msgstr ""
diff --git a/po/update-po.sh b/po/update-po.sh
new file mode 100644
index 0000000..ff5bff7
--- /dev/null
+++ b/po/update-po.sh
@@ -0,0 +1,57 @@
+#!/bin/sh
+
+PACKAGE=ug-myfile-efl
+SRCROOT=../
+POTFILES=POTFILES.in
+
+#ALL_LINGUAS= am az be ca cs da de el en_CA en_GB es et fi fr hr hu it ja ko lv mk ml ms nb ne nl pa pl pt pt_BR ru rw sk sl sr sr@Latn sv ta tr uk vi zh_CN zh_TW
+ALL_LINGUAS="en_US en_GB ja ko zh_CN"
+
+XGETTEXT=/usr/bin/xgettext
+MSGMERGE=/usr/bin/msgmerge
+
+echo -n "Make ${PACKAGE}.pot "
+if [ ! -e $POTFILES ] ; then
+ echo "$POTFILES not found"
+ exit 1
+fi
+
+$XGETTEXT --default-domain=${PACKAGE} --directory=${SRCROOT} \
+ --add-comments --keyword=_ --keyword=N_ --files-from=$POTFILES \
+&& test ! -f ${PACKAGE}.po \
+ || (rm -f ${PACKAGE}.pot && mv ${PACKAGE}.po ${PACKAGE}.pot)
+
+if [ $? -ne 0 ]; then
+ echo "error"
+ exit 1
+else
+ echo "done"
+fi
+
+for LANG in $ALL_LINGUAS; do
+ echo "$LANG : "
+
+ if [ ! -e $LANG.po ] ; then
+ sed 's/CHARSET/UTF-8/g' ${PACKAGE}.pot > ${LANG}.po
+ echo "${LANG}.po created"
+ else
+ if $MSGMERGE ${LANG}.po ${PACKAGE}.pot -o ${LANG}.new.po ; then
+ if cmp ${LANG}.po ${LANG}.new.po > /dev/null 2>&1; then
+ rm -f ${LANG}.new.po
+ else
+ if mv -f ${LANG}.new.po ${LANG}.po; then
+ echo ""
+ else
+ echo "msgmerge for $LANG.po failed: cannot move $LANG.new.po to $LANG.po" 1>&2
+ rm -f ${LANG}.new.po
+ exit 1
+ fi
+ fi
+ else
+ echo "msgmerge for $LANG failed!"
+ rm -f ${LANG}.new.po
+ fi
+ fi
+ echo ""
+done
+
diff --git a/po/zh_CN.po b/po/zh_CN.po
new file mode 100644
index 0000000..15f4371
--- /dev/null
+++ b/po/zh_CN.po
@@ -0,0 +1,158 @@
+msgid "IDS_MF_TAB_UP"
+msgstr "向上"
+
+msgid "IDS_MF_BUTTON_HOME"
+msgstr "主界面"
+msgid "IDS_MF_BODY_ALERTS"
+msgstr "提示"
+
+msgid "IDS_MF_BODY_WALLPAPERS"
+msgstr "墙纸"
+
+msgid "IDS_MF_BODY_ACCESS_MORE_MY_ALBUM"
+msgstr "我的相册"
+
+msgid "IDS_MF_BODY_MY_VIDEO_CLIPS"
+msgstr "我的录像片段"
+
+msgid "IDS_MF_BODY_RIGHT_STATUS"
+msgstr "授权状态"
+
+msgid "IDS_MF_BODY_VENDOR"
+msgstr "提供者"
+
+msgid "IDS_MF_HEADER_COUNT"
+msgstr "计数"
+
+msgid "IDS_MF_BODY_CONTAINS"
+msgstr "包括"
+
+msgid "IDS_MF_BODY_INDIVIDUAL"
+msgstr "个人"
+
+msgid "IDS_MF_BODY_INTERVAL"
+msgstr "间隔"
+
+msgid "IDS_MF_BODY_RENAME_ABB"
+msgstr "重命名"
+
+msgid "IDS_MF_BODY_TIME"
+msgstr "持续期间"
+
+msgid "IDS_MF_BODY_TIMED_COUNT"
+msgstr "计时"
+
+msgid "IDS_MF_BODY_TYPE"
+msgstr "类型"
+
+msgid "IDS_MF_BODY_UNLIMITED"
+msgstr "无限"
+
+msgid "IDS_MF_BUTTON_REPLACE_ABB"
+msgstr "替换"
+
+msgid "IDS_MF_OPT_CALLER_RINGTONE"
+msgstr "来电铃声"
+
+msgid "IDS_MF_OPT_LISTBY_NAME"
+msgstr "名称"
+
+msgid "IDS_MF_POP_COPIED"
+msgstr "已复制"
+
+msgid "IDS_MF_POP_MOVED"
+msgstr "已移动"
+
+msgid "IDS_MF_POP_NOTHING_SELECTED"
+msgstr "未选择"
+
+msgid "IDS_MF_POP_NOT_ENOUGH_HEAP_MEMORY"
+msgstr "堆存储器容量不足"
+
+msgid "IDS_MF_POP_NOT_ENOUGH_MEMORY_DELETE_SOME_ITEMS"
+msgstr "存储空间不足。请删除部分项目"
+
+msgid "IDS_MF_BODY_CREATED_DATE"
+msgstr "创建日期"
+
+msgid "IDS_MF_BODY_GPS_INFORMATION"
+msgstr "GPS 信息"
+
+msgid "IDS_MF_BODY_GPS_LATITUDE"
+msgstr "GPS纬度"
+
+msgid "IDS_MF_BODY_GPS_LONGITUDE"
+msgstr "GPS经度"
+
+msgid "IDS_MF_BODY_GPS_VERSION"
+msgstr "GPS 版本"
+
+msgid "IDS_MF_BODY_NAME"
+msgstr "名称"
+
+msgid "IDS_MF_SK_DETAILS"
+msgstr "详细信息"
+
+msgid "IDS_MF_BODY_ANY"
+msgstr "任何"
+
+msgid "IDS_MF_BODY_AVAILABLE_USES"
+msgstr "可用于"
+
+msgid "IDS_MF_BODY_EXECUTE"
+msgstr "执行"
+
+msgid "IDS_MF_BODY_FORWARDING"
+msgstr "转发"
+
+msgid "IDS_MF_BODY_IMPOSSIBLE"
+msgstr "不可以"
+
+msgid "IDS_MF_BODY_MMC_DATA_IS_INITIALIZING_ING"
+msgstr "正在初始化 MMC 数据..."
+
+msgid "IDS_MF_BODY_POSSIBLE"
+msgstr "可以"
+
+msgid "IDS_MF_BODY_PRINT"
+msgstr "打印"
+
+msgid "IDS_MF_BODY_VALIDITY"
+msgstr "有效"
+
+msgid "IDS_MF_HEADER_NEW_FOLDER"
+msgstr "新文件夹"
+
+msgid "IDS_MF_OPT_EDIT"
+msgstr "编辑"
+
+msgid "IDS_MF_OPT_LIST_BY"
+msgstr "排序方式"
+
+msgid "IDS_MF_OPT_MOVE_HERE"
+msgstr "移动到这里"
+
+msgid "IDS_MF_POP_CONTINUE"
+msgstr "继续"
+
+msgid "IDS_MF_POP_COPYING"
+msgstr "正在复制..."
+
+msgid "IDS_MF_POP_MOVING"
+msgstr "移动中..."
+
+msgid "IDS_MF_POP_PASTE_HERE"
+msgstr "粘贴至此"
+
+msgid "IDS_MF_POP_UNSUPPORTED_FILE_TYPE"
+msgstr "不支持的文件类型"
+
+msgid "IDS_MF_OPT_DETAIL_VIEW"
+msgstr "详情查看"
+
+msgid "IDS_MF_POP_ASCENDING"
+msgstr "升序"
+
+msgid "IDS_MF_POP_DESCENDING"
+msgstr "降序"
+
diff --git a/po/zh_HK.po b/po/zh_HK.po
new file mode 100644
index 0000000..0ee10ed
--- /dev/null
+++ b/po/zh_HK.po
@@ -0,0 +1,158 @@
+msgid "IDS_MF_TAB_UP"
+msgstr "向上"
+
+msgid "IDS_MF_BUTTON_HOME"
+msgstr "首頁"
+msgid "IDS_MF_BODY_ALERTS"
+msgstr "提示"
+
+msgid "IDS_MF_BODY_WALLPAPERS"
+msgstr "螢幕牆紙"
+
+msgid "IDS_MF_BODY_ACCESS_MORE_MY_ALBUM"
+msgstr "我的相簿"
+
+msgid "IDS_MF_BODY_MY_VIDEO_CLIPS"
+msgstr "我的短片"
+
+msgid "IDS_MF_BODY_RIGHT_STATUS"
+msgstr "版權狀態"
+
+msgid "IDS_MF_BODY_VENDOR"
+msgstr "供應商"
+
+msgid "IDS_MF_HEADER_COUNT"
+msgstr "計數"
+
+msgid "IDS_MF_BODY_CONTAINS"
+msgstr "包含"
+
+msgid "IDS_MF_BODY_INDIVIDUAL"
+msgstr "個人"
+
+msgid "IDS_MF_BODY_INTERVAL"
+msgstr "間隔"
+
+msgid "IDS_MF_BODY_RENAME_ABB"
+msgstr "重新命名"
+
+msgid "IDS_MF_BODY_TIME"
+msgstr "時間"
+
+msgid "IDS_MF_BODY_TIMED_COUNT"
+msgstr "計時"
+
+msgid "IDS_MF_BODY_TYPE"
+msgstr "類型"
+
+msgid "IDS_MF_BODY_UNLIMITED"
+msgstr "無限制"
+
+msgid "IDS_MF_BUTTON_REPLACE_ABB"
+msgstr "取代"
+
+msgid "IDS_MF_OPT_CALLER_RINGTONE"
+msgstr "聯絡人來電鈴聲"
+
+msgid "IDS_MF_OPT_LISTBY_NAME"
+msgstr "名稱"
+
+msgid "IDS_MF_POP_COPIED"
+msgstr "已複製"
+
+msgid "IDS_MF_POP_MOVED"
+msgstr "已移動"
+
+msgid "IDS_MF_POP_NOTHING_SELECTED"
+msgstr "無已選擇項目"
+
+msgid "IDS_MF_POP_NOT_ENOUGH_HEAP_MEMORY"
+msgstr "堆積記憶體不足"
+
+msgid "IDS_MF_POP_NOT_ENOUGH_MEMORY_DELETE_SOME_ITEMS"
+msgstr "記憶體不足。請刪除一些項目"
+
+msgid "IDS_MF_BODY_CREATED_DATE"
+msgstr "建立日期"
+
+msgid "IDS_MF_BODY_GPS_INFORMATION"
+msgstr "GPS 資訊"
+
+msgid "IDS_MF_BODY_GPS_LATITUDE"
+msgstr "GPS緯度"
+
+msgid "IDS_MF_BODY_GPS_LONGITUDE"
+msgstr "GPS經度"
+
+msgid "IDS_MF_BODY_GPS_VERSION"
+msgstr "GPS 版本"
+
+msgid "IDS_MF_BODY_NAME"
+msgstr "名稱"
+
+msgid "IDS_MF_SK_DETAILS"
+msgstr "詳細資料"
+
+msgid "IDS_MF_BODY_ANY"
+msgstr "任何"
+
+msgid "IDS_MF_BODY_AVAILABLE_USES"
+msgstr "可供使用"
+
+msgid "IDS_MF_BODY_EXECUTE"
+msgstr "執行"
+
+msgid "IDS_MF_BODY_FORWARDING"
+msgstr "轉寄中"
+
+msgid "IDS_MF_BODY_IMPOSSIBLE"
+msgstr "不可以"
+
+msgid "IDS_MF_BODY_MMC_DATA_IS_INITIALIZING_ING"
+msgstr "正在初始化 MMC 數據..."
+
+msgid "IDS_MF_BODY_POSSIBLE"
+msgstr "可以"
+
+msgid "IDS_MF_BODY_PRINT"
+msgstr "列印"
+
+msgid "IDS_MF_BODY_VALIDITY"
+msgstr "有效期"
+
+msgid "IDS_MF_HEADER_NEW_FOLDER"
+msgstr "新資料夾"
+
+msgid "IDS_MF_OPT_EDIT"
+msgstr "編輯"
+
+msgid "IDS_MF_OPT_LIST_BY"
+msgstr "排列按"
+
+msgid "IDS_MF_OPT_MOVE_HERE"
+msgstr "移到這裡"
+
+msgid "IDS_MF_POP_CONTINUE"
+msgstr "繼續"
+
+msgid "IDS_MF_POP_COPYING"
+msgstr "正在複製..."
+
+msgid "IDS_MF_POP_MOVING"
+msgstr "正在移動..."
+
+msgid "IDS_MF_POP_PASTE_HERE"
+msgstr "貼在這裡"
+
+msgid "IDS_MF_POP_UNSUPPORTED_FILE_TYPE"
+msgstr "不支援的檔案類型"
+
+msgid "IDS_MF_OPT_DETAIL_VIEW"
+msgstr "詳細檢視"
+
+msgid "IDS_MF_POP_ASCENDING"
+msgstr "升序"
+
+msgid "IDS_MF_POP_DESCENDING"
+msgstr "降序"
+
diff --git a/po/zh_TW.po b/po/zh_TW.po
new file mode 100644
index 0000000..3ba642e
--- /dev/null
+++ b/po/zh_TW.po
@@ -0,0 +1,158 @@
+msgid "IDS_MF_TAB_UP"
+msgstr "向上"
+
+msgid "IDS_MF_BUTTON_HOME"
+msgstr "家"
+msgid "IDS_MF_BODY_ALERTS"
+msgstr "提醒"
+
+msgid "IDS_MF_BODY_WALLPAPERS"
+msgstr "底色圖案"
+
+msgid "IDS_MF_BODY_ACCESS_MORE_MY_ALBUM"
+msgstr "我的相簿"
+
+msgid "IDS_MF_BODY_MY_VIDEO_CLIPS"
+msgstr "我的影片片段"
+
+msgid "IDS_MF_BODY_RIGHT_STATUS"
+msgstr "版權狀態"
+
+msgid "IDS_MF_BODY_VENDOR"
+msgstr "供應商"
+
+msgid "IDS_MF_HEADER_COUNT"
+msgstr "計數"
+
+msgid "IDS_MF_BODY_CONTAINS"
+msgstr "包含"
+
+msgid "IDS_MF_BODY_INDIVIDUAL"
+msgstr "個別"
+
+msgid "IDS_MF_BODY_INTERVAL"
+msgstr "間隔"
+
+msgid "IDS_MF_BODY_RENAME_ABB"
+msgstr "重新命名"
+
+msgid "IDS_MF_BODY_TIME"
+msgstr "時間"
+
+msgid "IDS_MF_BODY_TIMED_COUNT"
+msgstr "計時數"
+
+msgid "IDS_MF_BODY_TYPE"
+msgstr "類型"
+
+msgid "IDS_MF_BODY_UNLIMITED"
+msgstr "無限制"
+
+msgid "IDS_MF_BUTTON_REPLACE_ABB"
+msgstr "覆蓋"
+
+msgid "IDS_MF_OPT_CALLER_RINGTONE"
+msgstr "來電者鈴聲"
+
+msgid "IDS_MF_OPT_LISTBY_NAME"
+msgstr "名稱"
+
+msgid "IDS_MF_POP_COPIED"
+msgstr "已複製"
+
+msgid "IDS_MF_POP_MOVED"
+msgstr "已移動"
+
+msgid "IDS_MF_POP_NOTHING_SELECTED"
+msgstr "未選擇任何項目"
+
+msgid "IDS_MF_POP_NOT_ENOUGH_HEAP_MEMORY"
+msgstr "堆積記憶體不足"
+
+msgid "IDS_MF_POP_NOT_ENOUGH_MEMORY_DELETE_SOME_ITEMS"
+msgstr "記憶體不足。請刪除部分項目"
+
+msgid "IDS_MF_BODY_CREATED_DATE"
+msgstr "建立日期"
+
+msgid "IDS_MF_BODY_GPS_INFORMATION"
+msgstr "GPS 資訊"
+
+msgid "IDS_MF_BODY_GPS_LATITUDE"
+msgstr "GPS緯度"
+
+msgid "IDS_MF_BODY_GPS_LONGITUDE"
+msgstr "GPS經度"
+
+msgid "IDS_MF_BODY_GPS_VERSION"
+msgstr "GPS 版本"
+
+msgid "IDS_MF_BODY_NAME"
+msgstr "名稱"
+
+msgid "IDS_MF_SK_DETAILS"
+msgstr "詳細資料"
+
+msgid "IDS_MF_BODY_ANY"
+msgstr "任何"
+
+msgid "IDS_MF_BODY_AVAILABLE_USES"
+msgstr "可供使用"
+
+msgid "IDS_MF_BODY_EXECUTE"
+msgstr "執行"
+
+msgid "IDS_MF_BODY_FORWARDING"
+msgstr "正在轉寄"
+
+msgid "IDS_MF_BODY_IMPOSSIBLE"
+msgstr "不可能"
+
+msgid "IDS_MF_BODY_MMC_DATA_IS_INITIALIZING_ING"
+msgstr "正在初始化 MMC 資料..."
+
+msgid "IDS_MF_BODY_POSSIBLE"
+msgstr "可能"
+
+msgid "IDS_MF_BODY_PRINT"
+msgstr "列印"
+
+msgid "IDS_MF_BODY_VALIDITY"
+msgstr "有效期"
+
+msgid "IDS_MF_HEADER_NEW_FOLDER"
+msgstr "新資料夾"
+
+msgid "IDS_MF_OPT_EDIT"
+msgstr "編輯"
+
+msgid "IDS_MF_OPT_LIST_BY"
+msgstr "排列依據"
+
+msgid "IDS_MF_OPT_MOVE_HERE"
+msgstr "移到這裡"
+
+msgid "IDS_MF_POP_CONTINUE"
+msgstr "繼續"
+
+msgid "IDS_MF_POP_COPYING"
+msgstr "正在複製..."
+
+msgid "IDS_MF_POP_MOVING"
+msgstr "正在移動..."
+
+msgid "IDS_MF_POP_PASTE_HERE"
+msgstr "在此貼上"
+
+msgid "IDS_MF_POP_UNSUPPORTED_FILE_TYPE"
+msgstr "不支援的檔案類型"
+
+msgid "IDS_MF_OPT_DETAIL_VIEW"
+msgstr "詳細查看"
+
+msgid "IDS_MF_POP_ASCENDING"
+msgstr "遞增"
+
+msgid "IDS_MF_POP_DESCENDING"
+msgstr "遞減"
+
diff --git a/src/common/file-system/mf-ug-file-attr.c b/src/common/file-system/mf-ug-file-attr.c
new file mode 100755
index 0000000..082e394
--- /dev/null
+++ b/src/common/file-system/mf-ug-file-attr.c
@@ -0,0 +1,1072 @@
+/*
+ * Copyright 2012 Samsung Electronics Co., Ltd
+ *
+ * Licensed under the Flora License, Version 1.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.tizenopensource.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 <regex.h>
+#include <sys/types.h>
+#include <aul.h>
+#include <visual-svc.h>
+#include <media-svc.h>
+#include "mf-ug-fs-util.h"
+
+#define MF_UG_PHONE_DEFAULT_LEVEL 2 /*the phone path is /opt/media, it consists of opt and media two parts*/
+#define MF_UG_MMC_DEFAULT_LEVEL 3 /*the mmc path is /opt/storage/sdcard, it consists of opt and storage and sdcard three parts*/
+
+struct _ug_ftype_by_mime {
+ const char *mime;
+ mf_ug_fs_file_type ftype;
+};
+
+static struct _ug_ftype_by_mime mime_type[] = {
+ {"image/png", UG_FILE_TYPE_IMAGE},
+ {"image/jpeg", UG_FILE_TYPE_IMAGE},
+ {"image/gif", UG_FILE_TYPE_IMAGE},
+ {"image/bmp", UG_FILE_TYPE_IMAGE},
+ {"image/vnd.wap.wbmp", UG_FILE_TYPE_IMAGE},
+
+ {"video/x-msvideo", UG_FILE_TYPE_VIDEO},
+ {"video/mp4", UG_FILE_TYPE_VIDEO},
+ {"video/3gpp", UG_FILE_TYPE_VIDEO},
+ {"video/x-ms-asf", UG_FILE_TYPE_VIDEO},
+ {"video/x-ms-wmv", UG_FILE_TYPE_VIDEO},
+ {"video/x-matroska", UG_FILE_TYPE_VIDEO},
+
+ {"audio/mpeg", UG_FILE_TYPE_MUSIC},
+ {"audio/x-wav", UG_FILE_TYPE_MUSIC},
+ {"application/x-smaf", UG_FILE_TYPE_MUSIC},
+ {"audio/mxmf", UG_FILE_TYPE_MUSIC},
+ {"audio/midi", UG_FILE_TYPE_MUSIC},
+ {"audio/x-xmf", UG_FILE_TYPE_MUSIC},
+ {"audio/x-ms-wma", UG_FILE_TYPE_MUSIC},
+ {"audio/aac", UG_FILE_TYPE_MUSIC},
+ {"audio/ac3", UG_FILE_TYPE_MUSIC},
+ {"audio/ogg", UG_FILE_TYPE_MUSIC},
+ {"audio/vorbis", UG_FILE_TYPE_MUSIC},
+ {"audio/imelody", UG_FILE_TYPE_MUSIC},
+ {"audio/iMelody", UG_FILE_TYPE_MUSIC},
+ {"audio/x-rmf", UG_FILE_TYPE_MUSIC},
+ {"application/vnd.smaf", UG_FILE_TYPE_MUSIC},
+ {"audio/mobile-xmf", UG_FILE_TYPE_MUSIC},
+ {"audio/mid", UG_FILE_TYPE_MUSIC},
+ {"audio/vnd.ms-playready.media.pya", UG_FILE_TYPE_MUSIC},
+ {"audio/imy", UG_FILE_TYPE_MUSIC},
+ {"audio/m4a", UG_FILE_TYPE_MUSIC},
+ {"audio/melody", UG_FILE_TYPE_MUSIC},
+ {"audio/mmf", UG_FILE_TYPE_MUSIC},
+ {"audio/mp3", UG_FILE_TYPE_MUSIC},
+ {"audio/mp4", UG_FILE_TYPE_MUSIC},
+ {"audio/MP4A-LATM", UG_FILE_TYPE_MUSIC},
+ {"audio/mpeg3", UG_FILE_TYPE_MUSIC},
+ {"audio/mpeg4", UG_FILE_TYPE_MUSIC},
+ {"audio/mpg", UG_FILE_TYPE_MUSIC},
+ {"audio/mpg3", UG_FILE_TYPE_MUSIC},
+ {"audio/smaf", UG_FILE_TYPE_MUSIC},
+ {"audio/sp-midi", UG_FILE_TYPE_MUSIC},
+ {"audio/wav", UG_FILE_TYPE_MUSIC},
+ {"audio/wave", UG_FILE_TYPE_MUSIC},
+ {"audio/wma", UG_FILE_TYPE_MUSIC},
+ {"audio/xmf", UG_FILE_TYPE_MUSIC},
+ {"audio/x-mid", UG_FILE_TYPE_MUSIC},
+ {"audio/x-midi", UG_FILE_TYPE_MUSIC},
+ {"audio/x-mp3", UG_FILE_TYPE_MUSIC},
+ {"audio/-mpeg", UG_FILE_TYPE_MUSIC},
+ {"audio/x-mpeg", UG_FILE_TYPE_MUSIC},
+ {"audio/x-mpegaudio", UG_FILE_TYPE_MUSIC},
+ {"audio/x-mpg", UG_FILE_TYPE_MUSIC},
+ {"audio/x-ms-asf", UG_FILE_TYPE_MUSIC},
+ {"audio/x-wave", UG_FILE_TYPE_MUSIC},
+
+ {"application/pdf", UG_FILE_TYPE_PDF},
+
+ {"application/msword", UG_FILE_TYPE_DOC},
+ {"application/vnd.openxmlformats-officedocument.wordprocessingml.document", UG_FILE_TYPE_DOC},
+
+ {"application/vnd.ms-powerpoint", UG_FILE_TYPE_PPT},
+ {"application/vnd.openxmlformats-officedocument.presentationml.presentation", UG_FILE_TYPE_PPT},
+
+ {"application/vnd.ms-excel", UG_FILE_TYPE_EXCEL},
+ {"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet", UG_FILE_TYPE_EXCEL},
+
+ {"audio/AMR", UG_FILE_TYPE_VOICE},
+ {"audio/AMR-WB", UG_FILE_TYPE_VOICE},
+ {"audio/amr", UG_FILE_TYPE_VOICE},
+ {"audio/amr-wb", UG_FILE_TYPE_VOICE},
+ {"audio/x-amr", UG_FILE_TYPE_VOICE},
+
+ {"text/html", UG_FILE_TYPE_HTML},
+
+ {"application/x-shockwave-flash", UG_FILE_TYPE_FLASH},
+ {"video/x-flv", UG_FILE_TYPE_FLASH},
+
+ {"text/plain", UG_FILE_TYPE_TXT},
+
+ {"text/x-opml+xml", UG_FILE_TYPE_RSS},
+
+ {"text/vnd.sun.j2me.app-descriptor", UG_FILE_TYPE_JAVA},
+ {"application/x-java-archive", UG_FILE_TYPE_JAVA},
+
+ {NULL, UG_FILE_TYPE_ETC},
+};
+
+static char *icon_array[UG_FILE_TYPE_MAX] = {
+ [UG_FILE_TYPE_DIR] = UG_ICON_FOLDER,
+ [UG_FILE_TYPE_IMAGE] = UG_ICON_IMAGE,
+ [UG_FILE_TYPE_VIDEO] = UG_ICON_VIDEO,
+ [UG_FILE_TYPE_MUSIC] = UG_ICON_MUSIC,
+ [UG_FILE_TYPE_SOUND] = UG_ICON_SOUND,
+ [UG_FILE_TYPE_PDF] = UG_ICON_PDF,
+ [UG_FILE_TYPE_DOC] = UG_ICON_DOC,
+ [UG_FILE_TYPE_PPT] = UG_ICON_PPT,
+ [UG_FILE_TYPE_EXCEL] = UG_ICON_EXCEL,
+ [UG_FILE_TYPE_VOICE] = UG_ICON_VOICE,
+ [UG_FILE_TYPE_HTML] = UG_ICON_HTML,
+ [UG_FILE_TYPE_FLASH] = UG_ICON_FLASH,
+ [UG_FILE_TYPE_TXT] = UG_ICON_TXT,
+ [UG_FILE_TYPE_VCONTACT] = UG_ICON_VCONTACT,
+ [UG_FILE_TYPE_VCALENDAR] = UG_ICON_VCALENDAR,
+ [UG_FILE_TYPE_VNOTE] = UG_ICON_VNOTE,
+ [UG_FILE_TYPE_RSS] = UG_ICON_RSS,
+ [UG_FILE_TYPE_JAVA] = UG_ICON_JAVA,
+};
+
+/*********************
+**Function name: __mf_ug_file_attr_get_category_by_file_ext
+**Parameter: const char* file_ext
+**Return value: mf_ug_fs_file_type
+**
+**Action:
+** Get file category by extention
+**
+*********************/
+static mf_ug_fs_file_type __mf_ug_file_attr_get_category_by_file_ext(const char *file_ext, const char *fullpath)
+{
+ int i = 0;
+
+ if (file_ext == NULL) {
+ return UG_FILE_TYPE_ETC;
+ }
+
+ if (file_ext[0] == '.') {
+ i = 1;
+ }
+
+ switch (file_ext[i]) {
+ case 'a':
+ case 'A':
+ if (strcasecmp("ASF", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_VIDEO;
+ }
+ if (strcasecmp("AMR", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_VOICE;
+ }
+ if (strcasecmp("AWB", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_VOICE;
+ }
+ if (strcasecmp("AAC", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_MUSIC;
+ }
+ if (strcasecmp("AVI", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_VIDEO;
+ }
+ if (strcasecmp("AAC", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_MUSIC;
+ }
+
+ break;
+ case 'b':
+ case 'B':
+ if (strcasecmp("BMP", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_IMAGE;
+ }
+ break;
+ case 'd':
+ case 'D':
+ if (strcasecmp("DOC", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_DOC;
+ }
+ if (strcasecmp("DOCX", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_DOC;
+ }
+ if (strcasecmp("DIVX", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_VIDEO;
+ }
+ break;
+ case 'g':
+ case 'G':
+ if (strcasecmp("GIF", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_IMAGE;
+ }
+ if (strcasecmp("G72", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_MUSIC;
+ }
+ break;
+ case 'h':
+ case 'H':
+ if (strcasecmp("H263", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_MUSIC;
+ }
+ if (strcasecmp("HTML", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_HTML;
+ }
+ if (strcasecmp("HTM", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_HTML;
+ }
+ break;
+ case 'i':
+ case 'I':
+ if (strcasecmp("IMY", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_SOUND;
+ }
+ if (strcasecmp("IPK", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_APP;
+ }
+ break;
+ case 'j':
+ case 'J':
+ if (strcasecmp("JAD", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_JAVA;
+ }
+ if (strcasecmp("JAR", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_JAVA;
+ }
+
+ if (strcasecmp("JPG", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_IMAGE;
+ }
+ if (strcasecmp("JPEG", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_IMAGE;
+ }
+ if (strcasecmp("JPE", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_IMAGE;
+ }
+ break;
+ case 'm':
+ case 'M':
+ if (strcasecmp("MMF", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_SOUND;
+ }
+ if (strcasecmp("MP3", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_MUSIC;
+ }
+ if (strcasecmp("MID", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_SOUND;
+ }
+ if (strcasecmp("MIDI", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_SOUND;
+ }
+ if (strcasecmp("MP4", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_VIDEO;
+ }
+ if (strcasecmp("MPG", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_VIDEO;
+ }
+ if (strcasecmp("MPEG", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_VIDEO;
+ }
+ if (strcasecmp("M4A", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_MUSIC;
+ }
+ if (strcasecmp("M3G", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_FLASH;
+ }
+ if (strcasecmp("MXMF", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_SOUND;
+ }
+ if (strcasecmp("MKV", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_VIDEO;
+ }
+ if (strcasecmp("MKA", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_MUSIC;
+ }
+ break;
+ case 'o':
+ case 'O':
+ if (strcasecmp("opml", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_RSS;
+ }
+ break;
+ case 'p':
+ case 'P':
+ if (strcasecmp("PNG", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_IMAGE;
+ }
+ if (strcasecmp("PJPEG", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_IMAGE;
+ }
+ if (strcasecmp("PDF", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_PDF;
+ }
+ if (strcasecmp("PPT", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_PPT;
+ }
+ if (strcasecmp("PPTX", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_PPT;
+ }
+ if (strcasecmp("PEM", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_CERTIFICATION;
+ }
+ break;
+ case 'r':
+ case 'R':
+ break;
+ case 's':
+ case 'S':
+ if (strcasecmp("SDP", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_VIDEO;
+ }
+ if (strcasecmp("SPM", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_SOUND;
+ }
+ if (strcasecmp("SMP", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_SOUND;
+ }
+ if (strcasecmp("SPF", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_SOUND;
+ }
+ if (strcasecmp("SWF", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_FLASH;
+ }
+ if (strcasecmp("SCN", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_MOVIE_MAKER;
+ }
+ if (strcasecmp("SVG", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_SVG;
+ }
+ if (strcasecmp("SVGZ", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_SVG;
+ }
+ break;
+ case 't':
+ case 'T':
+ if (strcasecmp("TXT", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_TXT;
+ }
+ if (strcasecmp("THM", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_THEME;
+ }
+ break;
+ case 'v':
+ case 'V':
+ if (strcasecmp("VCF", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_VCONTACT;
+ }
+ if (strcasecmp("VCS", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_VCALENDAR;
+ }
+ if (strcasecmp("VNT", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_VNOTE;
+ }
+ if (strcasecmp("VBM", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_VBOOKMARK;
+ }
+ break;
+ case 'w':
+ case 'W':
+ if (strcasecmp("WAV", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_SOUND;
+ }
+ if (strcasecmp("WBMP", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_IMAGE;
+ }
+ if (strcasecmp("WGT", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_WGT;
+ }
+ if (strcasecmp("WMA", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_MUSIC;
+ }
+ if (strcasecmp("WMV", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_VIDEO;
+ }
+ break;
+ case 'x':
+ case 'X':
+ if (strcasecmp("XLS", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_EXCEL;
+ }
+ if (strcasecmp("XLSX", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_EXCEL;
+ }
+ if (strcasecmp("XMF", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_SOUND;
+ }
+ if (strcasecmp("XHTML", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_HTML;
+ }
+ break;
+ case '3':
+ if (strcasecmp("3GP", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_VIDEO;
+ }
+ if (strcasecmp("3GPP", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_VIDEO;
+ }
+ if (strcasecmp("3G2", &file_ext[i]) == 0) {
+ return UG_FILE_TYPE_VIDEO;
+ }
+ break;
+ }
+
+ return UG_FILE_TYPE_ETC;
+}
+
+/*********************
+**Function name: __mf_ug_file_attr_is_valid_name
+**Parameter:
+** const char *filename: the file/dir name we need to check
+**
+**Return value:
+** -0x14 if the name is invalid
+** 0 if the name is valid
+**
+**Action:
+** check if the name is valid by file name
+**
+*********************/
+static int __mf_ug_file_attr_is_valid_name(const char *filename)
+{
+ char *pattern;
+ int ret, z, cflags = 0;
+ char ebuf[128];
+ regex_t reg;
+ regmatch_t pm[1];
+ const size_t nmatch = 1;
+ /*/ToDo: ignore the file star with . */
+ if (strncmp(filename, ".", 1) == 0) {
+ return MYFILE_ERR_INVALID_FILE_NAME;
+ }
+
+ pattern = MYFILE_NAME_PATTERN;
+ z = regcomp(&reg, pattern, cflags);
+
+ if (z != 0) {
+ regerror(z, &reg, ebuf, sizeof(ebuf));
+ fprintf(stderr, "%s: pattern '%s' \n", ebuf, pattern);
+ return MYFILE_ERR_INVALID_FILE_NAME;
+ }
+
+ z = regexec(&reg, filename, nmatch, pm, 0);
+ if (z == REG_NOMATCH) {
+ ret = MYFILE_ERR_NONE;
+ } else {
+ ret = MYFILE_ERR_INVALID_FILE_NAME;
+ }
+ regfree(&reg);
+ return ret;
+}
+
+
+/******************************
+** Prototype : __mf_ug_file_attr_default_icon_get_by_type
+** Description : Samsung
+** Input : mf_ug_fs_file_type ftype
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+static char *__mf_ug_file_attr_default_icon_get_by_type(mf_ug_fs_file_type ftype)
+{
+ char *icon_path = NULL;
+
+ if (icon_array[ftype]) {
+ icon_path = strdup(icon_array[ftype]);
+ } else {
+ icon_path = strdup(UG_DEFAULT_ICON);
+ }
+
+ return icon_path;
+}
+
+
+/******************************
+** Prototype : mf_ug_file_attr_get_parent_path
+** Description : Samsung
+** Input : const char* path
+** char* parent_path
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+int mf_ug_file_attr_get_parent_path(const char *path, char **parent_path)
+{
+ ug_mf_retvm_if(path == NULL, MYFILE_ERR_INVALID_ARG, "path is NULL");
+ ug_mf_retvm_if(parent_path == NULL, MYFILE_ERR_INVALID_ARG, "parent_path is NULL");
+ ug_debug("Path :::: [%s]", path);
+
+ *parent_path = g_strdup(path);
+ if (*parent_path == NULL)
+ return MYFILE_ERR_ALLOCATE_FAIL;
+
+ const char *name = NULL;
+ name = ecore_file_file_get(path);
+ /*
+ ** input path and parent_path are check in the caller.
+ ** parent_path is full path must be like /opt/media/file.ext
+ ** name is file.ext
+ ** strlen(parent_path) should large than strlen(name) normally.
+ ** to take exception like input path is "", we add a if condition
+ */
+ if (strlen(*parent_path) > strlen(name))
+ (*parent_path)[strlen(*parent_path) - strlen(name) - 1] = '\0';
+
+ if (strlen(*parent_path) == 0) {
+ *parent_path = g_strdup("/");
+ }
+
+ return MYFILE_ERR_NONE;
+}
+
+
+/*********************
+**Function name: mf_get_category
+**Parameter:
+** const char* filepath: file fullpath
+** mf_ug_fs_file_type *category: output parameter of category
+**Return value:
+** error code
+**
+**Action:
+** Get file category by file full path
+**
+*********************/
+int mf_ug_file_attr_get_file_category(const char *filepath, mf_ug_fs_file_type * category)
+{
+ int i = 0;
+ int flag = 0;
+
+ if (mf_ug_file_attr_is_dir(filepath)) {
+ *category = UG_FILE_TYPE_DIR;
+ return MYFILE_ERR_NONE;
+ }
+
+ const char *filename = NULL;
+ filename = ecore_file_file_get(filepath);
+ /*/return value ceck */
+ if (filename == NULL) {
+ *category = UG_FILE_TYPE_NONE;
+ return MYFILE_ERR_SRC_ARG_INVALID;
+ }
+ char file_ext[FILE_EXT_LEN_MAX + 1] = { 0 };
+ /*/ToDo: error file name like the last letter is "." */
+ for (i = strlen(filename); i >= 0; i--) {
+ if (filename[i] == '.') {
+ strncpy(file_ext, &filename[i + 1], FILE_EXT_LEN_MAX + 1);
+ flag = 1;
+ break;
+ }
+
+ if (filename[i] == '/') {
+ flag = 0;
+ break;
+ }
+ }
+
+ if (flag == 1) {
+ *category = __mf_ug_file_attr_get_category_by_file_ext(file_ext, filepath);
+ return MYFILE_ERR_NONE;
+ } else {
+ *category = UG_FILE_TYPE_NONE;
+ return MYFILE_ERR_GET_CATEGORY_FAIL;
+ }
+}
+
+/*********************
+**Function name: mf_ug_file_attr_get_file_stat
+**Parameter:
+** const char* filename: file name
+** ugFsNodeInfo **node: output parameter of what we need to refine
+**Return value:
+** error code
+**
+**Action:
+** Get file size and last modified date by file path
+**
+*********************/
+int mf_ug_file_attr_get_file_stat(const char *filename, ugFsNodeInfo ** node)
+{
+ struct stat statbuf;
+
+ ug_mf_retvm_if(filename == NULL, MYFILE_ERR_INVALID_ARG, "filename is null");
+ ug_mf_retvm_if(node == NULL, MYFILE_ERR_INVALID_ARG, "node is null");
+
+ if (stat(filename, &statbuf) == -1) {
+ return MYFILE_ERR_GET_STAT_FAIL;
+ }
+
+ (*node)->size = statbuf.st_size;
+ (*node)->date = statbuf.st_mtime;
+
+ return MYFILE_ERR_NONE;
+}
+
+/*********************
+**Function name: mf_ug_file_attr_is_dir
+**Parameter:
+** const char* filename: file fullpath
+**Return value:
+** if path is a directory, return 1
+** else, return 0
+**
+**Action:
+** check if the file path is Directory
+**
+*********************/
+int mf_ug_file_attr_is_dir(const char *filepath)
+{
+ return ecore_file_is_dir(filepath);
+}
+
+/*********************
+**Function name: mf_ug_file_attr_get_store_type_by_full
+**Parameter:
+** const char* filepath: file full path
+** mf_ug_storage_type *store_type: output parameter of storage type
+**Return value:
+** error code
+**
+**Action:
+** Get file storage type by file path
+**
+*********************/
+int mf_ug_file_attr_get_store_type_by_full(const char *filepath, mf_ug_storage_type * store_type)
+{
+ if (filepath == NULL || store_type == NULL) {
+ return MYFILE_ERR_SRC_ARG_INVALID;
+ }
+
+ if (strncmp(filepath, PHONE_FOLDER, strlen(PHONE_FOLDER)) == 0) {
+ *store_type = MF_UG_PHONE;
+ return MYFILE_ERR_NONE;
+ } else if (strncmp(filepath, MEMORY_FOLDER, strlen(MEMORY_FOLDER)) == 0) {
+ *store_type = MF_UG_MMC;
+ return MYFILE_ERR_NONE;
+ } else {
+ *store_type = MF_UG_NONE;
+ return MYFILE_ERR_STORAGE_TYPE_ERROR;
+ }
+}
+
+/*********************
+**Function name: mf_ug_file_attr_get_file_ext
+**Parameter:
+** const char* filepath: file full path
+** char *file_ext: output parameter of file extension
+**
+**Return value:
+** error code
+**
+**Action:
+** get file extension by file full path
+**
+*********************/
+int mf_ug_file_attr_get_file_ext(const char *filepath, char *file_ext)
+{
+ const char *filename = NULL;
+ filename = ecore_file_file_get(filepath);
+
+ if (filename == NULL) {
+ return MYFILE_ERR_INVALID_FILE_NAME;
+ }
+
+ char *pdot = strrchr(filename, '.');
+
+ if (!pdot) {
+ return MYFILE_ERR_EXT_GET_ERROR;
+ } else if (pdot != filepath) {
+ memcpy(file_ext, pdot + 1, strlen(pdot) - 1);
+ return MYFILE_ERR_NONE;
+ } else {
+ return MYFILE_ERR_EXT_GET_ERROR;
+ }
+}
+
+
+
+/*********************
+**Function name: mf_ug_file_attr_is_right_dir_path
+**Parameter:
+** const char *filename: the file/dir name we need to check
+**
+**Return value:
+** error code
+**
+**Action:
+** check if the dir path is correct
+**
+*********************/
+int mf_ug_file_attr_is_right_dir_path(const char *dir_path)
+{
+ int result = MYFILE_ERR_NONE;
+ int length = 0;
+
+ length = strlen(dir_path);
+ if (length == 0) {
+ return MYFILE_ERR_INVALID_DIR_PATH;
+ }
+
+ if (dir_path[length - 1] == '/' && length > 1) {
+ return MYFILE_ERR_INVALID_DIR_PATH;
+ }
+
+ if (dir_path[0] != '/') {
+ return MYFILE_ERR_INVALID_DIR_PATH;
+ }
+
+ const char *file_name = NULL;
+ file_name = ecore_file_file_get(dir_path);
+ result = __mf_ug_file_attr_is_valid_name(file_name);
+
+ if (result != MYFILE_ERR_NONE) {
+ ug_mf_error("Is NOT Valid dir path name");
+ }
+
+ return result;
+}
+
+/*********************
+**Function name: mf_ug_file_attr_is_right_file_path
+**Parameter:
+** const char *filename: the file/dir name we need to check
+**
+**Return value:
+** error code
+**
+**Action:
+** check if the file path is correct
+**
+*********************/
+int mf_ug_file_attr_is_right_file_path(const char *file_path)
+{
+ int result = MYFILE_ERR_NONE;
+
+ if (strlen(file_path) == 0) {
+ return MYFILE_ERR_INVALID_FILE_PATH;
+ }
+
+ if (file_path[0] != '/') {
+ return MYFILE_ERR_INVALID_DIR_PATH;
+ }
+
+ const char *file_name = NULL;
+ file_name = ecore_file_file_get(file_path);
+ result = __mf_ug_file_attr_is_valid_name(file_name);
+ if (result != MYFILE_ERR_NONE) {
+ ug_mf_error("Is NOT Valid dir path name");
+ }
+
+ return result;
+}
+
+
+
+char *mf_ug_file_attr_get_file_icon(MediaSvcHandle *handle, const char *file_path, int *error_code)
+{
+ int index = 0;
+ char *icon_path = NULL;
+ mf_ug_fs_file_type ftype = UG_FILE_TYPE_NONE;
+ char *thumbnail_path = NULL;
+ char mime[255] = { '\0', };
+
+ ug_mf_retvm_if(file_path == NULL, NULL, "file_path is NULL");
+
+
+ if (aul_get_mime_from_file(file_path, mime, sizeof(mime)) < 0) {
+ ug_mf_warnig("Fail to aul_get_mime_from_file(), set etc icon");
+ return g_strdup(icon_path);
+ }
+
+ for (index = 0; mime_type[index].mime; index++) {
+ if (strncmp(mime, mime_type[index].mime, strlen(mime)) == 0) {
+ ftype = mime_type[index].ftype;
+ break;
+ }
+ }
+
+ switch (ftype) {
+ case UG_FILE_TYPE_IMAGE:
+ {
+ int err = 0;
+ thumbnail_path = calloc(1, (MYFILE_FILE_PATH_LEN_MAX + 1));
+ if (thumbnail_path == NULL) {
+ return NULL;
+ }
+
+ err = minfo_get_thumb_path(handle, file_path, thumbnail_path, MYFILE_FILE_PATH_LEN_MAX);
+ if (err == 0) {
+ icon_path = thumbnail_path;
+ } else {
+ icon_path = NULL;
+ if (error_code)
+ *error_code = err;
+ }
+ }
+ break;
+ case UG_FILE_TYPE_VIDEO:
+ {
+ int err = 0;
+ thumbnail_path = calloc(1, (MYFILE_FILE_PATH_LEN_MAX + 1));
+ if (thumbnail_path == NULL) {
+ return NULL;
+ }
+
+ err = minfo_get_thumb_path_for_video(handle, file_path, thumbnail_path, MYFILE_FILE_PATH_LEN_MAX);
+
+ if (err == 0) {
+ icon_path = thumbnail_path;
+ } else {
+ icon_path = NULL;
+ if (error_code)
+ *error_code = err;
+ }
+ }
+ break;
+ default:
+ icon_path = __mf_ug_file_attr_default_icon_get_by_type(ftype);
+ break;
+ }
+
+ ug_mf_debug("mime [%s], file type [%d], icon_path [%s]", mime, ftype, icon_path);
+
+ return icon_path;
+}
+
+static int mf_ug_file_attr_get_path_level(const char *fullpath, int *level)
+{
+ if (fullpath == NULL) {
+ return MYFILE_ERR_SRC_ARG_INVALID;
+ }
+
+ if (mf_ug_file_attr_is_right_dir_path(fullpath) != 0) {
+ return MYFILE_ERR_INVALID_PATH;
+ }
+
+ mf_ug_storage_type storage_t = 0;
+ int start_level = 0;
+ int error_code = mf_ug_file_attr_get_store_type_by_full(fullpath, &storage_t);
+ if (error_code != 0) {
+ return error_code;
+ }
+
+ if (storage_t == MF_UG_PHONE) {
+ start_level = MF_UG_PHONE_DEFAULT_LEVEL;
+ } else if (storage_t == MF_UG_MMC) {
+ start_level = MF_UG_MMC_DEFAULT_LEVEL;
+ }
+
+ char *temp = strdup(fullpath);
+ if (temp == NULL) {
+ return MYFILE_ERR_UNKNOW_ERROR;
+ }
+
+ int count = 0;
+
+ gchar **result = NULL;
+ gchar **params = NULL;
+ result = g_strsplit(temp, "/", 0);
+
+ if (result == NULL) {
+ free(temp);
+ temp = NULL;
+ return MYFILE_ERR_UNKNOW_ERROR;
+ }
+
+ for (params = result; *params; params++) {
+ count++;
+ }
+
+ g_strfreev(result);
+ *level = count - start_level - 1;
+ free(temp);
+ return MYFILE_ERR_NONE;
+
+}
+
+
+int mf_ug_file_attr_is_in_system_folder(char *fullpath, int level, bool * result)
+{
+ if (fullpath == NULL) {
+ return MYFILE_ERR_SRC_ARG_INVALID;
+ }
+
+ mf_ug_storage_type storage_t = 0;
+ int error_code = mf_ug_file_attr_get_store_type_by_full(fullpath, &storage_t);
+ if (error_code != 0) {
+ return error_code;
+ }
+
+ const char *name = NULL;
+ name = ecore_file_file_get(fullpath);
+ char *parent_path = malloc(MYFILE_DIR_PATH_LEN_MAX + 1);
+
+ if (parent_path == NULL) {
+ return MYFILE_ERR_ALLOCATE_FAIL;
+ }
+ memset(parent_path, 0, MYFILE_DIR_PATH_LEN_MAX + 1);
+ error_code = mf_ug_file_attr_get_parent_path(fullpath, &parent_path);
+
+ if (error_code != 0) {
+ return error_code;
+ }
+
+ if (storage_t == MF_UG_PHONE || storage_t == MF_UG_MMC) {
+ if (level == 1) {
+ if ((strlen(name) == strlen(IMAGE_AND_VIDEO)) && strcmp(name, IMAGE_AND_VIDEO) == 0) {
+ *result = true;
+ } else if ((strlen(name) == strlen(SOUND_AND_MUSIC)) && strcmp(name, SOUND_AND_MUSIC) == 0) {
+ *result = true;
+ } else if ((strlen(name) == strlen(DOWNLOADS)) && strcmp(name, DOWNLOADS) == 0) {
+ *result = true;
+ } else if ((strlen(name) == strlen(CAMERA_SHOTS)) && strcmp(name, CAMERA_SHOTS) == 0) {
+ *result = true;
+ } else {
+ *result = false;
+ }
+ } else if (level == 2) {
+ const char *parent_name = NULL;
+ parent_name = ecore_file_file_get(parent_path);
+ if (storage_t == MF_UG_PHONE && (strlen(parent_name) == strlen(DOWNLOADS)) && strcmp(parent_name, DOWNLOADS) == 0) {
+ if ((strlen(name) == strlen(OTHERS)) && !strcmp(OTHERS, name)) {
+ *result = true;
+ } else {
+ *result = false;
+ }
+ } else if ((strlen(parent_name) == strlen(SOUND_AND_MUSIC)) && strcmp(parent_name, SOUND_AND_MUSIC) == 0) {
+ if ((strlen(name) == strlen(FM_RADIO)) && !strcmp(FM_RADIO, name)) {
+ *result = true;
+ } else if ((strlen(name) == strlen(MUSIC)) && !strcmp(MUSIC, name)) {
+ *result = true;
+ } else if ((strlen(name) == strlen(RINGTONES)) && !strcmp(RINGTONES, name)) {
+ *result = true;
+ } else if ((strlen(name) == strlen(ALERTS)) && !strcmp(ALERTS, name)) {
+ *result = true;
+ } else if ((strlen(name) == strlen(VOICE_RECORDER)) && !strcmp(VOICE_RECORDER, name)) {
+ *result = true;
+ } else {
+ *result = false;
+ }
+ } else if ((strlen(parent_name) == strlen(IMAGE_AND_VIDEO)) && strcmp(parent_name, IMAGE_AND_VIDEO) == 0) {
+ if ((strlen(name) == strlen(WALLPAPER)) && !strcmp(WALLPAPER, name)) {
+ *result = true;
+ } else if ((strlen(name) == strlen(MY_PHOTO_CLIPS)) && !strcmp(MY_PHOTO_CLIPS, name)) {
+ *result = true;
+ } else if ((strlen(name) == strlen(MY_ALBUM)) && !strcmp(MY_ALBUM, name)) {
+ *result = true;
+ } else if ((strlen(name) == strlen(MY_VIDEO_CLIPS)) && !strcmp(MY_VIDEO_CLIPS, name)) {
+ *result = true;
+ } else {
+ *result = false;
+ }
+ } else {
+ *result = false;
+ }
+ } else {
+ if (parent_path) {
+ free(parent_path);
+ parent_path = NULL;
+ }
+ return MYFILE_ERR_STORAGE_TYPE_ERROR;
+ }
+ }
+
+ else {
+ if (parent_path) {
+ free(parent_path);
+ parent_path = NULL;
+ }
+ *result = false;
+ return MYFILE_ERR_STORAGE_TYPE_ERROR;
+ }
+
+ if (parent_path) {
+ free(parent_path);
+ parent_path = NULL;
+ }
+ return MYFILE_ERR_NONE;
+}
+
+
+int mf_ug_file_attr_is_system_dir(char *fullpath, bool * result)
+{
+ if (fullpath == NULL) {
+ ug_debug("source argument invalid");
+ return MYFILE_ERR_SRC_ARG_INVALID;
+ }
+
+ if (mf_ug_file_attr_is_dir(fullpath) == 0) {
+ ug_debug("source is not exist");
+ return MYFILE_ERR_SRC_NOT_EXIST;
+ }
+
+ int level = 0;
+ int error_code = 0;
+
+ error_code = mf_ug_file_attr_get_path_level(fullpath, &level);
+ if (error_code != 0) {
+ ug_debug("Fail to get path level");
+ return error_code;
+ }
+
+ if (level >= 3 || level <= 0) {
+ *result = false;
+ ug_debug("Path Level is wrong");
+ return MYFILE_ERR_NONE;
+ }
+ error_code = mf_ug_file_attr_is_in_system_folder(fullpath, level, result);
+
+ if (error_code != 0) {
+ ug_debug("Fail .. is in system folder err :: %d", error_code);
+ return error_code;
+ }
+
+ return MYFILE_ERR_NONE;
+
+}
+
+mf_ug_fs_file_type mf_ug_file_attr_get_file_type_by_mime(const char *file_path)
+{
+ int index;
+ mf_ug_fs_file_type ftype = UG_FILE_TYPE_NONE;
+ char mime[255] = { '\0', };
+
+ if (aul_get_mime_from_file(file_path, mime, sizeof(mime)) < 0) {
+ ug_debug("Fail to aul_get_mime_from_file(), set etc icon");
+ return ftype;
+ }
+
+ for (index = 0; mime_type[index].mime; index++) {
+ if (strncmp(mime, mime_type[index].mime, strlen(mime)) == 0) {
+ ftype = mime_type[index].ftype;
+ return ftype;
+ }
+ }
+
+ return ftype;
+}
diff --git a/src/common/file-system/mf-ug-fs-oper.c b/src/common/file-system/mf-ug-fs-oper.c
new file mode 100755
index 0000000..71fa889
--- /dev/null
+++ b/src/common/file-system/mf-ug-fs-oper.c
@@ -0,0 +1,381 @@
+/*
+ * Copyright 2012 Samsung Electronics Co., Ltd
+ *
+ * Licensed under the Flora License, Version 1.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.tizenopensource.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 <libgen.h>
+#include <glib.h>
+#include "mf-ug-fs-util.h"
+
+
+
+/*********************
+**Function name: __mf_ug_fs_oper_file_system_error
+**Parameter:
+** const char* src: source path
+** const char* dst: destination path
+** int check_option: check option
+**
+**Return value:
+** error code
+**
+**Action:
+** input parameter checking
+**
+*********************/
+static int __mf_ug_fs_oper_file_system_error(const char *src, const char *dst, int check_option)
+{
+ if ((check_option & MF_ERROR_CHECK_SRC_ARG_VALID) && (src == NULL)) {
+ return MYFILE_ERR_SRC_ARG_INVALID;
+ }
+ if ((check_option & MF_ERROR_CHECK_SRC_EXIST) && (!ecore_file_exists(src))) {
+ return MYFILE_ERR_SRC_NOT_EXIST;
+ }
+
+ if (check_option & MF_ERROR_CHECK_SRC_PATH_VALID) {
+ if (!ecore_file_is_dir(src)) {
+ if (mf_ug_file_attr_is_right_file_path(src)) {
+ return MYFILE_ERR_INVALID_FILE_PATH;
+ }
+ } else {
+ if (mf_ug_file_attr_is_right_dir_path(src)) {
+ return MYFILE_ERR_INVALID_DIR_PATH;
+ }
+ }
+ }
+ return MYFILE_ERR_NONE;
+}
+
+/*********************
+**Function name: mf_ug_fs_oper_read_dir
+**Parameter:
+** char *path: path which we need to read
+** Eina_List** dir_list: output parameter of dir list under specified path
+** Eina_List** file_list: output parameter of file list under specified path
+**
+**Return value:
+** error code
+**
+**Action:
+** read element under the specified path
+**
+*********************/
+int mf_ug_fs_oper_read_dir(const char *path, Eina_List **dir_list, Eina_List **file_list)
+{
+ DIR *pDir = NULL;
+ struct dirent *ent;
+
+ ug_mf_retvm_if(path == NULL, MYFILE_ERR_INVALID_ARG, "path is null");
+ ug_mf_retvm_if(dir_list == NULL, MYFILE_ERR_INVALID_ARG, "dir_list is null");
+ ug_mf_retvm_if(file_list == NULL, MYFILE_ERR_INVALID_ARG, "file_list is null");
+
+ int option = MF_ERROR_CHECK_SRC_ARG_VALID | MF_ERROR_CHECK_SRC_EXIST | MF_ERROR_CHECK_SRC_PATH_VALID;
+ int ret = __mf_ug_fs_oper_file_system_error(path, NULL, option);
+
+ if (ret != MYFILE_ERR_NONE) {
+ return ret;
+ }
+
+ pDir = opendir(path);
+
+ if (pDir == NULL) {
+ return MYFILE_ERR_DIR_OPEN_FAIL;
+ }
+
+ while ((ent = readdir(pDir)) != NULL) {
+ GString *childpath = NULL;
+ ugFsNodeInfo *pNode = NULL;
+
+ if (strncmp(ent->d_name, ".", 1) == 0 || strcmp(ent->d_name, "..") == 0) {
+ continue;
+ }
+
+ if ((ent->d_type & DT_DIR) == 0 && (ent->d_type & DT_REG) == 0) {
+ continue;
+ }
+#ifdef UG_DEBUG_FOLDER_OPTION
+ if ((ent->d_type & DT_DIR) != 0) {
+ if ((strlen(path) == strlen(PHONE_FOLDER)) && (strcmp(path, PHONE_FOLDER) == 0)
+ && (strlen(ent->d_name) == strlen(DEBUG_FOLDER)) && (strcmp(ent->d_name, DEBUG_FOLDER) == 0)) {
+ continue;
+ }
+ }
+#endif
+ pNode = (ugFsNodeInfo *) malloc(sizeof(ugFsNodeInfo));
+
+ if (pNode == NULL) {
+ continue;
+ }
+ memset(pNode, 0, sizeof(ugFsNodeInfo));
+ snprintf(pNode->path, sizeof(pNode->path), "%s", path);
+ snprintf(pNode->name, sizeof(pNode->name), "%s", ent->d_name);
+ if (ent->d_type & DT_DIR) {
+ pNode->type = UG_FILE_TYPE_DIR;
+ } else if (ent->d_type & DT_REG) {
+ mf_ug_file_attr_get_file_category(ent->d_name, &(pNode->type));
+ }
+ childpath = g_string_new(path);
+ if (childpath == NULL) {
+ free(pNode);
+ pNode = NULL;
+ continue;
+ }
+ g_string_append_printf(childpath, "/%s", ent->d_name);
+ mf_ug_file_attr_get_file_stat(childpath->str, &pNode);
+ if (pNode->type == UG_FILE_TYPE_DIR) {
+ ug_mf_debug("dir append\n");
+ *dir_list = eina_list_append(*dir_list, pNode);
+ } else {
+ ug_mf_debug("file append\n");
+ ret = mf_ug_file_attr_get_file_ext(childpath->str, pNode->ext);
+ if (ret != MYFILE_ERR_NONE) {
+ memset(pNode->ext, 0, FILE_EXT_LEN_MAX);
+ }
+ *file_list = eina_list_append(*file_list, pNode);
+ }
+
+ g_string_free(childpath, TRUE);
+ }
+ closedir(pDir);
+
+ return MYFILE_ERR_NONE;
+}
+
+/*********************
+**Function name: __mf_ug_fs_oper_exec_filter
+**Parameter:
+** ugFsNodeInfo* pnode_info: the node we need to check for filter
+** int option: filter
+**
+**Return value:
+** error code
+**
+**Action:
+** check if the node satisfied the filter option
+*********************/
+
+static bool __mf_ug_fs_oper_exec_filter(ugFsNodeInfo *pnode_info, int option)
+{
+ if (pnode_info == NULL) {
+ return FALSE;
+ }
+ if (option & UG_FILTER_CATEGORY_IMAGE) {
+ if (pnode_info->type == UG_FILE_TYPE_IMAGE) {
+ return TRUE;
+ }
+ }
+ if (option & UG_FILTER_CATEGORY_VIDEO) {
+ if (pnode_info->type == UG_FILE_TYPE_VIDEO) {
+ return TRUE;
+ }
+ }
+ if (option & UG_FILTER_CATEGORY_SOUND) {
+ if (pnode_info->type == UG_FILE_TYPE_SOUND) {
+ return TRUE;
+ }
+ }
+ if (option & UG_FILTER_CATEGORY_VOICE) {
+ if (pnode_info->type == UG_FILE_TYPE_VOICE) {
+ return TRUE;
+ }
+ }
+ if (option & UG_FILTER_CATEGORY_MUSIC) {
+ if (pnode_info->type == UG_FILE_TYPE_MUSIC) {
+ return TRUE;
+ }
+ }
+ if (option & UG_FILTER_CATEGORY_HTML) {
+ if (pnode_info->type == UG_FILE_TYPE_HTML) {
+ return TRUE;
+ }
+ }
+ if (option & UG_FILTER_CATEGORY_FLASH) {
+ if (pnode_info->type == UG_FILE_TYPE_FLASH) {
+ return TRUE;
+ }
+ }
+ if (option & UG_FILTER_CATEGORY_GAME) {
+ if (pnode_info->type == UG_FILE_TYPE_GAME) {
+ return TRUE;
+ }
+ }
+ if (option & UG_FILTER_CATEGORY_APP) {
+ if (pnode_info->type == UG_FILE_TYPE_APP) {
+ return TRUE;
+ }
+ }
+ if (option & UG_FILTER_CATEGORY_THEME) {
+ if (pnode_info->type == UG_FILE_TYPE_THEME) {
+ return TRUE;
+ }
+ }
+ if (option & UG_FILTER_CATEGORY_DOC) {
+ if (pnode_info->type == UG_FILE_TYPE_DOC) {
+ return TRUE;
+ }
+ }
+ if (option & UG_FILTER_CATEGORY_EXCEL) {
+ if (pnode_info->type == UG_FILE_TYPE_EXCEL) {
+ return TRUE;
+ }
+ }
+ if (option & UG_FILTER_CATEGORY_PPT) {
+ if (pnode_info->type == UG_FILE_TYPE_PPT) {
+ return TRUE;
+ }
+ }
+ if (option & UG_FILTER_CATEGORY_PDF) {
+ if (pnode_info->type == UG_FILE_TYPE_PDF) {
+ return TRUE;
+ }
+ }
+ if (option & UG_FILTER_CATEGORY_TXT) {
+ if (pnode_info->type == UG_FILE_TYPE_TXT) {
+ return TRUE;
+ }
+ }
+ if (option & UG_FILTER_CATEGORY_VCONTACT) {
+ if (pnode_info->type == UG_FILE_TYPE_VCONTACT) {
+ return TRUE;
+ }
+ }
+ if (option & UG_FILTER_CATEGORY_VCALENDAR) {
+ if (pnode_info->type == UG_FILE_TYPE_VCALENDAR) {
+ return TRUE;
+ }
+ }
+ if (option & UG_FILTER_CATEGORY_VNOTE) {
+ if (pnode_info->type == UG_FILE_TYPE_VNOTE) {
+ return TRUE;
+ }
+ }
+ if (option & UG_FILTER_CATEGORY_VBOOKMARK) {
+ if (pnode_info->type == UG_FILE_TYPE_VBOOKMARK) {
+ return TRUE;
+ }
+ }
+ if (option & UG_FILTER_CATEGORY_VIDEO_PROJECT) {
+ if (pnode_info->type == UG_FILE_TYPE_VIDEO_PROJECT) {
+ return TRUE;
+ }
+ }
+ if (option & UG_FILTER_CATEGORY_SVG) {
+ if (pnode_info->type == UG_FILE_TYPE_SVG) {
+ return TRUE;
+ }
+ }
+ if (option & UG_FILTER_CATEGORY_RSS) {
+ if (pnode_info->type == UG_FILE_TYPE_RSS) {
+ return TRUE;
+ }
+ }
+ if (option & UG_FILTER_CATEGORY_ETC) {
+ if (pnode_info->type == UG_FILE_TYPE_ETC) {
+ return TRUE;
+ }
+ }
+ return FALSE;
+}
+
+int mf_ug_fs_oper_list_filter(Eina_List *in_list, Eina_List **out_list, int option)
+{
+ ug_mf_debug();
+ if (in_list == NULL) {
+ return MYFILE_ERR_SRC_ARG_INVALID;
+ }
+
+ if (out_list == NULL) {
+ return MYFILE_ERR_DST_ARG_INVALID;
+ }
+
+ if (option == 0) {
+ *out_list = in_list;
+ return MYFILE_ERR_NONE;
+ }
+
+ Eina_List *l = NULL;
+ ugFsNodeInfo *data = NULL;
+ EINA_LIST_FOREACH(in_list, l, data) {
+ if (__mf_ug_fs_oper_exec_filter(data, option)) {
+ *out_list = eina_list_append(*out_list, data);
+ }
+ }
+ return MYFILE_ERR_NONE;
+}
+
+/******************************
+** Prototype : ug_mf_list_filter_by_extention
+** Description : filter from list by extension
+** Input : Eina_List *in_list
+** Eina_List **out_list
+** char* ext
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+int mf_ug_fs_oper_list_filter_by_extension(Eina_List *in_list, Eina_List **out_list, char *ext)
+{
+ if (in_list == NULL) {
+ return MYFILE_ERR_SRC_ARG_INVALID;
+ }
+
+ if (out_list == NULL) {
+ return MYFILE_ERR_DST_ARG_INVALID;
+ }
+
+ if (ext == NULL) {
+ *out_list = in_list;
+ return MYFILE_ERR_NONE;
+ }
+
+ Eina_List *l = NULL;
+ ugFsNodeInfo *data = NULL;
+
+ char *seps = ";";
+ char *temp_ext = malloc(strlen(ext) + 1);
+ gchar **result = NULL;
+ gchar **params = NULL;
+
+ EINA_LIST_FOREACH(in_list, l, data) {
+ memset(temp_ext, 0, strlen(ext) + 1);
+ strncpy(temp_ext, ext, strlen(ext));
+ result = g_strsplit(temp_ext, seps, 0);
+ if (result == NULL) {
+ continue;
+ }
+ for (params = result; *params; params++) {
+ if (strcasecmp(data->ext, *params) == 0) {
+ *out_list = eina_list_append(*out_list, data);
+ break;
+ }
+ }
+
+ g_strfreev(result);
+ result = NULL;
+ }
+ free(temp_ext);
+ return MYFILE_ERR_NONE;
+}
diff --git a/src/common/mf-ug-cb.c b/src/common/mf-ug-cb.c
new file mode 100755
index 0000000..ac94a2b
--- /dev/null
+++ b/src/common/mf-ug-cb.c
@@ -0,0 +1,1052 @@
+/*
+ * Copyright 2012 Samsung Electronics Co., Ltd
+ *
+ * Licensed under the Flora License, Version 1.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.tizenopensource.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 <stdio.h>
+#include <Elementary.h>
+#include <vconf.h>
+#include <vconf-keys.h>
+#include <pthread.h>
+
+#include "mf-ug-main.h"
+#include "mf-ug-inotify-handle.h"
+#include "mf-ug-winset.h"
+#include "mf-ug-fs-util.h"
+#include "mf-ug-fm-svc-wrapper.h"
+#include "mf-ug-resource.h"
+
+/******************************
+** Prototype : mf_ug_cb_back_button_cb
+** Description :
+** Input : void *data
+** Evas_Object *obj
+** void *event_info
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+
+void mf_ug_cb_back_button_cb(void *data, Evas_Object *obj, void *event_info)
+{
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+ ug_mf_retm_if(ugd == NULL, "ugData is NULL");
+
+ if (ugd->ug_Status.ug_bCancelDisableFlag) {
+ return;
+ }
+ if (0 != ugd->ug_ListPlay.ug_Player) {
+ mf_ug_list_play_destory_playing_file(ugd);
+ }
+ if (ugd->ug_Status.ug_bSettingEntry == true && ugd->ug_Status.ug_bInSettingView == false) {
+ Eina_List *l = NULL;
+ void *item = NULL;
+ ugNaviBar *pNavi_s = NULL;
+ ugNaviBar *pNavi_toshow = NULL;
+ GString *title = NULL;
+
+ if (ugd->ug_ListPlay.ug_iPlayState == PLAY_STATE_PLAYING || ugd->ug_ListPlay.ug_iPlayState == PLAY_STATE_PAUSED) {
+ mf_ug_list_play_destory_playing_file(ugd);
+ }
+
+ EINA_LIST_FOREACH(ugd->ug_MainWindow.ug_pNaviBarList, l, item) {
+ pNavi_s = (ugNaviBar *)item;
+ if (pNavi_s == NULL)
+ return;
+ if (g_strcmp0(pNavi_s->ug_pNaviLabel, MF_UG_LABEL_PHONE) == 0) {
+ if (pNavi_s->ug_pCurrentPath != NULL) {
+ free(pNavi_s->ug_pCurrentPath);
+ pNavi_s->ug_pCurrentPath = NULL;
+ }
+ pNavi_s->ug_pCurrentPath = strdup(UG_SETTING_RINGTONE_PATH);
+ pNavi_s->ug_bNaviFlagInUse = true;
+ pNavi_toshow = pNavi_s;
+ } else {
+ if (pNavi_s->ug_pCurrentPath != NULL) {
+ free(pNavi_s->ug_pCurrentPath);
+ pNavi_s->ug_pCurrentPath = NULL;
+ }
+ pNavi_s->ug_pCurrentPath = strdup(MEMORY_FOLDER);
+ pNavi_s->ug_bNaviFlagInUse = false;
+ }
+
+ }
+
+ if (pNavi_toshow == NULL) {
+ ug_debug("pNavi_toshow is NULL");
+ return;
+ }
+
+ if (ugd->ug_Status.ug_pPath) {
+ g_string_free(ugd->ug_Status.ug_pPath, TRUE);
+ ugd->ug_Status.ug_pPath = NULL;
+ }
+
+ ugd->ug_Status.ug_bInSettingView = true;
+
+ if (ugd->ug_Status.ug_pPath) {
+ g_string_free(ugd->ug_Status.ug_pPath, TRUE);
+ ugd->ug_Status.ug_pPath = NULL;
+ }
+ pNavi_toshow->ug_pCurrentPath = strdup(UG_SETTING_RINGTONE_PATH);
+ ugd->ug_Status.ug_pPath = g_string_new(pNavi_toshow->ug_pCurrentPath);
+ title = mf_ug_fm_svc_wapper_get_file_name(ugd->ug_Status.ug_pPath);
+
+ if (title != NULL) {
+ pNavi_toshow->ug_pNaviTitle = g_strdup(title->str);
+ g_string_free(title, TRUE);
+ title = NULL;
+ }
+ mf_ug_navi_bar_create_default_view(ugd);
+ mf_ug_ctrl_bar_set_item_disable(ugd);
+
+ elm_object_item_text_set(pNavi_toshow->ug_pNaviItem, pNavi_toshow->ug_pNaviTitle);
+ elm_naviframe_item_title_visible_set(pNavi_toshow->ug_pNaviItem, EINA_TRUE);
+
+ if (ugd->ug_MainWindow.ug_pTabBar && mf_ug_tab_bar_items_count_get(ugd->ug_MainWindow.ug_pTabBar) > 1) {
+ elm_object_part_content_unset(ugd->ug_MainWindow.ug_pTabLayout, "elm.swallow.content");
+ elm_object_part_content_unset(ugd->ug_MainWindow.ug_pTabLayout, "elm.swallow.tabbar");
+ elm_object_part_content_unset(ugd->ug_MainWindow.ug_pMainLayout, "elm.swallow.content");
+
+ mf_ug_tab_bar_remove_all_items(ugd->ug_MainWindow.ug_pTabBar);
+ UG_SAFE_FREE_OBJ(ugd->ug_MainWindow.ug_pTabBar);
+ mf_ug_navi_bar_remove_navi_list_item_by_label(ugd, MF_UG_LABEL_MMC);
+
+ Evas_Object *navibar = ug_mf_navi_bar_get_navibar_from_navilist(ugd->ug_MainWindow.ug_pNaviBarList, MF_UG_LABEL_PHONE);
+ elm_object_part_content_set(ugd->ug_MainWindow.ug_pMainLayout, "elm.swallow.content", navibar);
+ evas_object_hide(ugd->ug_MainWindow.ug_pTabLayout);
+ UG_SAFE_FREE_OBJ(ugd->ug_MainWindow.ug_pTabLayout);
+ }
+ } else {
+ ug_destroy_me(ugd->ug);
+ }
+ UG_TRACE_END;
+
+}
+
+/******************************
+** Prototype : mf_ug_cb_add_button_cb
+** Description :
+** Input : void *data
+** Evas_Object *obj
+** void *event_info
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+
+void mf_ug_cb_add_button_cb(void *data, Evas_Object *obj, void *event_info)
+{
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+ ug_mf_retm_if(ugd == NULL, "ugData is NULL");
+
+ bundle *b = NULL;
+ char *result = NULL;
+
+ if (ugd->ug_Status.ug_b_NaviPushFlag) {
+ UG_TRACE_END;
+ return;
+ }
+ result = mf_ug_util_get_send_result(ugd);
+ if (result) {
+ b = bundle_create();
+ ug_debug("result is [%s]", result);
+ bundle_add(b, "result", result);
+ ug_send_result(ugd->ug, b);
+ if (result) {
+ free(result);
+ }
+ if (b) {
+ bundle_free(b);
+ }
+ }
+
+ if (0 != ugd->ug_ListPlay.ug_Player) {
+ mf_ug_list_play_destory_playing_file(ugd);
+ }
+ ug_destroy_me(ugd->ug);
+ UG_TRACE_END;
+}
+
+void mf_ug_cb_goto_myfile_button_cb(void *data, Evas_Object *obj, void *event_info)
+{
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+ ug_mf_retm_if(ugd == NULL, "ugData is NULL");
+
+ if (ugd->ug_Status.ug_bCancelDisableFlag) {
+ ug_debug("ug_Status.ug_bCancelDisableFlag is true");
+ return;
+ }
+ ugNaviBar *item = NULL;
+ Eina_List *l = NULL;
+
+ ugNaviBar *pNavi_s = NULL;//ug_mf_navi_bar_get_navi_from_navilist(ugd->ug_MainWindow.ug_pNaviBarList, MF_UG_LABEL_PHONE);
+ ugNaviBar *pNavi_toshow = NULL;
+ int mmc_card = 0;
+ int error_code = 0;
+ EINA_LIST_FOREACH(ugd->ug_MainWindow.ug_pNaviBarList, l, item) {
+ pNavi_s = (ugNaviBar *)item;
+ if (pNavi_s == NULL)
+ return;
+ if (g_strcmp0(pNavi_s->ug_pNaviLabel, MF_UG_LABEL_PHONE) == 0) {
+ if (pNavi_s->ug_pCurrentPath != NULL) {
+ free(pNavi_s->ug_pCurrentPath);
+ pNavi_s->ug_pCurrentPath = NULL;
+ }
+ pNavi_s->ug_pCurrentPath = strdup(PHONE_FOLDER);
+ pNavi_s->ug_bNaviFlagInUse = true;
+ pNavi_toshow = pNavi_s;
+ } else {
+ if (pNavi_s->ug_pCurrentPath != NULL) {
+ free(pNavi_s->ug_pCurrentPath);
+ pNavi_s->ug_pCurrentPath = NULL;
+ }
+ pNavi_s->ug_pCurrentPath = strdup(MEMORY_FOLDER);
+ pNavi_s->ug_bNaviFlagInUse = false;
+ }
+
+ }
+
+
+ if (0 != ugd->ug_ListPlay.ug_Player)
+ mf_ug_list_play_destory_playing_file(ugd);
+
+ if (ugd->ug_Status.ug_pPath) {
+ g_string_free(ugd->ug_Status.ug_pPath, TRUE);
+ ugd->ug_Status.ug_pPath = NULL;
+ }
+ ugd->ug_Status.ug_pPath = g_string_new(PHONE_FOLDER);
+
+ ugd->ug_Status.ug_bInSettingView = false;
+ mf_ug_navi_bar_create_default_view(ugd);
+ ugd->ug_Status.ug_bCancelDisableFlag = true;
+
+ error_code = mf_ug_util_get_mmc_state(&mmc_card);
+ if (error_code == 0 && mmc_card == 1) {
+ Elm_Object_Item *pItemPhone = NULL;
+ Elm_Object_Item *pItemMMC = NULL;
+
+ if (ugd->ug_MainWindow.ug_pTabLayout == NULL) {
+ ugd->ug_MainWindow.ug_pTabLayout = mf_ug_main_tab_layout_create(ugd->ug_MainWindow.ug_pWindow);
+ ugd->ug_MainWindow.ug_pTabBackGround = mf_ug_main_create_bg(ugd->ug_MainWindow.ug_pWindow);
+ elm_object_part_content_set(ugd->ug_MainWindow.ug_pTabLayout, "elm.swallow.bg", ugd->ug_MainWindow.ug_pTabBackGround);
+ }
+ if (ugd->ug_MainWindow.ug_pTabBar == NULL) {
+ ugd->ug_MainWindow.ug_pTabBar = mf_ug_tab_bar_create(ugd->ug_MainWindow.ug_pWindow);
+ }
+
+ pItemPhone =
+ mf_ug_tab_bar_append_item(ugd->ug_MainWindow.ug_pTabBar, UG_ICON_PHONE, MF_UG_LABEL_PHONE,
+ ugd);
+ pItemMMC =
+ mf_ug_tab_bar_append_item(ugd->ug_MainWindow.ug_pTabBar, UG_ICON_MEMORY, MF_UG_LABEL_MMC,
+ ugd);
+
+ //mf_ug_tab_bar_set_selected_item(pItemPhone);
+ elm_object_part_content_unset(ugd->ug_MainWindow.ug_pMainLayout, "elm.swallow.content");
+ elm_object_part_content_set(ugd->ug_MainWindow.ug_pTabLayout, "elm.swallow.content", pNavi_toshow->ug_pNaviBar);
+ elm_object_part_content_set(ugd->ug_MainWindow.ug_pTabLayout, "elm.swallow.tabbar", ugd->ug_MainWindow.ug_pTabBar);
+ elm_object_part_content_set(ugd->ug_MainWindow.ug_pMainLayout, "elm.swallow.content", ugd->ug_MainWindow.ug_pTabLayout);
+ evas_object_show(ugd->ug_MainWindow.ug_pTabLayout);
+ if (ugd->ug_Status.ug_bMassStorageFlag) {
+ mf_ug_tab_bar_set_item_disable(ugd->ug_MainWindow.ug_pTabBar, EINA_TRUE);
+ }
+ }
+
+ mf_ug_ctrl_bar_set_item_disable(ugd);
+}
+
+
+/******************************
+** Prototype : _ug_popup_exit
+** Description : Samsung
+** Input : void *data
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+
+void mf_ug_cb_mass_storage_popup_cb(void *data)
+{
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+ ug_mf_retm_if(ugd == NULL, "ugData is NULL");
+
+ mf_ug_cb_back_button_cb(ugd, NULL, NULL);
+
+ if (ugd->ug_MainWindow.ug_pNormalPopup) {
+ evas_object_del(ugd->ug_MainWindow.ug_pNormalPopup);
+ ugd->ug_MainWindow.ug_pNormalPopup = NULL;
+ }
+ UG_TRACE_END;
+}
+
+
+/******************************
+** Prototype : mf_ug_cb_upper_click_cb
+** Description : Samsung
+** Input : void *data
+** Evas_Object * obj
+** void *event_info
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+void mf_ug_cb_upper_click_cb(void *data, Evas_Object * obj, void *event_info)
+{
+ UG_TRACE_BEGIN;
+ ug_mf_retm_if(data == NULL, "data is NULL");
+ ugData *ugd = (ugData *)data;
+ ugNaviBar *pNavi_s = mf_ug_navi_bar_get_in_use_navi(ugd);
+ ug_mf_retm_if(pNavi_s == NULL, "pNavi_s is NULL");
+
+ if (ugd->ug_Status.ug_b_NaviPushFlag) {
+ UG_TRACE_END;
+ return;
+ }
+
+ if (ugd->ug_Status.ug_pPath != NULL && pNavi_s->ug_pCurrentPath != NULL) {
+ if (g_strcmp0(pNavi_s->ug_pCurrentPath, MF_UG_LABEL_PHONE) == 0
+ || g_strcmp0(pNavi_s->ug_pCurrentPath, MF_UG_LABEL_MMC) == 0) {
+ mf_ug_navi_bar_create_default_view(ugd);
+ return;
+ }
+ GString *new_path = NULL;
+ char *file_dir = ecore_file_dir_get(pNavi_s->ug_pCurrentPath);
+ if (file_dir) {
+ new_path = g_string_new(file_dir);
+ UG_SAFE_FREE_GSTRING(ugd->ug_Status.ug_pPath);
+ ugd->ug_Status.ug_pPath = new_path;
+ UG_SAFE_FREE_CHAR(pNavi_s->ug_pCurrentPath);
+ pNavi_s->ug_pCurrentPath = strdup(new_path->str);
+ free(file_dir);
+ file_dir = NULL;
+ } else {
+ ug_debug("file_dir is NULL");
+ }
+ } else {
+ ugd->ug_Status.ug_pPath = g_string_new(MF_UG_LABEL_PHONE);
+ pNavi_s->ug_pCurrentPath = strdup(MF_UG_LABEL_PHONE);
+ }
+ mf_ug_navi_bar_create_default_view(ugd);
+ mf_ug_ctrl_bar_set_item_disable(ugd);
+ UG_TRACE_END;
+}
+
+
+void mf_ug_cb_home_button_cb(void *data, Evas_Object * obj, void *event_info)
+{
+ UG_TRACE_BEGIN;
+ ug_mf_retm_if(data == NULL, "data is NULL");
+ ugData *ugd = (ugData *)data;
+ ugNaviBar *pNavi_s = mf_ug_navi_bar_get_in_use_navi(ugd);
+ ug_mf_retm_if(pNavi_s == NULL, "pNavi_s is NULL");
+
+ if (ugd->ug_Status.ug_b_NaviPushFlag) {
+ UG_TRACE_END;
+ return;
+ }
+
+ int storage = MF_UG_PHONE;
+
+ storage = mf_ug_fm_svc_wapper_get_location(ugd->ug_Status.ug_pPath->str);
+ switch (storage) {
+ case MF_UG_PHONE:
+ UG_SAFE_FREE_GSTRING(ugd->ug_Status.ug_pPath);
+ ugd->ug_Status.ug_pPath = g_string_new(PHONE_FOLDER);
+ UG_SAFE_FREE_CHAR(pNavi_s->ug_pCurrentPath);
+ pNavi_s->ug_pCurrentPath = g_strdup(PHONE_FOLDER);
+ mf_ug_util_set_current_state(ugd, STATE_PHONE);
+ break;
+ case MF_UG_MMC:
+ UG_SAFE_FREE_GSTRING(ugd->ug_Status.ug_pPath);
+ ugd->ug_Status.ug_pPath = g_string_new(MEMORY_FOLDER);
+ UG_SAFE_FREE_CHAR(pNavi_s->ug_pCurrentPath);
+ pNavi_s->ug_pCurrentPath = g_strdup(MEMORY_FOLDER);
+ mf_ug_util_set_current_state(ugd, STATE_MEMORY);
+ break;
+ default:
+ return;
+ }
+
+ mf_ug_navi_bar_create_default_view(ugd);
+ mf_ug_ctrl_bar_set_item_disable(ugd);
+ UG_TRACE_END;
+}
+
+/******************************
+** Prototype : tab_callback
+** Description :
+** Input : void *data
+** Evas_Object *obj
+** void *event_info
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+void mf_ug_cb_tab_bar_cb(void *data, Evas_Object *obj, void *event_info)
+{
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+ ug_mf_retm_if(ugd == NULL, "ugd is NULL");
+
+
+ const char *label = NULL;
+ Evas_Object *newContent = NULL;
+ Evas_Object *pNaviBar = NULL;
+ Elm_Object_Item *it = NULL;
+ ugNaviBar *pNavi_s_toshow = NULL;
+ ugNaviBar *pNavi_s_inuse = NULL;
+
+ //mf_ug_navi_bar_del_item_directly(ugd);
+ it = (Elm_Object_Item *)event_info;
+ label = elm_object_item_text_get(it);
+
+ if (label != NULL) {
+ char *rootpath = NULL;
+
+ /*0. set the previous navi to be out of use */
+ pNavi_s_inuse = mf_ug_navi_bar_get_in_use_navi(ugd);
+
+ if (pNavi_s_inuse == NULL || pNavi_s_inuse->ug_pNaviLabel == NULL) {
+ UG_TRACE_END;
+ return;
+ }
+ ug_debug("label is [%s] pNavi_s_inuse->ug_pNaviLabel is [%s]", label, pNavi_s_inuse->ug_pNaviLabel);
+
+ if (g_strcmp0(label, pNavi_s_inuse->ug_pNaviLabel) == 0) {
+ UG_TRACE_END;
+ return;
+ }
+
+ pNavi_s_inuse->ug_bNaviFlagInUse = FALSE;
+
+ if (0 != ugd->ug_ListPlay.ug_Player) {
+ mf_ug_list_play_destory_playing_file(ugd);
+ }
+
+ /*if the muisc is playing, destory the play */
+
+ /*1. get navi bar pointer by the label */
+ pNaviBar = ug_mf_navi_bar_get_navibar_from_navilist(ugd->ug_MainWindow.ug_pNaviBarList, label);
+
+ ug_debug("label is %s", label);
+ /*2. create navi bar if not created, otherwise get it by pNaviBar */
+ if (pNaviBar == NULL) {
+ /*2.0 get root path by storage label */
+ rootpath = mf_ug_fm_svc_wapper_get_root_path_by_tab_label(label);
+ if (rootpath == NULL) {
+ UG_TRACE_END;
+ return;
+ }
+ /*2.1 create the navi for the tab */
+ pNavi_s_toshow = calloc(1, sizeof(ugNaviBar));
+ if (pNavi_s_toshow == NULL) {
+ ug_debug("pNavi_s_toshow is NULL");
+ free(rootpath);
+ rootpath = NULL;
+ return;
+ }
+
+ pNavi_s_toshow->ug_pNaviBar = mf_ug_navi_bar_create_navi_bar(ugd->ug_MainWindow.ug_pMainLayout);
+ if (pNavi_s_toshow->ug_pNaviBar == NULL) {
+ ug_debug("pNavi_s_toshow->ug_pNaviBar is NULL");
+ free(rootpath);
+ rootpath = NULL;
+ free(pNavi_s_toshow);
+ pNavi_s_toshow = NULL;
+ return;
+ }
+ pNavi_s_toshow->ug_bNaviFlagInUse = TRUE;
+ /*2.2 set path as root path of the storage */
+ pNavi_s_toshow->ug_pCurrentPath = g_strdup(rootpath);
+ pNavi_s_toshow->ug_pNaviLabel = strdup(label);
+ free(rootpath);
+ rootpath = NULL;
+ /*2.3 insert phone navi into the navi_list */
+ ugd->ug_MainWindow.ug_pNaviBarList = eina_list_append(ugd->ug_MainWindow.ug_pNaviBarList, pNavi_s_toshow);
+
+ if (ugd->ug_Status.ug_pPath != NULL) {
+ g_string_free(ugd->ug_Status.ug_pPath, TRUE);
+ ugd->ug_Status.ug_pPath = NULL;
+ }
+ ugd->ug_Status.ug_pPath = g_string_new(pNavi_s_toshow->ug_pCurrentPath);
+ mf_ug_navi_bar_create_default_view(ugd);
+
+ /*2.4 set the navi to tab bar item */
+ mf_ug_tab_bar_set_item_view(it, ugd->ug_MainWindow.ug_pTabLayout, pNavi_s_toshow->ug_pNaviBar);
+ mf_ug_navi_bar_set_blocking(ugd, false);
+
+ } else {
+ /*/2.1 get the navi of the tab */
+ pNavi_s_toshow = mf_ug_navi_bar_get_navi_struct_by_navi(ugd, pNaviBar);
+
+ pNavi_s_toshow->ug_bNaviFlagInUse = TRUE;
+
+ /*/2.2 set related status value. */
+ if (ugd->ug_Status.ug_pPath != NULL) {
+ g_string_free(ugd->ug_Status.ug_pPath, TRUE);
+ ugd->ug_Status.ug_pPath = NULL;
+ }
+ ugd->ug_Status.ug_pPath = g_string_new(pNavi_s_toshow->ug_pCurrentPath);
+ /*/2.3 update the content to catch update */
+ newContent = mf_ug_genlist_create_content_list_view(ugd);
+ pNavi_s_toshow->ug_pContent = newContent;
+ mf_ug_navi_bar_set_new_content(pNavi_s_toshow->ug_pNaviLayout, newContent);
+ mf_ug_tab_bar_set_item_view(it, ugd->ug_MainWindow.ug_pTabLayout, pNavi_s_toshow->ug_pNaviBar);
+ }
+
+ mf_ug_ctrl_bar_set_item_disable(ugd);
+ } else {
+ ug_debug("Invalid argument: label is NULL\n");
+ }
+ UG_TRACE_END;
+}
+
+
+void mf_ug_cb_ctrl_bar_button_cb(void *data, Evas_Object *obj, void *event_info)
+{
+
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+ ug_mf_retm_if(ugd == NULL, "ugd is NULL");
+ ug_mf_retm_if(event_info == NULL, "event_info is NULL");
+ const char *label = NULL;
+
+ if (ugd->ug_Status.ug_b_NaviPushFlag)
+ return;
+ label = elm_object_item_text_get((Elm_Object_Item *)event_info);
+ ug_mf_retm_if(label == NULL, "label is NULL");
+
+ ugNaviBar *pNavi_s = mf_ug_navi_bar_get_in_use_navi(ugd);
+ if (g_strcmp0(label, MF_UG_LABEL_RINGTONES) == 0) {
+ if (g_strcmp0(ugd->ug_Status.ug_pPath->str, UG_RINGTION_PATH) != 0) {
+ UG_SAFE_FREE_GSTRING(ugd->ug_Status.ug_pPath);
+ ugd->ug_Status.ug_pPath = g_string_new(UG_RINGTION_PATH);
+ UG_SAFE_FREE_CHAR(pNavi_s->ug_pCurrentPath);
+ pNavi_s->ug_pCurrentPath = g_strdup(UG_RINGTION_PATH);
+ mf_ug_util_set_current_state(ugd, STATE_PHONE);
+ ugd->ug_Status.ug_iCtrlBarType = CTRL_BAR_MUSIC;
+ mf_ug_navi_bar_create_default_view(ugd);
+ }
+ } else if (g_strcmp0(label, MF_UG_LABEL_OTHER_MUSIC) == 0) {
+ if (g_strcmp0(ugd->ug_Status.ug_pPath->str, UG_MUSIC_PATH) != 0) {
+ UG_SAFE_FREE_GSTRING(ugd->ug_Status.ug_pPath);
+ ugd->ug_Status.ug_pPath = g_string_new(UG_MUSIC_PATH);
+ UG_SAFE_FREE_CHAR(pNavi_s->ug_pCurrentPath);
+ pNavi_s->ug_pCurrentPath = g_strdup(UG_MUSIC_PATH);
+ mf_ug_util_set_current_state(ugd, STATE_PHONE);
+ ugd->ug_Status.ug_iCtrlBarType = CTRL_BAR_RINGTONE;
+ mf_ug_navi_bar_create_default_view(ugd);
+ }
+ }
+ UG_TRACE_END;
+}
+
+/******************************
+** Prototype : mf_ug_cb_list_play_cb
+** Description : Samsung
+** Input : ugListItemData *data
+** Evas_Object *obj
+** void *event_info
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+void mf_ug_cb_list_play_cb(ugListItemData *data, Evas_Object *obj, void *event_info)
+{
+ UG_TRACE_BEGIN;
+ ugListItemData *itemData = data;
+ ug_mf_retm_if(itemData == NULL, "itemData is NULL");
+ ug_mf_retm_if(itemData->ug_pData == NULL, "ug_pData is NULL");
+
+ if (itemData->ug_pData->ug_Status.ug_b_NaviPushFlag)
+ return;
+
+ mf_ug_list_play_play_music_item(itemData);
+ UG_TRACE_END;
+}
+
+/******************************
+** Prototype : mf_ug_cb_select_info_show_cb
+** Description : Samsung
+** Input : void *data
+** Evas *e
+** Evas_Object *obj
+** void *event_info
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+void mf_ug_cb_select_info_show_cb(void *data, Evas *e, Evas_Object *obj, void *event_info)
+{
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+ ug_mf_retm_if(ugd == NULL, "ugd is NULL");
+ edje_object_signal_emit(_EDJ(ugd->ug_MainWindow.ug_pMainLayout), "elm,state,show,default", "elm");
+ UG_TRACE_END;
+ return;
+}
+
+/******************************
+** Prototype : mf_ug_cb_select_info_hide_cb
+** Description : Samsung
+** Input : void *data
+** Evas *e
+** Evas_Object *obj
+** void *event_info
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+void mf_ug_cb_select_info_hide_cb(void *data, Evas *e, Evas_Object *obj, void *event_info)
+{
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+ ug_mf_retm_if(ugd == NULL, "ugd is NULL");
+ edje_object_signal_emit(_EDJ(ugd->ug_MainWindow.ug_pMainLayout), "elm,state,hide,default", "elm");
+ UG_TRACE_END;
+ return;
+}
+
+/******************************
+** Prototype : mf_ug_cb_select_info_timeout_cb
+** Description : Samsung
+** Input : void *data
+** Evas_Object *obj
+** void *event_info
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+void mf_ug_cb_select_info_timeout_cb(void *data, Evas_Object *obj, void *event_info)
+{
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+ ug_mf_retm_if(ugd == NULL, "ugd is NULL");
+ edje_object_signal_emit(_EDJ(ugd->ug_MainWindow.ug_pMainLayout), "elm,state,hide,default", "elm");
+ UG_TRACE_END;
+ return;
+}
+
+
+/******************************
+** Prototype : mf_ug_cb_mmc_changed_cb
+** Description : Samsung
+** Input : keynode_t *key
+** void* data
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+void mf_ug_cb_mmc_changed_cb(keynode_t *key, void *data)
+{
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+ ug_mf_retm_if(ugd == NULL, "ugd is NULL");
+ ug_mf_retm_if(ugd->ug_Status.ug_pPath == NULL || ugd->ug_Status.ug_pPath->str == NULL, "ugd->ug_Status.ug_pPath is NULL");
+
+ int optStorage = MF_UG_NONE;
+ char *labelStorage = NULL;
+
+ if (VCONF_TYPE_INT == vconf_keynode_get_type(key)
+ && VCONFKEY_SYSMAN_MMC_MOUNTED == vconf_keynode_get_int(key)) {
+ if (ugd->ug_Status.ug_bInSettingView && ugd->ug_Status.ug_bSettingEntry) {
+ ugd->ug_Status.ug_iMmcFlag = MMC_ON;
+ return;
+ }
+
+ mf_ug_util_storage_insert_action(ugd, MF_UG_LABEL_MMC);
+#ifdef MF_UG_FEATURE_NEW_UX
+ ugNaviBar *pNaviInUseStruct = mf_ug_navi_bar_get_in_use_navi(ugd);
+ elm_naviframe_item_title_visible_set(pNaviInUseStruct->ug_pNaviItem, EINA_FALSE);
+#endif
+ ugd->ug_Status.ug_iMmcFlag = MMC_ON;
+ return;
+ } else {
+ ugNaviBar *pNaviInUseStruct = NULL;
+
+ if (VCONFKEY_SYSMAN_MMC_REMOVED == vconf_keynode_get_int(key)
+ || VCONFKEY_SYSMAN_MMC_INSERTED_NOT_MOUNTED == vconf_keynode_get_int(key)) {
+ ug_debug("mmc removed");
+ if (ugd->ug_Status.ug_bInSettingView && ugd->ug_Status.ug_bSettingEntry) {
+ ugd->ug_Status.ug_iMmcFlag = MMC_OFF;
+ return;
+ }
+ optStorage = MF_UG_MMC;
+ ugd->ug_Status.ug_iMmcFlag = MMC_OFF;
+ }
+
+ if (optStorage == MF_UG_NONE) {
+ ug_debug("get removed storage failed");
+ return;
+ }
+
+ switch (optStorage) {
+ case MF_UG_MMC:
+ labelStorage = MF_UG_LABEL_MMC;
+ break;
+ default:
+ break;
+ }
+
+ if (mf_ug_fm_svc_wapper_get_location(ugd->ug_Status.ug_pPath->str) != optStorage) {
+ mf_ug_navi_bar_remove_navi_list_item_by_label(ugd, labelStorage);
+ mf_ug_tab_bar_remove_item_by_label(ugd->ug_MainWindow.ug_pTabBar, labelStorage);
+ if (mf_ug_util_set_main_layout_by_tab_item_count(ugd) == 0) {
+ pNaviInUseStruct = mf_ug_navi_bar_get_in_use_navi(ugd);
+ ug_debug("pNaviInUseStruct is [%p]", pNaviInUseStruct);
+ elm_object_part_content_set(ugd->ug_MainWindow.ug_pMainLayout, "elm.swallow.content", pNaviInUseStruct->ug_pNaviBar);
+ evas_object_show(ugd->ug_MainWindow.ug_pMainLayout);
+ }
+ } else {
+
+ if (0 != ugd->ug_ListPlay.ug_Player) {
+ mf_ug_list_play_destory_playing_file(ugd);
+ if (ugd->ug_ListPlay.ug_pPlayFilePath) {
+ g_free(ugd->ug_ListPlay.ug_pPlayFilePath);
+ ugd->ug_ListPlay.ug_pPlayFilePath = NULL;
+ }
+ }
+
+ mf_ug_navi_bar_remove_navi_list_item_by_label(ugd, labelStorage);
+ mf_ug_tab_bar_remove_item_by_label(ugd->ug_MainWindow.ug_pTabBar, labelStorage);
+ pNaviInUseStruct = mf_ug_navi_bar_get_in_use_navi(ugd);
+ if (mf_ug_util_set_main_layout_by_tab_item_count(ugd) == 0) {
+ ug_debug();
+ elm_object_part_content_set(ugd->ug_MainWindow.ug_pMainLayout, "elm.swallow.content", pNaviInUseStruct->ug_pNaviBar);
+ evas_object_show(ugd->ug_MainWindow.ug_pMainLayout);
+ }
+ mf_ug_navi_bar_refresh_navibar_recovered_view(ugd, pNaviInUseStruct);
+ }
+
+#ifdef MF_UG_FEATURE_NEW_UX
+ if (ugd->ug_Status.ug_iMmcFlag == MMC_ON && !(ugd->ug_Status.ug_bSettingEntry == true && ugd->ug_Status.ug_bInSettingView == true))
+ elm_naviframe_item_title_visible_set(pNaviInUseStruct->ug_pNaviItem, EINA_FALSE);
+ else
+ elm_naviframe_item_title_visible_set(pNaviInUseStruct->ug_pNaviItem, EINA_TRUE);
+#endif
+ }
+ UG_TRACE_END;
+ return;
+}
+
+
+void mf_ug_cb_mass_storage_changed_cb(keynode_t *key, void *data)
+{
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+ ug_mf_retm_if(ugd == NULL, "ugData is NULL");
+ ug_mf_retm_if(ugd->ug_Status.ug_pPath == NULL || ugd->ug_Status.ug_pPath->str == NULL, "ugd->ug_Status.ug_pPath is NULL");
+
+ if (VCONF_TYPE_INT == vconf_keynode_get_type(key)
+ && VCONFKEY_USB_STORAGE_STATUS_OFF == vconf_keynode_get_int(key)) {
+ if (ugd->ug_Status.ug_bMassStorageFlag == true) {
+ if (ugd->ug_Status.ug_bInSettingView && ugd->ug_Status.ug_bSettingEntry) {
+ ugd->ug_Status.ug_bMassStorageFlag = false;
+ return;
+ }
+ Evas_Object *newContent = NULL;
+ ugNaviBar *pNavi_toshow = NULL;
+
+ pNavi_toshow = mf_ug_navi_bar_get_in_use_navi(ugd);
+ ug_mf_retm_if(pNavi_toshow == NULL, "get navigation bar in use failed");
+
+ ugd->ug_Status.ug_bMassStorageFlag = false;
+ pNavi_toshow->ug_pContent = newContent = mf_ug_genlist_create_content_list_view(ugd);
+ mf_ug_navi_bar_set_new_content(pNavi_toshow->ug_pNaviLayout, newContent);
+ mf_ug_ctrl_bar_set_item_disable(ugd);
+
+ if (ugd->ug_MainWindow.ug_pTabBar) {
+ mf_ug_tab_bar_set_item_disable(ugd->ug_MainWindow.ug_pTabBar, EINA_FALSE);
+ }
+ }
+ UG_TRACE_END;
+ return;
+ } else if (VCONF_TYPE_INT == vconf_keynode_get_type(key)
+ && (VCONFKEY_USB_STORAGE_STATUS_UMS_ON == vconf_keynode_get_int(key)
+ || VCONFKEY_USB_STORAGE_STATUS_UMS_MMC_ON == vconf_keynode_get_int(key))) {
+ if (ugd->ug_Status.ug_bInSettingView && ugd->ug_Status.ug_bSettingEntry) {
+ ugd->ug_Status.ug_bMassStorageFlag = true;
+ return;
+ }
+ }
+ UG_TRACE_END;
+ return;
+}
+
+int mf_ug_cb_set_mass_storage_state_cb(void *data)
+{
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+ ug_mf_retvm_if(ugd == NULL, -1, "ugData is NULL");
+
+ return vconf_notify_key_changed(VCONFKEY_USB_STORAGE_STATUS, mf_ug_cb_mass_storage_changed_cb, ugd);
+}
+
+/******************************
+** Prototype : mf_ug_cb_dir_update_cb
+** Description : Samsung
+** Input : mf_ug_inotify_event event
+** char *name
+** void *data
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+void mf_ug_cb_dir_update_cb(mf_ug_inotify_event event, char *name, void *data)
+{
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+ ug_mf_retm_if(ugd == NULL, "ugData is NULL");
+
+ ug_debug("event : %d, name : %s", event, name);
+
+ ug_dir_event_t buffer;
+
+ buffer.event = event;
+ buffer.name = strdup(name);
+
+ ecore_pipe_write(ugd->ug_UiGadget.ug_pInotifyPipe, &buffer, sizeof(buffer));
+ UG_TRACE_END;
+
+ return;
+}
+
+/******************************
+** Prototype : mf_ug_cb_dir_pipe_cb
+** Description : Samsung
+** Input : void *data
+** void *buffer
+** unsigned int nbyte
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+void mf_ug_cb_dir_pipe_cb(void *data, void *buffer, unsigned int nbyte)
+{
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+ ug_mf_retm_if(ugd == NULL, "ugd is NULL");
+
+
+ ugNaviBar *pNavi_s = mf_ug_navi_bar_get_in_use_navi(ugd);
+ ug_mf_retm_if(pNavi_s == NULL, "get navigation bar in use failed");
+
+ if (ugd->ug_ListPlay.ug_iPlayState != PLAY_STATE_INIT) {
+ return;
+ }
+ if (buffer) {
+ ug_dir_event_t *msg = (ug_dir_event_t *) buffer;
+ ug_debug("event : %d, name : %s", msg->event, msg->name);
+
+ Evas_Object *newContent = NULL;
+ switch (msg->event) {
+ case UG_MF_INOTI_CREATE:
+ case UG_MF_INOTI_MOVE_IN:
+ /*/1 TODO: add new item to list */
+ break;
+ case UG_MF_INOTI_DELETE:
+ case UG_MF_INOTI_MOVE_OUT:
+ /*/1 TODO: remove item from list */
+ break;
+ case UG_MF_INOTI_MODIFY:
+ /*/1 TODO: update item in list */
+ break;
+ case UG_MF_INOTI_DELETE_SELF:
+ case UG_MF_INOTI_MOVE_SELF:
+ /*/1 TODO: watching directory is removed, change current directory. */
+ break;
+ default:
+ ug_mf_error("Unknown event");
+ break;
+ }
+ pNavi_s->ug_pContent = newContent = mf_ug_genlist_create_content_list_view(ugd);
+ mf_ug_navi_bar_set_new_content(pNavi_s->ug_pNaviLayout, newContent);
+ mf_ug_ctrl_bar_set_item_disable(ugd);
+ if (msg->name) {
+ free(msg->name);
+ msg->name = NULL;
+ }
+ }
+ UG_TRACE_END;
+}
+
+
+#ifdef UG_THUMB_REAL_TIME_UPDATE
+Eina_Bool mf_ug_cb_thumb_timer_cb(void *data)
+{
+ ugListItemData *itemData = (ugListItemData *)data;
+ ug_mf_retvm_if(itemData == NULL, EINA_FALSE, "input params is NULL");
+ ugData *ugd = (ugData *)itemData->ug_pData;
+ ug_mf_retvm_if(ugd == NULL, EINA_FALSE, "ugd is NULL");
+
+ bool allright_flag = true;
+ Evas_Object *pContent = NULL;
+
+ if (ugd->ug_Status.ug_pThumbUpdateTimer == NULL) {
+ return EINA_FALSE;
+ }
+
+ /****read the realized part of the list****/
+ if (itemData->ug_pItem) {
+ pContent = elm_object_item_widget_get(itemData->ug_pItem);
+ if (pContent == NULL) {
+ ugd->ug_Status.ug_pThumbUpdateTimer = NULL;
+ return EINA_FALSE;
+ }
+ } else {
+ ugd->ug_Status.ug_pThumbUpdateTimer = NULL;
+ return EINA_FALSE;
+ }
+ Eina_List *realized_list = elm_genlist_realized_items_get(pContent);
+ Eina_List *list = NULL;
+ Elm_Object_Item *it;
+ ugListItemData *item_data = NULL;
+
+ if (realized_list == NULL) {
+ allright_flag = false;
+ }
+
+ EINA_LIST_FOREACH(realized_list, list, it) {
+ item_data = (ugListItemData *)elm_object_item_data_get(it);
+ if (item_data == NULL)
+ continue;
+
+ if (item_data->ug_bRealThumbFlag == false) {
+ ug_debug("Update item: %s", item_data->ug_pItemName->str);
+ if (ecore_file_is_dir(item_data->ug_pItemName->str) == true) {
+ item_data->ug_pThumbPath = strdup(UG_ICON_FOLDER);
+ item_data->ug_bRealThumbFlag = true;
+ elm_object_item_data_set(it, item_data);
+ elm_genlist_item_update(it);
+
+ } else if (ecore_file_exists(item_data->ug_pItemName->str)) {
+ char *new_thumb = mf_ug_file_attr_get_file_icon(ugd->ug_Status.ug_pMedia_svc_handle, item_data->ug_pItemName->str, NULL);
+ if (new_thumb) {
+ if (item_data->ug_pThumbPath) {
+ free(item_data->ug_pThumbPath);
+ item_data->ug_pThumbPath = NULL;
+ }
+ item_data->ug_pThumbPath = strdup(new_thumb);
+ item_data->ug_bRealThumbFlag = true;
+ elm_object_item_data_set(it, item_data);
+ elm_genlist_item_update(it);
+
+ free(new_thumb);
+ new_thumb = NULL;
+ } else {
+ allright_flag = false;
+ }
+ }
+ }
+ }
+
+ if (allright_flag == false) {
+ return EINA_TRUE;
+ } else {
+ ugd->ug_Status.ug_pThumbUpdateTimer = NULL;
+ return EINA_FALSE;
+ }
+}
+#endif
diff --git a/src/common/mf-ug-fm-svc-wapper.c b/src/common/mf-ug-fm-svc-wapper.c
new file mode 100755
index 0000000..c7296e0
--- /dev/null
+++ b/src/common/mf-ug-fm-svc-wapper.c
@@ -0,0 +1,547 @@
+/*
+ * Copyright 2012 Samsung Electronics Co., Ltd
+ *
+ * Licensed under the Flora License, Version 1.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.tizenopensource.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 "mf-ug-util.h"
+#include "mf-ug-cb.h"
+#include "mf-ug-main.h"
+#include "mf-ug-fm-svc-wrapper.h"
+#include "mf-ug-fs-util.h"
+#include "mf-ug-resource.h"
+
+#define UG_FILTER_CATEGORY_ALL \
+UG_FILTER_CATEGORY_NONE | UG_FILTER_CATEGORY_IMAGE | UG_FILTER_CATEGORY_VIDEO \
+| UG_FILTER_CATEGORY_SOUND | UG_FILTER_CATEGORY_VOICE | UG_FILTER_CATEGORY_MUSIC \
+| UG_FILTER_CATEGORY_HTML | UG_FILTER_CATEGORY_FLASH | UG_FILTER_CATEGORY_GAME \
+| UG_FILTER_CATEGORY_APP | UG_FILTER_CATEGORY_THEME | UG_FILTER_CATEGORY_DOC \
+| UG_FILTER_CATEGORY_EXCEL | UG_FILTER_CATEGORY_PPT | UG_FILTER_CATEGORY_PDF \
+| UG_FILTER_CATEGORY_TXT | UG_FILTER_CATEGORY_VCONTACT | UG_FILTER_CATEGORY_VCALENDAR \
+| UG_FILTER_CATEGORY_VNOTE | UG_FILTER_CATEGORY_VBOOKMARK | UG_FILTER_CATEGORY_VIDEO_PROJECT\
+| UG_FILTER_CATEGORY_SVG | UG_FILTER_CATEGORY_ETC
+
+
+#define MF_UG_PATH_INFO_RETRENCH 128
+#define MF_UG_PATH_INFO_HEAD_LEN(x) strlen(x)
+#define MF_UG_PATH_INFO_TRANS_OMIT elm_entry_utf8_to_markup("..")
+#define MF_UG_PATH_INFO_LEVEL_BOUNDARY 3
+#define MF_UG_PATH_INFO_LEN_THRESHOLD 4
+#define MF_UG_PATH_INFO_SEP elm_entry_utf8_to_markup("/")
+typedef struct {
+ int len_orig;
+ int len_trans;
+ char *original;
+ char *transfer;
+ bool flag_trans;
+}ug_pNode;
+
+/*********************
+**Function name: __mf_ug_fm_svc_wapper_COMESFROM
+**Parameter:
+** GString* fullpath: fullpath to check the location
+**
+**Return value:
+** location of the path
+**
+**Action:
+** get storage type by fullpath
+*********************/
+static int __mf_ug_fm_svc_wapper_COMESFROM(char *fullpath)
+{
+ int len_phone = strlen(PHONE_FOLDER);
+ int len_memory = strlen(MEMORY_FOLDER);
+
+ if (strncmp(fullpath, PHONE_FOLDER, len_phone) == 0) {
+ return MF_UG_PHONE;
+ } else if (strncmp(fullpath, MEMORY_FOLDER, len_memory) == 0) {
+ return MF_UG_MMC;
+ } else {
+ return MYFILE_ERR_STORAGE_TYPE_ERROR;
+ }
+}
+
+/******************************
+** Prototype : _ug_mf_get_file_list
+** Description :
+** Input : struct ugmyfiledata *data
+** GString* folder_name
+** Eina_List** dir_list
+** Eina_List** file_list
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+static int __mf_ug_fm_svc_wapper_get_file_list(GString *fullpath, Eina_List **dir_list, Eina_List **file_list)
+{
+ ug_mf_retvm_if(fullpath == NULL, MYFILE_ERR_INVALID_ARG, "fullpath is NULL");
+ ug_mf_retvm_if(fullpath->str == NULL, MYFILE_ERR_INVALID_ARG, "fullpath->str is NULL");
+ ug_mf_retvm_if(fullpath->len == 0, MYFILE_ERR_INVALID_ARG, "fullpath->len is 0");
+
+ int error_code = 0;
+
+ error_code = mf_ug_fs_oper_read_dir(fullpath->str, dir_list, file_list);
+ if (error_code != 0) {
+ ug_debug("error_code is [%d]\n", error_code);
+ } else {
+ ug_debug("success get the file list\n");
+ }
+ return error_code;
+}
+
+
+/******************************
+** Prototype : mfUgGetFileListWithFormat
+** Description :
+** Input : struct ugmyfiledata *data
+** GString* folder_name
+** Eina_List** dir_list
+** Eina_List** file_list
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+unsigned long mf_ug_fm_svc_wapper_get_file_filter(int file_filter_mode)
+{
+ unsigned long filter = 0;
+ switch (file_filter_mode) {
+ case SHOW_ALL_LIST:
+ filter |= UG_FILTER_CATEGORY_ALL;
+ ug_debug("show_all_list:::::::::::::::::::::::::::::::::: filter is [%d]", filter);
+ break;
+ case SHOW_IMAGE_LIST:
+ filter |= UG_FILTER_CATEGORY_IMAGE;
+ break;
+ case SHOW_SOUND_LIST:
+ filter |= UG_FILTER_CATEGORY_MUSIC | UG_FILTER_CATEGORY_SOUND | UG_FILTER_CATEGORY_VOICE;
+ break;
+ case SHOW_VIDEO_LIST:
+ filter |= UG_FILTER_CATEGORY_VIDEO;
+ break;
+ case SHOW_FLASH_LIST:
+ filter |= UG_FILTER_CATEGORY_FLASH;
+ break;
+ case SHOW_FOLDER_LIST:
+ break;
+ case SHOW_IMAGE_VIDEO_LIST:
+ filter |= UG_FILTER_CATEGORY_IMAGE | UG_FILTER_CATEGORY_VIDEO;
+ break;
+ case SHOW_IMAGE_SOUND_LIST:
+ filter |= UG_FILTER_CATEGORY_IMAGE | UG_FILTER_CATEGORY_SOUND | UG_FILTER_CATEGORY_MUSIC | UG_FILTER_CATEGORY_VOICE;
+ break;
+ case SHOW_VIDEO_SOUND_LIST:
+ filter |= UG_FILTER_CATEGORY_SOUND | UG_FILTER_CATEGORY_VIDEO | UG_FILTER_CATEGORY_MUSIC | UG_FILTER_CATEGORY_VOICE;
+ break;
+ default:
+ break;
+ }
+ return filter;
+}
+
+int mf_ug_fm_svc_wapper_get_file_list_by_filter(ugData *data, GString *fullpath, Eina_List **dir_list, Eina_List **filter_list)
+{
+ ugData *ugd = data;
+ ug_mf_retvm_if(ugd == NULL, MYFILE_ERR_INVALID_ARG, "ugd is NULL");
+ ug_mf_retvm_if(fullpath == NULL, MYFILE_ERR_INVALID_ARG, "fullpath is NULL");
+ ug_mf_retvm_if(fullpath->str == NULL, MYFILE_ERR_INVALID_ARG, "fullpath->str is NULL");
+ ug_mf_retvm_if(fullpath->len == 0, MYFILE_ERR_INVALID_ARG, "fullpath->len is 0");
+
+ int error_code = 0;
+ int filter_mode = 0;
+ int file_filter = 0;
+ int file_list_len = 0;
+ Eina_List *file_list = NULL;
+ char *extension = NULL;
+
+ filter_mode = ugd->ug_UiGadget.ug_iFilterMode;
+ file_filter = ugd->ug_UiGadget.ug_iFileFilter;
+
+ ug_debug("fullpath is [%s]", fullpath->str);
+ error_code = __mf_ug_fm_svc_wapper_get_file_list(fullpath, dir_list, &file_list);
+
+ if (error_code == 0) {
+ ug_debug();
+ file_list_len = eina_list_count(file_list);
+
+ if (file_list_len > 0) {
+ ug_debug("file_filter is [%d]\n", filter_mode);
+
+ if (filter_mode != SHOW_BY_EXTENSION) {
+ error_code = mf_ug_fs_oper_list_filter(file_list, filter_list, file_filter);
+ } else if (ugd->ug_UiGadget.ug_pExtension != NULL) {
+ extension = strdup(ugd->ug_UiGadget.ug_pExtension);
+ error_code = mf_ug_fs_oper_list_filter_by_extension(file_list, filter_list, extension);
+ free(extension);
+ }
+ ug_debug("error is [%d]%s %d\n", error_code, __func__, __LINE__);
+ return error_code;
+ }
+ }
+ ug_debug("error is [%d]%s %d\n", error_code, __func__, __LINE__);
+ return error_code;
+}
+
+
+
+/******************************
+** Prototype : mfUgIsRootPath
+** Description :
+** Input : None
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+bool mf_ug_fm_svc_wapper_is_root_path(void *data)
+{
+ ugData *ugd = (ugData *)data;
+ ug_mf_retvm_if(ugd == NULL, false, "ugd is NULL");
+
+ if (!strcmp(ugd->ug_Status.ug_pPath->str, PHONE_FOLDER)) {
+ return true;
+ } else if (!strcmp(ugd->ug_Status.ug_pPath->str, MEMORY_FOLDER)) {
+ return true;
+ } else {
+ return false;
+ }
+}
+
+
+/******************************
+** Prototype : mfUgGetFileName
+** Description :
+** Input : GString* path
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+GString *mf_ug_fm_svc_wapper_get_file_name(GString *path)
+{
+ GString *ret = NULL;
+ if (ecore_file_exists(path->str)) {
+ ret = g_string_new(ecore_file_file_get(path->str));
+ } else {
+ ret = NULL;
+ }
+ return ret;
+}
+
+char *mf_ug_fm_svc_wapper_get_root_path_by_tab_label(const char *label)
+{
+ if (g_strcmp0(label, MF_UG_LABEL_PHONE) == 0) {
+ return g_strdup(PHONE_FOLDER);
+ } else if (g_strcmp0(label, MF_UG_LABEL_MMC) == 0) {
+ return g_strdup(MEMORY_FOLDER);
+ } else
+ return NULL;
+}
+
+/******************************
+** Prototype : mf_ug_fm_svc_wapper_get_location
+** Description : Samsung
+** Input : char* fullpath
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+int mf_ug_fm_svc_wapper_get_location(char *fullpath)
+{
+ return __mf_ug_fm_svc_wapper_COMESFROM(fullpath);
+}
+
+gint mf_ug_fm_svc_wapper_get_folder_foldersystem(GString *path, bool * result)
+{
+
+ int error_code = 0;
+ error_code = mf_ug_file_attr_is_system_dir(path->str, result);
+ return error_code;
+
+}
+
+GString *mf_ug_fm_svc_wrapper_get_file_parent_path(GString *fullpath)
+{
+ GString *ret = NULL;
+ char *path = NULL;
+ int error_code = 0;
+
+ if (fullpath == NULL || fullpath->str == NULL) {
+ return NULL;
+ }
+ error_code = mf_ug_file_attr_get_parent_path(fullpath->str, &path);
+ if (error_code != 0) {
+ return NULL;
+ }
+
+ ret = g_string_new(path);
+ free(path);
+ path = NULL;
+ return ret;
+}
+
+char *mf_ug_fm_svc_path_info_retrench(const char *string)
+{
+ ug_mf_retvm_if(string == NULL, g_strdup(MF_UG_PATH_INFO_TRANS_OMIT), "input path is NULL");
+ char *retrench = NULL;
+ char *utf8_string = elm_entry_utf8_to_markup(string);
+ if (utf8_string && strlen (string) > MF_UG_PATH_INFO_LEN_THRESHOLD) {
+ if (g_utf8_strlen(utf8_string, -1) > 2) {
+ retrench = calloc(1, MF_UG_PATH_INFO_RETRENCH);
+ if (retrench) {
+ char *omit = MF_UG_PATH_INFO_TRANS_OMIT;
+ char *temp = g_utf8_strncpy(retrench, utf8_string, 2);
+ retrench = g_strconcat(temp, omit, NULL);
+ UG_SAFE_FREE_CHAR(omit);
+ UG_SAFE_FREE_CHAR(utf8_string);
+ UG_SAFE_FREE_CHAR(temp);
+ }
+
+ } else {
+ retrench = utf8_string;
+ }
+ return retrench;
+ } else {
+ return utf8_string;
+ }
+}
+
+static void __mf_ug_fm_svc_wrapper_path_info_node_free(Eina_List *list)
+{
+ ug_mf_retm_if(list == NULL, "list is NULL");
+ const Eina_List *l = NULL;
+ void *data = NULL;
+ EINA_LIST_FOREACH(list, l, data) {
+ ug_pNode *node = (ug_pNode *)data;
+ if (node != NULL) {
+ UG_SAFE_FREE_CHAR(node->original);
+ UG_SAFE_FREE_CHAR(node->transfer);
+ UG_SAFE_FREE_CHAR(node);
+ }
+ }
+ eina_list_free(list);
+}
+
+
+char *mf_ug_fm_svc_path_info_translate(char *path_info, int path_info_max_len)
+{
+
+ ug_mf_retvm_if(path_info == NULL, g_strdup(dgettext("sys_string", "IDS_COM_BODY_UNKNOWN")), "input path is NULL");
+
+ int top = 0;
+ bool flag = TRUE;
+ Eina_List *temp_list = NULL;
+ const Eina_List *l = NULL;
+ gchar **result = NULL;
+ gchar **params = NULL;
+ int count = 0;
+ int max_len = 0;
+ int total_len = 0;
+ int i = 0;
+ char *output = NULL;
+ void *pnode = NULL;
+ char *omit = MF_UG_PATH_INFO_TRANS_OMIT;
+
+ if (strlen(path_info) < path_info_max_len) {
+ UG_SAFE_FREE_CHAR(omit);
+ return path_info;
+ }
+
+ result = g_strsplit(path_info, "/", 0);
+ if (result == NULL) {
+ free(path_info);
+ path_info = NULL;
+ UG_SAFE_FREE_CHAR(omit);
+ return g_strdup(dgettext("sys_string", "IDS_COM_BODY_UNKNOWN"));
+ }
+
+ params = result;
+ count = g_strv_length(result);
+
+ if (count > MF_UG_PATH_INFO_LEVEL_BOUNDARY)
+ {
+ top = MF_UG_PATH_INFO_LEVEL_BOUNDARY;
+ flag = FALSE;
+ max_len = path_info_max_len - MF_UG_PATH_INFO_LEVEL_BOUNDARY - MF_UG_PATH_INFO_HEAD_LEN(omit);//(2 is length of ..) ../aa../bb../***
+ }
+ else
+ {
+ top = count;
+ flag = TRUE;
+ max_len = path_info_max_len - (count-1);
+ }
+
+ for(i = top; i > 1; i--)
+ {
+ ug_pNode *nodeB = calloc(sizeof(ug_pNode), 1);
+ nodeB->original = elm_entry_utf8_to_markup(params[count -i]);
+ nodeB->len_orig = strlen(params[count - i]);
+ nodeB->transfer = mf_ug_fm_svc_path_info_retrench(params[count-i]);
+ nodeB->len_trans = strlen(nodeB->transfer);
+ nodeB->flag_trans = FALSE;
+ total_len += nodeB->len_orig;
+
+ temp_list = eina_list_append(temp_list, nodeB);
+ }
+
+ total_len += strlen(params[count - 1]);
+
+ for (i = 0 ; i < eina_list_count(temp_list); i++)
+ {
+ if (total_len > max_len)
+ {
+ ug_pNode *data = NULL;
+ data = eina_list_nth(temp_list, i);
+ total_len -= (data->len_orig - data->len_trans);
+ data->flag_trans = TRUE;
+ }
+
+ if (total_len <= max_len)
+ break;
+ }
+
+
+ if (flag == FALSE)
+ {
+ output = elm_entry_utf8_to_markup("..");
+ }
+ char *temp = NULL;
+ char *sep = MF_UG_PATH_INFO_SEP;
+ EINA_LIST_FOREACH(temp_list, l, pnode)
+ {
+ ug_pNode *node = (ug_pNode *)pnode;
+ temp = output;
+ if(node->flag_trans == TRUE)
+ {
+ if (output != NULL)
+ output = g_strconcat(output, sep, node->transfer, NULL);
+ else
+ output = g_strdup(node->transfer);
+ }
+ else
+ {
+ if (output != NULL)
+ output = g_strconcat(output, sep ,node->original, NULL);
+ else
+ output = g_strdup(node->original);
+ }
+ UG_SAFE_FREE_CHAR(temp);
+ }
+ temp = output;
+ char *last_string = params[count - 1];
+ char *utf8_last = elm_entry_utf8_to_markup(last_string);
+
+ if (output != NULL) {
+ int last_len = strlen(last_string);
+ int output_len = strlen(output);
+ int d_value = path_info_max_len - output_len;
+ if ((last_len + output_len) > path_info_max_len) {
+ const char *end = (char *)calloc(1, d_value+1);
+ g_utf8_validate(utf8_last, d_value, &end);
+ d_value = last_len - strlen(end);
+ utf8_last[d_value] = '\0';
+ output = g_strconcat(output, sep, utf8_last, omit, NULL);
+ } else {
+ output = g_strconcat(output, sep, utf8_last, NULL);
+ }
+ }
+ else
+ output = g_strdup(utf8_last);
+ UG_SAFE_FREE_CHAR(utf8_last);
+
+ UG_SAFE_FREE_CHAR(temp);
+ UG_SAFE_FREE_CHAR(sep);
+ UG_SAFE_FREE_CHAR(omit);
+ UG_SAFE_FREE_CHAR(path_info);
+ __mf_ug_fm_svc_wrapper_path_info_node_free(temp_list);
+ temp_list = NULL;
+ g_strfreev(result);
+ result = NULL;
+ return output;
+}
+
+
+char *mf_ug_fm_svc_wrapper_translate_path(char *original_path)
+{
+ ug_mf_retvm_if(original_path == NULL, g_strdup(dgettext("sys_string", "IDS_COM_BODY_UNKNOWN")), "input path is NULL");
+
+ char *new_path = NULL;
+ int root_len = 0;
+
+ if (mf_ug_fm_svc_wapper_get_location(original_path) == MF_UG_PHONE) {
+ root_len = strlen(PHONE_FOLDER);
+ new_path = g_strconcat(MF_UG_LABEL_PHONE, original_path + root_len, "/", NULL);
+ } else if (mf_ug_fm_svc_wapper_get_location(original_path) == MF_UG_MMC) {
+ root_len = strlen(MEMORY_FOLDER);
+ new_path = g_strconcat(MF_UG_LABEL_MMC, original_path + root_len, "/", NULL);
+ } else {
+ new_path = g_strdup(original_path);
+ }
+
+ ug_debug("new path is %s", new_path);
+ return new_path;
+}
+
+char *mf_ug_fm_svc_wapper_path_info_get(char *original_path)
+{
+ ug_mf_retvm_if(original_path == NULL, g_strdup(dgettext("sys_string", "IDS_COM_BODY_UNKNOWN")), "input path is NULL");
+ char *path_info = NULL;
+ int len = 0;
+
+ path_info = mf_ug_fm_svc_wrapper_translate_path(original_path);
+ if (path_info) {
+ len = strlen(path_info);
+ if (len > 0 && path_info[len - 1] == '/') {
+ path_info[len - 1] = '\0';
+ }
+ }
+ return path_info;
+
+}
+
diff --git a/src/common/mf-ug-inotify-handle.c b/src/common/mf-ug-inotify-handle.c
new file mode 100755
index 0000000..33432b2
--- /dev/null
+++ b/src/common/mf-ug-inotify-handle.c
@@ -0,0 +1,348 @@
+/*
+ * Copyright 2012 Samsung Electronics Co., Ltd
+ *
+ * Licensed under the Flora License, Version 1.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.tizenopensource.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 <stdio.h>
+#include <glib.h>
+#include <sys/inotify.h>
+#include <sys/types.h>
+#include <sys/stat.h>
+#include <unistd.h>
+#include <stdint.h>
+#include <fcntl.h>
+#include <errno.h>
+#include <pthread.h>
+
+#include "mf-ug-dlog.h"
+#include "mf-ug-inotify-handle.h"
+
+#define MF_WATCH_FLAGS \
+ IN_CREATE | IN_DELETE | IN_DELETE_SELF | IN_MOVE_SELF | IN_MOVED_FROM | IN_MOVED_TO | IN_CLOSE_WRITE
+
+#define MF_EVENT_SIZE (sizeof(struct inotify_event))
+/** reasonable guess as to size of 1024 events */
+#define MF_EVENT_BUF_LEN (1024 * (MF_EVENT_SIZE + 16))
+
+typedef struct _mf_inotify_t {
+ int fd;
+ int wd;
+ gchar *path;
+ unsigned int prev_event;
+ pthread_t monitor;
+ mf_ug_inotify_cb callback;
+ void *u_data;
+} mf_inotify_t;
+
+static pthread_mutex_t mf_noti_lock;
+static mf_inotify_t *g_handle;
+
+static void __mf_ug_inotify_handle_free_handle(void)
+{
+ pthread_mutex_destroy(&mf_noti_lock);
+
+ if (g_handle) {
+ if (g_handle->fd >= 0) {
+ close(g_handle->fd);
+ g_handle->fd = -1;
+ }
+ if (g_handle->path) {
+ g_free(g_handle->path);
+ g_handle->path = NULL;
+ }
+ g_free(g_handle);
+ g_handle = NULL;
+ }
+
+ return;
+}
+
+static mf_inotify_t *__mf_ug_inotify_handle_init_handle(void)
+{
+ __mf_ug_inotify_handle_free_handle();
+ g_handle = g_new0(mf_inotify_t, 1);
+
+ if (g_handle) {
+ g_handle->fd = -1;
+ g_handle->wd = -1;
+ pthread_mutex_init(&mf_noti_lock, NULL);
+ }
+
+ return g_handle;
+}
+
+static void __mf_ug_inotify_handle_clean_up_thread(void *data)
+{
+ pthread_mutex_t *lock = (pthread_mutex_t *) data;
+ ug_mf_debug("Thread cancel Clean_up function");
+ if (lock) {
+ pthread_mutex_unlock(lock);
+ }
+ return;
+}
+
+
+static gpointer __mf_ug_inotify_handle_watch_thread(gpointer user_data)
+{
+ mf_inotify_t *handle = (mf_inotify_t *) user_data;
+ int oldtype = 0;
+
+ ug_mf_retvm_if(handle == NULL, NULL, "handle is NULL");
+ ug_mf_debug("Create __mf_ug_inotify_handle_watch_thread!!! ");
+
+ pthread_setcanceltype(PTHREAD_CANCEL_DEFERRED, &oldtype);
+
+ while (1) {
+ ssize_t len = 0;
+ uint32_t i = 0;
+ char event_buff[MF_EVENT_BUF_LEN] = { 0, };
+
+ if (handle->fd < 0) {
+ ug_mf_error("fd is not a vaild one");
+ pthread_exit(NULL);
+ }
+
+ len = read(handle->fd, event_buff, sizeof(event_buff) - 1);
+ if (len <= 0 || len > sizeof(event_buff) - 1) {
+ ug_mf_error("Fail to read() -fd : %d, len : %d", handle->fd, len);
+ continue;
+ }
+
+ while (i < len) {
+ struct inotify_event *pevent = (struct inotify_event *)&event_buff[i];
+ mf_ug_inotify_event s_event = UG_MF_INOTI_NONE;
+ ug_mf_error("mask=%x dir=%s len=%d name=%s",
+ pevent->mask, (pevent->mask & IN_ISDIR) ? "yes" : "no", pevent->len, (pevent->len) ? pevent->name : NULL);
+
+ if (pevent->len && strncmp(pevent->name, ".", 1) == 0) {
+ s_event = UG_MF_INOTI_NONE;
+ } else if (pevent->mask & IN_ISDIR) {
+ if (pevent->mask & IN_DELETE_SELF)
+ s_event = UG_MF_INOTI_DELETE_SELF;
+
+ if (pevent->mask & IN_MOVE_SELF)
+ s_event = UG_MF_INOTI_MOVE_SELF;
+
+ if (pevent->mask & IN_CREATE)
+ s_event = UG_MF_INOTI_CREATE;
+
+ if (pevent->mask & IN_DELETE)
+ s_event = UG_MF_INOTI_DELETE;
+
+ if (pevent->mask & IN_MOVED_FROM)
+ s_event = UG_MF_INOTI_MOVE_OUT;
+
+ if (pevent->mask & IN_MOVED_TO)
+ s_event = UG_MF_INOTI_MOVE_IN;
+ } else {
+ if (pevent->mask & IN_CREATE) {
+ s_event = UG_MF_INOTI_NONE;
+ handle->prev_event = IN_CREATE;
+ }
+
+ if (pevent->mask & IN_CLOSE_WRITE) {
+ if (handle->prev_event == IN_CREATE) {
+ s_event = UG_MF_INOTI_CREATE;
+ } else {
+ s_event = UG_MF_INOTI_MODIFY;
+ }
+ handle->prev_event = 0;
+ }
+
+ if (pevent->mask & IN_DELETE)
+ s_event = UG_MF_INOTI_DELETE;
+
+ if (pevent->mask & IN_MOVED_FROM)
+ s_event = UG_MF_INOTI_MOVE_OUT;
+
+ if (pevent->mask & IN_MOVED_TO)
+ s_event = UG_MF_INOTI_MOVE_IN;
+ }
+
+ ug_mf_debug("s_event : %d, prev_event: %x, callback : %p", s_event, handle->prev_event, handle->callback);
+ if (s_event != UG_MF_INOTI_NONE) {
+ pthread_cleanup_push(__mf_ug_inotify_handle_clean_up_thread, (void *)&mf_noti_lock);
+ pthread_mutex_lock(&mf_noti_lock);
+ if (handle->callback) {
+ handle->callback(s_event, (pevent->len) ? pevent->name : NULL, handle->u_data);
+ }
+ pthread_mutex_unlock(&mf_noti_lock);
+ pthread_cleanup_pop(0);
+ }
+
+ i += sizeof(struct inotify_event) + pevent->len;
+ }
+ }
+
+ ug_mf_debug("end __mf_ug_inotify_handle_watch_thread!!! ");
+
+ return NULL;
+}
+
+int mf_ug_inotify_handle_init_inotify(void)
+{
+ mf_inotify_t *handle = NULL;
+ handle = __mf_ug_inotify_handle_init_handle();
+ ug_mf_retvm_if(handle == NULL, -1, "fail to __mf_ug_inotify_handle_init_handle()");
+
+ handle->fd = inotify_init();
+
+ if (handle->fd < 0) {
+ switch (errno) {
+ case EMFILE:
+ ug_mf_error("The user limit on the total number of inotify instances has been reached.\n");
+ break;
+ case ENFILE:
+ ug_mf_error("The system limit on the total number of file descriptors has been reached.\n");
+ break;
+ case ENOMEM:
+ ug_mf_error("Insufficient kernel memory is available.\n");
+ break;
+ default:
+ ug_mf_error("Fail to inotify_init(), Unknown error.\n");
+ break;
+ }
+ return -1;
+ }
+ pthread_create(&handle->monitor, NULL, __mf_ug_inotify_handle_watch_thread, handle);
+ return 0;
+}
+
+int mf_ug_inotify_handle_add_inotify_watch(const char *path, mf_ug_inotify_cb callback, void *user_data)
+{
+ mf_inotify_t *handle = NULL;
+ handle = g_handle;
+ ug_mf_retvm_if(handle == NULL, -1, "handle is NULL");
+
+ if (handle->wd >= 0) {
+ ug_mf_warnig("The mf_notify module supports single instance, the watch descript [%d] is removed automatically\n", handle->wd);
+ mf_ug_inotify_handle_rm_inotify_watch();
+ }
+
+ pthread_mutex_lock(&mf_noti_lock);
+ handle->wd = inotify_add_watch(handle->fd, path, MF_WATCH_FLAGS);
+
+ if (handle->wd < 0) {
+ switch (errno) {
+ case EACCES:
+ ug_mf_error("Read access to the given file is not permitted.\n");
+ break;
+ case EBADF:
+ ug_mf_error("The given file descriptor is not valid.\n");
+ handle->fd = -1;
+ break;
+ case EFAULT:
+ ug_mf_error("pathname points outside of the process's accessible address space.\n");
+ break;
+ case EINVAL:
+ ug_mf_error("The given event mask contains no legal events; or fd is not an inotify file descriptor.\n");
+ break;
+ case ENOMEM:
+ ug_mf_error("Insufficient kernel memory is available.\n");
+ break;
+ case ENOSPC:
+ ug_mf_error("User limit on the total num of inotify watch was reached or the kernel failed to alloc a needed resource.\n");
+ break;
+ default:
+ ug_mf_error("Fail to ug_ug_mf_inotify_add_watch(), Unknown error.\n");
+ break;
+ }
+ pthread_mutex_unlock(&mf_noti_lock);
+ return -1;
+ }
+
+ ug_mf_debug("start watching [%s] directory", path);
+ if (handle->path) {
+ g_free(handle->path);
+ handle->path = NULL;
+ }
+ handle->path = g_strdup(path);
+ handle->callback = callback;
+ handle->u_data = user_data;
+ pthread_mutex_unlock(&mf_noti_lock);
+
+ return 0;
+}
+
+
+
+int mf_ug_inotify_handle_rm_inotify_watch(void)
+{
+ int ret = -1;
+ mf_inotify_t *handle = NULL;
+
+ handle = g_handle;
+ ug_mf_retvm_if(handle == NULL, -1, "handle is NULL");
+
+ if (handle->fd < 0 || handle->wd < 0) {
+ ug_mf_warnig("inotify is not initialized or has no watching dir - fd [%d] wd [%d]", handle->fd, handle->wd);
+ return 0;
+ }
+
+ pthread_mutex_lock(&mf_noti_lock);
+
+ ret = inotify_rm_watch(handle->fd, handle->wd);
+ if (ret < 0) {
+ switch (errno) {
+ case EBADF:
+ ug_mf_error("fd is not a valid file descriptor\n");
+ handle->fd = -1;
+ break;
+ case EINVAL:
+ ug_mf_error("The watch descriptor wd is not valid; or fd is not an inotify file descriptor.\n");
+ handle->wd = -1;
+ break;
+ default:
+ ug_mf_error("Fail to mf_ug_inotify_handle_add_inotify_watch(), Unknown error.\n");
+ break;
+ }
+ pthread_mutex_unlock(&mf_noti_lock);
+ return -1;
+ }
+ ug_mf_debug("stop watching [%s] directory", handle->path);
+ if (handle->path) {
+ g_free(handle->path);
+ handle->path = NULL;
+ }
+ handle->callback = NULL;
+ handle->u_data = NULL;
+ handle->wd = -1;
+ pthread_mutex_unlock(&mf_noti_lock);
+
+ return 0;
+}
+
+void mf_ug_inotify_handle_finalize_inotify(void)
+{
+ mf_inotify_t *handle = NULL;
+ handle = g_handle;
+
+ ug_mf_retm_if(handle == NULL, "handle is NULL");
+
+ if (handle->fd >= 0 && handle->wd >= 0) {
+ mf_ug_inotify_handle_rm_inotify_watch();
+ }
+
+ pthread_cancel(handle->monitor);
+ pthread_join(handle->monitor, NULL);
+
+ __mf_ug_inotify_handle_free_handle();
+
+ return;
+}
diff --git a/src/common/mf-ug-list-play.c b/src/common/mf-ug-list-play.c
new file mode 100755
index 0000000..64591ec
--- /dev/null
+++ b/src/common/mf-ug-list-play.c
@@ -0,0 +1,989 @@
+/*
+ * Copyright 2012 Samsung Electronics Co., Ltd
+ *
+ * Licensed under the Flora License, Version 1.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.tizenopensource.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 <stdio.h>
+#include <Elementary.h>
+#include <Ecore_X.h>
+#include <mm_player.h>
+#include <mm_error.h>
+#include <vconf.h>
+#include <stdbool.h>
+
+#include "mf-ug-main.h"
+#include "mf-ug-conf.h"
+#include "mf-ug-cb.h"
+#include "mf-ug-fm-svc-wrapper.h"
+#include "mf-ug-util.h"
+#include "mf-ug-winset.h"
+#include "mf-ug-dlog.h"
+#include "mf-ug-fs-util.h"
+
+
+
+/******************************
+** Prototype : __mf_ug_list_play_init_data
+** Description : Samsung
+** Input : void *data
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+static void __mf_ug_list_play_init_data(void *data)
+{
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+
+ ug_mf_retm_if(ugd == NULL, "ugd is NULL");
+
+ if (ugd->ug_ListPlay.ug_Player != 0) {
+ mf_ug_list_play_destory_playing_file(ugd);
+ ugd->ug_ListPlay.ug_Player = 0;
+ }
+ ugd->ug_ListPlay.ug_iPlayState = PLAY_STATE_INIT;
+ ugd->ug_ListPlay.ug_pPlayFilePath = NULL;
+ UG_TRACE_END;
+}
+
+/******************************
+** Prototype : _mp_playing_error
+** Description :
+** Input : void * data
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+static int __mf_ug_list_play_playing_error(ugListItemData *data)
+{
+ UG_TRACE_BEGIN;
+ ugListItemData *itemData = data;
+ ug_mf_retvm_if(itemData == NULL, 0, "itemData is NULL");
+
+ mf_ug_list_play_destory_playing_file(itemData->ug_pData);
+ UG_TRACE_END;
+ return 0;
+}
+
+/******************************
+** Prototype : __mf_ug_list_play_update_item_icon
+** Description :
+** Input : ugListItemData *data
+** int state
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+static void __mf_ug_list_play_update_item_icon(void *data)
+{
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+ ug_mf_retm_if(ugd == NULL, "ugd is NULL");
+
+ Elm_Object_Item *gl_item = NULL;
+ ugListItemData *itemData = NULL;
+ ugNaviBar *pNaviInUse = NULL;
+ Evas_Object *pGenlist = NULL;
+
+ if (ugd->ug_ListPlay.ug_pPlayFilePath == NULL || strlen(ugd->ug_ListPlay.ug_pPlayFilePath) == 0) {
+ return;
+ }
+ pNaviInUse = mf_ug_navi_bar_get_in_use_navi(ugd);
+ pGenlist = pNaviInUse->ug_pContent;
+
+ gl_item = elm_genlist_first_item_get(pGenlist);
+ while (gl_item) {
+ itemData = elm_object_item_data_get(gl_item);
+ if (itemData && itemData->ug_pItemName) {
+ if (g_strcmp0(ugd->ug_ListPlay.ug_pPlayFilePath, itemData->ug_pItemName->str) == 0) {
+ elm_genlist_item_update(gl_item);
+ UG_TRACE_END;
+ return;
+ }
+ }
+ gl_item = elm_genlist_item_next_get(gl_item);
+ }
+
+ ug_debug("__mf_ug_list_play_update_item_icon failed");
+ UG_TRACE_END;
+}
+
+
+/******************************
+** Prototype : __mf_ug_list_play_set_play_start_status
+** Description :
+** Input : ugListItemData *data
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+static void __mf_ug_list_play_set_play_start_status(void *data, char *path)
+{
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+ ug_mf_retm_if(ugd == NULL, "ugd is NULL");
+
+ ugd->ug_ListPlay.ug_iPlayState = PLAY_STATE_PLAYING;
+ UG_TRACE_END;
+}
+
+/******************************
+** Prototype : __mf_ug_list_play_set_play_resume_status
+** Description :
+** Input : ugListItemData *data
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+static void __mf_ug_list_play_set_play_resume_status(void *data)
+{
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+ ug_mf_retm_if(ugd == NULL, "ugd is NULL");
+
+ ugd->ug_ListPlay.ug_iPlayState = PLAY_STATE_PLAYING;
+ UG_TRACE_END;
+}
+
+/******************************
+** Prototype : __mf_ug_list_play_set_play_pause_status
+** Description :
+** Input : ugListItemData *data
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+static void __mf_ug_list_play_set_play_pause_status(ugData *data)
+{
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+ ug_mf_retm_if(ugd == NULL, "ugd is NULL");
+
+ ugd->ug_ListPlay.ug_iPlayState = PLAY_STATE_PAUSED;
+ UG_TRACE_END;
+}
+
+/******************************
+** Prototype : __mf_ug_list_play_msg_cb
+** Description :
+** Input : int msg_type
+** void *msg_param
+** void *user_param
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+static int __mf_ug_list_play_msg_cb(int msg_type, void *msg_param, ugListItemData *user_param)
+{
+ UG_TRACE_BEGIN;
+ ugListItemData *itemData = user_param;
+ ug_mf_retvm_if(itemData == NULL, false, "itemData is NULL");
+ ugData *ugd = itemData->ug_pData;
+ ug_mf_retvm_if(ugd == NULL, false, "ugd is NULL");
+
+ MMMessageParamType *param = (MMMessageParamType *) msg_param;
+
+ ug_debug("msg_type is [%d]", msg_type);
+ if (ugd->ug_ListPlay.ug_Player == 0) {
+ return false;
+ } else {
+ switch (msg_type) {
+ case MM_MESSAGE_BEGIN_OF_STREAM:
+ ug_debug("receive MM_MESSAGE_BEGIN_OF_STREAM\n");
+ break;
+ case MM_MESSAGE_ERROR:
+ ug_debug("receive MM_MESSAGE_ERROR Error Code=%x\n", param->code);
+ switch (param->code) {
+ case MM_ERROR_PLAYER_INTERNAL:
+ ug_debug("receive MM_ERROR_PLAYER_INTERNAL\n");
+ break;
+ }
+ ecore_idler_add((Ecore_Task_Cb) __mf_ug_list_play_playing_error, itemData);
+ break;
+ case MM_MESSAGE_WARNING:
+ ug_debug("receive MM_MESSAGE_WARNING\n");
+ break;
+ case MM_MESSAGE_STATE_CHANGED:
+
+ ug_mf_retvm_if(param == NULL, false, "param is NULL");
+ ug_debug("msg_type is [%d]", param->state.current);
+ switch (param->state.current) {
+ case MM_PLAYER_STATE_NONE:
+ ug_debug("==> [MediaPlayerApp] Player is [NONE]\n");
+ break;
+ case MM_PLAYER_STATE_READY:
+ ug_debug("==> [MediaPlayerApp] Player is [READY]\n");
+ ugd->ug_ListPlay.ug_iPlayState = PLAY_STATE_READY;
+ __mf_ug_list_play_update_item_icon(ugd);
+ break;
+ case MM_PLAYER_STATE_PLAYING:
+ ug_debug("==> [MediaPlayerApp] Player is [PLAYING]\n");
+ if (ugd->ug_ListPlay.ug_iPlayState == PLAY_STATE_READY) {
+ if (ugd->ug_ListPlay.ug_pPlayFilePath == NULL)
+ ugd->ug_ListPlay.ug_pPlayFilePath = g_strdup(itemData->ug_pItemName->str);
+ __mf_ug_list_play_set_play_start_status(ugd, itemData->ug_pItemName->str);
+ } else if (ugd->ug_ListPlay.ug_iPlayState == PLAY_STATE_PAUSED) {
+ if (ugd->ug_ListPlay.ug_pPlayFilePath == NULL)
+ ugd->ug_ListPlay.ug_pPlayFilePath = g_strdup(itemData->ug_pItemName->str);
+ __mf_ug_list_play_set_play_resume_status(ugd);
+ }
+ __mf_ug_list_play_update_item_icon(ugd);
+ break;
+ case MM_PLAYER_STATE_PAUSED:
+ ug_debug("==> [MediaPlayerApp] Player is [PAUSED]\n");
+ __mf_ug_list_play_set_play_pause_status(ugd);
+ __mf_ug_list_play_update_item_icon(ugd);
+ break;
+ case MM_PLAYER_STATE_NULL:
+ ug_debug("==> [MediaPlayerApp] Player is [NULL]\n");
+ if (ugd->ug_ListPlay.ug_pPlayFilePath != NULL) {
+ g_free(ugd->ug_ListPlay.ug_pPlayFilePath);
+ ugd->ug_ListPlay.ug_pPlayFilePath = NULL;
+ }
+ break;
+ default:
+ break;
+ }
+
+ break;
+ case MM_MESSAGE_STATE_INTERRUPTED:
+ ug_debug("receive MM_MESSAGE_STATE_CHANGED_BY_ASM\n");
+ __mf_ug_list_play_set_play_pause_status(ugd);
+ __mf_ug_list_play_update_item_icon(ugd);
+ break;
+ case MM_MESSAGE_END_OF_STREAM:
+ mf_ug_list_play_destory_playing_file(ugd);
+ if (ugd->ug_ListPlay.ug_pPlayFilePath != NULL) {
+ g_free(ugd->ug_ListPlay.ug_pPlayFilePath);
+ ugd->ug_ListPlay.ug_pPlayFilePath = NULL;
+ }
+ break;
+ default:
+ UG_TRACE_END;
+ return false;
+ }
+ }
+ return true;
+}
+
+/******************************
+** Prototype : _mp_player_mgr_create
+** Description :
+** Input : void *data
+** const gchar *path
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+static bool __mf_ug_list_play_create_player_mgr(void *data, const char *path)
+{
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+ ug_mf_retvm_if(ugd == NULL, false, "ugd is NULL");
+
+ int path_len = strlen(path);
+ char *g_err_name = NULL;
+ int ret = MM_ERROR_NONE;
+
+ if (path_len > 0 && path_len < MYFILE_DIR_PATH_LEN_MAX) {
+ if (ugd->ug_ListPlay.ug_Player == 0) {
+ if (mm_player_create(&ugd->ug_ListPlay.ug_Player) != MM_ERROR_NONE) {
+ ug_debug("Error when __mf_ug_list_play_create_player_mgr\n");
+ UG_TRACE_END;
+ return false;
+ }
+ /*avsysaudiosink volume table setting */
+
+ ret = mm_player_set_attribute(ugd->ug_ListPlay.ug_Player, &g_err_name, "sound_volume_type", MM_SOUND_VOLUME_TYPE_MEDIA,
+ "profile_uri", path, strlen(path), NULL);
+ if (ret != MM_ERROR_NONE) {
+ ug_debug(">>>>>>>>>>>>>g_err_name : %s\n", g_err_name);
+ UG_TRACE_END;
+ return false;
+ } else {
+ UG_TRACE_END;
+ return true;
+ }
+ } else {
+ ug_debug("player handle is exist");
+ UG_TRACE_END;
+ return false;
+ }
+ } else {
+ ug_debug("the path_len is too long");
+ UG_TRACE_END;
+ return false;
+ }
+}
+
+/******************************
+** Prototype : _mp_player_mgr_set_msg_callback
+** Description :
+** Input : MMMessageCallback cb
+** gpointer user_data
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+static bool __mf_ug_list_play_set_player_mgr_msg_cb(MMMessageCallback cb, gpointer user_data)
+{
+ UG_TRACE_BEGIN;
+
+ ugListItemData *itemData = (ugListItemData *)user_data;
+ ug_mf_retvm_if(itemData == NULL, false, "itemData is NULL");
+
+ ugData *ugd = itemData->ug_pData;
+ ug_mf_retvm_if(ugd == NULL, false, "ugd is NULL");
+
+ if (ugd->ug_ListPlay.ug_Player != 0) {
+ if (mm_player_set_message_callback(ugd->ug_ListPlay.ug_Player, cb, user_data) != MM_ERROR_NONE) {
+ ug_debug("Error when _mp_player_mgr_set_msg_callback\n");
+ UG_TRACE_END;
+ return false;
+ } else {
+ UG_TRACE_END;
+ return true;
+ }
+ }
+ UG_TRACE_END;
+ return false;
+}
+
+
+/******************************
+** Prototype : _mp_player_mgr_realize
+** Description :
+** Input : ugListItemData *data
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+static bool __mf_ug_list_play_realize_player_mgr(void *data)
+{
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+
+ ug_mf_retvm_if(ugd == NULL, false, "ugd is NULL");
+
+ int error_code = 0;
+ MMPlayerStateType state = MM_PLAYER_STATE_NONE;
+
+ if (ugd->ug_ListPlay.ug_Player != 0) {
+ error_code = mm_player_get_state(ugd->ug_ListPlay.ug_Player, &state);
+
+ if (0 == error_code && MM_PLAYER_STATE_NULL == state) {
+ if (mm_player_realize(ugd->ug_ListPlay.ug_Player) != MM_ERROR_NONE) {
+ ug_debug("Error when _mp_player_mgr_realize\n");
+ UG_TRACE_END;
+ return false;
+ } else {
+ UG_TRACE_END;
+ return true;
+ }
+ } else {
+ UG_TRACE_END;
+ return false;
+ }
+ }
+ UG_TRACE_END;
+
+ return false;
+}
+
+
+/******************************
+** Prototype : __mf_ug_list_play_ready_new_file_play
+** Description : Samsung
+** Input : void *data
+**
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+static bool __mf_ug_list_play_ready_new_file_play(void *data)
+{
+
+ UG_TRACE_BEGIN;
+ ugListItemData *itemData = data;
+ ug_mf_retvm_if(itemData == NULL, false, "itemData is NULL");
+
+ ugData *ugd = (ugData *)itemData->ug_pData;
+ ug_mf_retvm_if(ugd == NULL, false, "ugd is NULL");
+
+ char *path = strdup(itemData->ug_pItemName->str);
+
+ /*check if file is exist */
+ if (path != NULL) {
+ if (!ecore_file_exists(path)) {
+ ug_debug("Error file %s is not exist\n", path);
+ free(path);
+ path = NULL;
+ UG_TRACE_END;
+ return false;
+ }
+
+ if (!__mf_ug_list_play_create_player_mgr(ugd, path)) {
+ ug_debug();
+ free(path);
+ path = NULL;
+ UG_TRACE_END;
+ return false;
+ }
+
+
+ if (!__mf_ug_list_play_set_player_mgr_msg_cb((MMMessageCallback) __mf_ug_list_play_msg_cb, itemData)) {
+ free(path);
+ path = NULL;
+ UG_TRACE_END;
+ return false;
+ }
+
+
+ if (!__mf_ug_list_play_realize_player_mgr(ugd)) {
+ free(path);
+ path = NULL;
+ UG_TRACE_END;
+ return false;
+ }
+ free(path);
+ path = NULL;
+ UG_TRACE_END;
+ return true;
+ } else {
+ return false;
+ }
+
+}
+
+
+/******************************
+** Prototype : _mp_player_mgr_play
+** Description :
+** Input : ugListItemData *data
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+static bool __mf_ug_list_play_play(void *data)
+{
+
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+ ug_mf_retvm_if(ugd == NULL, false, "ugd is NULL");
+
+ int err = MM_ERROR_NONE;
+ int error_code = 0;
+ MMPlayerStateType state = MM_PLAYER_STATE_NONE;
+
+ if (ugd->ug_ListPlay.ug_Player != 0) {
+ error_code = mm_player_get_state(ugd->ug_ListPlay.ug_Player, &state);
+
+ if (0 == error_code && MM_PLAYER_STATE_READY == state) {
+ err = mm_player_start(ugd->ug_ListPlay.ug_Player);
+ if (err != MM_ERROR_NONE) {
+ ug_debug("Error when _mp_player_mgr_play. err[%x]\n", err);
+ UG_TRACE_END;
+ return false;
+ } else {
+ UG_TRACE_END;
+ return true;
+ }
+ } else {
+ UG_TRACE_END;
+ return false;
+ }
+ } else {
+ UG_TRACE_END;
+ return false;
+ }
+}
+
+/******************************
+** Prototype : __mf_ug_list_play_stop
+** Description :
+** Input : void *data
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+static bool __mf_ug_list_play_stop(ugData *data)
+{
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+ ug_mf_retvm_if(ugd == NULL, false, "ugd is NULL");
+
+ MMPlayerStateType state = MM_PLAYER_STATE_NONE;
+ int error_code = 0;
+
+ if (ugd->ug_ListPlay.ug_Player != 0) {
+ error_code = mm_player_get_state(ugd->ug_ListPlay.ug_Player, &state);
+
+ if (0 == error_code && (MM_PLAYER_STATE_PLAYING == state || MM_PLAYER_STATE_PAUSED == state)) {
+ if (mm_player_stop(ugd->ug_ListPlay.ug_Player) != MM_ERROR_NONE) {
+ ug_debug("Error when __mf_ug_list_play_stop\n");
+ UG_TRACE_END;
+ return false;
+ } else {
+
+ ugd->ug_ListPlay.ug_iPlayState = PLAY_STATE_STOP;
+ UG_TRACE_END;
+ return true;
+ }
+
+ } else {
+ UG_TRACE_END;
+ return false;
+ }
+ }
+ UG_TRACE_END;
+ return false;
+}
+
+/******************************
+** Prototype : __mf_ug_list_play_unrealize
+** Description :
+** Input : void *data
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+static bool __mf_ug_list_play_unrealize(ugData *data)
+{
+
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+ ug_mf_retvm_if(ugd == NULL, false, "ugd is NULL");
+
+ if (ugd->ug_ListPlay.ug_Player != 0) {
+ /*/unrealize can be invoked at any state */
+ if (mm_player_unrealize(ugd->ug_ListPlay.ug_Player) != MM_ERROR_NONE) {
+ ug_debug("Error when __mf_ug_list_play_unrealize\n");
+ UG_TRACE_END;
+ return false;
+ } else {
+ UG_TRACE_END;
+ return true;
+ }
+ }
+ UG_TRACE_END;
+ return false;
+}
+
+/******************************
+** Prototype : __mf_ug_list_play_destory
+** Description :
+** Input : void *data
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+static bool __mf_ug_list_play_destory(ugData *data)
+{
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+ ug_mf_retvm_if(ugd == NULL, false, "ugd is NULL");
+
+ if (ugd->ug_ListPlay.ug_Player != 0) {
+ /*/destroy can be invoked at any state */
+ if (mm_player_destroy(ugd->ug_ListPlay.ug_Player) != MM_ERROR_NONE) {
+ ug_debug("Error when __mf_ug_list_play_destory\n");
+ UG_TRACE_END;
+ return false;
+ } else {
+ ugd->ug_ListPlay.ug_Player = 0;
+ ugd->ug_ListPlay.ug_iPlayState = PLAY_STATE_INIT;
+ UG_TRACE_END;
+ return true;
+ }
+ }
+ UG_TRACE_END;
+ return false;
+}
+
+/******************************
+** Prototype : __mf_ug_list_play_play_current_file
+** Description : Samsung
+** Input : ugData *data
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+static bool __mf_ug_list_play_play_current_file(ugData *data)
+{
+
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+ ug_mf_retvm_if(ugd == NULL, false, "ugd is NULL");
+
+ if (ugd->ug_ListPlay.ug_iPlayState != PLAY_STATE_READY) {
+ UG_TRACE_END;
+ return false;
+ }
+
+ if (!__mf_ug_list_play_play(ugd)) {
+ mf_ug_list_play_destory_playing_file(ugd);
+ UG_TRACE_END;
+ return false;
+ }
+ return true;
+}
+
+
+/******************************
+** Prototype : __mf_ug_list_play_resume
+** Description :
+** Input : ugListItemData *data
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+static bool __mf_ug_list_play_resume(void *data)
+{
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+ ug_mf_retvm_if(ugd == NULL, false, "ugd is NULL");
+
+ MMPlayerStateType state = MM_PLAYER_STATE_NONE;
+ int error_code = 0;
+ int err = -1;
+
+ if (ugd->ug_ListPlay.ug_Player != 0) {
+ error_code = mm_player_get_state(ugd->ug_ListPlay.ug_Player, &state);
+
+ if (0 == error_code && MM_PLAYER_STATE_PAUSED == state) {
+ err = mm_player_resume(ugd->ug_ListPlay.ug_Player);
+ if (err != MM_ERROR_NONE) {
+ ug_debug("Error when _ug_player_mgr_resume. err[%x]\n", err);
+ UG_TRACE_END;
+ return false;
+ } else {
+ UG_TRACE_END;
+ return true;
+ }
+ } else {
+ UG_TRACE_END;
+ return false;
+ }
+ }
+ UG_TRACE_END;
+ return false;
+
+}
+
+
+/******************************
+** Prototype : __mf_ug_list_play_pause
+** Description :
+** Input : ugListItemData *data
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+static bool __mf_ug_list_play_pause(void *data)
+{
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+ ug_mf_retvm_if(ugd == NULL, false, "ugd is NULL");
+
+ int err = MM_ERROR_NONE;
+ MMPlayerStateType state = MM_PLAYER_STATE_NONE;
+ int error_code = 0;
+
+ if (ugd->ug_ListPlay.ug_Player) {
+ error_code = mm_player_get_state(ugd->ug_ListPlay.ug_Player, &state);
+
+ if (0 == error_code && MM_PLAYER_STATE_PLAYING == state) {
+ err = mm_player_pause(ugd->ug_ListPlay.ug_Player);
+ if (err != MM_ERROR_NONE) {
+ ug_debug("Error when _ug_player_mgr_pause. err[%x]\n", err);
+ UG_TRACE_END;
+ return false;
+ } else {
+ UG_TRACE_END;
+ return true;
+ }
+ } else {
+ UG_TRACE_END;
+ return false;
+ }
+ }
+ UG_TRACE_END;
+ return false;
+}
+
+
+/******************************
+** Prototype : mp_play_control_cb
+** Description :
+** Input : ugListItemData *data
+** int state
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+static void __mf_ug_list_play_control_cb(void *data)
+{
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+
+ ug_mf_retm_if(ugd == NULL, "ugd is NULL");
+
+ int state = ugd->ug_ListPlay.ug_iPlayState;
+
+ if (state == PLAY_STATE_PLAYING) {
+ __mf_ug_list_play_pause(ugd);
+ } else {
+ __mf_ug_list_play_resume(ugd);
+
+ }
+ UG_TRACE_END;
+}
+
+static bool __mf_ug_list_play_play_new_file(ugListItemData *data)
+{
+ UG_TRACE_BEGIN;
+ ugListItemData *itemData = data;
+ ug_mf_retvm_if(itemData == NULL, false, "itemData is NULL");
+
+ ugData *ugd = (ugData *)itemData->ug_pData;
+ ug_mf_retvm_if(ugd == NULL, false, "ugd is NULL");
+
+ __mf_ug_list_play_init_data(ugd);
+
+ if (!__mf_ug_list_play_ready_new_file_play(itemData)) {
+ UG_TRACE_END;
+ return false;
+ }
+
+ if (!__mf_ug_list_play_play_current_file(ugd)) {
+ UG_TRACE_END;
+ return false;
+ }
+ UG_TRACE_END;
+
+ return true;
+}
+
+
+/******************************
+** Prototype : _music_item_play
+** Description :
+** Input : ugListItemData *param
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+void mf_ug_list_play_play_music_item(ugListItemData *data)
+{
+ UG_TRACE_BEGIN;
+ ugListItemData *itemData = data;
+ ug_mf_retm_if(itemData == NULL, "itemData is NULL");
+ ugData *ugd = itemData->ug_pData;
+ ug_mf_retm_if(ugd == NULL, "ugd is NULL");
+
+ int key = 0;
+ int error_code = 0;
+ error_code = vconf_get_int(VCONFKEY_SYSMAN_BATTERY_STATUS_LOW, &key);
+ ug_debug("key is [%d]", key);
+ if (error_code == 0 && key <= VCONFKEY_SYSMAN_BAT_POWER_OFF) {
+ mf_ug_popup_create(ugd, UG_POPMODE_TEXT, NULL, ("Battery low, play failed!"), NULL, NULL, NULL, NULL, NULL);
+ } else if (error_code != 0) {
+ mf_ug_popup_create(ugd, UG_POPMODE_TEXT, NULL, ("Unkown error, play failed!"), NULL, NULL, NULL, NULL, NULL);
+ } else {
+ if (ugd->ug_ListPlay.ug_pPlayFilePath != NULL) {
+ if (g_strcmp0(ugd->ug_ListPlay.ug_pPlayFilePath, itemData->ug_pItemName->str) != 0) {
+ mf_ug_list_play_destory_playing_file(ugd);
+ __mf_ug_list_play_play_new_file(itemData);
+ } else {
+ /*/ playing the same file */
+ __mf_ug_list_play_control_cb(ugd);
+ }
+ } else {
+ __mf_ug_list_play_play_new_file(itemData);
+ }
+ }
+ UG_TRACE_END;
+
+}
+
+/******************************
+** Prototype : mf_ug_list_play_destory_playing_file
+** Description :
+** Input : ugListItemData *data
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+void mf_ug_list_play_destory_playing_file(void *data)
+{
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+ ug_mf_retm_if(ugd == NULL, "ugd is NULL");
+
+ __mf_ug_list_play_stop(ugd);
+ __mf_ug_list_play_unrealize(ugd);
+ __mf_ug_list_play_destory(ugd);
+ UG_TRACE_END;
+}
diff --git a/src/common/mf-ug-util.c b/src/common/mf-ug-util.c
new file mode 100755
index 0000000..e934f33
--- /dev/null
+++ b/src/common/mf-ug-util.c
@@ -0,0 +1,729 @@
+/*
+ * Copyright 2012 Samsung Electronics Co., Ltd
+ *
+ * Licensed under the Flora License, Version 1.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.tizenopensource.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 <pthread.h>
+#include <vconf.h>
+
+#include "mf-ug-util.h"
+#include "mf-ug-winset.h"
+#include "mf-ug-fm-svc-wrapper.h"
+#include "mf-ug-fs-util.h"
+#include "mf-ug-inotify-handle.h"
+#include "mf-ug-resource.h"
+
+/******************************
+** Prototype : ug_genlist_selected_state_get
+** Description :
+** Input : void *data
+** Output : bool
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+bool mf_ug_util_is_genlist_selected(void *data)
+{
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+ ug_mf_retvm_if(ugd == NULL, false, "ugd is NULL");
+
+ Elm_Object_Item *gli = NULL;
+ Elm_Object_Item *nli = NULL;
+ Evas_Object *genlist = NULL;
+
+ ugNaviBar *pNavi_s = mf_ug_navi_bar_get_in_use_navi(ugd);
+ ug_mf_retvm_if(pNavi_s == NULL, false, "get navigation bar in use failed");
+
+ genlist = pNavi_s->ug_pContent;
+ gli = elm_genlist_first_item_get(genlist);
+
+ while (gli) {
+ ugListItemData *itemData = (ugListItemData *)elm_object_item_data_get(gli);
+ ug_mf_retvm_if(itemData == NULL, false, "itemData is NULL");
+ if (itemData->ug_bChecked == true) {
+ UG_TRACE_END;
+ return true;
+ }
+ nli = elm_genlist_item_next_get(gli);
+ gli = nli;
+ }
+ UG_TRACE_END;
+ return false;
+}
+
+/******************************
+** Prototype : ug_parase_path_get
+** Description :
+** Input : GList *dest_list
+** char *path_list
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+void mf_ug_util_get_params_path(Eina_List **dest_list, const char *path_list)
+{
+ UG_TRACE_BEGIN;
+ ug_mf_retm_if(dest_list == NULL, "dest_list is NULL");
+
+ gchar **result = NULL;
+ gchar **params = NULL;
+ result = g_strsplit(path_list, "?", 0);
+
+ for (params = result; *params; params++) {
+ *dest_list = eina_list_append(*dest_list, strdup(*params));
+ }
+
+ g_strfreev(result);
+ UG_TRACE_END;
+}
+
+/******************************
+** Prototype : mf_ug_util_free_eina_list_data
+** Description : Samsung
+** Input : Eina_List **list
+** mf_ug_eina_list_node_type node_type
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+void mf_ug_util_free_eina_list_data(Eina_List **list, mf_ug_eina_list_node_type node_type)
+{
+ UG_TRACE_BEGIN;
+ ug_mf_retm_if(list == NULL, "list is NULL");
+ ug_mf_retm_if(*list == NULL, "*list is NULL");
+
+ Eina_List *l = NULL;
+ void *pNode = NULL;
+ switch (node_type) {
+ case NODE_TYPE_CHAR:
+ case NODE_TYPE_PNODE:
+ EINA_LIST_FOREACH(*list, l, pNode) {
+ free(pNode);
+ pNode = NULL;
+ }
+ break;
+ case NODE_TYPE_GSTRING:
+ EINA_LIST_FOREACH(*list, l, pNode) {
+ if (pNode != NULL) {
+ g_string_free(pNode, TRUE);
+ pNode = NULL;
+ }
+ }
+ break;
+ default:
+ break;
+ }
+
+ eina_list_free(*list);
+ *list = NULL;
+ UG_TRACE_END;
+}
+
+/******************************
+** Prototype : mf_ug_util_is_mass_storage_on
+** Description : Samsung
+** Input : None
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+bool mf_ug_util_is_mass_storage_on()
+{
+ UG_TRACE_BEGIN;
+ int usb_state = 0;
+ int error_code = vconf_get_int(VCONFKEY_USB_STORAGE_STATUS, &usb_state);
+ ug_debug("usb state is %d", usb_state);
+ ug_debug("error_code is %d", error_code);
+ if (error_code == 0) {
+ if (usb_state != VCONFKEY_USB_STORAGE_STATUS_UMS_ON && usb_state != VCONFKEY_USB_STORAGE_STATUS_UMS_MMC_ON) {
+ UG_TRACE_END;
+ return false;
+ } else {
+ UG_TRACE_END;
+ return true;
+ }
+ } else {
+ UG_TRACE_END;
+ return false;
+ }
+}
+
+
+/******************************
+** Prototype : __mf_ug_util_get_marked_selected_items
+** Description :
+** Input : GList *list
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+static void __mf_ug_util_get_marked_selected_items(Eina_List *list, Eina_List **select_list)
+{
+ UG_TRACE_BEGIN;
+ ug_mf_retm_if(select_list == NULL, "select_list is NULL");
+ ug_mf_retm_if(list == NULL, "list is NULL");
+
+ Eina_List *l = NULL;
+ void *pNode = NULL;
+
+ EINA_LIST_FOREACH(list, l, pNode) {
+ if (pNode != NULL) {
+ *select_list = eina_list_append(*select_list, strdup(pNode));
+ }
+ }
+ UG_TRACE_END;
+
+}
+
+/******************************
+** Prototype : __mf_ug_util_get_marked_off_selected_items
+** Description :
+** Input : void *data
+** Evas_Object* content
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+static void __mf_ug_util_get_marked_off_selected_items(void *data, Eina_List **select_list)
+{
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+ ug_mf_retm_if(ugd == NULL, "ugData is NULL");
+ ug_mf_retm_if(select_list == NULL, "selected_list is NULL");
+
+
+ ugNaviBar *pNavi_s = mf_ug_navi_bar_get_in_use_navi(ugd);
+ Evas_Object *content = pNavi_s->ug_pContent;
+ Elm_Object_Item *gli = elm_genlist_first_item_get(content);
+ int radio_id = 1;
+ Elm_Object_Item *nli = NULL;
+
+
+ while (gli) {
+
+ ugListItemData *params = (ugListItemData *)elm_object_item_data_get(gli);
+ ug_mf_retm_if(params == NULL, "params is NULL");
+ if (ugd->ug_UiGadget.ug_iSelectMode == SINGLE_ALL_MODE || ugd->ug_UiGadget.ug_iSelectMode == SINGLE_FILE_MODE) {
+ if (params->ug_pRadioBox) {
+ if (elm_radio_value_get(ugd->ug_MainWindow.ug_pRadioGroup) == radio_id) {
+ *select_list = eina_list_append(*select_list, strdup(params->ug_pItemName->str));
+ break;
+ }
+ radio_id++;
+ }
+ } else if (ugd->ug_UiGadget.ug_iSelectMode == MULTI_ALL_MODE || ugd->ug_UiGadget.ug_iSelectMode == MULTI_FILE_MODE) {
+ if (params->ug_pCheckBox) {
+ if (params->ug_bChecked == true) {
+ *select_list = eina_list_append(*select_list, strdup(params->ug_pItemName->str));
+ }
+ }
+ }
+ nli = elm_genlist_item_next_get(gli);
+ gli = nli;
+ }
+ UG_TRACE_END;
+}
+
+/******************************
+** Prototype : mf_ug_util_get_send_result
+** Description :
+** Input : void *data
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+char *mf_ug_util_get_send_result(void *data)
+{
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+ ug_mf_retvm_if(ugd == NULL, NULL, "ugData is NULL");
+
+ char *file_selected = NULL;
+ Eina_List *selected_list = NULL;
+ Eina_List *l = NULL;
+ char *pNode = NULL;
+
+ if (ugd->ug_UiGadget.ug_iMarkedMode == MARKED_ON
+ && (ugd->ug_UiGadget.ug_iSelectMode == MULTI_FILE_MODE || ugd->ug_UiGadget.ug_iSelectMode == MULTI_ALL_MODE)) {
+ __mf_ug_util_get_marked_selected_items(ugd->ug_UiGadget.ug_pMultiSelectFileList, &selected_list);
+ } else {
+ __mf_ug_util_get_marked_off_selected_items(ugd, &selected_list);
+ }
+
+ EINA_LIST_FOREACH(selected_list, l, pNode) {
+ if (pNode != NULL) {
+ if (file_selected == NULL) {
+ file_selected = g_strconcat(pNode, NULL);
+ } else {
+ char *temp = file_selected;
+ file_selected = g_strconcat(file_selected, "?", pNode, NULL);
+ free(temp);
+ }
+ }
+ }
+ mf_ug_util_free_eina_list_data(&selected_list, NODE_TYPE_CHAR);
+ UG_TRACE_END;
+ return file_selected;
+}
+
+
+/******************************
+** Prototype : _ug_mf_set_state_as
+** Description :
+** Input : struct ugmyfiledata* data
+** int state
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+void mf_ug_util_set_current_state(void *data, int state)
+{
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+ ug_mf_retm_if(ugd == NULL, "ugd is NULL");
+
+ ugd->ug_Status.ug_iState = state;
+ UG_TRACE_END;
+}
+
+
+/******************************
+** Prototype : mf_ug_util_get_mmc_state
+** Description :
+** Input : int* mmc_card
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+int mf_ug_util_get_mmc_state(int *mmc_card)
+{
+ UG_TRACE_BEGIN;
+ int data = UG_ERROR_RETURN;
+ int error_code = MYFILE_ERR_NONE;
+
+ ug_mf_retvm_if(mmc_card == NULL, MYFILE_ERR_SRC_ARG_INVALID, "mmc_card is NULL");
+
+ *mmc_card = 0;
+ error_code = vconf_get_int(VCONFKEY_SYSMAN_MMC_STATUS, &data);
+
+ if (error_code) {
+ UG_TRACE_END;
+ return MYFILE_ERR_GET_VCONF_FAIL;
+ }
+
+ if (data != VCONFKEY_SYSMAN_MMC_MOUNTED) {
+ *mmc_card = MMC_OFF;
+ } else {
+ *mmc_card = MMC_ON;
+ }
+ UG_TRACE_END;
+ return error_code;
+}
+
+/******************************
+** Prototype : mf_ug_util_create_dir_monitor
+** Description : Samsung
+** Input : void *data
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+int mf_ug_util_create_dir_monitor(void *data)
+{
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+ ug_mf_retvm_if(ugd == NULL, UG_ERROR_RETURN, "ugData is NULL");
+
+ if (ugd->ug_UiGadget.ug_pInotifyPipe) {
+ ecore_pipe_del(ugd->ug_UiGadget.ug_pInotifyPipe);
+ ugd->ug_UiGadget.ug_pInotifyPipe = NULL;
+ }
+ ugd->ug_UiGadget.ug_pInotifyPipe = ecore_pipe_add(mf_ug_cb_dir_pipe_cb, (const void *)ugd);
+ UG_TRACE_END;
+
+ return mf_ug_inotify_handle_init_inotify();
+}
+
+
+/******************************
+** Prototype : mf_ug_util_add_dir_watch
+** Description : Samsung
+** Input : const char *path
+** void *data
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+int mf_ug_util_add_dir_watch(const char *path, void *data)
+{
+ return mf_ug_inotify_handle_add_inotify_watch(path, mf_ug_cb_dir_update_cb, data);
+}
+
+
+/******************************
+** Prototype : mf_ug_util_set_mmc_state_cb
+** Description : Samsung
+** Input : void *data
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+int mf_ug_util_set_mmc_state_cb(void *data)
+{
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+ ug_mf_retvm_if(ugd == NULL, UG_ERROR_RETURN, "ugd is NULL");
+
+ int mmc_state = MMC_OFF;
+ mf_ug_util_get_mmc_state(&mmc_state);
+ ugd->ug_Status.ug_iMmcFlag = mmc_state;
+
+ UG_TRACE_END;
+ return vconf_notify_key_changed(VCONFKEY_SYSMAN_MMC_STATUS, mf_ug_cb_mmc_changed_cb, ugd);
+}
+
+/******************************
+** Prototype : mf_ug_util_destory_mmc_state_cb
+** Description : Samsung
+** Input : None
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+void mf_ug_util_destory_mmc_state_cb()
+{
+ UG_TRACE_BEGIN;
+ vconf_ignore_key_changed(VCONFKEY_SYSMAN_MMC_STATUS, mf_ug_cb_mmc_changed_cb);
+ UG_TRACE_END;
+}
+
+void mf_ug_util_destory_mass_storage_callback()
+{
+ UG_TRACE_BEGIN;
+ vconf_ignore_key_changed(VCONFKEY_USB_STORAGE_STATUS, mf_ug_cb_mass_storage_changed_cb);
+ UG_TRACE_END;
+}
+
+/******************************
+** Prototype : mf_ug_util_destory_dir_monitor
+** Description : Samsung
+** Input : void *data
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+void mf_ug_util_destory_dir_monitor(void *data)
+{
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+ ug_mf_retm_if(ugd == NULL, "ugd is NULL");
+
+ if (ugd->ug_UiGadget.ug_pInotifyPipe) {
+ ecore_pipe_del(ugd->ug_UiGadget.ug_pInotifyPipe);
+ ugd->ug_UiGadget.ug_pInotifyPipe = NULL;
+ }
+
+ mf_ug_inotify_handle_finalize_inotify();
+ UG_TRACE_END;
+
+ return;
+}
+
+
+/******************************
+** Prototype : mf_ug_util_storage_insert_action
+** Description : Samsung
+** Input : void *data
+** char* pItemLabel
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+void mf_ug_util_storage_insert_action(void *data, char *pItemLabel)
+{
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+ ug_mf_retm_if(ugd == NULL, "ugd is NULL");
+
+ Elm_Object_Item *pItemPhone = NULL;
+ Elm_Object_Item *pItemMMC = NULL;
+ Evas_Object *pTabBar = NULL;
+ Evas_Object *pOldContent = NULL;
+
+ if (ugd->ug_MainWindow.ug_pTabBar == NULL) {
+ /*1. unset the current content of main layout */
+ pOldContent = elm_object_part_content_unset(ugd->ug_MainWindow.ug_pMainLayout, "elm.swallow.content");
+ /*2. create Tab Bar */
+ if (ugd->ug_MainWindow.ug_pTabLayout == NULL) {
+ ugd->ug_MainWindow.ug_pTabLayout = mf_ug_main_tab_layout_create(ugd->ug_MainWindow.ug_pWindow);
+ }
+ pTabBar = mf_ug_tab_bar_create(ugd->ug_MainWindow.ug_pWindow);
+ ugd->ug_MainWindow.ug_pTabBar = pTabBar;
+ elm_object_part_content_set(ugd->ug_MainWindow.ug_pTabLayout, "elm.swallow.content", pOldContent);
+ elm_object_part_content_set(ugd->ug_MainWindow.ug_pTabLayout, "elm.swallow.tabbar", ugd->ug_MainWindow.ug_pTabBar);
+ elm_object_part_content_set(ugd->ug_MainWindow.ug_pMainLayout, "elm.swallow.content", ugd->ug_MainWindow.ug_pTabLayout);
+ evas_object_show(ugd->ug_MainWindow.ug_pTabLayout);
+ /*3. set Navi Bars of phone and mmc as sub view of Tab Bar */
+ pItemPhone = mf_ug_tab_bar_append_item(pTabBar, UG_ICON_PHONE, MF_UG_LABEL_PHONE, ugd);
+ pItemMMC = mf_ug_tab_bar_append_item(pTabBar, UG_ICON_MEMORY, MF_UG_LABEL_MMC, ugd);
+ /*4. set selected */
+ //mf_ug_tab_bar_set_selected_item(pItemPhone);
+
+ } else {
+ pItemMMC = mf_ug_tab_bar_append_item(pTabBar, UG_ICON_MEMORY, MF_UG_LABEL_MMC, ugd);
+ }
+
+ if (ugd->ug_Status.ug_bMassStorageFlag) {
+ mf_ug_tab_bar_set_item_disable(ugd->ug_MainWindow.ug_pTabBar, EINA_TRUE);
+ }
+ UG_TRACE_END;
+}
+
+
+/******************************
+** Prototype : mf_ug_util_set_main_layout_by_tab_item_count
+** Description : __mf_ug_main_free_evas_object
+** Input : void *data
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+int mf_ug_util_set_main_layout_by_tab_item_count(void *data)
+{
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+ ug_mf_retvm_if(ugd == NULL, 0, "ugd is NULL");
+
+ Evas_Object *pOldContent = NULL;
+ pOldContent = ugd->ug_MainWindow.ug_pTabBar;
+ if (eina_list_count(ugd->ug_MainWindow.ug_pNaviBarList) < 2) {
+ /*no: tab bar delete operation */
+ elm_object_part_content_unset(ugd->ug_MainWindow.ug_pTabLayout, "elm.swallow.tabbar");
+ evas_object_del(pOldContent);
+ elm_object_part_content_unset(ugd->ug_MainWindow.ug_pTabLayout, "elm.swallow.content");
+
+ elm_object_part_content_unset(ugd->ug_MainWindow.ug_pMainLayout, "elm.swallow.content");
+ UG_SAFE_FREE_OBJ(ugd->ug_MainWindow.ug_pTabLayout);
+ ugd->ug_MainWindow.ug_pTabBar = NULL;
+ UG_TRACE_END;
+ return 0;
+ } else {
+ /*yes: do nothing */
+ //elm_toolbar_item_selected_set(elm_toolbar_first_item_get(ugd->ug_MainWindow.ug_pTabBar), EINA_TRUE);
+ UG_TRACE_END;
+ return 1;
+ }
+}
+
+/******************************
+** Prototype : mf_ug_util_get_file_launch_type
+** Description :
+** Input : char * path
+** Output : UG_MYFILE_LAUNCH_TYPE
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+mf_ug_launch_type mf_ug_util_get_file_launch_type(char *path)
+{
+ if (path == NULL) {
+ UG_TRACE_END;
+ return LAUNCH_TYPE_UNSUPPORT;
+ }
+ if (ecore_file_file_get(path) == NULL) {
+ UG_TRACE_END;
+ return LAUNCH_TYPE_UNSUPPORT;
+ }
+ if (ecore_file_is_dir(path) == 1) {
+ UG_TRACE_END;
+ return LAUNCH_TYPE_UNSUPPORT;
+ }
+
+ mf_ug_fs_file_type category_t = 0;
+ mf_ug_file_attr_get_file_category(path, &category_t);
+ if (category_t == UG_FILE_TYPE_MUSIC || category_t == UG_FILE_TYPE_SOUND || category_t == UG_FILE_TYPE_VOICE) {
+ UG_TRACE_END;
+ return LAUNCH_TYPE_MUSIC;
+ } else if (category_t == UG_FILE_TYPE_IMAGE) {
+ UG_TRACE_END;
+ return LAUNCH_TYPE_IMAGE;
+ } else {
+ UG_TRACE_END;
+ return LAUNCH_TYPE_UNSUPPORT;
+ }
+
+ UG_TRACE_END;
+}
+
+
+char *mf_ug_util_upper_folder_name_get(void *data, GString *fullpath)
+{
+ ug_mf_retvm_if(data == NULL, NULL, "data is NULL");
+ ug_mf_retvm_if(fullpath == NULL, NULL, "fullpath is NULL");
+ ug_mf_retvm_if(fullpath->str == NULL, NULL, "fullpath is NULL");
+
+ GString *parent_path = NULL;
+ GString *gName = NULL;
+ char *upper_name = NULL;
+
+ parent_path = mf_ug_fm_svc_wrapper_get_file_parent_path(fullpath);
+
+ ug_mf_retvm_if(parent_path == NULL, NULL, "fullpath is NULL");
+ ug_mf_retvm_if(parent_path->str == NULL, NULL, "fullpath is NULL");
+
+
+ if (!g_strcmp0(parent_path->str, PHONE_FOLDER)) {
+ upper_name = g_strdup(MF_UG_LABEL_PHONE);
+ } else if (!g_strcmp0(parent_path->str, MEMORY_FOLDER)) {
+ upper_name = g_strdup(MF_UG_LABEL_MMC);
+ } else {
+ gName = mf_ug_fm_svc_wapper_get_file_name(parent_path);
+ UG_GSTRING_CHECK_NULL_GOTO(gName, FAILED_EXIT);
+ upper_name = g_strdup(gName->str);
+ }
+
+ UG_CHAR_CHECK_NULL_GOTO(upper_name, FAILED_EXIT);
+ UG_SAFE_FREE_GSTRING(parent_path);
+ UG_SAFE_FREE_GSTRING(gName);
+ return upper_name;
+
+FAILED_EXIT:
+ UG_SAFE_FREE_GSTRING(parent_path);
+ UG_SAFE_FREE_GSTRING(gName);
+ return NULL;
+
+}
+
diff --git a/src/include/mf-ug-cb.h b/src/include/mf-ug-cb.h
new file mode 100755
index 0000000..f0bf01f
--- /dev/null
+++ b/src/include/mf-ug-cb.h
@@ -0,0 +1,50 @@
+/*
+ * Copyright 2012 Samsung Electronics Co., Ltd
+ *
+ * Licensed under the Flora License, Version 1.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.tizenopensource.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 __DEF_MF_UG_CB_H_
+#define __DEF_MF_UG_CB_H_
+
+#include <Elementary.h>
+#include <vconf.h>
+#include "mf-ug-main.h"
+#include "mf-ug-util.h"
+#include "mf-ug-inotify-handle.h"
+
+void mf_ug_cb_back_button_cb(void *data, Evas_Object *obj, void *event_info);
+void mf_ug_cb_add_button_cb(void *data, Evas_Object *obj, void *event_info);
+void mf_ug_cb_goto_myfile_button_cb(void *data, Evas_Object *obj, void *event_info);
+void mf_ug_cb_mass_storage_popup_cb(void *data);
+void mf_ug_cb_tab_bar_cb(void *data, Evas_Object *obj, void *event_info);
+void mf_ug_cb_ctrl_bar_button_cb(void *data, Evas_Object *obj, void *event_info);
+void mf_ug_cb_list_play_cb(ugListItemData *data, Evas_Object *obj, void *event_info);
+void mf_ug_cb_select_info_show_cb(void *data, Evas *e, Evas_Object *obj, void *event_info);
+void mf_ug_cb_select_info_hide_cb(void *data, Evas *e, Evas_Object *obj, void *event_info);
+void mf_ug_cb_select_info_timeout_cb(void *data, Evas_Object *obj, void *event_info);
+void mf_ug_cb_mmc_changed_cb(keynode_t *key, void *data);
+void mf_ug_cb_dir_update_cb(mf_ug_inotify_event event, char *name, void *data);
+void mf_ug_cb_dir_pipe_cb(void *data, void *buffer, unsigned int nbyte);
+Eina_Bool mf_ug_cb_thumb_timer_cb(void *data);
+int mf_ug_cb_set_mass_storage_state_cb(void *data);
+void mf_ug_cb_mass_storage_changed_cb(keynode_t *key, void *data);
+void mf_ug_cb_upper_click_cb(void *data, Evas_Object * obj, void *event_info);
+void mf_ug_cb_home_button_cb(void *data, Evas_Object * obj, void *event_info);
+
+#endif
diff --git a/src/include/mf-ug-conf.h b/src/include/mf-ug-conf.h
new file mode 100755
index 0000000..af5b8a2
--- /dev/null
+++ b/src/include/mf-ug-conf.h
@@ -0,0 +1,79 @@
+/*
+ * Copyright 2012 Samsung Electronics Co., Ltd
+ *
+ * Licensed under the Flora License, Version 1.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.tizenopensource.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 __DEF_MF_UG_CONF_H_
+#define __DEF_MF_UG_CONF_H_
+
+#include <Elementary.h>
+
+#define UGPACKAGE "ug-myfile-efl"
+#define UGLOCALEDIR "/opt/ug/res/locale"
+
+#define UG_EDJ_PATH "/opt/ug/res/edje/ug-myfile-efl"
+#define UG_ICON_PATH "/opt/ug/res/images/ug-myfile-efl"
+
+#define UG_EDJ_NAVIGATIONBAR UG_EDJ_PATH"/ug_navibar_layout.edj"
+
+
+#define UG_GRP_LIST "effect/model/list"
+#define UG_GRP_NAVI_VIEW "navigation_view"
+#define UG_GRP_GOTO_MYFILE "goto_myfile"
+#define UG_GRP_NO_CONTENT "noContent"
+#define UG_GRP_UPPER_LAYOUT "upper_folder"
+#define UG_GRP_PATH_INFO "pathinfo"
+#define UG_OPTION_COUNT 5
+#define UG_ERROR_RETURN (-1)
+
+#define UG_SELECT_MODE_MULTI_ALL "MULTI_ALL"
+#define UG_SELECT_MODE_SINGLE_ALL "SINGLE_ALL"
+#define UG_SELECT_MODE_MULTI_FILE "MULTI_FILE"
+#define UG_SELECT_MODE_SINGLE_FILE "SINGLE_FILE"
+
+#define UG_FILE_FILTER_IMAGE "IMAGE"
+#define UG_FILE_FILTER_SOUND "SOUND"
+#define UG_FILE_FILTER_VIDEO "VIDEO"
+#define UG_FILE_FILTER_FLASH "FLASH"
+#define UG_FILE_FILTER_FOLDER "FOLDER"
+#define UG_FILE_FILTER_IV "IV"
+#define UG_FILE_FILTER_IS "IS"
+#define UG_FILE_FILTER_VS "VS"
+#define UG_FILE_FILTER_ALL "ALL"
+
+#define UG_MUSIC_PATH "/opt/media/Sounds and music/Music"
+#define UG_RINGTION_PATH "/opt/media/Sounds and music/Ringtones"
+#define UG_SETTING_RINGTONE_PATH "/opt/share/settings/Ringtones"
+#define UG_SETTING_ALERTS_PATH "/opt/share/settings/Alerts"
+
+#define MAX_MESSAGE_LEN 1024
+#define ACCUMULATED_DATE 86400 /* 24*60*60 */
+
+#define UG_LABEL_STRING_LENGTH 128
+
+#define UG_TIME_FORMAT "02u:%02u:%02u"
+#define UG_TIME_ARGS(t) \
+ (t) / (3600), \
+ ((t) / 60) % 60, \
+ (t) % 60
+
+#define _EDJ(o) elm_layout_edje_get(o)
+
+#define INTERVAL_THUMB_UPDATE 0.5
+
+#endif /* __DEF_MYFILE_CONF_H_ */
diff --git a/src/include/mf-ug-dlog.h b/src/include/mf-ug-dlog.h
new file mode 100755
index 0000000..dd32beb
--- /dev/null
+++ b/src/include/mf-ug-dlog.h
@@ -0,0 +1,84 @@
+/*
+ * Copyright 2012 Samsung Electronics Co., Ltd
+ *
+ * Licensed under the Flora License, Version 1.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.tizenopensource.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 __DEF_MF_UG_DLOG_H_
+#define __DEF_MF_UG_DLOG_H_
+
+#include <stdio.h>
+#include <string.h>
+
+#define DLOG_ON 1
+
+#ifdef LOG_TAG
+#undef LOG_TAG
+#endif
+
+#define LOG_TAG "MYFILE-UG"
+#include <dlog.h>
+
+
+#if DLOG_ON
+#define ug_debug(fmt , args...) LOGD("[%s][%d]debug message from ug-myfile-efl is : "fmt"\n", __func__, __LINE__, ##args)
+#define ug_myfile_dlog(fmt , args...) LOGD("[%s][%d]debug message from myfile is : "fmt"\n", __func__, __LINE__, ##args)
+#define UG_TRACE_BEGIN do {\
+ {\
+ LOGD("\n\033[0;35mENTER FUNCTION: %s. \033[0m\t%s:%d\n", \
+ __FUNCTION__, (char *)(strrchr(__FILE__, '/') + 1), __LINE__);\
+ } \
+ } while (0);
+
+#define UG_TRACE_END do {\
+ {\
+ LOGD("\n\033[0;35mEXIT FUNCTION: %s. \033[0m\t%s:%d\n", \
+ __FUNCTION__, (char *)(strrchr(__FILE__, '/') + 1), __LINE__);\
+ } \
+ } while (0);
+
+#else
+#define ug_myfile_dlog(fmt , args...) printf("[MYFILE][%40s:%4d] "fmt"\n", __func__, __LINE__, ##args)
+#endif
+#define ug_mf_debug(fmt , args...) do { (void)0; } while (0)
+#define ug_mf_warnig(fmt , args...) do { (void)0; } while (0)
+#define ug_mf_error(fmt , args...) do { (void)0; } while (0)
+#define UG_MYFILE_TRACE_ERROR(fmt, arg...) do { LOGE("[%s][%d] "fmt"\n", strrchr(__FILE__, '/') + 1, __LINE__, ##arg); } while (0)
+
+#define ug_mf_retvm_if(expr, val, fmt, arg...) do { \
+ if (expr) { \
+ UG_MYFILE_TRACE_ERROR(fmt, ##arg); \
+ return (val); \
+ } \
+ } while (0)
+
+#define ug_mf_retv_if(expr, val) do { \
+ if (expr) { \
+ return (val); \
+ } \
+ } while (0)
+
+
+#define ug_mf_retm_if(expr, fmt, arg...) do { \
+ if (expr) { \
+ UG_MYFILE_TRACE_ERROR(fmt, ##arg); \
+ return; \
+ } \
+ } while (0)
+
+
+#endif
diff --git a/src/include/mf-ug-fm-svc-wrapper.h b/src/include/mf-ug-fm-svc-wrapper.h
new file mode 100755
index 0000000..f971e33
--- /dev/null
+++ b/src/include/mf-ug-fm-svc-wrapper.h
@@ -0,0 +1,41 @@
+/*
+ * Copyright 2012 Samsung Electronics Co., Ltd
+ *
+ * Licensed under the Flora License, Version 1.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.tizenopensource.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 __DEF_MF_UG_FM_SVC_WRAPPER_H_
+#define __DEF_MF_UG_FM_SVC_WRAPPER_H_
+
+#include <glib.h>
+#include "mf-ug-main.h"
+
+#define MF_UG_PATH_INFO_MAX_LENGTH_PORTRAIT 35
+
+
+/* file information get/set */
+unsigned long mf_ug_fm_svc_wapper_get_file_filter(int file_filter_mode);
+int mf_ug_fm_svc_wapper_get_file_list_by_filter(ugData *data, GString *fullpath, Eina_List **dir_list, Eina_List **filter_list);
+bool mf_ug_fm_svc_wapper_is_root_path(void *data);
+GString *mf_ug_fm_svc_wapper_get_file_name(GString *path);
+char *mf_ug_fm_svc_wapper_get_root_path_by_tab_label(const char *label);
+int mf_ug_fm_svc_wapper_get_location(char *fullpath);
+gint mf_ug_fm_svc_wapper_get_folder_foldersystem(GString *path, bool *result);
+GString *mf_ug_fm_svc_wrapper_get_file_parent_path(GString *fullpath);
+char *mf_ug_fm_svc_wapper_path_info_get(char *original_path);
+char *mf_ug_fm_svc_path_info_translate(char *path_info, int path_info_max_len);
+
+#endif
diff --git a/src/include/mf-ug-fs-util.h b/src/include/mf-ug-fs-util.h
new file mode 100755
index 0000000..1e3e08f
--- /dev/null
+++ b/src/include/mf-ug-fs-util.h
@@ -0,0 +1,257 @@
+/*
+ * Copyright 2012 Samsung Electronics Co., Ltd
+ *
+ * Licensed under the Flora License, Version 1.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.tizenopensource.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 __DEF_MF_UG_FS_UTIL_H_
+#define __DEF_MF_UG_FS_UTIL_H_
+
+#include <stdio.h>
+#include <stdbool.h>
+#include <string.h>
+#include <stdlib.h>
+#include <dirent.h>
+#include <sys/stat.h>
+#include <unistd.h>
+#include <sys/types.h>
+#include <sys/stat.h>
+#include <linux/fs.h>
+#include <Eina.h>
+
+#include <Elementary.h>
+#include <visual-svc.h>
+#include <media-svc.h>
+
+#include "mf-ug-dlog.h"
+
+
+/* File system related value definition */
+#define FILE_EXT_LEN_MAX 8
+#define MYFILE_DIR_PATH_LEN_MAX 4096
+#define MYFILE_FILE_NAME_LEN_MAX 256
+#define MYFILE_FILE_PATH_LEN_MAX MYFILE_DIR_PATH_LEN_MAX + MYFILE_FILE_NAME_LEN_MAX
+
+
+/* File system related String definition */
+#define PHONE_FOLDER "/opt/media"
+#define MEMORY_FOLDER "/opt/storage/sdcard"
+#define DEBUG_FOLDER "SLP_debug"
+
+#define MYFILE_NAME_PATTERN "[\\:;*\"<>|?/]"
+
+#define IMAGE_AND_VIDEO "Images and videos"
+#define SOUND_AND_MUSIC "Sounds and music"
+#define DOWNLOADS "Downloads"
+#define CAMERA_SHOTS "Camera shots"
+
+
+#define WALLPAPER "Wallpapers"
+#define MY_PHOTO_CLIPS "My photo clips"
+#define MY_ALBUM "My album" /*/_("IDS_MF_BODY_ACCESS_MORE_MY_ALBUM") */
+#define MY_VIDEO_CLIPS "My video clips" /*/_("IDS_MF_BODY_MY_VIDEO_CLIPS") */
+
+#define FM_RADIO "FM Radio" /*/dgettext("sys_string", "IDS_COM_HEADER_FMRADIO") */
+#define MUSIC "Music" /*/_("IDS_MF_BODY_MUSIC") */
+#define RINGTONES "Ringtones"
+#define VOICE_RECORDER "Voice recorder" /*/dgettext("sys_string", "IDS_COM_BODY_VOICE_RECORDER") */
+#define ALERTS "Alerts"
+#define OTHERS "Others" /*/dgettext("sys_string","IDS_COM_BODY_OTHERS") */
+
+/* File system define default folder */
+
+/* compile option */
+#define UG_DEBUG_FOLDER_OPTION
+
+#ifndef UG_ICON_PATH
+#define UG_ICON_PATH "/opt/ug/res/images/ug-myfile-efl"
+#endif
+
+#ifndef UG_DEFAULT_ICON
+#define UG_DEFAULT_ICON UG_ICON_PATH"/60_myfiles_file_etc.png"
+#endif
+
+#define UG_ICON_FOLDER UG_ICON_PATH"/47_myfiles_icon_folder.png"
+#define UG_ICON_IMAGE UG_ICON_PATH"/60_myfiles_icon_images.png"
+#define UG_ICON_VIDEO UG_ICON_PATH"/47_myfiles_icon_video.png"
+#define UG_ICON_MUSIC UG_ICON_PATH"/47_myfiles_icon_music.png"
+#define UG_ICON_SOUND UG_ICON_PATH"/60_myfiles_icon_music_default.png"
+#define UG_ICON_PDF UG_ICON_PATH"/47_myfiles_icon_pdf.png"
+#define UG_ICON_DOC UG_ICON_PATH"/47_myfiles_icon_word.png"
+#define UG_ICON_PPT UG_ICON_PATH"/47_myfiles_icon_ppt.png"
+#define UG_ICON_EXCEL UG_ICON_PATH"/47_myfiles_icon_excel.png"
+#define UG_ICON_VOICE UG_ICON_PATH"/60_myfiles_file_amr.png"
+#define UG_ICON_HTML UG_ICON_PATH"/47_myfiles_icon_html.png"
+#define UG_ICON_FLASH UG_ICON_PATH"/47_myfiles_icon_swf.png"
+#define UG_ICON_TXT UG_ICON_PATH"/47_myfiles_icon_text.png"
+#define UG_ICON_VCONTACT UG_ICON_PATH"/60_myfiles_icon_vcard.png"
+#define UG_ICON_VCALENDAR UG_ICON_PATH"/60_myfiles_icon_vcalender.png"
+#define UG_ICON_VNOTE UG_ICON_PATH"/60_myfiles_icon_vText.png"
+#define UG_ICON_RSS UG_ICON_PATH"/47_myfiles_icon_rss.png"
+#define UG_ICON_JAVA UG_ICON_PATH"/60_myfiles_icon_java.png"
+#define UG_ICON_MEMORY_SUB UG_ICON_PATH"/60_myfiles_memorycard_sub.png"
+#define UG_ICON_MUSIC_PLAY UG_ICON_PATH"/34_control_play.png"
+#define UG_ICON_MUSIC_PAUSE UG_ICON_PATH"/34_control_pause.png"
+#define UG_ICON_MUSIC_PLAY_WHITE UG_ICON_PATH"/47_myfiles_icon_play_focus.png"
+#define UG_ICON_MUSIC_PAUSE_WHITE UG_ICON_PATH"/47_myfiles_icon_pause_focus.png"
+#define UG_ICON_UPPER UG_ICON_PATH"/47_myfiles_icon_upper_folder_white_theme.png"
+
+#define UG_ICON_FOLDER_CREATED UG_ICON_PATH"/47_myfiles_icon_folder_created.png"
+#define UG_ICON_FOLDER_SINCED UG_ICON_PATH"/47_myfiles_icon_folder_sinced.png"
+#define UG_ICON_PHONE UG_ICON_PATH"/60_myfiles_phone.png"
+#define UG_ICON_MEMORY UG_ICON_PATH"/60_myfiles_memorycard.png"
+
+typedef enum _mf_ug_fs_file_type mf_ug_fs_file_type;
+
+enum _mf_ug_fs_file_type {
+ UG_FILE_TYPE_NONE = 0,
+ UG_FILE_TYPE_DIR, /**< Folder category */
+ UG_FILE_TYPE_FILE, /**< File category */
+ UG_FILE_TYPE_IMAGE, /**< Image category */
+ UG_FILE_TYPE_VIDEO, /**< Video category */
+ UG_FILE_TYPE_MUSIC, /**< Music category */
+ UG_FILE_TYPE_SOUND, /**< Sound category */
+ UG_FILE_TYPE_PDF, /**< Pdf category */
+ UG_FILE_TYPE_DOC, /**< Word category */
+ UG_FILE_TYPE_PPT, /**< Powerpoint category */
+ UG_FILE_TYPE_EXCEL, /**< Excel category */
+ UG_FILE_TYPE_VOICE, /**< Voice category */
+ UG_FILE_TYPE_HTML, /**< Html category */
+ UG_FILE_TYPE_FLASH, /**< Flash category */
+ UG_FILE_TYPE_GAME, /**< Game category */
+ UG_FILE_TYPE_APP, /**< Application category */
+ UG_FILE_TYPE_THEME, /**< Theme category */
+ UG_FILE_TYPE_TXT, /**< Txt category */
+ UG_FILE_TYPE_VCONTACT, /**< Vcontact category */
+ UG_FILE_TYPE_VCALENDAR, /**< Vcalendar category */
+ UG_FILE_TYPE_VNOTE, /**< Vnote category */
+ UG_FILE_TYPE_VBOOKMARK, /**< Vbookmark category */
+ UG_FILE_TYPE_VIDEO_PROJECT, /**< Video editor project category */
+ UG_FILE_TYPE_RADIO_RECORDED, /**< radio recorded clips category */
+ UG_FILE_TYPE_MOVIE_MAKER, /**< Movie maker project category */
+ UG_FILE_TYPE_SVG, /**< Svg category */
+ UG_FILE_TYPE_RSS, /**< Rss reader file, *.opml */
+ UG_FILE_TYPE_CERTIFICATION, /**< certification file, *.pem */
+ UG_FILE_TYPE_JAVA, /**< java file, *.jad, *.jar */
+ UG_FILE_TYPE_WGT, /**< wrt , *.wgt, *.wgt */
+ UG_FILE_TYPE_ETC, /**< Other files category */
+ UG_FILE_TYPE_MAX
+};
+
+typedef enum _mf_ug_iter_category_filter_t mf_ug_iter_category_filter_t;
+enum _mf_ug_iter_category_filter_t {
+ UG_FILTER_CATEGORY_NONE = 0x00000000, /**< Default */
+ UG_FILTER_CATEGORY_IMAGE = 0x00000001, /**< Image category */
+ UG_FILTER_CATEGORY_VIDEO = 0x00000002, /**< Video category */
+ UG_FILTER_CATEGORY_SOUND = 0x00000004, /**< Sound category */
+ UG_FILTER_CATEGORY_VOICE = 0x00000008, /**< Voice category */
+ UG_FILTER_CATEGORY_MUSIC = 0x00000010, /**< Music category */
+ UG_FILTER_CATEGORY_HTML = 0x00000020, /**< Html category */
+ UG_FILTER_CATEGORY_FLASH = 0x00000040, /**< Flash category */
+ UG_FILTER_CATEGORY_GAME = 0x00000080, /**< Game category */
+ UG_FILTER_CATEGORY_APP = 0x00000100, /**< Application category */
+ UG_FILTER_CATEGORY_THEME = 0x00000200, /**< Theme category */
+ UG_FILTER_CATEGORY_DOC = 0x00000400, /**< Word category */
+ UG_FILTER_CATEGORY_EXCEL = 0x00000800, /**< Excel category */
+ UG_FILTER_CATEGORY_PPT = 0x00001000, /**< Powerpoint category */
+ UG_FILTER_CATEGORY_PDF = 0x00002000, /**< Pdf category */
+ UG_FILTER_CATEGORY_TXT = 0x00004000, /**< Txt category */
+ UG_FILTER_CATEGORY_VCONTACT = 0x00008000, /**< Vcontact category */
+ UG_FILTER_CATEGORY_VCALENDAR = 0x00010000, /**< Vcalendar category */
+ UG_FILTER_CATEGORY_VNOTE = 0x00020000, /**< Vnote category */
+ UG_FILTER_CATEGORY_VBOOKMARK = 0x00040000, /**< Vbookmark category */
+ UG_FILTER_CATEGORY_VIDEO_PROJECT = 0x00080000, /**< Video editor project category */
+ UG_FILTER_CATEGORY_SVG = 0x00100000, /**< SVG category */
+ UG_FILTER_CATEGORY_RSS = 0x00200000, /**< RSS category */
+ UG_FILTER_CATEGORY_ETC = 0x00400000, /**< Other files category */
+
+};
+
+typedef enum _mf_ug_storage_type mf_ug_storage_type;
+enum _mf_ug_storage_type {
+ MF_UG_NONE,
+ MF_UG_PHONE,
+ MF_UG_MMC,
+ MF_UG_MAX
+};
+
+
+/* File operation error check options definition */
+#define MF_ERROR_CHECK_SRC_ARG_VALID 0x0001
+#define MF_ERROR_CHECK_SRC_EXIST 0x0002
+#define MF_ERROR_CHECK_SRC_PATH_VALID 0x0004
+
+/* File system error definition */
+#define MF_ERROR_MASKL16 0xFFFF
+
+#define MF_ERROR_SET(X) (X & MF_ERROR_MASKL16)
+
+#define MID_CONTENTS_MGR_ERROR 0
+
+#define MYFILE_ERR_NONE (MID_CONTENTS_MGR_ERROR - MF_ERROR_SET(0x00)) /**< No error */
+
+/*/1-10*/
+#define MYFILE_ERR_SRC_ARG_INVALID (MID_CONTENTS_MGR_ERROR - MF_ERROR_SET(0x01)) /**< invalid src argument */
+#define MYFILE_ERR_DST_ARG_INVALID (MID_CONTENTS_MGR_ERROR - MF_ERROR_SET(0x02)) /**< invalid dst argument */
+#define MYFILE_ERR_DIR_OPEN_FAIL (MID_CONTENTS_MGR_ERROR - MF_ERROR_SET(0x03)) /**< exception of dir open*/
+#define MYFILE_ERR_INVALID_DIR_PATH (MID_CONTENTS_MGR_ERROR - MF_ERROR_SET(0x04)) /**< exception of invalid dir path */
+#define MYFILE_ERR_INVALID_FILE_NAME (MID_CONTENTS_MGR_ERROR - MF_ERROR_SET(0x05)) /**< exception of invalid file name */
+#define MYFILE_ERR_INVALID_FILE_PATH (MID_CONTENTS_MGR_ERROR - MF_ERROR_SET(0x06)) /**< exception of invalid file path */
+#define MYFILE_ERR_SRC_NOT_EXIST (MID_CONTENTS_MGR_ERROR - MF_ERROR_SET(0x08)) /**< source not found */
+#define MYFILE_ERR_STORAGE_TYPE_ERROR (MID_CONTENTS_MGR_ERROR - MF_ERROR_SET(0x09)) /**< storage type error */
+#define MYFILE_ERR_EXT_GET_ERROR (MID_CONTENTS_MGR_ERROR - MF_ERROR_SET(0x0a)) /**< get ext type failed */
+#define MYFILE_ERR_GET_STAT_FAIL (MID_CONTENTS_MGR_ERROR - MF_ERROR_SET(0x0b)) /**< get stat failed */
+#define MYFILE_ERR_GET_CATEGORY_FAIL (MID_CONTENTS_MGR_ERROR - MF_ERROR_SET(0x0c)) /**< get file category failed */
+#define MYFILE_ERR_GET_VCONF_FAIL (MID_CONTENTS_MGR_ERROR - MF_ERROR_SET(0x0d)) /**< get vconf value failed */
+#define MYFILE_ERR_INVALID_ARG (MID_CONTENTS_MGR_ERROR - MF_ERROR_SET(0x0e)) /**< argument of function is not valid */
+#define MYFILE_ERR_ALLOCATE_FAIL (MID_CONTENTS_MGR_ERROR - MF_ERROR_SET(0x0f))
+#define MYFILE_ERR_LIST_PLAY_FAIL (MID_CONTENTS_MGR_ERROR - MF_ERROR_SET(0x10))
+#define MYFILE_ERR_INVALID_PATH (MID_CONTENTS_MGR_ERROR - MF_ERROR_SET(0x11)) /**< invalid path string */
+#define MYFILE_ERR_GET_THUMBNAIL_FAILED (MID_CONTENTS_MGR_ERROR - MF_ERROR_SET(0x12)) /**<get thumbnail failed */
+#define MYFILE_ERR_UNKNOW_ERROR (MID_CONTENTS_MGR_ERROR - MF_ERROR_SET(0x13)) /**<unknow error */
+/* File system related callback definition */
+
+typedef struct _ugFsNodeInfo ugFsNodeInfo;
+struct _ugFsNodeInfo {
+ char path[MYFILE_DIR_PATH_LEN_MAX];
+ char name[MYFILE_FILE_NAME_LEN_MAX];
+ time_t date;
+ mf_ug_fs_file_type type;
+ char ext[FILE_EXT_LEN_MAX];
+ unsigned int size;
+};
+
+
+/********** File Attribute Related **********/
+int mf_ug_file_attr_get_file_stat(const char *filename, ugFsNodeInfo ** node);
+
+int mf_ug_file_attr_get_file_category(const char *filepath, mf_ug_fs_file_type * category);
+int mf_ug_file_attr_is_dir(const char *filepath);
+int mf_ug_file_attr_get_store_type_by_full(const char *filepath, mf_ug_storage_type * store_type);
+int mf_ug_file_attr_get_file_ext(const char *filepath, char *file_ext);
+int mf_ug_file_attr_is_right_dir_path(const char *dir_path);
+int mf_ug_file_attr_is_right_file_path(const char *file_path);
+
+/********** File Operation Related **********/
+int mf_ug_fs_oper_read_dir(const char *path, Eina_List **dir_list, Eina_List **file_list);
+int mf_ug_fs_oper_list_filter(Eina_List *in_list, Eina_List **out_list, int option);
+int mf_ug_fs_oper_list_filter_by_extension(Eina_List *in_list, Eina_List **out_list, char *ext);
+char *mf_ug_file_attr_get_file_icon(MediaSvcHandle *handle, const char *file_path, int *error_code);
+int mf_ug_file_attr_is_system_dir(char *fullpath, bool * result);
+mf_ug_fs_file_type mf_ug_file_attr_get_file_type_by_mime(const char *file_path);
+
+#endif
diff --git a/src/include/mf-ug-inotify-handle.h b/src/include/mf-ug-inotify-handle.h
new file mode 100755
index 0000000..bd1627e
--- /dev/null
+++ b/src/include/mf-ug-inotify-handle.h
@@ -0,0 +1,44 @@
+/*
+ * Copyright 2012 Samsung Electronics Co., Ltd
+ *
+ * Licensed under the Flora License, Version 1.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.tizenopensource.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 __DEF_MF_UG_INOTIFY_HANDLE_H
+#define __DEF_MF_UG_INOTIFY_HANDLE_H
+
+typedef enum _mf_ug_inotify_event mf_ug_inotify_event;
+enum _mf_ug_inotify_event {
+ UG_MF_INOTI_NONE = 0,
+ UG_MF_INOTI_CREATE,
+ UG_MF_INOTI_DELETE,
+ UG_MF_INOTI_MODIFY,
+ UG_MF_INOTI_MOVE_OUT,
+ UG_MF_INOTI_MOVE_IN,
+ UG_MF_INOTI_DELETE_SELF,
+ UG_MF_INOTI_MOVE_SELF,
+ UG_MF_INOTI_MAX,
+};
+
+typedef void (*mf_ug_inotify_cb) (mf_ug_inotify_event event, char *name, void *data);
+
+int mf_ug_inotify_handle_init_inotify(void);
+int mf_ug_inotify_handle_add_inotify_watch(const char *path, mf_ug_inotify_cb callback, void *user_data);
+int mf_ug_inotify_handle_rm_inotify_watch(void);
+void mf_ug_inotify_handle_finalize_inotify(void);
+
+#endif
diff --git a/src/include/mf-ug-main.h b/src/include/mf-ug-main.h
new file mode 100755
index 0000000..d2fbd08
--- /dev/null
+++ b/src/include/mf-ug-main.h
@@ -0,0 +1,147 @@
+/*
+ * Copyright 2012 Samsung Electronics Co., Ltd
+ *
+ * Licensed under the Flora License, Version 1.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.tizenopensource.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 __DEF_MF_UG_MAIN_H_
+#define __DEF_MF_UG_MAIN_H_
+
+#define __ARM__
+
+#include <Elementary.h>
+#include <Ethumb.h>
+#include <glib.h>
+#include <Ecore.h>
+#include <glib-object.h>
+#include <mm_player.h>
+#include <ui-gadget-module.h>
+#include <ui-gadget.h>
+#include <bundle.h>
+#include <stdbool.h>
+#include <visual-svc.h>
+#include <media-svc.h>
+
+#include "mf-ug-dlog.h"
+#include "mf-ug-conf.h"
+/*********** Global Definitions ***********/
+#ifndef UG_MODULE_API
+#define UG_MODULE_API __attribute__ ((visibility("default")))
+#endif
+
+typedef void (*ugCallBack) (void *, Evas_Object *, void *);
+
+typedef struct _ugNaviBar ugNaviBar;
+
+struct _ugNaviBar {
+ Evas_Object *ug_pNaviBar;
+ Evas_Object *ug_pNaviBox;
+ Evas_Object *ug_pNaviLayout;
+ Evas_Object *ug_pContent;
+ Evas_Object *ug_pNaviCtrlBar;
+ Evas_Object *ug_pCtrlBarButton[3];
+
+ Elm_Object_Item *ug_pPreNaviItem;
+ Elm_Object_Item *ug_pNaviItem;
+ char *ug_pNaviLabel;
+ char *ug_pNaviTitle;
+ char *ug_pCurrentPath;
+ bool ug_bNaviFlagInUse;
+};
+
+
+typedef struct _ugMainWindow ugMainWindow;
+struct _ugMainWindow {
+ Evas_Object *ug_pWindow;
+ Evas_Object *ug_pBackGround;
+ Evas_Object *ug_pTabBackGround;
+ Evas_Object *ug_pMainLayout;
+ Evas_Object *ug_pNormalPopup;
+ Evas_Object *ug_pLabel;
+ Evas_Object *ug_pSelectInfoLayout;
+ Evas_Object *ug_pRadioGroup;
+ Evas_Object *ug_pTabBar;
+ Evas_Object *ug_pTabLayout;
+ Eina_List *ug_pNaviBarList;
+};
+
+
+typedef struct _ugStatus ugStatus;
+struct _ugStatus {
+ GString *ug_pPath;
+ int ug_iState;
+ int ug_iSortType;
+ int ug_iRadioOn;
+ int ug_iMmcFlag;
+ int ug_iCtrlBarType;
+ bool ug_bAudioPlayFlag;
+ bool ug_bInstallFlag;
+ bool ug_bSettingEntry;
+ bool ug_bInSettingView;
+ bool ug_bMassStorageFlag;
+ bool ug_bNoContentFlag;
+ bool ug_bCancelDisableFlag;
+ bool ug_b_NaviPushFlag;
+ char *ug_pUpper_folder;
+ bool ug_bUpperFlag;
+ Elm_Genlist_Item_Class ug_itc;
+ Elm_Genlist_Item_Class ug_topitc;
+ Elm_Genlist_Item_Class ug_separtor_no_bottom_line_itc;
+ Elm_Genlist_Item_Class ug_separtor_with_bottom_line_itc;
+ Elm_Genlist_Item_Class ug_normalitc;
+ Elm_Genlist_Item_Class ug_editfileditc;
+ Elm_Genlist_Item_Class ug_editfiledUpperSeperatoritc;
+ Elm_Genlist_Item_Class ug_editfiledBottomSeperatoritc;
+#ifdef UG_THUMB_REAL_TIME_UPDATE
+ Ecore_Timer *ug_pThumbUpdateTimer;
+#endif
+ MediaSvcHandle *ug_pMedia_svc_handle;
+};
+
+
+typedef struct _ugUiGadget ugUiGadget;
+struct _ugUiGadget {
+ int ug_iFilterMode;
+ int ug_iSelectMode;
+ int ug_iMarkedMode;
+ unsigned long ug_iFileFilter;
+ char *ug_pExtension;
+ Eina_List *ug_pDirList;
+ Eina_List *ug_pFilterList;
+ Eina_List *ug_pMultiSelectFileList;
+ Ecore_Pipe *ug_pInotifyPipe;
+};
+
+typedef struct _ugListPlay ugListPlay;
+struct _ugListPlay {
+ char *ug_pPlayFilePath;
+ MMHandleType ug_Player;
+ int ug_iPlayState;
+};
+
+
+typedef struct _ugData ugData;
+struct _ugData {
+ ugMainWindow ug_MainWindow;
+ ugStatus ug_Status;
+ ugUiGadget ug_UiGadget;
+ ugListPlay ug_ListPlay;
+ struct ui_gadget *ug;
+};
+
+
+#endif /* __DEF_MYFILE_H_ */
diff --git a/src/include/mf-ug-resource.h b/src/include/mf-ug-resource.h
new file mode 100755
index 0000000..3e9296f
--- /dev/null
+++ b/src/include/mf-ug-resource.h
@@ -0,0 +1,41 @@
+/*
+ * Copyright 2012 Samsung Electronics Co., Ltd
+ *
+ * Licensed under the Flora License, Version 1.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.tizenopensource.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 __DEF_MF_UG_RESOURCE_H_
+#define __DEF_MF_UG_RESOURCE_H_
+
+#include "mf-ug-conf.h"
+
+#define MF_UG_LABEL_PHONE dgettext("sys_string", "IDS_COM_BODY_PHONE")
+#define MF_UG_LABEL_MMC dgettext("sys_string", "IDS_COM_BODY_MEMORY_CARD")
+#define MF_UG_LABEL_OTG "External storage"
+#define MF_UG_LABEL_UNKNOWN dgettext("sys_string", "IDS_COM_BODY_UNKNOWN")
+#define MF_UG_LABEL_SET dgettext("sys_string", "IDS_COM_SK_SET")
+#define MF_UG_LABEL_ATTACH dgettext("sys_string", "IDS_COM_POP_ATTACH")
+#define MF_UG_LABEL_CANCEL dgettext("sys_string", "IDS_COM_SK_CANCEL")
+#define MF_UG_LABEL_OTHER_MUSIC "Other music"
+#define MF_UG_LABEL_RINGTONES "Ringtones"
+#define MF_UG_LABEL_NO_FILES dgettext("sys_string", "IDS_COM_BODY_NO_FILES")
+#define MF_UG_LABEL_MYFILES dgettext("sys_string", "IDS_COM_BODY_MY_FILES")
+#define MF_UG_LABEL_OK dgettext("sys_string", "IDS_COM_SK_OK")
+#define MF_UG_LABEL_HOME dgettext(UGPACKAGE, "IDS_MF_BUTTON_HOME")
+#define MF_UG_LABEL_UPPER dgettext(UGPACKAGE, "IDS_MF_TAB_UP")
+
+#endif
+
diff --git a/src/include/mf-ug-util.h b/src/include/mf-ug-util.h
new file mode 100755
index 0000000..f4a0de4
--- /dev/null
+++ b/src/include/mf-ug-util.h
@@ -0,0 +1,201 @@
+/*
+ * Copyright 2012 Samsung Electronics Co., Ltd
+ *
+ * Licensed under the Flora License, Version 1.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.tizenopensource.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 __DEF_MF_UG_UTIL_H_
+#define __DEF_MF_UG_UTIL_H_
+
+#include <Elementary.h>
+#include <stdbool.h>
+#include <glib.h>
+
+#include "mf-ug-main.h"
+
+#define UG_SAFE_FREE_CHAR(x) do {\
+ if ((x) != NULL) {\
+ free(x); \
+ x = NULL;\
+ } \
+ } while (0)
+
+#define UG_SAFE_FREE_GSTRING(x) do {\
+ if ((x) != NULL) {\
+ g_string_free(x, TRUE); \
+ x = NULL;\
+ } \
+ } while (0)
+
+#define UG_CHAR_CHECK_NULL_GOTO(arg, dest) do {\
+ if ((arg) == NULL) {\
+ goto dest;\
+ } \
+ } while (0)
+
+#define UG_GSTRING_CHECK_NULL_GOTO(arg, dest) do {\
+ if ((arg) == NULL || (arg->str) == NULL) {\
+ goto dest;\
+ } \
+ } while (0)
+
+
+#define UG_SAFE_DEL_NAVI_ITEM(x) do {\
+ if ((x) != NULL) {\
+ elm_object_item_del(x); \
+ x = NULL;\
+ } \
+ } while (0)
+
+
+#define UG_SAFE_FREE_OBJ(x) do {\
+ if ((x) != NULL) {\
+ evas_object_del(x); \
+ x = NULL;\
+ } \
+ } while (0)
+
+typedef enum _mf_ug_list_play_state mf_ug_list_play_state;
+
+enum _mf_ug_list_play_state {
+ PLAY_STATE_INIT = 0,
+ PLAY_STATE_READY,
+ PLAY_STATE_PLAYING,
+ PLAY_STATE_PAUSED,
+ PLAY_STATE_STOP,
+ PLAY_STATE_MAX
+};
+
+
+typedef enum _mf_ug_select_mode mf_ug_select_mode;
+enum _mf_ug_select_mode {
+ SELECT_MODE = 0,
+ SINGLE_FILE_MODE,
+ SINGLE_ALL_MODE,
+ MULTI_FILE_MODE,
+ MULTI_ALL_MODE,
+ SELECT_MODE_MAX
+};
+
+typedef enum _mf_ug_marked_switch mf_ug_marked_switch;
+enum _mf_ug_marked_switch {
+ MARKED_OFF = 0,
+ MARKED_ON,
+};
+
+typedef enum _mf_ug_file_filter_type mf_ug_file_filter_type;
+enum _mf_ug_file_filter_type {
+ SHOW_ALL_LIST = 0,
+ SHOW_IMAGE_LIST,
+ SHOW_SOUND_LIST,
+ SHOW_VIDEO_LIST,
+ SHOW_FLASH_LIST,
+ SHOW_FOLDER_LIST,
+ SHOW_IMAGE_VIDEO_LIST,
+ SHOW_IMAGE_SOUND_LIST,
+ SHOW_VIDEO_SOUND_LIST,
+ SHOW_BY_EXTENSION
+};
+
+
+
+typedef enum _mf_ug_state_mode mf_ug_state_mode;
+enum _mf_ug_state_mode {
+ STATE_PHONE = 0,
+ STATE_MEMORY,
+ STATE_MODE_MAX
+};
+
+typedef enum _mf_ug_mmc_insert_state mf_ug_mmc_insert_state;
+enum _mf_ug_mmc_insert_state {
+ MMC_OFF = 0,
+ MMC_ON
+};
+
+typedef enum _mf_ug_launch_type mf_ug_launch_type;
+enum _mf_ug_launch_type {
+ LAUNCH_TYPE_FORK = 0,
+ LAUNCH_TYPE_FAIL,
+ LAUNCH_TYPE_DIR,
+ LAUNCH_TYPE_IMAGE,
+ LAUNCH_TYPE_MUSIC,
+ LAUNCH_TYPE_VIDEO,
+ LAUNCH_TYPE_UNSUPPORT,
+ LAUNCH_TYPE_MAX
+};
+
+typedef enum _mf_ug_eina_list_node_type mf_ug_eina_list_node_type;
+enum _mf_ug_eina_list_node_type {
+ NODE_TYPE_NONE = 0,
+ NODE_TYPE_CHAR,
+ NODE_TYPE_PNODE,
+ NODE_TYPE_GSTRING,
+ NODE_TYPE_MAX
+};
+
+typedef enum _mf_ug_ctrl_bar_type mf_ug_ctrl_bar_type;
+enum _mf_ug_ctrl_bar_type {
+ CTRL_BAR_NORMAL = 0,
+ CTRL_BAR_MUSIC,
+ CTRL_BAR_RINGTONE,
+ CTRL_BAR_MULTI,
+ CTR_BAR_MAX
+};
+
+typedef struct _ugListItemData ugListItemData;
+struct _ugListItemData {
+ Evas_Object *ug_pCheckBox;
+ Evas_Object *ug_pRadioBox;
+ Elm_Object_Item *ug_pItem;
+ char *ug_pThumbPath;
+ GString *ug_pItemName;
+ ugData *ug_pData;
+ bool ug_bChecked;
+ int ug_iGroupValue;
+ bool ug_bRealThumbFlag;
+};
+
+typedef struct _ug_dir_event_t ug_dir_event_t;
+struct _ug_dir_event_t {
+ int event;
+ char *name;
+};
+
+bool mf_ug_util_is_mass_storage_on();
+int mf_ug_util_create_dir_monitor(void *data);
+int mf_ug_util_set_mmc_state_cb(void *data);
+int mf_ug_util_get_mmc_state(int *mmc_card);
+char *mf_ug_util_get_send_result(void *data);
+bool mf_ug_util_is_genlist_selected(void *data);
+
+void mf_ug_list_play_play_music_item(ugListItemData *data);
+void mf_ug_list_play_destory_playing_file(void *data);
+void mf_ug_util_storage_insert_action(void *data, char *pItemLabel);
+void mf_ug_util_destory_mmc_state_cb();
+void mf_ug_util_destory_dir_monitor(void *data);
+void mf_ug_util_get_params_path(Eina_List **dest_list, const char *path_list);
+void mf_ug_util_free_eina_list_data(Eina_List **list, mf_ug_eina_list_node_type node_type);
+int mf_ug_util_set_main_layout_by_tab_item_count(void *data);
+void mf_ug_util_set_current_state(void *data, int state);
+int mf_ug_util_add_dir_watch(const char *path, void *data);
+mf_ug_launch_type mf_ug_util_get_file_launch_type(char *path);
+
+void mf_ug_util_destory_mass_storage_callback();
+int mf_ug_file_attr_get_parent_path(const char *path, char **parent_path);
+char *mf_ug_util_upper_folder_name_get(void *data, GString *fullpath);
+
+#endif /* __DEF_MYFILE_UTIL_H_ */
diff --git a/src/include/mf-ug-winset.h b/src/include/mf-ug-winset.h
new file mode 100755
index 0000000..cd52adf
--- /dev/null
+++ b/src/include/mf-ug-winset.h
@@ -0,0 +1,129 @@
+/*
+ * Copyright 2012 Samsung Electronics Co., Ltd
+ *
+ * Licensed under the Flora License, Version 1.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.tizenopensource.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 __DEF_MF_UG_WINSET_H_
+#define __DEF_MF_UG_WINSET_H_
+
+#include <stdio.h>
+#include <assert.h>
+#include <Elementary.h>
+#include <glib.h>
+#include <vconf.h>
+#include <vconf-keys.h>
+
+
+#include "mf-ug-main.h"
+#include "mf-ug-cb.h"
+#include "mf-ug-conf.h"
+
+
+/******************Navigation Bar Definition ***********/
+#define MF_UG_NAVI_STYLE_ENABLE "1line"
+#define MF_UG_UPPER_HEIGHT (113*elm_config_scale_get())
+#define MF_UG_UPPER_WIDTH (480*elm_config_scale_get())
+
+Evas_Object *mf_ug_navi_bar_create_navi_bar(Evas_Object *parent);
+void mf_ug_navi_bar_set_new_content(Evas_Object *pLayout, Evas_Object *NaviContent);
+void mf_ug_navi_bar_create_default_view(void *data);
+ugNaviBar *mf_ug_navi_bar_get_in_use_navi(void *data);
+ugNaviBar *mf_ug_navi_bar_get_navi_struct_by_navi(void *data, Evas_Object *pNaviBar);
+void mf_ug_navi_bar_reset_navi_object(ugNaviBar *pNavi_s);
+void mf_ug_navi_bar_refresh_navibar_recovered_view(void *data, ugNaviBar *pNaviStruct);
+void mf_ug_navi_bar_remove_navi_list_item_by_label(void *data, const char *pNaviLabel);
+void mf_ug_navi_bar_set_select_info_label(void *data, int dir_count, int file_count);
+void mf_ug_navi_bar_set_blocking(void *data, bool bblock_during_transition);
+void mf_ug_navi_bar_remove_previous_contents(void *data);
+void mf_ug_navi_bar_del_item_directly(void *data);
+
+/********** Control Bar Definition ********/
+
+#define UG_CTRL_ICON_CANCEL UG_ICON_PATH"/myfile_icon_cancel.png"
+#define UG_CTRL_ICON_SAVE UG_ICON_PATH"/myfile_icon_done.png"
+
+typedef enum _eCtrlBarButtonType eCtrlBarButtonType;
+
+enum _eCtrlBarButtonType {
+ CTRL_BUTTON_CANCEL = 0,
+ CTRL_BUTTON_DONE,
+ CTRL_BUTTON_ADD,
+ CTRL_BUTTON_OTHER_RIONTONGS,
+ CTRL_BUTTON_MUSIC,
+ CTRL_BUTTON_MAX
+};
+
+void mf_ug_ctrl_bar_set(void *data, ugNaviBar *pNavi_s);
+void mf_ug_ctrl_bar_disable_item(void *data, bool disable);
+void mf_ug_ctrl_bar_set_item_disable(void *data);
+
+
+/**********Tab Bar Definition *************/
+Evas_Object *mf_ug_tab_bar_create(Evas_Object *parent);
+Elm_Object_Item *mf_ug_tab_bar_append_item(Evas_Object *pTabBar, char *pTabIconPath, char *pTabBarLabel, void *user_data);
+void mf_ug_tab_bar_set_item_view(Evas_Object *parent, Evas_Object *tab_layout, Evas_Object *view);
+void mf_ug_tab_bar_remove_item_by_label(Evas_Object *pTabBar, char *pTabLabel);
+void mf_ug_tab_bar_remove_all_items(Evas_Object *pTabBar);
+void mf_ug_tab_bar_set_selected_item(Elm_Object_Item *pItem);
+void mf_ug_tab_bar_set_item_disable(Evas_Object *pTabBar, Eina_Bool disable);
+void mf_ug_ctrl_bar_recover(void *data);
+
+
+/*********** Popup Definition ************/
+typedef enum _mf_ug_popup_mode mf_ug_popup_mode;
+enum _mf_ug_popup_mode {
+ UG_POPMODE_MIN = 0,
+ UG_POPMODE_TEXT,
+ UG_POPMODE_TITLE_TEXT,
+ UG_POPMODE_TEXT_TWO_BTN,
+ UG_POPMODE_TITLE_TEXT_TWO_BTN,
+ UG_POPMODE_TEXT_BTN,
+ UG_POPMODE_TITLE_TEXT_BTN,
+ UG_POPMODE_TITLE_TEXT_THREE_BTN,
+ UG_POPMODE_PROGRESSBAR,
+ UG_POPMPDE_MAX
+};
+
+typedef enum _mf_ug_popup_event_type mf_ug_popup_event_type;
+enum _mf_ug_popup_event_type {
+ UG_ELM_POPUP_NONE,
+ UG_ELM_POPUP_YES,
+ UG_ELM_POPUP_NO,
+ UG_ELM_POPUP_OK,
+ UG_ELM_POPUP_CANCLE,
+ UG_ELM_POPUP_AUTO_RENAME,
+ UG_ELM_POPUP_REPLACE,
+ UG_ELM_POPUP_PHONE,
+ UG_ELM_POPUP_MEMORY,
+ UG_ELM_POPUP_MAX
+};
+
+/*********** Popup API ************/
+void mf_ug_popup_create(void *data, mf_ug_popup_mode popupMode, char *title, char *context, char *first_btn_text, char *second_btn_text,
+ char *third_btn_text, Evas_Smart_Cb func, void *param);
+
+
+/******************* Genlist API *********************/
+
+void mf_ug_upper_genlist_item_append(Evas_Object *pGenlist, void *data);
+void mf_ug_genlist_goto_myfile_item_append(Evas_Object *pGenlist, void *data);
+Evas_Object *mf_navi_bar_upper_create(Evas_Object *parent);
+void mf_ug_genlist_goto_myfile_style_set(void *data);
+void mf_ug_genlist_upper_style_set(void *data);
+Evas_Object *mf_ug_genlist_create_content_list_view(void *data);
+
+#endif
diff --git a/src/mf-ug-main.c b/src/mf-ug-main.c
new file mode 100755
index 0000000..af80db3
--- /dev/null
+++ b/src/mf-ug-main.c
@@ -0,0 +1,1137 @@
+/*
+ * Copyright 2012 Samsung Electronics Co., Ltd
+ *
+ * Licensed under the Flora License, Version 1.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.tizenopensource.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 <stdio.h>
+#include <sys/time.h>
+#include <Elementary.h>
+#include <Ecore_X.h>
+#include <vconf.h>
+#include <visual-svc.h>
+#include <media-svc.h>
+
+#include "mf-ug-main.h"
+#include "mf-ug-fs-util.h"
+#include "mf-ug-util.h"
+#include "mf-ug-conf.h"
+#include "mf-ug-dlog.h"
+#include "mf-ug-winset.h"
+#include "mf-ug-fm-svc-wrapper.h"
+#include "mf-ug-resource.h"
+
+/******************************
+** Prototype : __mf_ug_main_init_data
+** Description :
+** Input : void *data
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+static void __mf_ug_main_init_data(void *data)
+{
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+ ug_mf_retm_if(ugd == NULL, "ugData is NULL");
+
+ if (ugd->ug_Status.ug_pPath != NULL) {
+ g_string_free(ugd->ug_Status.ug_pPath, TRUE);
+ ugd->ug_Status.ug_pPath = NULL;
+ }
+ ugd->ug_Status.ug_pPath = g_string_new(PHONE_FOLDER);
+ ugd->ug_Status.ug_iState = STATE_PHONE;
+ ugd->ug_Status.ug_iRadioOn = 0;
+ ugd->ug_Status.ug_iMmcFlag = false;
+ ugd->ug_Status.ug_bAudioPlayFlag = false;
+ ugd->ug_Status.ug_bInstallFlag = true;
+ ugd->ug_Status.ug_bInSettingView = false;
+ ugd->ug_Status.ug_bSettingEntry = false;
+
+ ugd->ug_UiGadget.ug_iSelectMode = SINGLE_FILE_MODE;
+ ugd->ug_UiGadget.ug_iFilterMode = SHOW_ALL_LIST;
+ ugd->ug_UiGadget.ug_pExtension = NULL;
+ ugd->ug_UiGadget.ug_iMarkedMode = MARKED_OFF;
+ ugd->ug_UiGadget.ug_pMultiSelectFileList = NULL;
+
+ ugd->ug_ListPlay.ug_pPlayFilePath = NULL;
+ ugd->ug_ListPlay.ug_iPlayState = PLAY_STATE_INIT;
+
+
+ mf_ug_util_create_dir_monitor(ugd);
+ mf_ug_util_set_mmc_state_cb(ugd);
+ mf_ug_cb_set_mass_storage_state_cb(ugd);
+ UG_TRACE_END;
+}
+
+/******************************
+** Prototype : __mf_ug_main_free_data
+** Description :
+** Input : void *data
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+static void __mf_ug_main_free_data(void *data)
+{
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+ ug_mf_retm_if(ugd == NULL, "ugData is NULL");
+
+ if (ugd->ug_Status.ug_pPath) {
+ g_string_free(ugd->ug_Status.ug_pPath, TRUE);
+ ugd->ug_Status.ug_pPath = NULL;
+ }
+ if (ugd->ug_UiGadget.ug_pMultiSelectFileList) {
+ mf_ug_util_free_eina_list_data(&ugd->ug_UiGadget.ug_pMultiSelectFileList, NODE_TYPE_CHAR);
+ ugd->ug_UiGadget.ug_pMultiSelectFileList = NULL;
+ }
+ if (ugd->ug_UiGadget.ug_pDirList) {
+ mf_ug_util_free_eina_list_data(&ugd->ug_UiGadget.ug_pDirList, NODE_TYPE_PNODE);
+ ugd->ug_UiGadget.ug_pDirList = NULL;
+ }
+ if (ugd->ug_UiGadget.ug_pFilterList) {
+ mf_ug_util_free_eina_list_data(&ugd->ug_UiGadget.ug_pFilterList, NODE_TYPE_PNODE);
+ ugd->ug_UiGadget.ug_pFilterList = NULL;
+ }
+
+ if (ugd->ug_Status.ug_pUpper_folder) {
+ free(ugd->ug_Status.ug_pUpper_folder);
+ ugd->ug_Status.ug_pUpper_folder = NULL;
+ }
+
+ UG_TRACE_END;
+
+}
+
+
+/******************************
+** Prototype : __mf_ug_main_free_evas_object
+** Description : Samsung
+** Input : void *data
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+static void __mf_ug_main_free_evas_object(void *data)
+{
+
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+ ug_mf_retm_if(ugd == NULL, "ugData is NULL");
+
+ int iNaviListLen = 0;
+ int index = 0;
+
+ if (ugd->ug_MainWindow.ug_pNormalPopup != NULL) {
+
+ evas_object_del(ugd->ug_MainWindow.ug_pNormalPopup);
+ ugd->ug_MainWindow.ug_pNormalPopup = NULL;
+ }
+ if (ugd->ug_MainWindow.ug_pRadioGroup != NULL) {
+
+ evas_object_del(ugd->ug_MainWindow.ug_pRadioGroup);
+ ugd->ug_MainWindow.ug_pRadioGroup = NULL;
+ }
+
+ iNaviListLen = eina_list_count(ugd->ug_MainWindow.ug_pNaviBarList);
+ for (index = 0; index < iNaviListLen; index++) {
+ ugNaviBar *pNavi_s = NULL;
+ pNavi_s = (ugNaviBar *)eina_list_nth(ugd->ug_MainWindow.ug_pNaviBarList, index);
+ evas_object_del(pNavi_s->ug_pNaviCtrlBar);
+ evas_object_del(pNavi_s->ug_pContent);
+ evas_object_del(pNavi_s->ug_pNaviLayout);
+ evas_object_del(pNavi_s->ug_pNaviBox);
+ evas_object_del(pNavi_s->ug_pNaviBar);
+ if (pNavi_s->ug_pNaviLabel != NULL) {
+ free(pNavi_s->ug_pNaviLabel);
+ pNavi_s->ug_pNaviLabel = NULL;
+ }
+ if (pNavi_s->ug_pNaviTitle != NULL) {
+ free(pNavi_s->ug_pNaviTitle);
+ pNavi_s->ug_pNaviTitle = NULL;
+ }
+ }
+
+ if (ugd->ug_MainWindow.ug_pTabBar != NULL) {
+ mf_ug_tab_bar_remove_all_items(ugd->ug_MainWindow.ug_pTabBar);
+ evas_object_del(ugd->ug_MainWindow.ug_pTabBar);
+ ugd->ug_MainWindow.ug_pTabBar = NULL;
+ }
+
+ if (ugd->ug_MainWindow.ug_pTabBackGround != NULL) {
+ evas_object_del(ugd->ug_MainWindow.ug_pTabBackGround);
+ ugd->ug_MainWindow.ug_pTabBackGround = NULL;
+ }
+ if (ugd->ug_MainWindow.ug_pTabLayout != NULL) {
+ evas_object_del(ugd->ug_MainWindow.ug_pTabLayout);
+ ugd->ug_MainWindow.ug_pTabLayout = NULL;
+ }
+
+ if (ugd->ug_MainWindow.ug_pBackGround != NULL) {
+ evas_object_del(ugd->ug_MainWindow.ug_pBackGround);
+ ugd->ug_MainWindow.ug_pBackGround = NULL;
+ }
+
+ if (ugd->ug_MainWindow.ug_pMainLayout != NULL) {
+ evas_object_del(ugd->ug_MainWindow.ug_pMainLayout);
+ ugd->ug_MainWindow.ug_pMainLayout = NULL;
+ }
+ UG_TRACE_END;
+}
+
+Evas_Object *mf_ug_main_create_bg(Evas_Object *win)
+{
+ ug_mf_retv_if(win == NULL, NULL);
+ Evas_Object *bg = elm_bg_add(win);
+
+ evas_object_size_hint_weight_set(bg, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
+ evas_object_size_hint_align_set(bg, EVAS_HINT_FILL, EVAS_HINT_FILL);
+ elm_win_resize_object_add(win, bg);
+ evas_object_show(bg);
+
+ return bg;
+}
+
+/******************************
+** Prototype : _ug_mf_create_layout_main
+** Description :
+** Input : Evas_Object* parent
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+static Evas_Object *__mf_ug_main_create_main_layout(Evas_Object *parent)
+{
+ UG_TRACE_BEGIN;
+ Evas_Object *layout = NULL;
+ ug_mf_retvm_if(parent == NULL, NULL, "parent is NULL");
+
+ layout = elm_layout_add(parent);
+ ug_mf_retvm_if(layout == NULL, NULL, "Failed elm_layout_add.\n");
+
+ elm_layout_theme_set(layout, "layout", "application", "default");
+ 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);
+ elm_win_resize_object_add(parent, layout);
+ evas_object_show(layout);
+ UG_TRACE_END;
+
+ return layout;
+}
+
+Evas_Object *mf_ug_main_tab_layout_create(Evas_Object *parent)
+{
+ Evas_Object *layout;
+
+ ug_mf_retv_if(parent == NULL, NULL);
+
+ layout = elm_layout_add(parent);
+ ug_mf_retvm_if(layout == NULL, NULL, "Failed elm_layout_add.\n");
+ elm_object_focus_set(layout, EINA_FALSE);
+
+ //elm_layout_theme_set(layout, "layout", "application", "tabbar");
+ elm_layout_theme_set(layout, "layout", "tabbar", "default");
+
+ evas_object_size_hint_weight_set(layout, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
+
+ evas_object_hide(layout);
+ return layout;
+}
+
+/******************************
+** Prototype : __mf_ug_main_set_path_option
+** Description : Samsung
+** Input : void *data
+** char *path
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+static int __mf_ug_main_set_path_option(void *data, const char *path)
+{
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+ ug_mf_retvm_if(ugd == NULL, MYFILE_ERR_SRC_ARG_INVALID, "ugd is NULL");
+ ug_mf_retvm_if(path == NULL, MYFILE_ERR_SRC_ARG_INVALID, "path is NULL");
+
+ int error_code = MYFILE_ERR_NONE;
+ char *entry_path = NULL;
+
+ if (strncmp(path, PHONE_FOLDER, strlen(PHONE_FOLDER)) == 0 || strncmp(path, MEMORY_FOLDER, strlen(MEMORY_FOLDER)) == 0) {
+
+ /**check whether is /opt/media or /mnt/mmc */
+ entry_path = strdup(path);
+ if (entry_path == NULL) {
+ return MYFILE_ERR_ALLOCATE_FAIL;
+ }
+ } else if (strncmp(path, UG_SETTING_RINGTONE_PATH, strlen(UG_SETTING_RINGTONE_PATH)) == 0
+ || strncmp(path, UG_SETTING_ALERTS_PATH, strlen(UG_SETTING_ALERTS_PATH)) == 0) {
+
+ /**check whether is setting ringtone or alerts path */
+ entry_path = strdup(path);
+ if (entry_path == NULL) {
+ return MYFILE_ERR_ALLOCATE_FAIL;
+ }
+ ugd->ug_Status.ug_bInSettingView = true;
+ ugd->ug_Status.ug_bSettingEntry = true;
+ } else if (strlen(path) == 1 && strncmp(path, "/", 1)) {
+ /**chech the path whether is "/" */
+ entry_path = strdup(PHONE_FOLDER);
+ if (entry_path == NULL) {
+ return MYFILE_ERR_ALLOCATE_FAIL;
+ }
+ } else {
+ /**not begin with /mnt/mmc and /opt/media , so append it to /opt/media*/
+ char *temp = strdup(PHONE_FOLDER);
+ if (temp == NULL) {
+ return MYFILE_ERR_ALLOCATE_FAIL;
+ }
+ entry_path = g_strconcat(temp, path, NULL);
+ free(temp);
+ }
+
+ if (entry_path != NULL) {
+ /** if there is a '/' at the end of the path, can't be recognized */
+ if (entry_path[strlen(entry_path) - 1] == '/') {
+ entry_path[strlen(entry_path) - 1] = '\0';
+ }
+
+ if (ecore_file_exists(entry_path) == false) {
+ ug_mf_debug("path is not exist");
+ free(entry_path);
+ return MYFILE_ERR_INVALID_FILE_PATH;
+ }
+ if (ecore_file_is_dir(entry_path) == false) {
+ ug_mf_debug("path is not a directory");
+ free(entry_path);
+ return MYFILE_ERR_INVALID_DIR_PATH;
+ }
+
+ if (ugd->ug_Status.ug_pPath) {
+ g_string_free(ugd->ug_Status.ug_pPath, TRUE);
+ ugd->ug_Status.ug_pPath = NULL;
+ }
+ ugd->ug_Status.ug_pPath = g_string_new(entry_path);
+ free(entry_path);
+ } else {
+ return MYFILE_ERR_ALLOCATE_FAIL;
+ }
+ UG_TRACE_END;
+ return error_code;
+}
+
+
+/******************************
+** Prototype : __mf_ug_main_set_select_mode
+** Description : Samsung
+** Input : void *data
+** char *select_mode
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+
+static void __mf_ug_main_set_select_mode(void *data, const char *select_mode)
+{
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+ ug_mf_retm_if(ugd == NULL, "ugd is NULL");
+
+ if (select_mode != NULL) {
+ if (!strncmp(select_mode, UG_SELECT_MODE_SINGLE_FILE, strlen(select_mode))) {
+ ugd->ug_UiGadget.ug_iSelectMode = SINGLE_FILE_MODE;
+ } else if (!strncmp(select_mode, UG_SELECT_MODE_MULTI_FILE, strlen(select_mode))) {
+ ugd->ug_UiGadget.ug_iSelectMode = MULTI_FILE_MODE;
+ } else if (!strncmp(select_mode, UG_SELECT_MODE_SINGLE_ALL, strlen(select_mode))) {
+
+ ugd->ug_UiGadget.ug_iSelectMode = SINGLE_ALL_MODE;
+ }
+
+ else if (!strncmp(select_mode, UG_SELECT_MODE_MULTI_ALL, strlen(select_mode))) {
+
+ ugd->ug_UiGadget.ug_iSelectMode = MULTI_ALL_MODE;
+ } else {
+ ugd->ug_UiGadget.ug_iSelectMode = SINGLE_FILE_MODE;
+ }
+ } else {
+ ugd->ug_UiGadget.ug_iSelectMode = SINGLE_FILE_MODE;
+ }
+ UG_TRACE_END;
+
+}
+
+
+
+/******************************
+** Prototype : __mf_ug_main_set_filter_mode
+** Description : Samsung
+** Input : void *data
+** char *file_filter
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+
+static void __mf_ug_main_set_filter_mode(void *data, const char *file_filter)
+{
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+ ug_mf_retm_if(ugd == NULL, "ugd is NULL");
+
+ if (file_filter != NULL) {
+ if (!strncmp(file_filter, UG_FILE_FILTER_ALL, strlen(file_filter))) {
+ ugd->ug_UiGadget.ug_iFilterMode = SHOW_ALL_LIST;
+ } else if (!strncmp(file_filter, UG_FILE_FILTER_IMAGE, strlen(file_filter))) {
+ ugd->ug_UiGadget.ug_iFilterMode = SHOW_IMAGE_LIST;
+ } else if (!strncmp(file_filter, UG_FILE_FILTER_SOUND, strlen(file_filter))) {
+ ugd->ug_UiGadget.ug_iFilterMode = SHOW_SOUND_LIST;
+ } else if (!strncmp(file_filter, UG_FILE_FILTER_VIDEO, strlen(file_filter))) {
+ ugd->ug_UiGadget.ug_iFilterMode = SHOW_VIDEO_LIST;
+ } else if (!strncmp(file_filter, UG_FILE_FILTER_FLASH, strlen(file_filter))) {
+ ugd->ug_UiGadget.ug_iFilterMode = SHOW_FLASH_LIST;
+ } else if (!strncmp(file_filter, UG_FILE_FILTER_FOLDER, strlen(file_filter))) {
+ ugd->ug_UiGadget.ug_iFilterMode = SHOW_FOLDER_LIST;
+ } else if (!strncmp(file_filter, UG_FILE_FILTER_IV, strlen(file_filter))) {
+ ugd->ug_UiGadget.ug_iFilterMode = SHOW_IMAGE_VIDEO_LIST;
+ } else if (!strncmp(file_filter, UG_FILE_FILTER_IS, strlen(file_filter))) {
+ ugd->ug_UiGadget.ug_iFilterMode = SHOW_IMAGE_SOUND_LIST;
+ } else if (!strncmp(file_filter, UG_FILE_FILTER_VS, strlen(file_filter))) {
+ ugd->ug_UiGadget.ug_iFilterMode = SHOW_VIDEO_SOUND_LIST;
+ } else {
+ ugd->ug_UiGadget.ug_iFilterMode = SHOW_BY_EXTENSION;
+ ugd->ug_UiGadget.ug_pExtension = strdup(file_filter);
+ }
+ } else {
+ ugd->ug_UiGadget.ug_iFilterMode = SHOW_ALL_LIST;
+ ugd->ug_UiGadget.ug_pExtension = NULL;
+ }
+
+ if (ugd->ug_UiGadget.ug_iFilterMode != SHOW_BY_EXTENSION) {
+ ugd->ug_UiGadget.ug_iFileFilter = mf_ug_fm_svc_wapper_get_file_filter(ugd->ug_UiGadget.ug_iFilterMode);
+ }
+
+
+ if (ugd->ug_UiGadget.ug_iFilterMode == SHOW_SOUND_LIST && ugd->ug_UiGadget.ug_iSelectMode == SINGLE_FILE_MODE) {
+ ugd->ug_Status.ug_iCtrlBarType = CTRL_BAR_MUSIC;
+ } else {
+ ugd->ug_Status.ug_iCtrlBarType = CTRL_BAR_MULTI;
+ }
+ UG_TRACE_END;
+}
+
+
+
+/******************************
+** Prototype : __mf_ug_main_set_marked_mode
+** Description : Samsung
+** Input : void *data
+** char *marked_mode
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+
+static void __mf_ug_main_set_marked_mode(void *data, const char *marked_mode)
+{
+
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+ ug_mf_retm_if(ugd == NULL, "ugd is NULL");
+
+ if (marked_mode != NULL) {
+ ugd->ug_UiGadget.ug_iMarkedMode = MARKED_ON;
+ mf_ug_util_get_params_path(&ugd->ug_UiGadget.ug_pMultiSelectFileList, marked_mode);
+ } else {
+ ugd->ug_UiGadget.ug_iMarkedMode = MARKED_OFF;
+ }
+ UG_TRACE_END;
+}
+
+
+/******************************
+** Prototype : __mf_ug_main_set_option_status
+** Description : Samsung
+** Input : void *data
+** bundle *option
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+
+static void __mf_ug_main_set_option_status(void *data, bundle * option)
+{
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+ ug_mf_retm_if(ugd == NULL, "ugd is NULL");
+ ug_mf_retm_if(option == NULL, "option is NULL");
+ char *key[UG_OPTION_COUNT] = { "path", "select_type", "file_type", "marked_mode"};
+ const char *path = NULL, *select_mode = NULL, *filter_mode = NULL, *marked_mode = NULL;
+
+ path = bundle_get_val(option, key[0]);
+ select_mode = bundle_get_val(option, key[1]);
+ filter_mode = bundle_get_val(option, key[2]);
+ marked_mode = bundle_get_val(option, key[3]);
+
+ __mf_ug_main_set_path_option(ugd, path);
+ __mf_ug_main_set_select_mode(ugd, select_mode);
+ __mf_ug_main_set_filter_mode(ugd, filter_mode);
+ __mf_ug_main_set_marked_mode(ugd, marked_mode);
+ UG_TRACE_END;
+}
+
+/******************************
+** Prototype : __mf_ug_main_create_default_layout
+** Description : Samsung
+** Input : Evas_Object* parent
+** void* data
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+static Evas_Object *__mf_ug_main_create_default_layout(Evas_Object *parent, void *data)
+{
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+ ug_mf_retvm_if(ugd == NULL, NULL, "ugd is NULL");
+ ug_mf_retvm_if(parent == NULL, NULL, "parent is NULL");
+ Elm_Object_Item *pItemPhone = NULL;
+ Elm_Object_Item *pItemMMC = NULL;
+ Evas_Object *pContent = NULL;
+ int tab_item_count = 1;
+
+ int mmc_card = 0;
+ int error_code = 0;
+ /*/check if mmc mounted */
+ error_code = mf_ug_util_get_mmc_state(&mmc_card);
+ if (error_code == 0 && mmc_card == 1) {
+ tab_item_count++;
+ }
+ /*/check if usb otg mounted
+ {
+ Todo: we need to add something to record what should on
+ }
+ create phone navi */
+ ugNaviBar *pNavi_phone = calloc(1, sizeof(ugNaviBar));
+ ug_mf_retvm_if(pNavi_phone == NULL, NULL, "pNavi_phone is NULL");
+
+ pNavi_phone->ug_pNaviBar = mf_ug_navi_bar_create_navi_bar(parent);
+ if (pNavi_phone->ug_pNaviBar == NULL) {
+ ug_debug("pNavi_phone->ug_pNaviBar is NULL");
+ free(pNavi_phone);
+ pNavi_phone = NULL;
+ UG_TRACE_END;
+ return NULL;
+ }
+
+ pNavi_phone->ug_bNaviFlagInUse = TRUE;
+
+ UG_SAFE_FREE_CHAR(pNavi_phone->ug_pCurrentPath);
+ pNavi_phone->ug_pCurrentPath = g_strdup(ugd->ug_Status.ug_pPath->str);
+
+ UG_SAFE_FREE_CHAR(pNavi_phone->ug_pNaviLabel);
+ pNavi_phone->ug_pNaviLabel = strdup(MF_UG_LABEL_PHONE);
+ /*/insert phone navi into the navi_list */
+ /** Todo: if we need to check ap->mf_MainWindow.plistNaviBar?*/
+ ugd->ug_MainWindow.ug_pNaviBarList = eina_list_append(ugd->ug_MainWindow.ug_pNaviBarList, pNavi_phone);
+
+ if (tab_item_count > 1 && !ugd->ug_Status.ug_bSettingEntry) {
+ /*create tab bar */
+ if (ugd->ug_MainWindow.ug_pTabLayout == NULL) {
+ ugd->ug_MainWindow.ug_pTabLayout = mf_ug_main_tab_layout_create(ugd->ug_MainWindow.ug_pWindow);
+ }
+ ugd->ug_MainWindow.ug_pTabBar = mf_ug_tab_bar_create(ugd->ug_MainWindow.ug_pWindow);
+ pContent = ugd->ug_MainWindow.ug_pTabBar;
+ pItemPhone =
+ mf_ug_tab_bar_append_item(pContent, UG_ICON_PHONE, MF_UG_LABEL_PHONE, ugd);
+ pItemMMC = mf_ug_tab_bar_append_item(pContent, UG_ICON_MEMORY, MF_UG_LABEL_MMC, ugd);
+
+ //mf_ug_tab_bar_set_selected_item(pItemPhone);
+ }
+ UG_TRACE_END;
+ return pNavi_phone->ug_pNaviBar;
+}
+
+/******************************
+** Prototype : __mf_ug_main_start
+** Description :
+** Input : void *data
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+
+static void __mf_ug_main_start(void *data)
+{
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+ ug_mf_retm_if(ugd == NULL, "ugd is NULL");
+ Evas_Object *pContent = NULL;
+ int error_code = 0;
+ int mmc_card = 0;
+
+ pContent = __mf_ug_main_create_default_layout(ugd->ug_MainWindow.ug_pMainLayout, ugd);
+
+ if (pContent != NULL) {
+ error_code = mf_ug_util_get_mmc_state(&mmc_card);
+ if (error_code == 0 && mmc_card == 1) {
+ ug_debug(" mmc is inserted");
+ ugd->ug_Status.ug_iMmcFlag = MMC_ON;
+ if (ugd->ug_Status.ug_bSettingEntry) {
+ ug_debug(" entry from setting sounds");
+ elm_object_part_content_set(ugd->ug_MainWindow.ug_pMainLayout, "elm.swallow.content", pContent);
+ } else {
+ ug_debug(" not entry from setting sounds");
+ evas_object_show(ugd->ug_MainWindow.ug_pTabLayout);
+ elm_object_part_content_set(ugd->ug_MainWindow.ug_pTabLayout, "elm.swallow.content", pContent);
+ elm_object_part_content_set(ugd->ug_MainWindow.ug_pTabLayout, "elm.swallow.tabbar", ugd->ug_MainWindow.ug_pTabBar);
+ elm_object_part_content_set(ugd->ug_MainWindow.ug_pMainLayout, "elm.swallow.content", ugd->ug_MainWindow.ug_pTabLayout);
+ }
+ } else {
+ ug_debug(" mmc is not inserted");
+ elm_object_part_content_set(ugd->ug_MainWindow.ug_pMainLayout, "elm.swallow.content", pContent);
+ }
+
+ mf_ug_navi_bar_create_default_view(ugd);
+ mf_ug_ctrl_bar_set_item_disable(ugd);
+ if (ugd->ug_Status.ug_bMassStorageFlag && ugd->ug_MainWindow.ug_pTabBar) {
+ mf_ug_tab_bar_set_item_disable(ugd->ug_MainWindow.ug_pTabBar, EINA_TRUE);
+ mf_ug_ctrl_bar_disable_item(ugd, true);
+ }
+
+ mf_ug_navi_bar_set_blocking(data, false);
+ } else {
+ return;
+ }
+ ug_debug("done");
+ UG_TRACE_END;
+
+ return;
+}
+
+
+
+/******************************
+** Prototype : on_create
+** Description : Samsung
+** Input : struct ui_gadget *ug
+** enum ug_mode mode
+** bundle *data
+** void *priv
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+
+static void *on_create(struct ui_gadget *ug, enum ug_mode mode, bundle * data, void *priv)
+{
+ UG_TRACE_BEGIN;
+
+ Evas_Object *win = NULL;
+ ugData *ugd = NULL;
+
+ ug_mf_retv_if(NULL == ug, NULL);
+ ug_mf_retv_if(NULL == priv, NULL);
+
+ ugd = priv;
+ ugd->ug = ug;
+
+ bindtextdomain(UGPACKAGE, UGLOCALEDIR);
+
+ win = (Evas_Object *)ug_get_window();
+ ug_mf_retv_if(NULL == win, NULL);
+
+ ugd->ug_MainWindow.ug_pWindow = win;
+ ugd->ug_Status.ug_bInstallFlag = false;
+ ugd->ug_Status.ug_bMassStorageFlag = false;
+ ugd->ug_Status.ug_bCancelDisableFlag = false;
+ ugd->ug_MainWindow.ug_pMainLayout = __mf_ug_main_create_main_layout(ugd->ug_MainWindow.ug_pWindow);
+ ugd->ug_MainWindow.ug_pTabLayout = mf_ug_main_tab_layout_create(ugd->ug_MainWindow.ug_pWindow);
+ ugd->ug_MainWindow.ug_pBackGround = mf_ug_main_create_bg(ugd->ug_MainWindow.ug_pWindow);
+ elm_object_part_content_set(ugd->ug_MainWindow.ug_pMainLayout, "elm.swallow.bg", ugd->ug_MainWindow.ug_pBackGround);
+
+ bool usb_state = mf_ug_util_is_mass_storage_on();
+
+#ifndef UG_LAUNCH_AT_MASS_STORAGE_MODE
+ if (usb_state) {
+ mf_ug_popup_create(ugd, UG_POPMODE_TEXT, NULL, ("Please use after turn off mass storage mode"), NULL, NULL, NULL,
+ (Evas_Smart_Cb) mf_ug_cb_mass_storage_popup_cb, ugd);
+ elm_object_style_set(ugd->ug_MainWindow.ug_pBackGround, "transparent");
+ UG_TRACE_END;
+ return (void *)ugd->ug_MainWindow.ug_pMainLayout;
+ } else
+#else
+ ug_debug();
+ if (usb_state) {
+ ugd->ug_Status.ug_bMassStorageFlag = true;
+ }
+#endif
+ {
+ __mf_ug_main_init_data(ugd);
+ __mf_ug_main_set_option_status(ugd, data);
+ media_svc_connect(&ugd->ug_Status.ug_pMedia_svc_handle);
+
+ __mf_ug_main_start(ugd);
+ UG_TRACE_END;
+ return ugd->ug_MainWindow.ug_pMainLayout;
+ }
+}
+
+/******************************
+** Prototype : on_start
+** Description :
+** Input : struct ui_gadget *ug
+** bundle *data
+** void *priv
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+static void on_start(struct ui_gadget *ug, bundle * data, void *priv)
+{
+}
+
+
+/******************************
+** Prototype : on_pause
+** Description :
+** Input : struct ui_gadget *ug
+** bundle *data
+** void *priv
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+static void on_pause(struct ui_gadget *ug, bundle * data, void *priv)
+{
+ if (!priv)
+ return;
+ ugData *ugd = (ugData *)priv;
+
+ if (0 != ugd->ug_ListPlay.ug_Player) {
+ mf_ug_list_play_destory_playing_file(ugd);
+ }
+}
+
+/******************************
+** Prototype : on_resume
+** Description :
+** Input : struct ui_gadget *ug
+** bundle *data
+** void *priv
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+inline bool __mf_ug_main_check_exist(const char *path)
+{
+ if (path && (access(path, F_OK) == 0)) {
+ return true;
+ }
+ return false;
+}
+
+static void on_resume(struct ui_gadget *ug, bundle * data, void *priv)
+{
+ UG_TRACE_BEGIN;
+ ug_mf_retm_if(NULL == priv, "priv is NULL");
+ ugData *ugd = priv;
+
+ if (!__mf_ug_main_check_exist(ugd->ug_Status.ug_pPath->str)) {
+ ugNaviBar *pNavi_s = mf_ug_navi_bar_get_in_use_navi(ugd);
+ GString *parent_path = mf_ug_fm_svc_wrapper_get_file_parent_path(ugd->ug_Status.ug_pPath);
+ int storage = mf_ug_fm_svc_wapper_get_location(ugd->ug_Status.ug_pPath->str);
+
+ g_string_free(ugd->ug_Status.ug_pPath, TRUE);
+ ugd->ug_Status.ug_pPath = NULL;
+ free(pNavi_s->ug_pCurrentPath);
+ pNavi_s->ug_pCurrentPath = NULL;
+
+ if (parent_path && parent_path->str) {
+ if (__mf_ug_main_check_exist(parent_path->str)) {
+ ug_debug("paretn is [%s] exit", parent_path->str);
+ ugd->ug_Status.ug_pPath = g_string_new(parent_path->str);
+ pNavi_s->ug_pCurrentPath = g_strdup(parent_path->str);
+ } else {
+ ug_debug("paretn is [%s] not exit", parent_path->str);
+ if (storage == MF_UG_PHONE) {
+ ugd->ug_Status.ug_pPath = g_string_new(PHONE_FOLDER);
+ pNavi_s->ug_pCurrentPath = strdup(PHONE_FOLDER);
+ } else {
+ ugd->ug_Status.ug_pPath = g_string_new(MEMORY_FOLDER);
+ pNavi_s->ug_pCurrentPath = strdup(MEMORY_FOLDER);
+ }
+ }
+ } else {
+ ug_debug("get parent failed");
+ if (storage == MF_UG_PHONE) {
+ ugd->ug_Status.ug_pPath = g_string_new(PHONE_FOLDER);
+ pNavi_s->ug_pCurrentPath = strdup(PHONE_FOLDER);
+ } else {
+ ugd->ug_Status.ug_pPath = g_string_new(MEMORY_FOLDER);
+ pNavi_s->ug_pCurrentPath = strdup(MEMORY_FOLDER);
+ }
+ }
+
+ mf_ug_navi_bar_create_default_view(ugd);
+ mf_ug_ctrl_bar_set_item_disable(ugd);
+ g_string_free(parent_path, TRUE);
+ parent_path = NULL;
+ }
+
+ UG_TRACE_END;
+}
+
+/******************************
+** Prototype : on_message
+** Description :
+** Input : struct ui_gadget *ug
+** bundle *msg
+** bundle *data
+** void *priv
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+static void on_message(struct ui_gadget *ug, bundle * msg, bundle * data, void *priv)
+{
+}
+
+/******************************
+** Prototype : on_event
+** Description :
+** Input : struct ui_gadget *ug
+** enum ug_event event
+** bundle *data
+** void *priv
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+static void on_event(struct ui_gadget *ug, enum ug_event event, bundle * data, void *priv)
+{
+ UG_TRACE_BEGIN;
+ switch (event) {
+ case UG_EVENT_LOW_MEMORY:
+ break;
+
+ case UG_EVENT_LOW_BATTERY:
+ break;
+
+ case UG_EVENT_LANG_CHANGE:
+ break;
+
+ case UG_EVENT_ROTATE_PORTRAIT:
+ break;
+
+ case UG_EVENT_ROTATE_PORTRAIT_UPSIDEDOWN:
+ break;
+
+ case UG_EVENT_ROTATE_LANDSCAPE:
+ break;
+
+ case UG_EVENT_ROTATE_LANDSCAPE_UPSIDEDOWN:
+ break;
+
+ default:
+ break;
+ }
+ UG_TRACE_END;
+}
+
+
+
+/******************************
+** Prototype : on_key_event
+** Description : Samsung
+** Input : struct ui_gadget *ug
+** enum ug_key_event event
+** bundle *data
+** void *priv
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+
+static void on_key_event(struct ui_gadget *ug, enum ug_key_event event, bundle * data, void *priv)
+{
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)priv;
+ ug_mf_retm_if(ugd == NULL, "ugd is NULL");
+
+ switch (event) {
+ case UG_KEY_EVENT_END:
+ if (ugd->ug_MainWindow.ug_pNormalPopup) {
+ evas_object_del(ugd->ug_MainWindow.ug_pNormalPopup);
+ ugd->ug_MainWindow.ug_pNormalPopup = NULL;
+ }
+ if (0 != ugd->ug_ListPlay.ug_Player) {
+ mf_ug_list_play_destory_playing_file(ugd);
+ }
+ ug_destroy_me(ug);
+ break;
+ default:
+ break;
+ }
+ UG_TRACE_END;
+}
+
+/******************************
+** Prototype : on_destroy
+** Description :
+** Input : struct ui_gadget *ug
+** bundle *data
+** void *priv
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+static void on_destroy(struct ui_gadget *ug, bundle * data, void *priv)
+{
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)priv;
+ ug_mf_retm_if(ugd == NULL, "ugd is NULL");
+
+ __mf_ug_main_free_data(ugd);
+
+ if (ugd->ug_Status.ug_bInstallFlag == true) {
+ mf_ug_util_destory_dir_monitor(ugd);
+ mf_ug_util_destory_mmc_state_cb();
+ media_svc_disconnect(ugd->ug_Status.ug_pMedia_svc_handle);
+ mf_ug_util_destory_mass_storage_callback();
+ }
+
+ if (0 != ugd->ug_ListPlay.ug_Player) {
+ mf_ug_list_play_destory_playing_file(ugd);
+ }
+ if (ugd->ug_Status.ug_pThumbUpdateTimer != NULL) {
+ ecore_timer_del(ugd->ug_Status.ug_pThumbUpdateTimer);
+ ugd->ug_Status.ug_pThumbUpdateTimer = NULL;
+ }
+ __mf_ug_main_free_evas_object(ugd);
+ UG_TRACE_END;
+}
+
+
+/******************************
+** Prototype : UG_MODULE_INIT
+** Description :
+** Input : struct ug_module_ops *ops
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+UG_MODULE_API int UG_MODULE_INIT(struct ug_module_ops *ops)
+{
+ UG_TRACE_BEGIN;
+ ugData *ugd;
+
+ if (!ops) {
+ return -1;
+ }
+
+ ugd = calloc(1, sizeof(ugData));
+ if (!ugd) {
+ return -1;
+ }
+
+ ops->create = on_create;
+ ops->start = on_start;
+ ops->pause = on_pause;
+ ops->resume = on_resume;
+ ops->destroy = on_destroy;
+ ops->message = on_message;
+ ops->event = on_event;
+ ops->key_event = on_key_event;
+ ops->priv = ugd;
+ ops->opt = UG_OPT_INDICATOR_ENABLE;
+ UG_TRACE_END;
+ return 0;
+}
+
+
+
+/******************************
+** Prototype : UG_MODULE_EXIT
+** Description :
+** Input : struct ug_module_ops *ops
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+UG_MODULE_API void UG_MODULE_EXIT(struct ug_module_ops *ops)
+{
+ UG_TRACE_BEGIN;
+ ugData *ugd;
+
+ if (!ops) {
+ return;
+ }
+ ugd = ops->priv;
+
+ if (ugd) {
+ free(ugd);
+ }
+ UG_TRACE_END;
+}
diff --git a/src/widget/mf-ug-ctrl-bar.c b/src/widget/mf-ug-ctrl-bar.c
new file mode 100755
index 0000000..969d804
--- /dev/null
+++ b/src/widget/mf-ug-ctrl-bar.c
@@ -0,0 +1,277 @@
+/*
+ * Copyright 2012 Samsung Electronics Co., Ltd
+ *
+ * Licensed under the Flora License, Version 1.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.tizenopensource.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 <Eina.h>
+#include <Elementary.h>
+
+#include "mf-ug-winset.h"
+#include "mf-ug-cb.h"
+#include "mf-ug-fm-svc-wrapper.h"
+#include "mf-ug-util.h"
+#include "mf-ug-resource.h"
+
+#define UG_CTRL_STYLE_TYPE "controlbar"
+
+/******************************
+** Prototype : __mf_ug_ctrl_bar_create
+** Description : Samsung
+** Input : Evas_Object *parent
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+static Evas_Object *__mf_ug_ctrl_bar_create(Evas_Object *parent)
+{
+ UG_TRACE_BEGIN;
+ ug_mf_retvm_if(parent == NULL, NULL, "parent is NULL");
+
+ Evas_Object *pCtrlBar = NULL;
+ pCtrlBar = elm_toolbar_add(parent);
+ elm_toolbar_shrink_mode_set(pCtrlBar, ELM_TOOLBAR_SHRINK_EXPAND);
+ elm_object_style_set(pCtrlBar, "naviframe");
+ elm_toolbar_homogeneous_set(pCtrlBar, EINA_TRUE);
+ evas_object_show(pCtrlBar);
+
+ UG_TRACE_END;
+ return pCtrlBar;
+}
+
+/******************************
+** Prototype : __mf_ug_ctrl_bar_create_button
+** Description : Samsung
+** Input : Evas_Object *parent
+** eCtrlBarButtonType type
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+#ifndef MF_UG_FEATURE_NEW_UX
+static Evas_Object *__mf_ug_ctrl_bar_create_button(Evas_Object *parent, eCtrlBarButtonType type)
+{
+ ug_mf_retvm_if(parent == NULL, NULL, "parent is NULL");
+ Evas_Object *button = NULL;
+
+
+ button = elm_button_add(parent);
+
+ evas_object_size_hint_weight_set(button, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
+ evas_object_size_hint_align_set(button, EVAS_HINT_FILL, 0.5);
+ elm_object_style_set(button, "naviframe_control/multiline");
+
+
+ switch (type) {
+ case CTRL_BUTTON_CANCEL:
+ elm_object_text_set(button, MF_UG_LABEL_CANCEL);
+ break;
+ case CTRL_BUTTON_ADD:
+ elm_object_text_set(button, MF_UG_LABEL_SET);
+ break;
+ case CTRL_BUTTON_DONE:
+ elm_object_text_set(button, MF_UG_LABEL_ATTACH);
+ break;
+ default:
+ break;
+ }
+
+ evas_object_show(button);
+ UG_TRACE_END;
+ return button;
+}
+#endif
+
+/******************************
+** Prototype : __mf_ug_ctrl_bar_append_item
+** Description : Samsung
+** Input : void *data
+** Evas_Object *ctrl_bar
+** int type
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+static void __mf_ug_ctrl_bar_append_item(void *data, Evas_Object *ctrl_bar, int type)
+{
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+ ug_mf_retm_if(ugd == NULL, "ugd is NULL");
+ Evas_Object *pCtrlBar = ctrl_bar;
+ ug_mf_retm_if(pCtrlBar == NULL, "pCtrlBar is NULL");
+
+ if (ugd->ug_UiGadget.ug_iSelectMode == SINGLE_ALL_MODE || ugd->ug_UiGadget.ug_iSelectMode == SINGLE_FILE_MODE)
+ elm_toolbar_item_append(pCtrlBar, NULL, MF_UG_LABEL_SET, (Evas_Smart_Cb) mf_ug_cb_add_button_cb, ugd);
+ else
+ elm_toolbar_item_append(pCtrlBar, NULL, MF_UG_LABEL_ATTACH, (Evas_Smart_Cb) mf_ug_cb_add_button_cb, ugd);
+
+ elm_toolbar_item_append(pCtrlBar, NULL, MF_UG_LABEL_CANCEL, (Evas_Smart_Cb) mf_ug_cb_back_button_cb, ugd);
+
+
+ UG_TRACE_END;
+}
+
+
+/******************************
+** Prototype : mf_ug_ctrl_bar_set
+** Description : Samsung
+** Input : void* data
+** ugNaviBar *pNavi_s
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+void mf_ug_ctrl_bar_set(void *data, ugNaviBar *pNavi_s)
+{
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+ ug_mf_retm_if(ugd == NULL, "ugd is NULL");
+
+ Evas_Object *pNaviBar = pNavi_s->ug_pNaviBar;
+ Evas_Object *pCtrlBar = NULL;
+
+ int type = ugd->ug_Status.ug_iCtrlBarType;
+ pCtrlBar = __mf_ug_ctrl_bar_create(pNaviBar);
+ pNavi_s->ug_pNaviCtrlBar = pCtrlBar;
+ type = CTRL_BAR_NORMAL;
+ __mf_ug_ctrl_bar_append_item(ugd, pCtrlBar, type);
+ evas_object_show(pCtrlBar);
+ elm_object_item_part_content_set(pNavi_s->ug_pNaviItem, UG_CTRL_STYLE_TYPE, pCtrlBar);
+ UG_TRACE_END;
+}
+
+/******************************
+** Prototype : mf_ug_ctrl_bar_disable_item
+** Description : Samsung
+** Input : void *data
+** bool disable
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+void mf_ug_ctrl_bar_disable_item(void *data, bool disable)
+{
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+ ug_mf_retm_if(ugd == NULL, "ugd is NULL");
+
+ Evas_Object *pCtrlBar = NULL;
+
+ ugNaviBar *pNavi_s = mf_ug_navi_bar_get_in_use_navi(ugd);
+ ug_mf_retm_if(pNavi_s == NULL, "get navigation bar in use failed");
+
+ pCtrlBar = pNavi_s->ug_pNaviCtrlBar;
+
+ Elm_Object_Item *it = NULL;
+ it = elm_toolbar_first_item_get(pCtrlBar);
+
+ while(it) {
+ const char *button_label = elm_object_item_text_get(it);
+ const char *disable_labe = NULL;
+ if (ugd->ug_UiGadget.ug_iSelectMode == SINGLE_ALL_MODE || ugd->ug_UiGadget.ug_iSelectMode == SINGLE_FILE_MODE)
+ disable_labe = MF_UG_LABEL_SET;
+ else
+ disable_labe = MF_UG_LABEL_ATTACH;
+ if (g_strcmp0(button_label, disable_labe) == 0) {
+ elm_object_item_disabled_set(it, !disable);
+ }
+ it = elm_toolbar_item_next_get(it);
+ }
+}
+
+
+/******************************
+** Prototype : mf_ug_ctrl_bar_set_item_disable
+** Description : Samsung
+** Input : void *data
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+void mf_ug_ctrl_bar_set_item_disable(void *data)
+{
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+ ug_mf_retm_if(ugd == NULL, "ugd is NULL");
+ bool disable = false;
+
+ if (ugd->ug_Status.ug_bNoContentFlag == true) {
+ mf_ug_ctrl_bar_disable_item(ugd, false);
+ } else {
+ disable = mf_ug_util_is_genlist_selected(ugd);
+
+ mf_ug_ctrl_bar_disable_item(ugd, disable);
+ }
+ UG_TRACE_END;
+}
+
+void mf_ug_ctrl_bar_recover(void *data)
+{
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+ ug_mf_retm_if(ugd == NULL, "ugd is NULL");
+
+ ugNaviBar *pNavi_s = mf_ug_navi_bar_get_in_use_navi(ugd);
+ ug_mf_retm_if(pNavi_s == NULL, "get navi failed");
+
+ Evas_Object *naviBar = pNavi_s->ug_pNaviBar;
+ Evas_Object *ctrl_bar = NULL;
+
+ ug_mf_retm_if(naviBar == NULL, "navi is NULL");
+ ctrl_bar = elm_object_item_part_content_get(pNavi_s->ug_pNaviItem, UG_CTRL_STYLE_TYPE);
+ pNavi_s->ug_pNaviCtrlBar = ctrl_bar;
+}
diff --git a/src/widget/mf-ug-genlist.c b/src/widget/mf-ug-genlist.c
new file mode 100755
index 0000000..ff3db4b
--- /dev/null
+++ b/src/widget/mf-ug-genlist.c
@@ -0,0 +1,1365 @@
+/*
+ * Copyright 2012 Samsung Electronics Co., Ltd
+ *
+ * Licensed under the Flora License, Version 1.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.tizenopensource.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 <Eina.h>
+#include "mf-ug-winset.h"
+#include "mf-ug-util.h"
+#include "mf-ug-fm-svc-wrapper.h"
+#include "mf-ug-fs-util.h"
+#include "mf-ug-resource.h"
+
+
+#define MF_UG_SELECTED_ITEM_BRING_UP_COUNT 7
+#define MF_UG_SELECTED_ITEM_BRING_UP_COUNT_MAX 8
+/******************************
+** Prototype : __mf_ug_genlist_is_file_marked
+** Description : Samsung
+** Input : Eina_List *source
+** GString *path
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+static gboolean __mf_ug_genlist_is_file_marked(Eina_List *source, GString *path)
+{
+ UG_TRACE_BEGIN;
+ ug_mf_retvm_if(source == NULL, false, "source is NULL");
+ ug_mf_retvm_if(path == NULL, false, "path is NULL");
+
+ bool flag = false;
+ Eina_List *l = NULL;
+ void *data = NULL;
+
+ EINA_LIST_FOREACH(source, l, data) {
+ char *source_path = strdup(data);
+ if (source_path != NULL) {
+ if (strcmp(source_path, path->str) == 0) {
+ flag = true;
+ free(source_path);
+ source_path = NULL;
+ break;
+ } else {
+ free(source_path);
+ source_path = NULL;
+ }
+ }
+ }
+ UG_TRACE_END;
+ return flag;
+}
+
+
+/******************************
+** Prototype : __mf_ug_genlist_set_marked_path
+** Description : Samsung
+** Input : Eina_List **source
+** GString *path
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+static void __mf_ug_genlist_set_marked_path(Eina_List **source, GString *path)
+{
+ UG_TRACE_BEGIN;
+ bool file_exist_flag = false;
+ char *source_path;
+ Eina_List *l = NULL;
+ void *data = NULL;
+
+ ug_mf_retm_if(source == NULL, "source is NULL");
+ ug_mf_retm_if(path == NULL, "path is NULL");
+
+ if (NULL == *source || eina_list_count(*source) == 0) {
+ *source = eina_list_append(*source, strdup(path->str));
+ } else {
+
+ EINA_LIST_FOREACH(*source, l, data) {
+ source_path = (char *)data;
+ if (source_path != NULL) {
+ if (strcmp(source_path, path->str) == 0) {
+ file_exist_flag = true;
+ break;
+ }
+ }
+ }
+ if (file_exist_flag == true) {
+ *source = eina_list_remove(*source, source_path);
+ } else {
+ *source = eina_list_append(*source, strdup(path->str));
+ }
+ }
+ UG_TRACE_END;
+}
+
+
+/******************************
+** Prototype : __mf_ug_genlist_create_checkbox
+** Description : Samsung
+** Input : Evas_Object *parent
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+static Evas_Object *__mf_ug_genlist_create_checkbox(Evas_Object *parent)
+{
+ UG_TRACE_BEGIN;
+ Evas_Object *ck_box = NULL;
+
+ ck_box = elm_check_add(parent);
+ evas_object_size_hint_weight_set(ck_box, 1.0, 1.0);
+ evas_object_size_hint_align_set(ck_box, -1.0, 0.5);
+ elm_check_state_set(ck_box, 0);
+ evas_object_show(ck_box);
+ evas_object_repeat_events_set(ck_box, 0);
+ UG_TRACE_END;
+ return ck_box;
+}
+
+static void __mf_ug_genlist_show_select_info(void *data)
+{
+ UG_TRACE_BEGIN;
+ ugListItemData *itemData = (ugListItemData *)data;
+ ug_mf_retm_if(itemData == NULL, "itemData is NULL");
+
+ ugData *ugd = itemData->ug_pData;
+ ug_mf_retm_if(ugd == NULL, "ugd is NULL");
+
+ int iDirCount = 0, iFileCount = 0;
+ Elm_Object_Item *it = NULL;
+
+ ugNaviBar *pNavi_s = mf_ug_navi_bar_get_in_use_navi(ugd);
+ Evas_Object *pGenlist = pNavi_s->ug_pContent;
+
+ it = elm_genlist_first_item_get(pGenlist);
+ while (it) {
+ itemData = elm_object_item_data_get(it);
+ if (itemData->ug_bChecked) {
+ if (ecore_file_is_dir(itemData->ug_pItemName->str)) {
+ iDirCount++;
+ } else {
+ iFileCount++;
+ }
+ }
+
+ it = elm_genlist_item_next_get(it);
+ }
+ mf_ug_navi_bar_set_select_info_label(itemData->ug_pData, iDirCount, iFileCount);
+ UG_TRACE_END;
+
+}
+
+/******************************
+** Prototype : __mf_ug_genlist_checkbox_cb
+** Description : Samsung
+** Input : void *data
+** Evas_Object *obj
+** void *event_info
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+static void __mf_ug_genlist_checkbox_cb(void *data, Evas_Object *obj, void *event_info)
+{
+ UG_TRACE_BEGIN;
+ ugListItemData *itemData = (ugListItemData *)data;
+ ug_mf_retm_if(itemData == NULL, "itemData is NULL");
+
+ if (itemData->ug_bChecked == false) {
+ itemData->ug_bChecked = true;
+ } else {
+ itemData->ug_bChecked = false;
+ }
+
+ if (itemData->ug_pData->ug_UiGadget.ug_iMarkedMode == MARKED_ON) {
+ __mf_ug_genlist_set_marked_path(&itemData->ug_pData->ug_UiGadget.ug_pMultiSelectFileList, itemData->ug_pItemName);
+ }
+
+ __mf_ug_genlist_show_select_info(itemData);
+ mf_ug_ctrl_bar_set_item_disable(itemData->ug_pData);
+
+ UG_TRACE_END;
+}
+
+
+/******************************
+** Prototype : __mf_ug_genlist_create_radio_box
+** Description : Samsung
+** Input : Evas_Object *parent
+** ugListItemData *params
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+static Evas_Object *__mf_ug_genlist_create_radio_box(Evas_Object *parent, ugListItemData *params)
+{
+ UG_TRACE_BEGIN;
+
+ ugListItemData *itemData = (ugListItemData *)params;
+ ug_mf_retvm_if(itemData == NULL, NULL, "itemData is NULL");
+
+ ugData *ugd = (ugData *)(itemData->ug_pData);
+ ug_mf_retvm_if(ugd == NULL, NULL, "ugd is NULL");
+
+ Evas_Object *radio_box = NULL;
+ radio_box = elm_radio_add(parent);
+ elm_radio_state_value_set(radio_box, itemData->ug_iGroupValue);
+ elm_radio_group_add(radio_box, ugd->ug_MainWindow.ug_pRadioGroup);
+ elm_radio_value_set(ugd->ug_MainWindow.ug_pRadioGroup, ugd->ug_Status.ug_iRadioOn);
+ UG_TRACE_END;
+ return radio_box;
+}
+
+
+
+/******************************
+** Prototype : __mf_ug_genlist_radio_box_cb
+** Description : Samsung
+** Input : void *data
+** Evas_Object *obj
+** void *event_info
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+static void __mf_ug_genlist_radio_box_cb(void *data, Evas_Object *obj, void *event_info)
+{
+
+ UG_TRACE_BEGIN;
+ ugListItemData *itemData = (ugListItemData *)data;
+ ug_mf_retm_if(itemData == NULL, "ugListItemData is NULL");
+
+ itemData->ug_bChecked = true;
+ itemData->ug_pData->ug_Status.ug_iRadioOn = itemData->ug_iGroupValue;
+ elm_radio_value_set(itemData->ug_pData->ug_MainWindow.ug_pRadioGroup, itemData->ug_iGroupValue);
+ mf_ug_ctrl_bar_set_item_disable(itemData->ug_pData);
+ UG_TRACE_END;
+}
+
+
+/******************************
+** Prototype : __mf_ug_genlist_get_gl_label
+** Description :
+** Input : const void *data
+** Evas_Object *obj
+** const char *part
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+static char *__mf_ug_genlist_get_gl_label(void *data, Evas_Object *obj, const char *part)
+{
+ UG_TRACE_BEGIN;
+ ugListItemData *itemData = (ugListItemData *)data;
+ ug_mf_retvm_if(itemData == NULL, NULL, "itemData is NULL");
+
+ if (strcmp(part, "elm.text") == 0) {
+ UG_TRACE_END;
+ return strdup(ecore_file_file_get(itemData->ug_pItemName->str));
+ } else if (strcmp(part, "elm.uptitle.text") == 0) {
+ UG_TRACE_END;
+ return strdup(("Upper Level"));
+ } else {
+ UG_TRACE_END;
+ return strdup("");
+ }
+}
+
+
+/******************************
+** Prototype : __mf_ug_genlist_get_thumbnail
+** Description : Samsung
+** Input : void *data
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+static void __mf_ug_genlist_get_thumbnail(void *data)
+{
+ UG_TRACE_BEGIN;
+ ugListItemData *itemData = (ugListItemData *)data;
+ ug_mf_retm_if(itemData == NULL, "itemData is NULL");
+
+ const char *dir_icon_path = UG_ICON_FOLDER;
+ //const char *dir_create_icon_path = UG_ICON_FOLDER_CREATED;
+ char *icon_path = NULL;
+ int error_code = MYFILE_ERR_NONE;
+
+ if (itemData->ug_pThumbPath == NULL) {
+ if (ecore_file_is_dir(itemData->ug_pItemName->str)) {
+ itemData->ug_pThumbPath = strdup(dir_icon_path);
+ itemData->ug_bRealThumbFlag = true;
+ } else {
+ icon_path = mf_ug_file_attr_get_file_icon(itemData->ug_pData->ug_Status.ug_pMedia_svc_handle, itemData->ug_pItemName->str, &error_code);
+ if (icon_path) {
+ itemData->ug_pThumbPath = strdup(icon_path);
+ itemData->ug_bRealThumbFlag = true;
+ free(icon_path);
+ icon_path = NULL;
+ } else { /*/must be image/video file */
+
+ mf_ug_fs_file_type type = UG_FILE_TYPE_NONE;
+ type = mf_ug_file_attr_get_file_type_by_mime(itemData->ug_pItemName->str);
+
+ if (type == UG_FILE_TYPE_VIDEO) {
+ itemData->ug_pThumbPath = strdup(UG_ICON_VIDEO);
+ } else if (type == UG_FILE_TYPE_IMAGE) {
+ itemData->ug_pThumbPath = strdup(UG_ICON_IMAGE);
+ } else {
+ itemData->ug_pThumbPath = strdup(UG_DEFAULT_ICON);
+ }
+ itemData->ug_bRealThumbFlag = false;
+ error_code = MYFILE_ERR_GET_THUMBNAIL_FAILED;
+ }
+ }
+ } else if (itemData->ug_pThumbPath && ecore_file_exists(itemData->ug_pThumbPath)) {
+ if (itemData->ug_bRealThumbFlag == false) {
+ error_code = MYFILE_ERR_GET_THUMBNAIL_FAILED;
+ }
+ } else if (!ecore_file_exists(itemData->ug_pThumbPath)) {
+
+ ug_debug("ug_pThumbPath[%s] is not exist", itemData->ug_pThumbPath);
+ free(itemData->ug_pThumbPath);
+ itemData->ug_pThumbPath = NULL;
+ /*/set default icon */
+ itemData->ug_pThumbPath = strdup(UG_DEFAULT_ICON);
+ itemData->ug_bRealThumbFlag = false;
+ error_code = MYFILE_ERR_GET_THUMBNAIL_FAILED;
+ }
+#ifdef UG_THUMB_REAL_TIME_UPDATE
+ /*/check if we need to add refresh timer */
+ if (error_code != 0 && itemData->ug_pData->ug_Status.ug_pThumbUpdateTimer == NULL) {
+ itemData->ug_pData->ug_Status.ug_pThumbUpdateTimer = ecore_timer_add(INTERVAL_THUMB_UPDATE, mf_ug_cb_thumb_timer_cb, itemData);
+ }
+#endif
+ UG_TRACE_END;
+}
+
+
+/******************************
+** Prototype : __mf_ug_genlist_create_thumbnail
+** Description : Samsung
+** Input : void *data
+** Evas_Object *parent
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+static Evas_Object *__mf_ug_genlist_create_thumbnail(void *data, Evas_Object *parent)
+{
+
+ UG_TRACE_BEGIN;
+ ugListItemData *itemData = (ugListItemData *)data;
+ ug_mf_retvm_if(itemData == NULL, NULL, "itemData is NULL");
+
+ Evas_Object *thumb = NULL;
+
+#ifdef USE_IMAGE_OBJECT
+ thumb = evas_object_image_add(evas_object_evas_get(parent));
+#else
+ thumb = elm_icon_add(parent);
+#endif
+ if (thumb == NULL) {
+ ug_debug("thumb is NULL");
+ }
+ if (thumb) {
+#ifdef USE_IMAGE_OBJECT
+ int load_err = EVAS_LOAD_ERROR_NONE;
+ evas_object_image_file_set(thumb, itemData->ug_pThumbPath, NULL);
+ load_err = evas_object_image_load_error_get(thumb);
+
+ if (load_err != EVAS_LOAD_ERROR_NONE) {
+ evas_object_del(thumb);
+ thumb = NULL;
+ } else {
+ evas_object_image_filled_set(thumb, EINA_TRUE);
+ }
+#else
+ elm_icon_file_set(thumb, itemData->ug_pThumbPath, NULL);
+#endif
+ }
+ UG_TRACE_END;
+ return thumb;
+}
+
+
+/******************************
+** Prototype : __mf_ug_genlist_create_mmc_icon
+** Description : Samsung
+** Input : Evas_Object *parent
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+static Evas_Object *__mf_ug_genlist_create_mmc_icon(Evas_Object *parent)
+{
+ UG_TRACE_BEGIN;
+ Evas_Object *ic_memory = NULL;
+ const char *memory_icon_path = UG_ICON_MEMORY_SUB;
+
+ ic_memory = elm_icon_add(parent);
+ elm_icon_file_set(ic_memory, memory_icon_path, NULL);
+ evas_object_show(ic_memory);
+
+ UG_TRACE_END;
+ return ic_memory;
+}
+
+
+/******************************
+** Prototype : __mf_ug_genlist_add_checkbox
+** Description : Samsung
+** Input : void *data
+** Evas_Object *parent
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+static Evas_Object *__mf_ug_genlist_add_checkbox(void *data, Evas_Object *parent)
+{
+ UG_TRACE_BEGIN;
+ ugListItemData *itemData = (ugListItemData *)data;
+ ug_mf_retvm_if(itemData == NULL, NULL, "itemData is NULL");
+
+ Evas_Object *check_box = __mf_ug_genlist_create_checkbox(parent);
+ evas_object_propagate_events_set(check_box, 0);
+
+ elm_check_state_set(check_box, itemData->ug_bChecked);
+
+ itemData->ug_pCheckBox = check_box;
+ evas_object_smart_callback_add(check_box, "changed", __mf_ug_genlist_checkbox_cb, itemData);
+
+ UG_TRACE_END;
+ return check_box;
+}
+
+
+
+/******************************
+** Prototype : __mf_ug_genlist_add_radio_box
+** Description : Samsung
+** Input : void *data
+** Evas_Object *parent
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+static Evas_Object *__mf_ug_genlist_add_radio_box(void *data, Evas_Object *parent)
+{
+ UG_TRACE_BEGIN;
+ ugListItemData *itemData = (ugListItemData *)data;
+ ug_mf_retvm_if(itemData == NULL, NULL, "itemData is NULL");
+
+ Evas_Object *radio_box = __mf_ug_genlist_create_radio_box(parent, itemData);
+
+ evas_object_propagate_events_set(radio_box, 0);
+ itemData->ug_pRadioBox = radio_box;
+ evas_object_smart_callback_add(radio_box, "changed", __mf_ug_genlist_radio_box_cb, itemData);
+
+ UG_TRACE_END;
+ return radio_box;
+}
+
+
+static Evas_Object *__mf_ug_genlist_gl_upper_icon_get(void *data, Evas_Object * obj, const char *part)
+{
+ UG_TRACE_BEGIN;
+ ugListItemData *listItemData = (ugListItemData *)data;
+
+ ug_mf_retvm_if(listItemData == NULL, NULL, "listItemData is NULL");
+ ug_mf_retvm_if(listItemData->ug_pItemName == NULL, NULL, "m_ItemName is NULL");
+ ug_mf_retvm_if(part == NULL, NULL, "part is NULL");
+ ug_mf_retvm_if(obj == NULL, NULL, "obj is NULL");
+
+ Evas_Object *thumb = NULL;
+ if (!strcmp(part, "elm.icon")) {
+ thumb = elm_icon_add(obj);
+ elm_object_focus_set(thumb, EINA_FALSE);
+ if (thumb) {
+ elm_icon_file_set(thumb, listItemData->ug_pThumbPath, NULL);
+ }
+ }
+ return thumb;
+}
+
+
+static Evas_Object *__mf_ug_genlist_upper_icon_get(void *data, Evas_Object * obj, const char *part)
+{
+ ug_mf_retvm_if(data == NULL, NULL, "data is NULL");
+ ug_mf_retvm_if(obj == NULL, NULL, "obj is NULL");
+
+ ugData *ugd = (ugData *)data;
+
+ if (!strcmp(part, "elm.icon.1")) {
+ Evas_Object *btn = elm_button_add(obj);
+ elm_object_text_set(btn, MF_UG_LABEL_HOME);
+ evas_object_smart_callback_add(btn, "clicked", mf_ug_cb_home_button_cb, ugd);
+ return btn;
+ } else if (!strcmp(part, "elm.icon.2")) {
+ Evas_Object *btn = elm_button_add(obj);
+ elm_object_text_set(btn, MF_UG_LABEL_UPPER);
+ evas_object_smart_callback_add(btn, "clicked", mf_ug_cb_upper_click_cb, ugd);
+ return btn;
+ }
+ return NULL;
+}
+
+/******************************
+** Prototype : __mf_ug_genlist_get_gl_icon
+** Description : Samsung
+** Input : const void *data
+** Evas_Object *obj
+** const char *part
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+static Evas_Object *__mf_ug_genlist_get_gl_icon(void *data, Evas_Object *obj, const char *part)
+{
+ UG_TRACE_BEGIN;
+ Evas_Object *thumb = NULL, *ic_memory = NULL;
+ Evas_Object *layout = NULL;
+ Evas_Object *selected_box = NULL;
+
+ mf_ug_storage_type is_in_mmc = 0;
+ ugListItemData *listItemData = (ugListItemData *)data;
+ ug_mf_retv_if(listItemData == NULL, NULL);
+ ugData *ugd = listItemData->ug_pData;
+ ug_mf_retv_if(ugd == NULL, NULL);
+
+ if (!strcmp(part, "elm.icon")) {
+ if (strncmp(listItemData->ug_pItemName->str, "Upper Level", strlen(listItemData->ug_pItemName->str)) == 0) {
+ listItemData->ug_pThumbPath = strdup(UG_ICON_UPPER);
+ thumb = __mf_ug_genlist_create_thumbnail(listItemData, obj);
+ return thumb;
+ }
+ __mf_ug_genlist_get_thumbnail(listItemData);
+ thumb = __mf_ug_genlist_create_thumbnail(listItemData, obj);
+ layout = elm_layout_add(obj);
+ elm_layout_file_set(layout, UG_EDJ_NAVIGATIONBAR, UG_GRP_LIST);
+ elm_object_part_content_set(layout, "swallow_thumb", thumb);
+
+ mf_ug_file_attr_get_store_type_by_full(listItemData->ug_pItemName->str, &is_in_mmc);
+ if (is_in_mmc == MF_UG_MMC) {
+ ic_memory = __mf_ug_genlist_create_mmc_icon(obj);
+ elm_object_part_content_set(layout, "myfile.memory_icon.sub", ic_memory);
+ }
+ UG_TRACE_END;
+ return layout;
+ } else if (!strcmp(part, "elm.icon.1")) {
+ if (ugd->ug_UiGadget.ug_pMultiSelectFileList) {
+ if (__mf_ug_genlist_is_file_marked(ugd->ug_UiGadget.ug_pMultiSelectFileList, listItemData->ug_pItemName)) {
+ listItemData->ug_bChecked = true;
+ }
+ }
+ if (ecore_file_is_dir(listItemData->ug_pItemName->str)) {
+ if (ugd->ug_UiGadget.ug_iSelectMode == MULTI_ALL_MODE) {
+ selected_box = __mf_ug_genlist_add_checkbox(listItemData, obj);
+ } else if (ugd->ug_UiGadget.ug_iSelectMode == SINGLE_ALL_MODE) {
+ selected_box = __mf_ug_genlist_add_radio_box(listItemData, obj);
+ }
+ } else {
+ if (ugd->ug_UiGadget.ug_iSelectMode == MULTI_FILE_MODE || ugd->ug_UiGadget.ug_iSelectMode == MULTI_ALL_MODE) {
+ selected_box = __mf_ug_genlist_add_checkbox(listItemData, obj);
+ } else if (ugd->ug_UiGadget.ug_iSelectMode == SINGLE_FILE_MODE || ugd->ug_UiGadget.ug_iSelectMode == SINGLE_ALL_MODE) {
+
+ selected_box = __mf_ug_genlist_add_radio_box(listItemData, obj);
+ }
+ }
+ return selected_box;
+ } else if (!strcmp(part, "elm.icon.2")) {
+ __mf_ug_genlist_get_thumbnail(listItemData);
+ thumb = __mf_ug_genlist_create_thumbnail(listItemData, obj);
+ return thumb;
+ } else if (!strcmp(part, "elm.icon.3")) {
+#ifdef LIST_PLAY_SUPPORT
+ ug_debug();
+ if (!ecore_file_is_dir(listItemData->ug_pItemName->str)) {
+ ug_debug();
+ Evas_Object *music_icon = NULL;
+ Evas_Object *music_button = NULL;
+ mf_ug_launch_type launch_type = mf_ug_util_get_file_launch_type(listItemData->ug_pItemName->str);
+ if (launch_type == LAUNCH_TYPE_MUSIC) {
+ char *play_icon = NULL;
+ char *pause_icon = NULL;
+
+ music_button = elm_button_add(obj);
+ elm_object_style_set(music_button, "circle/empty");
+
+ music_icon = elm_icon_add(music_button);
+ if (ugd->ug_ListPlay.ug_pPlayFilePath) {
+ if (g_strcmp0(ugd->ug_ListPlay.ug_pPlayFilePath, listItemData->ug_pItemName->str) == 0) {
+ if (ugd->ug_ListPlay.ug_iPlayState == PLAY_STATE_PLAYING) {
+
+ pause_icon = strdup(UG_ICON_MUSIC_PAUSE_WHITE);
+ elm_icon_file_set(music_icon, pause_icon, NULL);
+ } else if (ugd->ug_ListPlay.ug_iPlayState == PLAY_STATE_PAUSED) {
+ play_icon = strdup(UG_ICON_MUSIC_PLAY_WHITE);
+ elm_icon_file_set(music_icon, play_icon, NULL);
+ }
+ } else {
+ play_icon = strdup(UG_ICON_MUSIC_PLAY_WHITE);
+ elm_icon_file_set(music_icon, play_icon, NULL);
+ }
+ } else {
+ play_icon = strdup(UG_ICON_MUSIC_PLAY_WHITE);
+ elm_icon_file_set(music_icon, play_icon, NULL);
+ }
+ evas_object_size_hint_aspect_set(music_icon, EVAS_ASPECT_CONTROL_BOTH, 1, 1);
+ elm_object_part_content_set(music_button, "icon", music_icon);
+ evas_object_propagate_events_set(music_button, EINA_FALSE);
+ evas_object_smart_callback_add(music_button, "clicked", (Evas_Smart_Cb)mf_ug_cb_list_play_cb, (void*)listItemData);
+ UG_TRACE_END;
+ return music_button;
+ }
+ }
+#endif
+ UG_TRACE_END;
+
+ return NULL;
+
+ } else {
+ UG_TRACE_END;
+ return NULL;
+ }
+}
+
+static Evas_Object *__mf_ug_genlist_get_gl_editfiled_icon(void *data, Evas_Object *obj, const char *part)
+{
+ ugListItemData *listItemData = (ugListItemData *)data;
+ ug_mf_retv_if(listItemData == NULL, NULL);
+ ugData *ugd = listItemData->ug_pData;
+ ug_mf_retv_if(ugd == NULL, NULL);
+
+ ug_debug("listItemData is [%p]", listItemData);
+
+ if (!strcmp(part, "elm.icon")) {
+ Evas_Object *button = NULL;
+ button = elm_button_add(obj);
+ elm_object_text_set(button, "Go to My files");
+ evas_object_smart_callback_add(button, "clicked", mf_ug_cb_goto_myfile_button_cb, ugd);
+ return button;
+ }
+ return NULL;
+}
+
+/******************************
+** Prototype : __mf_ug_genlist_get_gl_state
+** Description :
+** Input : const void *data
+** Evas_Object *obj
+** const char *part
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+static Eina_Bool __mf_ug_genlist_get_gl_state(void *data, Evas_Object *obj, const char *part)
+{
+ return EINA_FALSE;
+}
+
+
+/******************************
+** Prototype : __mf_ug_genlist_del_gl
+** Description :
+** Input : const void *data
+** Evas_Object *obj
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+static void __mf_ug_genlist_del_gl(void *data, Evas_Object *obj)
+{
+ UG_TRACE_BEGIN;
+ ugListItemData *itemData = (ugListItemData *)data;
+ ug_mf_retm_if(itemData == NULL, "itemData is NULL");
+ if (itemData->ug_pItemName && itemData->ug_pItemName->str) {
+ g_string_free(itemData->ug_pItemName, TRUE);
+ itemData->ug_pItemName = NULL;
+ }
+ if (itemData->ug_pThumbPath) {
+ free(itemData->ug_pThumbPath);
+ itemData->ug_pThumbPath = NULL;
+ }
+ free(itemData);
+ itemData = NULL;
+ UG_TRACE_END;
+ return;
+}
+
+
+
+/******************************
+** Prototype : __mf_ug_genlist_selected_gl
+** Description : Samsung
+** Input : void *data
+** Evas_Object *obj
+** void *event_info
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+static void __mf_ug_genlist_selected_gl(void *data, Evas_Object *obj, void *event_info)
+{
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+ ug_mf_retm_if(ugd == NULL, "ugd is NULL");
+
+ Elm_Object_Item *item = (Elm_Object_Item *) event_info;
+ int error_code = 0;
+ int mmc_card = 0;
+ error_code = mf_ug_util_get_mmc_state(&mmc_card);
+
+ ugNaviBar *pNavi_s = mf_ug_navi_bar_get_in_use_navi(ugd);
+ if (item != NULL) {
+ ugListItemData *selected = (ugListItemData *)elm_object_item_data_get(item);
+ fprintf(stdout, "selected text %s\n", (char *)selected->ug_pItemName->str);
+ elm_genlist_item_selected_set(item, EINA_FALSE);
+ if (ugd->ug_Status.ug_b_NaviPushFlag)
+ return;
+ if (!strcmp(selected->ug_pItemName->str, "Upper Level")) {
+ if (ugd->ug_Status.ug_pPath != NULL && pNavi_s->ug_pCurrentPath != NULL) {
+ GString *new_path = NULL;
+ char *file_dir = ecore_file_dir_get(pNavi_s->ug_pCurrentPath);
+ if (file_dir) {
+ new_path = g_string_new(file_dir);
+ g_string_free(ugd->ug_Status.ug_pPath, TRUE);
+ ugd->ug_Status.ug_pPath = new_path;
+ free(pNavi_s->ug_pCurrentPath);
+ pNavi_s->ug_pCurrentPath = strdup(new_path->str);
+ free(file_dir);
+ file_dir = NULL;
+ } else {
+ ug_debug("file_dir is NULL");
+ }
+ } else {
+ ugd->ug_Status.ug_pPath = g_string_new(PHONE_FOLDER);
+ pNavi_s->ug_pCurrentPath = strdup(PHONE_FOLDER);
+ }
+ ugd->ug_Status.ug_b_NaviPushFlag = true;
+ mf_ug_navi_bar_create_default_view(ugd);
+ } else if (!ecore_file_is_dir(selected->ug_pItemName->str)) {
+
+ if (ugd->ug_UiGadget.ug_iSelectMode == SINGLE_FILE_MODE || ugd->ug_UiGadget.ug_iSelectMode == SINGLE_ALL_MODE) {
+ if (elm_radio_value_get(ugd->ug_MainWindow.ug_pRadioGroup) != selected->ug_iGroupValue) {
+ ugd->ug_Status.ug_iRadioOn = selected->ug_iGroupValue;
+ selected->ug_bChecked = true;
+ elm_radio_value_set(ugd->ug_MainWindow.ug_pRadioGroup, selected->ug_iGroupValue);
+ }
+
+ } else {
+ if (selected->ug_bChecked == 0) {
+ selected->ug_bChecked = 1;
+ } else {
+ selected->ug_bChecked = 0;
+ }
+ elm_check_state_set(selected->ug_pCheckBox, selected->ug_bChecked);
+ __mf_ug_genlist_show_select_info(selected);
+ }
+ } else if (ecore_file_is_dir(selected->ug_pItemName->str) && strcmp(selected->ug_pItemName->str, "Upper Level")) {
+
+ if (ugd->ug_ListPlay.ug_iPlayState == PLAY_STATE_PLAYING || ugd->ug_ListPlay.ug_iPlayState == PLAY_STATE_PAUSED) {
+ mf_ug_list_play_destory_playing_file(ugd);
+ }
+ if (ugd->ug_Status.ug_pPath) {
+ g_string_free(ugd->ug_Status.ug_pPath, TRUE);
+ ugd->ug_Status.ug_pPath = NULL;
+ }
+ ugd->ug_Status.ug_pPath = g_string_new(selected->ug_pItemName->str);
+ if (pNavi_s->ug_pCurrentPath != NULL) {
+ free(pNavi_s->ug_pCurrentPath);
+ pNavi_s->ug_pCurrentPath = NULL;
+ }
+ pNavi_s->ug_pCurrentPath = strdup(selected->ug_pItemName->str);
+ ugd->ug_Status.ug_b_NaviPushFlag = true;
+ mf_ug_navi_bar_create_default_view(ugd);
+ }
+
+ mf_ug_ctrl_bar_set_item_disable(ugd);
+ }
+ UG_TRACE_END;
+}
+
+
+/******************************
+** Prototype : __mf_ug_genlist_create_gl
+** Description : Samsung
+** Input : void *data
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+static Evas_Object *__mf_ug_genlist_create_gl(void *data)
+{
+
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+ ug_mf_retvm_if(ugd == NULL, NULL, "ugd is NULL");
+
+ ugNaviBar *pNaviInUse = mf_ug_navi_bar_get_in_use_navi(ugd);
+ ug_mf_retvm_if(pNaviInUse == NULL, NULL, "pNaviInUse is NULL");
+
+ Evas_Object *genlist;
+ ug_debug("pNaviInUse->ug_pNaviBar is [%p]", pNaviInUse->ug_pNaviBar);
+ genlist = elm_genlist_add(pNaviInUse->ug_pNaviBar);
+ evas_object_size_hint_weight_set(genlist, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
+ evas_object_size_hint_align_set(genlist, EVAS_HINT_FILL, EVAS_HINT_FILL);
+
+ evas_object_smart_callback_add(genlist, "selected", __mf_ug_genlist_selected_gl, ugd);
+
+#ifdef UG_THUMB_REAL_TIME_UPDATE
+ if (ugd->ug_Status.ug_pThumbUpdateTimer != NULL) {
+ ecore_timer_del(ugd->ug_Status.ug_pThumbUpdateTimer);
+ ugd->ug_Status.ug_pThumbUpdateTimer = NULL;
+ }
+#endif
+
+ ugd->ug_Status.ug_itc.item_style = "1text.3icon";
+ ugd->ug_Status.ug_itc.func.text_get = __mf_ug_genlist_get_gl_label;
+ ugd->ug_Status.ug_itc.func.content_get = __mf_ug_genlist_get_gl_icon;
+ ugd->ug_Status.ug_itc.func.state_get = __mf_ug_genlist_get_gl_state;
+ ugd->ug_Status.ug_itc.func.del = __mf_ug_genlist_del_gl;
+
+
+ if (ugd->ug_UiGadget.ug_iSelectMode == MULTI_FILE_MODE || ugd->ug_UiGadget.ug_iSelectMode == SINGLE_FILE_MODE) {
+ ugd->ug_Status.ug_normalitc.item_style = "1text.1icon.2";
+ ugd->ug_Status.ug_normalitc.func.text_get = __mf_ug_genlist_get_gl_label;
+ ugd->ug_Status.ug_normalitc.func.content_get = __mf_ug_genlist_get_gl_icon;
+ ugd->ug_Status.ug_normalitc.func.state_get = __mf_ug_genlist_get_gl_state;
+ ugd->ug_Status.ug_normalitc.func.del = __mf_ug_genlist_del_gl;
+ }
+
+ UG_TRACE_END;
+
+ return genlist;
+}
+
+
+/******************************
+** Prototype : __mf_ug_genlist_init_item_data
+** Description : Samsung
+** Input : void *data
+** ugListItemData **itemData
+** char *fullname
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+static void __mf_ug_genlist_init_item_data(void *data, ugListItemData **itemData, char *fullname)
+{
+
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+ ugListItemData **ug_ItemData = itemData;
+ ug_mf_retm_if(ugd == NULL, "ugd is NULL");
+ ug_mf_retm_if(ug_ItemData == NULL, "ug_ItemData is NULL");
+
+ *ug_ItemData = (ugListItemData *)malloc(sizeof(ugListItemData));
+ if (*ug_ItemData == NULL) {
+ ug_debug("ug_ItemData malloc failed");
+ } else {
+ memset(*ug_ItemData, 0, sizeof(ugListItemData));
+ if (fullname) {
+ (*ug_ItemData)->ug_pItemName = g_string_new(fullname);
+ } else {
+ (*ug_ItemData)->ug_pItemName = NULL;
+ }
+ (*ug_ItemData)->ug_bChecked = false;
+ (*ug_ItemData)->ug_pRadioBox = NULL;
+ (*ug_ItemData)->ug_pCheckBox = NULL;
+ (*ug_ItemData)->ug_iGroupValue = 0;
+ (*ug_ItemData)->ug_pItem = NULL;
+ (*ug_ItemData)->ug_pThumbPath = NULL;
+ (*ug_ItemData)->ug_bRealThumbFlag = false;
+ (*ug_ItemData)->ug_pData = ugd;
+ }
+ UG_TRACE_END;
+}
+
+/******************************
+** Prototype : mf_ug_genlist_create_content_list_view
+** Description : Samsung
+** Input : void *data
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+void mf_ug_genlist_upper_style_set(void *data)
+{
+ ug_mf_retm_if(data == NULL, "data is NULL");
+ ugData *ugd = (ugData *)data;
+ ugd->ug_Status.ug_topitc.item_style = "1text.1icon.2";
+ ugd->ug_Status.ug_topitc.func.text_get = __mf_ug_genlist_get_gl_label;
+ ugd->ug_Status.ug_topitc.func.content_get = __mf_ug_genlist_gl_upper_icon_get;
+ ugd->ug_Status.ug_topitc.func.state_get = __mf_ug_genlist_get_gl_state;
+ ugd->ug_Status.ug_topitc.func.del = __mf_ug_genlist_del_gl;
+}
+
+void mf_ug_genlist_goto_myfile_style_set(void *data)
+{
+ ug_mf_retm_if(data == NULL, "data is NULL");
+ ugData *ugd = (ugData *)data;
+ ugd->ug_Status.ug_editfileditc.item_style = "dialogue/bg/1icon";
+ ugd->ug_Status.ug_editfileditc.func.text_get = NULL;
+ ugd->ug_Status.ug_editfileditc.func.content_get = __mf_ug_genlist_get_gl_editfiled_icon;
+ ugd->ug_Status.ug_editfileditc.func.state_get = NULL;
+ ugd->ug_Status.ug_editfileditc.func.del = __mf_ug_genlist_del_gl;
+
+ ugd->ug_Status.ug_editfiledBottomSeperatoritc.item_style = "dialogue/separator/11/with_line";
+ ugd->ug_Status.ug_editfiledBottomSeperatoritc.func.text_get = NULL;
+ ugd->ug_Status.ug_editfiledBottomSeperatoritc.func.content_get = NULL;
+ ugd->ug_Status.ug_editfiledBottomSeperatoritc.func.state_get = NULL;
+ ugd->ug_Status.ug_editfiledBottomSeperatoritc.func.del = NULL;
+
+ ugd->ug_Status.ug_editfiledUpperSeperatoritc.item_style = "dialogue/separator/10";
+ ugd->ug_Status.ug_editfiledUpperSeperatoritc.func.text_get = NULL;
+ ugd->ug_Status.ug_editfiledUpperSeperatoritc.func.content_get = NULL;
+ ugd->ug_Status.ug_editfiledUpperSeperatoritc.func.state_get = NULL;
+ ugd->ug_Status.ug_editfiledUpperSeperatoritc.func.del = NULL;
+
+}
+
+Evas_Object *mf_navi_bar_upper_create(Evas_Object *parent)
+{
+ UG_TRACE_BEGIN;
+ ug_mf_retvm_if(parent == NULL, NULL, "parent is NULL");
+
+ Evas_Object *upper_genlist = NULL;
+ upper_genlist = elm_genlist_add(parent);
+ ug_mf_retvm_if(upper_genlist == NULL, NULL, "upper_genlist is NULL");
+ elm_object_focus_set(upper_genlist, EINA_FALSE);
+ evas_object_size_hint_weight_set(upper_genlist, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
+ evas_object_size_hint_align_set(upper_genlist, EVAS_HINT_FILL, EVAS_HINT_FILL);
+ elm_genlist_bounce_set(upper_genlist, EINA_FALSE, EINA_FALSE);
+ evas_object_show(upper_genlist);
+ UG_TRACE_END;
+ return upper_genlist;
+
+}
+
+
+void mf_ug_upper_genlist_item_append(Evas_Object *pGenlist, void *data)
+{
+ ug_mf_retm_if(data == NULL, "data is NULL");
+ ug_mf_retm_if(pGenlist == NULL, "pGenlist is NULL");
+ ugData *ugd = (ugData *)data;
+
+ Elm_Object_Item *item = NULL;
+
+ ugd->ug_Status.ug_topitc.item_style = "dialogue/bg/2icon";
+ ugd->ug_Status.ug_topitc.func.text_get = NULL;
+ ugd->ug_Status.ug_topitc.func.content_get = __mf_ug_genlist_upper_icon_get;
+ ugd->ug_Status.ug_topitc.func.state_get = NULL;
+ ugd->ug_Status.ug_topitc.func.del = NULL;
+ ugd->ug_Status.ug_separtor_no_bottom_line_itc.item_style = "dialogue/seperator.4";
+ ugd->ug_Status.ug_separtor_no_bottom_line_itc.func.text_get = NULL;
+ ugd->ug_Status.ug_separtor_no_bottom_line_itc.func.content_get = NULL;
+ ugd->ug_Status.ug_separtor_no_bottom_line_itc.func.state_get = NULL;
+ ugd->ug_Status.ug_separtor_no_bottom_line_itc.func.del = NULL;
+
+ ugd->ug_Status.ug_separtor_with_bottom_line_itc.item_style = "dialogue/seperator.2";
+ ugd->ug_Status.ug_separtor_with_bottom_line_itc.func.text_get = NULL;
+ ugd->ug_Status.ug_separtor_with_bottom_line_itc.func.content_get = NULL;
+ ugd->ug_Status.ug_separtor_with_bottom_line_itc.func.state_get = NULL;
+ ugd->ug_Status.ug_separtor_with_bottom_line_itc.func.del = NULL;
+
+ // separator with no bottom line
+ item = elm_genlist_item_append(pGenlist, &ugd->ug_Status.ug_separtor_no_bottom_line_itc, NULL, NULL, ELM_GENLIST_ITEM_NONE, NULL, NULL);
+ elm_genlist_item_select_mode_set(item, ELM_OBJECT_SELECT_MODE_DISPLAY_ONLY);
+
+ // button for dialogue item (dialogue bg)
+ item = elm_genlist_item_append(pGenlist, &ugd->ug_Status.ug_topitc, (void *) ugd, NULL, ELM_GENLIST_ITEM_NONE, NULL, NULL);
+
+ // separator with bottom line
+ item = elm_genlist_item_append(pGenlist, &ugd->ug_Status.ug_separtor_with_bottom_line_itc, NULL, NULL, ELM_GENLIST_ITEM_NONE, NULL, NULL);
+ elm_genlist_item_select_mode_set(item, ELM_OBJECT_SELECT_MODE_DISPLAY_ONLY);
+}
+
+void mf_ug_genlist_goto_myfile_item_append(Evas_Object *pGenlist, void *data)
+{
+ ug_mf_retm_if(pGenlist == NULL, "pGenlist is NULL");
+ ug_mf_retm_if(data == NULL, "data is NULL");
+ ugData *ugd = (ugData *)data;
+
+ ugListItemData *ug_ItemData;
+ Elm_Object_Item *it = NULL;
+
+ __mf_ug_genlist_init_item_data(ugd, &ug_ItemData, NULL);
+ ug_debug("ug_ItemData is [%p]", &ug_ItemData);
+
+ it = elm_genlist_item_append(pGenlist, &ugd->ug_Status.ug_editfiledUpperSeperatoritc, NULL, NULL, ELM_GENLIST_ITEM_NONE, NULL,
+ NULL);
+ elm_genlist_item_select_mode_set(it, ELM_OBJECT_SELECT_MODE_DISPLAY_ONLY);
+
+ it = elm_genlist_item_append(pGenlist, &ugd->ug_Status.ug_editfileditc, ug_ItemData, NULL, ELM_GENLIST_ITEM_GROUP, NULL, NULL);
+ ug_ItemData->ug_pItem = it;
+ elm_genlist_item_select_mode_set(it, ELM_OBJECT_SELECT_MODE_DISPLAY_ONLY);
+
+ it = elm_genlist_item_append(pGenlist, &ugd->ug_Status.ug_editfiledBottomSeperatoritc, NULL, NULL, ELM_GENLIST_ITEM_NONE, NULL,
+ NULL);
+ elm_genlist_item_select_mode_set(it, ELM_OBJECT_SELECT_MODE_DISPLAY_ONLY);
+}
+Evas_Object *mf_ug_genlist_create_content_list_view(void *data)
+{
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+ ug_mf_retvm_if(ugd == NULL, NULL, "ugd is NULL");
+ ugNaviBar *pNaviInUse = mf_ug_navi_bar_get_in_use_navi(ugd);
+ ug_mf_retvm_if(pNaviInUse == NULL, NULL, "pNaviInUse is NULL");
+
+ Evas_Object *genlist;
+ int groupValue = 1;
+ int error_code = 0;
+ Eina_List *dir_list = NULL;
+ Eina_List *file_list = NULL;
+ Elm_Object_Item *it = NULL;
+ int count = 0;
+
+ ugListItemData *ug_ItemData;
+
+ ugd->ug_Status.ug_iRadioOn = 0;
+ ugd->ug_Status.ug_bNoContentFlag = false;
+
+ genlist = __mf_ug_genlist_create_gl(ugd);
+ ug_mf_retvm_if(genlist == NULL, NULL, "genlist create failed");
+ pNaviInUse->ug_pContent = genlist;
+
+ GString *fullpath = g_string_new(ugd->ug_Status.ug_pPath->str);
+
+
+ error_code = mf_ug_fm_svc_wapper_get_file_list_by_filter(ugd, fullpath, &dir_list, &file_list);
+
+ if (error_code == 0) {
+
+ if (ugd->ug_UiGadget.ug_pDirList) {
+ mf_ug_util_free_eina_list_data(&ugd->ug_UiGadget.ug_pDirList, NODE_TYPE_PNODE);
+ ugd->ug_UiGadget.ug_pDirList = NULL;
+ }
+ if (ugd->ug_UiGadget.ug_pFilterList) {
+ mf_ug_util_free_eina_list_data(&ugd->ug_UiGadget.ug_pFilterList, NODE_TYPE_PNODE);
+ ugd->ug_UiGadget.ug_pFilterList = NULL;
+ }
+ ugd->ug_UiGadget.ug_pFilterList = file_list;
+ ugd->ug_UiGadget.ug_pDirList = dir_list;
+ }
+ /* list option set */
+ unsigned int dir_list_len = eina_list_count(dir_list);
+ unsigned int filter_file_list_len = eina_list_count(ugd->ug_UiGadget.ug_pFilterList);
+ ug_debug("error_code is [%d]dir_list_len is [%d]file_list_len is [%d]\n", error_code, dir_list_len, filter_file_list_len);
+
+
+ if ((dir_list_len == 0 && filter_file_list_len == 0) || (ugd->ug_Status.ug_bMassStorageFlag && !ugd->ug_Status.ug_bInSettingView)) {
+ Evas_Object *layout;
+ Evas_Object *nocontent;
+ nocontent = elm_layout_add(ugd->ug_MainWindow.ug_pMainLayout);
+ elm_layout_theme_set(nocontent, "layout", "nocontents", "text");
+ elm_object_part_text_set(nocontent, "elm.text", MF_UG_LABEL_NO_FILES);
+ ugd->ug_Status.ug_bNoContentFlag = true;
+
+ elm_genlist_bounce_set(genlist, EINA_FALSE, EINA_FALSE);
+
+ layout = elm_layout_add(ugd->ug_MainWindow.ug_pMainLayout);
+
+ elm_layout_file_set(layout, UG_EDJ_NAVIGATIONBAR, UG_GRP_NO_CONTENT);
+ elm_object_part_content_set(layout, "myfile.noContent.upper", genlist);
+ elm_object_part_content_set(layout, "myfile.noContent.content", nocontent);
+ if (!ugd->ug_Status.ug_bMassStorageFlag) {
+ mf_ug_util_add_dir_watch(fullpath->str, ugd);
+ g_string_free(fullpath, true);
+ fullpath = NULL;
+ }
+ return layout;
+ }
+ ugFsNodeInfo *pNode = NULL;
+ Eina_List *l = NULL;
+
+ EINA_LIST_FOREACH(dir_list, l, pNode) {
+ char *real_name = NULL;
+ count++;
+ if (pNode != NULL) {
+ real_name = g_strconcat(pNode->path, "/", pNode->name, NULL);
+ } else {
+ if (fullpath != NULL) {
+ g_string_free(fullpath, TRUE);
+ }
+ return NULL;
+ }
+
+ ug_debug("real_name is %s", real_name);
+ __mf_ug_genlist_init_item_data(ugd, &ug_ItemData, real_name);
+
+ if (ug_ItemData == NULL) {
+ ug_debug("alloc memory error\n");
+ if (real_name) {
+ free(real_name);
+ real_name = NULL;
+ }
+ continue;
+ }
+ if (ugd->ug_UiGadget.ug_iSelectMode == MULTI_FILE_MODE || ugd->ug_UiGadget.ug_iSelectMode == SINGLE_FILE_MODE) {
+
+ ug_ItemData->ug_iGroupValue = 0;
+ it = elm_genlist_item_append(genlist, &ugd->ug_Status.ug_normalitc, ug_ItemData, NULL, ELM_GENLIST_ITEM_NONE, NULL, NULL);
+ ug_ItemData->ug_pItem = it;
+ } else {
+ ug_ItemData->ug_iGroupValue = groupValue;
+ groupValue++;
+ it = elm_genlist_item_append(genlist, &ugd->ug_Status.ug_itc, ug_ItemData, NULL, ELM_GENLIST_ITEM_NONE, NULL, NULL);
+ ug_ItemData->ug_pItem = it;
+ }
+
+ if (real_name) {
+ free(real_name);
+ real_name = NULL;
+ }
+ }
+
+ EINA_LIST_FOREACH(file_list, l, pNode) {
+ char *real_name = NULL;
+ mf_ug_launch_type launch_type = LAUNCH_TYPE_FORK;
+ count++;
+ real_name = g_strconcat(pNode->path, "/", pNode->name, NULL);
+ ug_debug("real_name is %s", real_name);
+
+ __mf_ug_genlist_init_item_data(ugd, &ug_ItemData, real_name);
+ if (ug_ItemData == NULL) {
+ ug_debug("alloc memory error\n");
+ if (real_name) {
+ free(real_name);
+ real_name = NULL;
+ }
+ continue;
+ }
+
+ if (ugd->ug_UiGadget.ug_iSelectMode == SINGLE_ALL_MODE || ugd->ug_UiGadget.ug_iSelectMode == SINGLE_FILE_MODE) {
+ ug_ItemData->ug_iGroupValue = groupValue;
+ groupValue++;
+
+ if (__mf_ug_genlist_is_file_marked(ugd->ug_UiGadget.ug_pMultiSelectFileList, ug_ItemData->ug_pItemName)) {
+ ug_ItemData->ug_bChecked = true;
+ ugd->ug_Status.ug_iRadioOn = ug_ItemData->ug_iGroupValue;
+ }
+ }
+
+ it = elm_genlist_item_append(genlist, &ugd->ug_Status.ug_itc, ug_ItemData, NULL, ELM_GENLIST_ITEM_NONE, NULL, NULL);
+ ug_ItemData->ug_pItem = it;
+
+ ug_debug();
+ if (real_name) {
+ ug_debug("free real_name\n");
+ free(real_name);
+ real_name = NULL;
+ }
+ }
+
+ if (fullpath != NULL) {
+ mf_ug_util_add_dir_watch(fullpath->str, ugd);
+ g_string_free(fullpath, TRUE);
+ }
+ UG_TRACE_END;
+ return genlist;
+}
+
+
+/******************************
+** Prototype : mf_ug_genlist_update_main_layout_content
+** Description : Samsung
+** Input : void *data
+** char* pItemLabel
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+void mf_ug_genlist_update_main_layout_content(void *data, char *pItemLabel)
+{
+ ugData *ugd = (ugData *)data;
+ ug_mf_retm_if(ugd == NULL, "ugd is NULL");
+
+ ug_mf_retm_if(pItemLabel == NULL, "invalid parameter pItemLabel");
+ Evas_Object *pOldContent = NULL;
+ /*/1. delete the sepcified item from tab bar */
+ /*/1.1 get navi bar pointer from the control bar item */
+ Evas_Object *pNaviBar_toDel = ug_mf_navi_bar_get_navibar_from_navilist(ugd->ug_MainWindow.ug_pNaviBarList, pItemLabel);
+
+ ugNaviBar *pNavi_s = mf_ug_navi_bar_get_navi_struct_by_navi(ugd, pNaviBar_toDel);
+ /*/1.2 delete the item */
+ evas_object_del(pNaviBar_toDel);
+ mf_ug_tab_bar_remove_item_by_label(ugd->ug_MainWindow.ug_pTabBar, pItemLabel);
+ /*2. delete the item from navigation bar list */
+ Eina_List *plistNaviMMC = eina_list_data_find_list(ugd->ug_MainWindow.ug_pNaviBarList, pNavi_s);
+ /*/2.1 Todo: clear all the data in the structure. */
+ mf_ug_navi_bar_reset_navi_object(pNavi_s);
+ /*/2.2 remove from the list. */
+ ugd->ug_MainWindow.ug_pNaviBarList = eina_list_remove_list(ugd->ug_MainWindow.ug_pNaviBarList, plistNaviMMC);
+ /*/2.3 set first navi as navi in use */
+ pNavi_s = (ugNaviBar *)eina_list_nth(ugd->ug_MainWindow.ug_pNaviBarList, 1);
+ pNavi_s->ug_bNaviFlagInUse = TRUE;
+ /*/3. check if tab bar has at least 2 items */
+ if (eina_list_count(ugd->ug_MainWindow.ug_pNaviBarList) < 2) {
+ /*/no: tab bar delete operation */
+ pOldContent = elm_object_part_content_unset(ugd->ug_MainWindow.ug_pMainLayout, "elm.swallow.content");
+ evas_object_del(pOldContent);
+ /*/3.1 get pNavi Inuse */
+ pNavi_s = mf_ug_navi_bar_get_in_use_navi(ugd);
+ elm_object_part_content_set(ugd->ug_MainWindow.ug_pMainLayout, "elm.swallow.content", pNavi_s->ug_pNaviBar);
+ } else {
+ /*/yes: do nothing */
+ //elm_toolbar_item_selected_set(elm_toolbar_first_item_get(ugd->ug_MainWindow.ug_pTabBar), EINA_TRUE);
+ }
+}
diff --git a/src/widget/mf-ug-navi-bar.c b/src/widget/mf-ug-navi-bar.c
new file mode 100755
index 0000000..b94700c
--- /dev/null
+++ b/src/widget/mf-ug-navi-bar.c
@@ -0,0 +1,794 @@
+/*
+ * Copyright 2012 Samsung Electronics Co., Ltd
+ *
+ * Licensed under the Flora License, Version 1.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.tizenopensource.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 "mf-ug-winset.h"
+#include "mf-ug-cb.h"
+#include "mf-ug-fm-svc-wrapper.h"
+#include "mf-ug-util.h"
+#include "mf-ug-fs-util.h"
+#include "mf-ug-resource.h"
+
+
+/******************************
+** Prototype : __mf_ug_navi_bar_create_group_radio_box
+** Description : Samsung
+** Input : void *data
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+static void __mf_ug_navi_bar_create_group_radio_box(void *data)
+{
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+ ug_mf_retm_if(ugd == NULL, "ugd is NULL");
+
+ Evas_Object *group_radio = NULL;
+
+ if (ugd->ug_MainWindow.ug_pRadioGroup != NULL) {
+ evas_object_del(ugd->ug_MainWindow.ug_pRadioGroup);
+ ugd->ug_MainWindow.ug_pRadioGroup = NULL;
+ }
+
+ group_radio = elm_radio_add(ugd->ug_MainWindow.ug_pMainLayout);
+ ug_mf_retm_if(group_radio == NULL, "ugd is NULL");
+
+ elm_radio_value_set(group_radio, 0);
+ evas_object_hide(group_radio);
+ /*/Internal/invisible Radio Objects used to group the radio buttons in the list. */
+ ugd->ug_MainWindow.ug_pRadioGroup = group_radio;
+ UG_TRACE_END;
+}
+
+
+/******************************
+** Prototype : __mf_ug_navi_bar_push_content
+** Description : Samsung
+** Input : ugData *data
+** Evas_Object *NaviContent
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+static void __mf_ug_navi_bar_push_content(ugNaviBar *pNavi_s, Evas_Object *NaviContent)
+{
+ UG_TRACE_BEGIN;
+ ug_mf_retm_if(pNavi_s == NULL, "pNavi_s is NULL");
+
+ Evas_Object *NaviBar = pNavi_s->ug_pNaviBar;
+ char *title = pNavi_s->ug_pNaviTitle;
+
+ pNavi_s->ug_pPreNaviItem = pNavi_s->ug_pNaviItem;
+
+ pNavi_s->ug_pNaviItem = elm_naviframe_item_push(NaviBar, title, NULL, NULL, NaviContent, MF_UG_NAVI_STYLE_ENABLE);
+
+ UG_TRACE_END;
+}
+
+static Evas_Object *__mf_ug_navi_bar_create_select_info(void *data, Evas_Object *parent)
+{
+
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+ ug_mf_retvm_if(ugd == NULL, NULL, "ugd is NULL");
+ ug_mf_retvm_if(parent == NULL, NULL, "parent is NULL");
+
+ Evas_Object *pSelectInfo = NULL;
+ pSelectInfo = elm_notify_add(parent);
+ elm_notify_orient_set(pSelectInfo, ELM_NOTIFY_ORIENT_BOTTOM);
+
+ evas_object_smart_callback_add(pSelectInfo, "selectioninfo,timeout", mf_ug_cb_select_info_timeout_cb, ugd);
+ evas_object_event_callback_add(pSelectInfo, EVAS_CALLBACK_SHOW, mf_ug_cb_select_info_show_cb, ugd);
+ evas_object_event_callback_add(pSelectInfo, EVAS_CALLBACK_HIDE, mf_ug_cb_select_info_hide_cb, ugd);
+ UG_TRACE_END;
+
+ return pSelectInfo;
+}
+
+static Evas_Object *__mf_ug_navi_bar_create_select_info_layout(Evas_Object *parent, Evas_Object *select_info)
+{
+ UG_TRACE_BEGIN;
+ ug_mf_retvm_if(parent == NULL, NULL, "parent is NULL");
+ ug_mf_retvm_if(select_info == NULL, NULL, "select_info is NULL");
+
+ Evas_Object *pSelectInfoLayout = NULL;
+
+ pSelectInfoLayout = elm_layout_add(parent);
+ //elm_layout_theme_set(pSelectInfoLayout, "standard", "selectioninfo", "bottom_86");
+ elm_object_content_set(select_info, pSelectInfoLayout);
+
+ UG_TRACE_END;
+ return pSelectInfoLayout;
+}
+
+void mf_ug_navi_bar_set_select_info_label(void *data, int dir_count, int file_count)
+{
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+ ug_mf_retm_if(ugd == NULL, "ugd is NULL");
+
+ ug_debug("dir count is [%d], file count is [%d]", dir_count, file_count);
+
+ if (ugd->ug_MainWindow.ug_pLabel) {
+ if (ugd->ug_MainWindow.ug_pSelectInfoLayout) {
+ evas_object_del(ugd->ug_MainWindow.ug_pSelectInfoLayout);
+ ugd->ug_MainWindow.ug_pSelectInfoLayout = NULL;
+ }
+ if (ugd->ug_MainWindow.ug_pLabel) {
+ evas_object_del(ugd->ug_MainWindow.ug_pLabel);
+ ugd->ug_MainWindow.ug_pLabel = NULL;
+ }
+ }
+
+ if (!ugd->ug_MainWindow.ug_pLabel) {
+ /*Note: selectioninfo is kind of popup, so, do not swallow it to part of layout
+ //And it should be attached on main layout because it calculate the position of itself by layout size (elm_layout_theme_set())
+ //Evas_Object *countlabel = elm_selectioninfo_add(ugd->ug_MainWindow.ug_pMainLayout);
+ */
+
+ ugd->ug_MainWindow.ug_pLabel = __mf_ug_navi_bar_create_select_info(ugd, ugd->ug_MainWindow.ug_pMainLayout);
+
+ ugd->ug_MainWindow.ug_pSelectInfoLayout =
+ __mf_ug_navi_bar_create_select_info_layout(ugd->ug_MainWindow.ug_pMainLayout, ugd->ug_MainWindow.ug_pLabel);
+ elm_layout_theme_set(ugd->ug_MainWindow.ug_pSelectInfoLayout, "standard", "selectioninfo", "vertical/bottom_64");
+
+ }
+
+ if (dir_count + file_count > 0) {
+ char lable_dir[UG_LABEL_STRING_LENGTH] = { '\0', };
+ char lable_file[UG_LABEL_STRING_LENGTH] = { '\0', };
+ char *select_lable = NULL;
+ /*1 TODO: need to update for multi-language */
+ if (dir_count > 1) {
+ snprintf(lable_dir, sizeof(lable_dir), "%d %s", dir_count, ("folders"));
+ } else if (dir_count == 1) {
+ snprintf(lable_dir, sizeof(lable_dir), "%d %s", dir_count, ("folder"));
+ }
+
+ if (file_count > 1) {
+ snprintf(lable_file, sizeof(lable_file), "%d %s", file_count, ("files"));
+ } else if (file_count == 1) {
+ snprintf(lable_file, sizeof(lable_file), "%d %s", file_count, ("file"));
+ }
+
+ if (dir_count < 1) {
+ select_lable = g_strconcat("Selected (", lable_file, ")", NULL);
+ } else if (file_count < 1) {
+ select_lable = g_strconcat("Selected (", lable_dir, ")", NULL);
+ } else {
+ select_lable = g_strconcat("Selected (", lable_dir, " , ", lable_file, ")", NULL);
+ }
+
+ elm_object_part_text_set(ugd->ug_MainWindow.ug_pSelectInfoLayout, "elm.text", select_lable);
+ edje_object_part_text_set(_EDJ(ugd->ug_MainWindow.ug_pSelectInfoLayout), "elm.text", select_lable);
+ elm_notify_timeout_set(ugd->ug_MainWindow.ug_pLabel, 3);
+ evas_object_show(ugd->ug_MainWindow.ug_pLabel);
+ } else {
+ evas_object_hide(ugd->ug_MainWindow.ug_pLabel);
+ }
+ UG_TRACE_END;
+
+ return;
+}
+
+/******************************
+** Prototype : mf_ug_navi_bar_create_navi_bar
+** Description :
+** Input : Evas_Object* parent
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+Evas_Object *mf_ug_navi_bar_create_navi_bar(Evas_Object *parent)
+{
+ UG_TRACE_BEGIN;
+ Evas_Object *navi_bar = NULL;
+ ug_mf_retvm_if(parent == NULL, NULL, "parent is NULL");
+
+ navi_bar = elm_naviframe_add(parent);
+ ug_mf_retvm_if(navi_bar == NULL, NULL, "Failed elm_navigationbar_add");
+ elm_naviframe_prev_btn_auto_pushed_set(navi_bar, EINA_FALSE);
+
+ evas_object_show(navi_bar);
+
+ UG_TRACE_END;
+ return navi_bar;
+}
+
+
+/******************************
+** Prototype : mf_ug_navi_bar_set_new_content
+** Description : Samsung
+** Input : Evas_Object *pLayout
+** Evas_Object *NaviContent
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+void mf_ug_navi_bar_set_new_content(Evas_Object *pLayout, Evas_Object *NaviContent)
+{
+ UG_TRACE_BEGIN;
+ Evas_Object *unUsed = elm_object_part_content_unset(pLayout, "part1");
+ evas_object_del(unUsed);
+ elm_object_part_content_set(pLayout, "part1", NaviContent);
+ UG_TRACE_END;
+}
+
+Evas_Object *mf_ug_navi_bar_create_box(Evas_Object * parent)
+{
+ UG_TRACE_BEGIN;
+ ug_mf_retvm_if(parent == NULL, NULL, "parent is NULL");
+
+ Evas_Object *box = NULL;
+ ug_debug("parent is [%p]", parent);
+ box = elm_box_add(parent);
+ ug_mf_retvm_if(box == NULL, NULL, "box is NULL");
+ elm_object_focus_set(box, EINA_FALSE);
+ evas_object_size_hint_weight_set(box, EVAS_HINT_EXPAND, EVAS_HINT_FILL);
+ evas_object_size_hint_align_set(box, EVAS_HINT_FILL, EVAS_HINT_FILL);
+ elm_box_clear(box);
+ evas_object_show(box);
+ UG_TRACE_END;
+ return box;
+
+}
+
+Evas_Object *mf_ug_navi_bar_create_layout(Evas_Object *parent, const char *edj, const char *grp_name)
+{
+ UG_TRACE_BEGIN;
+ ug_mf_retvm_if(parent == NULL, NULL, "parent is NULL");
+ ug_mf_retvm_if(edj == NULL, NULL, "edj is NULL");
+ ug_mf_retvm_if(grp_name == NULL, NULL, "grp_name is NULL");
+
+ Evas_Object *layout = NULL;
+
+ layout = elm_layout_add(parent);
+ ug_mf_retvm_if(layout == NULL, NULL, "layout is NULL");
+ elm_object_focus_set(layout, EINA_FALSE);
+ elm_layout_file_set(layout, edj, grp_name);
+ 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);
+ UG_TRACE_END;
+ return layout;
+
+}
+
+/******************************
+** Prototype : mf_ug_navi_bar_create_default_view
+** Description : Samsung
+** Input : void *data
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+Evas_Object *mf_ug_navi_bar_pathinfo_label_create(Evas_Object *parent, char *pathinfo)
+{
+ UG_TRACE_BEGIN;
+ ug_mf_retvm_if(parent == NULL, NULL, "parent is NULL");
+ ug_mf_retvm_if(pathinfo == NULL, NULL, "pathinfo is NULL");
+
+ Evas_Object *label = NULL;
+
+ label = elm_label_add(parent);
+ elm_object_focus_set(label, EINA_FALSE);
+ evas_object_size_hint_weight_set(label, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
+ evas_object_size_hint_align_set(label, EVAS_HINT_FILL, EVAS_HINT_FILL);
+ elm_object_text_set(label, pathinfo);
+ evas_object_show(label);
+ UG_SAFE_FREE_CHAR(pathinfo);
+ UG_TRACE_END;
+ return label;
+}
+
+Evas_Object *__mf_ug_navi_bar_pathinfo_create(Evas_Object *parent, char *pathinfo)
+{
+ UG_TRACE_BEGIN;
+ ug_mf_retvm_if(parent == NULL, NULL, "parent is NULL");
+ ug_mf_retvm_if(pathinfo == NULL, NULL, "pathinfo is NULL");
+
+ Evas_Object *layout = NULL;
+ Evas_Object *label = NULL;
+
+ layout = elm_layout_add(parent);
+ elm_object_focus_set(layout, EINA_FALSE);
+ elm_layout_file_set(layout, UG_EDJ_NAVIGATIONBAR, UG_GRP_PATH_INFO);
+ 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);
+
+ label = mf_ug_navi_bar_pathinfo_label_create(layout, pathinfo);
+ elm_object_part_content_set(layout, "info", label);
+ evas_object_show(layout);
+ UG_TRACE_END;
+ return layout;
+}
+
+void mf_ug_navi_bar_create_default_view(void *data)
+{
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+ ug_mf_retm_if(ugd == NULL, "ugd is NULL");
+
+ GString *title = NULL;
+ Evas_Object *pNaviLayout = NULL;
+ Evas_Object *newContent = NULL;
+ Evas_Object *box = NULL;
+ Evas_Object *top_layout = NULL;
+ Evas_Object *upper_genlist = NULL;
+ ugNaviBar *pNavi_s = mf_ug_navi_bar_get_in_use_navi(ugd);
+ ug_mf_retm_if(pNavi_s == NULL, "get navigation bar in use failed");
+
+
+ /*if the muisc is playing, destory the play */
+ if (0 != ugd->ug_ListPlay.ug_Player) {
+ mf_ug_list_play_destory_playing_file(ugd);
+ }
+
+ box = mf_ug_navi_bar_create_box(pNavi_s->ug_pNaviBar);
+ pNavi_s->ug_pNaviBox = box;
+
+ if (ugd->ug_Status.ug_bSettingEntry == true && ugd->ug_Status.ug_bInSettingView == true) {
+ top_layout = mf_ug_navi_bar_create_box(box);
+ evas_object_size_hint_min_set(top_layout, MF_UG_UPPER_WIDTH, MF_UG_UPPER_HEIGHT);
+ upper_genlist = mf_navi_bar_upper_create(top_layout);
+ mf_ug_genlist_goto_myfile_style_set(ugd);
+ mf_ug_genlist_goto_myfile_item_append(upper_genlist, ugd);
+ ugd->ug_Status.ug_bUpperFlag = true;
+ elm_box_pack_end(top_layout, upper_genlist);
+ } else if (!mf_ug_fm_svc_wapper_is_root_path(ugd)){
+ Evas_Object *pathinfo_layout = NULL;
+ Evas_Object *upper_layout = NULL;
+ char *pathinfo = NULL;
+ char *info = NULL;
+
+ top_layout = mf_ug_navi_bar_create_box(box);
+ evas_object_size_hint_weight_set(top_layout, EVAS_HINT_EXPAND, EVAS_HINT_FILL);
+ evas_object_size_hint_align_set(top_layout, EVAS_HINT_FILL, EVAS_HINT_FILL);
+ elm_box_clear(top_layout);
+ //evas_object_size_hint_min_set(top_layout, MF_UG_UPPER_WIDTH, MF_UG_UPPER_HEIGHT);
+
+ pathinfo = mf_ug_fm_svc_wapper_path_info_get(ugd->ug_Status.ug_pPath->str);
+ info = mf_ug_fm_svc_path_info_translate(pathinfo, MF_UG_PATH_INFO_MAX_LENGTH_PORTRAIT);
+ pathinfo_layout = __mf_ug_navi_bar_pathinfo_create(top_layout, info);
+
+ upper_layout = elm_layout_add(top_layout);
+ elm_object_focus_set(upper_layout, EINA_FALSE);
+ elm_layout_file_set(upper_layout, UG_EDJ_NAVIGATIONBAR, UG_GRP_UPPER_LAYOUT);
+ evas_object_size_hint_weight_set(upper_layout, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
+ evas_object_size_hint_align_set(upper_layout, EVAS_HINT_FILL, EVAS_HINT_FILL);
+ evas_object_show(upper_layout);
+
+ upper_genlist = mf_navi_bar_upper_create(top_layout);
+ //mf_ug_genlist_upper_style_set(ugd);
+ mf_ug_upper_genlist_item_append(upper_genlist, ugd);
+
+ elm_object_part_content_set(upper_layout, "upper", upper_genlist);
+ elm_box_pack_end(top_layout, pathinfo_layout);
+ elm_box_pack_end(top_layout, upper_layout);
+ ugd->ug_Status.ug_bUpperFlag = true;
+ }
+
+ if (top_layout) {
+ elm_box_pack_start(box, top_layout);
+ } else {
+ ugd->ug_Status.ug_bUpperFlag = true;
+ }
+
+ pNaviLayout = mf_ug_navi_bar_create_layout(box, UG_EDJ_NAVIGATIONBAR, UG_GRP_NAVI_VIEW);
+ pNavi_s->ug_pNaviLayout = pNaviLayout;
+ /*set content */
+ if (ugd->ug_UiGadget.ug_iSelectMode == SINGLE_ALL_MODE || ugd->ug_UiGadget.ug_iSelectMode == SINGLE_FILE_MODE) {
+ __mf_ug_navi_bar_create_group_radio_box(ugd);
+ }
+ newContent = mf_ug_genlist_create_content_list_view(ugd);
+ pNavi_s->ug_pContent = newContent;
+ /*set title segment or title */
+ if (mf_ug_fm_svc_wapper_is_root_path(ugd)) {
+ title = g_string_new(MF_UG_LABEL_MYFILES);
+ } else {
+ title = mf_ug_fm_svc_wapper_get_file_name(ugd->ug_Status.ug_pPath);
+ }
+
+ if (title != NULL) {
+ pNavi_s->ug_pNaviTitle = g_strdup(title->str);
+ g_string_free(title, TRUE);
+ title = NULL;
+ }
+ /*navigation view integration */
+ evas_object_show(newContent);
+ elm_object_part_content_set(pNaviLayout, "part1", newContent);
+ elm_box_pack_end(box, pNaviLayout);
+ __mf_ug_navi_bar_push_content(pNavi_s, box);
+
+ /*add control bar for navigation bar */
+ mf_ug_ctrl_bar_set(ugd, pNavi_s);
+#ifdef MF_UG_FEATURE_NEW_UX
+ if (ugd->ug_Status.ug_iMmcFlag == MMC_ON && !(ugd->ug_Status.ug_bSettingEntry == true && ugd->ug_Status.ug_bInSettingView == true))
+ elm_naviframe_item_title_visible_set(pNavi_s->ug_pNaviItem, EINA_FALSE);
+#endif
+ mf_ug_navi_bar_remove_previous_contents(ugd);
+ UG_TRACE_END;
+}
+
+
+/******************************
+** Prototype : mf_ug_navi_bar_get_in_use_navi
+** Description : Samsung
+** Input : void* data
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+ugNaviBar *mf_ug_navi_bar_get_in_use_navi(void *data)
+{
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+ ug_mf_retvm_if(ugd == NULL, NULL, "ugd is NULL");
+
+ Eina_List *pNaviList = ugd->ug_MainWindow.ug_pNaviBarList;
+ ug_mf_retvm_if(pNaviList == NULL, NULL, "pNavi_sList is NULL");
+
+ ugNaviBar *ret = NULL;
+ Eina_List *l = NULL;
+ void *item;
+
+ EINA_LIST_FOREACH(pNaviList, l, item) {
+ ret = (ugNaviBar *)item;
+ if (ret->ug_bNaviFlagInUse == TRUE) {
+ break;
+ } else {
+ ret = NULL;
+ }
+ }
+ ug_debug(" ret is [%p]", ret);
+ UG_TRACE_END;
+ return ret;
+}
+
+
+/******************************
+** Prototype : mf_ug_navi_bar_reset_navi_object
+** Description : Samsung
+** Input : ugNaviBar *pNavi_s
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+void mf_ug_navi_bar_reset_navi_object(ugNaviBar *pNavi_s)
+{
+ UG_TRACE_BEGIN;
+ ug_mf_retm_if(pNavi_s == NULL, "pNavi_s is NULL");
+
+ UG_SAFE_FREE_OBJ(pNavi_s->ug_pNaviBar);
+ pNavi_s->ug_pContent = NULL;
+ pNavi_s->ug_pNaviCtrlBar = NULL;
+ pNavi_s->ug_pNaviTitle = NULL;
+ if (pNavi_s->ug_pCurrentPath != NULL) {
+ free(pNavi_s->ug_pCurrentPath);
+ pNavi_s->ug_pCurrentPath = NULL;
+ }
+ if (pNavi_s->ug_pNaviLabel != NULL)
+ free(pNavi_s->ug_pNaviLabel);
+ pNavi_s->ug_pNaviLabel = NULL;
+ UG_TRACE_END;
+}
+
+/******************************
+** Prototype : mf_ug_navi_bar_get_navi_struct_by_navi
+** Description : Samsung
+** Input : void* data
+** Evas_Object* pNaviBar
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+ugNaviBar *mf_ug_navi_bar_get_navi_struct_by_navi(void *data, Evas_Object *pNaviBar)
+{
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+ ug_mf_retvm_if(ugd == NULL, NULL, "ugd is NULL");
+ ug_mf_retvm_if(pNaviBar == NULL, NULL, "pNaviBar is NULL");
+
+ Eina_List *pNaviList = ugd->ug_MainWindow.ug_pNaviBarList;
+ ug_mf_retvm_if(pNaviList == NULL, NULL, "pNavi_sList is NULL");
+
+ Eina_List *l = NULL;
+ void *item = NULL;
+
+ ugNaviBar *ret = NULL;
+ EINA_LIST_FOREACH(pNaviList, l, item) {
+ if (((ugNaviBar *)item)->ug_pNaviBar == pNaviBar) {
+ ret = (ugNaviBar *)item;
+ break;
+ }
+ }
+ UG_TRACE_END;
+ return ret;
+}
+
+
+/******************************
+** Prototype : mf_ug_navi_bar_get_navi_struct_by_label
+** Description : Samsung
+** Input : void* data
+** const char* pNaviLabel
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+ugNaviBar *mf_ug_navi_bar_get_navi_struct_by_label(void *data, const char *pNaviLabel)
+{
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+ ug_mf_retvm_if(ugd == NULL, NULL, "ugd is NULL");
+ ug_mf_retvm_if(pNaviLabel == NULL, NULL, "pNaviLabel is NULL");
+
+ Eina_List *l = NULL;
+ void *item = NULL;
+
+ ugNaviBar *ret = NULL;
+ EINA_LIST_FOREACH(ugd->ug_MainWindow.ug_pNaviBarList, l, item) {
+ if (g_strcmp0(((ugNaviBar *)item)->ug_pNaviLabel, pNaviLabel) == 0) {
+ ret = (ugNaviBar *)item;
+ break;
+ }
+ }
+ UG_TRACE_END;
+ return ret;
+}
+
+
+/******************************
+** Prototype : mf_ug_navi_bar_remove_navi_list_item_by_label
+** Description : Samsung
+** Input : void *data
+** const char* pNaviLabel
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+void mf_ug_navi_bar_remove_navi_list_item_by_label(void *data, const char *pNaviLabel)
+{
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+ ug_mf_retm_if(ugd == NULL, "ugd is NULL");
+ ug_mf_retm_if(pNaviLabel == NULL, "pNaviLabel is NULL");
+
+ bool bInUseFlag = FALSE;
+
+ ugNaviBar *pNavi_s = mf_ug_navi_bar_get_navi_struct_by_label(ugd, pNaviLabel);
+
+ if (pNavi_s == NULL) {
+ return;
+ }
+ Eina_List *plistNaviMMC = eina_list_data_find_list(ugd->ug_MainWindow.ug_pNaviBarList, pNavi_s);
+ ugd->ug_MainWindow.ug_pNaviBarList = eina_list_remove_list(ugd->ug_MainWindow.ug_pNaviBarList, plistNaviMMC);
+
+ if (pNavi_s->ug_bNaviFlagInUse == TRUE) {
+ bInUseFlag = TRUE;
+ }
+
+ mf_ug_navi_bar_reset_navi_object(pNavi_s);
+
+ if (bInUseFlag == TRUE) {
+ pNavi_s = (ugNaviBar *)eina_list_nth(ugd->ug_MainWindow.ug_pNaviBarList, 0);
+ pNavi_s->ug_bNaviFlagInUse = TRUE;
+ }
+ UG_TRACE_END;
+}
+
+
+/******************************
+** Prototype : mf_ug_navi_bar_refresh_navibar_recovered_view
+** Description : Samsung
+** Input : void *data
+** ugNaviBar* pNaviStruct
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+void mf_ug_navi_bar_refresh_navibar_recovered_view(void *data, ugNaviBar *pNaviStruct)
+{
+ UG_TRACE_BEGIN;
+ ugData *ugd = (ugData *)data;
+ ug_mf_retm_if(ugd == NULL, "ugd is NULL");
+ ug_mf_retm_if(pNaviStruct == NULL, "pNaviStruct is NULL");
+
+ if (ugd->ug_Status.ug_pPath != NULL) {
+ g_string_free(ugd->ug_Status.ug_pPath, TRUE);
+ ugd->ug_Status.ug_pPath = NULL;
+ }
+ ugd->ug_Status.ug_pPath = g_string_new(pNaviStruct->ug_pCurrentPath);
+ Evas_Object *newContent = mf_ug_genlist_create_content_list_view(ugd);
+
+ pNaviStruct->ug_pContent = newContent;
+ mf_ug_navi_bar_set_new_content(pNaviStruct->ug_pNaviLayout, newContent);
+ UG_TRACE_END;
+}
+
+void mf_ug_navi_bar_transition_finished_cb(void *data, Evas_Object *obj, void *event_info)
+{
+ UG_TRACE_BEGIN;
+ ug_mf_retm_if(data == NULL, "data is NULL");
+ ug_mf_retm_if(obj == NULL, "obj is NULL");
+ ugData *ugd = (ugData *)data;
+ ugNaviBar *pNavi_s = mf_ug_navi_bar_get_in_use_navi(ugd);
+ Elm_Object_Item *it = pNavi_s->ug_pPreNaviItem;
+ UG_SAFE_DEL_NAVI_ITEM(it);
+ pNavi_s->ug_pPreNaviItem = NULL;
+ mf_ug_navi_bar_set_blocking(data, false);
+ evas_object_smart_callback_del(obj, "transition,finished", mf_ug_navi_bar_transition_finished_cb);
+ UG_TRACE_END;
+}
+
+void mf_ug_navi_bar_remove_previous_contents(void *data)
+{
+ UG_TRACE_BEGIN;
+
+ ug_mf_retm_if(data == NULL, "data is NULL");
+ ugData *ugd = (ugData *)data;
+ Evas_Object *pNaviBar = NULL;
+ ugNaviBar *pNavi_s = mf_ug_navi_bar_get_in_use_navi(ugd);
+ if (pNavi_s && pNavi_s->ug_pNaviBar) {
+ pNaviBar = pNavi_s->ug_pNaviBar;
+ mf_ug_navi_bar_set_blocking(data, true);
+ evas_object_smart_callback_add(pNaviBar, "transition,finished", mf_ug_navi_bar_transition_finished_cb, ugd);
+ }
+ UG_TRACE_END;
+}
+
+void mf_ug_navi_bar_del_item_directly(void *data)
+{
+ UG_TRACE_BEGIN;
+ ug_mf_retm_if(data == NULL, "data is NULL");
+ ugData *ugd = (ugData *)data;
+
+ if (ugd->ug_Status.ug_b_NaviPushFlag) {
+ ugNaviBar *pNavi_s_previous = NULL;
+ pNavi_s_previous = mf_ug_navi_bar_get_in_use_navi(ugd) ;
+ if(pNavi_s_previous && pNavi_s_previous->ug_pPreNaviItem)
+ {
+ UG_SAFE_DEL_NAVI_ITEM(pNavi_s_previous->ug_pPreNaviItem);
+ mf_ug_navi_bar_set_blocking(ugd, false);
+ evas_object_smart_callback_del(pNavi_s_previous->ug_pNaviBar, "transition,finished", mf_ug_navi_bar_transition_finished_cb);
+ }
+ }
+ UG_TRACE_END;
+}
+
+
+void mf_ug_navi_bar_set_blocking(void *data, bool bblock_during_transition)
+{
+ ug_mf_retm_if(data == NULL, "data is NULL");
+ ugData *ugd = (ugData *)data;
+
+ ugd->ug_Status.ug_bCancelDisableFlag = bblock_during_transition;
+ ugd->ug_Status.ug_b_NaviPushFlag = bblock_during_transition;
+ return;
+}
+
+ugNaviBar *ug_mf_navi_bar_get_navi_from_navilist(Eina_List *navilist, const char *label)
+{
+
+ UG_TRACE_BEGIN;
+ ug_mf_retvm_if(navilist == NULL, NULL, "navilist is NULL");
+ ug_mf_retvm_if(label == NULL, NULL, "label is NULL");
+
+ void *data = NULL;
+ ugNaviBar *pNavi = NULL;
+ Eina_List *l = NULL;
+ EINA_LIST_FOREACH(navilist, l, data) {
+ if (data) {
+ pNavi = (ugNaviBar *)data;
+ if (pNavi && pNavi->ug_pNaviLabel && g_strcmp0(label, pNavi->ug_pNaviLabel) == 0)
+ return pNavi;
+ else
+ continue;
+ }
+ }
+ return NULL;
+}
+
+Evas_Object *ug_mf_navi_bar_get_navibar_from_navilist(Eina_List *navilist, const char *label)
+{
+ ugNaviBar *pNavi_s = NULL;
+ pNavi_s = ug_mf_navi_bar_get_navi_from_navilist(navilist, label);
+ if (pNavi_s && pNavi_s->ug_pNaviBar)
+ return pNavi_s->ug_pNaviBar;
+ else
+ return NULL;
+}
+
diff --git a/src/widget/mf-ug-popup.c b/src/widget/mf-ug-popup.c
new file mode 100755
index 0000000..cceeb69
--- /dev/null
+++ b/src/widget/mf-ug-popup.c
@@ -0,0 +1,95 @@
+/*
+ * Copyright 2012 Samsung Electronics Co., Ltd
+ *
+ * Licensed under the Flora License, Version 1.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.tizenopensource.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 "mf-ug-util.h"
+#include "mf-ug-winset.h"
+#include "mf-ug-resource.h"
+
+
+/******************************
+** Prototype : mfPopupCreate
+** Description :
+** Input : void *data
+** ePopMode popupMode
+** char *title
+** char *context
+** char *first_btn_text
+** char *second_btn_text
+** char *third_btn_text
+** Evas_Smart_Cb func
+** void* param
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+void mf_ug_popup_create(void *data, mf_ug_popup_mode popupMode, char *title, char *context, char *first_btn_text, char *second_btn_text,
+ char *third_btn_text, Evas_Smart_Cb func, void *param)
+{
+ Evas_Object *popup;
+ ugData *ugd = (ugData *)data;
+ ug_mf_retm_if(ugd == NULL, "ugd is NULL");
+ Evas_Object *btn1 = NULL;
+ Evas_Object *btn2 = NULL;
+
+ popup = elm_popup_add(ugd->ug_MainWindow.ug_pMainLayout);
+ ugd->ug_MainWindow.ug_pNormalPopup = popup;
+ evas_object_size_hint_weight_set(popup, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
+ if (title) {
+ elm_object_part_text_set(popup, "elm.title", title);
+ }
+ if (context && popupMode != UG_POPMODE_PROGRESSBAR) {
+ elm_object_text_set(popup, context);
+ }
+ switch (popupMode) {
+ case UG_POPMODE_TEXT:
+ case UG_POPMODE_TITLE_TEXT:
+ elm_popup_timeout_set(popup, 3);
+ if (func) {
+ evas_object_smart_callback_add(popup, "response", (Evas_Smart_Cb) func, param);
+ }
+ break;
+ case UG_POPMODE_TEXT_TWO_BTN:
+ case UG_POPMODE_TITLE_TEXT_TWO_BTN:
+ btn1 = __ug_mf_popup_button_create(popup, first_btn_text);
+ btn2 = __ug_mf_popup_button_create(popup, second_btn_text);
+
+ evas_object_smart_callback_add(btn1, "clicked", func, param);
+ evas_object_smart_callback_add(btn2, "clicked", func, param);
+ elm_object_part_content_set(popup, "button1", btn1);
+ elm_object_part_content_set(popup, "button2", btn2);
+ break;
+ case UG_POPMODE_TEXT_BTN:
+ case UG_POPMODE_TITLE_TEXT_BTN:
+ btn1 = __ug_mf_popup_button_create(popup, MF_UG_LABEL_OK);
+ evas_object_smart_callback_add(btn1, "clicked", func, param);
+ elm_object_part_content_set(popup, "button1", btn1);
+ break;
+ default:
+ return;
+ }
+ evas_object_show(popup);
+}
+
diff --git a/src/widget/mf-ug-tab-bar.c b/src/widget/mf-ug-tab-bar.c
new file mode 100755
index 0000000..26ea0e3
--- /dev/null
+++ b/src/widget/mf-ug-tab-bar.c
@@ -0,0 +1,251 @@
+/*
+ * Copyright 2012 Samsung Electronics Co., Ltd
+ *
+ * Licensed under the Flora License, Version 1.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.tizenopensource.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 "mf-ug-winset.h"
+#include "mf-ug-util.h"
+#include "mf-ug-fm-svc-wrapper.h"
+
+
+/******************************
+** Prototype : mf_ug_tab_bar_create
+** Description : Samsung
+** Input : Evas_Object *parent
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+Evas_Object *mf_ug_tab_bar_create(Evas_Object *parent)
+{
+ UG_TRACE_BEGIN;
+ ug_mf_retv_if(parent == NULL, NULL);
+ Evas_Object *toolbar = elm_toolbar_add(parent);
+ elm_toolbar_shrink_mode_set(toolbar, ELM_TOOLBAR_SHRINK_EXPAND);
+ elm_object_style_set(toolbar, "tabbar");
+ elm_toolbar_select_mode_set(toolbar, ELM_OBJECT_SELECT_MODE_ALWAYS);
+ elm_toolbar_homogeneous_set(toolbar, EINA_FALSE);
+
+ UG_TRACE_BEGIN;
+ return toolbar;
+}
+
+
+
+/******************************
+** Prototype : mf_ug_tab_bar_append_item
+** Description : Samsung
+** Input : Evas_Object *pTabBar
+** char *pTabIconPath
+** char *pTabBarLabel
+** Evas_Object *pTabView
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+Elm_Object_Item *mf_ug_tab_bar_append_item(Evas_Object *pTabBar, char *pTabIconPath, char *pTabBarLabel, void *user_data)
+{
+ UG_TRACE_BEGIN;
+ ug_mf_retv_if(pTabBar == NULL, NULL);
+
+ Elm_Object_Item *pItem = NULL;
+ pItem = elm_toolbar_item_append(pTabBar, pTabIconPath, pTabBarLabel, mf_ug_cb_tab_bar_cb, user_data);
+ UG_TRACE_END;
+ return pItem;
+}
+
+
+
+/******************************
+** Prototype : mf_ug_tab_bar_set_item_view
+** Description : Samsung
+** Input : Elm_Object_Item *it
+** Evas_Object * view
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+void mf_ug_tab_bar_set_item_view(Evas_Object *parent, Evas_Object *tab_layout, Evas_Object *view)
+{
+ UG_TRACE_BEGIN;
+ Evas_Object *layout = tab_layout;
+ Evas_Object *unset = elm_object_part_content_get(layout, "elm.swallow.content");
+ if (unset) {
+ elm_object_part_content_unset(layout, "elm.swallow.content");
+ evas_object_hide(unset);
+ }
+
+ elm_object_part_content_set(layout, "elm.swallow.content", view);
+ UG_TRACE_END;
+}
+
+/******************************
+** Prototype : mf_ug_tab_bar_remove_item_by_label
+** Description : Samsung
+** Input : Evas_Object *pTabBar
+** char *pTabLabel
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+void mf_ug_tab_bar_remove_item_by_label(Evas_Object *pTabBar, char *pTabLabel)
+{
+ UG_TRACE_BEGIN;
+ Elm_Object_Item *pItem = NULL;
+ pItem = elm_toolbar_first_item_get(pTabBar);
+
+ while(pItem) {
+ if (g_strcmp0(pTabLabel, elm_object_item_text_get(pItem)) == 0) {
+ elm_object_item_del(pItem);
+ return;
+ }
+ pItem = elm_toolbar_item_next_get(pItem);
+ }
+ UG_TRACE_END;
+}
+
+
+/******************************
+** Prototype : mf_ug_tab_bar_remove_all_items
+** Description : Samsung
+** Input : Evas_Object *pTabBar
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+void mf_ug_tab_bar_remove_all_items(Evas_Object *pTabBar)
+{
+
+ UG_TRACE_BEGIN;
+ Elm_Object_Item *it = NULL;
+ Elm_Object_Item *pNext = NULL;
+
+ it = elm_toolbar_first_item_get(pTabBar);
+ while(it) {
+ pNext = elm_toolbar_item_next_get(it);
+ elm_object_item_del(it);
+ it = pNext;
+ }
+ UG_TRACE_END;
+}
+
+/******************************
+** Prototype : mf_ug_tab_bar_set_selected_item
+** Description : Samsung
+** Input : Elm_Object_Item* pItem
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+void mf_ug_tab_bar_set_selected_item(Elm_Object_Item *pItem)
+{
+ UG_TRACE_BEGIN;
+ elm_toolbar_item_selected_set(pItem, EINA_TRUE);
+ UG_TRACE_END;
+}
+
+
+
+
+/******************************
+** Prototype : mf_ug_tab_bar_set_item_disable
+** Description : Samsung
+** Input : Evas_Object *pTabBar
+** Eina_Bool disable
+** Output : None
+** Return Value :
+** Calls :
+** Called By :
+**
+** History :
+** 1.Date : 2010/12/10
+** Author : Samsung
+** Modification : Created function
+**
+******************************/
+void mf_ug_tab_bar_set_item_disable(Evas_Object *pTabBar, Eina_Bool disable)
+{
+ Elm_Object_Item *pCurrentItem = NULL;
+
+ if (pTabBar != NULL) {
+
+ pCurrentItem = elm_toolbar_first_item_get(pTabBar);
+ while(pCurrentItem) {
+ elm_object_item_disabled_set(pCurrentItem, disable);
+ pCurrentItem = elm_toolbar_item_next_get(pCurrentItem);
+ }
+ }
+}
+
+int mf_ug_tab_bar_items_count_get(Evas_Object *pTabBar)
+{
+ ug_mf_retvm_if(pTabBar == NULL, 0, "pTabBar is NULL");
+
+ Elm_Object_Item *pCurrentItem = NULL;
+ int count = 0;
+
+ pCurrentItem = elm_toolbar_first_item_get(pTabBar);
+ while(pCurrentItem) {
+ count++;
+ pCurrentItem = elm_toolbar_item_next_get(pCurrentItem);
+ }
+
+ return count;
+}
+
diff --git a/ug_navibar_layout.edc b/ug_navibar_layout.edc
new file mode 100755
index 0000000..64c0b7d
--- /dev/null
+++ b/ug_navibar_layout.edc
@@ -0,0 +1,448 @@
+/*
+ * Copyright (c) Samsung Electronics Co., Ltd. All rights reserved.
+ *
+ * Licensed under the Flora Software License (the "License").
+ *
+ * You may obtain a copy of the License at
+ * http://www.tizenopensource.org/license
+ *
+ * Your use of this source code is conditioned on your acceptance of the
+ * terms and conditions of the License.
+ * If you do not agree to the terms and conditions of the License,
+ * do not use the source code herein.
+ *
+ * THIS SOURCE CODE IS LICENSED ONLY UNDER THE TERMS OF THE LICENSE.
+ *
+ * THIS SOURCE CODE IS DISTRIBUTED ON AN "AS-IS" BASIS AND "WITH ALL FAULTS",
+ * WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EXPRESS OR IMPLIED.
+ *
+ * See the License for specific language governing permissions and limitations.
+ */
+
+#define UG_BASIC_W 480
+#define UG_BASIC_H 800
+
+#define UG_MAIN_W 720
+#define UG_MAIN_H 1280
+
+#define UG_MF_SCALE_W (UG_MAIN_W/UG_BASIC_W)
+#define UG_MF_SCALE_H (UG_MAIN_H/UG_BASIC_H)
+
+#define UG_THUMBNAIL_W 50*UG_MF_SCALE_W
+#define UG_THUMBNAIL_H 50*UG_MF_SCALE_H
+
+#define UG_MEMORY_SUB_THUMB_W 40*UG_MF_SCALE_W
+#define UG_MEMORY_SUB_THUMB_H 25*UG_MF_SCALE_H
+
+#define UG_SOUND_BUTTON_W 240*UG_MF_SCALE_W
+#define UG_SOUND_BUTTON_H 46*UG_MF_SCALE_H
+
+#define GENLIST_ITEM_H 71*UG_MF_SCALE_H
+#define PATH_INFO_H 30*UG_MF_SCALE_H
+#define PATH_INFO_LABEL_H 25
+#define PATH_INFO_BG_COLOR 200 200 200 127
+#define BOTTOM_LINE_COLOR 199 199 199 255
+
+
+#define MF_UG_PART_PADDING_TOP( param_padding_size ) \
+ part { name: "elm.padding.top"; \
+ type: RECT; \
+ scale: 1; \
+ description { \
+ state: "default" 0.0; \
+ min: 0 param_padding_size; \
+ fixed: 0 1; \
+ visible: 0; \
+ rel2.relative: 1.0 0.0; \
+ align: 0.0 0.0; \
+ } \
+ }
+#define MF_UG_PART_PADDING_BOTTOM( param_padding_size ) \
+ part { name: "elm.padding.bottom"; \
+ type: RECT; \
+ scale: 1; \
+ description { state: "default" 0.0; \
+ min: 0 param_padding_size; \
+ fixed: 0 1; \
+ visible: 0; \
+ rel1.relative: 0.0 1.0; \
+ align: 0.0 1.0; \
+ } \
+ }
+
+#define MF_UG_PART_PADDING_LEFT( param_padding_size ) \
+ part { name: "elm.padding.left"; \
+ type: RECT; \
+ scale: 1; \
+ description { state: "default" 0.0; \
+ min: param_padding_size 0; \
+ fixed: 1 0; \
+ visible: 0; \
+ rel2.relative: 0.0 1.0; \
+ align: 0.0 0.0; \
+ } \
+ }
+
+#define EFFECT_PROGRAMS(part_name, part_state, after_name) \
+ program \
+ { \
+ name: part_name; \
+ action: STATE_SET part_state 0.0;\
+ target: "icon"; \
+ transition: DECELERATE 0.03; \
+ after: after_name; \
+ }
+
+collections
+{
+ group
+ {
+ name: "navigation_view";
+ parts
+ {
+ part
+ {
+ name: "base";
+ type: RECT;
+ description
+ {
+ state: "default" 0.0;
+ rel1
+ {
+ relative: 0 0; offset: 0 0;
+ }
+ rel2
+ {
+ relative: 1 1; offset: -1 -1;
+ }
+ color: 0 0 0 0;
+ }
+ }
+ part
+ {
+ name: "part1";
+ type: SWALLOW;
+ scale: 1;
+ description
+ {
+ state: "default" 0.0;
+ visible: 1;
+ rel1
+ {
+ relative: 0.0 0.0; to:"base";
+ }
+ rel2
+ {
+ relative: 1.0 1.0; to:"base";
+ }
+ }
+ }
+ }
+ }
+
+ group
+ {
+ name: "noContent";
+ parts
+ {
+ part
+ {
+ name: "myfile.noContent.upper";
+ type: SWALLOW;
+ scale: 1;
+ description
+ {
+ state: "default" 0.0;
+ rel1
+ {
+ relative: 0.0 0.0;
+ }
+ rel2
+ {
+ relative: 1.0 0.0; offset: 0 90;
+ }
+ }
+ }
+ part
+ {
+ name: "myfile.noContent.content";
+ type: SWALLOW;
+ scale: 1;
+ description
+ {
+ state: "default" 0.0;
+ rel1
+ {
+ relative: 0.0 1.0;
+ offset: 0 0;
+ to_y: "myfile.noContent.upper";
+ }
+ rel2
+ {
+ relative: 1.0 1.0;
+ }
+ }
+ }
+
+ }
+ }
+ group
+ {
+ name: "effect/model/list";
+ parts
+ {
+ part
+ {
+ name: "icon";
+ type: RECT;
+ mouse_events: 0;
+ scale: 1;
+ description
+ {
+ state: "default" 0.0;
+ max : UG_THUMBNAIL_W UG_THUMBNAIL_H;
+ fixed: 1 1;
+ align: 0.5 0.5;
+ aspect: 1.0 1.0;
+ rel1
+ {
+ relative: 0.0 0.0;
+ }
+ rel2
+ {
+ relative: 1.0 1.0;
+ }
+ visible: 0;
+ color: 0 0 0 255;
+ }
+ description
+ {
+ state: "min" 0.0;
+ inherit: "default" 0.0;
+ max: 0 0;
+ }
+ description
+ {
+ state: "level1" 0.0;
+ inherit: "default" 0.0;
+ rel1
+ {
+ relative: 0.0 0.0;
+ }
+ rel2
+ {
+ relative: 1.0 1.0;
+ }
+ }
+ }
+
+ part
+ {
+ name: "swallow_thumb";
+ type: SWALLOW;
+ mouse_events: 0;
+
+ scale: 1;
+ description
+ {
+ state: "default" 0.0;
+ align: 0.5 0.5;
+ rel1
+ {
+ to: "icon";
+ }
+ rel2
+ {
+ to: "icon";
+ }
+ }
+ }
+ part
+ {
+ name: "myfile.memory_icon.sub";
+ type: SWALLOW;
+ scale: 1;
+ description
+ {
+ state: "default" 0.0;
+ max : UG_MEMORY_SUB_THUMB_W UG_MEMORY_SUB_THUMB_H;
+ min : UG_MEMORY_SUB_THUMB_W UG_MEMORY_SUB_THUMB_H;
+ fixed: 1 1;
+ rel1
+ {
+ relative:0.5 0.5; to:"icon";
+ }
+ rel2
+ {
+ relative:1.0 1.0;to:"icon";
+ }
+ }
+ }
+ }
+ programs
+ {
+ program
+ {
+ name: "effect_gen";
+ signal: "effect.gen";
+ source: "thumb";
+ action: STATE_SET "min" 0.0;
+ target: "icon";
+ after: "thumb_gen_1";
+ }
+ EFFECT_PROGRAMS("thumb_gen_1", "level1", "thumb_gen_2");
+ program
+ {
+ name: "thumb_gen_2";
+ action: STATE_SET "default" 0.0;
+ target: "icon";
+ transition: SINUSOIDAL 0.1;
+ }
+ }
+ }
+ group
+ {
+ name: "goto_myfile";
+ parts
+ {
+ part
+ {
+ name: "gotoButton";
+ type: SWALLOW;
+ description
+ {
+ state: "default" 0.0;
+ fixed: 1 1;
+ max : UG_SOUND_BUTTON_W UG_SOUND_BUTTON_H;
+ min : UG_SOUND_BUTTON_W UG_SOUND_BUTTON_H;
+ align: 0.5 0.5;
+ rel1
+ {
+ relative: 0.0 0.0;
+ }
+ rel2
+ {
+ relative: 1.0 1.0;
+ }
+ }
+ }
+ }
+ }
+
+ group
+ {
+ name:"upper_folder";
+ parts
+ {
+ part
+ {
+ name: "upper";
+ type: SWALLOW;
+ mouse_events: 1;
+ scale: 1;
+ description {
+ state: "default" 0.0;
+ min: UG_MAIN_W GENLIST_ITEM_H;
+ rel1
+ {
+ relative: 0.0 0.0;
+ }
+ rel2
+ {
+ relative: 1.0 1.0;
+ }
+ align: 0.5 0.5;
+ }
+ }
+ }
+ }
+ group
+ {
+ name: "pathinfo";
+ parts {
+ part
+ {
+ name: "base";
+ type: RECT;
+ repeat_events: 0;
+ scale: 1;
+ description {
+ state: "default" 0.0;
+ min: UG_MAIN_W PATH_INFO_H;
+ color: PATH_INFO_BG_COLOR;
+ }
+ }
+ part
+ {
+ name: "bg";
+ type: RECT;
+ clip_to: "disclip";
+ repeat_events: 0;
+ mouse_events: 0;
+ description {
+ state: "default" 0.0;
+ color: PATH_INFO_BG_COLOR;
+ }
+ }
+ MF_UG_PART_PADDING_TOP(0)
+ MF_UG_PART_PADDING_BOTTOM( 0 )
+ MF_UG_PART_PADDING_LEFT( 10 )
+ part
+ {
+ name: "bottom_line";
+ type: RECT;
+ mouse_events: 0;
+ description { state: "default" 0.0;
+ min: 0 1;
+ fixed: 0 1;
+ visible: 1;
+ color: BOTTOM_LINE_COLOR;
+ rel1
+ {
+ relative: 0.0 1.0;
+ offset: 0 -1;
+ }
+ }
+ }
+ part
+ {
+ name: "info";
+ clip_to: "disclip";
+ type: SWALLOW;
+ scale: 1;
+ description { state: "default" 0.0;
+ min: 0 PATH_INFO_LABEL_H;
+ max: 0 PATH_INFO_LABEL_H;
+ fixed: 0 1;
+ align: 0.0 0.5;
+ rel1
+ {
+ relative: 1.0 1.0;
+ offset: 0 0;
+ to_x: "elm.padding.left";
+ to_y: "elm.padding.top";
+ }
+ rel2
+ {
+ relative: 1.0 0.0;
+ offset: 0 0;
+ to_x: "elm.padding.left";
+ to_y: "elm.padding.bottom";
+ }
+ }
+ }
+
+ part
+ {
+ name: "disclip";
+ type: RECT;
+ description
+ {
+ state: "default" 0.0;
+ }
+ }
+ }
+ }
+
+}
+