From 337a52a41ea44570da65586403f14248042f0169 Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Thu, 29 Jun 2017 21:44:11 +0300 Subject: Use std::move in some places. --- src/gui/popups/itempopup.cpp | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) (limited to 'src/gui/popups/itempopup.cpp') diff --git a/src/gui/popups/itempopup.cpp b/src/gui/popups/itempopup.cpp index 5c5dfd19e..5179627e1 100644 --- a/src/gui/popups/itempopup.cpp +++ b/src/gui/popups/itempopup.cpp @@ -34,7 +34,14 @@ #include "gui/widgets/label.h" #include "gui/widgets/textbox.h" +#include "net/beinghandler.h" +#include "net/net.h" + +#include "utils/foreach.h" #include "utils/gettext.h" +#include "utils/stdmove.h" + +#include "utils/translation/podict.h" #include "resources/iteminfo.h" @@ -49,13 +56,6 @@ #include "resources/loaders/imageloader.h" -#include "net/beinghandler.h" -#include "net/net.h" - -#include "utils/foreach.h" - -#include "utils/translation/podict.h" - #include "debug.h" ItemPopup *itemPopup = nullptr; @@ -208,8 +208,8 @@ void ItemPopup::setItem(const ItemInfo &item, cardsStr = getCardsString(cards); optionsStr = getOptionsString(options); } - mItemOptionsStr = optionsStr; - mCardsStr = cardsStr; + mItemOptionsStr = STD_MOVE(optionsStr); + mCardsStr = STD_MOVE(cardsStr); if (id == -1) id = item.getId(); @@ -269,7 +269,7 @@ void ItemPopup::setItem(const ItemInfo &item, mItemWeight->setTextWrapped(strprintf(_("Weight: %s"), UnitsDb::formatWeight(item.getWeight()).c_str()), 196); mItemCards->setTextWrapped(mCardsStr, 196); - mItemOptions->setTextWrapped(optionsStr, 196); + mItemOptions->setTextWrapped(mItemOptionsStr, 196); int minWidth = mItemName->getWidth() + space; -- cgit v1.2.3-70-g09d2