feat: allow setting roundedCorners
on Windows (#45594)
* feat: allow setting roundedCorners on Windows * Update docs/api/structures/base-window-options.md Co-authored-by: Will Anderson <will@itsananderson.com> --------- Co-authored-by: Will Anderson <will@itsananderson.com>
This commit is contained in:
parent
5ea885c87f
commit
340fdaf511
2 changed files with 9 additions and 3 deletions
|
@ -378,6 +378,11 @@ NativeWindowViews::NativeWindowViews(const gin_helper::Dictionary& options,
|
|||
if (!thick_frame_)
|
||||
frame_style &= ~(WS_THICKFRAME | WS_CAPTION);
|
||||
::SetWindowLong(GetAcceleratedWidget(), GWL_STYLE, frame_style);
|
||||
|
||||
bool rounded_corner = true;
|
||||
options.Get(options::kRoundedCorners, &rounded_corner);
|
||||
if (!rounded_corner)
|
||||
SetRoundedCorners(false);
|
||||
}
|
||||
|
||||
LONG ex_style = ::GetWindowLong(GetAcceleratedWidget(), GWL_EXSTYLE);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue