2012-04-21 10:51:01 +02:00
|
|
|
#ifndef MGUI_Inventory_H
|
|
|
|
#define MGUI_Inventory_H
|
|
|
|
|
|
|
|
#include "container.hpp"
|
2012-05-12 22:44:12 +02:00
|
|
|
#include "window_pinnable_base.hpp"
|
|
|
|
|
2012-04-21 10:51:01 +02:00
|
|
|
namespace MWWorld
|
|
|
|
{
|
|
|
|
class Environment;
|
|
|
|
}
|
|
|
|
|
|
|
|
namespace MyGUI
|
|
|
|
{
|
|
|
|
class Gui;
|
|
|
|
class Widget;
|
|
|
|
}
|
|
|
|
|
|
|
|
namespace MWGui
|
|
|
|
{
|
|
|
|
class WindowManager;
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
namespace MWGui
|
|
|
|
{
|
2012-05-12 22:44:12 +02:00
|
|
|
class InventoryWindow : public ContainerBase, public WindowPinnableBase
|
2012-04-21 10:51:01 +02:00
|
|
|
{
|
|
|
|
public:
|
2012-05-11 11:52:07 +02:00
|
|
|
InventoryWindow(WindowManager& parWindowManager,DragAndDrop* dragAndDrop);
|
2012-04-21 11:05:30 +02:00
|
|
|
|
|
|
|
void openInventory();
|
2012-05-12 18:24:47 +02:00
|
|
|
|
2012-05-15 22:45:46 +02:00
|
|
|
virtual void notifyContentChanged();
|
|
|
|
|
2012-05-12 18:24:47 +02:00
|
|
|
protected:
|
2012-05-12 21:28:04 +02:00
|
|
|
MyGUI::Widget* mAvatar;
|
|
|
|
MyGUI::TextBox* mArmorRating;
|
|
|
|
MyGUI::ProgressBar* mEncumbranceBar;
|
|
|
|
MyGUI::TextBox* mEncumbranceText;
|
|
|
|
|
2012-05-13 11:25:35 +02:00
|
|
|
MyGUI::Widget* mLeftPane;
|
|
|
|
MyGUI::Widget* mRightPane;
|
|
|
|
|
2012-05-12 21:28:04 +02:00
|
|
|
MyGUI::Button* mFilterAll;
|
|
|
|
MyGUI::Button* mFilterWeapon;
|
|
|
|
MyGUI::Button* mFilterApparel;
|
|
|
|
MyGUI::Button* mFilterMagic;
|
|
|
|
MyGUI::Button* mFilterMisc;
|
|
|
|
|
2012-05-12 18:24:47 +02:00
|
|
|
void onWindowResize(MyGUI::Window* _sender);
|
2012-05-12 21:44:33 +02:00
|
|
|
void onFilterChanged(MyGUI::Widget* _sender);
|
2012-05-15 18:05:53 +02:00
|
|
|
void onAvatarClicked(MyGUI::Widget* _sender);
|
2012-05-12 22:44:12 +02:00
|
|
|
void onPinToggled();
|
2012-05-15 18:05:53 +02:00
|
|
|
|
2012-05-15 22:45:46 +02:00
|
|
|
void updateEncumbranceBar();
|
|
|
|
|
2012-05-15 18:05:53 +02:00
|
|
|
virtual bool isInventory() { return true; }
|
2012-05-15 20:33:34 +02:00
|
|
|
virtual std::vector<MWWorld::Ptr> getEquippedItems();
|
|
|
|
virtual void _unequipItem(MWWorld::Ptr item);
|
2012-04-21 10:51:01 +02:00
|
|
|
};
|
|
|
|
}
|
|
|
|
#endif // Inventory_H
|