fix: split fullscreen functions

This commit is contained in:
rbrugo 2023-11-07 11:26:06 +01:00 committed by ArthurSonzogni
parent 044c2684e7
commit 77169b618d
No known key found for this signature in database
GPG Key ID: 41D98248C074CD6C
2 changed files with 14 additions and 3 deletions

View File

@ -31,8 +31,9 @@ class ScreenInteractive : public Screen {
// Constructors:
static ScreenInteractive FixedSize(int dimx, int dimy);
static ScreenInteractive Fullscreen();
static ScreenInteractive FullscreenPrimaryScreen();
static ScreenInteractive FitComponent();
static ScreenInteractive TerminalOutput(bool use_alternative_screen = true);
static ScreenInteractive TerminalOutput();
// Options. Must be called before Loop().
void TrackMouse(bool enable = true);

View File

@ -353,12 +353,22 @@ ScreenInteractive ScreenInteractive::FixedSize(int dimx, int dimy) {
}
// static
ScreenInteractive ScreenInteractive::Fullscreen(bool use_alternative_screen) {
ScreenInteractive ScreenInteractive::Fullscreen() {
return {
0,
0,
Dimension::Fullscreen,
use_alternative_screen,
true,
};
}
// static
ScreenInteractive ScreenInteractive::FullscreenPrimaryScreen() {
return {
0,
0,
Dimension::Fullscreen,
false,
};
}