summaryrefslogtreecommitdiff
path: root/src/gui/widgets/guitable.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2014-03-21 19:45:48 +0300
committerAndrei Karas <akaras@inbox.ru>2014-03-21 19:45:48 +0300
commit60b40c0c68e9cffbc5f48d4f672d99009488f8b1 (patch)
tree7d2efefb965c0ae928eb80313f2f37fa34cf42b4 /src/gui/widgets/guitable.cpp
parent3ed0b5f6edce152fa2eca9c84d64cbeec8ac0173 (diff)
downloadmv-60b40c0c68e9cffbc5f48d4f672d99009488f8b1.tar.gz
mv-60b40c0c68e9cffbc5f48d4f672d99009488f8b1.tar.bz2
mv-60b40c0c68e9cffbc5f48d4f672d99009488f8b1.tar.xz
mv-60b40c0c68e9cffbc5f48d4f672d99009488f8b1.zip
Rename mouseEvent variables into event.
Diffstat (limited to 'src/gui/widgets/guitable.cpp')
-rw-r--r--src/gui/widgets/guitable.cpp26
1 files changed, 13 insertions, 13 deletions
diff --git a/src/gui/widgets/guitable.cpp b/src/gui/widgets/guitable.cpp
index 08da80322..44248037c 100644
--- a/src/gui/widgets/guitable.cpp
+++ b/src/gui/widgets/guitable.cpp
@@ -465,56 +465,56 @@ void GuiTable::keyPressed(KeyEvent& keyEvent)
}
// -- MouseListener notifications
-void GuiTable::mousePressed(MouseEvent& mouseEvent)
+void GuiTable::mousePressed(MouseEvent& event)
{
if (!mModel || !mSelectable)
return;
- if (mouseEvent.getButton() == MouseEvent::LEFT)
+ if (event.getButton() == MouseEvent::LEFT)
{
- const int row = getRowForY(mouseEvent.getY());
- const int column = getColumnForX(mouseEvent.getX());
+ const int row = getRowForY(event.getY());
+ const int column = getColumnForX(event.getX());
if (row > -1 && column > -1 &&
row < mModel->getRows() && column < mModel->getColumns())
{
mSelectedColumn = column;
mSelectedRow = row;
- mouseEvent.consume();
+ event.consume();
}
distributeActionEvent();
}
}
-void GuiTable::mouseWheelMovedUp(MouseEvent& mouseEvent)
+void GuiTable::mouseWheelMovedUp(MouseEvent& event)
{
if (isFocused())
{
const int selRow = getSelectedRow();
if (selRow > 0 || (selRow == 0 && mWrappingEnabled))
setSelectedRow(selRow - 1);
- mouseEvent.consume();
+ event.consume();
}
}
-void GuiTable::mouseWheelMovedDown(MouseEvent& mouseEvent)
+void GuiTable::mouseWheelMovedDown(MouseEvent& event)
{
if (isFocused())
{
setSelectedRow(getSelectedRow() + 1);
- mouseEvent.consume();
+ event.consume();
}
}
-void GuiTable::mouseDragged(MouseEvent& mouseEvent)
+void GuiTable::mouseDragged(MouseEvent& event)
{
- if (mouseEvent.getButton() != MouseEvent::LEFT)
+ if (event.getButton() != MouseEvent::LEFT)
return;
// Make table selection update on drag
- const int x = std::max(0, mouseEvent.getX());
- const int y = std::max(0, mouseEvent.getY());
+ const int x = std::max(0, event.getX());
+ const int y = std::max(0, event.getY());
setSelectedRow(getRowForY(y));
setSelectedColumn(getColumnForX(x));