From 994b97f58f9323322e2c971ad198089afb2e3f78 Mon Sep 17 00:00:00 2001 From: Devine Lu Linvega Date: Mon, 15 Jul 2019 17:32:56 +0900 Subject: [PATCH] Canvas is no longer hidden by the commander --- desktop/sources/links/main.css | 8 +++++--- desktop/sources/scripts/commander.js | 10 +++++----- 2 files changed, 10 insertions(+), 8 deletions(-) diff --git a/desktop/sources/links/main.css b/desktop/sources/links/main.css index 1257ec8..cc17c46 100644 --- a/desktop/sources/links/main.css +++ b/desktop/sources/links/main.css @@ -7,7 +7,9 @@ body { margin:0px; padding:0px; overflow:hidden; font-family:"input_mono_regular #ronin #wrapper #commander { z-index: 9000; position: relative; width: 300px; height: calc(100vh - 60px); border-right: 1px solid #333; -webkit-app-region: no-drag; padding-right: 30px; transition: margin-left 250ms;} #ronin #wrapper #commander textarea { background: none; width: 100%; height: calc(100vh - 80px); resize: none; font-size: 12px;line-height: 15px; padding-right: 15px} #ronin #wrapper #commander div#status { position: absolute; bottom: 0px; } -#ronin #wrapper #commander.hidden { margin-left:-331px; } +#ronin.hidden #wrapper #commander { margin-left:-331px; } -#ronin canvas#surface,#ronin canvas#guide { position: absolute; right:0px; top:0px; -webkit-user-select: none;-webkit-app-region: no-drag; background-image: url("data:image/svg+xml;utf8,"); background-size: 10px 10px; background-position: -4px -4px; width:100%; height:100%;} -#ronin canvas#guide { background:none; } \ No newline at end of file +#ronin canvas#surface,#ronin canvas#guide { position: absolute; top:0px; -webkit-user-select: none;-webkit-app-region: no-drag; background-image: url("data:image/svg+xml;utf8,"); background-size: 10px 10px; background-position: -4px -4px; width:100%; height:100%; left:340px; transition: left 250ms} +#ronin canvas#guide { background:none; } + +#ronin.hidden canvas#surface, #ronin.hidden canvas#guide { left:0px; } \ No newline at end of file diff --git a/desktop/sources/scripts/commander.js b/desktop/sources/scripts/commander.js index b6b5b3d..5d51581 100644 --- a/desktop/sources/scripts/commander.js +++ b/desktop/sources/scripts/commander.js @@ -145,19 +145,19 @@ function Commander (ronin) { // Display this.show = function () { - if (this.el.className !== '') { - this.el.className = '' + if (ronin.el.className !== '') { + ronin.el.className = '' } } this.hide = function () { - if (this.el.className !== 'hidden') { - this.el.className = 'hidden' + if (ronin.el.className !== 'hidden') { + ronin.el.className = 'hidden' } } this.toggle = function () { - if (this.el.className === 'hidden') { + if (ronin.el.className === 'hidden') { this.show() } else { this.hide()