Skip to content

Commit 65b54c5

Browse files
committed
Fixed clicking the close button of a window also initiating a drag. (#24)
1 parent 4cbc0f8 commit 65b54c5

1 file changed

Lines changed: 1 addition & 0 deletions

File tree

src/SFGUI/Window.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -172,6 +172,7 @@ void Window::HandleMouseButtonEvent( sf::Mouse::Button button, bool press, int x
172172

173173
if( close_rect.contains( static_cast<float>( x ), static_cast<float>( y ) ) ) {
174174
GetSignals().Emit( OnCloseButton );
175+
return;
175176
}
176177
}
177178

0 commit comments

Comments
 (0)