Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
B
baas-ide
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
JIRA
JIRA
Merge Requests
1
Merge Requests
1
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
guxukai
baas-ide
Commits
c189363e
Commit
c189363e
authored
May 09, 2019
by
Grandschtroumpf
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Update app and framing service
parent
17bee538
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
20 additions
and
29 deletions
+20
-29
app.js
src/app.js
+11
-19
framingService.js
src/framingService.js
+9
-10
No files found.
src/app.js
View file @
c189363e
...
...
@@ -33,11 +33,7 @@ var TransactionReceiptResolver = require('./transactionReceiptResolver')
const
PluginManagerComponent
=
require
(
'./app/components/plugin-manager-component'
)
const
VerticalIconsComponent
=
require
(
'./app/components/vertical-icons-component'
)
const
VerticalIconsApi
=
require
(
'./app/components/vertical-icons-api'
)
const
SwapPanelComponent
=
require
(
'./app/components/swap-panel-component'
)
const
SwapPanelApi
=
require
(
'./app/components/swap-panel-api'
)
const
VerticalIcons
=
require
(
'./app/components/vertical-icons-component'
)
const
CompileTab
=
require
(
'./app/tabs/compile-tab'
)
const
SettingsTab
=
require
(
'./app/tabs/settings-tab'
)
...
...
@@ -55,6 +51,8 @@ import framingService from './framingService'
import
{
MainView
}
from
'./app/panels/main-view'
import
{
ThemeModule
}
from
'./app/tabs/theme-module'
import
{
NetworkModule
}
from
'./app/tabs/network-module'
import
{
SwapPanel
}
from
'./app/components/swap-panel'
import
{
MainPanel
}
from
'./app/components/main-panel'
var
css
=
csjs
`
html { box-sizing: border-box; }
...
...
@@ -324,7 +322,6 @@ Please make a backup of your contracts and start using http://remix.ethereum.org
const
appManager
=
new
RemixAppManager
(
appStore
)
registry
.
put
({
api
:
appManager
,
name
:
'appmanager'
})
const
mainPanelComponent
=
new
SwapPanelComponent
(
'mainPanel'
,
appStore
,
appManager
,
{
default
:
false
,
displayHeader
:
false
})
// ----------------- file manager ----------------------------
self
.
_components
.
fileManager
=
new
FileManager
()
...
...
@@ -342,6 +339,12 @@ Please make a backup of your contracts and start using http://remix.ethereum.org
// ----------------- main view ----------------------
self
.
_components
.
mainview
=
new
MainView
(
appStore
,
appManager
,
mainPanelComponent
)
registry
.
put
({
api
:
self
.
_components
.
mainview
,
name
:
'mainview'
})
// ----------------- Vertical Icon ----------------------------
const
verticalIcons
=
new
VerticalIcons
(
'swapPanel'
,
appStore
)
registry
.
put
({
api
:
verticalIcons
,
name
:
'verticalicon'
})
const
swapPanel
=
new
SwapPanel
(
appStore
)
const
mainPanel
=
new
MainPanel
(
appStore
)
// ----------------- Renderer -----------------
const
renderer
=
new
Renderer
()
...
...
@@ -359,21 +362,11 @@ Please make a backup of your contracts and start using http://remix.ethereum.org
// TODOs those are instanciated before hand. should be instanciated on demand
const
pluginManagerComponent
=
new
PluginManagerComponent
()
const
swapPanelComponent
=
new
SwapPanelComponent
(
'swapPanel'
,
appStore
,
appManager
,
{
default
:
true
,
displayHeader
:
true
})
registry
.
put
({
api
:
appManager
.
proxy
(),
name
:
'pluginmanager'
})
pluginManagerComponent
.
setApp
(
appManager
)
pluginManagerComponent
.
setStore
(
appStore
)
// Need to have Home initialized before VerticalIconComponent render to access profile of it for icon
const
landingPage
=
new
LandingPage
(
appManager
,
appStore
)
// ----------------- Vertical Icon ----------------------------
const
verticalIconsComponent
=
new
VerticalIconsComponent
(
'swapPanel'
,
appStore
,
landingPage
.
profile
)
const
swapPanelApi
=
new
SwapPanelApi
(
swapPanelComponent
,
verticalIconsComponent
)
// eslint-disable-line
const
mainPanelApi
=
new
SwapPanelApi
(
mainPanelComponent
,
verticalIconsComponent
)
// eslint-disable-line
const
verticalIconsApi
=
new
VerticalIconsApi
(
verticalIconsComponent
)
// eslint-disable-line
registry
.
put
({
api
:
verticalIconsApi
,
name
:
'verticalicon'
})
self
.
_components
.
mainview
.
init
()
self
.
_components
.
fileManager
.
init
()
...
...
@@ -423,7 +416,6 @@ Please make a backup of your contracts and start using http://remix.ethereum.org
fileManager
.
api
(),
sourceHighlighters
.
api
(),
filePanel
.
api
(),
// { profile: support.profile(), api: support },
settings
.
api
(),
pluginManagerComponent
.
api
(),
networkModule
.
api
(),
...
...
@@ -440,7 +432,7 @@ Please make a backup of your contracts and start using http://remix.ethereum.org
...
appManager
.
plugins
()
])
framingService
.
start
(
appStore
,
swapPanel
Api
,
verticalIconsApi
,
mainPanelApi
,
this
.
_components
.
resizeFeature
)
framingService
.
start
(
appStore
,
swapPanel
,
verticalIcons
,
mainPanel
,
this
.
_components
.
resizeFeature
)
// The event listener needs to be registered as early as possible, because the
// parent will send the message upon the "load" event.
...
...
@@ -467,7 +459,7 @@ Please make a backup of your contracts and start using http://remix.ethereum.org
txLogger
.
event
.
register
(
'debuggingRequested'
,
(
hash
)
=>
{
if
(
!
appStore
.
isActive
(
'debugger'
))
appManager
.
activateOne
(
'debugger'
)
debug
.
debugger
().
debug
(
hash
)
verticalIcons
Api
.
select
(
'debugger'
)
verticalIcons
.
select
(
'debugger'
)
})
let
transactionContextAPI
=
{
...
...
src/framingService.js
View file @
c189363e
export
default
{
start
:
(
appStore
,
swapPanel
Api
,
verticalIconApi
,
mainPanelApi
,
resizeFeature
)
=>
{
swapPanel
Api
.
event
.
on
(
'toggle'
,
()
=>
{
start
:
(
appStore
,
swapPanel
,
verticalIcon
,
mainPanel
,
resizeFeature
)
=>
{
swapPanel
.
events
.
on
(
'toggle'
,
()
=>
{
resizeFeature
.
panel1
.
clientWidth
!==
0
?
resizeFeature
.
minimize
()
:
resizeFeature
.
maximise
()
})
swapPanel
Api
.
event
.
on
(
'showing'
,
()
=>
{
swapPanel
.
events
.
on
(
'showing'
,
()
=>
{
resizeFeature
.
panel1
.
clientWidth
===
0
?
resizeFeature
.
maximise
()
:
''
})
mainPanel
Api
.
event
.
on
(
'toggle'
,
()
=>
{
mainPanel
.
events
.
on
(
'toggle'
,
()
=>
{
resizeFeature
.
maximise
()
})
// mainPanelApi.event.on('showing', (moduleName) => {})
verticalIcon
Api
.
select
(
'fileExplorers'
)
mainPanel
Api
.
showContent
(
'home'
)
verticalIcon
.
select
(
'fileExplorers'
)
mainPanel
.
showContent
(
'home'
)
document
.
addEventListener
(
'keypress'
,
(
e
)
=>
{
if
(
e
.
shiftKey
&&
e
.
ctrlKey
)
{
if
(
e
.
code
===
'KeyF'
)
{
// Ctrl+Shift+F
verticalIcon
Api
.
select
(
'fileExplorers'
)
verticalIcon
.
select
(
'fileExplorers'
)
}
else
if
(
e
.
code
===
'KeyA'
)
{
// Ctrl+Shift+A
verticalIcon
Api
.
select
(
'pluginManager'
)
verticalIcon
.
select
(
'pluginManager'
)
}
else
if
(
e
.
code
===
'KeyS'
)
{
// Ctrl+Shift+S
verticalIcon
Api
.
select
(
'settings'
)
verticalIcon
.
select
(
'settings'
)
}
e
.
preventDefault
()
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment