Where are the min/max buttons on new Chrome Packaged Apps?

一笑奈何 提交于 2019-12-10 06:56:21

问题


I'm using the dev-channel v23 of Chrome and I'm working with the new Chrome Packaged Apps platfrom.

One purpose of the new platform is to take packaged apps "out of the browser" and give the packaged app top-level window status. I have a lot of things working, but the window that Chrome opens for me has no title bar, or minimize, maximize buttons. It does have the chrome's custom close button (like the one on internal windows like settings dialogs).

You can hide the close button, and provide custom min/max/close functionality in html/js but it breaks the UX in functionality and appearance. If chrome's aim is to make my app look and function like every other top-level window, where is the system specific title bar (with window state buttons)?

Am I missing something? Can this be done with some sort of API I'm not seeing?

Thanks, Tim

* I understand that I can use the "none" frame type, and create my own title bar, but there's no way to account for all platforms with variations of each. It's a window. I mean, if the goal is to be be like any other top level window then open a standard platform specific window and give me a client area to work with. I'd say customization is secondary to a standard window consistent with the functionality and appearance of every other window on particular OS.


回答1:


Currently there are two types of windows you can create: [frame: "chrome"] (default) and [frame: "none"]. You are probably using the frame:"none", right? In that window type, you have to draw all decorations you need, including the window controls. If you use the default frame type ("chrome"), you get a window with a native titlebar, but no customization option.

Having said that, rest assured that we are investigating other options to help you bootstrap your app. One of the options being evaluated is a HTML component that mimics the platform title bar but can be customized by you.



来源:https://stackoverflow.com/questions/12483563/where-are-the-min-max-buttons-on-new-chrome-packaged-apps

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