From 9063736fd4ea10165e5f17bb41391ef2c03555e7 Mon Sep 17 00:00:00 2001 From: Charles Dang Date: Mon, 19 Mar 2018 16:59:44 +1100 Subject: [PATCH] Display: removed drawing_queue_ member This was the core of the surface-based drawing engine. Unused now. The drawing_queue_add() calls throughout the code have been left, but commented out, for reference while reimplementing things. The actual drawing_queue code has been left to, since its layers are referenced in places. Need to remove them. --- src/display.cpp | 1 - src/display.hpp | 35 ----------------------------------- src/whiteboard/attack.cpp | 4 ++-- 3 files changed, 2 insertions(+), 38 deletions(-) diff --git a/src/display.cpp b/src/display.cpp index fe8c057ecca8..d18bd41ce2b6 100644 --- a/src/display.cpp +++ b/src/display.cpp @@ -188,7 +188,6 @@ display::display(const display_context * dc, std::weak_ptr wb, repo , animate_water_(true) , flags_() , activeTeam_(0) - , drawing_queue_() , map_screenshot_(false) , reach_map_() , overlays_(nullptr) diff --git a/src/display.hpp b/src/display.hpp index 392931767d03..105178a72af5 100644 --- a/src/display.hpp +++ b/src/display.hpp @@ -1059,41 +1059,6 @@ class display : public video2::draw_layering // TODO sort std::size_t activeTeam_; - drawing_queue drawing_queue_; - -public: - drawing_queue& get_drawing_queue() - { - return drawing_queue_; - } - - /** - * Add an item to the drawing buffer. You need to update screen on affected area - * - */ - - void drawing_queue_add(const drawing_queue::layer, - const map_location&, - int, - int, - const surface&, - const SDL_Rect& clip = SDL_Rect()) - { - UNUSED(clip); - } - - void drawing_queue_add(const drawing_queue::layer, - const map_location&, - int, - int, - const std::vector&, - const SDL_Rect& clip = SDL_Rect()) - { - UNUSED(clip); - } - -protected: - /** Used to indicate to drawing functions that we are doing a map screenshot */ bool map_screenshot_; diff --git a/src/whiteboard/attack.cpp b/src/whiteboard/attack.cpp index 80bc4497008e..214c76ad8d82 100644 --- a/src/whiteboard/attack.cpp +++ b/src/whiteboard/attack.cpp @@ -183,8 +183,8 @@ void attack::draw_hex(const map_location& hex) int xpos = display::get_singleton()->get_location_x(get_dest_hex()); int ypos = display::get_singleton()->get_location_y(get_dest_hex()); - display::get_singleton()->drawing_queue_add(layer, get_dest_hex(), xpos, ypos, - image::get_image("whiteboard/attack-indicator-src-" + direction_text + ".png")); + //display::get_singleton()->drawing_queue_add(layer, get_dest_hex(), xpos, ypos, + // image::get_image("whiteboard/attack-indicator-src-" + direction_text + ".png")); } else if (hex == target_hex_) //add symbol to defender hex {