Fix : Add mac os menu (removed with nw > 0.10)

This commit is contained in:
juliandescottes 2015-04-26 23:33:49 +02:00
parent cf62f2ac0b
commit 9de77c9f21

View file

@ -152,6 +152,13 @@
if (pskl.devtools) {
pskl.devtools.init();
}
if (pskl.utils.Environment.detectNodeWebkit() && pskl.utils.UserAgent.isMac) {
var gui = require('nw.gui');
var mb = new gui.Menu({type:'menubar'});
mb.createMacBuiltin('Piskel');
gui.Window.get().menu = mb;
}
},
loadPiskel_ : function (serializedPiskel, descriptor, fps) {