summaryrefslogtreecommitdiff
path: root/src/gui/browserbox.cpp
diff options
context:
space:
mode:
authorBjørn Lindeijer <bjorn@lindeijer.nl>2007-01-14 14:54:39 +0000
committerBjørn Lindeijer <bjorn@lindeijer.nl>2007-01-14 14:54:39 +0000
commitf842e0b40d8382011f0bc46b1446945d99ac0425 (patch)
tree5ddbb7c146a8ece28a4260d788350b1c2cf0dbed /src/gui/browserbox.cpp
parentcbbcc5489e2f72a76b66ae849cbe8f1dc44246ca (diff)
downloadmana-f842e0b40d8382011f0bc46b1446945d99ac0425.tar.gz
mana-f842e0b40d8382011f0bc46b1446945d99ac0425.tar.bz2
mana-f842e0b40d8382011f0bc46b1446945d99ac0425.tar.xz
mana-f842e0b40d8382011f0bc46b1446945d99ac0425.zip
Upgraded to Guichan 0.6.0 (merge from guichan-0.6.0 branch).
Diffstat (limited to 'src/gui/browserbox.cpp')
-rw-r--r--src/gui/browserbox.cpp15
1 files changed, 9 insertions, 6 deletions
diff --git a/src/gui/browserbox.cpp b/src/gui/browserbox.cpp
index 2aec84a5..65fdde64 100644
--- a/src/gui/browserbox.cpp
+++ b/src/gui/browserbox.cpp
@@ -98,7 +98,7 @@ void BrowserBox::disableLinksAndUserColors()
mUseLinksAndUserColors = false;
}
-void BrowserBox::addRow(const std::string& row)
+void BrowserBox::addRow(const std::string &row)
{
std::string tmp = row;
std::string newRow;
@@ -238,25 +238,28 @@ struct MouseOverLink
int mX, mY;
};
-void BrowserBox::mousePress(int mx, int my, int button)
+void
+BrowserBox::mousePressed(gcn::MouseEvent &event)
{
LinkIterator i = find_if(mLinks.begin(), mLinks.end(),
- MouseOverLink(mx, my));
+ MouseOverLink(event.getX(), event.getY()));
if (i != mLinks.end()) {
mLinkHandler->handleLink(i->link);
}
}
-void BrowserBox::mouseMotion(int mx, int my)
+void
+BrowserBox::mouseMoved(gcn::MouseEvent &event)
{
LinkIterator i = find_if(mLinks.begin(), mLinks.end(),
- MouseOverLink(mx, my));
+ MouseOverLink(event.getX(), event.getY()));
mSelectedLink = (i != mLinks.end()) ? (i - mLinks.begin()) : -1;
}
-void BrowserBox::draw(gcn::Graphics* graphics)
+void
+BrowserBox::draw(gcn::Graphics *graphics)
{
if (mOpaque)
{