From 5fc61f321cbe6c8f4a4e6529c27603302f3d5eba Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Wed, 15 Jul 2015 02:37:23 +0300 Subject: Update existing item after inserting card. --- src/gui/popups/itempopup.cpp | 5 +++++ src/gui/popups/itempopup.h | 2 ++ 2 files changed, 7 insertions(+) (limited to 'src/gui/popups') diff --git a/src/gui/popups/itempopup.cpp b/src/gui/popups/itempopup.cpp index 2374f693b..33b2eba91 100644 --- a/src/gui/popups/itempopup.cpp +++ b/src/gui/popups/itempopup.cpp @@ -330,6 +330,11 @@ void ItemPopup::mouseMoved(MouseEvent &event) // When the mouse moved on top of the popup, hide it setVisible(Visible_false); + resetPopup(); +} + +void ItemPopup::resetPopup() +{ mLastName.clear(); mLastColor = 1; mLastId = 0; diff --git a/src/gui/popups/itempopup.h b/src/gui/popups/itempopup.h index 6072bc90c..fb3feefa2 100644 --- a/src/gui/popups/itempopup.h +++ b/src/gui/popups/itempopup.h @@ -68,6 +68,8 @@ class ItemPopup final : public Popup void mouseMoved(MouseEvent &event) override final; + void resetPopup(); + private: std::string getCardsString(const int *const cards); -- cgit v1.2.3-70-g09d2