Changeset - r25007:c39f47be967b
[Not reviewed]
master
0 4 0
Patric Stout - 4 years ago 2021-03-08 15:57:59
truebrain@openttd.org
Fix #8784: using alt+enter didn't update the fullscreen toggle visibly (#8820)

Basically, the window was not invalidated, so it was never redrawn.
This made it look like it wasn't working, but it really was.
4 files changed with 7 insertions and 1 deletions:
0 comments (0 inline, 0 general)
src/video/cocoa/cocoa_v.mm
Show inline comments
 
@@ -201,6 +201,7 @@ bool VideoDriver_Cocoa::ToggleFullscreen
 
		[ NSMenu setMenuBarVisible:!full_screen ];
 

	
 
		this->UpdateVideoModes();
 
		InvalidateWindowClassesData(WC_GAME_OPTIONS, 3);
 
		return true;
 
	}
 

	
src/video/sdl2_v.cpp
Show inline comments
 
@@ -761,6 +761,7 @@ bool VideoDriver_SDL_Base::ToggleFullscr
 
		DEBUG(driver, 0, "SDL_SetWindowFullscreen() failed: %s", SDL_GetError());
 
	}
 

	
 
	InvalidateWindowClassesData(WC_GAME_OPTIONS, 3);
 
	return ret == 0;
 
}
 

	
src/video/sdl_v.cpp
Show inline comments
 
@@ -763,6 +763,7 @@ bool VideoDriver_SDL::ToggleFullscreen(b
 
		_fullscreen ^= true;
 
	}
 

	
 
	InvalidateWindowClassesData(WC_GAME_OPTIONS, 3);
 
	return ret;
 
}
 

	
src/video/win32_v.cpp
Show inline comments
 
@@ -967,7 +967,10 @@ bool VideoDriver_Win32Base::ToggleFullsc
 
	std::unique_lock<std::recursive_mutex> lock;
 
	if (this->draw_mutex != nullptr) lock = std::unique_lock<std::recursive_mutex>(*this->draw_mutex);
 

	
 
	return this->MakeWindow(full_screen);
 
	bool res = this->MakeWindow(full_screen);
 

	
 
	InvalidateWindowClassesData(WC_GAME_OPTIONS, 3);
 
	return res;
 
}
 

	
 
void VideoDriver_Win32Base::AcquireBlitterLock()
0 comments (0 inline, 0 general)