summaryrefslogtreecommitdiff
path: root/src/gui
diff options
context:
space:
mode:
authorBjørn Lindeijer <bjorn@lindeijer.nl>2006-10-01 14:47:42 +0000
committerBjørn Lindeijer <bjorn@lindeijer.nl>2006-10-01 14:47:42 +0000
commit935ff1e5cdd0bc44d5de947cb06ee30871b870eb (patch)
tree986a94e587b724c93b4a051de1676324fc10b42a /src/gui
parentfc0b308983f9421861e508381f73a0605eeed5b7 (diff)
downloadmana-935ff1e5cdd0bc44d5de947cb06ee30871b870eb.tar.gz
mana-935ff1e5cdd0bc44d5de947cb06ee30871b870eb.tar.bz2
mana-935ff1e5cdd0bc44d5de947cb06ee30871b870eb.tar.xz
mana-935ff1e5cdd0bc44d5de947cb06ee30871b870eb.zip
Accepted patches by GDO and VictorSan that fix problems with hiding windows
using h and problems with trade window positioning.
Diffstat (limited to 'src/gui')
-rw-r--r--src/gui/inventorywindow.cpp1
-rw-r--r--src/gui/trade.cpp10
2 files changed, 6 insertions, 5 deletions
diff --git a/src/gui/inventorywindow.cpp b/src/gui/inventorywindow.cpp
index 5812a71a..eb85220b 100644
--- a/src/gui/inventorywindow.cpp
+++ b/src/gui/inventorywindow.cpp
@@ -49,6 +49,7 @@ InventoryWindow::InventoryWindow():
setResizable(true);
setMinWidth(240);
setMinHeight(172);
+ // If you adjust these defaults, don't forget to adjust the trade window's.
setDefaultSize(115, 25, 322, 172);
mUseButton = new Button("Use", "use", this);
diff --git a/src/gui/trade.cpp b/src/gui/trade.cpp
index cb839157..b83c6ee6 100644
--- a/src/gui/trade.cpp
+++ b/src/gui/trade.cpp
@@ -51,7 +51,8 @@ TradeWindow::TradeWindow(Network *network):
mMyInventory(new Inventory()),
mPartnerInventory(new Inventory())
{
- setContentSize(322, 150);
+ setWindowName("Trade");
+ setDefaultSize(115,197,322,150);
mAddButton = new Button("Add", "add", this);
mOkButton = new Button("Ok", "ok", this);
@@ -104,12 +105,12 @@ TradeWindow::TradeWindow(Network *network):
mMoneyLabel->setPosition(8 + 60 + 50 + 6, getHeight() - 20);
mMoneyLabel2->setPosition(8, getHeight() - 20);
- mCancelButton->setPosition(getWidth() - 48, getHeight() - 49);
- mTradeButton->setPosition(mCancelButton->getX() - 40
+ mCancelButton->setPosition(getWidth() - 54, getHeight() - 49);
+ mTradeButton->setPosition(mCancelButton->getX() - 41
, getHeight() - 49);
mOkButton->setPosition(mTradeButton->getX() - 24,
getHeight() - 49);
- mAddButton->setPosition(mOkButton->getX() - 32,
+ mAddButton->setPosition(mOkButton->getX() - 31,
getHeight() - 49);
mMyItemContainer->setSize(getWidth() - 24 - 12 - 1,
@@ -125,7 +126,6 @@ TradeWindow::TradeWindow(Network *network):
mItemDescriptionLabel->setPosition(8,
mItemNameLabel->getY() + mItemNameLabel->getHeight() + 4);
- setContentSize(getWidth(), getHeight());
}
TradeWindow::~TradeWindow()