Commit 31126b45 authored by yann300's avatar yann300 Committed by ioedeveloper

collapse terminal and side panel

parent 55001c80
...@@ -412,7 +412,8 @@ Please make a backup of your contracts and start using http://remix.ethereum.org ...@@ -412,7 +412,8 @@ Please make a backup of your contracts and start using http://remix.ethereum.org
// get the file from gist // get the file from gist
const gistHandler = new GistHandler() const gistHandler = new GistHandler()
const queryParams = new QueryParams() const queryParams = new QueryParams()
const loadedFromGist = gistHandler.loadFromGist(queryParams.get(), fileManager) const params = queryParams.get()
const loadedFromGist = gistHandler.loadFromGist(params, fileManager)
if (!loadedFromGist) { if (!loadedFromGist) {
// insert example contracts if there are no files to show // insert example contracts if there are no files to show
self._components.filesProviders['browser'].resolveDirectory('/', (error, filesList) => { self._components.filesProviders['browser'].resolveDirectory('/', (error, filesList) => {
...@@ -428,4 +429,6 @@ Please make a backup of your contracts and start using http://remix.ethereum.org ...@@ -428,4 +429,6 @@ Please make a backup of your contracts and start using http://remix.ethereum.org
if (isElectron()) { if (isElectron()) {
appManager.activatePlugin('remixd') appManager.activatePlugin('remixd')
} }
if (params.embed) framingService.embed()
} }
...@@ -80,7 +80,7 @@ export class MainView { ...@@ -80,7 +80,7 @@ export class MainView {
self.data = { self.data = {
_layout: { _layout: {
top: { top: {
offset: self._deps.config.get('terminal-top-offset') || 150, offset: self._terminalTopOffset(),
show: true show: true
} }
} }
...@@ -97,6 +97,9 @@ export class MainView { ...@@ -97,6 +97,9 @@ export class MainView {
}) })
} }
} }
_terminalTopOffset () {
return this._deps.config.get('terminal-top-offset') || 150
}
_adjustLayout (direction, delta) { _adjustLayout (direction, delta) {
var limitUp = 0 var limitUp = 0
var limitDown = 32 var limitDown = 32
...@@ -126,6 +129,12 @@ export class MainView { ...@@ -126,6 +129,12 @@ export class MainView {
self._components.terminal.scroll2bottom() self._components.terminal.scroll2bottom()
} }
} }
minimizeTerminal () {
this._adjustLayout('top')
}
showTerminal (offset) {
this._adjustLayout('top', offset || this._terminalTopOffset())
}
getTerminal () { getTerminal () {
return this._components.terminal return this._components.terminal
} }
......
...@@ -34,4 +34,9 @@ export class FramingService { ...@@ -34,4 +34,9 @@ export class FramingService {
} }
}) })
} }
embed () {
this.mainView.minimizeTerminal()
this.resizeFeature.hidePanel()
}
} }
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment