Change deprecated internal api to public api 16/171916/1 accepted/tizen/unified/20180316.062506 submit/tizen/20180315.052738
authorpr.jung <pr.jung@samsung.com>
Thu, 8 Mar 2018 06:07:23 +0000 (15:07 +0900)
committerpr.jung <pr.jung@samsung.com>
Thu, 8 Mar 2018 06:17:52 +0000 (15:17 +0900)
- libdeviced haptic apis are deprecated
- Changed to use capi-system-device apis

Change-Id: I7c592774f379620aec1ddae9a60f43cb0694c6ef
Signed-off-by: pr.jung <pr.jung@samsung.com>
packaging/crosswalk-tizen.spec
runtime/browser/vibration_manager.cc
runtime/runtime.gyp

index 945b02e..0c24483 100755 (executable)
@@ -31,7 +31,7 @@ BuildRequires: pkgconfig(capi-system-info)
 BuildRequires: pkgconfig(capi-ui-efl-util)
 BuildRequires: pkgconfig(chromium-efl) >= 56.0.0, pkgconfig(chromium-efl) < 57.0.0
 BuildRequires: pkgconfig(cynara-client)
-BuildRequires: pkgconfig(deviced)
+BuildRequires: pkgconfig(capi-system-device)
 BuildRequires: pkgconfig(dlog)
 BuildRequires: pkgconfig(ecore)
 BuildRequires: pkgconfig(efl-extension)
index 0e6cfcd..301b20c 100755 (executable)
@@ -16,7 +16,7 @@
 
 #include "runtime/browser/vibration_manager.h"
 
-#include <dd-haptic.h>
+#include <device/haptic.h>
 
 #include "common/logger.h"
 
@@ -42,7 +42,7 @@ VibrationImpl::VibrationImpl()
 
 VibrationImpl::~VibrationImpl() {
   if (handle_ != 0) {
-    haptic_close(handle_);
+    device_haptic_close(handle_);
     handle_ = 0;
   }
 }
@@ -51,8 +51,8 @@ bool VibrationImpl::Initialize() {
   if (handle_ != 0)
     return true;
 
-  int ret = haptic_open(HAPTIC_DEVICE_0, &handle_);
-  if (ret != HAPTIC_ERROR_NONE) {
+  int ret = device_haptic_open(0, &handle_);
+  if (ret != DEVICE_ERROR_NONE) {
     LOGGER(ERROR) << "Fail to open haptic device";
     handle_ = 0;
     return false;
@@ -62,13 +62,13 @@ bool VibrationImpl::Initialize() {
 
 void VibrationImpl::Start(int ms) {
   if (Initialize()) {
-    haptic_vibrate_monotone(handle_, ms, NULL);
+    device_haptic_vibrate(handle_, ms, 100, NULL);
   }
 }
 
 void VibrationImpl::Stop() {
   if (Initialize()) {
-    haptic_stop_all_effects(handle_);
+    device_haptic_stop(handle_, NULL);
   }
 }
 
index ce48619..5772a35 100755 (executable)
@@ -57,7 +57,7 @@
           'ecore',
           'elementary',
           'efl-extension',
-          'deviced',
+          'capi-system-device',
           'manifest-parser',
           'wgt-manifest-handlers',
           'notification',