From 1d64816653b5d1835dd60762c2bc64f000d88fa5 Mon Sep 17 00:00:00 2001 From: Chris Xiong Date: Thu, 7 Jan 2016 23:54:06 +0800 Subject: Add a new way to hook into smelt. --- include/smelt.hpp | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'include') diff --git a/include/smelt.hpp b/include/smelt.hpp index 5435d15..4651814 100644 --- a/include/smelt.hpp +++ b/include/smelt.hpp @@ -71,6 +71,10 @@ typedef size_t SMCHN;//Audio channel Handle //callback function pointer typedef bool (*smHook)(); +class smHandler +{ + public: virtual bool handlerFunc()=0; +}; //Special FPS modes //Unlimited FPS @@ -167,6 +171,7 @@ public: * It returns true when you want to terminate the main loop. */ virtual void smUpdateFunc(smHook func)=0; + virtual void smUpdateFunc(smHandler* h)=0; /** * Sets the focus lost function. * Focus lost function is called when the application window loses -- cgit v1.2.3