Update change log and spec for wrt-plugins-tizen_0.4.74
authorLee Siwoo <siwoo0.lee@samsung.com>
Tue, 22 Oct 2013 11:29:18 +0000 (20:29 +0900)
committerLee Siwoo <siwoo0.lee@samsung.com>
Tue, 22 Oct 2013 11:29:18 +0000 (20:29 +0900)
12 files changed:
packaging/wrt-plugins-tizen.spec
src/Application/ApplicationController.cpp [changed mode: 0644->0755]
src/Application/JSApplication.cpp [changed mode: 0644->0755]
src/Application/JSApplicationInformation.cpp [changed mode: 0644->0755]
src/Application/JSApplicationManager.cpp [changed mode: 0644->0755]
src/Application/JSRequestedApplicationControl.cpp [changed mode: 0644->0755]
src/Calendar/JSCalendar.cpp
src/Calendar/JSCalendarEvent.cpp
src/Calendar/JSCalendarItemProperties.cpp
src/Calendar/JSCalendarManager.cpp
src/DataSync/DataSyncManager.cpp
src/Power/JSPowerManager.cpp

index a31e333..1caa814 100755 (executable)
@@ -1,6 +1,6 @@
 Name:       wrt-plugins-tizen
 Summary:    JavaScript plugins for WebRuntime
-Version:    0.4.73
+Version:    0.4.74
 Release:    0
 Group:      Development/Libraries
 License:    Apache License, Version 2.0
old mode 100644 (file)
new mode 100755 (executable)
index 2c1f3f4..c674eb3
@@ -145,12 +145,14 @@ void ApplicationAsyncAnswerHandler::launch(const EventApplicationLaunchPtr &even
 
        Try {
                callbackManager->callOnSuccess();
+               LoggerD("launch success callback called");
                return;
        } Catch(Exception) {
                LoggerE("error during processing answer" << _rethrown_exception.GetMessage());
                error = JSWebAPIErrorFactory::makeErrorObject(gContext, JSWebAPIErrorFactory::UNKNOWN_ERROR, "Internal error");
 
                callbackManager->callOnError(error);
+               LoggerD("launch error callback called");
                return;
        }
 }
@@ -193,17 +195,20 @@ void ApplicationAsyncAnswerHandler::kill(const EventApplicationKillPtr &event)
                }
 
                callbackManager->callOnError(error);
+               LoggerD("kill error callback called");
                return;
        }
 
        Try {
                callbackManager->callOnSuccess();
+               LoggerD("kill success callback called");
                return;
        } Catch(Exception) {
                LoggerE("error during processing answer" << _rethrown_exception.GetMessage());
                error = JSWebAPIErrorFactory::makeErrorObject(gContext, JSWebAPIErrorFactory::UNKNOWN_ERROR, "Internal error");
 
                callbackManager->callOnError(error);
+               LoggerD("kill error callback called");
                return;
        }
 }
@@ -243,17 +248,20 @@ void ApplicationAsyncAnswerHandler::launchAppControl(const EventApplicationLaunc
                }
 
                callbackManager->callOnError(error);
+               LoggerD("launchAppControl error callback called");
                return;
        }
 
        Try {
                callbackManager->callOnSuccess();
+               LoggerD("launchAppControl success callback called");
                return;
        } Catch(Exception) {
                LoggerE("error during processing answer" << _rethrown_exception.GetMessage());
                error = JSWebAPIErrorFactory::makeErrorObject(gContext, JSWebAPIErrorFactory::UNKNOWN_ERROR, "Internal error");
 
                callbackManager->callOnError(error);
+               LoggerD("launchAppControl error callback called");
                return;
        }
 }
@@ -279,6 +287,7 @@ void ApplicationAsyncAnswerHandler::launchAppControlReply(const EventApplication
        if (ExceptionCodes::None != event->getExceptionCode())
        {
                callbackManager->callOnError();
+               LoggerD("launchAppControl reply failure callback called");
                return;
        }
 
@@ -294,9 +303,11 @@ void ApplicationAsyncAnswerHandler::launchAppControlReply(const EventApplication
                JSValueRef result = converter->toJSValueRef(*appControlDataArray);
 
                callbackManager->callOnSuccess(result);
+               LoggerD("launchAppControl reply return callback called");
                return;
        } Catch(Exception) {
                callbackManager->callOnError();
+               LoggerD("launchAppControl reply failure callback called");
                return;
        }
 }
@@ -336,6 +347,7 @@ void ApplicationAsyncAnswerHandler::findAppControl(const EventApplicationFindApp
                }
 
                callbackManager->callOnError(error);
+               LoggerD("findAppControl error callback called");
                return;
        }
 
@@ -350,12 +362,14 @@ void ApplicationAsyncAnswerHandler::findAppControl(const EventApplicationFindApp
                result[1] = converter.toJSValueRef(appControl);
 
                callbackManager->callOnSuccess(result, 2);
+               LoggerD("findAppControl success callback called");
                return;
        } Catch(Exception) {
                LoggerE("error during processing answer" << _rethrown_exception.GetMessage());
                error = JSWebAPIErrorFactory::makeErrorObject(gContext, JSWebAPIErrorFactory::UNKNOWN_ERROR, "Internal error");
 
                callbackManager->callOnError(error);
+               LoggerD("findAppControl error callback called");
                return;
        }
 }
@@ -395,6 +409,7 @@ void ApplicationAsyncAnswerHandler::getAppsContext(const EventApplicationGetApps
                }
 
                callbackManager->callOnError(error);
+               LoggerD("getAppsContext error callback called");
                return;
        }
 
@@ -407,12 +422,14 @@ void ApplicationAsyncAnswerHandler::getAppsContext(const EventApplicationGetApps
                JSValueRef result = converter->toJSValueRef(appContextArray);
 
                callbackManager->callOnSuccess(result);
+               LoggerD("getAppsContext success callback called");
                return;
        } Catch(Exception) {
                LoggerE("error during processing answer" << _rethrown_exception.GetMessage());
                error = JSWebAPIErrorFactory::makeErrorObject(gContext, JSWebAPIErrorFactory::UNKNOWN_ERROR, "Internal error");
 
                callbackManager->callOnError(error);
+               LoggerD("getAppsContext error callback called");
                return;
        }
 }
@@ -452,6 +469,7 @@ void ApplicationAsyncAnswerHandler::getAppsInfo(const EventApplicationGetAppsInf
                }
 
                callbackManager->callOnError(error);
+               LoggerD("getAppsInfo error callback called");
                return;
        }
 
@@ -463,12 +481,14 @@ void ApplicationAsyncAnswerHandler::getAppsInfo(const EventApplicationGetAppsInf
                JSValueRef result = converter.toJSValueRef(appInfoArray);
 
                callbackManager->callOnSuccess(result);
+               LoggerD("getAppsInfo success callback called");
                return;
        } Catch(Exception) {
                LoggerE("error during processing answer" << _rethrown_exception.GetMessage());
                error = JSWebAPIErrorFactory::makeErrorObject(gContext, JSWebAPIErrorFactory::UNKNOWN_ERROR, "Internal error");
 
                callbackManager->callOnError(error);
+               LoggerD("getAppsInfo error callback called");
                return;
        }
 }
@@ -499,6 +519,7 @@ void ApplicationAsyncAnswerHandler::eventListener(const EventApplicationAppInfoE
                        }
                        JSValueRef result = converter.toJSValueRefFromApplicationInformation(appInfo);
                        callbackManager->callOnInstalled(result);
+                       LoggerD("AppInfoEvent oninstalled callback called");
                }
                else if(event->getType() == EventApplicationAppInfoEventListener::OnUpdated)
                {
@@ -510,6 +531,7 @@ void ApplicationAsyncAnswerHandler::eventListener(const EventApplicationAppInfoE
                        }
                        JSValueRef result = converter.toJSValueRefFromApplicationInformation(appInfo);
                        callbackManager->callOnUpdated(result);
+                       LoggerD("AppInfoEvent onupdated callback called");
                }
                else if(event->getType() == EventApplicationAppInfoEventListener::OnUninstalled)
                {
@@ -522,6 +544,7 @@ void ApplicationAsyncAnswerHandler::eventListener(const EventApplicationAppInfoE
                        }
                        JSValueRef result = converter.toJSValueRef(appId);
                        callbackManager->callOnUninstalled(result);
+                       LoggerD("AppInfoEvent onuninstalled callback called");
                }
                else
                {
old mode 100644 (file)
new mode 100755 (executable)
index 15b57b6..349afef
@@ -120,6 +120,8 @@ JSValueRef JSApplication::exit(JSContextRef context,
        const JSValueRef arguments[], 
        JSValueRef* exception) 
 {
+       LoggerD("exit called");
+
        TIME_TRACER_ITEM_BEGIN(__FUNCTION__, 0);
 
        try {
@@ -142,6 +144,8 @@ JSValueRef JSApplication::hide(JSContextRef context,
        const JSValueRef arguments[], 
        JSValueRef* exception) 
 {
+       LoggerD("hide called");
+
        TIME_TRACER_ITEM_BEGIN(__FUNCTION__, 0);
 
        try {
@@ -165,6 +169,8 @@ JSValueRef JSApplication::getRequestedAppControl(JSContextRef context,
        const JSValueRef arguments[], 
        JSValueRef* exception) 
 {
+       LoggerD("getRequestedAppControl called");
+
        TIME_TRACER_ITEM_BEGIN(__FUNCTION__, 0);
 
        JSApplicationPriv *priv = static_cast<JSApplicationPriv*>(JSObjectGetPrivate(thisObject));
old mode 100644 (file)
new mode 100755 (executable)
index 91e3a5a..ab0dcf1
@@ -224,6 +224,8 @@ JSValueRef JSApplicationInformation::getPropertySize(JSContextRef context,
        JSStringRef propertyName,
        JSValueRef* exception)
 {
+       LoggerD("getPropertySize called");
+
        JSApplicationInformationPriv *priv = static_cast<JSApplicationInformationPriv*>(JSObjectGetPrivate(object));
        if (!priv) {
                LoggerE("Private object is not exists.");
@@ -240,7 +242,6 @@ JSValueRef JSApplicationInformation::getPropertySize(JSContextRef context,
 
        try {
                CommonsJavaScript::Converter converter(context);
-               JSContextRef gContext = static_cast<JSApplicationInformationPriv*>(JSObjectGetPrivate(object))->getContext();
 
                if (!privateData->isInitialized()) {
                        AppManagerWrapperSingleton::Instance().initializeAppInfo(privateData);
old mode 100644 (file)
new mode 100755 (executable)
index 66f916c..2f209c8
@@ -148,6 +148,8 @@ JSValueRef JSApplicationManager::getCurrentApplication(JSContextRef context,
        const JSValueRef arguments[], 
        JSValueRef* exception) 
 {
+       LoggerD("getCurrentApplication called");
+
        TIME_TRACER_ITEM_BEGIN(__FUNCTION__, 0);
 
        try {
@@ -176,6 +178,8 @@ JSValueRef JSApplicationManager::launch(JSContextRef context,
        const JSValueRef arguments[], 
        JSValueRef* exception) 
 {
+       LoggerD("launch called");
+
        TIME_TRACER_ITEM_BEGIN(__FUNCTION__, 0);
        TIME_TRACER_ITEM_BEGIN("launch(async)", 0);
 
@@ -239,6 +243,8 @@ JSValueRef JSApplicationManager::kill(JSContextRef context,
        const JSValueRef arguments[], 
        JSValueRef* exception) 
 {
+       LoggerD("kill called");
+
        TIME_TRACER_ITEM_BEGIN(__FUNCTION__, 0);
        TIME_TRACER_ITEM_BEGIN("kill(async)", 0);
 
@@ -302,6 +308,8 @@ JSValueRef JSApplicationManager::setUserAgent(JSContextRef context,
        const JSValueRef arguments[],
        JSValueRef* exception)
 {
+       LoggerD("setUserAgent called");
+
        TIME_TRACER_ITEM_BEGIN(__FUNCTION__, 0);
 
        try {
@@ -332,6 +340,8 @@ JSValueRef JSApplicationManager::launchAppControl(JSContextRef context,
        const JSValueRef arguments[], 
        JSValueRef* exception) 
 {
+       LoggerD("launchAppControl called");
+
        TIME_TRACER_ITEM_BEGIN(__FUNCTION__, 0);
        TIME_TRACER_ITEM_BEGIN("launchAppControlReply", 0);
        TIME_TRACER_ITEM_BEGIN("launchAppControl(async)", 0);
@@ -438,6 +448,8 @@ JSValueRef JSApplicationManager::findAppControl(JSContextRef context,
        const JSValueRef arguments[],
        JSValueRef* exception)
 {
+       LoggerD("findAppControl called");
+
        TIME_TRACER_ITEM_BEGIN(__FUNCTION__, 0);
        TIME_TRACER_ITEM_BEGIN("findAppControl(async)", 0);
        try {
@@ -507,6 +519,8 @@ JSValueRef JSApplicationManager::getAppsContext(JSContextRef context,
        const JSValueRef arguments[], 
        JSValueRef* exception) 
 {
+       LoggerD("getAppsContext called");
+
        TIME_TRACER_ITEM_BEGIN(__FUNCTION__, 0);
        TIME_TRACER_ITEM_BEGIN("getAppsContext(async)", 0);
 
@@ -564,6 +578,8 @@ JSValueRef JSApplicationManager::getAppContext(JSContextRef context,
        const JSValueRef arguments[], 
        JSValueRef* exception) 
 {
+       LoggerD("getAppContext called");
+
        TIME_TRACER_ITEM_BEGIN(__FUNCTION__, 0);
 
        try {
@@ -593,6 +609,8 @@ JSValueRef JSApplicationManager::getAppsInfo(JSContextRef context,
        const JSValueRef arguments[], 
        JSValueRef* exception) 
 {
+       LoggerD("getAppsInfo called");
+
        TIME_TRACER_ITEM_BEGIN(__FUNCTION__, 0);
        TIME_TRACER_ITEM_BEGIN("getAppsInfo(async)", 0);
 
@@ -650,6 +668,8 @@ JSValueRef JSApplicationManager::getAppInfo(JSContextRef context,
        const JSValueRef arguments[], 
        JSValueRef* exception) 
 {
+       LoggerD("getAppInfo called");
+
        TIME_TRACER_ITEM_BEGIN(__FUNCTION__, 0);
 
        try {
@@ -684,6 +704,8 @@ JSValueRef JSApplicationManager::addAppInfoEventListener(JSContextRef context,
        const JSValueRef arguments[], 
        JSValueRef* exception) 
 {
+       LoggerD("addAppInfoEventListener called");
+
        TIME_TRACER_ITEM_BEGIN(__FUNCTION__, 0);
 
        try {
@@ -761,6 +783,8 @@ JSValueRef JSApplicationManager::removeAppInfoEventListener(JSContextRef context
         const JSValueRef arguments[],
         JSValueRef* exception)
 {
+       LoggerD("removeAppInfoEventListener called");
+
        TIME_TRACER_ITEM_BEGIN(__FUNCTION__, 0);
 
        try {
@@ -817,6 +841,8 @@ JSValueRef JSApplicationManager::getAppCerts(JSContextRef context,
        const JSValueRef arguments[],
        JSValueRef* exception)
 {
+       LoggerD("getAppCerts called");
+
        TIME_TRACER_ITEM_BEGIN(__FUNCTION__, 0);
 
        try {
@@ -856,6 +882,8 @@ JSValueRef JSApplicationManager::getAppSharedURI(JSContextRef context,
        const JSValueRef arguments[], 
        JSValueRef* exception) 
 {
+       LoggerD("getAppSharedURI called");
+
        TIME_TRACER_ITEM_BEGIN(__FUNCTION__, 0);
 
        try {
@@ -884,6 +912,8 @@ JSValueRef JSApplicationManager::getAppMetaData(JSContextRef context,
        const JSValueRef arguments[],
        JSValueRef* exception)
 {
+       LoggerD("getAppMetaData called");
+
        TIME_TRACER_ITEM_BEGIN(__FUNCTION__, 0);
 
        try {
old mode 100644 (file)
new mode 100755 (executable)
index 53aeed1..91a1ad2
@@ -185,6 +185,8 @@ JSValueRef JSRequestedApplicationControl::replyResult(JSContextRef context,
        const JSValueRef arguments[], 
        JSValueRef* exception) 
 {
+       LoggerD("replyResult called");
+
        TIME_TRACER_ITEM_BEGIN(__FUNCTION__, 0);
        JSRequestedApplicationControlPriv *priv = static_cast<JSRequestedApplicationControlPriv*>(JSObjectGetPrivate(thisObject));
 
@@ -227,6 +229,8 @@ JSValueRef JSRequestedApplicationControl::replyFailure(JSContextRef context,
        const JSValueRef arguments[], 
        JSValueRef* exception) 
 {
+       LoggerD("replyFailure called");
+
        TIME_TRACER_ITEM_BEGIN(__FUNCTION__, 0);
        JSRequestedApplicationControlPriv *priv = static_cast<JSRequestedApplicationControlPriv*>(JSObjectGetPrivate(thisObject));
 
index ee8328c..1673584 100755 (executable)
@@ -151,15 +151,14 @@ JSValueRef JSCalendar::add(JSContextRef context,
     CalendarPrivObject *privateObject =
         static_cast<CalendarPrivObject*>(JSObjectGetPrivate(thisObject));
 
-
-    TIZEN_CHECK_ACCESS(context, exception, privateObject, CALENDAR_FUNCTION_API_ADD);
-
     Try
     {
         if (!privateObject) {
             ThrowMsg(ConversionException, "Object is null.");
         }
 
+               TIZEN_CHECK_ACCESS(context, exception, privateObject, CALENDAR_FUNCTION_API_ADD);
+
         ICalendarPtr calendar = getCalendar(context, thisObject, NULL);
 
         if (argumentCount<1) {
@@ -231,14 +230,14 @@ JSValueRef JSCalendar::addBatch(JSContextRef context,
     CalendarPrivObject *privateObject =
         static_cast<CalendarPrivObject*>(JSObjectGetPrivate(thisObject));
 
-    TIZEN_CHECK_ACCESS(context, exception, privateObject, CALENDAR_FUNCTION_API_ADD_BATCH);
-
     Try
     {
         if (!privateObject) {
             ThrowMsg(ConversionException, "Object is null.");
         }
 
+               TIZEN_CHECK_ACCESS(context, exception, privateObject, CALENDAR_FUNCTION_API_ADD_BATCH);
+
         ICalendarPtr calendar = getCalendar(context, thisObject, NULL);
 
         JSContextRef globalContext = GlobalContextManager::getInstance()->getGlobalContext(context);
@@ -313,14 +312,14 @@ JSValueRef JSCalendar::update(JSContextRef context,
     CalendarPrivObject *privateObject =
         static_cast<CalendarPrivObject*>(JSObjectGetPrivate(thisObject));
 
-    TIZEN_CHECK_ACCESS(context, exception, privateObject, CALENDAR_FUNCTION_API_UPDATE);
-
     Try
     {
         if (!privateObject) {
             ThrowMsg(ConversionException, "Object is null.");
         }
 
+               TIZEN_CHECK_ACCESS(context, exception, privateObject, CALENDAR_FUNCTION_API_UPDATE);
+
         ICalendarPtr calendar = getCalendar(context, thisObject, exception);
 
         if (argumentCount<1) {
@@ -399,14 +398,14 @@ JSValueRef JSCalendar::updateBatch(JSContextRef context,
     CalendarPrivObject *privateObject =
         static_cast<CalendarPrivObject*>(JSObjectGetPrivate(thisObject));
 
-    TIZEN_CHECK_ACCESS(context, exception, privateObject, CALENDAR_FUNCTION_API_UPDATE_BATCH);
-
     Try
     {
         if (!privateObject) {
             ThrowMsg(ConversionException, "Object is null.");
         }
 
+               TIZEN_CHECK_ACCESS(context, exception, privateObject, CALENDAR_FUNCTION_API_UPDATE_BATCH);
+
         JSContextRef globalContext = GlobalContextManager::getInstance()->getGlobalContext(context);
 
         ICalendarPtr calendar = getCalendar(context, thisObject, exception);
@@ -493,14 +492,14 @@ JSValueRef JSCalendar::remove(JSContextRef context,
     CalendarPrivObject *privateObject =
         static_cast<CalendarPrivObject*>(JSObjectGetPrivate(thisObject));
 
-    TIZEN_CHECK_ACCESS(context, exception, privateObject, CALENDAR_FUNCTION_API_REMOVE);
-
     Try
     {
         if (!privateObject) {
             ThrowMsg(ConversionException, "Object is null.");
         }
 
+               TIZEN_CHECK_ACCESS(context, exception, privateObject, CALENDAR_FUNCTION_API_REMOVE);
+
         ICalendarPtr calendar = getCalendar(context, thisObject, exception);
 
         EventIdPtr itemId;
@@ -585,14 +584,14 @@ JSValueRef JSCalendar::removeBatch(JSContextRef context,
     CalendarPrivObject *privateObject =
         static_cast<CalendarPrivObject*>(JSObjectGetPrivate(thisObject));
 
-    TIZEN_CHECK_ACCESS(context, exception, privateObject, CALENDAR_FUNCTION_API_REMOVE_BATCH);
-
     Try
     {
         if (!privateObject) {
             ThrowMsg(ConversionException, "Object is null.");
         }
 
+               TIZEN_CHECK_ACCESS(context, exception, privateObject, CALENDAR_FUNCTION_API_REMOVE_BATCH);
+
         ICalendarPtr calendar = getCalendar(context, thisObject, exception);
         JSContextRef globalContext = GlobalContextManager::getInstance()->getGlobalContext(context);
 
@@ -698,14 +697,14 @@ JSValueRef JSCalendar::find(JSContextRef context,
     CalendarPrivObject *privateObject =
         static_cast<CalendarPrivObject*>(JSObjectGetPrivate(thisObject));
 
-    TIZEN_CHECK_ACCESS(context, exception, privateObject, CALENDAR_FUNCTION_API_FIND);
-
     Try
     {
         if (!privateObject) {
             ThrowMsg(ConversionException, "Object is null.");
         }
 
+               TIZEN_CHECK_ACCESS(context, exception, privateObject, CALENDAR_FUNCTION_API_FIND);
+
         ICalendarPtr calendar = getCalendar(context, thisObject, exception);
 
         JSContextRef globalContext = GlobalContextManager::getInstance()->getGlobalContext(context);
@@ -804,14 +803,14 @@ JSValueRef JSCalendar::get(JSContextRef context,
     CalendarPrivObject *privateObject =
         static_cast<CalendarPrivObject*>(JSObjectGetPrivate(thisObject));
 
-    TIZEN_CHECK_ACCESS(context, exception, privateObject, CALENDAR_FUNCTION_API_GET);
-
     Try
     {
         if (!privateObject) {
             ThrowMsg(ConversionException, "Object is null.");
         }
 
+               TIZEN_CHECK_ACCESS(context, exception, privateObject, CALENDAR_FUNCTION_API_GET);
+
         ICalendarPtr calendar = getCalendar(context, thisObject, exception);
         JSContextRef globalContext = GlobalContextManager::getInstance()->getGlobalContext(context);
 
@@ -905,14 +904,14 @@ JSValueRef JSCalendar::addChangeListener(JSContextRef context,
     CalendarPrivObject *privateObject =
         static_cast<CalendarPrivObject*>(JSObjectGetPrivate(thisObject));
 
-    TIZEN_CHECK_ACCESS(context, exception, privateObject, CALENDAR_FUNCTION_API_ADD_CHANGE_LISTENER);
-
     Try
     {
         if (!privateObject) {
             ThrowMsg(ConversionException, "Object is null.");
         }
 
+               TIZEN_CHECK_ACCESS(context, exception, privateObject, CALENDAR_FUNCTION_API_ADD_CHANGE_LISTENER);
+
         ICalendarPtr calendar = getCalendar(context, thisObject, exception);
         JSContextRef globalContext = GlobalContextManager::getInstance()->getGlobalContext(context);
 
@@ -1021,14 +1020,14 @@ JSValueRef JSCalendar::removeChangeListener(JSContextRef context,
     CalendarPrivObject *privateObject =
         static_cast<CalendarPrivObject*>(JSObjectGetPrivate(thisObject));
 
-    TIZEN_CHECK_ACCESS(context, exception, privateObject, CALENDAR_FUNCTION_API_REMOVE_CHANGE_LISTENER);
-
     Try
     {
         if (!privateObject) {
             ThrowMsg(ConversionException, "Object is null.");
         }
 
+               TIZEN_CHECK_ACCESS(context, exception, privateObject, CALENDAR_FUNCTION_API_REMOVE_CHANGE_LISTENER);
+
         ICalendarPtr calendar = getCalendar(context, thisObject, exception);
 
         JSContextRef globalContext = GlobalContextManager::getInstance()->getGlobalContext(context);
index 6ff19c7..31219fd 100755 (executable)
@@ -284,14 +284,14 @@ JSValueRef JSCalendarEvent::expandRecurrence(JSContextRef context,
     CalendarEventPrivObject *privateObject =
         static_cast<CalendarEventPrivObject*>(JSObjectGetPrivate(thisObject));
 
-    TIZEN_CHECK_ACCESS(context, exception, privateObject, CALENDAR_FUNCTION_API_EXPAND_RECURRENCE);
-
     Try
     {
         if (!privateObject) {
             ThrowMsg(ConversionException, "Object is null.");
         }
 
+               TIZEN_CHECK_ACCESS(context, exception, privateObject, CALENDAR_FUNCTION_API_EXPAND_RECURRENCE);
+
         CalendarEventPtr event = privateObject->getObject();
         if (!event) {
             ThrowMsg(ConversionException, "Parameter conversion failed.");
index 0391201..855e987 100755 (executable)
@@ -196,14 +196,14 @@ JSValueRef JSCalendarItemProperties::convertToString(JSContextRef context,
     CalendarItemPropertiesPrivObject *privateObject =
         static_cast<CalendarItemPropertiesPrivObject*>(JSObjectGetPrivate(thisObject));
 
-    TIZEN_CHECK_ACCESS(context, exception, privateObject, CALENDAR_FUNCTION_API_CONVERT_TO_STRING);
-
     Try
     {
         if (!privateObject) {
             ThrowMsg(ConversionException, "Object is null.");
         }
 
+               TIZEN_CHECK_ACCESS(context, exception, privateObject, CALENDAR_FUNCTION_API_CONVERT_TO_STRING);
+
         CalendarEventPtr item = privateObject->getObject();
         if (!item) {
             ThrowMsg(ConversionException, "Parameter conversion failed.");
@@ -274,14 +274,14 @@ JSValueRef JSCalendarItemProperties::clone(JSContextRef context,
     CalendarItemPropertiesPrivObject *privateObject =
         static_cast<CalendarItemPropertiesPrivObject*>(JSObjectGetPrivate(thisObject));
 
-    TIZEN_CHECK_ACCESS(context, exception, privateObject, CALENDAR_FUNCTION_API_CLONE);
-
     Try
     {
         if (!privateObject) {
             ThrowMsg(ConversionException, "Object is null.");
         }
 
+               TIZEN_CHECK_ACCESS(context, exception, privateObject, CALENDAR_FUNCTION_API_CLONE);
+
         CalendarEventPtr item = privateObject->getObject(); // item to copy
         if (!item) {
             ThrowMsg(ConversionException, "Parameter conversion failed.");
index 86dbe9d..8d6ebfc 100755 (executable)
@@ -115,13 +115,13 @@ JSValueRef JSCalendarManager::getCalendars(JSContextRef context,
        TIME_TRACER_ITEM_BEGIN(__FUNCTION__, 0);
     CalendarManagerPrivObject *privateObject = static_cast<CalendarManagerPrivObject*>(JSObjectGetPrivate(thisObject));
 
-    TIZEN_CHECK_ACCESS(context, exception, privateObject, CALENDAR_FUNCTION_API_GET_CALENDARS);
-
     Try {
         if (!privateObject) {
             ThrowMsg(ConversionException, "Object is null.");
         }
 
+               TIZEN_CHECK_ACCESS(context, exception, privateObject, CALENDAR_FUNCTION_API_GET_CALENDARS);
+
         CalendarConverter converter(context);
 
         JSContextRef globalContext = GlobalContextManager::getInstance()->getGlobalContext(context);
@@ -187,13 +187,13 @@ JSValueRef JSCalendarManager::getDefaultCalendar(JSContextRef context,
        TIME_TRACER_ITEM_BEGIN(__FUNCTION__, 0);
     CalendarManagerPrivObject *privateObject = static_cast<CalendarManagerPrivObject*>(JSObjectGetPrivate(thisObject));
 
-    TIZEN_CHECK_ACCESS(context, exception, privateObject, CALENDAR_FUNCTION_API_GET_DEFAULT_CALENDAR);
-
     Try {
         if (!privateObject) {
             ThrowMsg(ConversionException, "Object is null.");
         }
 
+               TIZEN_CHECK_ACCESS(context, exception, privateObject, CALENDAR_FUNCTION_API_GET_DEFAULT_CALENDAR);
+
                // Global context should be passed to the calendar object.
         JSContextRef globalContext = GlobalContextManager::getInstance()->getGlobalContext(context);
 
@@ -261,13 +261,13 @@ JSValueRef JSCalendarManager::getUnifiedCalendar(JSContextRef context,
        TIME_TRACER_ITEM_BEGIN(__FUNCTION__, 0);
     CalendarManagerPrivObject *privateObject = static_cast<CalendarManagerPrivObject*>(JSObjectGetPrivate(thisObject));
 
-    TIZEN_CHECK_ACCESS(context, exception, privateObject, CALENDAR_FUNCTION_API_GET_UNIFIED_CALENDAR);
-
     Try {
         if (!privateObject) {
             ThrowMsg(ConversionException, "Object is null.");
         }
 
+           TIZEN_CHECK_ACCESS(context, exception, privateObject, CALENDAR_FUNCTION_API_GET_UNIFIED_CALENDAR);
+
                // Global context should be passed to the calendar object.
         JSContextRef globalContext = GlobalContextManager::getInstance()->getGlobalContext(context);
 
@@ -335,13 +335,13 @@ JSValueRef JSCalendarManager::getCalendar(JSContextRef context,
        TIME_TRACER_ITEM_BEGIN(__FUNCTION__, 0);
     CalendarManagerPrivObject *privateObject = static_cast<CalendarManagerPrivObject*>(JSObjectGetPrivate(thisObject));
 
-    TIZEN_CHECK_ACCESS(context, exception, privateObject, CALENDAR_FUNCTION_API_GET_CALENDAR);
-
     Try {
         if (!privateObject) {
             ThrowMsg(ConversionException, "Object is null.");
         }
 
+               TIZEN_CHECK_ACCESS(context, exception, privateObject, CALENDAR_FUNCTION_API_GET_CALENDAR);
+
                // Global context should be passed to the calendar object.
         JSContextRef globalContext = GlobalContextManager::getInstance()->getGlobalContext(context);
 
index 2894ac8..9a635b6 100755 (executable)
@@ -600,7 +600,7 @@ void DataSyncManager::OnRequestReceived(const IEventUpdateProfilePtr &event)
                }
 
                ret = sync_agent_ds_update_profile(profile_h);
-               if (SYNC_AGENT_DS_SUCCESS!=ret) {
+               if (SYNC_AGENT_DS_SUCCESS!=ret && SYNC_AGENT_DS_SYNCHRONISING !=ret) {
                        ThrowMsg(NotFoundException, "Platform error while updating a profile: "<<ret);
                }
 
@@ -642,7 +642,7 @@ void DataSyncManager::OnRequestReceived(const IEventRemoveProfilePtr &event)
                }
 
                ret = sync_agent_ds_delete_profile(profile_h);
-               if (SYNC_AGENT_DS_SUCCESS!=ret) {
+               if (SYNC_AGENT_DS_SUCCESS!=ret && SYNC_AGENT_DS_SYNCHRONISING !=ret) {
                        ThrowMsg(PlatformException, "Platform error while deleting a profile: "<<ret);
                }
 
@@ -969,7 +969,7 @@ void DataSyncManager::OnRequestReceived(const IEventStartSyncPtr &event)
         }
 
                ret = sync_agent_ds_start_sync(profile_h);
-               if (SYNC_AGENT_DS_SUCCESS!=ret) {
+               if (SYNC_AGENT_DS_SUCCESS!=ret && SYNC_AGENT_DS_SYNCHRONISING !=ret) {
                        ThrowMsg(PlatformException, "Platform error while starting a profile: "<<ret);
                }
 
index 8bd5a57..3a401f5 100755 (executable)
@@ -195,6 +195,7 @@ JSValueRef JSPowerManager::unsetScreenStateChangeListener(JSContextRef context,
        TIME_TRACER_ITEM_BEGIN(__FUNCTION__, 0);
 
     PowerManagerPriv *thisPriv = static_cast<PowerManagerPriv*>(JSObjectGetPrivate(thisObject));
+    PowerManager::getInstance()->removeScreenStateChangedCallback(thisPriv);
 
        TIME_TRACER_ITEM_END(__FUNCTION__, 0);
     return JSValueMakeUndefined(context);
@@ -212,6 +213,7 @@ JSValueRef JSPowerManager::getScreenBrightness(JSContextRef context,
 
     try{
         double brightness = PowerManager::getInstance()->getScreenBrightness();
+        LoggerD("brightness : " << brightness);
                TIME_TRACER_ITEM_END(__FUNCTION__, 0);
         return JSUtil::toJSValueRef(context, brightness);
     }catch(const BasePlatformException& err){