Enable right click on overlay
This commit is contained in:
parent
9647f93cc2
commit
f0b283ea24
@ -104,7 +104,6 @@ const config: GameConfig = {
|
|||||||
dom: {
|
dom: {
|
||||||
createContainer: true,
|
createContainer: true,
|
||||||
},
|
},
|
||||||
disableContextMenu: true,
|
|
||||||
render: {
|
render: {
|
||||||
pixelArt: true,
|
pixelArt: true,
|
||||||
roundPixels: true,
|
roundPixels: true,
|
||||||
@ -142,6 +141,14 @@ const game = new Game(config);
|
|||||||
|
|
||||||
waScaleManager.setGame(game);
|
waScaleManager.setGame(game);
|
||||||
|
|
||||||
|
/*
|
||||||
|
TODO: replace with disableContextMenu when Phaser does not disable context menu on document.body
|
||||||
|
see https://github.com/photonstorm/phaser/issues/6064
|
||||||
|
*/
|
||||||
|
HtmlUtils.querySelectorOrFail("#game canvas").addEventListener("contextmenu", function (e) {
|
||||||
|
e.preventDefault();
|
||||||
|
});
|
||||||
|
|
||||||
window.addEventListener("resize", function (event) {
|
window.addEventListener("resize", function (event) {
|
||||||
coWebsiteManager.resetStyleMain();
|
coWebsiteManager.resetStyleMain();
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user