From 026ff0407158b5a33727b1e5b857983359631c91 Mon Sep 17 00:00:00 2001 From: Gergely Nagy Date: Mon, 20 Aug 2018 23:04:11 +0200 Subject: [PATCH] Drop the V1 plugin API compatibility code Signed-off-by: Gergely Nagy --- src/Kaleidoscope/HostPowerManagement.cpp | 14 -------------- src/Kaleidoscope/HostPowerManagement.h | 10 ---------- 2 files changed, 24 deletions(-) diff --git a/src/Kaleidoscope/HostPowerManagement.cpp b/src/Kaleidoscope/HostPowerManagement.cpp index da7bacd5..46f8053f 100644 --- a/src/Kaleidoscope/HostPowerManagement.cpp +++ b/src/Kaleidoscope/HostPowerManagement.cpp @@ -54,20 +54,6 @@ EventHandlerResult HostPowerManagement::beforeEachCycle() { return EventHandlerResult::OK; } -// Legacy V1 API -#if KALEIDOSCOPE_ENABLE_V1_PLUGIN_API -void HostPowerManagement::begin() { - Kaleidoscope.useLoopHook(legacyLoopHook); -} - -void HostPowerManagement::legacyLoopHook(bool is_post_clear) { - if (is_post_clear) - return; - - ::HostPowerManagement.beforeEachCycle(); -} -#endif - } __attribute__((weak)) void hostPowerManagementEventHandler(kaleidoscope::HostPowerManagement::Event event) { diff --git a/src/Kaleidoscope/HostPowerManagement.h b/src/Kaleidoscope/HostPowerManagement.h index 72a0826f..61b8716b 100644 --- a/src/Kaleidoscope/HostPowerManagement.h +++ b/src/Kaleidoscope/HostPowerManagement.h @@ -40,16 +40,6 @@ class HostPowerManagement : public kaleidoscope::Plugin { EventHandlerResult beforeEachCycle(); -#if KALEIDOSCOPE_ENABLE_V1_PLUGIN_API - kaleidoscope::EventHandlerResult onSetup() { - return kaleidoscope::EventHandlerResult::OK; - } - - protected: - void begin(); - static void legacyLoopHook(bool is_post_clear); -#endif - private: static bool was_suspended_; static bool initial_suspend_;