Make default wakeup policy to choose the first wakeup event 22/276322/1
authorJi-hoon Lee <dalton.lee@samsung.com>
Tue, 14 Jun 2022 12:26:38 +0000 (21:26 +0900)
committerJi-hoon Lee <dalton.lee@samsung.com>
Tue, 14 Jun 2022 12:29:51 +0000 (21:29 +0900)
Change-Id: I9c7ca76a001983198d6ffbb458911e28aceffac3

plugins/wakeup-manager/src/wakeup_policy_default.cpp

index ab8d01f..a7844ca 100644 (file)
@@ -93,12 +93,8 @@ void CWakeupPolicyDefault::wakeup_candidate(mas_wakeup_event_info wakeup_info)
        mWakeupInfos.push_back(wrapper);
        if (nullptr == mTimer) {
                ecore_main_loop_thread_safe_call_async([](void* data) {
-                       CWakeupPolicyDefault* policy = static_cast<CWakeupPolicyDefault*>(data);
-                       if (!policy) return;
-
-                       Ecore_Timer* timer = ecore_timer_add(policy->get_delay(), timer_func, data);
-                       MWR_LOGI("Adding timer : %f", policy->get_delay());
-                       policy->set_timer(timer);
+                       /* Assume that choosing the first wakeup event is the default behavior */
+                       timer_func(data);
                }, this);
        }
 }