Commit 9d1fe94 1 parent 103f69c commit 9d1fe94 Copy full SHA for 9d1fe94
File tree 3 files changed +12
-7
lines changed
3 files changed +12
-7
lines changed Original file line number Diff line number Diff line change 9
9
10
10
#include " matsig.h"
11
11
#include " memberproperties.h"
12
- #include " style.h"
12
+ #include " paint.h"
13
+ #include < string>
13
14
14
15
namespace matgui {
15
16
@@ -47,7 +48,7 @@ class View {
47
48
48
49
// ! Trigger a redraw
49
50
virtual void invalidate ();
50
- virtual void refresh (){};
51
+ virtual void refresh () {};
51
52
virtual void updateStyle () {
52
53
currentStyle = style;
53
54
currentStyle += hoverStyle;
Original file line number Diff line number Diff line change @@ -4,16 +4,20 @@ RUNSTRING=./${TARGET}
4
4
OBJECTS =signal-test.o font-test.o shadertranslate-test.o
5
5
LIBS = -lpthread ` sdl2-config --libs ` -lGL -lSDL2_ttf -lSDL2_image
6
6
CXXFLAGS =-g -std=c++14 -O0 ` sdl2-config --cflags ` -I"../include/" -Imls-unit-test
7
+ CXXFLAGS =-g -std=c++17 -O0 ` sdl2-config --cflags ` -I"../include/" -Imls-unit-test
7
8
CXXFLAGS+ = -MMD -MF $* .d # For calculating dependencies
8
9
TESTS=${OBJECTS:.o= }
9
10
10
11
LINKFLAGS =${FLAGS} ../matgui-sdl.a ${LIBS}
11
12
12
13
all : ${TESTS}
13
14
14
- % -test : % -test.o ../matgui-sdl.a
15
+ main.o : mls-unit-test/test_main.cpp
16
+ ${CXX} -o $@ $< ${CXXFLAGS}
17
+
18
+ % -test : % -test.o ../matgui-sdl.a main.o
15
19
@echo " test" $<
16
- ${CXX} -o $@ $< ${LINKFLAGS}
20
+ ${CXX} -o $@ $< main.o ${LINKFLAGS} -std=c++17
17
21
18
22
-include *.d
19
23
Original file line number Diff line number Diff line change 5
5
* Author: Mattias Larsson Sköld
6
6
*/
7
7
8
- // #define DO_NOT_CATCH_ERRORS
8
+ // #define DO_NOT_CATCH_ERRORS
9
9
10
10
#include " matgui/matsig.h"
11
11
#include " mls-unit-test/unittest.h"
12
- #include < thread>
13
12
14
13
using namespace MatSig ;
15
14
using namespace std ;
@@ -53,7 +52,7 @@ static void globalArgumentFunction(int i) {
53
52
functionIsCalled = true ;
54
53
}
55
54
56
- TEST_SUIT_BEGIN
55
+ TEST_SUIT_BEGIN (MatguiSignal)
57
56
58
57
TEST_CASE(" void signal callback" ) {
59
58
Signal<void > signal ;
@@ -136,6 +135,7 @@ TEST_CASE("lambda void argument function") {
136
135
flushSignals ();
137
136
138
137
ASSERT (isCalled, " the function not called" );
138
+
139
139
ASSERT_EQ (y, 5 );
140
140
141
141
isCalled = false ;
You can’t perform that action at this time.
0 commit comments