Skip to content

Commit

Permalink
fixed scrollview
Browse files Browse the repository at this point in the history
  • Loading branch information
nekitu committed Aug 29, 2018
1 parent fc35d19 commit 6da2d08
Show file tree
Hide file tree
Showing 5 changed files with 10 additions and 7 deletions.
1 change: 0 additions & 1 deletion examples/common/sfml_input_provider.h
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
#include "horus.h"
#include <horus_interfaces.h>
#define SFML_STATIC
#include <SFML/System.hpp>
#include <SFML/Window.hpp>
#include <SFML/OpenGL.hpp>
Expand Down
4 changes: 3 additions & 1 deletion generate.cmd
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
set VSVER=vs2017
IF EXIST vs2015 set VSVER=vs2015
premake5 %VSVER%
premake5 %VSVER%

xcopy .\3rdparty\sfml\win64\bin\*.* .\bin /c /q /i /e /h /y
8 changes: 4 additions & 4 deletions premake5.lua
Original file line number Diff line number Diff line change
Expand Up @@ -253,18 +253,18 @@ function link_sfml()
includedirs {scriptRoot.."/3rdparty/sfml/win64/include"}
libdirs {scriptRoot.."/3rdparty/sfml/win64/lib"}
filter { "system:windows", "configurations:Debug" }
links { "freetype", "sfml-window-s-d", "sfml-system-s-d", "sfml-graphics-s-d", "sfml-audio-s-d" }
links { "freetype", "sfml-window-d", "sfml-system-d", "sfml-graphics-d", "sfml-audio-d" }
filter { "system:windows", "configurations:Release" }
links { "freetype", "sfml-window-s", "sfml-system-s", "sfml-graphics-s", "sfml-audio-s" }
links { "freetype", "sfml-window", "sfml-system", "sfml-graphics", "sfml-audio" }
filter {}

filter {"system:linux"}
includedirs {scriptRoot.."/3rdparty/sfml/linux/include"}
libdirs {scriptRoot.."/3rdparty/sfml/linux/lib"}
filter { "system:linux", "configurations:Debug" }
links { "freetype", "sfml-window-s-d", "sfml-system-s-d", "sfml-graphics-s-d", "sfml-audio-s-d" }
links { "freetype", "sfml-window-d", "sfml-system-d", "sfml-graphics-d", "sfml-audio-d" }
filter { "system:linux", "configurations:Release" }
links { "freetype", "sfml-window-s", "sfml-system-s", "sfml-graphics-s", "sfml-audio-s" }
links { "freetype", "sfml-window", "sfml-system", "sfml-graphics", "sfml-audio" }
filter {}

filter {"system:macosx"}
Expand Down
1 change: 1 addition & 0 deletions src/native_dialogs.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
#include "util.h"
#include "3rdparty/nativefiledialog/src/include/nfd.h"
#include <string.h>
#include <algorithm>

namespace hui
{
Expand Down
3 changes: 2 additions & 1 deletion src/scrollview_widget.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -160,7 +160,8 @@ f32 endScrollView()
}
}
}
else if (ctx->scrollViewStack[ctx->scrollViewDepth].draggingThumb
else if (ctx->mouseMoved
&& ctx->scrollViewStack[ctx->scrollViewDepth].draggingThumb
&& ctx->dragScrollViewHandleWidgetId == ctx->scrollViewStack[ctx->scrollViewDepth].widgetId)
{
f32 crtLocalY = ctx->event.mouse.point.y - ctx->scrollViewStack[ctx->scrollViewDepth].dragDelta.y - clipRect.y;
Expand Down

0 comments on commit 6da2d08

Please sign in to comment.