Skip to content
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

OSX - Transparency clickthrough broken on High Sierra #6307

Closed
Blatman opened this issue Nov 27, 2017 · 25 comments
Closed

OSX - Transparency clickthrough broken on High Sierra #6307

Blatman opened this issue Nov 27, 2017 · 25 comments

Comments

@Blatman
Copy link

Blatman commented Nov 27, 2017

OSX High Sierra 10.13.1 Retina 5K
Clickthrough not working - tried 0.27.0rc1/0.26.7/0.17.6/0.14.7 (tried both --disable-gpu and --disable-gpu-composited).

Works fine on a Mavericks VM on High Sierra using 0.17.6 (also with --disable-gpu) and also fine on another machine with Yosemite
Attached is test app -

TransTest.zip

@Christywl
Copy link
Contributor

I can reproduce this issue on Mac High Sierra with nwjs-sdk-v0.26.6. It works fine on Mac 10.12.6.

@rogerwang
Copy link
Member

cc @jtg-gg

@Blatman
Copy link
Author

Blatman commented Nov 28, 2017

Ah - also noticed that if devtools window is used if it is closed the transparent area becomes white ....
Cheers.

@thedracle
Copy link

Maybe these new warning messages that are popping up are related:

017-11-28 20:12:00.246 nwjs[4341:111413] *** WARNING: Textured window <AppFramelessNSWindow: 0x7fd166543290> is getting an implicitly transparent titlebar. This will break when linking against newer SDKs. Use NSWindow's -titlebarAppearsTransparent=YES instead.

@jtg-gg
Copy link
Member

jtg-gg commented Nov 29, 2017

i am a bit busy now, will look into this once i am "free"

@jtg-gg jtg-gg self-assigned this Nov 29, 2017
@rogerwang
Copy link
Member

@Blatman does the devtools issue appear on 10.12 or earlier version of macOS?

@Blatman
Copy link
Author

Blatman commented Dec 19, 2017

@rogerwang tried it on Yosemite (10.10.5 - MBP) and it failed also - got white background when tools closed. Possibly a separate issue?
Trying to get an El Capitan VM going but not having much luck.

@rogerwang
Copy link
Member

@Blatman yeah. it should be different. Please submit another issue for it.

@rogerwang
Copy link
Member

btw, with your case I get a window with nothing visible in a 10.10 and 10.12 system. But in a 10.13 system the transparent picture with a square is correctly displayed. Is that what you've got?

@Blatman
Copy link
Author

Blatman commented Dec 19, 2017

@rogerwang unable to test 10.12 - can't get the VM working properly but on 10.10 the window works OK and shows problem - just opened #6343 for this issue.
Cheers.

@Blatman
Copy link
Author

Blatman commented Dec 19, 2017

@rogerwang may be a red herring but I do get similar issues to you when I try the testapp in the VM - basically my 10.11 VM (Parallels) shows the window but no content(this also happens when opening SublimeText!) , I also find that dragging nwjs binaries from the host to the guest results in the symlinks in nwjs Framework.framework becoming actual folders therefore breaking the app - something is not right with Parallels .... My successful troubleshooting is on actual machine installs of OSX.

UPDATE: just got access to the old machine install of 10.11.6 (El Cap) and found that using 0.27.3-sdk the main test app window was missing but the devtools was there and when closed then no window at all.

UPDATE again - on El Cap (10.11.6) the windows will work correctly and show the white background problem if set for --disable-gpu --force-cpu-draw rather than --disable-gpu-composited --force-cpu-draw.

@jtg-gg
Copy link
Member

jtg-gg commented Jan 17, 2018

@rogerwang I've made a pull request nwjs/chromium.src#102
please also patch nw27

@rogerwang
Copy link
Member

Thanks! merged into nw28, will see nw27 as well.

@Blatman
Copy link
Author

Blatman commented Jan 17, 2018

Just tried latest 0.27 http://dl.nwjs.io/live-build/nw27/01-17-2018/ff9b366-d2ae21b-a3ef615-6c8870e/ build and click-through only works with --disable-gpu but the debug window that is opened programatically is blank with a white background. (click-through with --disable-gpu-composited does not work - which setting is meant to be used these days?).
Cheers

@jtg-gg
Copy link
Member

jtg-gg commented Jan 17, 2018

@Blatman you must use these 2 params together "--disable-gpu-compositing --force-cpu-draw"
then the package.json must use
"window":{
"frame": false,
"transparent": true,
"resizable": false
}

frame: false, and resizable:false is needed for click through transparency

@jtg-gg
Copy link
Member

jtg-gg commented Jan 17, 2018

@rogerwang just now I found a "regression", the window can't be maximized / fullscreen (though transparent window is defined as "resizable:false", but this feature works on existing version)
will fix this tomorrow

@Blatman
Copy link
Author

Blatman commented Jan 17, 2018

@jtg-gg thanks for that I was using composited rather than compositing - my error.
The blank debug window with white background still occurs but I think this will probably be addressed by #6343. The click-through is fine. Thanks.

@jtg-gg
Copy link
Member

jtg-gg commented Jan 18, 2018

@rogerwang I have the pull request for the regression nwjs/chromium.src#103

@rogerwang
Copy link
Member

@jtg-gg 👍 merged.

@thedracle
Copy link

thedracle commented Jan 22, 2018

Is there a live build for the above fix allowing maximizing the window?

I'm experiencing a strange problem with transparent clickthrough enabled, mainly the area that I can click in my UI seems to be adjusted downwards when "--disable-gpu-compositing --force-cpu-draw" are set.

In order to click on a button, you have to move the mouse pointer slightly below it.

I will try to make something that demonstrates this, but I am trying to figure out a workaround.

@rogerwang
Copy link
Member

@thedracle
Copy link

Thanks Roger.

Maximizing fixes this weird click offset issue. It's probably something to do with the page layout or some odd chrome rendering bug, and nothing to do with NWJS.

@cecilpeng
Copy link

Do nwjs 0.27.6 support it? Is it stable now?

@rogerwang
Copy link
Member

@cecilpeng there is no plan to release 0.27.6 as 0.28.0 is to be released soon with this fix. However the live build version of 0.27.6 is in release quality.

@cecilpeng
Copy link

@rogerwang I am glad to see stable 0.28.0 soon.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

6 participants