From a5b3bda1045078766fd24c64f73bbcc93dd2ac03 Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Tue, 9 Oct 2012 21:35:00 +0300 Subject: Fix type casting in itemamount window class. --- src/gui/itemamountwindow.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/gui/itemamountwindow.cpp b/src/gui/itemamountwindow.cpp index 3e22246b5..1751f6043 100644 --- a/src/gui/itemamountwindow.cpp +++ b/src/gui/itemamountwindow.cpp @@ -388,18 +388,18 @@ void ItemAmountWindow::action(const gcn::ActionEvent &event) if (event.getId() == "incPrice") { mPrice++; - price = static_cast(pow(10, mPrice)); + price = static_cast(pow(10.0, mPrice)); } else if (event.getId() == "decPrice") { mPrice--; - price = static_cast(pow(10, mPrice)); + price = static_cast(pow(10.0, mPrice)); } else if (event.getId() == "slidePrice") { price = static_cast(mItemPriceSlide->getValue()); if (price) - mPrice = static_cast(log(price)); + mPrice = static_cast(log(static_cast(price))); else mPrice = 0; } -- cgit v1.2.3-60-g2f50