Drop the V1 plugin API compatibility code

Signed-off-by: Gergely Nagy <algernon@keyboard.io>
pull/365/head
Gergely Nagy 6 years ago
parent 282926214a
commit 026ff04071

@ -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) {

@ -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_;

Loading…
Cancel
Save