From ef9c335dc3bd7da0bc66135576e52915aa1d03b0 Mon Sep 17 00:00:00 2001 From: "pr.jung" Date: Thu, 8 Mar 2018 15:07:23 +0900 Subject: [PATCH] Change deprecated internal api to public api - libdeviced haptic apis are deprecated - Changed to use capi-system-device apis Change-Id: I7c592774f379620aec1ddae9a60f43cb0694c6ef Signed-off-by: pr.jung --- packaging/crosswalk-tizen.spec | 2 +- runtime/browser/vibration_manager.cc | 12 ++++++------ runtime/runtime.gyp | 2 +- 3 files changed, 8 insertions(+), 8 deletions(-) diff --git a/packaging/crosswalk-tizen.spec b/packaging/crosswalk-tizen.spec index 945b02e..0c24483 100755 --- a/packaging/crosswalk-tizen.spec +++ b/packaging/crosswalk-tizen.spec @@ -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) diff --git a/runtime/browser/vibration_manager.cc b/runtime/browser/vibration_manager.cc index 0e6cfcd..301b20c 100755 --- a/runtime/browser/vibration_manager.cc +++ b/runtime/browser/vibration_manager.cc @@ -16,7 +16,7 @@ #include "runtime/browser/vibration_manager.h" -#include +#include #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); } } diff --git a/runtime/runtime.gyp b/runtime/runtime.gyp index ce48619..5772a35 100755 --- a/runtime/runtime.gyp +++ b/runtime/runtime.gyp @@ -57,7 +57,7 @@ 'ecore', 'elementary', 'efl-extension', - 'deviced', + 'capi-system-device', 'manifest-parser', 'wgt-manifest-handlers', 'notification', -- 2.7.4