[TBT][All][DPTTIZEN-1952][Scenario for sound manager connection and device status... 35/73935/1
authorNibha Sharma <nibha.sharma@samsung.com>
Fri, 10 Jun 2016 06:11:10 +0000 (15:11 +0900)
committerNibha Sharma <nibha.sharma@samsung.com>
Fri, 10 Jun 2016 06:11:10 +0000 (15:11 +0900)
Change-Id: I633f92331e46676624399d45a9bb9537db1c401c
Signed-off-by: Nibha Sharma <nibha.sharma@samsung.com>
29 files changed:
release/binary-armv7l/org.tizen.tbtcoreapp-1.0.0-arm.tpk
release/binary-x86/org.tizen.tbtcoreapp-1.0.0-i386.tpk
tbtcoreapp/CMakeLists.txt
tbtcoreapp/inc/model/tbt-info.h
tbtcoreapp/inc/utils/app_module_config.h
tbtcoreapp/inc/utils/ui-utils.h
tbtcoreapp/inc/view/tbt-connection-view.h [new file with mode: 0755]
tbtcoreapp/inc/view/tbt-media-key-view.h [new file with mode: 0644]
tbtcoreapp/inc/view/tbt-notification-view.h [new file with mode: 0644]
tbtcoreapp/inc/view/tbt-package-manager-view.h [new file with mode: 0644]
tbtcoreapp/inc/view/tbt-sound-manager-view.h [new file with mode: 0644]
tbtcoreapp/packaging/org.tizen.tbtcoreapp.spec
tbtcoreapp/res/edje/3.0/mobile/connection_viewer.edc [new file with mode: 0755]
tbtcoreapp/res/edje/3.0/mobile/mediakey_viewer.edc [new file with mode: 0644]
tbtcoreapp/res/edje/3.0/mobile/notification_viewer.edc [new file with mode: 0644]
tbtcoreapp/res/edje/3.0/mobile/package_manager_viewer.edc [new file with mode: 0644]
tbtcoreapp/res/edje/3.0/mobile/sound_manager_viewer.edc [new file with mode: 0644]
tbtcoreapp/res/package/native-testapp-itc-1.0.0-arm.tpk [new file with mode: 0755]
tbtcoreapp/src/model/tbt-list.c
tbtcoreapp/src/utils/ui-utils.c
tbtcoreapp/src/view/tbt-connection-view.c [new file with mode: 0755]
tbtcoreapp/src/view/tbt-genlist-view.c
tbtcoreapp/src/view/tbt-media-key-view.c [new file with mode: 0644]
tbtcoreapp/src/view/tbt-nfc-view.c
tbtcoreapp/src/view/tbt-notification-view.c [new file with mode: 0644]
tbtcoreapp/src/view/tbt-package-manager-view.c [new file with mode: 0644]
tbtcoreapp/src/view/tbt-radio-view.c
tbtcoreapp/src/view/tbt-sound-manager-view.c [new file with mode: 0644]
tbtcoreapp/tizen-manifest.xml

index 0e2177c953fbd0b2994c976deb1a9045950170bb..6ef0b6bee737d7365a9d9adb180a4496bff9e264 100644 (file)
Binary files a/release/binary-armv7l/org.tizen.tbtcoreapp-1.0.0-arm.tpk and b/release/binary-armv7l/org.tizen.tbtcoreapp-1.0.0-arm.tpk differ
index 7fdd1638668bd5fe0e15f1f80684367637fdf6fa..309d4b70d8dc5eddce0889e49d5e25dc61a9ca2c 100644 (file)
Binary files a/release/binary-x86/org.tizen.tbtcoreapp-1.0.0-i386.tpk and b/release/binary-x86/org.tizen.tbtcoreapp-1.0.0-i386.tpk differ
index 2c8450e82f312412942cec066e98949e0a8e9961..29473130e47113d883d97dfc64337fc5d915ca72 100755 (executable)
@@ -67,6 +67,7 @@ nsd-ssdp
 capi-network-mtp
 ecore-wayland
 efl
+notification
 )
 
 INCLUDE(FindPkgConfig)
@@ -115,6 +116,7 @@ TARGET_LINK_LIBRARIES(${PROJECT_NAME}
                elementary
                evas
                glib-2.0
+               gobject-2.0
                json-glib-1.0
                curl
                m
@@ -131,6 +133,7 @@ TARGET_LINK_LIBRARIES(${PROJECT_NAME}
                capi-network-mtp
                efl
                data-control
+               notification
 )
 
 CONFIGURE_FILE(tizen-manifest.xml ${PACKAGE_NAME}.xml)
index 9df84c651e60824fdc2919e0dddf2ae1f8798428..4b56778bd30b59e6bb13d98410f4740ad5d199a7 100644 (file)
@@ -188,7 +188,25 @@ typedef enum {
 
     TBT_APP_STORAGE,
        
-    TBT_APP_RADIO
+    TBT_APP_RADIO,
+       
+    TBT_APP_SOUND_MANAGER,
+
+    TBT_APP_SOUND_MANAGER_DEVICE,
+
+    TBT_APP_MEDIA_KEY,
+       
+    TBT_APP_PACKAGE_MANAGER,
+
+    TBT_APP_NOTIFICATION_TEXT,
+       
+    TBT_APP_NOTIFICATION_TIME,
+
+    TBT_APP_NOTIFICATION_TITLE,
+
+    TBT_APP_NOTIFICATION_IMAGE,
+       
+    TBT_APP_CONNECTION
 
 } tbt_app_type_e;
 
@@ -357,7 +375,8 @@ static char *feature_list[1024] =
        "tizen.org/feature/network.nfc.p2p",
        "tizen.org/feature/network.nfc.tag",
        "tizen.org/feature/network.wifi.direct.display",
-       "tizen.org/feature/network.internet"
+       "tizen.org/feature/network.internet",
+       "tizen.org/feature/notification"
 };
 
 #endif /* __TBT_INFO_H__ */
index cf855ba9feff5ed08bbf88dbb48bcaf0f0674f33..9c349cd0a8ae52d3e7c37d4b2f3aad161f8be879 100644 (file)
 #define TBT_MODULE_RADIO
 #define TBT_MODULE_APP_RADIO
 
+#define TBT_MODULE_SOUND_MANAGER
+#define TBT_MODULE_APP_SOUND_MANAGER
+#define TBT_MODULE_APP_SOUND_MANAGER_DEVICE
+
+#define TBT_MODULE_MEDIA_KEY
+#define TBT_MODULE_APP_MEDIA_KEY
+
+#define TBT_MODULE_PACKAGE_MANAGER
+#define TBT_MODULE_APP_PACKAGE_MANAGER
+
+#define TBT_MODULE_NOTIFICATION
+#define TBT_MODULE_APP_NOTIFICATION
+#define TBT_MODULE_APP_NOTIFICATION_TIME
+#define TBT_MODULE_APP_NOTIFICATION_TITLE
+#define TBT_MODULE_APP_NOTIFICATION_IMAGE
+
+#define TBT_MODULE_CONNECTION
+#define TBT_MODULE_APP_CONNECTION
+
 #endif
index 527400e6b440c63ba6236709a1c1adbebf6047c3..266b26e022f78636e30f2e7ebfea7fa34ddbe599 100644 (file)
@@ -221,4 +221,11 @@ Evas_Object *ui_utils_progressbar_add(void *data, Evas_Object *parent, Evas_Smar
  * @since_tizen 2.3
  * */
 void ui_utils_show_toast(const char* message, const Evas_Object* data, float timeout);
+
+/*
+ * @brief Pop up Manual Instruction Button
+ * @since_tizen 3.0
+ * */
+void ui_utils_guide_instruction_popup_button(const Evas_Object* view, const char* txtInstruction);
+
 #endif /* __UI_UTILS_H__ */
diff --git a/tbtcoreapp/inc/view/tbt-connection-view.h b/tbtcoreapp/inc/view/tbt-connection-view.h
new file mode 100755 (executable)
index 0000000..f0a0cc0
--- /dev/null
@@ -0,0 +1,55 @@
+/*******************************************************************************
+ * Copyright (c) 2014 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.
+ *
+ *******************************************************************************/
+/**
+ * @file       tbt-feature-view.h
+ * @brief      checks availability of features in device
+ * @since_tizen 2.3
+ * @author     A B M Nazibullah(nazib.ullah@samsung.com)
+ * @date       October, 2014
+ * @bug                NA
+ * @credit     Tizen SDK Version 2.3.0 Sample Example
+ *
+ */
+
+#ifndef __TBT_CONNECTION_VIEW_H__
+#define __TBT_CONNECTION_VIEW_H__
+
+#include "utils/app_module_config.h"
+#ifdef TBT_MODULE_CONNECTION
+
+#include <Evas.h>
+#include "model/tbt-list.h"
+
+
+/**
+ * @typedef feature_view
+ * @since_tizen 2.3
+ * @brief A feature viewer view handle.
+ */
+typedef struct _connection_view connection_view;
+
+/**
+ * @brief Add feature view
+ * @since_tizen 2.3 
+ * @param[in] app The pointer to _app_data instance
+ * @param[in] navi The naviframe object
+ * @return Feature viewer view data
+ */
+connection_view *connection_view_add(Evas_Object *navi, tbt_info *tbt_info, Elm_Object_Item *item);
+
+#endif
+#endif // __TBT_FEATURE_VIEW_H__
diff --git a/tbtcoreapp/inc/view/tbt-media-key-view.h b/tbtcoreapp/inc/view/tbt-media-key-view.h
new file mode 100644 (file)
index 0000000..d29f716
--- /dev/null
@@ -0,0 +1,58 @@
+/*******************************************************************************
+ * Copyright (c) 2014 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.
+ *
+ *******************************************************************************/
+/**
+ * @file       tbt-mediakey-view.h
+ * @brief      retrieves mediakey info
+ * @since_tizen 3.0
+ * @author     Nibha Sharma(nibha.sharma@samsung.com)
+ * @date       June, 2016
+ * @bug                none
+ * @credit
+ * @credit
+ *
+ */
+
+#ifndef __TBT_MEDIA_KEY_VIEW_H__
+#define __TBT_MEDIA_KEY_VIEW_H__
+
+#include "utils/app_module_config.h"
+#ifdef TBT_MODULE_MEDIA_KEY
+
+#include <Evas.h>
+#include "model/tbt-list.h"
+#include <media_key.h>
+
+
+/**
+ * @typedef mediakey_viewer_view
+ * @since_tizen 3.0
+ * @brief A mediakey view handle.
+ */
+typedef struct _mediakey_view mediakey_view;
+
+/**
+ * @brief      Create mediakey view
+ * @since_tizen 3.0 
+ * @param[in]  navi Parent naviframe
+ * @param[in]  custom structute to hold tbt application information
+ * @param[in]  item of the main tbt menu
+ * @return     Pointer of mediakey on success, otherwise NULL
+ */
+mediakey_view *mediakey_view_add(Evas_Object *navi, tbt_info *tbt_info, Elm_Object_Item *item);
+
+#endif
+#endif // __TBT_MEDIA_KEY_VIEW_H__
diff --git a/tbtcoreapp/inc/view/tbt-notification-view.h b/tbtcoreapp/inc/view/tbt-notification-view.h
new file mode 100644 (file)
index 0000000..0fef4c1
--- /dev/null
@@ -0,0 +1,58 @@
+/*******************************************************************************
+ * Copyright (c) 2014 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.
+ *
+ *******************************************************************************/
+/**
+ * @file       tbt-notification-view.h
+ * @brief      retrieves notification info
+ * @since_tizen 3.0
+ * @author     Nibha Sharma(nibha.sharma@samsung.com)
+ * @date       June, 2016
+ * @bug                none
+ * @credit
+ * @credit
+ *
+ */
+
+#ifndef __TBT_NOTIFICATION_VIEW_H__
+#define __TBT_NOTIFICATION_VIEW_H__
+
+#include "utils/app_module_config.h"
+#ifdef TBT_MODULE_NOTIFICATION
+
+#include <Evas.h>
+#include "model/tbt-list.h"
+#include <notification.h>
+
+
+/**
+ * @typedef notification_viewer_view
+ * @since_tizen 3.0
+ * @brief A notification viewer view handle.
+ */
+typedef struct _notification_view notification_view;
+
+/**
+ * @brief      Create notification view
+ * @since_tizen 3.0 
+ * @param[in]  navi Parent naviframe
+ * @param[in]  custom structute to hold tbt application information
+ * @param[in]  item of the main tbt menu
+ * @return     Pointer of notification on success, otherwise NULL
+ */
+notification_view *notification_view_add(Evas_Object *navi, tbt_info *tbt_info, Elm_Object_Item *item);
+
+#endif
+#endif // __TBT_NOTIFICATION_VIEW_H__
diff --git a/tbtcoreapp/inc/view/tbt-package-manager-view.h b/tbtcoreapp/inc/view/tbt-package-manager-view.h
new file mode 100644 (file)
index 0000000..e9169df
--- /dev/null
@@ -0,0 +1,58 @@
+/*******************************************************************************
+ * Copyright (c) 2014 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.
+ *
+ *******************************************************************************/
+/**
+ * @file       tbt-packagemanager-view.h
+ * @brief      retrieves packagemanager info
+ * @since_tizen 3.0
+ * @author     Nibha Sharma(nibha.sharma@samsung.com)
+ * @date       June, 2016
+ * @bug                none
+ * @credit
+ * @credit
+ *
+ */
+
+#ifndef __TBT_PACKAGE_MANAGER_VIEW_H__
+#define __TBT_PACKAGE_MANAGER_VIEW_H__
+
+#include "utils/app_module_config.h"
+#ifdef TBT_MODULE_PACKAGE_MANAGER
+
+#include <Evas.h>
+#include "model/tbt-list.h"
+#include <package_manager.h>
+
+
+/**
+ * @typedef packagemanager_viewer_view
+ * @since_tizen 3.0
+ * @brief A packagemanager viewer view handle.
+ */
+typedef struct _packagemanager_view packagemanager_view;
+
+/**
+ * @brief      Create packagemanager view
+ * @since_tizen 3.0 
+ * @param[in]  navi Parent naviframe
+ * @param[in]  custom structute to hold tbt application information
+ * @param[in]  item of the main tbt menu
+ * @return     Pointer of packagemanager on success, otherwise NULL
+ */
+packagemanager_view *packagemanager_view_add(Evas_Object *navi, tbt_info *tbt_info, Elm_Object_Item *item);
+
+#endif
+#endif // __TBT_PACKAGE_MANAGER_VIEW_H__
diff --git a/tbtcoreapp/inc/view/tbt-sound-manager-view.h b/tbtcoreapp/inc/view/tbt-sound-manager-view.h
new file mode 100644 (file)
index 0000000..393d378
--- /dev/null
@@ -0,0 +1,58 @@
+/*******************************************************************************
+ * Copyright (c) 2014 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.
+ *
+ *******************************************************************************/
+/**
+ * @file       tbt-soundmanager-view.h
+ * @brief      retrieves soundmanager info
+ * @since_tizen 2.3
+ * @author     A. B. M. Nazibullah(nazib.ullah@samsung.com)
+ * @date       October, 2014
+ * @bug                none
+ * @credit
+ * @credit
+ *
+ */
+
+#ifndef __TBT_SOUND_MANAGER_VIEW_H__
+#define __TBT_SOUND_MANAGER_VIEW_H__
+
+#include "utils/app_module_config.h"
+#ifdef TBT_MODULE_SOUND_MANAGER
+
+#include <Evas.h>
+#include "model/tbt-list.h"
+#include <sound_manager.h>
+
+
+/**
+ * @typedef soundmanager_viewer_view
+ * @since_tizen 2.3
+ * @brief A soundmanager viewer view handle.
+ */
+typedef struct _soundmanager_view soundmanager_view;
+
+/**
+ * @brief Create soundmanager view
+ * @since_tizen 2.3 
+ * @param[in] navi Parent naviframe
+ * @param[in] custom structute to hold tbt application information
+ * @param[in] item of the main tbt menu
+ * @return Pointer of runtimeinfo on success, otherwise NULL
+ */
+soundmanager_view *soundmanager_view_add(Evas_Object *navi, tbt_info *tbt_info, Elm_Object_Item *item);
+
+#endif
+#endif // __TBT_SOUND_MANAGER_VIEW_H__
index 447e4f4898241512f101d7724a2cc0199611bd75..b5b7b4159fc525c6aefce132dff7f61027bda3c0 100755 (executable)
@@ -107,6 +107,7 @@ BuildRequires: pkgconfig(nsd-ssdp)
 BuildRequires: pkgconfig(capi-network-mtp)
 BuildRequires: pkgconfig(ecore-wayland)
 BuildRequires: pkgconfig(efl)
+BuildRequires: pkgconfig(capi-system-media-key)
 
 %description
 Platform Project
@@ -173,6 +174,8 @@ chsmack -a %{name} %{_resdir}
 %{_resdir}/images/YUV/*.raw
 %{_resdir}/images/AGIF/*.gif
 
+%{_resdir}/package/*.tpk
+
 %{_resdir}/sounds/*.raw
 %{_resdir}/sounds/*.aac
 %{_resdir}/sounds/*.amr
diff --git a/tbtcoreapp/res/edje/3.0/mobile/connection_viewer.edc b/tbtcoreapp/res/edje/3.0/mobile/connection_viewer.edc
new file mode 100755 (executable)
index 0000000..262c622
--- /dev/null
@@ -0,0 +1,39 @@
+/*
+ * Copyright (c) 2014 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#define TEXT_HEIGHT 0.08
+
+collections
+{
+    base_scale: 1.8;
+    group
+    {
+        name: "connection_viewer";
+        parts{                 
+            part{
+                name: "connection_view";
+                type: SWALLOW;
+                description{
+                    state: "default" 0.0;
+                    align: 0.0 0.0;
+                    visible: 1;
+                    rel1 {relative: 0.0 0.0; }
+                    rel2 {relative: 1.0 TEXT_HEIGHT; }
+                }
+            }
+        }
+    }
+}
diff --git a/tbtcoreapp/res/edje/3.0/mobile/mediakey_viewer.edc b/tbtcoreapp/res/edje/3.0/mobile/mediakey_viewer.edc
new file mode 100644 (file)
index 0000000..d4b9be3
--- /dev/null
@@ -0,0 +1,51 @@
+/*
+ * Copyright (c) 2014 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#define TEXT_HEIGHT 0.08
+
+collections
+{
+    base_scale: 1.8;
+    group
+    {
+        name: "mediakey_viewer";
+        parts{
+            part{
+                name: "media_text";
+                type: SWALLOW;
+                description{
+                    state: "default" 0.0;
+                    align: 0.0 0.0;
+                    visible: 1;
+                    rel1 {relative: 0.0 0.0; }
+                    rel2 {relative: 1.0 TEXT_HEIGHT; }
+                       }
+                }
+           part{
+                name: "media_key";
+                type: SWALLOW;
+                description{
+                    state: "default" 0.0;
+                    align: 0.0 0.0;
+                    visible: 1;
+                    rel1 {relative: 0.0 TEXT_HEIGHT; }
+                    rel2 {relative: 1.0 2*TEXT_HEIGHT; }
+                       }
+                }
+               
+        }
+    }
+}
diff --git a/tbtcoreapp/res/edje/3.0/mobile/notification_viewer.edc b/tbtcoreapp/res/edje/3.0/mobile/notification_viewer.edc
new file mode 100644 (file)
index 0000000..58bd2a0
--- /dev/null
@@ -0,0 +1,50 @@
+/*
+ * Copyright (c) 2014 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#define TEXT_HEIGHT 0.08
+
+collections
+{
+    base_scale: 1.8;
+    group
+    {
+        name: "notification_viewer";
+        parts{
+            part{
+                name: "notification_text";
+                type: SWALLOW;
+                description{
+                    state: "default" 0.0;
+                    align: 0.0 0.0;
+                    visible: 1;
+                    rel1 {relative: 0.0 0.0; }
+                    rel2 {relative: 1.0 TEXT_HEIGHT; }
+                       }
+                }
+          /* part{
+                name: "packagemanager_state";
+                type: SWALLOW;
+                description{
+                    state: "default" 0.0;
+                    align: 0.0 0.0;
+                    visible: 1;
+                    rel1 {relative: 0.0 TEXT_HEIGHT; }
+                    rel2 {relative: 1.0 2*TEXT_HEIGHT; }
+                       }
+                }*/
+        }
+    }
+}
diff --git a/tbtcoreapp/res/edje/3.0/mobile/package_manager_viewer.edc b/tbtcoreapp/res/edje/3.0/mobile/package_manager_viewer.edc
new file mode 100644 (file)
index 0000000..96c5537
--- /dev/null
@@ -0,0 +1,50 @@
+/*
+ * Copyright (c) 2014 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#define TEXT_HEIGHT 0.08
+
+collections
+{
+    base_scale: 1.8;
+    group
+    {
+        name: "package_manager_viewer";
+        parts{
+            part{
+                name: "packagemanager_text";
+                type: SWALLOW;
+                description{
+                    state: "default" 0.0;
+                    align: 0.0 0.0;
+                    visible: 1;
+                    rel1 {relative: 0.0 0.0; }
+                    rel2 {relative: 1.0 TEXT_HEIGHT; }
+                       }
+                }
+           part{
+                name: "packagemanager_state";
+                type: SWALLOW;
+                description{
+                    state: "default" 0.0;
+                    align: 0.0 0.0;
+                    visible: 1;
+                    rel1 {relative: 0.0 TEXT_HEIGHT; }
+                    rel2 {relative: 1.0 2*TEXT_HEIGHT; }
+                       }
+                }
+        }
+    }
+}
diff --git a/tbtcoreapp/res/edje/3.0/mobile/sound_manager_viewer.edc b/tbtcoreapp/res/edje/3.0/mobile/sound_manager_viewer.edc
new file mode 100644 (file)
index 0000000..b005247
--- /dev/null
@@ -0,0 +1,39 @@
+/*
+ * Copyright (c) 2014 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#define TEXT_HEIGHT 0.08
+
+collections
+{
+    base_scale: 1.8;
+    group
+    {
+        name: "sound_manager_viewer";
+        parts{
+            part{
+                name: "sound_manager_text";
+                type: SWALLOW;
+                description{
+                    state: "default" 0.0;
+                    align: 0.0 0.0;
+                    visible: 1;
+                    rel1 {relative: 0.0 0.0; }
+                    rel2 {relative: 1.0 TEXT_HEIGHT; }
+                       }
+                }
+        }
+    }
+}
diff --git a/tbtcoreapp/res/package/native-testapp-itc-1.0.0-arm.tpk b/tbtcoreapp/res/package/native-testapp-itc-1.0.0-arm.tpk
new file mode 100755 (executable)
index 0000000..54c0270
Binary files /dev/null and b/tbtcoreapp/res/package/native-testapp-itc-1.0.0-arm.tpk differ
index 98c9c0174c3bb130b1e7a13f9745241c4f340d5c..5bb6e789d1a0004208d74cb89342254fed884722 100644 (file)
@@ -502,7 +502,7 @@ static tbt_info tbtapps[] =
                        .parent = "NFC",
                        .apptype = TBT_APP_NFC_TAG,
                        .icon_name = "dummy",
-                       .info = "Test NFC tag",
+                       .info = "1. Please Touch NFC Tag with Phone it shows nfc attach<br/>2.Now remove phone from the nfc tag it shows nfc detach",
                        .result = 0,
                        .required_features_count = 2,
                        .features_required = {17,77}
@@ -518,7 +518,7 @@ static tbt_info tbtapps[] =
                        .parent = "NFC",
                        .apptype = TBT_APP_NFC_P2P,
                        .icon_name = "dummy",
-                       .info = "Test NFC P2P",
+                       .info = "1. Please Touch One phone with other Phone it shows nfc attach<br/>2.Now remove phone from each other it shows nfc detach",
                        .result = 0,
                        .required_features_count = 2,
                        .features_required = {17,76}
@@ -1533,6 +1533,138 @@ static tbt_info tbtapps[] =
                        .result = 0,
                        .required_features_count = 1,
                        .features_required = {6}
+               },
+       #endif
+#endif
+#ifdef TBT_MODULE_SOUND_MANAGER
+       #ifdef TBT_MODULE_APP_SOUND_MANAGER
+
+               //SOUND_MANAGER
+               {
+                       .name = "Connection Status",
+                       .parent = "Sound Manager",
+                       .apptype = TBT_APP_SOUND_MANAGER,
+                       .icon_name = "dummy",
+                       .info = "Insert/Remove Audio jack",
+                       .result = 0,
+                       .required_features_count = 1,
+                       .features_required = {13}
+               },
+       #endif
+       #ifdef TBT_MODULE_APP_SOUND_MANAGER_DEVICE
+
+               //SOUND_MANAGER
+               {
+                       .name = "Device Status",
+                       .parent = "Sound Manager",
+                       .apptype = TBT_APP_SOUND_MANAGER_DEVICE,
+                       .icon_name = "dummy",
+                       .info = "Insert Audio jack and change sound profile to Sound",
+                       .result = 0,
+                       .required_features_count = 1,
+                       .features_required = {13}
+               },
+       #endif
+#endif
+#ifdef TBT_MODULE_MEDIA_KEY
+       #ifdef TBT_MODULE_APP_MEDIA_KEY
+
+               //Media Key
+               {
+                       .name = "Media Key",
+                       .parent = "Media Key",
+                       .apptype = TBT_APP_MEDIA_KEY,
+                       .icon_name = "dummy",
+                       .info = "Press Media Key eg:Audio Jack Key",
+                       .result = 0
+               },
+       #endif
+#endif
+#ifdef TBT_MODULE_PACKAGE_MANAGER
+       #ifdef TBT_MODULE_APP_PACKAGE_MANAGER
+
+               //Package Manager
+               {
+                       .name = "Package Manager",
+                       .parent = "Package Manager Status",
+                       .apptype = TBT_APP_PACKAGE_MANAGER,
+                       .icon_name = "dummy",
+                       .info = "1.Please Uninstall package from Application manager<br/>2. Please install package in device from sdb shell<br/> 3.Update is re-install same package on the device",
+                       .result = 0
+               },
+       #endif
+#endif
+#ifdef TBT_MODULE_NOTIFICATION
+       #ifdef TBT_MODULE_APP_NOTIFICATION
+
+               //Notification
+               {
+                       .name = "Notification Text",
+                       .parent = "Notification Status",
+                       .apptype = TBT_APP_NOTIFICATION_TEXT,
+                       .icon_name = "dummy",
+                       .info = "Notification is updated",
+                       .result = 0,
+                       .required_features_count = 1,
+                       .features_required = {80}
+               },
+       #endif
+       #ifdef TBT_MODULE_APP_NOTIFICATION_TIME
+
+               //Notification
+               {
+                       .name = "Notification Time",
+                       .parent = "Notification Status",
+                       .apptype = TBT_APP_NOTIFICATION_TIME,
+                       .icon_name = "dummy",
+                       .info = "Notification is updated",
+                       .result = 0,
+                       .required_features_count = 1,
+                       .features_required = {80}
+               },
+       #endif
+       #ifdef TBT_MODULE_APP_NOTIFICATION_TITLE
+
+               //Notification
+               {
+                       .name = "Notification Title",
+                       .parent = "Notification Status",
+                       .apptype = TBT_APP_NOTIFICATION_TITLE,
+                       .icon_name = "dummy",
+                       .info = "Notification is updated",
+                       .result = 0,
+                       .required_features_count = 1,
+                       .features_required = {80}
+               },
+       #endif
+       #ifdef TBT_MODULE_APP_NOTIFICATION_IMAGE
+
+               //Notification
+               {
+                       .name = "Notification Image",
+                       .parent = "Notification Status",
+                       .apptype = TBT_APP_NOTIFICATION_IMAGE,
+                       .icon_name = "dummy",
+                       .info = "Notification is updated",
+                       .result = 0,
+                       .required_features_count = 1,
+                       .features_required = {80}
+               },
+       #endif
+#endif
+#ifdef TBT_MODULE_CONNECTION
+       #ifdef TBT_MODULE_APP_CONNECTION
+
+               //Connection
+               {
+                       .name = "Connection",
+                       .parent = "Connection Status",
+                       .apptype = TBT_APP_CONNECTION,
+                       .icon_name = "dummy",
+                       .info = "1.Please Change connection status to flight mode or some other mode<br/>2.Please press back button and again open connection view<br/>3.You will see updated connection status<br/>",
+                       .result = 0,
+                       .required_features_count = 2,
+                       .features_required = {24,21}
                }
        #endif
 #endif
index cb396b5581baaf37cc2f6d754a88e6d5490a2c37..ee96bcbf286a670c54c40ffea8c65113efc72cf0 100644 (file)
 #define PART_POPUP_BUTTON3      "button3"
 #define STYLE_POPUP_BUTTON      "popup_button/default"
 
+/**
+ * @function           guide_pop_up_button_callback
+ * @since_tizen                3.0
+ * @description                Callback for OK press by user
+ * @parameter          void *data, Evas_Object *obj, void *event_info
+ * @return                     void
+ */
+static void guide_pop_up_button_callback(void *data, Evas_Object *obj, void *event_info)
+{
+    RETM_IF(NULL == data, "data is null");
+
+    Evas_Object *obj_to_del = data;
+    evas_object_del(obj_to_del);
+
+    if(event_info)
+    {
+        Elm_Object_Item *item = event_info;
+        elm_genlist_item_selected_set(item, EINA_FALSE);
+    }
+}
+
 /**
 * @function            DoesFeatureExixts
 * @description         Checks if a particular feature exists or not
@@ -435,3 +456,21 @@ void ui_utils_show_toast(const char* message, const Evas_Object* data, float tim
        elm_popup_timeout_set(popup, timeout);
        evas_object_show(popup);
 }
+
+/**
+ * @function           ui_utils_guide_instruction_popup_button
+ * @since_tizen                3.0
+ * @description                Pop up Manual Instruction Button
+ * @parameter          common_view*: Common View Pointer, const char* txtMessage: Instruction Message to render
+ * @return             static void
+ */
+void ui_utils_guide_instruction_popup_button(const Evas_Object* view, const char* txtInstruction)
+{
+    RETM_IF(NULL == view, "view is NULL");
+
+    Evas_Object *guide_popup_btn = ui_utils_popup_add(view, "Instruction Guide");
+    RETM_IF(NULL == guide_popup_btn, "guide_popup_btn is NULL");
+
+    elm_object_text_set(guide_popup_btn, txtInstruction);
+    ui_utils_popup_button_add(guide_popup_btn, caption_ok, guide_pop_up_button_callback, guide_popup_btn);
+}
diff --git a/tbtcoreapp/src/view/tbt-connection-view.c b/tbtcoreapp/src/view/tbt-connection-view.c
new file mode 100755 (executable)
index 0000000..8063a86
--- /dev/null
@@ -0,0 +1,269 @@
+/*******************************************************************************
+ * Copyright (c) 2014 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.
+ *******************************************************************************/
+/**
+ * @file       tbt-connection-view.c
+ * @brief      retrieves connection info
+ *
+ * @author     Nibha Sharma(nibha.sharma@samsung.com)
+ * @date       June, 2016
+ * @bug                NA
+ * @credit     
+ *
+ */
+
+#include "utils/app_module_config.h"
+#ifdef TBT_MODULE_CONNECTION
+
+#include <Elementary.h>
+#include <system_info.h>
+
+#include "utils/logger.h"
+#include "utils/config.h"
+#include "utils/ui-utils.h"
+#include "view/tbt-connection-view.h"
+#include "view/tbt-common-view.h"
+#include <net_connection.h>
+
+struct _connection_view
+{
+       common_view* view;
+
+    Evas_Object *connection_label;
+    Evas_Object *capture_btn;
+};
+connection_h g_hConenctionHandle = NULL;
+static char* get_connection_error(connection_error_e err_code);
+static void _app_destroy_cb(void* this);
+static bool is_not_supported = false;
+
+/**
+ * @function           connection_view_add
+ * @since_tizen                3.0
+ * @description                connection View Add
+ * @parameter          Evas_Object*: Evas Object Pointer, tbt_info*: Tbt Info Pointer, Elm_Object_Item*: Elm Object Item Pointer
+ * @return             connection_view*
+ */
+connection_view *connection_view_add(Evas_Object *navi, tbt_info *tbt_info, Elm_Object_Item *item)
+{
+       RETVM_IF(NULL == navi, NULL, "navi is null");
+
+       connection_view *this = NULL;
+        this = calloc(1, sizeof(connection_view));
+       RETVM_IF(!this, NULL, "calloc failed");
+       this->view = calloc(1, sizeof(common_view));
+       RETVM_IF(!this->view, NULL, "calloc failed");
+
+       tbt_info->layout_group = "connection_viewer";
+       tbt_info->layout_file = get_edje_path("connection_viewer.edj");
+
+       common_view_add(navi, tbt_info, item, this->view, _app_destroy_cb, this);
+       RETVM_IF(!this, NULL, "calloc failed");
+       RETVM_IF(NULL == this->view, NULL, "navi is null");
+
+       this->connection_label = ui_utils_label_add(this->view->layout, "");
+       elm_label_line_wrap_set(this->connection_label, ELM_WRAP_WORD);
+       int result;
+
+       connection_profile_iterator_h profile_iter;
+       connection_profile_type_e eConnectionProfileType;
+       connection_profile_h profile_h = NULL;
+
+       ui_utils_guide_instruction_popup_button(navi, "1.Please Change connection status to flight mode or some other mode<br/>2.Please press back button and again open connection view<br/>3.You will see updated connection status<br/><b>Note:You can also refer info section</b>");
+       
+       result = connection_create(&g_hConenctionHandle);
+       RETVM_IF(result != CONNECTION_ERROR_NONE && result!= CONNECTION_ERROR_NOT_SUPPORTED, NULL, "connection_create fail > Error = %s", get_connection_error(result));
+       
+       if(result == CONNECTION_ERROR_NOT_SUPPORTED)
+       {
+               is_not_supported = true;
+               Evas_Object *popup = ui_utils_popup_add(this->view->navi, "Message");
+               elm_object_text_set(popup, "Connection is not supported");
+               RETVM_IF(!this->view, NULL,"Connection is not supported");
+       }
+       if(g_hConenctionHandle != NULL)
+       {
+                       result = connection_get_profile_iterator(g_hConenctionHandle, CONNECTION_ITERATOR_TYPE_REGISTERED, &profile_iter);
+                       RETVM_IF(result != CONNECTION_ERROR_NONE, NULL, "connection_create fail > Error = %s", get_connection_error(result));
+
+                       while ( connection_profile_iterator_has_next(profile_iter) )
+                       {
+                               result = connection_profile_iterator_next(profile_iter, &profile_h);
+                               RETVM_IF(result != CONNECTION_ERROR_NONE, NULL, "connection_create fail > Error = %s", get_connection_error(result));
+
+                               result = connection_profile_get_type(profile_h, &eConnectionProfileType);
+                               RETVM_IF(result != CONNECTION_ERROR_NONE, NULL, "connection_create fail > Error = %s", get_connection_error(result));
+
+                               if ( eConnectionProfileType == CONNECTION_PROFILE_TYPE_CELLULAR )
+                               {
+                                       break;
+                               }
+                       }
+               
+       
+               if ( eConnectionProfileType == CONNECTION_PROFILE_TYPE_CELLULAR )
+               {
+                       connection_cellular_state_e eFindCellularState = -1;
+
+               result = connection_get_cellular_state(g_hConenctionHandle, &eFindCellularState);
+               RETVM_IF(result != CONNECTION_ERROR_NONE, NULL, "connection_get_cellular_state fail > Error = %s", get_connection_error(result));
+
+                       switch(eFindCellularState)
+                       {
+                               case CONNECTION_CELLULAR_STATE_OUT_OF_SERVICE:
+                                       ui_utils_label_set_text(this->connection_label, "Out of service ", "left");
+                                       break;
+
+                               case CONNECTION_CELLULAR_STATE_FLIGHT_MODE:
+                                       ui_utils_label_set_text(this->connection_label, "Flight mode ", "left");
+                                       break;
+
+                               case CONNECTION_CELLULAR_STATE_ROAMING_OFF:
+                                       ui_utils_label_set_text(this->connection_label, "Roaming is turned off ", "left");
+                                       break;
+                       
+                               case CONNECTION_CELLULAR_STATE_CALL_ONLY_AVAILABLE:
+                                       ui_utils_label_set_text(this->connection_label, "Call is only available  ", "left");
+                                       break;
+                       
+                               case CONNECTION_CELLULAR_STATE_AVAILABLE:
+                                       ui_utils_label_set_text(this->connection_label, "Available but not connected yet  ", "left");
+                                       break;
+                       
+                               case CONNECTION_CELLULAR_STATE_CONNECTED:
+                                       ui_utils_label_set_text(this->connection_label, "Connected ", "left");
+                                       break;
+
+                               default:
+                                       ui_utils_label_set_text(this->connection_label, "Unknown status", "left");
+                                       break;
+
+                       }
+               }
+               else
+               {
+                       ui_utils_label_set_text(this->connection_label, "Profile is not cellular type", "left");
+               }
+       }
+               
+       else
+       {
+               ui_utils_label_set_text(this->connection_label, "Connection is not created", "left");
+       }
+
+       elm_object_part_content_set(this->view->layout, "connection_view", this->connection_label);
+       return this;
+}
+
+/**
+ * @function           _app_destroy_cb
+ * @since_tizen                2.3
+ * @description                 App Destroy Cb
+ * @parameter          void*: Void Pointer
+ * @return             static void
+ */
+static void _app_destroy_cb(void* this)
+{
+       RETM_IF(NULL == this, "data is NULL");
+
+       int result;
+       connection_view *view = NULL;
+       view = (connection_view*)this;
+       RETM_IF(NULL == view, "view is NULL");
+
+       if(is_not_supported == true)
+       {
+               view->view->tbt_info->result = TBT_INFO_RESULT_NOT_SUPPORTED;
+               elm_genlist_item_update(view->view->item);
+       }
+
+       result = connection_destroy(g_hConenctionHandle);
+        RETM_IF(result != CONNECTION_ERROR_NONE, "connection_destroy fail > Error = %s", get_connection_error(result));
+       
+       SAFE_DELETE(view->view);
+       SAFE_DELETE(view);
+}
+
+/**
+ * @function           get_connection_error
+ * @since_tizen                3.0
+ * @description                Get connection Error
+ * @parameter          connection_error_e err_code
+ * @return             char*
+ */
+static char* get_connection_error(connection_error_e err_code)
+{
+       char* err_msg;
+
+       switch (err_code) {
+       case CONNECTION_ERROR_NONE:
+               err_msg = "CONNECTION_ERROR_NONE";
+               break;
+       case CONNECTION_ERROR_INVALID_PARAMETER:
+               err_msg = "CONNECTION_ERROR_INVALID_PARAMETER";
+               break;
+       case CONNECTION_ERROR_OUT_OF_MEMORY:
+               err_msg = "CONNECTION_ERROR_OUT_OF_MEMORY";
+               break;
+       case CONNECTION_ERROR_INVALID_OPERATION:
+               err_msg = "CONNECTION_ERROR_INVALID_OPERATION";
+               break;
+       case CONNECTION_ERROR_ADDRESS_FAMILY_NOT_SUPPORTED:
+               err_msg = "CONNECTION_ERROR_ADDRESS_FAMILY_NOT_SUPPORTED";
+               break;
+       case CONNECTION_ERROR_OPERATION_FAILED:
+               err_msg = "CONNECTION_ERROR_OPERATION_FAILED";
+               break;
+       case CONNECTION_ERROR_ITERATOR_END:
+               err_msg = "CONNECTION_ERROR_ITERATOR_END";
+               break;
+       case CONNECTION_ERROR_NO_CONNECTION:
+               err_msg = "CONNECTION_ERROR_NO_CONNECTION";
+               break;
+       case CONNECTION_ERROR_NOW_IN_PROGRESS:
+               err_msg = "CONNECTION_ERROR_NOW_IN_PROGRESS";
+               break;
+       case CONNECTION_ERROR_ALREADY_EXISTS:
+               err_msg = "CONNECTION_ERROR_ALREADY_EXISTS";
+               break;
+       case CONNECTION_ERROR_OPERATION_ABORTED:
+               err_msg = "CONNECTION_ERROR_OPERATION_ABORTED";
+               break;
+       case CONNECTION_ERROR_DHCP_FAILED:
+               err_msg = "CONNECTION_ERROR_DHCP_FAILED";
+               break;
+       case CONNECTION_ERROR_INVALID_KEY:
+               err_msg = "CONNECTION_ERROR_INVALID_KEY";
+               break;
+       case CONNECTION_ERROR_NO_REPLY:
+               err_msg = "CONNECTION_ERROR_NO_REPLY";
+               break;
+       case CONNECTION_ERROR_PERMISSION_DENIED:
+               err_msg = "CONNECTION_ERROR_PERMISSION_DENIED";
+               break;
+       case CONNECTION_ERROR_NOT_SUPPORTED:
+               err_msg = "CONNECTION_ERROR_NOT_SUPPORTED";
+               break;
+       default:
+               err_msg = "Unknown Error";
+               break;
+
+       }
+       return err_msg;
+}
+
+
+
+#endif
index aa5c7d07f8c8d230d762551f42c41f8306b49ba1..0181d20c0e29e33872a2c2dd558c66455465e587 100644 (file)
 #include "view/tbt-nsd-ssdp-view.h"
 #include "view/tbt-storage-view.h"
 #include "view/tbt-radio-view.h"
+#include "view/tbt-sound-manager-view.h"
+#include "view/tbt-media-key-view.h"
+#include "view/tbt-package-manager-view.h"
+#include "view/tbt-notification-view.h"
+#include "view/tbt-connection-view.h"
 
 typedef struct
 {
@@ -973,8 +978,43 @@ static void _gl_item_selected_cb(void *data, Evas_Object *obj EINA_UNUSED, void
                                radio_view_add(view->navi, info, it);
                                break;
                #endif
-
-
+               #ifdef TBT_MODULE_SOUND_MANAGER
+                       case TBT_APP_SOUND_MANAGER:
+                               soundmanager_view_add(view->navi, info, it);
+                               break;
+                       case TBT_APP_SOUND_MANAGER_DEVICE:
+                               soundmanager_view_add(view->navi, info, it);
+                               break;
+               #endif
+               #ifdef TBT_MODULE_MEDIA_KEY
+                       case TBT_APP_MEDIA_KEY:
+                               mediakey_view_add(view->navi, info, it);
+                               break;
+               #endif
+               #ifdef TBT_MODULE_PACKAGE_MANAGER
+                       case TBT_APP_PACKAGE_MANAGER:
+                               packagemanager_view_add(view->navi, info, it);
+                               break;
+               #endif
+               #ifdef TBT_MODULE_NOTIFICATION
+                       case TBT_APP_NOTIFICATION_TEXT:
+                               notification_view_add(view->navi, info, it);
+                               break;
+                       case TBT_APP_NOTIFICATION_TIME:
+                               notification_view_add(view->navi, info, it);
+                               break;
+                       case TBT_APP_NOTIFICATION_TITLE:
+                               notification_view_add(view->navi, info, it);
+                               break;
+                       case TBT_APP_NOTIFICATION_IMAGE:
+                               notification_view_add(view->navi, info, it);
+                               break;
+               #endif
+               #ifdef TBT_MODULE_CONNECTION
+                       case TBT_APP_CONNECTION:
+                               connection_view_add(view->navi, info, it);
+                               break;
+               #endif
                default:
                        assert(false);
                        break;
diff --git a/tbtcoreapp/src/view/tbt-media-key-view.c b/tbtcoreapp/src/view/tbt-media-key-view.c
new file mode 100644 (file)
index 0000000..3386f99
--- /dev/null
@@ -0,0 +1,218 @@
+/*******************************************************************************
+ * Copyright (c) 2014 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.
+ *******************************************************************************/
+/**
+ * @file       tbt-mediakey-view.c
+ * @brief      retrieves mediakey info
+ *
+ * @author     Nibha Sharma(nibha.sharma@samsung.com)
+ * @date       June, 2016
+ * @bug                none
+ * @credit
+ *
+ */
+#include "utils/app_module_config.h"
+#ifdef TBT_MODULE_MEDIA_KEY
+
+#include <Elementary.h>
+#include <locations.h>
+
+#include "utils/logger.h"
+#include "utils/config.h"
+#include "utils/ui-utils.h"
+#include "view/tbt-media-key-view.h"
+#include "view/tbt-common-view.h"
+
+struct _mediakey_view
+{
+       common_view* view;
+
+       Evas_Object *mediakey_label;
+       Evas_Object *mediakey2_label;
+       
+};
+
+static void _app_destroy_cb(void* this);
+static void _media_key_event_cb(media_key_e key, media_key_event_e status, void *user_data);
+
+/**
+ * @function           get_mediakey_type_error
+ * @since_tizen                3.0
+ * @description                Get mediakey Error
+ * @parameter          int: Int
+ * @return             char*
+ */
+char* get_mediakey_type_error(int ret)
+{
+       char* err_msg = NULL;
+       switch (ret) {
+       case MEDIA_KEY_ERROR_NONE:
+               err_msg = "MEDIA_KEY_ERROR_NONE";
+               break;
+       case MEDIA_KEY_ERROR_INVALID_PARAMETER:
+               err_msg = "MEDIA_KEY_ERROR_INVALID_PARAMETER";
+               break;
+       case MEDIA_KEY_ERROR_OPERATION_FAILED:
+               err_msg = "MEDIA_KEY_ERROR_OPERATION_FAILED";
+               break;
+       default:
+               err_msg = "Unknown Error";
+               break;
+       }
+
+       return err_msg;
+}
+
+/**
+ * @function           mediakey_view_add
+ * @since_tizen                3.0
+ * @description                mediakey View Add
+ * @parameter          Evas_Object*: Evas Object Pointer, tbt_info*: Tbt Info Pointer, Elm_Object_Item*: Elm Object Item Pointer
+ * @return             mediakey_view*
+ */
+mediakey_view *mediakey_view_add(Evas_Object *navi, tbt_info *tbt_info, Elm_Object_Item *item)
+{
+       RETVM_IF(NULL == navi, NULL, "navi is null");
+       int ret;
+       mediakey_view *this = NULL;
+       this = calloc(1, sizeof(mediakey_view));
+       RETVM_IF(!this, NULL, "calloc failed");
+
+       this->view = calloc(1, sizeof(common_view));
+       RETVM_IF(!this->view, NULL, "calloc failed");
+
+       tbt_info->layout_group = "mediakey_viewer";
+       tbt_info->layout_file = get_edje_path("mediakey_viewer.edj");
+
+       common_view_add(navi, tbt_info, item, this->view, _app_destroy_cb, this);
+       RETVM_IF(NULL == this->view, NULL, "navi is null");     
+
+       ui_utils_guide_instruction_popup_button(navi, "1.Please Insert Audio Jack with media key button<br/>2.Press that key and you can see media key status changes<br/><b>Note:You can also refer info section</b>");
+       
+       ret = media_key_reserve(_media_key_event_cb,this);
+       RETVM_IF(ret != MEDIA_KEY_ERROR_NONE, NULL, "media_key_reserve failed : %s", get_mediakey_type_error(ret));
+                
+       this->mediakey_label = ui_utils_label_add(this->view->layout, "Media Key Status[Press audiojack key] ");
+       elm_label_line_wrap_set(this->mediakey_label, ELM_WRAP_WORD);
+
+       this->mediakey2_label = ui_utils_label_add(this->view->layout, "Media Key Type[Press audiojack key]");
+       elm_label_line_wrap_set(this->mediakey2_label, ELM_WRAP_WORD);
+       
+       elm_object_part_content_set(this->view->layout, "media_text", this->mediakey_label);
+       elm_object_part_content_set(this->view->layout, "media_key", this->mediakey2_label);
+
+    return this;
+}
+
+
+/**
+ * @function           _app_destroy_cb
+ * @since_tizen                2.3
+ * @description                App Destroy Cb
+ * @parameter          void*: Void Pointer
+ * @return             static void
+ */
+static void _app_destroy_cb(void* this)
+{
+
+       RETM_IF(NULL == this, "data is NULL");
+
+       int result;
+       mediakey_view *view = NULL;
+       view = (mediakey_view*)this;
+       RETM_IF(NULL == view, "view is NULL");
+
+       result = media_key_release();
+       RETM_IF(MEDIA_KEY_ERROR_NONE!=result, "media_key_release failed:%s", get_mediakey_type_error(result));
+
+       SAFE_DELETE(view->view);
+       SAFE_DELETE(view);
+}
+
+
+/**
+ * @function           _media_key_event_cb
+ * @since_tizen                3.0
+ * @description                media key event Cb
+ * @parameter          media_key_e key, media_key_event_e status, void *user_data
+ * @return             void
+ */
+static void _media_key_event_cb(media_key_e key, media_key_event_e status, void *user_data)
+{
+
+       RETM_IF(NULL == user_data, "user_data is null");
+       mediakey_view *this = NULL;
+       this = (mediakey_view*) user_data;
+       RETM_IF(NULL == this, "view is NULL");
+
+       DBG("value: %d", status);
+
+       switch (status) 
+       {
+               case MEDIA_KEY_STATUS_PRESSED:
+                               ui_utils_label_set_text(this->mediakey_label, "Pressed status", "left");
+                               break;
+               case MEDIA_KEY_STATUS_RELEASED:
+                               ui_utils_label_set_text(this->mediakey_label, "Released status", "left");
+                               break;
+               case MEDIA_KEY_STATUS_UNKNOWN:
+                               ui_utils_label_set_text(this->mediakey_label, "Unknown status", "left");
+                               break;
+               default:
+                       ui_utils_label_set_text(this->mediakey_label, "unknown state", "left");
+                       break;
+       }
+       
+       DBG("value: %d", key);
+       switch (key) 
+       {
+               case MEDIA_KEY_PLAY:
+                               ui_utils_label_set_text(this->mediakey2_label, "Play key", "left");
+                               break;
+               case MEDIA_KEY_STOP:
+                               ui_utils_label_set_text(this->mediakey2_label, "Stop key", "left");
+                               break;
+               case MEDIA_KEY_PAUSE:
+                               ui_utils_label_set_text(this->mediakey2_label, "Pause key", "left");
+                               break;
+               case MEDIA_KEY_PREVIOUS:
+                               ui_utils_label_set_text(this->mediakey2_label, "Previous key", "left");
+                               break;
+               case MEDIA_KEY_NEXT:
+                               ui_utils_label_set_text(this->mediakey2_label, "Next key", "left");
+                               break;
+               case MEDIA_KEY_FASTFORWARD:
+                               ui_utils_label_set_text(this->mediakey2_label, "Fastforward key", "left");
+                               break;
+               case MEDIA_KEY_REWIND:
+                               ui_utils_label_set_text(this->mediakey2_label, "Rewind key", "left");
+                               break;
+               case MEDIA_KEY_PLAYPAUSE:
+                               ui_utils_label_set_text(this->mediakey2_label, "Playpause key", "left");
+                               break;
+               case MEDIA_KEY_MEDIA:
+                               ui_utils_label_set_text(this->mediakey2_label, "Media key for earjack", "left");
+                               break;
+               case MEDIA_KEY_UNKNOWN:
+                               ui_utils_label_set_text(this->mediakey2_label, "Unknown key", "left");
+                               break;
+               default:
+                       ui_utils_label_set_text(this->mediakey_label, "unknown state", "left");
+                       break;
+       }
+       return ;
+}
+
+#endif
index 36fe25c347a1542bc0595f9cb10fdf10f027c683..883db6788a29f70cd62e614c6e94d9a9f4642104 100644 (file)
@@ -118,6 +118,8 @@ nfc_view *nfc_view_add(Evas_Object *navi, tbt_info *tbt_info, Elm_Object_Item *i
 
        if(tbt_info->apptype == TBT_APP_NFC_TAG)
        {
+               ui_utils_guide_instruction_popup_button(navi, "1. Please Touch NFC Tag with Phone it shows nfc attach<br/>2.Now remove phone from the nfc tag it shows nfc detach<b>Note:You can also refer info section</b><br/>");
+
                tbt_info->layout_group = "nfc_viewer_tag";
                tbt_info->layout_file = get_edje_path("nfc_viewer.edj");
 
@@ -125,6 +127,8 @@ nfc_view *nfc_view_add(Evas_Object *navi, tbt_info *tbt_info, Elm_Object_Item *i
        }
        else if(tbt_info->apptype == TBT_APP_NFC_P2P)
        {
+               ui_utils_guide_instruction_popup_button(navi, "1. Please Touch One phone with other Phone it shows nfc attach<br/>2.Now remove phone from each other it shows nfc detach<b>Note:You can also refer info section</b><br/>");
+
                tbt_info->layout_group = "nfc_viewer_p2p";
                tbt_info->layout_file = get_edje_path("nfc_viewer.edj");
        }
@@ -377,6 +381,91 @@ switch(error_code)
        return error;
 }
 
+/**
+ * @function           get_nfc_error
+ * @since_tizen                2.3
+ * @description                Get Nfc Error
+ * @parameter          nfc_error_e: Nfc Error E
+ * @return             char*
+ */
+char* get_nfc_string_error(nfc_error_e error_code)
+{
+       char* error;
+
+switch(error_code)
+{
+       case NFC_ERROR_NONE:
+               error = "Successful";
+               break;
+       case NFC_ERROR_OUT_OF_MEMORY:
+               error = "Out of memory ";
+               break;
+       case NFC_ERROR_OPERATION_FAILED:
+               error = "Operation failed ";
+               break;
+       case NFC_ERROR_INVALID_PARAMETER:
+               error = "Invalid parameter ";
+               break;
+       case NFC_ERROR_INVALID_NDEF_MESSAGE:
+               error = "Invalid NDEF message ";
+               break;
+       case NFC_ERROR_INVALID_RECORD_TYPE:
+               error = "Invalid record type ";
+               break;
+       case NFC_ERROR_TIMED_OUT:
+               error = "Timeout error, no answer ";
+               break;
+       case NFC_ERROR_DEVICE_BUSY:
+               error = "Previous operation is not finished still busy ";
+               break;
+       case NFC_ERROR_NO_DEVICE:
+               error = "no device ";
+               break;
+       case NFC_ERROR_NOT_ACTIVATED:
+               error = "NFC is not activated ";
+               break;
+       case NFC_ERROR_NOT_SUPPORTED:
+               error = "Not supported ";
+               break;
+       case NFC_ERROR_ALREADY_ACTIVATED:
+               error = "Already activated ";
+               break;
+       case NFC_ERROR_ALREADY_DEACTIVATED:
+               error = "Already deactivated ";
+               break;
+       case NFC_ERROR_READ_ONLY_NDEF:
+               error = "Read only tag ";
+               break;
+       case NFC_ERROR_NO_SPACE_ON_NDEF:
+               error = "No enough space on tag ";
+               break;
+       case NFC_ERROR_NO_NDEF_MESSAGE:
+               error = "No NDEF Message on Tag ";
+               break;
+       case NFC_ERROR_NOT_NDEF_FORMAT:
+               error = "Not NDEF format Tag ";
+               break;
+       case NFC_ERROR_SECURITY_RESTRICTED:
+               error = "Restricted by access control ";
+               break;
+       case NFC_ERROR_PERMISSION_DENIED:
+               error = "Restricted by Smack";
+               break;
+       case NFC_ERROR_ILLEGAL_STATE:
+               error = "The state is wrong";
+               break;
+       case NFC_ERROR_NOT_INITIALIZED:
+               error = "NFC is not initialized";
+               break;
+       case NFC_ERROR_TAG_NOT_SUPPORTED:
+               error = "Tag is not supported";
+               break;
+       case NFC_ERROR_AID_ALREADY_REGISTERED:
+               error = "AID already registered";
+       }
+
+       return error;
+}
 
 /**
  * @function           _nfc_activation_changed_cb
@@ -593,7 +682,18 @@ void _nfc_tag_discovered_cb(nfc_discovered_type_e type, nfc_tag_h tag, void *use
                                elm_list_go(this->nfc_list);
                                evas_object_show(this->nfc_list);
                        }
-
+                       DBG("NFC Discovery Attach");
+                       ui_utils_label_set_text(this->nfc_label, "NFC Discovery Attach", "left");
+               }
+               else    if(type == NFC_DISCOVERED_TYPE_DETACHED)
+               {
+                         DBG("NFC Discovery Detach");
+                         this->nfc_label = ui_utils_label_add(this->view->layout,  "NFC Discovery Detach");
+                               elm_object_part_content_set(this->view->layout, "nfc_text", this->nfc_label);
+                               this->nfc_list = elm_list_add(this->view->layout);
+                               evas_object_data_set(this->nfc_list, "nfc_view", this);
+                               elm_object_part_content_set(this->view->layout, "nfc_list", this->nfc_list);
+                               ui_utils_show_toast("NFC Discovery Detach", this->view->layout, 3);
                }
        }
 }
@@ -694,28 +794,42 @@ void _nfc_p2p_target_discovered_cb(nfc_discovered_type_e type, nfc_p2p_target_h
 
        if(this->view->tbt_info->apptype == TBT_APP_NFC_P2P)
        {
-               DBG("Inside TBT_APP_NFC_P2P");
-               if(is_tab_1_clicked == true)
+               if(type == NFC_DISCOVERED_TYPE_ATTACHED)
                {
-                       DBG("Inside server");
-                       result = nfc_p2p_set_data_received_cb(this->target, _nfc_p2p_data_received_cb, this);
-//                     result = nfc_snep_register_server("default", 4, _nfc_snep_event_cb, this);
-//                     DBG("nfc_snep_register_server %s", get_nfc_error(result));
-//                     RETM_IF(result != NFC_ERROR_NONE, "nfc_snep_register_server: %s", get_nfc_error(result));
-//
-//                     result = nfc_snep_start_server(this->target, "default", 4, _nfc_snep_event_cb, this);
-//                     RETM_IF(result != NFC_ERROR_NONE, "nfc_snep_start_server: %s", get_nfc_error(result));
+                       DBG("Inside TBT_APP_NFC_P2P");
+                       if(is_tab_1_clicked == true)
+                       {
+                               DBG("Inside server");
+                               result = nfc_p2p_set_data_received_cb(this->target, _nfc_p2p_data_received_cb, this);
+       //                      result = nfc_snep_register_server("default", 4, _nfc_snep_event_cb, this);
+       //                      DBG("nfc_snep_register_server %s", get_nfc_error(result));
+       //                      RETM_IF(result != NFC_ERROR_NONE, "nfc_snep_register_server: %s", get_nfc_error(result));
+       //
+       //                      result = nfc_snep_start_server(this->target, "default", 4, _nfc_snep_event_cb, this);
+       //                      RETM_IF(result != NFC_ERROR_NONE, "nfc_snep_start_server: %s", get_nfc_error(result));
 
+                       }
+                       else if(is_tab_2_clicked == true)
+                       {
+                               nfc_ndef_message_h message = create_ndef_message();
+                               nfc_p2p_send(this->target, message, _nfc_p2p_send_completed_cb, this);
+       //                      result = nfc_snep_start_client(this->target, "urn:nfc:sn:snep", 4, _nfc_snep_event_cb, this);
+       //                      RETM_IF(result != NFC_ERROR_NONE, "nfc_snep_start_client: %s", get_nfc_error(result));
+                       }
+                       DBG("NFC Discovery Attach");
+                       ui_utils_label_set_text(this->nfc_label, "NFC Discovery Attach", "left");
                }
-               else if(is_tab_2_clicked == true)
+               else
                {
-                       nfc_ndef_message_h message = create_ndef_message();
-                       nfc_p2p_send(this->target, message, _nfc_p2p_send_completed_cb, this);
-//                     result = nfc_snep_start_client(this->target, "urn:nfc:sn:snep", 4, _nfc_snep_event_cb, this);
-//                     RETM_IF(result != NFC_ERROR_NONE, "nfc_snep_start_client: %s", get_nfc_error(result));
+                                                       DBG("NFC Discovery Detach");
+                                                 this->nfc_label = ui_utils_label_add(this->view->layout,  "NFC Discovery Detach");
+                                                       elm_object_part_content_set(this->view->layout, "nfc_text", this->nfc_label);
+                                                       this->nfc_list = elm_list_add(this->view->layout);
+                                                       evas_object_data_set(this->nfc_list, "nfc_view", this);
+                                                       elm_object_part_content_set(this->view->layout, "nfc_list", this->nfc_list);
+                                                       ui_utils_show_toast("NFC Discovery Detach", this->view->layout, 3);
                }
 
-
        }
 
 
@@ -896,12 +1010,13 @@ void _nfc_tag_transceive_completed_cb(nfc_error_e result, unsigned char *buffer,
        this = (nfc_view*)user_data;
        RETM_IF(NULL == this, "view is NULL");
 
-       char* fmt_str = NULL;
-
-       fmt_str = nfc_util_itoa("Transceive Data: %s size: %d", buffer, buffer_size);
-       elm_list_item_append(this->nfc_list, fmt_str, NULL, NULL, NULL, NULL);
-       SAFE_DELETE(fmt_str);
+       if(result != NFC_ERROR_NONE)
+                               ui_utils_show_toast(get_nfc_string_error(result), this->view->layout, 3);
 
+         char* fmt_str = NULL;
+               fmt_str = nfc_util_itoa("Transceive Data: %s size: %d", buffer, buffer_size);
+               elm_list_item_append(this->nfc_list, fmt_str, NULL, NULL, NULL, NULL);
+               SAFE_DELETE(fmt_str);
 }
 
 
@@ -1020,7 +1135,7 @@ void _tag_write_completed_cb(nfc_error_e result, void *user_data)
        }
        else
        {
-               elm_object_text_set(this->nfc_label, "Write Error");
+               elm_object_text_set(this->nfc_label, get_nfc_string_error(result));
        }
 }
 
@@ -1281,8 +1396,12 @@ void _nfc_tag_read_completed_cb(nfc_error_e result, nfc_ndef_message_h message,
        this = (nfc_view*)user_data;
        RETM_IF(NULL == this, "view is NULL");
 
-       ret = nfc_ndef_message_get_record_count(message, &count);
-       RETM_IF(ret != NFC_ERROR_NONE, "nfc_ndef_message_get_record_count failed with error: %s", get_nfc_error(ret));
+               if(result != NFC_ERROR_NONE)
+               {
+                               ui_utils_show_toast(get_nfc_string_error(result), this->view->layout, 3);
+               }
+               ret = nfc_ndef_message_get_record_count(message, &count);
+               RETM_IF(ret != NFC_ERROR_NONE, "nfc_ndef_message_get_record_count failed with error: %s", get_nfc_error(ret));
 
        char* fmt_str = NULL;
        fmt_str = nfc_util_itoa("NDEF Record Count: %d", count);
@@ -1409,6 +1528,10 @@ void _nfc_p2p_send_completed_cb(nfc_error_e result, void *user_data)
        {
                ui_utils_label_set_text(this->nfc_label, "Data Sent Successfully", "left");
        }
+       else
+       {
+               ui_utils_label_set_text(this->nfc_label, get_nfc_string_error(result), "left");
+       }
 
 }
 
diff --git a/tbtcoreapp/src/view/tbt-notification-view.c b/tbtcoreapp/src/view/tbt-notification-view.c
new file mode 100644 (file)
index 0000000..738fbf8
--- /dev/null
@@ -0,0 +1,199 @@
+/*******************************************************************************
+ * Copyright (c) 2014 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.
+ *******************************************************************************/
+/**
+ * @file       tbt-notification-view.c
+ * @brief      retrieves notification info
+ *
+ * @author     Nibha Sharma(nibha.sharma@samsung.com)
+ * @date       June, 2016
+ * @bug                none
+ * @credit
+ *
+ */
+#include "utils/app_module_config.h"
+#ifdef TBT_MODULE_NOTIFICATION
+
+#include <Elementary.h>
+#include <locations.h>
+#include <time.h>
+
+#include "utils/logger.h"
+#include "utils/config.h"
+#include "utils/ui-utils.h"
+#include "view/tbt-notification-view.h"
+#include "view/tbt-common-view.h"
+
+struct _notification_view
+{
+       common_view* view;
+
+       Evas_Object *notification_label;
+       
+};
+
+static void _app_destroy_cb(void* this);
+
+notification_h g_NotificationHandle;
+
+/**
+ * @function           get_notification_error
+ * @since_tizen                3.0
+ * @description                Get notification Error
+ * @parameter          int: Int
+ * @return             char*
+ */
+char* get_notification_error(int ret)
+{
+       char* err_msg = NULL;
+       switch (ret) {
+       case NOTIFICATION_ERROR_NONE:
+               err_msg = "NOTIFICATION_ERROR_NONE";
+               break;
+       case NOTIFICATION_ERROR_INVALID_PARAMETER:
+               err_msg = "NOTIFICATION_ERROR_INVALID_PARAMETER";
+               break;
+       case NOTIFICATION_ERROR_OUT_OF_MEMORY:
+               err_msg = "NOTIFICATION_ERROR_OUT_OF_MEMORY";
+               break;
+       case NOTIFICATION_ERROR_FROM_DB:                                
+               err_msg = " NOTIFICATION_ERROR_FROM_DB";
+               break;
+       case NOTIFICATION_ERROR_ALREADY_EXIST_ID:               
+               err_msg = " NOTIFICATION_ERROR_ALREADY_EXIST_ID";
+               break;
+       case NOTIFICATION_ERROR_FROM_DBUS:                              
+               err_msg = "NOTIFICATION_ERROR_FROM_DBUS";
+               break;
+       case NOTIFICATION_ERROR_NOT_EXIST_ID:
+               err_msg = "NOTIFICATION_ERROR_NOT_EXIST_ID";
+               break;
+       case NOTIFICATION_ERROR_IO_ERROR:                               
+               err_msg = "NOTIFICATION_ERROR_IO_ERROR";
+               break;
+       case NOTIFICATION_ERROR_SERVICE_NOT_READY:              
+               err_msg = "NOTIFICATION_ERROR_SERVICE_NOT_READY";
+               break;
+       case NOTIFICATION_ERROR_PERMISSION_DENIED:              
+               err_msg = "NOTIFICATION_ERROR_PERMISSION_DENIED";
+               break;
+       default:
+               err_msg = "Unknown Error";
+               break;
+       }
+
+       return err_msg;
+}
+
+/**
+ * @function           notification_view_add
+ * @since_tizen                3.0
+ * @description                Notification View Add
+ * @parameter          Evas_Object*: Evas Object Pointer, tbt_info*: Tbt Info Pointer, Elm_Object_Item*: Elm Object Item Pointer
+ * @return             notification_view*
+ */
+notification_view *notification_view_add(Evas_Object *navi, tbt_info *tbt_info, Elm_Object_Item *item)
+{
+       RETVM_IF(NULL == navi, NULL, "navi is null");
+       int ret;
+       notification_view *this = NULL;
+       this = calloc(1, sizeof(notification_view));
+       RETVM_IF(!this, NULL, "calloc failed");
+
+
+       this->view = calloc(1, sizeof(common_view));
+       RETVM_IF(!this->view, NULL, "calloc failed");
+
+       tbt_info->layout_group = "notification_viewer";
+       tbt_info->layout_file = get_edje_path("notification_viewer.edj");
+
+       common_view_add(navi, tbt_info, item, this->view, _app_destroy_cb, this);
+       RETVM_IF(NULL == this->view, NULL, "navi is null");
+
+       g_NotificationHandle =  notification_create(NOTIFICATION_TYPE_NOTI);
+
+       if(this->view->tbt_info->apptype == TBT_APP_NOTIFICATION_TITLE)
+       {
+               ret = notification_set_text(g_NotificationHandle,NOTIFICATION_TEXT_TYPE_TITLE, "IDS_APP_BODY_IM_TITLE", "I'm Title", NOTIFICATION_VARIABLE_TYPE_NONE);
+               RETVM_IF(ret != NOTIFICATION_ERROR_NONE, NULL, "package_manager_set_event_cb failed : %s", get_notification_error(ret));        
+
+               ret = notification_post(g_NotificationHandle);  
+               RETVM_IF(ret != NOTIFICATION_ERROR_NONE, NULL, "notification_post failed : %s", get_notification_error(ret));
+
+               return this;
+       }
+       else if (this->view->tbt_info->apptype == TBT_APP_NOTIFICATION_TEXT)
+       {
+               ret = notification_status_message_post("Hello World!!!");
+               RETVM_IF(ret != NOTIFICATION_ERROR_NONE, NULL, "notification_status_message_post failed : %s", get_notification_error(ret));
+               return this;
+       }
+       else if (this->view->tbt_info->apptype == TBT_APP_NOTIFICATION_TIME)
+       {       
+               ret =  notification_set_time_to_text(g_NotificationHandle,NOTIFICATION_TEXT_TYPE_CONTENT, time(NULL));
+               RETVM_IF(ret != NOTIFICATION_ERROR_NONE, NULL, "notification_set_time failed : %s", get_notification_error(ret));
+               
+               ret = notification_post(g_NotificationHandle);  
+               RETVM_IF(ret != NOTIFICATION_ERROR_NONE, NULL, "notification_post failed : %s", get_notification_error(ret));
+
+               return this;
+               
+       }
+       else if (this->view->tbt_info->apptype == TBT_APP_NOTIFICATION_IMAGE)
+       {
+               char image_path[128] = {'\0'};
+               snprintf(image_path, sizeof(image_path), "%simages/%s",app_get_resource_path(),"dial.png");
+
+               DBG("%s",image_path);
+
+               ret  = notification_set_image(g_NotificationHandle,NOTIFICATION_IMAGE_TYPE_ICON_FOR_INDICATOR ,image_path);
+                       RETVM_IF(ret != NOTIFICATION_ERROR_NONE, NULL, "notification_set_image failed : %s", get_notification_error(ret));                              
+
+               ret = notification_post(g_NotificationHandle);  
+               RETVM_IF(ret != NOTIFICATION_ERROR_NONE, NULL, "notification_post failed : %s", get_notification_error(ret));
+
+               return this;
+       }
+    return this;
+}
+
+
+/**
+ * @function           _app_destroy_cb
+ * @since_tizen                2.3
+ * @description                App Destroy Cb
+ * @parameter          void*: Void Pointer
+ * @return             static void
+ */
+static void _app_destroy_cb(void* this)
+{
+
+       RETM_IF(NULL == this, "data is NULL");
+
+       int result;
+       notification_view *view = NULL;
+       view = (notification_view*)this;
+       RETM_IF(NULL == view, "view is NULL");
+
+       result = notification_delete(g_NotificationHandle);
+       RETM_IF(result != NOTIFICATION_ERROR_NONE, "notification_delete fail > Error = %s", get_notification_error(result));
+
+       result = notification_free(g_NotificationHandle);
+       RETM_IF(result != NOTIFICATION_ERROR_NONE, "notification_free fail > Error = %s", get_notification_error(result));
+
+       SAFE_DELETE(view->view);
+       SAFE_DELETE(view);
+}
+#endif
diff --git a/tbtcoreapp/src/view/tbt-package-manager-view.c b/tbtcoreapp/src/view/tbt-package-manager-view.c
new file mode 100644 (file)
index 0000000..33e052f
--- /dev/null
@@ -0,0 +1,212 @@
+/*******************************************************************************
+ * Copyright (c) 2014 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.
+ *******************************************************************************/
+/**
+ * @file       tbt-packagemanager-view.c
+ * @brief      retrieves packagemanager info
+ *
+ * @author     Nibha Sharma(nibha.sharma@samsung.com)
+ * @date       June, 2016
+ * @bug                none
+ * @credit
+ *
+ */
+#include "utils/app_module_config.h"
+#ifdef TBT_MODULE_PACKAGE_MANAGER
+
+#include <Elementary.h>
+#include <locations.h>
+
+#include "utils/logger.h"
+#include "utils/config.h"
+#include "utils/ui-utils.h"
+#include "view/tbt-package-manager-view.h"
+#include "view/tbt-common-view.h"
+
+struct _packagemanager_view
+{
+       common_view* view;
+
+       Evas_Object *packagemanager_label;
+       Evas_Object *packagemanagerstate_label;
+       
+};
+
+static void _app_destroy_cb(void* this);
+static void _package_manager_event_cb(const char *type, const char *package, package_manager_event_type_e event_type, package_manager_event_state_e event_state, int progress, package_manager_error_e error, void *user_data);
+
+package_manager_h g_pstPkgMngr;
+
+/**
+ * @function           get_package_manager_error
+ * @since_tizen                3.0
+ * @description                Get packagemanager Error
+ * @parameter          int: Int
+ * @return             char*
+ */
+char* get_package_manager_error(int ret)
+{
+       char* err_msg = NULL;
+       switch (ret) {
+       case PACKAGE_MANAGER_ERROR_NONE:
+               err_msg = "PACKAGE_MANAGER_ERROR_NONE";
+               break;
+       case PACKAGE_MANAGER_ERROR_INVALID_PARAMETER:
+               err_msg = "PACKAGE_MANAGER_ERROR_INVALID_PARAMETER";
+               break;
+       case PACKAGE_MANAGER_ERROR_OUT_OF_MEMORY:
+               err_msg = "PACKAGE_MANAGER_ERROR_OUT_OF_MEMORY";
+               break;
+       case PACKAGE_MANAGER_ERROR_IO_ERROR:
+               err_msg = "PACKAGE_MANAGER_ERROR_IO_ERROR";
+               break;
+       case PACKAGE_MANAGER_ERROR_PERMISSION_DENIED:
+               err_msg = "PACKAGE_MANAGER_ERROR_PERMISSION_DENIED";
+               break;
+       default:
+               err_msg = "Unknown Error";
+               break;
+       }
+
+       return err_msg;
+}
+
+/**
+ * @function           packagemanager_view_add
+ * @since_tizen                3.0
+ * @description                Package Manager View Add
+ * @parameter          Evas_Object*: Evas Object Pointer, tbt_info*: Tbt Info Pointer, Elm_Object_Item*: Elm Object Item Pointer
+ * @return             packagemanager_view*
+ */
+packagemanager_view *packagemanager_view_add(Evas_Object *navi, tbt_info *tbt_info, Elm_Object_Item *item)
+{
+       RETVM_IF(NULL == navi, NULL, "navi is null");
+       int ret;
+       packagemanager_view *this = NULL;
+       this = calloc(1, sizeof(packagemanager_view));
+       RETVM_IF(!this, NULL, "calloc failed");
+
+
+       this->view = calloc(1, sizeof(common_view));
+       RETVM_IF(!this->view, NULL, "calloc failed");
+
+       tbt_info->layout_group = "package_manager_viewer";
+       tbt_info->layout_file = get_edje_path("package_manager_viewer.edj");
+
+       common_view_add(navi, tbt_info, item, this->view, _app_destroy_cb, this);
+       RETVM_IF(NULL == this->view, NULL, "navi is null");
+
+       ui_utils_guide_instruction_popup_button(navi, "To install sample package please follow steps:br/>1.sdb shell<br/>2.cd /home/owner/apps_rw/org.tizen.tbtcoreapp/res/package<br/>Run command pkgcmd -iqt tpk -p native-testapp-itc-1.0.0-arm.tpk in sdb shell <br/><b>Note:While installation you can see in package status that package status and state changes</b>");
+
+       ui_utils_guide_instruction_popup_button(navi, "1.Please Uninstall package from Application manager.<br/>2.Please install package in device manually from sdb shell.<br/>3.Update is re-install same package on the device<br/><b>Note:You can also refer info section</b>");
+
+       ret = package_manager_create(&g_pstPkgMngr);
+       RETVM_IF(ret != PACKAGE_MANAGER_ERROR_NONE, NULL, "package_manager_create failed : %s", get_package_manager_error(ret));
+               
+       ret = package_manager_set_event_cb(g_pstPkgMngr,_package_manager_event_cb, this);
+       RETVM_IF(ret != PACKAGE_MANAGER_ERROR_NONE, NULL, "package_manager_set_event_cb failed : %s", get_package_manager_error(ret));
+                
+       this->packagemanager_label = ui_utils_label_add(this->view->layout, "Package Status:Install/Uninstall/Update ");
+       elm_label_line_wrap_set(this->packagemanager_label, ELM_WRAP_WORD);
+
+       this->packagemanagerstate_label = ui_utils_label_add(this->view->layout, "State: No Progress");
+       elm_label_line_wrap_set(this->packagemanagerstate_label, ELM_WRAP_WORD);
+
+       elm_object_part_content_set(this->view->layout, "packagemanager_text", this->packagemanager_label);
+       elm_object_part_content_set(this->view->layout, "packagemanager_state", this->packagemanagerstate_label);
+
+    return this;
+}
+
+
+/**
+ * @function           _app_destroy_cb
+ * @since_tizen                2.3
+ * @description                App Destroy Cb
+ * @parameter          void*: Void Pointer
+ * @return             static void
+ */
+static void _app_destroy_cb(void* this)
+{
+
+       RETM_IF(NULL == this, "data is NULL");
+
+       int result;
+       packagemanager_view *view = NULL;
+       view = (packagemanager_view*)this;
+       RETM_IF(NULL == view, "view is NULL");
+
+       result = package_manager_destroy(g_pstPkgMngr);
+       RETM_IF(result != PACKAGE_MANAGER_ERROR_NONE, "package_manager_destroy fail > Error = %s", get_package_manager_error(result));
+
+       SAFE_DELETE(view->view);
+       SAFE_DELETE(view);
+}
+
+
+/**
+ * @function           _package_manager_event_cb
+ * @since_tizen                3.0
+ * @description                package manager event Cb
+ * @parameter          const char *type, const char *package, package_manager_event_type_e event_type, package_manager_event_state_e event_state, int progress, package_manager_error_e error, void *user_data
+ * @return             void
+ */
+static void _package_manager_event_cb(const char *type, const char *package, package_manager_event_type_e event_type, package_manager_event_state_e event_state, int progress, package_manager_error_e error, void *user_data)
+{
+
+       RETM_IF(NULL == user_data, "user_data is null");
+       packagemanager_view *this = NULL;
+       this = (packagemanager_view*) user_data;
+       RETM_IF(NULL == this, "view is NULL");
+
+       DBG("value: %d", event_type);
+
+       switch (event_type) 
+       {
+               case PACKAGE_MANAGER_EVENT_TYPE_INSTALL:
+                               ui_utils_label_set_text(this->packagemanager_label, "Install event type ", "left");
+                               break;
+               case PACKAGE_MANAGER_EVENT_TYPE_UNINSTALL:
+                               ui_utils_label_set_text(this->packagemanager_label, "Uninstall event type", "left");
+                               break;
+               case PACKAGE_MANAGER_EVENT_TYPE_UPDATE:
+                               ui_utils_label_set_text(this->packagemanager_label, "Update event type", "left");
+                               break;
+               default:
+                               ui_utils_label_set_text(this->packagemanager_label, "unknown state", "left");
+                               break;
+       }
+       switch(event_state)
+       {
+               case PACKAGE_MANAGER_EVENT_STATE_STARTED:
+                               ui_utils_label_set_text(this->packagemanagerstate_label, "Started event state", "left");
+                               break;
+               case PACKAGE_MANAGER_EVENT_STATE_PROCESSING:
+                               ui_utils_label_set_text(this->packagemanagerstate_label, "Processing event state", "left");
+                               break;
+               case PACKAGE_MANAGER_EVENT_STATE_COMPLETED:
+                               ui_utils_label_set_text(this->packagemanagerstate_label, "Completed event state", "left");
+                               break;
+               case PACKAGE_MANAGER_EVENT_STATE_FAILED:
+                               ui_utils_label_set_text(this->packagemanagerstate_label, "Failed event state", "left");
+                               break;
+               default:
+                               ui_utils_label_set_text(this->packagemanagerstate_label, "unknown state", "left");
+                               break;
+       }
+       return ;
+}
+
+#endif
index d117f552da83789ff10a7242d9a0051d157d5fed..5c52369f6b292f473f9068c631ba028019a5c24f 100644 (file)
@@ -46,7 +46,7 @@ static void _app_destroy_cb(void* this);
 static void _radio_interrupted_cb(radio_interrupted_code_e code, void *user_data);
 
 radio_h g_pstRadio;
-bool is_not_supported = false;
+static bool is_not_supported = false;
 
 /**
  * @function           get_radio_type_error
diff --git a/tbtcoreapp/src/view/tbt-sound-manager-view.c b/tbtcoreapp/src/view/tbt-sound-manager-view.c
new file mode 100644 (file)
index 0000000..97656a2
--- /dev/null
@@ -0,0 +1,255 @@
+/*******************************************************************************
+ * Copyright (c) 2014 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.
+ *******************************************************************************/
+/**
+ * @file       tbt-soundmanager-view.c
+ * @brief      retrieves soundmanager info
+ *
+ * @author     Nibha Sharma(nibha.sharma@samsung.com)
+ * @date       June, 2016
+ * @bug                none
+ * @credit
+ *
+ */
+#include "utils/app_module_config.h"
+#ifdef TBT_MODULE_SOUND_MANAGER
+
+#include <Elementary.h>
+#include <locations.h>
+
+#include "utils/logger.h"
+#include "utils/config.h"
+#include "utils/ui-utils.h"
+#include "view/tbt-sound-manager-view.h"
+#include "view/tbt-common-view.h"
+
+struct _soundmanager_view
+{
+       common_view* view;
+
+       Evas_Object *info_label;
+       Evas_Object *device_label;
+};
+
+static void _app_destroy_cb(void* this);
+void _sound_device_connected_cb(sound_device_h device, bool is_connected, void *user_data);
+void _sound_device_information_changed_cb(sound_device_h device, sound_device_changed_info_e changed_info, void *user_data);
+
+static bool is_not_supported = false;
+
+/**
+ * @function           get_soundmanager_error
+ * @since_tizen                3.0
+ * @description                Get SoundManager Error
+ * @parameter          int: Int
+ * @return             char*
+ */
+char* get_soundmanager_error(int ret)
+{
+       char* err_msg = NULL;
+       switch (ret) {
+       case SOUND_MANAGER_ERROR_NONE:
+               err_msg = "SOUND_MANAGER_ERROR_NONE";
+               break;
+       case SOUND_MANAGER_ERROR_OUT_OF_MEMORY:
+               err_msg = "SOUND_MANAGER_ERROR_OUT_OF_MEMORY";
+               break;
+       case SOUND_MANAGER_ERROR_INVALID_PARAMETER:
+               err_msg = "SOUND_MANAGER_ERROR_INVALID_PARAMETER";
+               break;
+       case SOUND_MANAGER_ERROR_INVALID_OPERATION:
+               err_msg = "SOUND_MANAGER_ERROR_INVALID_OPERATION";
+               break;
+       case SOUND_MANAGER_ERROR_PERMISSION_DENIED:
+               err_msg = "SOUND_MANAGER_ERROR_PERMISSION_DENIED";
+               break;
+       case SOUND_MANAGER_ERROR_NOT_SUPPORTED:
+               err_msg = "SOUND_MANAGER_ERROR_NOT_SUPPORTED";
+               break;
+       case SOUND_MANAGER_ERROR_NO_DATA:
+               err_msg = "SOUND_MANAGER_ERROR_NO_DATA";
+               break;
+       case SOUND_MANAGER_ERROR_NO_PLAYING_SOUND:
+               err_msg = "SOUND_MANAGER_ERROR_NO_PLAYING_SOUND";
+               break;
+       case SOUND_MANAGER_ERROR_INTERNAL:
+               err_msg = "SOUND_MANAGER_ERROR_INTERNAL";
+               break;  
+       case SOUND_MANAGER_ERROR_POLICY:
+               err_msg = "SOUND_MANAGER_ERROR_POLICY";
+               break;  
+       default:
+               err_msg = "Unknown Error";
+       }
+
+       return err_msg;
+}
+
+
+/**
+ * @function           soundmanager_view_add
+ * @since_tizen                3.0
+ * @description                soundmanager View Add
+ * @parameter          Evas_Object*: Evas Object Pointer, tbt_info*: Tbt Info Pointer, Elm_Object_Item*: Elm Object Item Pointer
+ * @return             soundmanager_view*
+ */
+soundmanager_view *soundmanager_view_add(Evas_Object *navi, tbt_info *tbt_info, Elm_Object_Item *item)
+{
+       RETVM_IF(NULL == navi, NULL, "navi is null");
+       int ret, value;
+       soundmanager_view *this = NULL;
+       this = calloc(1, sizeof(soundmanager_view));
+       RETVM_IF(!this, NULL, "calloc failed");
+
+
+       this->view = calloc(1, sizeof(common_view));
+       RETVM_IF(!this->view, NULL, "calloc failed");
+
+       tbt_info->layout_group = "sound_manager_viewer";
+       tbt_info->layout_file = get_edje_path("sound_manager_viewer.edj");
+
+       common_view_add(navi, tbt_info, item, this->view, _app_destroy_cb, this);
+       RETVM_IF(NULL == this->view, NULL, "navi is null");             
+
+       if(this->view->tbt_info->apptype == TBT_APP_SOUND_MANAGER)
+       {
+               ui_utils_guide_instruction_popup_button(navi, "* Please Insert/Remove Audio jack to change status<br/><b>Note:You can also refer info section</b><br/>");
+
+               ret = sound_manager_set_device_connected_cb(SOUND_DEVICE_IO_DIRECTION_BOTH_MASK,_sound_device_connected_cb,this);
+               RETVM_IF(ret != SOUND_MANAGER_ERROR_NONE && ret != SOUND_MANAGER_ERROR_NOT_SUPPORTED, NULL, "sound_manager_set_device_connected_cb failed : %s", get_soundmanager_error(ret));
+
+               this->info_label = ui_utils_label_add(this->view->layout, "Please change Audio Jack state[Insert/Remove]");
+               elm_label_line_wrap_set(this->info_label, ELM_WRAP_WORD);
+
+               if(ret == SOUND_MANAGER_ERROR_NOT_SUPPORTED)
+               {
+                       is_not_supported = true;
+                       Evas_Object *popup = ui_utils_popup_add(this->view->navi, "Message");
+                       elm_object_text_set(popup, "Sound Device is not supported");
+                       RETVM_IF(!this->view, NULL,"Sound Device is not supported");
+               }
+               elm_object_part_content_set(this->view->layout, "sound_manager_text", this->info_label);
+               return this;
+       }
+       else if (this->view->tbt_info->apptype == TBT_APP_SOUND_MANAGER_DEVICE)
+       {
+               ui_utils_guide_instruction_popup_button(navi, "*Please Insert Audio jack and change sound profile to Sound,Sound state will be changed<br/><b>Note:You can also refer info section</b><br/>");
+
+               ret = sound_manager_set_device_information_changed_cb(SOUND_DEVICE_TYPE_EXTERNAL_MASK, _sound_device_information_changed_cb,this);
+       RETVM_IF(ret != SOUND_MANAGER_ERROR_NONE && ret != SOUND_MANAGER_ERROR_NOT_SUPPORTED, NULL, "sound_manager_set_device_information_changed_cb failed : %s", get_soundmanager_error(ret));
+               
+               this->info_label = ui_utils_label_add(this->view->layout, "Please change state of sound profile[Sound]");
+               elm_label_line_wrap_set(this->info_label, ELM_WRAP_WORD);
+
+               if(ret == SOUND_MANAGER_ERROR_NOT_SUPPORTED)
+               {
+                       is_not_supported = true;
+                       Evas_Object *popup = ui_utils_popup_add(this->view->navi, "Message");
+                       elm_object_text_set(popup, "Sound Device is not supported");
+                       RETVM_IF(!this->view, NULL,"Sound Device is not supported");
+               }
+               elm_object_part_content_set(this->view->layout, "sound_manager_text", this->info_label);
+               return this;
+       }       
+}
+
+
+/**
+ * @function           _app_destroy_cb
+ * @since_tizen                2.3
+ * @description                 App Destroy Cb
+ * @parameter          void*: Void Pointer
+ * @return             static void
+ */
+static void _app_destroy_cb(void* this)
+{
+
+       RETM_IF(NULL == this, "data is NULL");
+
+       soundmanager_view *view = NULL;
+       view = (soundmanager_view*)this;
+       RETM_IF(NULL == view, "view is NULL");
+
+       if(is_not_supported == true)
+       {
+               view->view->tbt_info->result = TBT_INFO_RESULT_NOT_SUPPORTED;
+               elm_genlist_item_update(view->view->item);
+       }
+
+       SAFE_DELETE(view->view);
+       SAFE_DELETE(view);
+}
+
+
+/**
+ * @function           _sound_device_connected_cb
+ * @since_tizen                3.0
+ * @description                Sound Device Connected Cb
+ * @parameter          sound_device_h device, bool is_connected, void *user_data
+ * @return             void
+ */
+void _sound_device_connected_cb(sound_device_h device, bool is_connected, void *user_data)
+{
+
+       RETM_IF(NULL == user_data, "user_data is null");
+       soundmanager_view *this = NULL;
+       this = (soundmanager_view*) user_data;
+
+       DBG("is_connected: %d", is_connected);
+
+       if(is_connected == true)
+       {
+               ui_utils_label_set_text(this->info_label, "Audio Jack connected", "left");
+       }
+       else
+       {
+               ui_utils_label_set_text(this->info_label, "Audio Jack Not connected", "left");
+       }
+
+}
+
+/**
+ * @function           _sound_device_information_changed_cb
+ * @since_tizen                3.0
+ * @description                sound Device Information Changed Cb
+ * @parameter          sound_device_h device, sound_device_changed_info_e changed_info, void *user_data
+ * @return             void
+ */
+void _sound_device_information_changed_cb(sound_device_h device, sound_device_changed_info_e changed_info, void *user_data)
+{
+
+       RETM_IF(NULL == user_data, "user_data is null");
+       soundmanager_view *this = NULL;
+       this = (soundmanager_view*) user_data;
+
+       DBG("changed_info: %d", changed_info);
+
+       switch(changed_info)
+       {
+               case SOUND_DEVICE_CHANGED_INFO_STATE :
+                       ui_utils_label_set_text(this->info_label, "State of the device was changed", "left");
+                       break;
+
+               case SOUND_DEVICE_CHANGED_INFO_IO_DIRECTION:
+                       ui_utils_label_set_text(this->info_label, "IO direction of the device was changed", "left");
+                       break;
+               default:
+                       ui_utils_label_set_text(this->info_label, "Unknown status", "left");
+                       break;
+       }
+
+}
+
+#endif
index ab13c99cbc31cb72e542f40000aca654b29e5575..03f2f5085fc5f72919388029083f756dad1c8175 100644 (file)
@@ -22,5 +22,9 @@
         <privilege>http://tizen.org/privilege/internet</privilege>
         <privilege>http://tizen.org/privilege/notification</privilege>
         <privilege>http://tizen.org/privilege/network.set</privilege>
+       <privilege>http://tizen.org/privilege/volume.set</privilege>
+       <privilege>http://tizen.org/privilege/packagemanager.info</privilege>
+       <privilege>http://tizen.org/privilege/packagemanager.clearcache</privilege>
+       <privilege>http://tizen.org/privilege/network.profile</privilege>
     </privileges>
 </manifest>