-
Notifications
You must be signed in to change notification settings - Fork 16.2k
feat: allow setting window shape #13789
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
51aef5a
to
c688a92
Compare
This binds Widget::SetShape, an API that already exists in Chromium (for Windows and Linux). It's a more reliable method of having some parts of your window be "click-through" than the current `setIgnoreMouseEvents` API, which messes around with the `WS_EX_LAYERED` window style on Windows, causing strange bugs and incompatibility with hardware acceleration.
c688a92
to
41a322e
Compare
@@ -1262,6 +1262,11 @@ Sets the opacity of the window. On Linux does nothing. | |||
|
|||
Returns `Number` - between 0.0 (fully transparent) and 1.0 (fully opaque) | |||
|
|||
#### `win.setShape(rects)` _Windows_ _Linux_ _Experimental_ | |||
|
|||
* `rects` [Rectangle[]](structures/rectangle.md) - Sets a shape on the window. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you expand this documentation a bit to explain what shapes are and why you'd want to use them?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done
/trop run backport-to 2-1-x |
The backport process for this PR has been manually initiated, sending your 1's and 0's to "2-1-x" here we go! :D |
This binds Widget::SetShape, an API that already exists in Chromium (for Windows and Linux). It's a more reliable method of having some parts of your window be "click-through" than the current `setIgnoreMouseEvents` API, which messes around with the `WS_EX_LAYERED` window style on Windows, causing strange bugs and incompatibility with hardware acceleration.
This binds Widget::SetShape, an API that already exists in Chromium (for Windows and Linux). It's a more reliable method of having some parts of your window be "click-through" than the current `setIgnoreMouseEvents` API, which messes around with the `WS_EX_LAYERED` window style on Windows, causing strange bugs and incompatibility with hardware acceleration.
This binds Widget::SetShape, an API that already exists in Chromium (for Windows and Linux). It's a more reliable method of having some parts of your window be "click-through" than the current `setIgnoreMouseEvents` API, which messes around with the `WS_EX_LAYERED` window style on Windows, causing strange bugs and incompatibility with hardware acceleration.
This binds Widget::SetShape, an API that already exists in Chromium (for Windows and Linux). It's a more reliable method of having some parts of your window be "click-through" than the current `setIgnor 8000 eMouseEvents` API, which messes around with the `WS_EX_LAYERED` window style on Windows, causing strange bugs and incompatibility with hardware acceleration.
This binds Widget::SetShape, an API that already exists in Chromium (for Windows and Linux). It's a more reliable method of having some parts of your window be "click-through" than the current `setIgnoreMouseEvents` API, which messes around with the `WS_EX_LAYERED` window style on Windows, causing strange bugs and incompatibility with hardware acceleration.
This binds Widget::SetShape, an API that already exists in Chromium (for Windows and Linux). It's a more reliable method of having some parts of your window be "click-through" than the current `setIgnoreMouseEvents` API, which messes around with the `WS_EX_LAYERED` window style on Windows, causing strange bugs and incompatibility with hardware acceleration.
This binds Widget::SetShape, an API that already exists in Chromium (for Windows and Linux). It's a more reliable method of having some parts of your window be "click-through" than the current `setIgnoreMouseEvents` API, which messes around with the `WS_EX_LAYERED` window style on Windows, causing strange bugs and incompatibility with hardware acceleration.
This binds Widget::SetShape, an API that already exists in Chromium (for Windows and Linux). It's a more reliable method of having some parts of your window be "click-through" than the current `setIgnoreMouseEvents` API, which messes around with the `WS_EX_LAYERED` window style on Windows, causing strange bugs and incompatibility with hardware acceleration.
This binds Widget::SetShape, an API that already exists in Chromium (for Windows and Linux). It's a more reliable method of having some parts of your window be "click-through" than the current `setIgnoreMouseEvents` API, which messes around with the `WS_EX_LAYERED` window style on Windows, causing strange bugs and incompatibility with hardware acceleration.
/trop run backport-to 3-0-x |
The backport process for this PR has been manually initiated, |
We have automatically backported this PR to "3-0-x", please check out #14445 |
This binds Widget::SetShape, an API that already exists in Chromium. It's a more reliable method of having some parts of your window be "click-through" than the current
setIgnoreMouseEvents
API, which messes around with theWS_EX_LAYERED
window style, causing strange bugs and incompatibility with hardware acceleration.Checklist
npm test
passes