ShowWindow is not working when I use the handle from getNativeWindowHandle() of electron

Viewed 22

I use electron in my project. I get the window handle by getNativeWindowHandle(), and use it like this:

ShowWindow(handle, SW_SHOW);
SetWindowPos(handle, HWND_TOPMOST, r.left, r.top, 0, 0, 0);

The window shows, but the background color of the window is lost, the color was rgb(0,0,0).

I think that electron's render process doesn't render the window. I don't know why.

0 Answers
Related