From 5f39885975dcd73a9589ce9be0aeb908eebc3450 Mon Sep 17 00:00:00 2001 From: Perttu Ahola Date: Mon, 17 Oct 2011 01:03:45 +0300 Subject: [PATCH] Improve inventory debug output --- src/guiInventoryMenu.cpp | 21 ++++++----- src/inventory.cpp | 80 ++++++++++++++++++++++++---------------- 2 files changed, 59 insertions(+), 42 deletions(-) diff --git a/src/guiInventoryMenu.cpp b/src/guiInventoryMenu.cpp index 165d4d86..7d49acaa 100644 --- a/src/guiInventoryMenu.cpp +++ b/src/guiInventoryMenu.cpp @@ -27,6 +27,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #include #include #include +#include "log.h" void drawInventoryItem(video::IVideoDriver *driver, gui::IGUIFont *font, @@ -326,11 +327,11 @@ bool GUIInventoryMenu::OnEvent(const SEvent& event) if(amount >= 0) { v2s32 p(event.MouseInput.X, event.MouseInput.Y); - //dstream<<"Mouse down at p=("<getList(s.listname); if(list_from == NULL) - dstream<<"from list doesn't exist"<getItem(m_selected_item->i) != NULL) { - dstream<<"Handing IACTION_MOVE to manager"<count = amount; a->from_inv = m_selected_item->inventoryname; @@ -408,7 +409,7 @@ bool GUIInventoryMenu::OnEvent(const SEvent& event) { if(!canTakeFocus(event.GUIEvent.Element)) { - dstream<<"GUIInventoryMenu: Not allowing focus change." + infostream<<"GUIInventoryMenu: Not allowing focus change." <getList(from_list); InventoryList *list_to = inv_to->getList(to_list); - /*dstream<<"list_from="<getItem(from_i)="<getItem(from_i) - <getItem(to_i)="<getItem(to_i) - <getItem(from_i) == NULL) { - dstream<<__FUNCTION_NAME<<": Operation not allowed " - <<"(the source item doesn't exist)" - <