summaryrefslogtreecommitdiff
path: root/src/gui/widgets/textbox.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/gui/widgets/textbox.cpp')
-rw-r--r--src/gui/widgets/textbox.cpp14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/gui/widgets/textbox.cpp b/src/gui/widgets/textbox.cpp
index 50e423de8..39e585279 100644
--- a/src/gui/widgets/textbox.cpp
+++ b/src/gui/widgets/textbox.cpp
@@ -582,29 +582,29 @@ void TextBox::addRow(const std::string &row)
adjustSize();
}
-void TextBox::mousePressed(MouseEvent& mouseEvent)
+void TextBox::mousePressed(MouseEvent& event)
{
- if (mouseEvent.getButton() == MouseEvent::LEFT)
+ if (event.getButton() == MouseEvent::LEFT)
{
const int height = getFont()->getHeight();
if (!height)
return;
- mouseEvent.consume();
- mCaretRow = mouseEvent.getY() / height;
+ event.consume();
+ mCaretRow = event.getY() / height;
const int sz = static_cast<int>(mTextRows.size());
if (mCaretRow >= sz)
mCaretRow = sz - 1;
mCaretColumn = getFont()->getStringIndexAt(
- mTextRows[mCaretRow], mouseEvent.getX());
+ mTextRows[mCaretRow], event.getX());
}
}
-void TextBox::mouseDragged(MouseEvent& mouseEvent)
+void TextBox::mouseDragged(MouseEvent& event)
{
- mouseEvent.consume();
+ event.consume();
}
void TextBox::drawCaret(Graphics *const graphics, const int x, const int y)