forked from mirror/OpenTTD
Remove: DOS support
In 10 years there was no active development on DOS. Although it turned out to still work, the FPS was very bad. There is little interest in the current community to look into this. Further more, we like to switch to c++11 functions for threads, which are not implemented by DJGPP, the only current compiler for DOS. Additionally, DOS is the only platform which does not support networking. It is the reason we have tons of #ifdefs to support disabling networking. By removing DOS support, we can both use c++11 functions for threads, and remove all the code related to disabling network. Sadly, this means we have to see DOS go. Of course, if you feel up for the task, simply revert this commit, and implement stub c++11 functions for threads and stub functions for networking. We are more than happy to accept such Pull Request.
This commit is contained in:
@@ -440,12 +440,6 @@ const char *VideoDriver_Allegro::Start(const char * const *parm)
|
||||
signal(SIGSEGV, NULL);
|
||||
#endif
|
||||
|
||||
#if defined(DOS)
|
||||
/* Force DOS builds to ALWAYS use full screen as
|
||||
* it can't do windowed. */
|
||||
_fullscreen = true;
|
||||
#endif
|
||||
|
||||
GetVideoModes();
|
||||
if (!CreateMainSurface(_cur_resolution.width, _cur_resolution.height)) {
|
||||
return "Failed to set up Allegro video";
|
||||
@@ -461,7 +455,7 @@ void VideoDriver_Allegro::Stop()
|
||||
if (--_allegro_instance_count == 0) allegro_exit();
|
||||
}
|
||||
|
||||
#if defined(UNIX) || defined(__OS2__) || defined(DOS)
|
||||
#if defined(UNIX) || defined(__OS2__)
|
||||
# include <sys/time.h> /* gettimeofday */
|
||||
|
||||
static uint32 GetTime()
|
||||
@@ -548,9 +542,6 @@ bool VideoDriver_Allegro::ChangeResolution(int w, int h)
|
||||
|
||||
bool VideoDriver_Allegro::ToggleFullscreen(bool fullscreen)
|
||||
{
|
||||
#ifdef DOS
|
||||
return false;
|
||||
#else
|
||||
_fullscreen = fullscreen;
|
||||
GetVideoModes(); // get the list of available video modes
|
||||
if (_num_resolutions == 0 || !this->ChangeResolution(_cur_resolution.width, _cur_resolution.height)) {
|
||||
@@ -559,7 +550,6 @@ bool VideoDriver_Allegro::ToggleFullscreen(bool fullscreen)
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
#endif
|
||||
}
|
||||
|
||||
bool VideoDriver_Allegro::AfterBlitterChange()
|
||||
|
Reference in New Issue
Block a user