mirror of
https://github.com/panda3d/panda3d.git
synced 2025-09-30 16:58:40 -04:00
eliminate old win_height, win_width, win_origin_x, win_origin_y
This commit is contained in:
parent
98f9a10dd6
commit
d502a2489e
@ -184,22 +184,10 @@ ConfigVariableInt win_size
|
||||
"replaces the deprecated win-width and win-height variables."));
|
||||
|
||||
ConfigVariableInt win_origin
|
||||
("win-origin", "0 0",
|
||||
("win-origin", "",
|
||||
PRC_DESC("This is the default position at which to open a new window. This "
|
||||
"replaces the deprecated win-origin-x and win-origin-y variables."));
|
||||
|
||||
ConfigVariableInt win_width
|
||||
("win-width", 0);
|
||||
|
||||
ConfigVariableInt win_height
|
||||
("win-height", 0);
|
||||
|
||||
ConfigVariableInt win_origin_x
|
||||
("win-origin-x", 0);
|
||||
|
||||
ConfigVariableInt win_origin_y
|
||||
("win-origin-y", 0);
|
||||
|
||||
ConfigVariableBool fullscreen
|
||||
("fullscreen", false);
|
||||
|
||||
|
@ -63,10 +63,6 @@ extern EXPCL_PANDA ConfigVariableBool color_scale_via_lighting;
|
||||
|
||||
extern EXPCL_PANDA ConfigVariableInt win_size;
|
||||
extern EXPCL_PANDA ConfigVariableInt win_origin;
|
||||
extern EXPCL_PANDA ConfigVariableInt win_width;
|
||||
extern EXPCL_PANDA ConfigVariableInt win_height;
|
||||
extern EXPCL_PANDA ConfigVariableInt win_origin_x;
|
||||
extern EXPCL_PANDA ConfigVariableInt win_origin_y;
|
||||
extern EXPCL_PANDA ConfigVariableBool fullscreen;
|
||||
extern EXPCL_PANDA ConfigVariableBool undecorated;
|
||||
extern EXPCL_PANDA ConfigVariableBool cursor_hidden;
|
||||
|
@ -61,23 +61,13 @@ get_default() {
|
||||
|
||||
props.set_open(true);
|
||||
|
||||
if (win_width.has_value() && win_height.has_value() &&
|
||||
!win_size.has_value()) {
|
||||
props.set_size(win_width, win_height);
|
||||
|
||||
} else {
|
||||
if (win_size.get_num_words() == 1) {
|
||||
props.set_size(win_size[0], win_size[0]);
|
||||
} else {
|
||||
props.set_size(win_size[0], win_size[1]);
|
||||
}
|
||||
if (win_size.get_num_words() == 1) {
|
||||
props.set_size(win_size[0], win_size[0]);
|
||||
} else if (win_size.get_num_words() >= 2) {
|
||||
props.set_size(win_size[0], win_size[1]);
|
||||
}
|
||||
|
||||
if (win_origin_x.has_value() && win_origin_y.has_value() &&
|
||||
!win_origin.has_value()) {
|
||||
props.set_origin(win_origin_x, win_origin_y);
|
||||
|
||||
} else {
|
||||
if (win_origin.get_num_words() >= 2) {
|
||||
props.set_origin(win_origin[0], win_origin[1]);
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user