Skip to content

Commit

Permalink
#5567: Fix initial size of dialog if no settings are found in the reg…
Browse files Browse the repository at this point in the history
…istry
  • Loading branch information
codereader committed Apr 2, 2021
1 parent 35960fc commit 024d783
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
6 changes: 6 additions & 0 deletions libs/wxutil/WindowPosition.cpp
Expand Up @@ -110,6 +110,12 @@ void WindowPosition::applyPosition()
{
if (_window == nullptr) return;

if (_size[0] == 0 || _size[1] == 0)
{
// Don't apply empty sizes
return;
}

// On multi-monitor setups, wxWidgets offers a virtual big screen with
// coordinates going from 0,0 to whatever lower-rightmost point there is

Expand Down
2 changes: 1 addition & 1 deletion radiant/ui/materials/editor/MaterialEditor.cpp
Expand Up @@ -169,7 +169,7 @@ MaterialEditor::MaterialEditor() :
setupMaterialDeformPage();

// Set the default size of the window
FitToScreen(0.8f, 0.6f);
FitToScreen(0.8f, 0.9f);

Layout();
Fit();
Expand Down

0 comments on commit 024d783

Please sign in to comment.