Only expand maximum size constraint if there was a constraint originally (#13003)
This commit is contained in:
parent
156a97b80d
commit
8b2bffcf9e
1 changed files with 3 additions and 1 deletions
|
@ -288,7 +288,9 @@ gfx::Size NativeWindow::GetContentMinimumSize() const {
|
||||||
gfx::Size NativeWindow::GetContentMaximumSize() const {
|
gfx::Size NativeWindow::GetContentMaximumSize() const {
|
||||||
gfx::Size maximum_size = GetContentSizeConstraints().GetMaximumSize();
|
gfx::Size maximum_size = GetContentSizeConstraints().GetMaximumSize();
|
||||||
#if defined(OS_WIN)
|
#if defined(OS_WIN)
|
||||||
return GetExpandedWindowSize(this, maximum_size);
|
return GetContentSizeConstraints().HasMaximumSize()
|
||||||
|
? GetExpandedWindowSize(this, maximum_size)
|
||||||
|
: maximum_size;
|
||||||
#else
|
#else
|
||||||
return maximum_size;
|
return maximum_size;
|
||||||
#endif
|
#endif
|
||||||
|
|
Loading…
Reference in a new issue