ckerr

#46917: refactor: add NativeWindow::FromWidget() helper

Merged
Created: May 3, 2025, 12:33:22 PM
Merged: May 5, 2025, 10:27:41 AM
4 comments
Target: main

Description of Change

Add a helper method static NativeWindow* NativeWindow::FromWidget(const views::Widget*) to simplify client code: instead of knowing about the native window property values and kElectronNativeWindowKey, it just calls a getter instead.

Checklist

Release Notes

Notes: none.

Backports

36-x-y
Merged
PR Number
#46932
Merged At
May 6, 2025, 3:51:12 AM
Released In
Not yet
Release Date
Not yet
37-x-y
Merged
PR Number
#46928
Merged At
May 5, 2025, 1:02:48 PM
Released In
Not yet
Release Date
Not yet

Semver Impact

Major
Breaking changes
Minor
New features
Patch
Bug fixes
None
Docs, tests, etc.

Semantic Versioning helps users understand the impact of updates:

  • Major (X.y.z): Breaking changes that may require code modifications
  • Minor (x.Y.z): New features that maintain backward compatibility
  • Patch (x.y.Z): Bug fixes that don't change the API
  • None: Changes that don't affect using facing parts of Electron