summaryrefslogtreecommitdiff
path: root/src/guichan/gui.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2013-05-31 23:59:16 +0300
committerAndrei Karas <akaras@inbox.ru>2013-05-31 23:59:16 +0300
commit4e596c5929ff5b773caeda3fcf0de9ca89602b37 (patch)
treee937dba7b85f2beb2aa9f1d65abedddf6299888e /src/guichan/gui.cpp
parent0e37aebef74df6221df8f219572b9abe2ed0f3fd (diff)
downloadmanaverse-4e596c5929ff5b773caeda3fcf0de9ca89602b37.tar.gz
manaverse-4e596c5929ff5b773caeda3fcf0de9ca89602b37.tar.bz2
manaverse-4e596c5929ff5b773caeda3fcf0de9ca89602b37.tar.xz
manaverse-4e596c5929ff5b773caeda3fcf0de9ca89602b37.zip
Change mouserelease gui function.
Diffstat (limited to 'src/guichan/gui.cpp')
-rw-r--r--src/guichan/gui.cpp43
1 files changed, 0 insertions, 43 deletions
diff --git a/src/guichan/gui.cpp b/src/guichan/gui.cpp
index d363bdc9b..fcfe58bef 100644
--- a/src/guichan/gui.cpp
+++ b/src/guichan/gui.cpp
@@ -416,49 +416,6 @@ namespace gcn
mouseInput.getY());
}
- void Gui::handleMouseReleased(const MouseInput& mouseInput)
- {
- Widget* sourceWidget = getMouseEventSource(
- mouseInput.getX(), mouseInput.getY());
-
- if (mFocusHandler->getDraggedWidget())
- {
- if (sourceWidget != mFocusHandler->getLastWidgetPressed())
- mFocusHandler->setLastWidgetPressed(nullptr);
-
- sourceWidget = mFocusHandler->getDraggedWidget();
- }
-
- int sourceWidgetX, sourceWidgetY;
- sourceWidget->getAbsolutePosition(sourceWidgetX, sourceWidgetY);
-
- distributeMouseEvent(sourceWidget,
- MouseEvent::RELEASED,
- mouseInput.getButton(),
- mouseInput.getX(),
- mouseInput.getY());
-
- if (mouseInput.getButton() == mLastMousePressButton
- && mFocusHandler->getLastWidgetPressed() == sourceWidget)
- {
- distributeMouseEvent(sourceWidget,
- MouseEvent::CLICKED,
- mouseInput.getButton(),
- mouseInput.getX(),
- mouseInput.getY());
-
- mFocusHandler->setLastWidgetPressed(nullptr);
- }
- else
- {
- mLastMousePressButton = 0;
- mClickCount = 0;
- }
-
- if (mFocusHandler->getDraggedWidget())
- mFocusHandler->setDraggedWidget(nullptr);
- }
-
Widget* Gui::getWidgetAt(int x, int y)
{
// If the widget's parent has no child then we have found the widget..