From 581cc9e1331fdc37072430a70c49455858b19ac5 Mon Sep 17 00:00:00 2001 From: Shelley Vohr Date: Wed, 23 Feb 2022 11:52:30 +0100 Subject: [PATCH] fix: also check max_size empty --- shell/browser/native_window.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/shell/browser/native_window.cc b/shell/browser/native_window.cc index 90c2b8630abcb..6e42c30304943 100644 --- a/shell/browser/native_window.cc +++ b/shell/browser/native_window.cc @@ -177,7 +177,7 @@ void NativeWindow::InitFromOptions(const gin_helper::Dictionary& options) { // By default the window has a default maximum size that prevents it // from being resized larger than the screen, so we should only set this // if th user has passed in values. - if (have_max_height || have_max_width) + if (have_max_height || have_max_width || !max_size.IsEmpty()) size_constraints.set_maximum_size(gfx::Size(max_width, max_height)); if (use_content_size) {