summaryrefslogtreecommitdiff
path: root/src/gui/itempopup.cpp
diff options
context:
space:
mode:
authorDavid Athay <ko2fan@gmail.com>2009-01-13 12:48:36 +0000
committerIra Rice <irarice@gmail.com>2009-01-20 10:54:07 -0700
commit088ccc74d9b8695c906eaabae8e4019ebf55c83c (patch)
tree8054c8531d721a7555b2c2b46c7b43adbad9b9d2 /src/gui/itempopup.cpp
parent114559b98b7e8c94b1d84d4d450309fd16ed2a38 (diff)
downloadmana-client-088ccc74d9b8695c906eaabae8e4019ebf55c83c.tar.gz
mana-client-088ccc74d9b8695c906eaabae8e4019ebf55c83c.tar.bz2
mana-client-088ccc74d9b8695c906eaabae8e4019ebf55c83c.tar.xz
mana-client-088ccc74d9b8695c906eaabae8e4019ebf55c83c.zip
Added WoW style item adding to chat window. Right click, then left
clicking on add to chat to put the item in the chat input. Left click the item link to show a popup description, and click the link again to remove the popup.
Diffstat (limited to 'src/gui/itempopup.cpp')
-rw-r--r--src/gui/itempopup.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/gui/itempopup.cpp b/src/gui/itempopup.cpp
index 5f7dc736..c0a75193 100644
--- a/src/gui/itempopup.cpp
+++ b/src/gui/itempopup.cpp
@@ -50,6 +50,7 @@ ItemPopup::ItemPopup():
// Item Description
mItemDesc = new TextBox();
mItemDesc->setEditable(false);
+ mItemDesc->setMinWidth(186);
mItemDescScroll = new ScrollArea(mItemDesc);
mItemDescScroll->setHorizontalScrollPolicy(gcn::ScrollArea::SHOW_NEVER);
@@ -61,6 +62,7 @@ ItemPopup::ItemPopup():
// Item Effect
mItemEffect = new TextBox();
mItemEffect->setEditable(false);
+ mItemEffect->setMinWidth(186);
mItemEffectScroll = new ScrollArea(mItemEffect);
mItemEffectScroll->setHorizontalScrollPolicy(gcn::ScrollArea::SHOW_NEVER);
@@ -98,11 +100,9 @@ void ItemPopup::setItem(const ItemInfo &item)
int numRowsEffect = mItemEffect->getNumberOfRows();
if(item.getEffect() == "")
- {
setContentSize(200, (numRowsDesc * 14) + 30);
- } else {
+ else
setContentSize(200, (numRowsDesc * 14) + (numRowsEffect * 14) + 30);
- }
mItemDescScroll->setDimension(gcn::Rectangle(2, 0, 196, numRowsDesc * 14));