-Giyeol Ok <giyeol.ok@samsung.com>\r
-Suchang Woo <Suchang Woo@samsung.com>\r
+Giyeol Ok <giyeol.ok at samsung dot com>\r
+Taeyoung Kim <ty317.kim at samsung dot com>\r
ADD_SUBDIRECTORY(poweroff-popup)
ADD_SUBDIRECTORY(lowbatt-popup)
ADD_SUBDIRECTORY(lowmem-popup)
-ADD_SUBDIRECTORY(usbotg-popup)
-ADD_SUBDIRECTORY(usbotg-unmount-popup)
ADD_SUBDIRECTORY(mmc-popup)
+ADD_SUBDIRECTORY(usb-popup)
+ADD_SUBDIRECTORY(usbotg-popup)
############## END ##############
-
- Apache License
- Version 2.0, January 2004
- http://www.apache.org/licenses/
-
- TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
-
- 1. Definitions.
-
- "License" shall mean the terms and conditions for use, reproduction,
- and distribution as defined by Sections 1 through 9 of this document.
-
- "Licensor" shall mean the copyright owner or entity authorized by
- the copyright owner that is granting the License.
-
- "Legal Entity" shall mean the union of the acting entity and all
- other entities that control, are controlled by, or are under common
- control with that entity. For the purposes of this definition,
- "control" means (i) the power, direct or indirect, to cause the
- direction or management of such entity, whether by contract or
- otherwise, or (ii) ownership of fifty percent (50%) or more of the
- outstanding shares, or (iii) beneficial ownership of such entity.
-
- "You" (or "Your") shall mean an individual or Legal Entity
- exercising permissions granted by this License.
-
- "Source" form shall mean the preferred form for making modifications,
- including but not limited to software source code, documentation
- source, and configuration files.
-
- "Object" form shall mean any form resulting from mechanical
- transformation or translation of a Source form, including but
- not limited to compiled object code, generated documentation,
- and conversions to other media types.
-
- "Work" shall mean the work of authorship, whether in Source or
- Object form, made available under the License, as indicated by a
- copyright notice that is included in or attached to the work
- (an example is provided in the Appendix below).
-
- "Derivative Works" shall mean any work, whether in Source or Object
- form, that is based on (or derived from) the Work and for which the
- editorial revisions, annotations, elaborations, or other modifications
- represent, as a whole, an original work of authorship. For the purposes
- of this License, Derivative Works shall not include works that remain
- separable from, or merely link (or bind by name) to the interfaces of,
- the Work and Derivative Works thereof.
-
- "Contribution" shall mean any work of authorship, including
- the original version of the Work and any modifications or additions
- to that Work or Derivative Works thereof, that is intentionally
- submitted to Licensor for inclusion in the Work by the copyright owner
- or by an individual or Legal Entity authorized to submit on behalf of
- the copyright owner. For the purposes of this definition, "submitted"
- means any form of electronic, verbal, or written communication sent
- to the Licensor or its representatives, including but not limited to
- communication on electronic mailing lists, source code control systems,
- and issue tracking systems that are managed by, or on behalf of, the
- Licensor for the purpose of discussing and improving the Work, but
- excluding communication that is conspicuously marked or otherwise
- designated in writing by the copyright owner as "Not a Contribution."
-
- "Contributor" shall mean Licensor and any individual or Legal Entity
- on behalf of whom a Contribution has been received by Licensor and
- subsequently incorporated within the Work.
-
- 2. Grant of Copyright License. Subject to the terms and conditions of
- this License, each Contributor hereby grants to You a perpetual,
- worldwide, non-exclusive, no-charge, royalty-free, irrevocable
- copyright license to reproduce, prepare Derivative Works of,
- publicly display, publicly perform, sublicense, and distribute the
- Work and such Derivative Works in Source or Object form.
-
- 3. Grant of Patent License. Subject to the terms and conditions of
- this License, each Contributor hereby grants to You a perpetual,
- worldwide, non-exclusive, no-charge, royalty-free, irrevocable
- (except as stated in this section) patent license to make, have made,
- use, offer to sell, sell, import, and otherwise transfer the Work,
- where such license applies only to those patent claims licensable
- by such Contributor that are necessarily infringed by their
- Contribution(s) alone or by combination of their Contribution(s)
- with the Work to which such Contribution(s) was submitted. If You
- institute patent litigation against any entity (including a
- cross-claim or counterclaim in a lawsuit) alleging that the Work
- or a Contribution incorporated within the Work constitutes direct
- or contributory patent infringement, then any patent licenses
- granted to You under this License for that Work shall terminate
- as of the date such litigation is filed.
-
- 4. Redistribution. You may reproduce and distribute copies of the
- Work or Derivative Works thereof in any medium, with or without
- modifications, and in Source or Object form, provided that You
- meet the following conditions:
-
- (a) You must give any other recipients of the Work or
- Derivative Works a copy of this License; and
-
- (b) You must cause any modified files to carry prominent notices
- stating that You changed the files; and
-
- (c) You must retain, in the Source form of any Derivative Works
- that You distribute, all copyright, patent, trademark, and
- attribution notices from the Source form of the Work,
- excluding those notices that do not pertain to any part of
- the Derivative Works; and
-
- (d) If the Work includes a "NOTICE" text file as part of its
- distribution, then any Derivative Works that You distribute must
- include a readable copy of the attribution notices contained
- within such NOTICE file, excluding those notices that do not
- pertain to any part of the Derivative Works, in at least one
- of the following places: within a NOTICE text file distributed
- as part of the Derivative Works; within the Source form or
- documentation, if provided along with the Derivative Works; or,
- within a display generated by the Derivative Works, if and
- wherever such third-party notices normally appear. The contents
- of the NOTICE file are for informational purposes only and
- do not modify the License. You may add Your own attribution
- notices within Derivative Works that You distribute, alongside
- or as an addendum to the NOTICE text from the Work, provided
- that such additional attribution notices cannot be construed
- as modifying the License.
-
- You may add Your own copyright statement to Your modifications and
- may provide additional or different license terms and conditions
- for use, reproduction, or distribution of Your modifications, or
- for any such Derivative Works as a whole, provided Your use,
- reproduction, and distribution of the Work otherwise complies with
- the conditions stated in this License.
-
- 5. Submission of Contributions. Unless You explicitly state otherwise,
- any Contribution intentionally submitted for inclusion in the Work
- by You to the Licensor shall be under the terms and conditions of
- this License, without any additional terms or conditions.
- Notwithstanding the above, nothing herein shall supersede or modify
- the terms of any separate license agreement you may have executed
- with Licensor regarding such Contributions.
-
- 6. Trademarks. This License does not grant permission to use the trade
- names, trademarks, service marks, or product names of the Licensor,
- except as required for reasonable and customary use in describing the
- origin of the Work and reproducing the content of the NOTICE file.
-
- 7. Disclaimer of Warranty. Unless required by applicable law or
- agreed to in writing, Licensor provides the Work (and each
- Contributor provides its Contributions) on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
- implied, including, without limitation, any warranties or conditions
- of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
- PARTICULAR PURPOSE. You are solely responsible for determining the
- appropriateness of using or redistributing the Work and assume any
- risks associated with Your exercise of permissions under this License.
-
- 8. Limitation of Liability. In no event and under no legal theory,
- whether in tort (including negligence), contract, or otherwise,
- unless required by applicable law (such as deliberate and grossly
- negligent acts) or agreed to in writing, shall any Contributor be
- liable to You for damages, including any direct, indirect, special,
- incidental, or consequential damages of any character arising as a
- result of this License or out of the use or inability to use the
- Work (including but not limited to damages for loss of goodwill,
- work stoppage, computer failure or malfunction, or any and all
- other commercial damages or losses), even if such Contributor
- has been advised of the possibility of such damages.
-
- 9. Accepting Warranty or Additional Liability. While redistributing
- the Work or Derivative Works thereof, You may choose to offer,
- and charge a fee for, acceptance of support, warranty, indemnity,
- or other liability obligations and/or rights consistent with this
- License. However, in accepting such obligations, You may act only
- on Your own behalf and on Your sole responsibility, not on behalf
- of any other Contributor, and only if You agree to indemnify,
- defend, and hold each Contributor harmless for any liability
- incurred by, or claims asserted against, such Contributor by reason
- of your accepting any such warranty or additional liability.
-
- END OF TERMS AND CONDITIONS
-
- APPENDIX: How to apply the Apache License to your work.
-
- To apply the Apache License to your work, attach the following
- boilerplate notice, with the fields enclosed by brackets "[]"
- replaced with your own identifying information. (Don't include
- the brackets!) The text should be enclosed in the appropriate
- comment syntax for the file format. We also recommend that a
- file or class name and description of purpose be included on the
- same "printed page" as the copyright notice for easier
- identification within third-party archives.
-
- Copyright [yyyy] [name of copyright owner]
-
- Licensed under the Apache License, Version 2.0 (the "License");
- you may not use this file except in compliance with the License.
- You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing, software
- distributed under the License is distributed on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- See the License for the specific language governing permissions and
- limitations under the License.
+Copyright (c) 2000 - 2011 Samsung Electronics Co., Ltd. All rights reserved.\r
+\r
+ Apache License\r
+ Version 2.0, January 2004\r
+ http://www.apache.org/licenses/\r
+\r
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION\r
+\r
+ 1. Definitions.\r
+\r
+ "License" shall mean the terms and conditions for use, reproduction,\r
+ and distribution as defined by Sections 1 through 9 of this document.\r
+\r
+ "Licensor" shall mean the copyright owner or entity authorized by\r
+ the copyright owner that is granting the License.\r
+\r
+ "Legal Entity" shall mean the union of the acting entity and all\r
+ other entities that control, are controlled by, or are under common\r
+ control with that entity. For the purposes of this definition,\r
+ "control" means (i) the power, direct or indirect, to cause the\r
+ direction or management of such entity, whether by contract or\r
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the\r
+ outstanding shares, or (iii) beneficial ownership of such entity.\r
+\r
+ "You" (or "Your") shall mean an individual or Legal Entity\r
+ exercising permissions granted by this License.\r
+\r
+ "Source" form shall mean the preferred form for making modifications,\r
+ including but not limited to software source code, documentation\r
+ source, and configuration files.\r
+\r
+ "Object" form shall mean any form resulting from mechanical\r
+ transformation or translation of a Source form, including but\r
+ not limited to compiled object code, generated documentation,\r
+ and conversions to other media types.\r
+\r
+ "Work" shall mean the work of authorship, whether in Source or\r
+ Object form, made available under the License, as indicated by a\r
+ copyright notice that is included in or attached to the work\r
+ (an example is provided in the Appendix below).\r
+\r
+ "Derivative Works" shall mean any work, whether in Source or Object\r
+ form, that is based on (or derived from) the Work and for which the\r
+ editorial revisions, annotations, elaborations, or other modifications\r
+ represent, as a whole, an original work of authorship. For the purposes\r
+ of this License, Derivative Works shall not include works that remain\r
+ separable from, or merely link (or bind by name) to the interfaces of,\r
+ the Work and Derivative Works thereof.\r
+\r
+ "Contribution" shall mean any work of authorship, including\r
+ the original version of the Work and any modifications or additions\r
+ to that Work or Derivative Works thereof, that is intentionally\r
+ submitted to Licensor for inclusion in the Work by the copyright owner\r
+ or by an individual or Legal Entity authorized to submit on behalf of\r
+ the copyright owner. For the purposes of this definition, "submitted"\r
+ means any form of electronic, verbal, or written communication sent\r
+ to the Licensor or its representatives, including but not limited to\r
+ communication on electronic mailing lists, source code control systems,\r
+ and issue tracking systems that are managed by, or on behalf of, the\r
+ Licensor for the purpose of discussing and improving the Work, but\r
+ excluding communication that is conspicuously marked or otherwise\r
+ designated in writing by the copyright owner as "Not a Contribution."\r
+\r
+ "Contributor" shall mean Licensor and any individual or Legal Entity\r
+ on behalf of whom a Contribution has been received by Licensor and\r
+ subsequently incorporated within the Work.\r
+\r
+ 2. Grant of Copyright License. Subject to the terms and conditions of\r
+ this License, each Contributor hereby grants to You a perpetual,\r
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable\r
+ copyright license to reproduce, prepare Derivative Works of,\r
+ publicly display, publicly perform, sublicense, and distribute the\r
+ Work and such Derivative Works in Source or Object form.\r
+\r
+ 3. Grant of Patent License. Subject to the terms and conditions of\r
+ this License, each Contributor hereby grants to You a perpetual,\r
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable\r
+ (except as stated in this section) patent license to make, have made,\r
+ use, offer to sell, sell, import, and otherwise transfer the Work,\r
+ where such license applies only to those patent claims licensable\r
+ by such Contributor that are necessarily infringed by their\r
+ Contribution(s) alone or by combination of their Contribution(s)\r
+ with the Work to which such Contribution(s) was submitted. If You\r
+ institute patent litigation against any entity (including a\r
+ cross-claim or counterclaim in a lawsuit) alleging that the Work\r
+ or a Contribution incorporated within the Work constitutes direct\r
+ or contributory patent infringement, then any patent licenses\r
+ granted to You under this License for that Work shall terminate\r
+ as of the date such litigation is filed.\r
+\r
+ 4. Redistribution. You may reproduce and distribute copies of the\r
+ Work or Derivative Works thereof in any medium, with or without\r
+ modifications, and in Source or Object form, provided that You\r
+ meet the following conditions:\r
+\r
+ (a) You must give any other recipients of the Work or\r
+ Derivative Works a copy of this License; and\r
+\r
+ (b) You must cause any modified files to carry prominent notices\r
+ stating that You changed the files; and\r
+\r
+ (c) You must retain, in the Source form of any Derivative Works\r
+ that You distribute, all copyright, patent, trademark, and\r
+ attribution notices from the Source form of the Work,\r
+ excluding those notices that do not pertain to any part of\r
+ the Derivative Works; and\r
+\r
+ (d) If the Work includes a "NOTICE" text file as part of its\r
+ distribution, then any Derivative Works that You distribute must\r
+ include a readable copy of the attribution notices contained\r
+ within such NOTICE file, excluding those notices that do not\r
+ pertain to any part of the Derivative Works, in at least one\r
+ of the following places: within a NOTICE text file distributed\r
+ as part of the Derivative Works; within the Source form or\r
+ documentation, if provided along with the Derivative Works; or,\r
+ within a display generated by the Derivative Works, if and\r
+ wherever such third-party notices normally appear. The contents\r
+ of the NOTICE file are for informational purposes only and\r
+ do not modify the License. You may add Your own attribution\r
+ notices within Derivative Works that You distribute, alongside\r
+ or as an addendum to the NOTICE text from the Work, provided\r
+ that such additional attribution notices cannot be construed\r
+ as modifying the License.\r
+\r
+ You may add Your own copyright statement to Your modifications and\r
+ may provide additional or different license terms and conditions\r
+ for use, reproduction, or distribution of Your modifications, or\r
+ for any such Derivative Works as a whole, provided Your use,\r
+ reproduction, and distribution of the Work otherwise complies with\r
+ the conditions stated in this License.\r
+\r
+ 5. Submission of Contributions. Unless You explicitly state otherwise,\r
+ any Contribution intentionally submitted for inclusion in the Work\r
+ by You to the Licensor shall be under the terms and conditions of\r
+ this License, without any additional terms or conditions.\r
+ Notwithstanding the above, nothing herein shall supersede or modify\r
+ the terms of any separate license agreement you may have executed\r
+ with Licensor regarding such Contributions.\r
+\r
+ 6. Trademarks. This License does not grant permission to use the trade\r
+ names, trademarks, service marks, or product names of the Licensor,\r
+ except as required for reasonable and customary use in describing the\r
+ origin of the Work and reproducing the content of the NOTICE file.\r
+\r
+ 7. Disclaimer of Warranty. Unless required by applicable law or\r
+ agreed to in writing, Licensor provides the Work (and each\r
+ Contributor provides its Contributions) on an "AS IS" BASIS,\r
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or\r
+ implied, including, without limitation, any warranties or conditions\r
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A\r
+ PARTICULAR PURPOSE. You are solely responsible for determining the\r
+ appropriateness of using or redistributing the Work and assume any\r
+ risks associated with Your exercise of permissions under this License.\r
+\r
+ 8. Limitation of Liability. In no event and under no legal theory,\r
+ whether in tort (including negligence), contract, or otherwise,\r
+ unless required by applicable law (such as deliberate and grossly\r
+ negligent acts) or agreed to in writing, shall any Contributor be\r
+ liable to You for damages, including any direct, indirect, special,\r
+ incidental, or consequential damages of any character arising as a\r
+ result of this License or out of the use or inability to use the\r
+ Work (including but not limited to damages for loss of goodwill,\r
+ work stoppage, computer failure or malfunction, or any and all\r
+ other commercial damages or losses), even if such Contributor\r
+ has been advised of the possibility of such damages.\r
+\r
+ 9. Accepting Warranty or Additional Liability. While redistributing\r
+ the Work or Derivative Works thereof, You may choose to offer,\r
+ and charge a fee for, acceptance of support, warranty, indemnity,\r
+ or other liability obligations and/or rights consistent with this\r
+ License. However, in accepting such obligations, You may act only\r
+ on Your own behalf and on Your sole responsibility, not on behalf\r
+ of any other Contributor, and only if You agree to indemnify,\r
+ defend, and hold each Contributor harmless for any liability\r
+ incurred by, or claims asserted against, such Contributor by reason\r
+ of your accepting any such warranty or additional liability.\r
+\r
+ END OF TERMS AND CONDITIONS\r
+\r
+ APPENDIX: How to apply the Apache License to your work.\r
+\r
+ To apply the Apache License to your work, attach the following\r
+ boilerplate notice, with the fields enclosed by brackets "[]"\r
+ replaced with your own identifying information. (Don't include\r
+ the brackets!) The text should be enclosed in the appropriate\r
+ comment syntax for the file format. We also recommend that a\r
+ file or class name and description of purpose be included on the\r
+ same "printed page" as the copyright notice for easier\r
+ identification within third-party archives.\r
+\r
+ Copyright [yyyy] [name of copyright owner]\r
+\r
+ Licensed under the Apache License, Version 2.0 (the "License");\r
+ you may not use this file except in compliance with the License.\r
+ You may obtain a copy of the License at\r
+\r
+ http://www.apache.org/licenses/LICENSE-2.0\r
+\r
+ Unless required by applicable law or agreed to in writing, software\r
+ distributed under the License is distributed on an "AS IS" BASIS,\r
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\r
+ See the License for the specific language governing permissions and\r
+ limitations under the License.\r
+\r
Copyright (c) Samsung Electronics Co., Ltd. All rights reserved.
Except as noted, This software is licensed under Apache License, Version 2.
-Please, see the LICENSE.APLv2 file for Apache License terms and conditions.
+Please, see the LICENSE.Apache_v2 file for Apache License terms and conditions.
--- /dev/null
+<?xml version="1.0" encoding="utf-8" ?>
+<manifest xmlns="http://tizen.org/ns/packages" package="org.tizen.usb-syspopup" version="0.0.1" install-location="internal-only">
+ <label>Usb syspopup</label>
+ <author email="ty317.kim@samsung.com" href="www.samsung.com">Taeyoung Kim</author>
+ <description>USB System Popup Application</description>
+ <ui-application appid="org.tizen.usb-syspopup" exec="/usr/apps/org.tizen.usb-syspopup/bin/usb-syspopup" nodisplay="true" multiple="false" type="capp" taskmanage="false">
+ <label>Usb syspopup</label>
+ <label xml:lang="en-us">Usb system popup</label>
+ <label xml:lang="nl-nl">Usb-systeem pop-up</label>
+ <label xml:lang="de-de">USB-System popup</label>
+ <label xml:lang="zh-hk">USB系統彈出</label>
+ <label xml:lang="zh-cn">USB系统弹出</label>
+ <label xml:lang="ru-ru">Usb система всплывающих</label>
+ <label xml:lang="zh-tw">USB系統彈出</label>
+ <label xml:lang="ja-jp">USBシステムのポップアップ</label>
+ <label xml:lang="es-es">USB del sistema emergente</label>
+ <label xml:lang="el-gr">Usb σύστημα popup</label>
+ <label xml:lang="it-it">Usb sistema popup</label>
+ <label xml:lang="tr-tr">Usb sistemi açılır</label>
+ <label xml:lang="pt-pt">Usb sistema pop-up</label>
+ <label xml:lang="fr-fr">Usb système contextuel</label>
+ <label xml:lang="ko-kr">USB 시스템 팝업</label>
+ </ui-application>
+</manifest>
-<?xml version="1.0" encoding="utf-8"?>
-<manifest xmlns="http://tizen.org/ns/packages" package="org.tizen.usbotg-syspopup" version="0.1.7" install-location="internal-only">
- <label>usbotg-syspopup</label>
- <author email="giyeol.ok@samsung.com" href="www.samsung.com">Giyeol Ok</author>
- <description>system-popup application (usbotg popup)</description>
- <ui-application appid="org.tizen.usbotg-syspopup" exec="/usr/apps/org.tizen.usbotg-syspopup/bin/usbotg-popup" nodisplay="true" multiple="false" type="capp" taskmanage="false">
- <icon>org.tizen.usbotg-syspopup.png</icon>
- <label>USB otg system popup</label>
+<?xml version="1.0" encoding="utf-8" ?>
+<manifest xmlns="http://tizen.org/ns/packages" package="org.tizen.usbotg-syspopup" version="0.0.1" install-location="internal-only">
+ <label>Usb otg syspopup</label>
+ <author email="ty317.kim@samsung.com" href="www.samsung.com">Taeyoung Kim</author>
+ <description>USB otg system Popup Application</description>
+ <ui-application appid="org.tizen.usbotg-syspopup" exec="/usr/apps/org.tizen.usbotg-syspopup/bin/usbotg-syspopup" nodisplay="true" multiple="false" type="capp" taskmanage="false">
+ <label>Usb otg syspopup</label>
+ <label xml:lang="en-us">Usb otg system popup</label>
+ <label xml:lang="nl-nl">Usb otg systeem pop-up</label>
+ <label xml:lang="de-de">USB otg system popup</label>
+ <label xml:lang="zh-hk">USB otg 系統彈出</label>
+ <label xml:lang="zh-cn">USB otg 系统弹出</label>
+ <label xml:lang="ru-ru">Usb otg система всплывающих</label>
+ <label xml:lang="zh-tw">USB otg 系統彈出</label>
+ <label xml:lang="ja-jp">USB otg システムのポップアップ</label>
+ <label xml:lang="es-es">USB otg del sistema emergente</label>
+ <label xml:lang="el-gr">Usb otg σύστημα popup</label>
+ <label xml:lang="it-it">Usb otg sistema popup</label>
+ <label xml:lang="tr-tr">Usb otg sistemi açılır</label>
+ <label xml:lang="pt-pt">Usb otg sistema pop-up</label>
+ <label xml:lang="fr-fr">Usb otg système contextuel</label>
+ <label xml:lang="ko-kr">USB otg 시스템 팝업</label>
</ui-application>
</manifest>
+++ /dev/null
-<?xml version="1.0" encoding="utf-8"?>
-<manifest xmlns="http://tizen.org/ns/packages" package="org.tizen.usbotg-unmount-popup" version="0.1.7" install-location="internal-only">
- <label>usbotg-unmount-popup</label>
- <author email="giyeol.ok@samsung.com" href="www.samsung.com">Giyeol Ok</author>
- <description>system-popup application (usbotg unmount popup)</description>
- <ui-application appid="org.tizen.usbotg-unmount-popup" exec="/usr/apps/org.tizen.usbotg-unmount-popup/bin/usbotg-unmount-popup" nodisplay="true" multiple="false" type="capp" taskmanage="false">
- <icon>org.tizen.usbotg-unmount-popup.png</icon>
- <label>USB otg unmount popup</label>
- </ui-application>
-</manifest>
+++ /dev/null
-[ProcessSetting]
-BG_SCHEDULE=true
+++ /dev/null
-[ProcessSetting]
-BG_SCHEDULE=true
Depends: ${shlibs:Depends}, ${misc:Depends}
Description: Low battery popup application
-Package: org.tizen.usbotg-syspopup
-Architecture: any
-Depends: ${shlibs:Depends}, ${misc:Depends}
-Description: USB otg popup application
-
-Package: org.tizen.usbotg-unmount-popup
-Architecture: any
-Depends: ${shlibs:Depends}, ${misc:Depends}
-Description: USB otg unmount popup application
-
Package: system-popup-dbg
Section: debug
Architecture: any
-Depends: ${shlibs:Depends}, ${misc:Depends}, org.tizen.poweroff-syspopup (= ${Source-Version}), org.tizen.lowmem-syspopup (= ${Source-Version}), org.tizen.lowbat-syspopup (= ${Source-Version}), org.tizen.usbotg-syspopup (= ${Source-Version}), org.tizen.usbotg-unmount-popup (= ${Source-Version})
+Depends: ${shlibs:Depends}, ${misc:Depends}, org.tizen.poweroff-syspopup (= ${Source-Version}), org.tizen.lowmem-syspopup (= ${Source-Version}), org.tizen.lowbat-syspopup (= ${Source-Version})
Description: System popup application (unstripped)
+++ /dev/null
-/usr/apps/org.tizen.usbotg-syspopup/bin/usbotg-popup
-/usr/apps/org.tizen.usbotg-syspopup/res/keysound/02_Warning.wav
-/usr/apps/org.tizen.usbotg-syspopup/res/edje/usbotg/usbotg.edj
-/usr/share/applications/org.tizen.usbotg-syspopup.desktop
-/usr/share/process-info/usbotg-popup.ini
-/usr/apps/org.tizen.usbotg-syspopup/res/locale/*
+++ /dev/null
-/usr/apps/org.tizen.usbotg-unmount-popup/bin/usbotg-unmount-popup
-/usr/apps/org.tizen.usbotg-unmount-popup/res/keysound/02_Warning.wav
-/usr/apps/org.tizen.usbotg-unmount-popup/res/edje/usbotg/usbotg-unmount.edj
-/usr/share/applications/org.tizen.usbotg-unmount-popup.desktop
-/usr/share/process-info/usbotg-unmount-popup.ini
-/usr/apps/org.tizen.usbotg-unmount-popup/res/locale/*
rm -rf *.so
rm -rf *.edj
rm -rf data/*.desktop
- for i in lowbatt-popup lowmem-popup poweroff-popup usbotg-popup usbotg-unmount-popup; do \
+ for i in lowbatt-popup lowmem-popup poweroff-popup; do \
rm -rf $$i/CMakeCache.txt; \
rm -rf $$i/CMakeFiles; \
rm -rf $$i/cmake_install.cmake; \
+++ /dev/null
-#define MAIN_W 480
-#define MAIN_H 800
-#define POPUP_MAIN_W 458
-#define POPUP_MAIN_H 240
-
-collections
-{
- group
- {
-
- name: "main";
- min: MAIN_W MAIN_H;
- parts {
- part
- {
- name: "background";
- type: RECT;
- mouse_events: 1;
- description {
- state: "default" 0.0;
- rel1 { relative: 0 0; offset: 0 0; }
- rel2 { relative: 1 1; offset: -1 -1; }
- color: 0 0 0 100;
- }
- }
-
- part
- {
- name: "txt_title";
- type: TEXT;
- mouse_events: 1;
- description {
- state: "default" 0.0;
- rel1 { relative: 0.0 0.0; to: background; }
- rel2 { relative: 1.0 0.5; to: background; }
- text { text_class: "tc_default"; align: 0.5 0.5; }
- color: 255 255 255 255;
- }
- }
-
- part
- {
- name: "txt_mesg";
- type: TEXT;
- mouse_events: 1;
- description {
- state: "default" 0.0;
- rel1 { relative: 0.0 0.5; to: background; }
- rel2 { relative: 1.0 1.0; to: background; }
- text { text_class: "tc_default"; align: 0.5 0.5; }
- color: 255 255 255 255;
- }
- }
- }
-
- programs {
- program
- {
- name: "click_exit";
- source: "background";
- signal: "mouse,clicked,1";
- action: SIGNAL_EMIT "update_clicked" "background";
- }
- }
- }
-
-
- group
- {
- name: "popup";
- min: POPUP_MAIN_W POPUP_MAIN_H;
- parts
- {
- part {
- name: "background";
- type: RECT;
- mouse_events: 1;
- description {
- state: "default" 0.0;
- rel1 { relative: 0.0 0.0; offset: 0 0; }
- rel2 { relative: 1.0 1.0; offset: -1 -1; }
- color: 0 0 0 0;
- }
- }
-
- part {
- name: "txt_title";
- type: TEXT;
- mouse_events: 1;
- description {
- state: "default" 0.0;
- rel1 { relative: 0.0 0.0; to: background; }
- rel2 { relative: 1.0 0.5; to: background; }
- text { text_class: "tc_default"; align: 0.5 0.5; }
- color: 0 0 0 0;
- }
- }
-
- part {
- name: "txt_mesg";
- type: TEXT;
- mouse_events: 1;
- description {
- state: "default" 0.0;
- rel1 { relative: 0.0 0.5; to: background; }
- rel2 { relative: 1.0 1.0; to: background; }
- text { text_class: "GP_Latin"; align: 0.5 0.5; }
- color: 255 255 255 255;
- }
- }
- }
-
- programs
- {
- program
- {
- name: "bg_click";
- signal: "mouse,down,1";
- source: "bg";
- action, SIGNAL_EMIT "background_click" "background";
- }
- }
- }
-}
+++ /dev/null
-#define MAIN_W 480
-#define MAIN_H 800
-#define POPUP_MAIN_W 458
-#define POPUP_MAIN_H 240
-
-collections
-{
- group
- {
-
- name: "main";
- min: MAIN_W MAIN_H;
- parts {
- part
- {
- name: "background";
- type: RECT;
- mouse_events: 1;
- description {
- state: "default" 0.0;
- rel1 { relative: 0 0; offset: 0 0; }
- rel2 { relative: 1 1; offset: -1 -1; }
- color: 0 0 0 100;
- }
- }
-
- part
- {
- name: "txt_title";
- type: TEXT;
- mouse_events: 1;
- description {
- state: "default" 0.0;
- rel1 { relative: 0.0 0.0; to: background; }
- rel2 { relative: 1.0 0.5; to: background; }
- text { text_class: "tc_default"; align: 0.5 0.5; }
- color: 255 255 255 255;
- }
- }
-
- part
- {
- name: "txt_mesg";
- type: TEXT;
- mouse_events: 1;
- description {
- state: "default" 0.0;
- rel1 { relative: 0.0 0.5; to: background; }
- rel2 { relative: 1.0 1.0; to: background; }
- text { text_class: "tc_default"; align: 0.5 0.5; }
- color: 255 255 255 255;
- }
- }
- }
-
- programs {
- program
- {
- name: "click_exit";
- source: "background";
- signal: "mouse,clicked,1";
- action: SIGNAL_EMIT "update_clicked" "background";
- }
- }
- }
-
-
- group
- {
- name: "popup";
- min: POPUP_MAIN_W POPUP_MAIN_H;
- parts
- {
- part {
- name: "background";
- type: RECT;
- mouse_events: 1;
- description {
- state: "default" 0.0;
- rel1 { relative: 0.0 0.0; offset: 0 0; }
- rel2 { relative: 1.0 1.0; offset: -1 -1; }
- color: 0 0 0 0;
- }
- }
-
- part {
- name: "txt_title";
- type: TEXT;
- mouse_events: 1;
- description {
- state: "default" 0.0;
- rel1 { relative: 0.0 0.0; to: background; }
- rel2 { relative: 1.0 0.5; to: background; }
- text { text_class: "tc_default"; align: 0.5 0.5; }
- color: 0 0 0 0;
- }
- }
-
- part {
- name: "txt_mesg";
- type: TEXT;
- mouse_events: 1;
- description {
- state: "default" 0.0;
- rel1 { relative: 0.0 0.5; to: background; }
- rel2 { relative: 1.0 1.0; to: background; }
- text { text_class: "GP_Latin"; align: 0.5 0.5; }
- color: 255 255 255 255;
- }
- }
- }
-
- programs
- {
- program
- {
- name: "bg_click";
- signal: "mouse,down,1";
- source: "bg";
- action, SIGNAL_EMIT "background_click" "background";
- }
- }
- }
-}
<request>
<domain name="_"/>
</request>
-</manifest>
+</manifest>
\ No newline at end of file
Name: system-popup
Summary: system-popup application (poweroff popup,sysevent-alert)
-Version: 0.1.13
+Version: 0.1.16
Release: 2
-Group: framework-system
-License: APLv2
+Group: framework/system
+License: Apache License, Version 2.0
Source0: %{name}-%{version}.tar.bz2
Source1001: org.tizen.poweroff-syspopup.manifest
Source1002: org.tizen.lowmem-syspopup.manifest
Source1003: org.tizen.lowbat-syspopup.manifest
-Source1004: org.tizen.usbotg-syspopup.manifest
-Source1005: org.tizen.usbotg-unmount-popup.manifest
-Source1006: org.tizen.mmc-syspopup.manifest
+Source1004: org.tizen.mmc-syspopup.manifest
+Source1005: org.tizen.usb-syspopup.manifest
+Source1006: org.tizen.usbotg-syspopup.manifest
BuildRequires: pkgconfig(evas)
BuildRequires: pkgconfig(ecore-input)
BuildRequires: pkgconfig(ethumb)
BuildRequires: pkgconfig(pmapi)
BuildRequires: pkgconfig(appsvc)
BuildRequires: pkgconfig(svi)
-
+BuildRequires: pkgconfig(bundle)
+BuildRequires: pkgconfig(vconf)
+BuildRequires: pkgconfig(dlog)
BuildRequires: cmake
BuildRequires: edje-bin
BuildRequires: embryo-bin
%description -n org.tizen.lowbat-syspopup
system-popup application (lowmem popup).
-%package -n org.tizen.usbotg-syspopup
-Summary: system-popup application (usbotg popup)
+%package -n org.tizen.mmc-syspopup
+Summary: system-popup application (mmc popup)
Group: main
Requires: %{name} = %{version}-%{release}
-%description -n org.tizen.usbotg-syspopup
-system-popup application (usbotg popup).
+%description -n org.tizen.mmc-syspopup
+system-popup application (mmc popup).
-%package -n org.tizen.usbotg-unmount-popup
-Summary: system-popup application (usbotg unmount popup)
+%package -n org.tizen.usb-syspopup
+Summary: system-popup application (usb popup)
Group: main
Requires: %{name} = %{version}-%{release}
-%description -n org.tizen.usbotg-unmount-popup
-system-popup application (usbotg unmount popup).
+%description -n org.tizen.usb-syspopup
+system-popup application (usb popup).
-%package -n org.tizen.mmc-syspopup
-Summary: system-popup application (mmc popup)
+%package -n org.tizen.usbotg-syspopup
+Summary: system-popup application (usb otg popup)
Group: main
Requires: %{name} = %{version}-%{release}
-%description -n org.tizen.mmc-syspopup
-system-popup application (mmc popup).
+%description -n org.tizen.usbotg-syspopup
+system-popup application (usb otg popup).
%prep
%setup -q
cp %{SOURCE1004} .
cp %{SOURCE1005} .
cp %{SOURCE1006} .
-cmake . -DCMAKE_INSTALL_PREFIX=/usr
+cmake . -DCMAKE_INSTALL_PREFIX=%{_prefix}
make %{?jobs:-j%jobs}
%install
rm -rf %{buildroot}
%make_install
+%post
+vconftool set -t int db/setting/select_popup_btn "0" -u 5000 -f
%files
%defattr(-,root,root,-)
/usr/share/packages/org.tizen.lowbat-syspopup.xml
/usr/share/process-info/lowbatt-popup.ini
-%files -n org.tizen.usbotg-syspopup
-%manifest org.tizen.usbotg-syspopup.manifest
-%defattr(-,root,root,-)
-/usr/apps/org.tizen.usbotg-syspopup/bin/usbotg-popup
-/usr/apps/org.tizen.usbotg-syspopup/res/keysound/02_Warning.wav
-/usr/apps/org.tizen.usbotg-syspopup/res/edje/usbotg/usbotg.edj
-/usr/apps/org.tizen.usbotg-syspopup/res/icons/usb_icon.png
-/usr/apps/org.tizen.usbotg-syspopup/res/icon/org.tizen.usbotg-syspopup.png
-/usr/share/packages/org.tizen.usbotg-syspopup.xml
-/usr/share/process-info/usbotg-popup.ini
-/usr/apps/org.tizen.usbotg-syspopup/res/locale/*/LC_MESSAGES/*.mo
-
-%files -n org.tizen.usbotg-unmount-popup
-%manifest org.tizen.usbotg-unmount-popup.manifest
-%defattr(-,root,root,-)
-/usr/apps/org.tizen.usbotg-unmount-popup/bin/usbotg-unmount-popup
-/usr/apps/org.tizen.usbotg-unmount-popup/res/keysound/02_Warning.wav
-/usr/apps/org.tizen.usbotg-unmount-popup/res/edje/usbotg-unmount/usbotg-unmount.edj
-/usr/apps/org.tizen.usbotg-unmount-popup/res/icon/org.tizen.usbotg-unmount-popup.png
-/usr/share/packages/org.tizen.usbotg-unmount-popup.xml
-/usr/share/process-info/usbotg-unmount-popup.ini
-/usr/apps/org.tizen.usbotg-unmount-popup/res/locale/*/LC_MESSAGES/*.mo
%files -n org.tizen.mmc-syspopup
%manifest org.tizen.mmc-syspopup.manifest
%defattr(-,root,root,-)
/usr/share/packages/org.tizen.mmc-syspopup.xml
/usr/share/process-info/mmc-popup.ini
/usr/apps/org.tizen.mmc-syspopup/res/locale/*/LC_MESSAGES/*.mo
+
+%files -n org.tizen.usb-syspopup
+%manifest org.tizen.usb-syspopup.manifest
+%defattr(440,root,root,-)
+%attr(555,app,app) /usr/apps/org.tizen.usb-syspopup/bin/usb-syspopup
+%attr(440,app,app) /usr/apps/org.tizen.usb-syspopup/res/locale/*/LC_MESSAGES/usb-syspopup.mo
+/usr/share/packages/org.tizen.usb-syspopup.xml
+
+%files -n org.tizen.usbotg-syspopup
+%manifest org.tizen.usbotg-syspopup.manifest
+%defattr(440,root,root,-)
+%attr(555,app,app) /usr/apps/org.tizen.usbotg-syspopup/bin/usbotg-syspopup
+/usr/share/packages/org.tizen.usbotg-syspopup.xml
if (data != NULL)
poweroff_cleanup(data);
- /* Sysman API to poweroff */
if (sysman_call_predef_action(PREDEF_POWEROFF, 0) == -1) {
system_print("System-popup : failed to request poweroff to system_server \n");
system("poweroff");
}
-// exit(0);
}
void poweroff_response_no_cb_min(void *data, Evas_Object * obj, void *event_info)
--- /dev/null
+CMAKE_MINIMUM_REQUIRED(VERSION 2.6)
+
+SET(SRCS src/usb-syspopup.c)
+
+SET(VENDOR "tizen")
+SET(PACKAGE "usb-syspopup")
+SET(PKGNAME "org.${VENDOR}.${PACKAGE}")
+SET(PREFIX "${CMAKE_INSTALL_PREFIX}/apps/${PKGNAME}")
+SET(BINDIR "${PREFIX}/bin")
+SET(RESDIR "${PREFIX}/res")
+SET(LOCALEDIR "${RESDIR}/locale")
+SET(MANIFESTDIR "${CMAKE_INSTALL_PREFIX}/share/packages")
+
+INCLUDE(FindPkgConfig)
+pkg_check_modules(pkgs REQUIRED
+ appcore-efl
+ bundle
+ dlog
+ ecore
+ elementary
+ evas
+ syspopup
+ devman
+ appsvc
+ pmapi
+ vconf)
+
+FOREACH(flag ${pkgs_CFLAGS})
+ SET(EXTRA_CFLAGS "${EXTRA_CFLAGS} ${flag}")
+ENDFOREACH(flag)
+
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${EXTRA_CFLAGS} -O2 -g -Wall")
+
+ADD_DEFINITIONS("-DPACKAGE=\"${PACKAGE}\"")
+ADD_DEFINITIONS("-DLOCALEDIR=\"${LOCALEDIR}\"")
+
+SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed")
+
+ADD_EXECUTABLE(${PACKAGE} ${SRCS})
+TARGET_LINK_LIBRARIES(${PACKAGE} syspopup ${pkgs_LDFLAGS})
+
+INSTALL(TARGETS ${PACKAGE} DESTINATION ${BINDIR})
+
+# install manifest file
+INSTALL(FILES ${CMAKE_SOURCE_DIR}/data/${PKGNAME}.xml DESTINATION ${MANIFESTDIR})
+
+ADD_SUBDIRECTORY(po)
--- /dev/null
+# for i18n
+SET(POFILES ar.po az.po bg.po ca.po cs.po da.po de_DE.po el_GR.po en.po en_PH.po en_US.po es_ES.po es_MX.po et.po eu.po fi.po fr_CA.po fr_FR.po ga.po gl.po hi.po hr.po hu.po hy.po is.po it_IT.po ja_JP.po ka.po kk.po ko_KR.po lt.po lv.po mk.po nb.po nl_NL.po pl.po pt_BR.po pt_PT.po ro.po ru_RU.po sk.po sl.po sr.po sv.po tr_TR.po uk.po uz.po zh_CN.po zh_HK.po zh_SG.po zh_TW.po)
+SET(MSGFMT "/usr/bin/msgfmt")
+
+FOREACH(pofile ${POFILES})
+ SET(pofile ${CMAKE_CURRENT_SOURCE_DIR}/${pofile})
+ MESSAGE("PO: ${pofile}")
+ GET_FILENAME_COMPONENT(absPofile ${pofile} ABSOLUTE)
+ GET_FILENAME_COMPONENT(lang ${absPofile} NAME_WE)
+ SET(moFile ${CMAKE_CURRENT_BINARY_DIR}/${lang}.mo)
+ ADD_CUSTOM_COMMAND(
+ OUTPUT ${moFile}
+ COMMAND ${MSGFMT} -o ${moFile} ${absPofile}
+ DEPENDS ${absPofile}
+ )
+ INSTALL(FILES ${moFile}
+ DESTINATION /usr/apps/org.tizen.usb-syspopup/res/locale/${lang}/LC_MESSAGES RENAME usb-syspopup.mo)
+ SET(moFiles ${moFiles} ${moFile})
+ENDFOREACH(pofile)
+
+MESSAGE(".mo files: ${moFiles}")
+ADD_CUSTOM_TARGET(po_usb_syspopup ALL DEPENDS ${moFiles})
--- /dev/null
+msgid "IDS_USB_POP_USB_CONNECTION_FAILED"
+msgstr "فشل اتصال USB"
+
+msgid "IDS_COM_HEADER_USB_ACCESSORY"
+msgstr "ملحق USB"
+
+msgid "IDS_COM_POP_ALLOW_APPLICATION_P1SS_TO_ACCESS_USB_ACCESSORY_Q_ABB"
+msgstr "هل تريد السماح للتطبيق بالوصول إلى ملحق USB؟"
+
--- /dev/null
+msgid "IDS_USB_POP_USB_CONNECTION_FAILED"
+msgstr "USB bağlantısı alınmadı"
+
+msgid "IDS_COM_HEADER_USB_ACCESSORY"
+msgstr "USB aksesuarı"
+
+msgid "IDS_COM_POP_ALLOW_APPLICATION_P1SS_TO_ACCESS_USB_ACCESSORY_Q_ABB"
+msgstr "Proqrama USB aksesuarına daxil olmağa icazə verilsin?"
+
--- /dev/null
+msgid "IDS_USB_POP_USB_CONNECTION_FAILED"
+msgstr "USB връзката е неуспешна"
+
+msgid "IDS_COM_HEADER_USB_ACCESSORY"
+msgstr "USB аксесоар"
+
+msgid "IDS_COM_POP_ALLOW_APPLICATION_P1SS_TO_ACCESS_USB_ACCESSORY_Q_ABB"
+msgstr "Позволяване на приложението достъп до USB аксесоара?"
+
--- /dev/null
+msgid "IDS_USB_POP_USB_CONNECTION_FAILED"
+msgstr "Error de connexió USB"
+
+msgid "IDS_COM_HEADER_USB_ACCESSORY"
+msgstr "Accessori USB"
+
+msgid "IDS_COM_POP_ALLOW_APPLICATION_P1SS_TO_ACCESS_USB_ACCESSORY_Q_ABB"
+msgstr "Permetre a l'aplicació accedir a l'accessori USB?"
+
--- /dev/null
+msgid "IDS_USB_POP_USB_CONNECTION_FAILED"
+msgstr "Připojení USB se nezdařilo"
+
+msgid "IDS_COM_HEADER_USB_ACCESSORY"
+msgstr "Příslušenství USB"
+
+msgid "IDS_COM_POP_ALLOW_APPLICATION_P1SS_TO_ACCESS_USB_ACCESSORY_Q_ABB"
+msgstr "Povolit aplikaci používat příslušenství USB?"
+
--- /dev/null
+msgid "IDS_USB_POP_USB_CONNECTION_FAILED"
+msgstr "USB-forbindelse mislykkedes"
+
+msgid "IDS_COM_HEADER_USB_ACCESSORY"
+msgstr "USB-tilbehør"
+
+msgid "IDS_COM_POP_ALLOW_APPLICATION_P1SS_TO_ACCESS_USB_ACCESSORY_Q_ABB"
+msgstr "Tillad, at programmet får adgang til USB-tilbehør?"
+
--- /dev/null
+msgid "IDS_USB_POP_USB_CONNECTION_FAILED"
+msgstr "USB-Verbindung fehlgeschlagen"
+
+msgid "IDS_COM_HEADER_USB_ACCESSORY"
+msgstr "USB-Gerät"
+
+msgid "IDS_COM_POP_ALLOW_APPLICATION_P1SS_TO_ACCESS_USB_ACCESSORY_Q_ABB"
+msgstr "Anwendung den Zugriff auf das USB-Gerät erlauben?"
+
--- /dev/null
+msgid "IDS_USB_POP_USB_CONNECTION_FAILED"
+msgstr "Η σύνδεση USB απέτυχε"
+
+msgid "IDS_COM_HEADER_USB_ACCESSORY"
+msgstr "Αξεσουάρ USB"
+
+msgid "IDS_COM_POP_ALLOW_APPLICATION_P1SS_TO_ACCESS_USB_ACCESSORY_Q_ABB"
+msgstr "Να επιτρέπεται στην εφαρμογή πρόσβαση σε αξεσουάρ USB;"
+
--- /dev/null
+msgid "IDS_USB_POP_USB_CONNECTION_FAILED"
+msgstr "USB connection failed"
+
+msgid "IDS_COM_HEADER_USB_ACCESSORY"
+msgstr "USB accessory"
+
+msgid "IDS_COM_POP_ALLOW_APPLICATION_P1SS_TO_ACCESS_USB_ACCESSORY_Q_ABB"
+msgstr "Allow application to access USB accessory?"
+
--- /dev/null
+msgid "IDS_USB_POP_USB_CONNECTION_FAILED"
+msgstr "USB connection failed"
+
+msgid "IDS_COM_HEADER_USB_ACCESSORY"
+msgstr "USB accessory"
+
+msgid "IDS_COM_POP_ALLOW_APPLICATION_P1SS_TO_ACCESS_USB_ACCESSORY_Q_ABB"
+msgstr "Allow application to access USB accessory?"
+
--- /dev/null
+msgid "IDS_USB_POP_USB_CONNECTION_FAILED"
+msgstr "USB connection failed"
+
+msgid "IDS_COM_HEADER_USB_ACCESSORY"
+msgstr "USB accessory"
+
+msgid "IDS_COM_POP_ALLOW_APPLICATION_P1SS_TO_ACCESS_USB_ACCESSORY_Q_ABB"
+msgstr "Allow application to access USB accessory?"
+
--- /dev/null
+msgid "IDS_USB_POP_USB_CONNECTION_FAILED"
+msgstr "Error de conexión USB"
+
+msgid "IDS_COM_HEADER_USB_ACCESSORY"
+msgstr "Accesorio USB"
+
+msgid "IDS_COM_POP_ALLOW_APPLICATION_P1SS_TO_ACCESS_USB_ACCESSORY_Q_ABB"
+msgstr "¿Permitir a la aplicación acceder al accesorio USB?"
+
--- /dev/null
+msgid "IDS_USB_POP_USB_CONNECTION_FAILED"
+msgstr "Falló la conexión USB"
+
+msgid "IDS_COM_HEADER_USB_ACCESSORY"
+msgstr "Accesorio USB"
+
+msgid "IDS_COM_POP_ALLOW_APPLICATION_P1SS_TO_ACCESS_USB_ACCESSORY_Q_ABB"
+msgstr "¿Permitir que la aplicación acceda al accesorio USB?"
+
--- /dev/null
+msgid "IDS_USB_POP_USB_CONNECTION_FAILED"
+msgstr "USB-ühendus nurjus"
+
+msgid "IDS_COM_HEADER_USB_ACCESSORY"
+msgstr "USB-tarvik"
+
+msgid "IDS_COM_POP_ALLOW_APPLICATION_P1SS_TO_ACCESS_USB_ACCESSORY_Q_ABB"
+msgstr "Kas lubada rakendusel juurde pääseda USB-tarvikule?"
+
--- /dev/null
+msgid "IDS_USB_POP_USB_CONNECTION_FAILED"
+msgstr "USB konexioak huts egin du"
+
+msgid "IDS_COM_HEADER_USB_ACCESSORY"
+msgstr "USB osagarria"
+
+msgid "IDS_COM_POP_ALLOW_APPLICATION_P1SS_TO_ACCESS_USB_ACCESSORY_Q_ABB"
+msgstr "Baimena eman aplikazioari USB osagarrira sartzeko?"
+
--- /dev/null
+msgid "IDS_USB_POP_USB_CONNECTION_FAILED"
+msgstr "USB-yhteys epäonnistui"
+
+msgid "IDS_COM_HEADER_USB_ACCESSORY"
+msgstr "USB-lisälaite"
+
+msgid "IDS_COM_POP_ALLOW_APPLICATION_P1SS_TO_ACCESS_USB_ACCESSORY_Q_ABB"
+msgstr "Annetaanko sovelluksen käyttää USB-lisälaitetta?"
+
--- /dev/null
+msgid "IDS_USB_POP_USB_CONNECTION_FAILED"
+msgstr "Échec de la connexion USB"
+
+msgid "IDS_COM_HEADER_USB_ACCESSORY"
+msgstr "Accessoire USB"
+
+msgid "IDS_COM_POP_ALLOW_APPLICATION_P1SS_TO_ACCESS_USB_ACCESSORY_Q_ABB"
+msgstr "Autoriser l'application à accéder à l'accessoire USB ?"
+
--- /dev/null
+msgid "IDS_USB_POP_USB_CONNECTION_FAILED"
+msgstr "Echec de la connexion USB"
+
+msgid "IDS_COM_HEADER_USB_ACCESSORY"
+msgstr "Accessoire USB"
+
+msgid "IDS_COM_POP_ALLOW_APPLICATION_P1SS_TO_ACCESS_USB_ACCESSORY_Q_ABB"
+msgstr "Autoriser l'application à accéder à l'accessoire USB ?"
+
--- /dev/null
+msgid "IDS_USB_POP_USB_CONNECTION_FAILED"
+msgstr "Theip ar nasc USB"
+
+msgid "IDS_COM_HEADER_USB_ACCESSORY"
+msgstr "Oiriúint USB"
+
+msgid "IDS_COM_POP_ALLOW_APPLICATION_P1SS_TO_ACCESS_USB_ACCESSORY_Q_ABB"
+msgstr "Ceadaigh d'fheidhmchlár oiriúint USB a rochtain?"
+
--- /dev/null
+msgid "IDS_USB_POP_USB_CONNECTION_FAILED"
+msgstr "Erro na conexión USB"
+
+msgid "IDS_COM_HEADER_USB_ACCESSORY"
+msgstr "Accesorio USB"
+
+msgid "IDS_COM_POP_ALLOW_APPLICATION_P1SS_TO_ACCESS_USB_ACCESSORY_Q_ABB"
+msgstr "Desexas permitir á aplicación acceder ao accesorio USB?"
+
--- /dev/null
+msgid "IDS_USB_POP_USB_CONNECTION_FAILED"
+msgstr "USB कनेक्शन विफल"
+
+msgid "IDS_COM_HEADER_USB_ACCESSORY"
+msgstr "USB उपसाधन"
+
+msgid "IDS_COM_POP_ALLOW_APPLICATION_P1SS_TO_ACCESS_USB_ACCESSORY_Q_ABB"
+msgstr "एप्लीकेशन को USB उपसाधन ऍक्सेस करने की अनुमति दें?"
+
--- /dev/null
+msgid "IDS_USB_POP_USB_CONNECTION_FAILED"
+msgstr "Greška USB veze"
+
+msgid "IDS_COM_HEADER_USB_ACCESSORY"
+msgstr "USB priključak"
+
+msgid "IDS_COM_POP_ALLOW_APPLICATION_P1SS_TO_ACCESS_USB_ACCESSORY_Q_ABB"
+msgstr "Dopustiti aplikaciji pristup USB priključku?"
+
--- /dev/null
+msgid "IDS_USB_POP_USB_CONNECTION_FAILED"
+msgstr "Sikertelen USB-kapcsolat"
+
+msgid "IDS_COM_HEADER_USB_ACCESSORY"
+msgstr "USB-tartozék"
+
+msgid "IDS_COM_POP_ALLOW_APPLICATION_P1SS_TO_ACCESS_USB_ACCESSORY_Q_ABB"
+msgstr "Lehetővé teszi a(z) alkalmazás számára a hozzáférést az USB-tartozékhoz?"
+
--- /dev/null
+msgid "IDS_USB_POP_USB_CONNECTION_FAILED"
+msgstr "USB միացումը ձախողվեց"
+
+msgid "IDS_COM_HEADER_USB_ACCESSORY"
+msgstr "USB լրասարք"
+
+msgid "IDS_COM_POP_ALLOW_APPLICATION_P1SS_TO_ACCESS_USB_ACCESSORY_Q_ABB"
+msgstr "Թույլ տա՞լ, որ ծրագիրը մուտք գործի USB լրասարք:"
+
--- /dev/null
+msgid "IDS_USB_POP_USB_CONNECTION_FAILED"
+msgstr "USB-tenging mistókst"
+
+msgid "IDS_COM_HEADER_USB_ACCESSORY"
+msgstr "USB-aukahlutur"
+
+msgid "IDS_COM_POP_ALLOW_APPLICATION_P1SS_TO_ACCESS_USB_ACCESSORY_Q_ABB"
+msgstr "Leyfa forritinu að fá aðgang að USB-aukabúnaðinum?"
+
--- /dev/null
+msgid "IDS_USB_POP_USB_CONNECTION_FAILED"
+msgstr "Connessione USB non riuscita"
+
+msgid "IDS_COM_HEADER_USB_ACCESSORY"
+msgstr "Accessorio USB"
+
+msgid "IDS_COM_POP_ALLOW_APPLICATION_P1SS_TO_ACCESS_USB_ACCESSORY_Q_ABB"
+msgstr "Consentire all'applicazione di accedere all'accessorio USB?"
+
--- /dev/null
+msgid "IDS_USB_POP_USB_CONNECTION_FAILED"
+msgstr "USB接続に失敗しました。"
+
+msgid "IDS_COM_HEADER_USB_ACCESSORY"
+msgstr "USBアクセサリ"
+
+msgid "IDS_COM_POP_ALLOW_APPLICATION_P1SS_TO_ACCESS_USB_ACCESSORY_Q_ABB"
+msgstr "アプリケーションに、USBアクセサリへのアクセスを許可しますか?"
+
--- /dev/null
+msgid "IDS_USB_POP_USB_CONNECTION_FAILED"
+msgstr "USB კავშირი ვერ დამყარდა"
+
+msgid "IDS_COM_HEADER_USB_ACCESSORY"
+msgstr "USB აქსესუარი"
+
+msgid "IDS_COM_POP_ALLOW_APPLICATION_P1SS_TO_ACCESS_USB_ACCESSORY_Q_ABB"
+msgstr "პროგრამას ჰქონდეს წვდომა USB აქსესუარზე?"
+
--- /dev/null
+msgid "IDS_USB_POP_USB_CONNECTION_FAILED"
+msgstr "USB қосылмады"
+
+msgid "IDS_COM_HEADER_USB_ACCESSORY"
+msgstr "USB аксессуары"
+
+msgid "IDS_COM_POP_ALLOW_APPLICATION_P1SS_TO_ACCESS_USB_ACCESSORY_Q_ABB"
+msgstr "бағдарламасына USB аксессуарына кіруге мүмкіндік беру керек пе?"
+
--- /dev/null
+msgid "IDS_USB_POP_USB_CONNECTION_FAILED"
+msgstr "USB 연결 실패"
+
+msgid "IDS_COM_HEADER_USB_ACCESSORY"
+msgstr "USB 액세서리"
+
+msgid "IDS_COM_POP_ALLOW_APPLICATION_P1SS_TO_ACCESS_USB_ACCESSORY_Q_ABB"
+msgstr "애플리케이션이 USB 액세서리에 접근할 수 있도록 허용할까요?"
+
--- /dev/null
+msgid "IDS_USB_POP_USB_CONNECTION_FAILED"
+msgstr "Nutrūko USB ryšys"
+
+msgid "IDS_COM_HEADER_USB_ACCESSORY"
+msgstr "USB priedas"
+
+msgid "IDS_COM_POP_ALLOW_APPLICATION_P1SS_TO_ACCESS_USB_ACCESSORY_Q_ABB"
+msgstr "Leisti programai pasiekti USB priedą?"
+
--- /dev/null
+msgid "IDS_USB_POP_USB_CONNECTION_FAILED"
+msgstr "USB savienojums neizdevās"
+
+msgid "IDS_COM_HEADER_USB_ACCESSORY"
+msgstr "USB piederums"
+
+msgid "IDS_COM_POP_ALLOW_APPLICATION_P1SS_TO_ACCESS_USB_ACCESSORY_Q_ABB"
+msgstr "Vai ļaut programmai piekļūt USB piederumam?"
+
--- /dev/null
+msgid "IDS_USB_POP_USB_CONNECTION_FAILED"
+msgstr "Неуспешно поврзување USB"
+
+msgid "IDS_COM_HEADER_USB_ACCESSORY"
+msgstr "USB додаток"
+
+msgid "IDS_COM_POP_ALLOW_APPLICATION_P1SS_TO_ACCESS_USB_ACCESSORY_Q_ABB"
+msgstr "Да се дозволи апликацијата да пристапи до USB додатокот?"
+
--- /dev/null
+msgid "IDS_USB_POP_USB_CONNECTION_FAILED"
+msgstr "USB-tilkobling mislyktes"
+
+msgid "IDS_COM_HEADER_USB_ACCESSORY"
+msgstr "USB-enhet"
+
+msgid "IDS_COM_POP_ALLOW_APPLICATION_P1SS_TO_ACCESS_USB_ACCESSORY_Q_ABB"
+msgstr "Tillate at programmet får tilgang til USB-tilbehør?"
+
--- /dev/null
+msgid "IDS_USB_POP_USB_CONNECTION_FAILED"
+msgstr "USB-verbinding mislukt"
+
+msgid "IDS_COM_HEADER_USB_ACCESSORY"
+msgstr "USB-accessoire"
+
+msgid "IDS_COM_POP_ALLOW_APPLICATION_P1SS_TO_ACCESS_USB_ACCESSORY_Q_ABB"
+msgstr "Mag applicatie toegang krijgen tot USB-accessoire?"
+
--- /dev/null
+msgid "IDS_USB_POP_USB_CONNECTION_FAILED"
+msgstr "Połączenie USB nie powiodło się"
+
+msgid "IDS_COM_HEADER_USB_ACCESSORY"
+msgstr "Akcesorium USB"
+
+msgid "IDS_COM_POP_ALLOW_APPLICATION_P1SS_TO_ACCESS_USB_ACCESSORY_Q_ABB"
+msgstr "Zezwolić aplikacji na uzyskiwanie dostępu do akcesorium USB?"
+
--- /dev/null
+msgid "IDS_USB_POP_USB_CONNECTION_FAILED"
+msgstr "Falha da conexão USB"
+
+msgid "IDS_COM_HEADER_USB_ACCESSORY"
+msgstr "Acessório USB"
+
+msgid "IDS_COM_POP_ALLOW_APPLICATION_P1SS_TO_ACCESS_USB_ACCESSORY_Q_ABB"
+msgstr "Permitir que o aplicativo acesse o acessório USB?"
+
--- /dev/null
+msgid "IDS_USB_POP_USB_CONNECTION_FAILED"
+msgstr "Ligação USB falhou"
+
+msgid "IDS_COM_HEADER_USB_ACCESSORY"
+msgstr "Acessório USB"
+
+msgid "IDS_COM_POP_ALLOW_APPLICATION_P1SS_TO_ACCESS_USB_ACCESSORY_Q_ABB"
+msgstr "Permitir que a aplicação aceda ao acessório USB?"
+
--- /dev/null
+msgid "IDS_USB_POP_USB_CONNECTION_FAILED"
+msgstr "Conexiunea USB nu a reuşit"
+
+msgid "IDS_COM_HEADER_USB_ACCESSORY"
+msgstr "Accesoriu USB"
+
+msgid "IDS_COM_POP_ALLOW_APPLICATION_P1SS_TO_ACCESS_USB_ACCESSORY_Q_ABB"
+msgstr "Permiteţi aplicaţiei să acceseze accesoriul USB?"
+
--- /dev/null
+msgid "IDS_USB_POP_USB_CONNECTION_FAILED"
+msgstr "Сбой подключения через USB"
+
+msgid "IDS_COM_HEADER_USB_ACCESSORY"
+msgstr "USB-аксессуар"
+
+msgid "IDS_COM_POP_ALLOW_APPLICATION_P1SS_TO_ACCESS_USB_ACCESSORY_Q_ABB"
+msgstr "Разрешить приложению получать доступ к USB-аксессуару?"
+
--- /dev/null
+msgid "IDS_USB_POP_USB_CONNECTION_FAILED"
+msgstr "Pripojenie USB zlyhalo"
+
+msgid "IDS_COM_HEADER_USB_ACCESSORY"
+msgstr "Príslušenstvo USB"
+
+msgid "IDS_COM_POP_ALLOW_APPLICATION_P1SS_TO_ACCESS_USB_ACCESSORY_Q_ABB"
+msgstr "Povoliť aplikácii prístup k príslušenstvu USB?"
+
--- /dev/null
+msgid "IDS_USB_POP_USB_CONNECTION_FAILED"
+msgstr "Povezava USB ni uspela"
+
+msgid "IDS_COM_HEADER_USB_ACCESSORY"
+msgstr "Dodatek USB"
+
+msgid "IDS_COM_POP_ALLOW_APPLICATION_P1SS_TO_ACCESS_USB_ACCESSORY_Q_ABB"
+msgstr "Dovolite programu, da dostopa do dodatka USB?"
+
--- /dev/null
+msgid "IDS_USB_POP_USB_CONNECTION_FAILED"
+msgstr "USB veza nije uspostavljena"
+
+msgid "IDS_COM_HEADER_USB_ACCESSORY"
+msgstr "USB pribor"
+
+msgid "IDS_COM_POP_ALLOW_APPLICATION_P1SS_TO_ACCESS_USB_ACCESSORY_Q_ABB"
+msgstr "Dozvoliti aplikaciji da pristupi USB priboru?"
+
--- /dev/null
+msgid "IDS_USB_POP_USB_CONNECTION_FAILED"
+msgstr "USB-anslutningen misslyckades"
+
+msgid "IDS_COM_HEADER_USB_ACCESSORY"
+msgstr "USB-tillbehör"
+
+msgid "IDS_COM_POP_ALLOW_APPLICATION_P1SS_TO_ACCESS_USB_ACCESSORY_Q_ABB"
+msgstr "Tillåt att programmet får åtkomst till USB-tillbehöret?"
+
--- /dev/null
+msgid "IDS_USB_POP_USB_CONNECTION_FAILED"
+msgstr "USB bağlantısı kurulamadı"
+
+msgid "IDS_COM_HEADER_USB_ACCESSORY"
+msgstr "USB aksesuarı"
+
+msgid "IDS_COM_POP_ALLOW_APPLICATION_P1SS_TO_ACCESS_USB_ACCESSORY_Q_ABB"
+msgstr "Uygulama'nin USB aksesuarına erişmesine izin verilsin mi?"
+
--- /dev/null
+msgid "IDS_USB_POP_USB_CONNECTION_FAILED"
+msgstr "Збій підключення через USB"
+
+msgid "IDS_COM_HEADER_USB_ACCESSORY"
+msgstr "USB-аксесуар"
+
+msgid "IDS_COM_POP_ALLOW_APPLICATION_P1SS_TO_ACCESS_USB_ACCESSORY_Q_ABB"
+msgstr "Дозволити програмі отримувати доступ до цього USB-пристрою?"
+
--- /dev/null
+msgid "IDS_USB_POP_USB_CONNECTION_FAILED"
+msgstr "USB ulanishi bajarilmadi"
+
+msgid "IDS_COM_HEADER_USB_ACCESSORY"
+msgstr "USB aksessuari"
+
+msgid "IDS_COM_POP_ALLOW_APPLICATION_P1SS_TO_ACCESS_USB_ACCESSORY_Q_ABB"
+msgstr "ilovasiga USB aksessuariga kirish uchun ruxsat berilsinmi?"
+
--- /dev/null
+msgid "IDS_USB_POP_USB_CONNECTION_FAILED"
+msgstr "USB 连接失败"
+
+msgid "IDS_COM_HEADER_USB_ACCESSORY"
+msgstr "USB配件"
+
+msgid "IDS_COM_POP_ALLOW_APPLICATION_P1SS_TO_ACCESS_USB_ACCESSORY_Q_ABB"
+msgstr "是否允许应用程序 访问 USB 附件?"
+
--- /dev/null
+msgid "IDS_USB_POP_USB_CONNECTION_FAILED"
+msgstr "USB 連接失敗"
+
+msgid "IDS_COM_HEADER_USB_ACCESSORY"
+msgstr "USB 配件"
+
+msgid "IDS_COM_POP_ALLOW_APPLICATION_P1SS_TO_ACCESS_USB_ACCESSORY_Q_ABB"
+msgstr "允許應用程式 存取 USB 配件嗎?"
+
--- /dev/null
+msgid "IDS_USB_POP_USB_CONNECTION_FAILED"
+msgstr "USB 连接失败"
+
+msgid "IDS_COM_HEADER_USB_ACCESSORY"
+msgstr "USB 附件"
+
+msgid "IDS_COM_POP_ALLOW_APPLICATION_P1SS_TO_ACCESS_USB_ACCESSORY_Q_ABB"
+msgstr "是否允许应用程序 访问 USB 附件?"
+
--- /dev/null
+msgid "IDS_USB_POP_USB_CONNECTION_FAILED"
+msgstr "USB 連接失敗"
+
+msgid "IDS_COM_HEADER_USB_ACCESSORY"
+msgstr "USB 配件"
+
+msgid "IDS_COM_POP_ALLOW_APPLICATION_P1SS_TO_ACCESS_USB_ACCESSORY_Q_ABB"
+msgstr "允許應用程式 存取 USB 配件嗎?"
+
--- /dev/null
+/*
+ * usb-syspopup
+ * Copyright (c) 2012 Samsung Electronics Co., Ltd.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#include <stdio.h>
+#include <vconf.h>
+#include <ail.h>
+#include <string.h>
+#include <sys/un.h>
+#include <sys/socket.h>
+#include <appcore-efl.h>
+#include <Ecore_X.h>
+#include <assert.h>
+#include "usb-syspopup.h"
+
+#define SOCK_PATH "/tmp/usb_server_sock"
+#define SOCK_STR_LEN 1542
+
+#define SYSPOPUP_TYPE "_SYSPOPUP_TYPE"
+
+#define ACC_MANUFACTURER "_ACC_MANUFACTURER"
+#define ACC_MODEL "_ACC_MODEL"
+#define ACC_DESCRIPTION "_ACC_DESCRIPTION"
+#define ACC_VERSION "_ACC_VERSION"
+#define ACC_URI "_ACC_URI"
+#define ACC_SERIAL "_ACC_SERIAL"
+
+#define HOST_CLASS "_HOST_CLASS"
+#define HOST_SUBCLASS "_HOST_SUBCLASS"
+#define HOST_PROTOCOL "_HOST_PROTOCOL"
+#define HOST_IDVENDOR "_HOST_IDVENDOR"
+#define HOST_IDPRODUCT "_HOST_IDPRODUCT"
+
+static int ipc_socket_client_init()
+{
+ __USB_FUNC_ENTER__ ;
+ int sock;
+ struct sockaddr_un remote;
+
+ if ((sock = socket(AF_UNIX, SOCK_STREAM, 0)) == -1) {
+ USB_LOG("FAIL: socket(AF_UNIX, SOCK_STREAM, 0)");
+ return -1;
+ }
+ remote.sun_family = AF_UNIX;
+ strncpy(remote.sun_path, SOCK_PATH, sizeof(remote.sun_path));
+
+ if (connect(sock, (struct sockaddr *)&remote, sizeof(remote)) == -1) {
+ USB_LOG("FAIL: connect(sock, (struct sockaddr *)&remote, len)");
+ close(sock);
+ return -1;
+ }
+ __USB_FUNC_EXIT__ ;
+ return sock;
+}
+
+static void __win_del(void *data, Evas_Object * obj, void *event)
+{
+ __USB_FUNC_ENTER__ ;
+ elm_exit();
+ __USB_FUNC_EXIT__ ;
+}
+
+static Evas_Object *__create_win(const char *name)
+{
+ __USB_FUNC_ENTER__ ;
+ assert(name);
+ Evas_Object *eo;
+ int w;
+ int h;
+
+ eo = elm_win_add(NULL, name, ELM_WIN_DIALOG_BASIC);
+ if (!eo) {
+ USB_LOG("FAIL: elm_win_add()");
+ return NULL;
+ }
+
+ elm_win_title_set(eo, name);
+ elm_win_borderless_set(eo, EINA_TRUE);
+ elm_win_alpha_set(eo, EINA_TRUE);
+ elm_win_raise(eo);
+ evas_object_smart_callback_add(eo, "delete,request", __win_del, NULL);
+ ecore_x_window_size_get(ecore_x_window_root_first_get(), &w, &h);
+ evas_object_resize(eo, w, h);
+
+ __USB_FUNC_EXIT__ ;
+
+ return eo;
+}
+
+static void usp_usbclient_chgdet_cb(keynode_t *key, void *data)
+{
+ __USB_FUNC_ENTER__ ;
+ int ret;
+ int usb_status;
+
+ ret = vconf_get_int(VCONFKEY_SYSMAN_USB_STATUS, &usb_status);
+ if (0 == ret && usb_status == VCONFKEY_SYSMAN_USB_DISCONNECTED) {
+ USB_LOG("USB cable is not connected");
+ elm_exit();
+ }
+ __USB_FUNC_EXIT__ ;
+}
+
+static void usp_usbhost_chgdet_cb(keynode_t *key, void *data)
+{
+ __USB_FUNC_ENTER__ ;
+ int ret;
+ int usb_status;
+
+ ret = vconf_get_int(VCONFKEY_SYSMAN_USB_HOST_STATUS, &usb_status);
+ if (0 == ret && usb_status == VCONFKEY_SYSMAN_USB_HOST_DISCONNECTED) {
+ USB_LOG("USB host is not connected");
+ elm_exit();
+ }
+ __USB_FUNC_EXIT__ ;
+}
+
+static int usp_vconf_key_notify(void)
+{
+ __USB_FUNC_ENTER__;
+ int ret;
+
+ /* Event for USB cable */
+ ret = vconf_notify_key_changed(VCONFKEY_SYSMAN_USB_STATUS,
+ usp_usbclient_chgdet_cb, NULL);
+ if (0 != ret) {
+ USB_LOG("FAIL: vconf_notify_key_changed(VCONFKEY_SYSMAN_USB_STATUS)");
+ return -1;
+ }
+
+ /* Event for USB host */
+ ret = vconf_notify_key_changed(VCONFKEY_SYSMAN_USB_HOST_STATUS,
+ usp_usbhost_chgdet_cb, NULL);
+ if (0 != ret) {
+ USB_LOG("FAIL: vconf_notify_key_changed(VCONFKEY_SYSMAN_USB_HOST_STATUS)");
+ return -1;
+ }
+
+ __USB_FUNC_EXIT__ ;
+ return 0;
+}
+
+static int usp_vconf_key_ignore(void)
+{
+ __USB_FUNC_ENTER__;
+ int ret;
+
+ /* Event for USB cable */
+ ret = vconf_ignore_key_changed(VCONFKEY_SYSMAN_USB_STATUS, usp_usbclient_chgdet_cb);
+ if (0 != ret) {
+ USB_LOG("FAIL: vconf_ignore_key_changed(VCONFKEY_SYSMAN_USB_STATUS)");
+ return -1;
+ }
+
+ /* Event for USB host */
+ ret = vconf_ignore_key_changed(VCONFKEY_SYSMAN_USB_HOST_STATUS, usp_usbhost_chgdet_cb);
+ if (0 != ret) {
+ USB_LOG("FAIL: vconf_ignore_key_changed(VCONFKEY_SYSMAN_USB_HOST_STATUS)");
+ return -1;
+ }
+
+ __USB_FUNC_EXIT__ ;
+ return 0;
+}
+
+static int __app_create(void *data)
+{
+ __USB_FUNC_ENTER__ ;
+ assert(data);
+ struct appdata *ad = (struct appdata *)data;
+ int ret;
+
+ ad->handler.def_term_fn = NULL;
+ ad->handler.def_timeout_fn = NULL;
+ ad->usbAcc = NULL;
+ ad->usbHost = NULL;
+ ad->mApps = NULL;
+
+ ret = usp_vconf_key_notify();
+ if (ret != 0) {
+ USB_LOG("FAIL: usp_vconf_key_notify()");
+ return -1;
+ }
+
+ /* init internationalization */
+ ret = appcore_set_i18n(PACKAGE, LOCALEDIR);
+ if (ret != 0) {
+ USB_LOG("FAIL: appcore_set_i18n(PACKAGE, LOCALEDIR)");
+ return -1;
+ }
+
+ __USB_FUNC_EXIT__ ;
+
+ return 0;
+}
+
+static void unload_popup(struct appdata *ad)
+{
+ __USB_FUNC_ENTER__ ;
+ assert(ad);
+
+ if (ad->win) {
+ evas_object_del(ad->win);
+ ad->win = NULL;
+ }
+
+ __USB_FUNC_EXIT__ ;
+}
+
+static int __app_terminate(void *data)
+{
+ __USB_FUNC_ENTER__ ;
+ assert(data);
+ struct appdata *ad = (struct appdata *)data;
+ int ret;
+
+ ret = usp_vconf_key_ignore();
+ if (ret != 0) USB_LOG("FAIL: usp_vconf_key_ignore()");
+
+ unload_popup(ad);
+
+ if (ad->b) {
+ ret = bundle_free(ad->b);
+ if (ret != 0) {
+ USB_LOG("FAIL: bundle_free(ad->b)");
+ }
+ ad->b = NULL;
+ }
+
+ if (ad->usbAcc) {
+ FREE(ad->usbAcc->manufacturer);
+ FREE(ad->usbAcc->model);
+ FREE(ad->usbAcc->description);
+ FREE(ad->usbAcc->version);
+ FREE(ad->usbAcc->uri);
+ FREE(ad->usbAcc->serial);
+ }
+
+ FREE(ad->usbAcc);
+ FREE(ad->usbHost);
+
+ if (ad->mApps) {
+ g_list_free(ad->mApps);
+ }
+
+ __USB_FUNC_EXIT__ ;
+ return 0;
+}
+
+static int __app_pause(void *data)
+{
+ __USB_FUNC_ENTER__ ;
+ __USB_FUNC_EXIT__ ;
+ return 0;
+}
+
+static int __app_resume(void *data)
+{
+ __USB_FUNC_ENTER__ ;
+ __USB_FUNC_EXIT__ ;
+ return 0;
+}
+
+static int request_to_usb_server(int request, char *pkgName, char *answer, int answerLen)
+{
+ __USB_FUNC_ENTER__ ;
+ assert(answer);
+ int sock_remote;
+ char str[SOCK_STR_LEN];
+ int t;
+ sock_remote = ipc_socket_client_init();
+ if (0 > sock_remote) {
+ USB_LOG("FAIL: ipc_socket_client_init()");
+ return -1;
+ }
+
+ switch (request) {
+ case LAUNCH_APP_FOR_ACC:
+ case LAUNCH_APP_FOR_HOST:
+ snprintf(str, sizeof(str), "%d|%s", request, pkgName);
+ break;
+ default:
+ snprintf(str, sizeof(str), "%d|", request);
+ break;
+ }
+ USB_LOG("request: %s", str);
+
+ if (send (sock_remote, str, strlen(str)+1, 0) == -1) {
+ USB_LOG("FAIL: send (sock_remote, str, strlen(str), 0)");
+ close(sock_remote);
+ return -1;
+ }
+
+ if ((t = recv(sock_remote, answer, answerLen, 0)) > 0) {
+ if (t < answerLen) {
+ answer[t] = '\0';
+ } else { /* t == answerLen */
+ answer[answerLen-1] = '\0';
+ }
+ USB_LOG("[CLIENT] Received value: %s", answer);
+ } else {
+ USB_LOG("FAIL: recv(sock_remote, answer, answerLen, 0)");
+ close(sock_remote);
+ return -1;
+ }
+
+ close(sock_remote);
+ __USB_FUNC_EXIT__ ;
+ return 0;
+}
+
+static int load_normal_popup(struct appdata *ad,
+ char *mainText,
+ char *lbtnText,
+ Evas_Smart_Cb lbtn_cb,
+ char *rbtnText,
+ Evas_Smart_Cb rbtn_cb)
+{
+ __USB_FUNC_ENTER__ ;
+ assert(ad);
+ assert(mainText);
+ assert(lbtnText);
+ assert(lbtn_cb);
+
+ Evas_Object *win;
+ int ret = -1;
+ Evas_Object *lbtn;
+ Evas_Object *rbtn;
+
+ unload_popup(ad);
+
+ /* create window */
+ win = __create_win(PACKAGE);
+ if (win == NULL)
+ return -1;
+ ad->win = win;
+
+ ret = syspopup_create(ad->b, &(ad->handler), ad->win, ad);
+ if (0 != ret) {
+ USB_LOG("FAIL: syspopup_create(): %d", ret);
+ return -1;
+ }
+
+ evas_object_show(ad->win);
+ ad->popup = elm_popup_add(ad->win);
+ evas_object_size_hint_weight_set(ad->popup, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
+ elm_object_text_set(ad->popup, mainText);
+
+ if (lbtnText && lbtn_cb) {
+ /* Left button */
+ lbtn = elm_button_add(ad->popup);
+ elm_object_text_set(lbtn, lbtnText);
+ elm_object_part_content_set(ad->popup, "button1", lbtn);
+ evas_object_smart_callback_add(lbtn, "clicked", lbtn_cb, ad);
+ }
+
+ if (rbtnText && rbtn_cb) {
+ /* Right button */
+ rbtn = elm_button_add(ad->popup);
+ elm_object_text_set(rbtn, rbtnText);
+ elm_object_part_content_set(ad->popup, "button2", rbtn);
+ evas_object_smart_callback_add(rbtn, "clicked", rbtn_cb, ad);
+ }
+
+ evas_object_show(ad->popup);
+
+ __USB_FUNC_EXIT__ ;
+ return 0;
+}
+
+static void load_connection_failed_popup_ok_response_cb(void *data, Evas_Object *obj, void *info)
+{
+ __USB_FUNC_ENTER__;
+ assert(data);
+ struct appdata *ad = (struct appdata *)data;
+ char buf[SOCK_STR_LEN];
+ int ret;
+
+ unload_popup(ad);
+
+ ret = request_to_usb_server(ERROR_POPUP_OK_BTN, NULL, buf, sizeof(buf));
+ if (ret < 0) {
+ USB_LOG("FAIL: request_to_usb_server(ERROR_POPUP_OK_BTN)");
+ return;
+ }
+
+ elm_exit();
+
+ __USB_FUNC_EXIT__ ;
+}
+
+static void notice_to_usb_server_perm_response(struct appdata *ad, int info)
+{
+ __USB_FUNC_ENTER__;
+ assert(ad);
+ int ret;
+ char buf[SOCK_STR_LEN];
+
+ unload_popup(ad);
+
+ ret = request_to_usb_server(info, NULL, buf, sizeof(buf));
+ if (ret < 0) {
+ USB_LOG("FAIL: request_to_usb_server()");
+ }
+ __USB_FUNC_EXIT__ ;
+}
+
+static void request_perm_popup_yes_response_cb(void *data, Evas_Object * obj, void *event_info)
+{
+ __USB_FUNC_ENTER__;
+ assert(data);
+ struct appdata *ad = (struct appdata *)data;
+
+ switch (ad->type) {
+ case REQ_ACC_PERM_POPUP:
+ notice_to_usb_server_perm_response(ad, REQ_ACC_PERM_NOTI_YES_BTN);
+ break;
+ case REQ_HOST_PERM_POPUP:
+ notice_to_usb_server_perm_response(ad, REQ_HOST_PERM_NOTI_YES_BTN);
+ break;
+ default:
+ USB_LOG("ERROR: ad->type is improper: %d", ad->type);
+ break;
+ }
+
+ elm_exit();
+ __USB_FUNC_EXIT__ ;
+}
+
+static void request_perm_popup_no_response_cb(void *data, Evas_Object * obj, void *event_info)
+{
+ __USB_FUNC_ENTER__;
+ assert(data);
+ struct appdata *ad = (struct appdata *)data;
+
+ switch (ad->type) {
+ case REQ_ACC_PERM_POPUP:
+ notice_to_usb_server_perm_response(ad, REQ_ACC_PERM_NOTI_NO_BTN);
+ break;
+ case REQ_HOST_PERM_POPUP:
+ notice_to_usb_server_perm_response(ad, REQ_HOST_PERM_NOTI_NO_BTN);
+ break;
+ default:
+ USB_LOG("ERROR: ad->type is improper: %d", ad->type);
+ break;
+ }
+
+ elm_exit();
+ __USB_FUNC_EXIT__ ;
+}
+
+static void load_connection_failed_popup(void *data)
+{
+ __USB_FUNC_ENTER__ ;
+ assert(data);
+ struct appdata *ad = (struct appdata *)data;
+ int ret;
+
+ ret = load_normal_popup(ad,
+ gettext("IDS_USB_POP_USB_CONNECTION_FAILED"),
+ dgettext("sys_string","IDS_COM_SK_OK"),
+ load_connection_failed_popup_ok_response_cb,
+ NULL,
+ NULL);
+ if (0 > ret) {
+ USB_LOG("FAIL: load_normal_popup(): %d", ret);
+ elm_exit();
+ }
+
+ __USB_FUNC_EXIT__ ;
+}
+
+static char *_gl_text_get(void *data, Evas_Object *obj, const char *part)
+{
+ __USB_FUNC_ENTER__ ;
+ assert(data);
+ char *text = (char *)data;
+ __USB_FUNC_EXIT__ ;
+ return strdup(text);
+}
+
+static void select_app_popup_cancel_response_cb(void *data, Evas_Object * obj, void *event_info)
+{
+ __USB_FUNC_ENTER__ ;
+ assert(data);
+ struct appdata *ad = (struct appdata *)data;
+ unload_popup(ad);
+ elm_exit();
+ __USB_FUNC_EXIT__ ;
+}
+
+static int launch_app_for_device(struct appdata *ad, char *appId)
+{
+ __USB_FUNC_ENTER__ ;
+ assert(ad);
+ assert(appId);
+ int ret;
+ char answer[SOCK_STR_LEN];
+
+ switch (ad->type) {
+ case SELECT_PKG_FOR_ACC_POPUP:
+ ret = request_to_usb_server(LAUNCH_APP_FOR_ACC, appId,
+ answer, sizeof(answer));
+ break;
+ case SELECT_PKG_FOR_HOST_POPUP:
+ ret = request_to_usb_server(LAUNCH_APP_FOR_HOST, appId,
+ answer, sizeof(answer));
+ break;
+ default:
+ ret = -1;
+ break;
+ }
+ if (0 != ret) {
+ USB_LOG("FAIL: request_to_usb_server(LAUNCH_APP, ad->selPkg, answer)");
+ return -1;
+ }
+
+ USB_LOG("Launching app result is %s", answer);
+ __USB_FUNC_EXIT__ ;
+ return 0;
+}
+
+static void select_app_popup_gl_select_cb(void *data, Evas_Object *obj, void *event_info)
+{
+ __USB_FUNC_ENTER__ ;
+ assert(event_info);
+ assert(data);
+ struct appdata *ad = (struct appdata *)data;
+ char *appId;
+ int ret;
+ Elm_Object_Item *item = (Elm_Object_Item *)event_info;
+
+ if (!item) {
+ USB_LOG("ERROR: item is NULL");
+ unload_popup(ad);
+ return;
+ }
+
+ appId = (char *)elm_object_item_data_get(item);
+ USB_LOG("Selected Item: %s", appId);
+
+ unload_popup(ad);
+
+ ret = launch_app_for_device(ad, appId);
+ if (0 != ret) {
+ USB_LOG("FAIL: send_sel_pkg_to_usb_server(ad)");
+ }
+
+ elm_exit();
+
+ __USB_FUNC_EXIT__ ;
+}
+
+static void load_popup_to_select_app(struct appdata *ad)
+{
+ __USB_FUNC_ENTER__ ;
+ assert(ad);
+ int ret;
+ char *text;
+ GList *l;
+ Evas_Object *btn;
+ Evas_Object *win;
+ Evas_Object *genlist;
+ Elm_Object_Item *item;
+
+ /* create window */
+ win = __create_win(PACKAGE);
+ if (win == NULL)
+ return ;
+ ad->win = win;
+
+ ret = syspopup_create(ad->b, &(ad->handler), ad->win, ad);
+ if (ret != 0) {
+ USB_LOG("FAIL: syspopup_create(): %d", ret);
+ return ;
+ }
+
+ evas_object_show(ad->win);
+ ad->popup = elm_popup_add(ad->win);
+ elm_object_style_set(ad->popup,"menustyle");
+ elm_object_part_text_set(ad->popup, "title,text", "Select app to launch");
+ evas_object_size_hint_weight_set(ad->popup, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
+ btn = elm_button_add(ad->popup);
+ elm_object_text_set(btn, "Cancel");
+ elm_object_part_content_set(ad->popup, "button1", btn);
+ evas_object_smart_callback_add(btn, "clicked", select_app_popup_cancel_response_cb, ad);
+
+ ad->itc.item_style = "1text";
+ ad->itc.func.text_get = _gl_text_get;
+ ad->itc.func.content_get = NULL;
+ ad->itc.func.state_get = NULL;
+ ad->itc.func.del = NULL;
+ genlist = elm_genlist_add(ad->popup);
+ 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);
+
+ for (l = ad->mApps; l; l = g_list_next(l)) {
+ text = (char *)(l->data);
+ item = elm_genlist_item_append(genlist, &(ad->itc), (void *) text, NULL,
+ ELM_GENLIST_ITEM_NONE, select_app_popup_gl_select_cb, ad);
+ if (!item) {
+ USB_LOG("ERROR: item == NULL");
+ }
+ }
+
+ elm_object_content_set(ad->popup, genlist);
+ evas_object_show(ad->popup);
+
+ __USB_FUNC_EXIT__ ;
+}
+
+static void load_popup_to_confirm_uri(struct appdata *ad)
+{
+ __USB_FUNC_ENTER__ ;
+ /* TODO
+ * After using Manifest for Accessory and Host,
+ * this function can be implemented*/
+ __USB_FUNC_EXIT__ ;
+}
+
+static int get_accessory_info(struct appdata *ad)
+{
+ __USB_FUNC_ENTER__ ;
+ assert(ad);
+ assert(ad->usbAcc);
+
+ ad->usbAcc->manufacturer = strdup(bundle_get_val(ad->b, ACC_MANUFACTURER));
+ if (!(ad->usbAcc->manufacturer))
+ goto out_manufacturer;
+
+ ad->usbAcc->model = strdup(bundle_get_val(ad->b, ACC_MODEL));
+ if (!(ad->usbAcc->model))
+ goto out_model;
+
+ ad->usbAcc->description = strdup(bundle_get_val(ad->b, ACC_DESCRIPTION));
+ if (!(ad->usbAcc->description))
+ goto out_description;
+
+ ad->usbAcc->version = strdup(bundle_get_val(ad->b, ACC_VERSION));
+ if (!(ad->usbAcc->version))
+ goto out_version;
+
+ ad->usbAcc->uri = strdup(bundle_get_val(ad->b, ACC_URI));
+ if (!(ad->usbAcc->uri))
+ goto out_uri;
+
+ ad->usbAcc->serial = strdup(bundle_get_val(ad->b, ACC_SERIAL));
+ if (!(ad->usbAcc->serial))
+ goto out_serial;
+
+ __USB_FUNC_EXIT__ ;
+ return 0;
+
+out_serial:
+ FREE(ad->usbAcc->serial);
+out_uri:
+ FREE(ad->usbAcc->uri);
+out_version:
+ FREE(ad->usbAcc->version);
+out_description:
+ FREE(ad->usbAcc->description);
+out_model:
+ FREE(ad->usbAcc->model);
+out_manufacturer:
+ FREE(ad->usbAcc->manufacturer);
+
+ __USB_FUNC_EXIT__ ;
+ return -1;
+}
+
+static int get_host_info(struct appdata *ad)
+{
+ __USB_FUNC_ENTER__ ;
+ assert(ad);
+ assert(ad->usbHost);
+
+ char *text;
+
+ text = (char *)bundle_get_val(ad->b, HOST_CLASS);
+ if (!text) return -1;
+ ad->usbHost->devClass = atoi(text);
+
+ text = (char *)bundle_get_val(ad->b, HOST_SUBCLASS);
+ if (!text) return -1;
+ ad->usbHost->devSubClass = atoi(text);
+
+ text = (char *)bundle_get_val(ad->b, HOST_PROTOCOL);
+ if (!text) return -1;
+ ad->usbHost->devProtocol = atoi(text);
+
+ text = (char *)bundle_get_val(ad->b, HOST_IDVENDOR);
+ if (!text) return -1;
+ ad->usbHost->idVendor = atoi(text);
+
+ text = (char *)bundle_get_val(ad->b, HOST_IDPRODUCT);
+ if (!text) return -1;
+ ad->usbHost->idProduct = atoi(text);
+
+ __USB_FUNC_EXIT__ ;
+ return 0;
+}
+
+static int get_accessory_matched(struct appdata* ad)
+{
+ __USB_FUNC_ENTER__ ;
+ assert(ad);
+ if (ad->mApps) {
+ g_list_free(ad->mApps);
+ ad->mApps = NULL;
+ }
+
+ /* TODO ************************************************
+ * Find apps which is matched with the connected device
+ * and store the apps to the list (ad->mApps) */
+ ad->mApps = g_list_append(ad->mApps, "acc_test");
+ /*******************************************************/
+
+ __USB_FUNC_EXIT__ ;
+ return g_list_length(ad->mApps);
+}
+
+static void load_select_pkg_for_acc_popup(struct appdata *ad)
+{
+ __USB_FUNC_ENTER__ ;
+ assert(ad);
+ int ret;
+ int numOfApps;
+
+ ad->usbAcc = (struct UsbAccessory *)malloc(sizeof(struct UsbAccessory));
+
+ ret = get_accessory_info(ad);
+ if (0 > ret) {
+ USB_LOG("FAIL: get_accessory_info(ad)");
+ elm_exit();
+ }
+
+ numOfApps = get_accessory_matched(ad);
+ USB_LOG("number of apps matched: %d", numOfApps);
+ if (numOfApps > 0) {
+ load_popup_to_select_app(ad);
+ } else {
+ load_popup_to_confirm_uri(ad);
+ }
+ __USB_FUNC_EXIT__ ;
+}
+
+static int get_host_matched(struct appdata* ad)
+{
+ __USB_FUNC_ENTER__ ;
+ assert(ad);
+ if (ad->mApps) {
+ g_list_free(ad->mApps);
+ ad->mApps = NULL;
+ }
+
+ /* TODO ************************************************
+ * Find apps which is matched with the connected device
+ * and store the apps to the list (ad->mApps) */
+ ad->mApps = g_list_append(ad->mApps, "host_test");
+ /*******************************************************/
+
+ __USB_FUNC_EXIT__ ;
+ return g_list_length(ad->mApps);
+}
+
+static void load_select_pkg_for_host_popup(struct appdata *ad)
+{
+ __USB_FUNC_ENTER__ ;
+ assert(ad);
+ int ret;
+ int numOfApps;
+
+ ad->usbHost = (struct UsbHost *)malloc(sizeof(struct UsbHost));
+
+ ret = get_host_info(ad);
+ if (0 > ret) {
+ USB_LOG("FAIL: get_host_info(ad)");
+ elm_exit();
+ }
+
+ numOfApps = get_host_matched(ad);
+ USB_LOG("number of apps matched: %d\n", numOfApps);
+ if (numOfApps > 0) {
+ load_popup_to_select_app(ad);
+ } else {
+ load_popup_to_confirm_uri(ad);
+ }
+ __USB_FUNC_EXIT__ ;
+}
+
+void load_request_perm_popup(struct appdata *ad)
+{
+ __USB_FUNC_ENTER__ ;
+ assert(ad);
+ int ret;
+ char *text;
+
+ switch (ad->type) {
+ case REQ_ACC_PERM_POPUP:
+ text = gettext("IDS_COM_POP_ALLOW_APPLICATION_P1SS_TO_ACCESS_USB_ACCESSORY_Q_ABB");
+ break;
+ case REQ_HOST_PERM_POPUP:
+ text = "Allow application to access USB host?";
+ break;
+ default:
+ USB_LOG("ERROR: ad->type is improper");
+ return;
+ }
+ USB_LOG("Main text is (%s)\n", text);
+
+ ret = load_normal_popup(ad,
+ text,
+ dgettext("sys_string","IDS_COM_SK_YES"),
+ request_perm_popup_yes_response_cb,
+ dgettext("sys_string","IDS_COM_SK_NO"),
+ request_perm_popup_no_response_cb);
+ if (0 > ret) {
+ USB_LOG("FAIL: load_normal_popup(): %d", ret);
+ elm_exit();
+ }
+
+ __USB_FUNC_EXIT__ ;
+}
+
+static int __app_reset(bundle *b, void *data)
+{
+ __USB_FUNC_ENTER__ ;
+ assert(data);
+ struct appdata *ad = data;
+ char *type;
+
+ ad->b = bundle_dup(b);
+
+ /* When syspopup is already loaded, remove the popup and load new popup */
+ if (syspopup_has_popup(b)) {
+ USB_LOG("usb-syspopup is already loaded");
+ unload_popup(ad);
+ /* Resetting all proporties of syspopup */
+ syspopup_reset(b);
+ }
+
+ type = (char *)bundle_get_val(b, SYSPOPUP_TYPE);
+ if (!type) {
+ USB_LOG("ERROR: Non existing type of popup\n");
+ elm_exit();
+ }
+
+ ad->type = atoi(type);
+ USB_LOG("ad->type is (%d)\n", ad->type);
+
+ /* In case that USB cable/device is disconnected before launching popup,
+ * the connection status are checked according to the popup type */
+ switch(ad->type) {
+ case ERROR_POPUP:
+ case SELECT_PKG_FOR_ACC_POPUP:
+ case REQ_ACC_PERM_POPUP:
+ ad->isClientOrHost = USB_DEVICE_CLIENT;
+ usp_usbclient_chgdet_cb(NULL, NULL);
+ break;
+ case SELECT_PKG_FOR_HOST_POPUP:
+ case REQ_HOST_PERM_POPUP:
+ ad->isClientOrHost = USB_DEVICE_HOST;
+ usp_usbhost_chgdet_cb(NULL, NULL);
+ break;
+ default:
+ USB_LOG("ERROR: The popup type(%d) does not exist\n", ad->type);
+ ad->isClientOrHost = USB_DEVICE_UNKNOWN;
+ elm_exit();
+ break;
+ }
+
+ switch(ad->type) {
+ case ERROR_POPUP:
+ USB_LOG("Connection failed popup is loaded");
+ load_connection_failed_popup(ad);
+ break;
+ case SELECT_PKG_FOR_ACC_POPUP:
+ USB_LOG("Select pkg for acc popup is loaded");
+ load_select_pkg_for_acc_popup(ad);
+ break;
+ case SELECT_PKG_FOR_HOST_POPUP:
+ USB_LOG("Select pkg for host popup is loaded");
+ load_select_pkg_for_host_popup(ad);
+ break;
+ case REQ_ACC_PERM_POPUP:
+ case REQ_HOST_PERM_POPUP:
+ USB_LOG("Request Permission popup is loaded");
+ load_request_perm_popup(ad);
+ break;
+ default:
+ USB_LOG("ERROR: The popup type(%d) does not exist", ad->type);
+ return -1;
+ }
+
+ __USB_FUNC_EXIT__ ;
+ return 0;
+}
+
+int main(int argc, char *argv[])
+{
+ __USB_FUNC_ENTER__ ;
+
+ struct appdata ad;
+ struct appcore_ops ops = {
+ .create = __app_create,
+ .terminate = __app_terminate,
+ .pause = __app_pause,
+ .resume = __app_resume,
+ .reset = __app_reset,
+ };
+
+ memset(&ad, 0x0, sizeof(struct appdata));
+
+ ops.data = &ad;
+
+ __USB_FUNC_EXIT__ ;
+ return appcore_efl_main(PACKAGE, &argc, &argv, &ops);
+}
--- /dev/null
+/*
+ * usb-syspopup
+ * Copyright (c) 2012 Samsung Electronics Co., Ltd.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#ifndef __SYSPOPUP_APP_H__
+#define __SYSPOPUP_APP_H__
+
+#include <syspopup.h>
+#include <glib.h>
+
+#if !defined(PACKAGE)
+#define PACKAGE "usb-syspopup"
+#endif
+
+#include <dlog.h>
+#undef LOG_TAG
+#define LOG_TAG "USB_SYSPOPUP"
+#define USB_LOG(fmt, args...) SLOGD(fmt, ##args)
+#define __USB_FUNC_ENTER__ USB_LOG("ENTER")
+#define __USB_FUNC_EXIT__ USB_LOG("EXIT")
+
+#define FREE(arg) \
+ do { \
+ if(arg) { \
+ free((void *)arg); \
+ arg = NULL; \
+ } \
+ } while (0);
+
+typedef enum {
+ ERROR_POPUP = 0,
+ SELECT_PKG_FOR_ACC_POPUP,
+ SELECT_PKG_FOR_HOST_POPUP,
+ REQ_ACC_PERM_POPUP,
+ REQ_HOST_PERM_POPUP,
+ MAX_NUM_SYSPOPUP_TYPE
+ /* When we need to add other system popup,
+ * Write here the type of popup */
+} POPUP_TYPE;
+
+typedef enum {
+ USB_DEVICE_CLIENT = 0,
+ USB_DEVICE_HOST,
+ USB_DEVICE_BOTH,
+ USB_DEVICE_UNKNOWN
+} IS_CLIENT_OR_HOST;
+
+typedef enum {
+ /* General */
+ ERROR_POPUP_OK_BTN = 0,
+ IS_EMUL_BIN,
+
+ /* for Accessory */
+ LAUNCH_APP_FOR_ACC = 20,
+ REQ_ACC_PERMISSION,
+ HAS_ACC_PERMISSION,
+ REQ_ACC_PERM_NOTI_YES_BTN,
+ REQ_ACC_PERM_NOTI_NO_BTN,
+ GET_ACC_INFO,
+
+ /* for Host */
+ LAUNCH_APP_FOR_HOST = 40,
+ REQ_HOST_PERMISSION,
+ HAS_HOST_PERMISSION,
+ REQ_HOST_PERM_NOTI_YES_BTN,
+ REQ_HOST_PERM_NOTI_NO_BTN,
+ REQ_HOST_CONNECTION
+} REQUEST_TO_USB_MANGER;
+
+struct UsbAccessory {
+ char *manufacturer;
+ char *model;
+ char *description;
+ char *version;
+ char *uri;
+ char *serial;
+};
+
+struct UsbHost {
+ int devClass;
+ int devSubClass;
+ int devProtocol;
+ int idVendor;
+ int idProduct;
+};
+
+struct appdata {
+ Evas_Object *win;
+ Evas_Object *popup;
+ bundle *b;
+ int type;
+ int isClientOrHost;
+ syspopup_handler handler;
+ Elm_Genlist_Item_Class itc;
+
+ GList *mApps;
+ struct UsbAccessory *usbAcc;
+ struct UsbHost *usbHost;
+
+
+ /* add more variables here */
+};
+
+#endif /* __SYSPOPUP_APP_H__ */
+
-
-########################### usbotg ###########################
CMAKE_MINIMUM_REQUIRED(VERSION 2.6)
-PROJECT(usbotg-popup C)
-
-SET(SRCS ${CMAKE_SOURCE_DIR}/usbotg-popup/src/usbotg.c)
-IF("${CMAKE_BUILD_TYPE}" STREQUAL "")
- SET(CMAKE_BUILD_TYPE "Release")
-ENDIF("${CMAKE_BUILD_TYPE}" STREQUAL "")
-MESSAGE("Build type: ${CMAKE_BUILD_TYPE}")
+SET(SRCS src/usbotg-syspopup.c)
-INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR})
-INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/usbotg-popup)
+SET(VENDOR "tizen")
+SET(PACKAGE "usbotg-syspopup")
+SET(PKGNAME "org.${VENDOR}.${PACKAGE}")
+SET(PREFIX "${CMAKE_INSTALL_PREFIX}/apps/${PKGNAME}")
+SET(BINDIR "${PREFIX}/bin")
+SET(RESDIR "${PREFIX}/res")
+SET(LOCALEDIR "${RESDIR}/locale")
+SET(MANIFESTDIR "${CMAKE_INSTALL_PREFIX}/share/packages")
INCLUDE(FindPkgConfig)
-pkg_check_modules(pkgs REQUIRED appcore-efl elementary devman devman_haptic mm-sound sysman syspopup syspopup-caller ecore-evas appsvc)
+pkg_check_modules(pkgs REQUIRED
+ appcore-efl
+ elementary
+ devman
+ syspopup
+ syspopup-caller
+ ecore-evas
+ vconf
+ appsvc
+ dlog)
FOREACH(flag ${pkgs_CFLAGS})
- SET(EXTRA_CFLAGS "${EXTRA_CFLAGS} ${flag} -g -I/usr/include/elementary-0 ")
+ SET(EXTRA_CFLAGS "${EXTRA_CFLAGS} ${flag}")
ENDFOREACH(flag)
-SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${EXTRA_CFLAGS}")
-SET(CMAKE_C_FLAGS_DEBUG "-O0 -g")
-SET(CMAKE_C_FLAGS_RELEASE "-O2")
-
-FIND_PROGRAM(UNAME NAMES uname)
-EXEC_PROGRAM("${UNAME}" ARGS "-m" OUTPUT_VARIABLE "ARCH")
-IF("${ARCH}" STREQUAL "arm")
- ADD_DEFINITIONS("-DTARGET")
- MESSAGE("add -DTARGET")
-ENDIF("${ARCH}" STREQUAL "arm")
+SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${EXTRA_CFLAGS} -O2 -g -Wall")
-ADD_DEFINITIONS("-DPREFIX=\"${CMAKE_INSTALL_PREFIX}\"")
-ADD_DEFINITIONS("-DSLP_DEBUG")
+ADD_DEFINITIONS("-DLOCALEDIR=\"${LOCALEDIR}\"")
+ADD_DEFINITIONS("-DPACKAGE=\"${PACKAGE}\"")
SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed")
-ADD_EXECUTABLE(${PROJECT_NAME} ${SRCS})
-TARGET_LINK_LIBRARIES(${PROJECT_NAME} ${pkgs_LDFLAGS})
-
-ADD_CUSTOM_TARGET(usbotg.edj
- COMMAND edje_cc -id ${CMAKE_SOURCE_DIR}/../images
- ${CMAKE_SOURCE_DIR}/edcs/usbotg.edc ${CMAKE_BINARY_DIR}/${PROJECT_NAME}/usbotg.edj
- DEPENDS ${CMAKE_SOURCE_DIR}/edcs/usbotg.edc
-)
-ADD_DEPENDENCIES(${PROJECT_NAME} usbotg.edj)
-
-INSTALL(TARGETS ${PROJECT_NAME} DESTINATION /usr/apps/org.tizen.usbotg-syspopup/bin)
-INSTALL(FILES ${CMAKE_BINARY_DIR}/${PROJECT_NAME}/usbotg.edj DESTINATION /usr/apps/org.tizen.usbotg-syspopup/res/edje/usbotg)
-
-# install desktop file & icon
-SET(PREFIX ${CMAKE_INSTALL_PREFIX})
-INSTALL(FILES ${CMAKE_SOURCE_DIR}/data/org.tizen.usbotg-syspopup.png DESTINATION /usr/apps/org.tizen.usbotg-syspopup/res/icon)
-INSTALL(FILES ${CMAKE_SOURCE_DIR}/sound/02_Warning.wav DESTINATION /usr/apps/org.tizen.usbotg-syspopup/res/keysound)
-INSTALL(FILES ${CMAKE_SOURCE_DIR}/data/usb_icon.png DESTINATION /usr/apps/org.tizen.usbotg-syspopup/res/icons/)
+ADD_EXECUTABLE(${PACKAGE} ${SRCS})
+TARGET_LINK_LIBRARIES(${PACKAGE} syspopup ${pkgs_LDFLAGS})
+INSTALL(TARGETS ${PACKAGE} DESTINATION ${BINDIR})
# install manifest xml file
-INSTALL(FILES ${CMAKE_SOURCE_DIR}/data/org.tizen.usbotg-syspopup.xml DESTINATION /usr/share/packages/)
-
-# install ini file
-INSTALL(FILES ${CMAKE_SOURCE_DIR}/data/${PROJECT_NAME}.ini DESTINATION /usr/share/process-info)
-
-# i18n
-ADD_SUBDIRECTORY(po_usbotg)
-
-################################# End ##############################################
+INSTALL(FILES ${CMAKE_SOURCE_DIR}/data/${PKGNAME}.xml DESTINATION ${MANIFESTDIR})
+++ /dev/null
-# for i18n
-
-SET(POFILES ar.po el_GR.po es_ES.po fi.po gl.po hy.po ka.po lv.po pl.po ru_RU.po sv.po zh_CN.po az.po cs.po en_PH.po es_US.po fr_CA.po hi.po is.po kk.po mk.po pt_BR.po sk.po tr_TR.po zh_HK.po bg.po da.po en.po et.po fr_FR.po hr.po it_IT.po ko_KR.po nb.po pt_PT.po sl.po uk.po zh_SG.po ca.po de_DE.po en_US.po eu.po ga.po hu.po ja_JP.po lt.po nl_NL.po ro.po sr.po uz.po zh_TW.po)
-
-SET(MSGFMT "/usr/bin/msgfmt")
-
-FOREACH(pofile ${POFILES})
- SET(pofile ${CMAKE_CURRENT_SOURCE_DIR}/${pofile})
- MESSAGE("PO: ${pofile}")
- GET_FILENAME_COMPONENT(absPofile ${pofile} ABSOLUTE)
- GET_FILENAME_COMPONENT(lang ${absPofile} NAME_WE)
- SET(moFile ${CMAKE_CURRENT_BINARY_DIR}/${lang}.mo)
- ADD_CUSTOM_COMMAND(
- OUTPUT ${moFile}
- COMMAND ${MSGFMT} -o ${moFile} ${absPofile}
- DEPENDS ${absPofile}
- )
- INSTALL(FILES ${moFile}
- DESTINATION /usr/apps/org.tizen.usbotg-syspopup/res/locale/${lang}/LC_MESSAGES RENAME ${PROJECT_NAME}.mo)
- SET(moFiles ${moFiles} ${moFile})
-ENDFOREACH(pofile)
-
-MESSAGE(".mo files: ${moFiles}")
-ADD_CUSTOM_TARGET(po_usbotg ALL DEPENDS ${moFiles})
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "معلومات النظام"
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "الذاكرة لا تكفي"
-
-msgid "IDS_COM_SK_OK"
-msgstr "موافق"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "حجم الذاكرة منخفض"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s مغلق"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Sistm mlmtı"
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Yaddaş kifayət etmir"
-
-msgid "IDS_COM_SK_OK"
-msgstr "OK"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Batareya azdır"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s bağlanmışdır"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Сист. инф."
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Няма достатъчно памет"
-
-msgid "IDS_COM_SK_OK"
-msgstr "OK"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Паметта е на привършване"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s затворен"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Info sist"
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "No hi ha prou memòria"
-
-msgid "IDS_COM_SK_OK"
-msgstr "Acceptar"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Poca memòria"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s tancat"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Syst. info"
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Nedostatek paměti"
-
-msgid "IDS_COM_SK_OK"
-msgstr "OK"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Nedostatek paměti"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s byl uzavřen"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Systeminfo"
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Ikke nok hukommelse"
-
-msgid "IDS_COM_SK_OK"
-msgstr "OK"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Lav hukommelse"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s blev lukket"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Systeminfo"
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Speicher voll"
-
-msgid "IDS_COM_SK_OK"
-msgstr "OK"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Wenig Speicher übrig"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s geschlossen"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Πληρ. Συστήμ."
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Ανεπαρκής μνήμη"
-
-msgid "IDS_COM_SK_OK"
-msgstr "OK"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Ανεπαρκής μνήμη"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s έκλεισε"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "System info"
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Not enough memory"
-
-msgid "IDS_COM_SK_OK"
-msgstr "OK"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Low memory"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s closed"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "System info"
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Not enough memory"
-
-msgid "IDS_COM_SK_OK"
-msgstr "OK"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Low memory"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s closed"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "System info"
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Not enough memory"
-
-msgid "IDS_COM_SK_OK"
-msgstr "OK"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Low memory"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s closed"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Información del sistema"
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "No hay suficiente memoria"
-
-msgid "IDS_COM_SK_OK"
-msgstr "Aceptar"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Memoria baja"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s cerrado"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Inf. sistem."
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Memoria insuficiente"
-
-msgid "IDS_COM_SK_OK"
-msgstr "Aceptar"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Memoria baja"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s cerrado"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Süst.teave"
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Mälu pole piisavalt"
-
-msgid "IDS_COM_SK_OK"
-msgstr "OK"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Aku tühjeneb"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s suleti"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Sist. inf."
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Ez dago memoria nahikoa"
-
-msgid "IDS_COM_SK_OK"
-msgstr "Ados"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Memoria gutxi"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s itxita"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Järj.tied."
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Ei tarpeeksi muistia"
-
-msgid "IDS_COM_SK_OK"
-msgstr "OK"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Muisti vähissä"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s suljettu"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Infos syst."
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Mémoire insuffisante"
-
-msgid "IDS_COM_SK_OK"
-msgstr "OK"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Mémoire faible"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s fermé"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Infos système"
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Mémoire insuffisante"
-
-msgid "IDS_COM_SK_OK"
-msgstr "OK"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Mémoire faible"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s fermé"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Fais. Chórais"
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Easpa cuimhne"
-
-msgid "IDS_COM_SK_OK"
-msgstr "OK"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Cuimhne íseal"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s dúnta"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Info sist"
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Non hai suficiente memoria"
-
-msgid "IDS_COM_SK_OK"
-msgstr "Aceptar"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Memoria baixa"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s pechado"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "सिस्टम जानका."
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "पर्याप्त मेमोरी नहीं"
-
-msgid "IDS_COM_SK_OK"
-msgstr "ठीक"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "बैटरी कम है"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s बंद"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "O sustavu"
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Memorija nedovoljna"
-
-msgid "IDS_COM_SK_OK"
-msgstr "OK"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Malo memorije"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s zatvoren"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "R.szerinfó"
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Kevés a memória"
-
-msgid "IDS_COM_SK_OK"
-msgstr "OK"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Kevés a memória"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s lezárva"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Հմկրգ ինֆո"
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Չկա բավական հիշողություն"
-
-msgid "IDS_COM_SK_OK"
-msgstr "OK"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Մարտկոցի լիցքը թույլ է"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s փակվեց"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Kerfisuppl"
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Ekki er nægt minni"
-
-msgid "IDS_COM_SK_OK"
-msgstr "Í lagi"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Það er of lítið minni"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s var lokað"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Info sistema"
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Memoria insufficiente"
-
-msgid "IDS_COM_SK_OK"
-msgstr "OK"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Memoria insufficiente"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s chiuso"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "システム情報"
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "メモリが不足しています。"
-
-msgid "IDS_COM_SK_OK"
-msgstr "OK"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "メモリの容量不足です"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%sを終了しました"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "სისტემ.ინფო"
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "მეხსიერება არ არის საკმარისი"
-
-msgid "IDS_COM_SK_OK"
-msgstr "OK"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "კვების ელემენტი იცლება"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s დახურულია"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Жүйе. ақп."
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Жадында орын аз"
-
-msgid "IDS_COM_SK_OK"
-msgstr "OK"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Батарея заряды аз"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s жабық"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "시스템 정보"
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "메모리가 부족합니다"
-
-msgid "IDS_COM_SK_OK"
-msgstr "확인"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "메모리가 부족합니다"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s이(가) 종료되었습니다"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Sist. inform."
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Nepakanka atminties"
-
-msgid "IDS_COM_SK_OK"
-msgstr "Gerai"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Senkanti baterija"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s uždaryta"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Sist. inf."
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Atmiņa pilna"
-
-msgid "IDS_COM_SK_OK"
-msgstr "Labi"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Tukšs akumulators"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "Sadaļa %s ir aizvērta"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Сист.инфо."
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Нема доволно меморија"
-
-msgid "IDS_COM_SK_OK"
-msgstr "OK"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Има уште малку меморија"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s се затвори"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Systeminfo"
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Ikke nok minne"
-
-msgid "IDS_COM_SK_OK"
-msgstr "OK"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Lite minne"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s lukket"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Systeeminfo"
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Onvoldoende geheugen"
-
-msgid "IDS_COM_SK_OK"
-msgstr "OK"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Onvoldoende geheugen"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s afgesloten"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Info syst."
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Brak pamięci"
-
-msgid "IDS_COM_SK_OK"
-msgstr "OK"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Mało pamięci"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "Zamknięto %s"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Sistema"
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Memória insuficiente"
-
-msgid "IDS_COM_SK_OK"
-msgstr "OK"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Baixa memória"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s fechado"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Info. sist."
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Cartão SD cheio"
-
-msgid "IDS_COM_SK_OK"
-msgstr "OK"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Pouca memória"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s fechado"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Info. sis."
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Memorie plină"
-
-msgid "IDS_COM_SK_OK"
-msgstr "OK"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Memorie insuficientă"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s a fost închis"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Системная информация"
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Недостаточно памяти"
-
-msgid "IDS_COM_SK_OK"
-msgstr "Да"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Аккумулятор разряжен"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s закрыт"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Syst. inf."
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Nedostatok pamäte"
-
-msgid "IDS_COM_SK_OK"
-msgstr "OK"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Nedostatok pamäte"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s zatvorené"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Sist. info"
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Ni dovolj pomnilnika"
-
-msgid "IDS_COM_SK_OK"
-msgstr "V redu"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Zmanjkuje pomnilnika"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s zaprto"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Info.sist."
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Nedovoljna memorija"
-
-msgid "IDS_COM_SK_OK"
-msgstr "OK"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Memorija pri kraju"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s zatvoreno"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Systeminfo"
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Minnet fullt"
-
-msgid "IDS_COM_SK_OK"
-msgstr "OK"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Ont om minnesplats"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s har stängts"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Sistem bilgi."
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Yeterli hafıza yok"
-
-msgid "IDS_COM_SK_OK"
-msgstr "Tamam"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Düşük hafıza"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s kapatıldı"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Сист. інф."
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Недостатньо пам'яті"
-
-msgid "IDS_COM_SK_OK"
-msgstr "ОК"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Батарея розряджена"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s закрито"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Tizim ma’l."
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Xotira yetarli emas"
-
-msgid "IDS_COM_SK_OK"
-msgstr "OK"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Bo‘sh xotira kam"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s yopildi"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "系统信息"
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "没有足够内存"
-
-msgid "IDS_COM_SK_OK"
-msgstr "确定"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "内存不足"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s 已关闭"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "系統資料"
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "記憶體不足"
-
-msgid "IDS_COM_SK_OK"
-msgstr "確定"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "記憶體不足"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s 已關閉"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "系统信息"
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "内存不足"
-
-msgid "IDS_COM_SK_OK"
-msgstr "确认"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "内存不足"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s 已关闭"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "系統訊息"
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "記憶體不足"
-
-msgid "IDS_COM_SK_OK"
-msgstr "確定"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "記憶體不足"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s 已關閉"
-
--- /dev/null
+/*
+ * usbotg-syspopup
+ * Copyright (c) 2012 Samsung Electronics Co., Ltd.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#include <stdio.h>
+#include <appcore-efl.h>
+#include <pmapi.h>
+#include <assert.h>
+#include "usbotg-syspopup.h"
+#include <Ecore_X.h>
+#include <appsvc.h>
+#include <syspopup.h>
+#include <vconf.h>
+
+#include <string.h>
+#include <sys/socket.h>
+#include <sys/un.h>
+
+#define SOCK_PATH "/tmp/usb_server_sock"
+#define SOCK_STR_LEN 1542
+#define UNMOUNT_USB_STORAGE 60
+
+#define USB_MOUNT_PATH "/opt/storage/usb"
+#define MYFILE_APP_NAME "org.tizen.myfile"
+#define GALLERY_APP_NAME "org.tizen.gallery"
+
+#define STORAGE_ADD "storage_add"
+#define STORAGE_REMOVE "storage_remove"
+#define STORAGE_UNMOUNT "storage_unmount"
+#define CAMERA_ADD "camera_add"
+#define CAMERA_REMOVE "camera_remove"
+
+static int ipc_socket_client_init()
+{
+ __USB_FUNC_ENTER__ ;
+ struct sockaddr_un remote;
+ int sockFd;
+
+ if ((sockFd = socket(AF_UNIX, SOCK_STREAM, 0)) == -1) {
+ USB_LOG("FAIL: socket(AF_UNIX, SOCK_STREAM, 0)");
+ return -1;;
+ }
+ remote.sun_family = AF_UNIX;
+ strncpy(remote.sun_path, SOCK_PATH, sizeof(remote.sun_family));
+ if (connect(sockFd, (struct sockaddr *)&remote, sizeof(remote)) == -1) {
+ USB_LOG("FAIL: connect()");
+ close(sockFd);
+ return -1;
+ }
+ __USB_FUNC_EXIT__ ;
+ return sockFd;
+}
+
+static int request_to_usb_server(int request, char *device, char *answer, int answerLen)
+{
+ __USB_FUNC_ENTER__ ;
+ assert(device);
+ assert(answer);
+ assert(answerLen > 0);
+
+ int sock_remote;
+ char str[SOCK_STR_LEN];
+ int t;
+ sock_remote = ipc_socket_client_init();
+ if (sock_remote < 0) {
+ USB_LOG("FAIL: ipc_socket_client_init()");
+ return -1;
+ }
+
+ snprintf(str, sizeof(str), "%d|%s", request, device);
+ USB_LOG("request: %s", str);
+ if (send (sock_remote, str, strlen(str)+1, 0) == -1) {
+ USB_LOG("FAIL: send (sock_remote, str, strlen(str), 0)");
+ close(sock_remote);
+ return -1;
+ }
+
+ if ((t = recv(sock_remote, answer, answerLen, 0)) > 0) {
+ if (t < answerLen) {
+ answer[t] = '\0';
+ } else { /* t == answerLen */
+ answer[answerLen - 1] = '\0';
+ }
+ USB_LOG("[CLIENT] Received value: %s", answer);
+ } else {
+ USB_LOG("FAIL: recv(sock_remote, answer, answerLen, 0)");
+ close(sock_remote);
+ return -1;
+ }
+
+ close(sock_remote);
+ __USB_FUNC_EXIT__ ;
+ return 0;
+}
+
+/* App Life cycle funtions */
+static void win_del(void *data, Evas_Object *obj, void *event)
+{
+ elm_exit();
+}
+
+static void uosp_free_evas_object(Evas_Object **eo)
+{
+ __USB_FUNC_ENTER__;
+ assert(eo);
+ if (!(*eo)) return;
+ evas_object_del(*eo);
+ *eo = NULL;
+ __USB_FUNC_EXIT__;
+}
+
+static void unload_window(struct appdata *ad)
+{
+ __USB_FUNC_ENTER__;
+ assert(ad);
+ if (ad->storage_added_popup || ad->storage_unmount_popup || ad->camera_added_popup) {
+ USB_LOG("More than one popup is loaded");
+ return;
+ }
+
+ USB_LOG("unload window");
+ uosp_free_evas_object(&(ad->win_main));
+ elm_exit();
+
+ __USB_FUNC_EXIT__;
+}
+
+/* Create main window */
+static Evas_Object *create_win(const char *name)
+{
+ __USB_FUNC_ENTER__;
+ Evas_Object *eo;
+ int w, h;
+
+ eo = elm_win_add(NULL, name, ELM_WIN_DIALOG_BASIC);
+ if (eo) {
+ elm_win_title_set(eo, name);
+ elm_win_borderless_set(eo, EINA_TRUE);
+ evas_object_smart_callback_add(eo, "delete,request", win_del, NULL);
+ elm_win_alpha_set(eo, EINA_TRUE);
+ ecore_x_window_size_get(ecore_x_window_root_first_get(), &w, &h);
+ evas_object_resize(eo, w, h);
+ }
+
+ __USB_FUNC_EXIT__;
+ return eo;
+}
+
+static void uosp_usbhost_chgdet_cb(keynode_t *keynode, void *data)
+{
+ __USB_FUNC_ENTER__ ;
+ assert(keynode);
+ assert(data);
+ struct appdata *ad = (struct appdata *)data;
+ int usb_status;
+
+ usb_status = vconf_keynode_get_int(keynode);
+ if (usb_status == VCONFKEY_SYSMAN_USB_HOST_DISCONNECTED) {
+ USB_LOG("USB host is not connected");
+ unload_window(ad);
+ }
+ __USB_FUNC_EXIT__ ;
+}
+
+/* App init */
+static int app_create(void *data)
+{
+ __USB_FUNC_ENTER__;
+ struct appdata *ad = (struct appdata *)data;
+ int ret;
+
+ ret = vconf_notify_key_changed(VCONFKEY_SYSMAN_USB_HOST_STATUS,
+ uosp_usbhost_chgdet_cb, ad);
+ if (0 != ret) {
+ USB_LOG("FAIL: vconf_notify_key_changed()");
+ return -1;
+ }
+
+ /* init internationalization */
+ if (0 != appcore_set_i18n(PACKAGE, LOCALEDIR)) {
+ USB_LOG("FAIL: appcore_set_i18n(PACKAGE, LOCALEDIR)\n");
+ return -1;
+ }
+
+ __USB_FUNC_EXIT__;
+ return 0;
+
+}
+
+/* Terminate noti handler */
+static int app_terminate(void *data)
+{
+ __USB_FUNC_ENTER__;
+ struct appdata *ad = data;
+ int ret;
+
+ ret = vconf_ignore_key_changed(VCONFKEY_SYSMAN_USB_HOST_STATUS, uosp_usbhost_chgdet_cb);
+ if (0 != ret) USB_LOG("FAIL: vconf_ignore_key_changed()");
+
+ uosp_free_evas_object(&(ad->storage_added_popup));
+ uosp_free_evas_object(&(ad->storage_unmount_popup));
+ uosp_free_evas_object(&(ad->camera_added_popup));
+ FREE(ad->storage_added_path);
+ FREE(ad->storage_unmount_path);
+
+ __USB_FUNC_EXIT__;
+ return 0;
+}
+
+/* Pause/background */
+static int app_pause(void *data)
+{
+ return 0;
+}
+
+/* Resume */
+static int app_resume(void *data)
+{
+ return 0;
+}
+
+static void storage_browse_clicked_cb(void *data, Evas_Object * obj, void *event_info)
+{
+ __USB_FUNC_ENTER__;
+ assert(data);
+
+ struct appdata *ad = (struct appdata *)data;
+ int ret;
+ bundle *b;
+
+ uosp_free_evas_object(&(ad->storage_added_popup));
+
+ b = bundle_create();
+ appsvc_set_operation(b, APPSVC_OPERATION_VIEW);
+ if (ad->storage_added_path) {
+ appsvc_add_data(b, "path", ad->storage_added_path);
+ } else {
+ appsvc_add_data(b, "path", USB_MOUNT_PATH);
+ }
+ appsvc_set_pkgname(b, MYFILE_APP_NAME);
+ ret = appsvc_run_service(b, 0, NULL, (void*)NULL);
+ if (ret < 0)
+ USB_LOG("app launching fail(%d)", ret);
+ bundle_free(b);
+
+ FREE(ad->storage_added_path);
+ unload_window(ad);
+
+ __USB_FUNC_EXIT__;
+}
+
+static void storage_unmount_clicked_cb(void *data, Evas_Object * obj, void *event_info)
+{
+ __USB_FUNC_ENTER__;
+ assert(data);
+
+ struct appdata *ad = (struct appdata *)data;
+ int ret;
+ char buf[SOCK_STR_LEN];
+
+ uosp_free_evas_object(&(ad->storage_unmount_popup));
+
+ ret = request_to_usb_server(UNMOUNT_USB_STORAGE, ad->storage_unmount_path, buf, sizeof(buf));
+ if (ret < 0) {
+ USB_LOG("FAIL: request_to_usb_server()");
+ }
+ USB_LOG("buf: %s", buf);
+
+ FREE(ad->storage_unmount_path);
+ unload_window(ad);
+
+ __USB_FUNC_EXIT__;
+}
+
+static void camera_browse_clicked_cb(void *data, Evas_Object * obj, void *event_info)
+{
+ __USB_FUNC_ENTER__;
+ assert(data);
+
+ struct appdata *ad = (struct appdata *)data;
+ bundle *b;
+ int ret;
+
+ uosp_free_evas_object(&(ad->camera_added_popup));
+
+ b = bundle_create();
+ appsvc_set_operation(b, APPSVC_OPERATION_VIEW);
+ appsvc_add_data(b, "album-id", "GALLERY_ALBUM_PTP_ID");
+ appsvc_set_pkgname(b, GALLERY_APP_NAME);
+ ret = appsvc_run_service(b, 0, NULL, (void*)NULL);
+ if (ret < 0)
+ USB_LOG("app launching fail(%d)", ret);
+ bundle_free(b);
+
+ unload_window(ad);
+
+ __USB_FUNC_EXIT__;
+}
+
+static void storage_browse_cancel_clicked_cb(void *data, Evas_Object * obj, void *event_info)
+{
+ __USB_FUNC_ENTER__;
+ assert(data);
+ struct appdata *ad = (struct appdata *)data;
+
+ uosp_free_evas_object(&(ad->storage_added_popup));
+ FREE(ad->storage_added_path);
+ unload_window(ad);
+
+ __USB_FUNC_EXIT__;
+}
+
+static void storage_unmount_cancel_clicked_cb(void *data, Evas_Object * obj, void *event_info)
+{
+ __USB_FUNC_ENTER__;
+ assert(data);
+ struct appdata *ad = (struct appdata *)data;
+
+ uosp_free_evas_object(&(ad->storage_unmount_popup));
+ FREE(ad->storage_unmount_path);
+ unload_window(ad);
+
+ __USB_FUNC_EXIT__;
+}
+
+static void camera_browse_cancel_clicked_cb(void *data, Evas_Object * obj, void *event_info)
+{
+ __USB_FUNC_ENTER__;
+ assert(data);
+ struct appdata *ad = (struct appdata *)data;
+
+ uosp_free_evas_object(&(ad->camera_added_popup));
+ unload_window(ad);
+
+ __USB_FUNC_EXIT__;
+}
+
+static int load_usbotg_popup(struct appdata *ad,
+ bundle *b,
+ Evas_Object **popup,
+ char *mainText,
+ char *lbtnText,
+ Evas_Smart_Cb lbtn_cb,
+ char *rbtnText,
+ Evas_Smart_Cb rbtn_cb)
+{
+ __USB_FUNC_ENTER__;
+ assert(ad && b && popup && mainText && lbtnText && lbtn_cb && rbtnText && rbtn_cb);
+
+ Evas_Object *btn1;
+ Evas_Object *btn2;
+ Evas_Object *win;
+ syspopup_handler handler = {
+ .def_term_fn = NULL,
+ .def_timeout_fn = NULL
+ };
+
+ /* create window */
+ if (!(ad->win_main)) {
+ win = create_win(PACKAGE);
+ if (win == NULL) {
+ USB_LOG("FAIL: create_win()");
+ return -1;
+ }
+ ad->win_main = win;
+ if (syspopup_create(b, &handler, ad->win_main, ad) != 0) {
+ USB_LOG("FAIL: syspopup_create()");
+ return -1;
+ }
+ }
+
+ evas_object_show(ad->win_main);
+
+ *popup = elm_popup_add(ad->win_main);
+ evas_object_size_hint_weight_set(*popup, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
+ elm_object_text_set(*popup, mainText);
+
+ btn1 = elm_button_add(*popup);
+ elm_object_text_set(btn1, lbtnText);
+ elm_object_part_content_set(*popup, "button1", btn1);
+ evas_object_smart_callback_add(btn1, "clicked", lbtn_cb, ad);
+
+ btn2 = elm_button_add(*popup);
+ elm_object_text_set(btn2, rbtnText);
+ elm_object_part_content_set(*popup, "button2", btn2);
+ evas_object_smart_callback_add(btn2, "clicked", rbtn_cb, ad);
+
+ evas_object_show(*popup);
+
+ __USB_FUNC_EXIT__;
+ return 0;
+}
+
+static void load_storage_added_popup(struct appdata *ad, bundle *b)
+{
+ __USB_FUNC_ENTER__;
+ assert(ad);
+ assert(b);
+ int ret;
+ char *path;
+
+ uosp_free_evas_object(&(ad->storage_added_popup));
+ FREE(ad->storage_added_path);
+
+ path = (char *)(bundle_get_val(b, "DEVICE_PATH"));
+ if (!path) return;
+ USB_LOG("storage_added_path: %s", path);
+
+ ret = load_usbotg_popup(ad, b, &(ad->storage_added_popup),
+ "Browse storage connected via USB?",
+ "Browse", storage_browse_clicked_cb,
+ "Cancel", storage_browse_cancel_clicked_cb);
+ if (ret < 0) {
+ USB_LOG("FAIL: load_usbotg_popup(storage_added)");
+ unload_window(ad);
+ return;
+ }
+
+ ad->storage_added_path = strdup(path);
+
+ __USB_FUNC_EXIT__;
+}
+
+static void load_storage_unmount_popup(struct appdata *ad, bundle *b)
+{
+ __USB_FUNC_ENTER__;
+ assert(ad);
+ assert(b);
+ int ret;
+ char *path;
+
+ uosp_free_evas_object(&(ad->storage_unmount_popup));
+ FREE(ad->storage_unmount_path);
+
+ path = (char *)(bundle_get_val(b, "DEVICE_PATH"));
+ if (!path) return;
+ USB_LOG("unmount_path: %s", path);
+
+ /* If unmount path is same as storage_added_path, unload storage_added_popup */
+ if (ad->storage_added_path
+ && !strncmp(path, ad->storage_added_path, strlen(ad->storage_added_path))) {
+ uosp_free_evas_object(&(ad->storage_added_popup));
+ FREE(ad->storage_added_path);
+ }
+
+ ret = load_usbotg_popup(ad, b, &(ad->storage_unmount_popup),
+ "Unmount USB mass storage before removing to avoid data loss",
+ "Unmount", storage_unmount_clicked_cb,
+ "Cancel", storage_unmount_cancel_clicked_cb);
+ if (ret < 0) {
+ USB_LOG("FAIL: load_usbotg_popup(storage_unmount)");
+ unload_window(ad);
+ }
+
+ ad->storage_unmount_path = strdup(path);
+
+ __USB_FUNC_EXIT__;
+}
+
+static void load_camera_added_popup(struct appdata *ad, bundle *b)
+{
+ __USB_FUNC_ENTER__;
+ assert(ad);
+ assert(b);
+ int ret;
+
+ uosp_free_evas_object(&(ad->camera_added_popup));
+
+ ret = load_usbotg_popup(ad, b, &(ad->camera_added_popup),
+ "Browse camera connected via USB?",
+ "Browse", camera_browse_clicked_cb,
+ "Cancel", camera_browse_cancel_clicked_cb);
+ if (ret < 0) {
+ USB_LOG("FAIL: load_usbotg_popup(storage_unmount)");
+ unload_window(ad);
+ }
+
+ __USB_FUNC_EXIT__;
+}
+
+static void unload_storage_added_unmount_popup(struct appdata *ad, bundle *b)
+{
+ __USB_FUNC_ENTER__;
+ assert(ad);
+ assert(b);
+ char *path;
+
+ path = (char *)(bundle_get_val(b, "DEVICE_PATH"));
+ USB_LOG("removed_path: %s", path);
+ if (!path) return;
+
+ if (NULL == ad->storage_added_path
+ || !strncmp(path, ad->storage_added_path, strlen(ad->storage_added_path))) {
+ uosp_free_evas_object(&(ad->storage_added_popup));
+ FREE(ad->storage_added_path);
+ }
+
+ if (NULL == ad->storage_unmount_path
+ || !strncmp(path, ad->storage_unmount_path, strlen(ad->storage_unmount_path))) {
+ uosp_free_evas_object(&(ad->storage_unmount_popup));
+ FREE(ad->storage_unmount_path);
+ }
+
+ unload_window(ad);
+
+ __USB_FUNC_EXIT__;
+}
+
+/* Reset */
+static int app_reset(bundle *b, void *data)
+{
+ __USB_FUNC_ENTER__;
+ assert(data);
+ assert(b);
+
+ struct appdata *ad = (struct appdata *)data;
+ const char *opt = bundle_get_val(b, "POPUP_TYPE");
+ if (!opt) {
+ USB_LOG("FAIL: bundle_get_val()");
+ unload_window(ad);
+ return 0;
+ }
+
+ if (syspopup_has_popup(b)) {
+ USB_LOG("usbotg-syspopup is already loaded");
+ syspopup_reset(b);
+ }
+
+ if (pm_change_state(LCD_NORMAL) != 0) return -1;
+
+ if (!strcmp(opt, STORAGE_ADD)) {
+ load_storage_added_popup(ad, b);
+ __USB_FUNC_EXIT__;
+ return 0;
+ }
+
+ if (!strcmp(opt, STORAGE_REMOVE)) {
+ unload_storage_added_unmount_popup(ad, b);
+ __USB_FUNC_EXIT__;
+ return 0;
+ }
+
+ if (!strcmp(opt, STORAGE_UNMOUNT)) {
+ load_storage_unmount_popup(ad, b);
+ __USB_FUNC_EXIT__;
+ return 0;
+ }
+
+ if (!strcmp(opt, CAMERA_ADD)) {
+ load_camera_added_popup(ad, b);
+ __USB_FUNC_EXIT__;
+ return 0;
+ }
+
+ if (!strcmp(opt, CAMERA_REMOVE)) {
+ uosp_free_evas_object(&(ad->camera_added_popup));
+ unload_window(ad);
+ __USB_FUNC_EXIT__;
+ return 0;
+ }
+
+ USB_LOG("FAIL: popup type is %s", opt);
+ __USB_FUNC_EXIT__;
+ return -1;
+}
+
+int main(int argc, char *argv[])
+{
+ __USB_FUNC_ENTER__;
+ struct appdata ad;
+
+ /* App life cycle management */
+ struct appcore_ops ops = {
+ .create = app_create,
+ .terminate = app_terminate,
+ .pause = app_pause,
+ .resume = app_resume,
+ .reset = app_reset,
+ };
+
+ memset(&ad, 0x0, sizeof(struct appdata));
+ ops.data = &ad;
+
+ __USB_FUNC_EXIT__;
+ return appcore_efl_main(PACKAGE, &argc, &argv, &ops);
+}
--- /dev/null
+/*
+ * usbotg-syspopup
+ * Copyright (c) 2012 Samsung Electronics Co., Ltd.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#ifndef __USBOTG_SYSPOPUP_H___
+#define __USBOTG_SYSPOPUP_H__
+
+#include <Elementary.h>
+#include <dlog.h>
+#undef LOG_TAG
+#define LOG_TAG "USBOTG_SYSPOPUP"
+#define USB_LOG(fmt, args...) SLOGD(fmt, ##args)
+#define __USB_FUNC_ENTER__ USB_LOG("ENTER")
+#define __USB_FUNC_EXIT__ USB_LOG("EXIT")
+
+#define FREE(arg) \
+ do { \
+ if(arg) { \
+ free((void *)arg); \
+ arg = NULL; \
+ } \
+ } while (0);
+
+typedef enum {
+ POPUP_NONE = 0x0,
+ STORAGE_ADDED_POPUP = 0x1,
+ STORAGE_UNMOUNT_POPUP = 0x4,
+ CAMERA_ADDED_POPUP = 0x8
+} USBOTG_SYSPOPUP_TYPE;
+
+typedef enum {
+ STORAGE_ADDED_PATH = 0x1,
+ STORAGE_REMOVED_PATH = 0x2,
+ STORAGE_UNMOUNT_PATH = 0x4
+} USBOTG_STORAGE_PATH;
+
+struct appdata {
+ Evas_Object *win_main;
+ Evas_Object *storage_added_popup;
+ Evas_Object *storage_unmount_popup;
+ Evas_Object *camera_added_popup;
+
+ char *storage_added_path;
+ char *storage_unmount_path;
+};
+
+#endif /* __USBOTG_SYSPOPUP_H__ */
+++ /dev/null
-/*
- * Copyright (c) 2012 Samsung Electronics Co., Ltd.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-
-
-#include <stdio.h>
-#include <appcore-efl.h>
-#include <sensor.h>
-#include <devman_haptic.h>
-#include <mmf/mm_sound.h>
-#include <pmapi.h>
-#include <sysman.h>
-#include "usbotg.h"
-#include <Ecore_X.h>
-#include <utilX.h>
-#include <notification.h>
-#include <syspopup_caller.h>
-#include <appsvc.h>
-
-#define APPLICATION_BG 1
-#define INDICATOR_HEIGHT (38) /* the case of 480*800 */
-#define SOUND_PATH PREFIX"/apps/org.tizen.usborg-syspopup/res/keysound/02_Warning.wav"
-#define NEW_INDI
-
-#define DEVICE_ADDED 1
-#define DEVICE_REMOVED 0
-
-#define UNKNOWN_USB_ICON_PATH PREFIX"/apps/org.tizen.usbotg-syspopup/res/icons/usb_icon.png"
-#define USB_ICON_PATH PREFIX"/apps/org.tizen.usbotg-syspopup/res/icons/usb_icon.png"
-
-#define ACCT_PROF
-#ifdef ACCT_PROF
-#include <sys/acct.h>
-#endif /* ACCT_PROF */
-
-#include <syspopup.h>
-
-#define USB_MOUNT_PATH "/opt/storage/usb"
-
-#define GALLERY_APP_NAME "org.tizen.gallery"
-#define MYFILE_APP_NAME "org.tizen.myfile"
-#define CAMERA_DEVICE 1
-
-static int connected_device = 0;
-static char *otg_path = NULL;
-
-int unknown_usb_noti(int option);
-int camera_noti(int option, char* device_name);
-
-int myterm(bundle *b, void *data)
-{
- return 0;
-}
-
-int mytimeout(bundle *b, void *data)
-{
- return 0;
-}
-
-syspopup_handler handler = {
- .def_term_fn = myterm,
- .def_timeout_fn = mytimeout
-};
-
-struct text_part {
- char *part;
- char *msgid;
-};
-
-static struct text_part main_txt[] = {
- {"txt_title", N_("USB otg popup"),},
- {"txt_mesg", N_(""),},
-};
-
-
-/* App Life cycle funtions */
-static void win_del(void *data, Evas_Object *obj, void *event)
-{
- elm_exit();
-}
-
-/* Quit */
-static void main_quit_cb(void *data, Evas_Object *obj, const char *emission,
- const char *source)
-{
- elm_exit();
-}
-
-/* Update text font */
-static void update_ts(Evas_Object *eo, struct text_part *tp, int size)
-{
- int i;
-
- if (eo == NULL || tp == NULL || size < 0)
- return;
-
- for (i = 0; i < size; i++) {
- if (tp[i].part && tp[i].msgid)
- edje_object_part_text_set(eo, tp[i].part,
- _(tp[i].msgid));
- }
-}
-
-/* Language changed noti handler */
-static int lang_changed(void *data)
-{
- struct appdata *ad = data;
-
- if (ad->layout_main == NULL)
- return 0;
-
- update_ts(elm_layout_edje_get(ad->layout_main), main_txt,
- sizeof(main_txt) / sizeof(main_txt[0]));
- return 0;
-}
-
-/* Create main window */
-static Evas_Object *create_win(const char *name)
-{
- Evas_Object *eo;
- int w, h;
-
- eo = elm_win_add(NULL, name, ELM_WIN_DIALOG_BASIC);
- if (eo) {
- elm_win_title_set(eo, name);
- elm_win_borderless_set(eo, EINA_TRUE);
- evas_object_smart_callback_add(eo, "delete,request", win_del, NULL);
- elm_win_alpha_set(eo, EINA_TRUE);
- ecore_x_window_size_get(ecore_x_window_root_first_get(), &w,
- &h);
- evas_object_resize(eo, w, h);
- }
-
- return eo;
-}
-
-/* Read from EDJ file */
-static Evas_Object *load_edj(Evas_Object * parent, const char *file,
- const char *group)
-{
- Evas_Object *eo;
- int r;
-
- eo = elm_layout_add(parent);
- if (eo) {
- r = elm_layout_file_set(eo, file, group);
- if (!r) {
- evas_object_del(eo);
- return NULL;
- }
-
- evas_object_size_hint_weight_set(eo, EVAS_HINT_EXPAND,
- EVAS_HINT_EXPAND);
- }
-
- return eo;
-}
-
-/* Terminate noti handler */
-static int app_terminate(void *data)
-{
- struct appdata *ad = data;
-
- if (ad->layout_main)
- evas_object_del(ad->layout_main);
-
- if (ad->win_main)
- evas_object_del(ad->win_main);
-
- return 0;
-}
-
-/* Pause/background */
-static int app_pause(void *data)
-{
- return 0;
-}
-
-/* Resume */
-static int app_resume(void *data)
-{
- return 0;
-}
-
-
-/* Reset */
-static int app_reset(bundle *b, void *data)
-{
- struct appdata *ad = data;
- int removenoti = -1;
- char *opt = NULL;
-
- opt = bundle_get_val(b, "_SYSPOPUP_CONTENT_");
- if (!strcmp(opt,"unknown_add")) {
- unknown_usb_noti(DEVICE_ADDED);
- } else if (!strcmp(opt,"unknown_remove")) {
- unknown_usb_noti(DEVICE_REMOVED);
- } else {
- if(!strcmp(opt,"camera_add")) {
- connected_device = CAMERA_DEVICE;
- camera_noti(DEVICE_ADDED, bundle_get_val(b, "device_name"));
- } else if (!strcmp(opt,"camera_remove")) {
- camera_noti(DEVICE_REMOVED, NULL);
- removenoti = DEVICE_REMOVED;
- } else if (!strcmp(opt,"otg_add")) {
- otg_path = bundle_get_val(b, "path");
- otg_noti(DEVICE_ADDED, (strrchr(otg_path, '/')+1));
- } else if (!strcmp(opt,"otg_remove")) {
- otg_noti(DEVICE_REMOVED, NULL);
- removenoti = DEVICE_REMOVED;
- }
-
- if (syspopup_has_popup(b)) {
- if (removenoti == DEVICE_REMOVED)
- return 0;
- syspopup_reset(b);
- } else {
- if (removenoti == DEVICE_REMOVED)
- exit(0);
- syspopup_create(b, &handler, ad->win_main, ad);
- evas_object_show(ad->win_main);
-
- /* Start Main UI */
- usbotg_start((void *)ad);
- }
- }
-
- return 0;
-}
-
-/* Customized print */
-void system_print(const char *format, ...)
-{
- /* Un-comment return to disable logs */
- //return;
-
- va_list args;
- va_start(args, format);
- vfprintf(stderr, format, args);
- va_end(args);
-}
-
-/* Cleanup objects to avoid mem-leak */
-void usbotg_cleanup(struct appdata *ad)
-{
- if (ad == NULL)
- return;
-
- if (ad->popup)
- evas_object_del(ad->popup);
- if (ad->layout_main)
- evas_object_del(ad->layout_main);
-}
-
-/* Background clicked noti */
-void bg_clicked_cb(void *data, Evas * e, Evas_Object * obj, void *event_info)
-{
- system_print("\n system-popup : In BG Noti \n");
- fflush(stdout);
- exit(0);
-}
-
-/* Browse clicked noti */
-void browse_clicked_cb(void *data, Evas * e, Evas_Object * obj, void *event_info)
-{
- system_print("\n system-popup : Bwose Noti \n");
-
- int ret;
- bundle *b;
- b = bundle_create();
-
- // TO DO
- // launch my files with option
- if (connected_device == CAMERA_DEVICE) {
- appsvc_set_operation(b, APPSVC_OPERATION_VIEW);
- appsvc_add_data(b, "album-id", "GALLERY_ALBUM_PTP_ID");
- appsvc_set_pkgname(b, GALLERY_APP_NAME);
- ret = appsvc_run_service(b, 0, NULL, (void*)NULL);
- } else {
- appsvc_set_operation(b, APPSVC_OPERATION_VIEW);
- if (otg_path != NULL) {
- appsvc_add_data(b, "path", otg_path);
- } else {
- appsvc_add_data(b, "path", USB_MOUNT_PATH);
- }
- appsvc_set_pkgname(b, MYFILE_APP_NAME);
- ret = appsvc_run_service(b, 0, NULL, (void*)NULL);
- }
- if (ret < 0)
- system_print("app launching fail(%d)", ret);
- bundle_free(b);
-
- fflush(stdout);
- exit(0);
-}
-
-void usbotg_clicked_cb(void *data, Evas * e, Evas_Object * obj,
- void *event_info)
-{
- system_print("\n system-popup : Screen clicked \n");
- fflush(stdout);
- elm_exit();
- exit(0);
-}
-
-/* Create indicator bar */
-int usbotg_create_indicator(struct appdata *ad)
-{
- elm_win_indicator_mode_set(ad->win_main, ELM_WIN_INDICATOR_HIDE);
- return 0;
-}
-
-/* Play vibration */
-int usbotg_play_vibration()
-{
- int ret_val = 0;
- int dev_handle = 0;
- int mode = 0;
-
- /* Open the haptic device */
- dev_handle = device_haptic_open(DEV_IDX_0, mode);
- if (dev_handle < 0)
- return -1;
-
- /* Play a monotone pattern for 1s */
- ret_val = device_haptic_play_monotone(dev_handle, 1000);
- device_haptic_close(dev_handle);
- if (ret_val < 0)
- return -1;
-
- return 0;
-}
-
-/* Basic popup widget */
-int usbotg_create_and_show_basic_popup(struct appdata *ad)
-{
- Evas_Object *btn1;
- Evas_Object *btn2;
-
- /* Initialization */
- int ret_val = 0;
-
- /* Add notify */
- /* No need to give main window, it will create internally */
- ad->popup = elm_popup_add(ad->win_main);
- evas_object_size_hint_weight_set(ad->popup, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
- elm_object_style_set(ad->popup, "transparent");
- if (connected_device == CAMERA_DEVICE)
- elm_object_text_set(ad->popup, "Browse connected CAMERA?");
- else
- elm_object_text_set(ad->popup, "Browse connected USB Storage?");
- elm_object_part_text_set(ad->popup, "title,text", _("IDS_COM_BODY_SYSTEM_INFO_ABB"));
-
- btn1 = elm_button_add(ad->popup);
- elm_object_text_set(btn1, "Browse");
- elm_object_part_content_set(ad->popup, "button1", btn1);
- elm_object_style_set(btn1, "popup_button/default");
- evas_object_smart_callback_add(btn1, "clicked", browse_clicked_cb, ad);
-
- btn2 = elm_button_add(ad->popup);
- elm_object_text_set(btn2, "Cancel");
- elm_object_part_content_set(ad->popup, "button2", btn2);
- elm_object_style_set(btn2, "popup_button/default");
- evas_object_smart_callback_add(btn2, "clicked", bg_clicked_cb, ad);
-
- Ecore_X_Window xwin;
- xwin = elm_win_xwindow_get(ad->popup);
- ecore_x_netwm_window_type_set(xwin, ECORE_X_WINDOW_TYPE_NOTIFICATION);
- evas_object_show(ad->popup);
-
- return 0;
-}
-
-int usbotg_start(void *data)
-{
- struct appdata *ad = data;
- int ret_val = 0;
-
- /* Create and show popup */
- ret_val = usbotg_create_and_show_basic_popup(ad);
- if (ret_val != 0)
- return -1;
-
- /* Change LCD brightness */
- ret_val = pm_change_state(LCD_NORMAL);
- if (ret_val != 0)
- return -1;
-
- /* Play vibration */
- ret_val = usbotg_play_vibration();
- if (ret_val == -1)
- system_print("\n Lowmem : Play vibration failed \n");
-
- return 0;
-}
-
-/* App init */
-int app_create(void *data)
-{
- Evas_Object *win;
- struct appdata *ad = data;
-
- /* create window */
- win = create_win(PACKAGE);
- if (win == NULL)
- return -1;
-
- ad->win_main = win;
-
- return 0;
-
-}
-
-int unknown_usb_noti(int option)
-{
- notification_h noti = NULL;
- notification_error_e noti_err = NOTIFICATION_ERROR_NONE;
-
- if (option == DEVICE_REMOVED) {
- notification_delete_all_by_type(NULL, NOTIFICATION_TYPE_NOTI);
- system_print("unknown usb device is removed\n");
- return -1;
- } else if (option == DEVICE_ADDED) {
- noti_err = notification_delete_all_by_type(NULL, NOTIFICATION_TYPE_NOTI);
- system_print("add notification for unknow usb device\n");
- noti = notification_new(NOTIFICATION_TYPE_NOTI, NOTIFICATION_GROUP_ID_NONE, NOTIFICATION_PRIV_ID_NONE);
- if (noti == NULL) {
- system_print("Errot noti == NULL\n");
- return -1;
- }
-
- noti_err = notification_set_text(noti, NOTIFICATION_TEXT_TYPE_TITLE, "Unknown USB device connected", NULL, NOTIFICATION_VARIABLE_TYPE_NONE);
- if (noti_err != NOTIFICATION_ERROR_NONE) {
- system_print("Error notification_set_title : %d\n", noti_err);
- goto UNKNOWN_USB_NOTI_FREE;
- }
-
- noti_err = notification_set_text(noti, NOTIFICATION_TEXT_TYPE_CONTENT_FOR_DISPLAY_OPTION_IS_OFF, "Unknown USB device connected", NULL, NOTIFICATION_VARIABLE_TYPE_NONE);
- if (noti_err != NOTIFICATION_ERROR_NONE) {
- system_print("Error notification_set_content : %d\n", noti_err);
- goto UNKNOWN_USB_NOTI_FREE;
- }
-
- noti_err = notification_set_image(noti, NOTIFICATION_IMAGE_TYPE_ICON, UNKNOWN_USB_ICON_PATH);
- if (noti_err != NOTIFICATION_ERROR_NONE) {
- system_print("Error notification_set_image : %d\n", noti_err);
- goto UNKNOWN_USB_NOTI_FREE;
- }
-
- noti_err = notification_set_property(noti, NOTIFICATION_PROP_DISABLE_APP_LAUNCH | NOTIFICATION_PROP_DISABLE_TICKERNOTI | NOTIFICATION_PROP_VOLATILE_DISPLAY);
- if (noti_err != NOTIFICATION_ERROR_NONE) {
- system_print("Error notification_set_property : %d\n", noti_err);
- goto UNKNOWN_USB_NOTI_FREE;
- }
-
- noti_err = notification_set_display_applist(noti, NOTIFICATION_DISPLAY_APP_NOTIFICATION_TRAY);
- if (noti_err != NOTIFICATION_ERROR_NONE) {
- system_print("Error notification_set_display_applist : %d\n", noti_err);
- goto UNKNOWN_USB_NOTI_FREE;
- }
-
- noti_err = notification_insert(noti, NULL);
- if (noti_err != NOTIFICATION_ERROR_NONE) {
- system_print("Error notification_insert : %d\n", noti_err);
- goto UNKNOWN_USB_NOTI_FREE;
- }
-
- noti_err = notification_free(noti);
- if (noti_err != NOTIFICATION_ERROR_NONE) {
- system_print("Error notification_free : %d\n", noti_err);
- return -1;
- }
-
- }
-
- return 0;
-
-UNKNOWN_USB_NOTI_FREE:
- noti_err = notification_free(noti);
- if (noti_err != NOTIFICATION_ERROR_NONE)
- system_print("Error notification_free : %d\n", noti_err);
- return -1;
-}
-
-int camera_noti(int option, char* device_name)
-{
- notification_h noti = NULL;
- notification_error_e noti_err = NOTIFICATION_ERROR_NONE;
-
- if (option == DEVICE_REMOVED) {
- notification_delete_all_by_type(NULL, NOTIFICATION_TYPE_ONGOING);
- system_print("camera removed\n");
- return -1;
- } else if (option == DEVICE_ADDED) {
- noti_err = notification_delete_all_by_type(NULL, NOTIFICATION_TYPE_ONGOING);
- system_print("add notification for camera\n");
- noti = notification_new(NOTIFICATION_TYPE_ONGOING, NOTIFICATION_GROUP_ID_NONE, NOTIFICATION_PRIV_ID_NONE);
- if (noti == NULL) {
- system_print("Errot noti == NULL\n");
- return -1;
- }
-
- noti_err = notification_set_text(noti, NOTIFICATION_TEXT_TYPE_TITLE, "Camera connected", NULL, NOTIFICATION_VARIABLE_TYPE_NONE);
- if (noti_err != NOTIFICATION_ERROR_NONE) {
- system_print("Error notification_set_title : %d\n", noti_err);
- goto CAMERA_NOTI_FREE;
- }
-
- noti_err = notification_set_text(noti, NOTIFICATION_TEXT_TYPE_CONTENT, device_name, NULL, NOTIFICATION_VARIABLE_TYPE_NONE);
- if (noti_err != NOTIFICATION_ERROR_NONE) {
- system_print("Error notification_set_contents : %d\n", noti_err);
- goto CAMERA_NOTI_FREE;
- }
-
- noti_err = notification_set_text(noti, NOTIFICATION_TEXT_TYPE_CONTENT_FOR_DISPLAY_OPTION_IS_OFF, "Camera connected", NULL, NOTIFICATION_VARIABLE_TYPE_NONE);
- if (noti_err != NOTIFICATION_ERROR_NONE) {
- system_print("Error notification_set_content : %d\n", noti_err);
- goto CAMERA_NOTI_FREE;
- }
-
- noti_err = notification_set_image(noti, NOTIFICATION_IMAGE_TYPE_ICON, USB_ICON_PATH);
- if (noti_err != NOTIFICATION_ERROR_NONE) {
- system_print("Error notification_set_image : %d\n", noti_err);
- goto CAMERA_NOTI_FREE;
- }
-
- noti_err = notification_set_property(noti, NOTIFICATION_PROP_DISABLE_APP_LAUNCH | NOTIFICATION_PROP_DISABLE_TICKERNOTI | NOTIFICATION_PROP_VOLATILE_DISPLAY);
- if (noti_err != NOTIFICATION_ERROR_NONE) {
- system_print("Error notification_set_property : %d\n", noti_err);
- goto CAMERA_NOTI_FREE;
- }
-
- noti_err = notification_set_display_applist(noti, NOTIFICATION_DISPLAY_APP_NOTIFICATION_TRAY);
- if (noti_err != NOTIFICATION_ERROR_NONE) {
- system_print("Error notification_set_display_applist : %d\n", noti_err);
- goto CAMERA_NOTI_FREE;
- }
-
- noti_err = notification_insert(noti, NULL);
- if (noti_err != NOTIFICATION_ERROR_NONE) {
- system_print("Error notification_insert : %d\n", noti_err);
- goto CAMERA_NOTI_FREE;
- }
-
- noti_err = notification_free(noti);
- if (noti_err != NOTIFICATION_ERROR_NONE) {
- system_print("Error notification_free : %d\n", noti_err);
- return -1;
- }
- }
-
- return 0;
-
-CAMERA_NOTI_FREE:
- noti_err = notification_free(noti);
- if (noti_err != NOTIFICATION_ERROR_NONE)
- system_print("Error notification_free : %d\n", noti_err);
- return -1;
-}
-
-int otg_noti(int option, char* device_name)
-{
- notification_h noti = NULL;
- notification_error_e noti_err = NOTIFICATION_ERROR_NONE;
-
- if (option == DEVICE_REMOVED) {
- notification_delete_all_by_type(NULL, NOTIFICATION_TYPE_ONGOING);
- system_print("usb otg removed\n");
- return -1;
- } else if (option == DEVICE_ADDED) {
- noti_err = notification_delete_all_by_type(NULL, NOTIFICATION_TYPE_ONGOING);
- system_print("add notification for usb otg\n");
- noti = notification_new(NOTIFICATION_TYPE_ONGOING, NOTIFICATION_GROUP_ID_NONE, NOTIFICATION_PRIV_ID_NONE);
- if (noti == NULL) {
- system_print("Errot noti == NULL\n");
- return -1;
- }
-
- noti_err = notification_set_text(noti, NOTIFICATION_TEXT_TYPE_TITLE, "USB mass storage connected", NULL, NOTIFICATION_VARIABLE_TYPE_NONE);
- if (noti_err != NOTIFICATION_ERROR_NONE) {
- system_print("Error notification_set_title : %d\n", noti_err);
- goto OTG_NOTI_FREE;
- }
-
- noti_err = notification_set_text(noti, NOTIFICATION_TEXT_TYPE_CONTENT, device_name, NULL, NOTIFICATION_VARIABLE_TYPE_NONE);
- if (noti_err != NOTIFICATION_ERROR_NONE) {
- system_print("Error notification_set_contents : %d\n", noti_err);
- goto OTG_NOTI_FREE;
- }
-
- noti_err = notification_set_text(noti, NOTIFICATION_TEXT_TYPE_CONTENT_FOR_DISPLAY_OPTION_IS_OFF, "USB mass storage connected", NULL, NOTIFICATION_VARIABLE_TYPE_NONE);
- if (noti_err != NOTIFICATION_ERROR_NONE) {
- system_print("Error notification_set_content : %d\n", noti_err);
- goto OTG_NOTI_FREE;
- }
-
- noti_err = notification_set_image(noti, NOTIFICATION_IMAGE_TYPE_ICON, USB_ICON_PATH);
- if (noti_err != NOTIFICATION_ERROR_NONE) {
- system_print("Error notification_set_image : %d\n", noti_err);
- goto OTG_NOTI_FREE;
- }
-
- noti_err = notification_set_property(noti, NOTIFICATION_PROP_DISABLE_TICKERNOTI | NOTIFICATION_PROP_VOLATILE_DISPLAY);
- if (noti_err != NOTIFICATION_ERROR_NONE) {
- system_print("Error notification_set_property : %d\n", noti_err);
- goto OTG_NOTI_FREE;
- }
-
- noti_err = notification_set_display_applist(noti, NOTIFICATION_DISPLAY_APP_NOTIFICATION_TRAY);
- if (noti_err != NOTIFICATION_ERROR_NONE) {
- system_print("Error notification_set_display_applist : %d\n", noti_err);
- goto OTG_NOTI_FREE;
- }
-
- bundle *b;
- b = bundle_create();
- appsvc_set_pkgname(b, "org.tizen.usbotg-unmount-popup");
- appsvc_add_data(b, "device_name", device_name);
-
- noti_err = notification_set_execute_option(noti, NOTIFICATION_EXECUTE_TYPE_SINGLE_LAUNCH, "Launch", NULL, b);
- if (noti_err != NOTIFICATION_ERROR_NONE) {
- system_print("Error notification_set_execute_option : %d\n", noti_err);
- bundle_free(b);
- goto OTG_NOTI_FREE;
- }
- bundle_free(b);
-
-
- noti_err = notification_insert(noti, NULL);
- if (noti_err != NOTIFICATION_ERROR_NONE) {
- system_print("Error notification_insert : %d\n", noti_err);
- goto OTG_NOTI_FREE;
- }
-
- noti_err = notification_free(noti);
- if (noti_err != NOTIFICATION_ERROR_NONE) {
- system_print("Error notification_free : %d\n", noti_err);
- return -1;
- }
- }
-
- return 0;
-OTG_NOTI_FREE:
- noti_err = notification_free(noti);
- if (noti_err != NOTIFICATION_ERROR_NONE)
- system_print("Error notification_free : %d\n", noti_err);
- return -1;
-}
-
-
-int main(int argc, char *argv[])
-{
- struct appdata ad;
-
- /* App life cycle management */
- struct appcore_ops ops = {
- .create = app_create,
- .terminate = app_terminate,
- .pause = app_pause,
- .resume = app_resume,
- .reset = app_reset,
- };
-
- memset(&ad, 0x0, sizeof(struct appdata));
- ops.data = &ad;
-
- sysconf_set_mempolicy(OOM_IGNORE);
-
- return appcore_efl_main(PACKAGE, &argc, &argv, &ops);
-}
+++ /dev/null
-/*
- * Copyright (c) 2012 Samsung Electronics Co., Ltd.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-
-
-#ifndef __DEF_usbotg_H_
-#define __DEF_usbotg_H_
-
-#include <Elementary.h>
-#include <sys/types.h>
-#include <sys/stat.h>
-#include <fcntl.h>
-
-#ifndef PREFIX
-#define PREFIX "/usr"
-#endif /* PREFIX */
-
-#define TEMP_DIR "/tmp"
-#define PACKAGE "usbotg-popup"
-#define APPNAME "usbotg-popup"
-#define ICON_DIR PREFIX"/apps/org.tizen.usbotg-syspopup/res/images"
-#define BG_IMAGE TEMP_DIR"/01_popup_bg.jpg"
-#define MAIN_W (480)
-#define MAIN_H (800)
-#define EDJ_PATH PREFIX"/apps/org.tizen.usbotg-syspopup/res/edje/usbotg"
-#define EDJ_NAME EDJ_PATH"/usbotg.edj"
-#define EDJ_POPUP_NAME EDJ_PATH"/usbotg_popup.edj"
-#define GRP_MAIN "main"
-#define GRP_POPUP "popup"
-#define MAX_PROCESS_NAME 100
-#define PROCESS_NAME_FILE "/tmp/processname.txt"
-#define BEAT
-
-struct appdata {
- Evas *evas;
- Evas_Object *win_main;
- Evas_Object *popup;
-
- Evas_Object *layout_main; /* layout widget based on EDJ */
-
- Evas_Object *root_w;
- Evas_Object *root_h;
- Evas_Object *bg;
- Evas_Object *indicator;
-
- double w_ratio;
- double h_ratio;
-
-};
-
-#endif /* __DEF_usbotg_H__ */
+++ /dev/null
-
-########################### usbotg-unmount ###########################
-CMAKE_MINIMUM_REQUIRED(VERSION 2.6)
-PROJECT(usbotg-unmount-popup C)
-
-SET(SRCS ${CMAKE_SOURCE_DIR}/usbotg-unmount-popup/src/usbotg-unmount.c)
-
-IF("${CMAKE_BUILD_TYPE}" STREQUAL "")
- SET(CMAKE_BUILD_TYPE "Release")
-ENDIF("${CMAKE_BUILD_TYPE}" STREQUAL "")
-MESSAGE("Build type: ${CMAKE_BUILD_TYPE}")
-
-INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR})
-INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/usbotg-unmount-popup)
-
-INCLUDE(FindPkgConfig)
-pkg_check_modules(pkgs REQUIRED appcore-efl elementary devman devman_haptic mm-sound sysman syspopup syspopup-caller ecore-evas appsvc)
-
-FOREACH(flag ${pkgs_CFLAGS})
- SET(EXTRA_CFLAGS "${EXTRA_CFLAGS} ${flag} -g -I/usr/include/elementary-0 ")
-ENDFOREACH(flag)
-
-SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${EXTRA_CFLAGS}")
-SET(CMAKE_C_FLAGS_DEBUG "-O0 -g")
-SET(CMAKE_C_FLAGS_RELEASE "-O2")
-
-FIND_PROGRAM(UNAME NAMES uname)
-EXEC_PROGRAM("${UNAME}" ARGS "-m" OUTPUT_VARIABLE "ARCH")
-IF("${ARCH}" STREQUAL "arm")
- ADD_DEFINITIONS("-DTARGET")
- MESSAGE("add -DTARGET")
-ENDIF("${ARCH}" STREQUAL "arm")
-
-ADD_DEFINITIONS("-DPREFIX=\"${CMAKE_INSTALL_PREFIX}\"")
-ADD_DEFINITIONS("-DSLP_DEBUG")
-
-SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed")
-
-ADD_EXECUTABLE(${PROJECT_NAME} ${SRCS})
-TARGET_LINK_LIBRARIES(${PROJECT_NAME} ${pkgs_LDFLAGS})
-
-ADD_CUSTOM_TARGET(usbotg-unmount.edj
- COMMAND edje_cc -id ${CMAKE_SOURCE_DIR}/../images
- ${CMAKE_SOURCE_DIR}/edcs/usbotg-unmount.edc ${CMAKE_BINARY_DIR}/${PROJECT_NAME}/usbotg-unmount.edj
- DEPENDS ${CMAKE_SOURCE_DIR}/edcs/usbotg-unmount.edc
-)
-ADD_DEPENDENCIES(${PROJECT_NAME} usbotg-unmount.edj)
-
-INSTALL(TARGETS ${PROJECT_NAME} DESTINATION /usr/apps/org.tizen.usbotg-unmount-popup/bin)
-INSTALL(FILES ${CMAKE_BINARY_DIR}/${PROJECT_NAME}/usbotg-unmount.edj DESTINATION /usr/apps/org.tizen.usbotg-unmount-popup/res/edje/usbotg-unmount)
-
-# install desktop file & icon
-SET(PREFIX ${CMAKE_INSTALL_PREFIX})
-INSTALL(FILES ${CMAKE_SOURCE_DIR}/data/org.tizen.usbotg-unmount-popup.png DESTINATION /usr/apps/org.tizen.usbotg-unmount-popup/res/icon)
-INSTALL(FILES ${CMAKE_SOURCE_DIR}/sound/02_Warning.wav DESTINATION /usr/apps/org.tizen.usbotg-unmount-popup/res/keysound)
-
-# install manifest xml file
-INSTALL(FILES ${CMAKE_SOURCE_DIR}/data/org.tizen.usbotg-unmount-popup.xml DESTINATION /usr/share/packages/)
-
-# install ini file
-INSTALL(FILES ${CMAKE_SOURCE_DIR}/data/${PROJECT_NAME}.ini DESTINATION /usr/share/process-info)
-
-# i18n
-ADD_SUBDIRECTORY(po_usbotg_unmount)
-
-################################# End ##############################################
-
+++ /dev/null
-# for i18n
-
-SET(POFILES ar.po el_GR.po es_ES.po fi.po gl.po hy.po ka.po lv.po pl.po ru_RU.po sv.po zh_CN.po az.po cs.po en_PH.po es_US.po fr_CA.po hi.po is.po kk.po mk.po pt_BR.po sk.po tr_TR.po zh_HK.po bg.po da.po en.po et.po fr_FR.po hr.po it_IT.po ko_KR.po nb.po pt_PT.po sl.po uk.po zh_SG.po ca.po de_DE.po en_US.po eu.po ga.po hu.po ja_JP.po lt.po nl_NL.po ro.po sr.po uz.po zh_TW.po)
-
-SET(MSGFMT "/usr/bin/msgfmt")
-
-FOREACH(pofile ${POFILES})
- SET(pofile ${CMAKE_CURRENT_SOURCE_DIR}/${pofile})
- MESSAGE("PO: ${pofile}")
- GET_FILENAME_COMPONENT(absPofile ${pofile} ABSOLUTE)
- GET_FILENAME_COMPONENT(lang ${absPofile} NAME_WE)
- SET(moFile ${CMAKE_CURRENT_BINARY_DIR}/${lang}.mo)
- ADD_CUSTOM_COMMAND(
- OUTPUT ${moFile}
- COMMAND ${MSGFMT} -o ${moFile} ${absPofile}
- DEPENDS ${absPofile}
- )
- INSTALL(FILES ${moFile}
- DESTINATION /usr/apps/org.tizen.usbotg-unmount-popup/res/locale/${lang}/LC_MESSAGES RENAME ${PROJECT_NAME}.mo)
- SET(moFiles ${moFiles} ${moFile})
-ENDFOREACH(pofile)
-
-MESSAGE(".mo files: ${moFiles}")
-ADD_CUSTOM_TARGET(po_usbotg_unmount ALL DEPENDS ${moFiles})
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "معلومات النظام"
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "الذاكرة لا تكفي"
-
-msgid "IDS_COM_SK_OK"
-msgstr "موافق"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "حجم الذاكرة منخفض"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s مغلق"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Sistm mlmtı"
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Yaddaş kifayət etmir"
-
-msgid "IDS_COM_SK_OK"
-msgstr "OK"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Batareya azdır"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s bağlanmışdır"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Сист. инф."
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Няма достатъчно памет"
-
-msgid "IDS_COM_SK_OK"
-msgstr "OK"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Паметта е на привършване"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s затворен"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Info sist"
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "No hi ha prou memòria"
-
-msgid "IDS_COM_SK_OK"
-msgstr "Acceptar"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Poca memòria"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s tancat"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Syst. info"
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Nedostatek paměti"
-
-msgid "IDS_COM_SK_OK"
-msgstr "OK"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Nedostatek paměti"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s byl uzavřen"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Systeminfo"
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Ikke nok hukommelse"
-
-msgid "IDS_COM_SK_OK"
-msgstr "OK"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Lav hukommelse"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s blev lukket"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Systeminfo"
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Speicher voll"
-
-msgid "IDS_COM_SK_OK"
-msgstr "OK"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Wenig Speicher übrig"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s geschlossen"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Πληρ. Συστήμ."
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Ανεπαρκής μνήμη"
-
-msgid "IDS_COM_SK_OK"
-msgstr "OK"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Ανεπαρκής μνήμη"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s έκλεισε"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "System info"
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Not enough memory"
-
-msgid "IDS_COM_SK_OK"
-msgstr "OK"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Low memory"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s closed"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "System info"
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Not enough memory"
-
-msgid "IDS_COM_SK_OK"
-msgstr "OK"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Low memory"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s closed"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "System info"
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Not enough memory"
-
-msgid "IDS_COM_SK_OK"
-msgstr "OK"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Low memory"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s closed"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Información del sistema"
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "No hay suficiente memoria"
-
-msgid "IDS_COM_SK_OK"
-msgstr "Aceptar"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Memoria baja"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s cerrado"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Inf. sistem."
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Memoria insuficiente"
-
-msgid "IDS_COM_SK_OK"
-msgstr "Aceptar"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Memoria baja"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s cerrado"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Süst.teave"
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Mälu pole piisavalt"
-
-msgid "IDS_COM_SK_OK"
-msgstr "OK"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Aku tühjeneb"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s suleti"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Sist. inf."
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Ez dago memoria nahikoa"
-
-msgid "IDS_COM_SK_OK"
-msgstr "Ados"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Memoria gutxi"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s itxita"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Järj.tied."
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Ei tarpeeksi muistia"
-
-msgid "IDS_COM_SK_OK"
-msgstr "OK"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Muisti vähissä"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s suljettu"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Infos syst."
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Mémoire insuffisante"
-
-msgid "IDS_COM_SK_OK"
-msgstr "OK"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Mémoire faible"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s fermé"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Infos système"
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Mémoire insuffisante"
-
-msgid "IDS_COM_SK_OK"
-msgstr "OK"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Mémoire faible"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s fermé"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Fais. Chórais"
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Easpa cuimhne"
-
-msgid "IDS_COM_SK_OK"
-msgstr "OK"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Cuimhne íseal"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s dúnta"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Info sist"
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Non hai suficiente memoria"
-
-msgid "IDS_COM_SK_OK"
-msgstr "Aceptar"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Memoria baixa"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s pechado"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "सिस्टम जानका."
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "पर्याप्त मेमोरी नहीं"
-
-msgid "IDS_COM_SK_OK"
-msgstr "ठीक"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "बैटरी कम है"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s बंद"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "O sustavu"
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Memorija nedovoljna"
-
-msgid "IDS_COM_SK_OK"
-msgstr "OK"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Malo memorije"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s zatvoren"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "R.szerinfó"
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Kevés a memória"
-
-msgid "IDS_COM_SK_OK"
-msgstr "OK"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Kevés a memória"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s lezárva"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Հմկրգ ինֆո"
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Չկա բավական հիշողություն"
-
-msgid "IDS_COM_SK_OK"
-msgstr "OK"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Մարտկոցի լիցքը թույլ է"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s փակվեց"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Kerfisuppl"
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Ekki er nægt minni"
-
-msgid "IDS_COM_SK_OK"
-msgstr "Í lagi"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Það er of lítið minni"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s var lokað"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Info sistema"
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Memoria insufficiente"
-
-msgid "IDS_COM_SK_OK"
-msgstr "OK"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Memoria insufficiente"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s chiuso"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "システム情報"
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "メモリが不足しています。"
-
-msgid "IDS_COM_SK_OK"
-msgstr "OK"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "メモリの容量不足です"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%sを終了しました"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "სისტემ.ინფო"
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "მეხსიერება არ არის საკმარისი"
-
-msgid "IDS_COM_SK_OK"
-msgstr "OK"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "კვების ელემენტი იცლება"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s დახურულია"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Жүйе. ақп."
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Жадында орын аз"
-
-msgid "IDS_COM_SK_OK"
-msgstr "OK"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Батарея заряды аз"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s жабық"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "시스템 정보"
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "메모리가 부족합니다"
-
-msgid "IDS_COM_SK_OK"
-msgstr "확인"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "메모리가 부족합니다"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s이(가) 종료되었습니다"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Sist. inform."
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Nepakanka atminties"
-
-msgid "IDS_COM_SK_OK"
-msgstr "Gerai"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Senkanti baterija"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s uždaryta"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Sist. inf."
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Atmiņa pilna"
-
-msgid "IDS_COM_SK_OK"
-msgstr "Labi"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Tukšs akumulators"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "Sadaļa %s ir aizvērta"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Сист.инфо."
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Нема доволно меморија"
-
-msgid "IDS_COM_SK_OK"
-msgstr "OK"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Има уште малку меморија"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s се затвори"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Systeminfo"
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Ikke nok minne"
-
-msgid "IDS_COM_SK_OK"
-msgstr "OK"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Lite minne"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s lukket"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Systeeminfo"
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Onvoldoende geheugen"
-
-msgid "IDS_COM_SK_OK"
-msgstr "OK"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Onvoldoende geheugen"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s afgesloten"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Info syst."
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Brak pamięci"
-
-msgid "IDS_COM_SK_OK"
-msgstr "OK"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Mało pamięci"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "Zamknięto %s"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Sistema"
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Memória insuficiente"
-
-msgid "IDS_COM_SK_OK"
-msgstr "OK"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Baixa memória"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s fechado"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Info. sist."
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Cartão SD cheio"
-
-msgid "IDS_COM_SK_OK"
-msgstr "OK"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Pouca memória"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s fechado"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Info. sis."
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Memorie plină"
-
-msgid "IDS_COM_SK_OK"
-msgstr "OK"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Memorie insuficientă"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s a fost închis"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Системная информация"
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Недостаточно памяти"
-
-msgid "IDS_COM_SK_OK"
-msgstr "Да"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Аккумулятор разряжен"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s закрыт"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Syst. inf."
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Nedostatok pamäte"
-
-msgid "IDS_COM_SK_OK"
-msgstr "OK"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Nedostatok pamäte"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s zatvorené"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Sist. info"
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Ni dovolj pomnilnika"
-
-msgid "IDS_COM_SK_OK"
-msgstr "V redu"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Zmanjkuje pomnilnika"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s zaprto"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Info.sist."
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Nedovoljna memorija"
-
-msgid "IDS_COM_SK_OK"
-msgstr "OK"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Memorija pri kraju"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s zatvoreno"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Systeminfo"
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Minnet fullt"
-
-msgid "IDS_COM_SK_OK"
-msgstr "OK"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Ont om minnesplats"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s har stängts"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Sistem bilgi."
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Yeterli hafıza yok"
-
-msgid "IDS_COM_SK_OK"
-msgstr "Tamam"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Düşük hafıza"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s kapatıldı"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Сист. інф."
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Недостатньо пам'яті"
-
-msgid "IDS_COM_SK_OK"
-msgstr "ОК"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Батарея розряджена"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s закрито"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "Tizim ma’l."
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "Xotira yetarli emas"
-
-msgid "IDS_COM_SK_OK"
-msgstr "OK"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "Bo‘sh xotira kam"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s yopildi"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "系统信息"
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "没有足够内存"
-
-msgid "IDS_COM_SK_OK"
-msgstr "确定"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "内存不足"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s 已关闭"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "系統資料"
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "記憶體不足"
-
-msgid "IDS_COM_SK_OK"
-msgstr "確定"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "記憶體不足"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s 已關閉"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "系统信息"
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "内存不足"
-
-msgid "IDS_COM_SK_OK"
-msgstr "确认"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "内存不足"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s 已关闭"
-
+++ /dev/null
-msgid "IDS_COM_BODY_SYSTEM_INFO_ABB"
-msgstr "系統訊息"
-
-msgid "IDS_COM_POP_NOT_ENOUGH_MEMORY"
-msgstr "記憶體不足"
-
-msgid "IDS_COM_SK_OK"
-msgstr "確定"
-
-msgid "IDS_IDLE_BODY_LOW_MEMORY"
-msgstr "記憶體不足"
-
-msgid "IDS_IDLE_POP_PS_CLOSED"
-msgstr "%s 已關閉"
-
+++ /dev/null
-/*
- * Copyright (c) 2012 Samsung Electronics Co., Ltd.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-
-
-#include <stdio.h>
-#include <appcore-efl.h>
-#include <sensor.h>
-#include <devman_haptic.h>
-#include <mmf/mm_sound.h>
-#include <pmapi.h>
-#include <sysman.h>
-#include "usbotg-unmount.h"
-#include <Ecore_X.h>
-#include <utilX.h>
-#include <notification.h>
-#include <syspopup_caller.h>
-#include <appsvc.h>
-
-#define APPLICATION_BG 1
-#define INDICATOR_HEIGHT (38) /* the case of 480*800 */
-#define NEW_INDI
-
-#define ACCT_PROF
-#ifdef ACCT_PROF
-#include <sys/acct.h>
-#endif /* ACCT_PROF */
-
-#include <syspopup.h>
-
-static const char *dev_name = NULL;
-
-int myterm(bundle *b, void *data)
-{
- return 0;
-}
-
-int mytimeout(bundle *b, void *data)
-{
- return 0;
-}
-
-syspopup_handler handler = {
- .def_term_fn = myterm,
- .def_timeout_fn = mytimeout
-};
-
-struct text_part {
- char *part;
- char *msgid;
-};
-
-static struct text_part main_txt[] = {
- {"txt_title", N_("USB otg popup"),},
- {"txt_mesg", N_(""),},
-};
-
-
-/* App Life cycle funtions */
-static void win_del(void *data, Evas_Object *obj, void *event)
-{
- elm_exit();
-}
-
-/* Quit */
-static void main_quit_cb(void *data, Evas_Object *obj, const char *emission,
- const char *source)
-{
- elm_exit();
-}
-
-/* Update text font */
-static void update_ts(Evas_Object *eo, struct text_part *tp, int size)
-{
- int i;
-
- if (eo == NULL || tp == NULL || size < 0)
- return;
-
- for (i = 0; i < size; i++) {
- if (tp[i].part && tp[i].msgid)
- edje_object_part_text_set(eo, tp[i].part,
- _(tp[i].msgid));
- }
-}
-
-/* Language changed noti handler */
-static int lang_changed(void *data)
-{
- struct appdata *ad = data;
-
- if (ad->layout_main == NULL)
- return 0;
-
- update_ts(elm_layout_edje_get(ad->layout_main), main_txt,
- sizeof(main_txt) / sizeof(main_txt[0]));
- return 0;
-}
-
-/* Create main window */
-static Evas_Object *create_win(const char *name)
-{
- Evas_Object *eo;
- int w, h;
-
- eo = elm_win_add(NULL, name, ELM_WIN_DIALOG_BASIC);
- if (eo) {
- elm_win_title_set(eo, name);
- elm_win_borderless_set(eo, EINA_TRUE);
- evas_object_smart_callback_add(eo, "delete,request", win_del, NULL);
- elm_win_alpha_set(eo, EINA_TRUE);
- ecore_x_window_size_get(ecore_x_window_root_first_get(), &w,
- &h);
- evas_object_resize(eo, w, h);
- }
-
- return eo;
-}
-
-/* Read from EDJ file */
-static Evas_Object *load_edj(Evas_Object * parent, const char *file,
- const char *group)
-{
- Evas_Object *eo;
- int r;
-
- eo = elm_layout_add(parent);
- if (eo) {
- r = elm_layout_file_set(eo, file, group);
- if (!r) {
- evas_object_del(eo);
- return NULL;
- }
-
- evas_object_size_hint_weight_set(eo, EVAS_HINT_EXPAND,
- EVAS_HINT_EXPAND);
- }
-
- return eo;
-}
-
-/* Terminate noti handler */
-static int app_terminate(void *data)
-{
- struct appdata *ad = data;
-
- if (ad->layout_main)
- evas_object_del(ad->layout_main);
-
- if (ad->win_main)
- evas_object_del(ad->win_main);
-
- return 0;
-}
-
-/* Pause/background */
-static int app_pause(void *data)
-{
- return 0;
-}
-
-/* Resume */
-static int app_resume(void *data)
-{
- return 0;
-}
-
-
-/* Reset */
-static int app_reset(bundle *b, void *data)
-{
- struct appdata *ad = data;
- int removenoti = -1;
- char *opt = NULL;
-
- dev_name = bundle_get_val(b, "device_name");
- if (dev_name == NULL)
- return 0;
-
- if (syspopup_has_popup(b)) {
- syspopup_reset(b);
- } else {
- syspopup_create(b, &handler, ad->win_main, ad);
- evas_object_show(ad->win_main);
-
- /* Start Main UI */
- usbotg_unmount_start((void *)ad);
- }
-
- return 0;
-}
-
-/* Customized print */
-void system_print(const char *format, ...)
-{
- /* Un-comment return to disable logs */
- //return;
-
- va_list args;
- va_start(args, format);
- vfprintf(stderr, format, args);
- va_end(args);
-}
-
-/* Cleanup objects to avoid mem-leak */
-void usbotg_unmount_cleanup(struct appdata *ad)
-{
- if (ad == NULL)
- return;
-
- if (ad->popup)
- evas_object_del(ad->popup);
- if (ad->layout_main)
- evas_object_del(ad->layout_main);
-}
-
-/* Background clicked noti */
-void bg_clicked_cb(void *data, Evas * e, Evas_Object * obj, void *event_info)
-{
- system_print("\n system-popup : In BG Noti \n");
- fflush(stdout);
- exit(0);
-}
-
-/* Yes clicked noti */
-// TO DO
-// following is private vconf key for system-server
-#define VCONFKEY_REMOVED_USB_STORAGE "memory/private/sysman/removed_storage_uevent"
-
-void ok_clicked_cb(void *data, Evas * e, Evas_Object * obj, void *event_info)
-{
- system_print("\n system-popup : Yes Noti \n");
-
- struct appdata *ad = data;
- vconf_set_str(VCONFKEY_REMOVED_USB_STORAGE, ad->device_name);
- free(ad->device_name);
-
- fflush(stdout);
- exit(0);
-}
-
-/* Create indicator bar */
-int usbotg_unmount_create_indicator(struct appdata *ad)
-{
- elm_win_indicator_mode_set(ad->win_main, ELM_WIN_INDICATOR_HIDE);
- return 0;
-}
-
-/* Basic popup widget */
-int usbotg_unmount_create_and_show_basic_popup(struct appdata *ad)
-{
- Evas_Object *btn1;
- Evas_Object *btn2;
- char buf[PATH_MAX] = {0, };
-
- /* Initialization */
- int ret_val = 0;
- snprintf(buf, PATH_MAX, "Unmount %s?", dev_name);
- ad->device_name = malloc(strlen(dev_name)+1);
- strncpy(ad->device_name, dev_name, strlen(dev_name));
-
- /* Add notify */
- /* No need to give main window, it will create internally */
- ad->popup = elm_popup_add(ad->win_main);
- evas_object_size_hint_weight_set(ad->popup, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
- elm_object_style_set(ad->popup, "transparent");
- elm_object_text_set(ad->popup, buf);
- elm_object_part_text_set(ad->popup, "title,text", _("IDS_COM_BODY_SYSTEM_INFO_ABB"));
-
- btn1 = elm_button_add(ad->popup);
- elm_object_text_set(btn1, "OK");
- elm_object_part_content_set(ad->popup, "button1", btn1);
- elm_object_style_set(btn1, "popup_button/default");
- evas_object_smart_callback_add(btn1, "clicked", ok_clicked_cb, ad);
-
- btn2 = elm_button_add(ad->popup);
- elm_object_text_set(btn2, "Cancel");
- elm_object_part_content_set(ad->popup, "button2", btn2);
- elm_object_style_set(btn2, "popup_button/default");
- evas_object_smart_callback_add(btn2, "clicked", bg_clicked_cb, ad);
-
- Ecore_X_Window xwin;
- xwin = elm_win_xwindow_get(ad->popup);
- ecore_x_netwm_window_type_set(xwin, ECORE_X_WINDOW_TYPE_NOTIFICATION);
- evas_object_show(ad->popup);
-
- return 0;
-}
-
-int usbotg_unmount_start(void *data)
-{
- struct appdata *ad = data;
- int ret_val = 0;
-
- /* Create and show popup */
- ret_val = usbotg_unmount_create_and_show_basic_popup(ad);
- if (ret_val != 0)
- return -1;
-
- return 0;
-}
-
-/* App init */
-int app_create(void *data)
-{
- Evas_Object *win;
- struct appdata *ad = data;
-
- /* create window */
- win = create_win(PACKAGE);
- if (win == NULL)
- return -1;
-
- ad->win_main = win;
-
- return 0;
-
-}
-
-int main(int argc, char *argv[])
-{
- struct appdata ad;
-
- /* App life cycle management */
- struct appcore_ops ops = {
- .create = app_create,
- .terminate = app_terminate,
- .pause = app_pause,
- .resume = app_resume,
- .reset = app_reset,
- };
-
- memset(&ad, 0x0, sizeof(struct appdata));
- ops.data = &ad;
-
- sysconf_set_mempolicy(OOM_IGNORE);
-
- return appcore_efl_main(PACKAGE, &argc, &argv, &ops);
-}
+++ /dev/null
-/*
- * Copyright (c) 2012 Samsung Electronics Co., Ltd.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-
-
-#ifndef __DEF_usbotg_unmount_H_
-#define __DEF_usbotg_unmount_H_
-
-#include <Elementary.h>
-#include <sys/types.h>
-#include <sys/stat.h>
-#include <fcntl.h>
-
-#ifndef PREFIX
-#define PREFIX "/usr"
-#endif /* PREFIX */
-
-#define TEMP_DIR "/tmp"
-#define PACKAGE "usbotg-unmount-popup"
-#define APPNAME "usbotg-unmount-popup"
-#define ICON_DIR PREFIX"/apps/org.tizen.usbotg-unmount-popup/res/images"
-#define BG_IMAGE TEMP_DIR"/01_popup_bg.jpg"
-#define MAIN_W (480)
-#define MAIN_H (800)
-#define EDJ_PATH PREFIX"/apps/org.tizen.usbotg-unmount-popup/res/edje/usbotg-unmount"
-#define EDJ_NAME EDJ_PATH"/usbotg-unmount.edj"
-#define EDJ_POPUP_NAME EDJ_PATH"/usbotg_unmount_popup.edj"
-#define GRP_MAIN "main"
-#define GRP_POPUP "popup"
-#define MAX_PROCESS_NAME 100
-#define PROCESS_NAME_FILE "/tmp/processname.txt"
-#define BEAT
-
-struct appdata {
- Evas *evas;
- Evas_Object *win_main;
- Evas_Object *popup;
-
- Evas_Object *layout_main; /* layout widget based on EDJ */
-
- Evas_Object *root_w;
- Evas_Object *root_h;
- Evas_Object *bg;
- Evas_Object *indicator;
-
- double w_ratio;
- double h_ratio;
-
- const char *device_name;
-
-};
-
-#endif /* __DEF_usbotg_unmount_H__ */