Display Cocoa window above Keynote presentation

喜欢而已 提交于 2019-12-21 19:22:02

问题


Some context: I am building a tool to be used on screen during a Keynote or PowerPoint presentation.

The biggest issue I've had so far is that Keynote seems to take over the desktop whenever you view a presentation. I have tried setting my Cocoa window's level to the maximum using:

[[self window] setLevel:kCGMaximumWindowLevel];

That seems to have some effect (I can have the window hover over Keynote's "control panel" that's active in the off-screen window), but it doesn't let me hover over the actual presentation.

Any ideas? Thanks in advance for the help!


回答1:


Try setting the level to NSScreenSaverWindowLevel + 1.




回答2:


Keynote has some settings in its Preferences that also must be set. Try these:

/usr/bin/defaults write com.apple.iWork.Keynote PresentationModePlayWellWithOthers 1
/usr/bin/defaults write com.apple.iWork.Keynote MouseVisibility 2

Definitely the 1st one is required. The 2nd is just for practicality.

This is in addition to what Rob suggested above in setting the window level to just above the NSScreenSaverWindowLevel.



来源:https://stackoverflow.com/questions/6233702/display-cocoa-window-above-keynote-presentation

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!