From 3fbd9e6cf291387f50a580de8bb1195dac3b1143 Mon Sep 17 00:00:00 2001 From: David Robillard Date: Tue, 20 Sep 2016 08:55:33 -0400 Subject: Fix C++ bindings --- pugl/pugl.hpp | 17 +---------------- 1 file changed, 1 insertion(+), 16 deletions(-) diff --git a/pugl/pugl.hpp b/pugl/pugl.hpp index d405759..8232887 100644 --- a/pugl/pugl.hpp +++ b/pugl/pugl.hpp @@ -38,9 +38,6 @@ public: { puglSetHandle(_view, this); puglSetEventFunc(_view, _onEvent); - puglSetCloseFunc(_view, _onClose); - puglSetReshapeFunc(_view, _onReshape); - puglSetDisplayFunc(_view, _onDisplay); } virtual ~View() { puglDestroy(_view); } @@ -81,10 +78,7 @@ public: virtual void hideWindow() { puglHideWindow(_view); } virtual PuglNativeWindow getNativeWindow() { return puglGetNativeWindow(_view); } - virtual void onEvent(const PuglEvent* event) {} - virtual void onClose() {} - virtual void onReshape(int width, int height) {} - virtual void onDisplay() {} + virtual void onEvent(const PuglEvent* event) = 0; virtual void* getContext() { return puglGetContext(_view); } virtual void ignoreKeyRepeat(bool ignore) { puglIgnoreKeyRepeat(_view, ignore); } @@ -99,15 +93,6 @@ private: static void _onEvent(PuglView* view, const PuglEvent* event) { ((View*)puglGetHandle(view))->onEvent(event); } - static void _onClose(PuglView* view) { - ((View*)puglGetHandle(view))->onClose(); - } - static void _onReshape(PuglView* view, int width, int height) { - ((View*)puglGetHandle(view))->onReshape(width, height); - } - static void _onDisplay(PuglView* view) { - ((View*)puglGetHandle(view))->onDisplay(); - } PuglView* _view; }; -- cgit v1.2.1