From b476086c394c6bcf893f292ef67565ef2b5496a2 Mon Sep 17 00:00:00 2001 From: rubidium Date: Mon, 28 Apr 2014 21:06:51 +0000 Subject: (svn r26538) -Codechange: remove double accounting of the drivers --- src/video/video_driver.hpp | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'src/video/video_driver.hpp') diff --git a/src/video/video_driver.hpp b/src/video/video_driver.hpp index 190bfcc10..916044d35 100644 --- a/src/video/video_driver.hpp +++ b/src/video/video_driver.hpp @@ -78,9 +78,15 @@ public: * An edit box lost the input focus. Abort character compositing if necessary. */ virtual void EditBoxLostFocus() {} + + /** + * Get the currently active instance of the video driver. + */ + static VideoDriver *GetInstance() { + return static_cast(*DriverFactoryBase::GetActiveDriver(Driver::DT_VIDEO)); + } }; -extern VideoDriver *_video_driver; extern char *_ini_videodriver; extern int _num_resolutions; extern Dimension _resolutions[32]; -- cgit v1.2.3-54-g00ecf