View Single Post
02-11-20, 01:39 AM   #1
gmarco
An Onyxian Warder
 
gmarco's Avatar
AddOn Author - Click to view addons
Join Date: Dec 2009
Posts: 362
System Preferences - Graphics

Hi everyone,

I'd like to make a little addon to switch from full screen to windowed mode.

The problem is that the system preferences do it so nicely:



While a simple code to switch from a mode to the other like this:

Lua Code:
  1. C_CVar.SetCVar("gxMaximize", "1")
  2. RestartGx()

or

Lua Code:
  1. C_CVar.SetCVar("gxMaximize", "0")
  2. C_CVar.SetCVar("gxWindowedResolution", "1790x1007")
  3. RestartGx()

freeze for a little bit the game and is not as perfect as the first.

So the question.
How is, if any, the best way to achieve this ?

Thanks so much.
__________________
This is Unix-Land. In quiet nights, you can hear the Windows machines reboot.
  Reply With Quote