diff options
author | rubidium <rubidium@openttd.org> | 2014-04-28 21:06:51 +0000 |
---|---|---|
committer | rubidium <rubidium@openttd.org> | 2014-04-28 21:06:51 +0000 |
commit | b476086c394c6bcf893f292ef67565ef2b5496a2 (patch) | |
tree | 7bbdfcc4597cae1378070d82c5da36c8668171e0 /src/driver.h | |
parent | 3b634b628c8b8ce30cdd11d38a38cf2f455a1c73 (diff) | |
download | openttd-b476086c394c6bcf893f292ef67565ef2b5496a2.tar.xz |
(svn r26538) -Codechange: remove double accounting of the drivers
Diffstat (limited to 'src/driver.h')
-rw-r--r-- | src/driver.h | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/src/driver.h b/src/driver.h index a466d67d0..12ca4474d 100644 --- a/src/driver.h +++ b/src/driver.h @@ -59,6 +59,10 @@ DECLARE_POSTFIX_INCREMENT(Driver::Type) /** Base for all driver factories. */ class DriverFactoryBase { private: + friend class MusicDriver; + friend class SoundDriver; + friend class VideoDriver; + Driver::Type type; ///< The type of driver. int priority; ///< The priority of this factory. const char *name; ///< The name of the drivers of this factory. @@ -97,6 +101,8 @@ private: return driver_type_name[type]; } + static bool SelectDriverImpl(const char *name, Driver::Type type); + protected: DriverFactoryBase(Driver::Type type, int priority, const char *name, const char *description); @@ -114,7 +120,7 @@ public: } } - static Driver *SelectDriver(const char *name, Driver::Type type); + static void SelectDriver(const char *name, Driver::Type type); static char *GetDriversInfo(char *p, const char *last); /** |