From f2890620d1a0b9c3bd9616195f7e260d46ca5324 Mon Sep 17 00:00:00 2001 From: lethosor Date: Thu, 18 Jan 2018 01:05:33 -0500 Subject: [PATCH] Remove tweak kitchen-keys - DF bug 614 was fixed --- dfhack.init-example | 1 - docs/Plugins.rst | 1 - plugins/tweak/tweak.cpp | 6 --- plugins/tweak/tweaks/kitchen-keys.h | 68 ----------------------------- 4 files changed, 76 deletions(-) delete mode 100644 plugins/tweak/tweaks/kitchen-keys.h diff --git a/dfhack.init-example b/dfhack.init-example index 3542956ce..75552006e 100644 --- a/dfhack.init-example +++ b/dfhack.init-example @@ -207,7 +207,6 @@ tweak civ-view-agreement tweak eggs-fertile tweak fps-min tweak hide-priority -tweak kitchen-keys tweak kitchen-prefs-empty tweak max-wheelbarrow tweak shift-8-scroll diff --git a/docs/Plugins.rst b/docs/Plugins.rst index 0ed65c4a3..04f5df321 100644 --- a/docs/Plugins.rst +++ b/docs/Plugins.rst @@ -311,7 +311,6 @@ Subcommands that persist until disabled or DF quits: :import-priority-category: Allows changing the priority of all goods in a category when discussing an import agreement with the liaison -:kitchen-keys: Fixes DF kitchen meal keybindings (:bug:`614`) :kitchen-prefs-color: Changes color of enabled items to green in kitchen preferences :kitchen-prefs-empty: Fixes a layout issue with empty kitchen tabs (:bug:`9000`) :max-wheelbarrow: Allows assigning more than 3 wheelbarrows to a stockpile diff --git a/plugins/tweak/tweak.cpp b/plugins/tweak/tweak.cpp index 417784efb..252f4c738 100644 --- a/plugins/tweak/tweak.cpp +++ b/plugins/tweak/tweak.cpp @@ -94,7 +94,6 @@ #include "tweaks/hide-priority.h" #include "tweaks/hotkey-clear.h" #include "tweaks/import-priority-category.h" -#include "tweaks/kitchen-keys.h" #include "tweaks/kitchen-prefs-color.h" #include "tweaks/kitchen-prefs-empty.h" #include "tweaks/max-wheelbarrow.h" @@ -218,8 +217,6 @@ DFhackCExport command_result plugin_init (color_ostream &out, std::vector (world->selected_building); - if (!ws) - return false; - if (ws->type != workshop_type::Kitchen) - return false; - return true; - } - - DEFINE_VMETHOD_INTERPOSE(void, feed, (std::set *input)) - { - if (kitchen_in_add()) - { - for (int i = 0; i < 4; i++) - { - if (input->count(kitchen_bindings[i])) - { - ui_sidebar_menus->workshop_job.cursor = i; - input->clear(); - input->insert(df::interface_key::SELECT); - } - } - } - INTERPOSE_NEXT(feed)(input); - } - - DEFINE_VMETHOD_INTERPOSE(void, render, ()) - { - INTERPOSE_NEXT(render)(); - if (kitchen_in_add()) - for (int i = 0; i < 3; i++) - draw_binding(i, kitchen_bindings[i]); - } -}; - -IMPLEMENT_VMETHOD_INTERPOSE(kitchen_keys_hook, feed); -IMPLEMENT_VMETHOD_INTERPOSE(kitchen_keys_hook, render);