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
b437dd18
Commit
b437dd18
authored
Jun 15, 2020
by
ioedeveloper
Committed by
yann300
Jul 01, 2020
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fixed deactivate bug
parent
12c4ef65
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
15 additions
and
14 deletions
+15
-14
fileManager.js
src/app/files/fileManager.js
+7
-7
remixDProvider.js
src/app/files/remixDProvider.js
+5
-4
remixd-handle.js
src/app/files/remixd-handle.js
+3
-3
No files found.
src/app/files/fileManager.js
View file @
b437dd18
...
@@ -266,13 +266,13 @@ class FileManager extends Plugin {
...
@@ -266,13 +266,13 @@ class FileManager extends Plugin {
localhostExplorer
:
this
.
_components
.
registry
.
get
(
'fileproviders/localhost'
).
api
,
localhostExplorer
:
this
.
_components
.
registry
.
get
(
'fileproviders/localhost'
).
api
,
filesProviders
:
this
.
_components
.
registry
.
get
(
'fileproviders'
).
api
filesProviders
:
this
.
_components
.
registry
.
get
(
'fileproviders'
).
api
}
}
//
this._deps.browserExplorer.event.register('fileChanged', (path) => { this.fileChangedEvent(path) })
this
.
_deps
.
browserExplorer
.
event
.
register
(
'fileChanged'
,
(
path
)
=>
{
this
.
fileChangedEvent
(
path
)
})
//
this._deps.browserExplorer.event.register('fileRenamed', (oldName, newName, isFolder) => { this.fileRenamedEvent(oldName, newName, isFolder) })
this
.
_deps
.
browserExplorer
.
event
.
register
(
'fileRenamed'
,
(
oldName
,
newName
,
isFolder
)
=>
{
this
.
fileRenamedEvent
(
oldName
,
newName
,
isFolder
)
})
//
this._deps.localhostExplorer.event.register('fileRenamed', (oldName, newName, isFolder) => { this.fileRenamedEvent(oldName, newName, isFolder) })
this
.
_deps
.
localhostExplorer
.
event
.
register
(
'fileRenamed'
,
(
oldName
,
newName
,
isFolder
)
=>
{
this
.
fileRenamedEvent
(
oldName
,
newName
,
isFolder
)
})
//
this._deps.browserExplorer.event.register('fileRemoved', (path) => { this.fileRemovedEvent(path) })
this
.
_deps
.
browserExplorer
.
event
.
register
(
'fileRemoved'
,
(
path
)
=>
{
this
.
fileRemovedEvent
(
path
)
})
//
this._deps.localhostExplorer.event.register('fileRemoved', (path) => { this.fileRemovedEvent(path) })
this
.
_deps
.
localhostExplorer
.
event
.
register
(
'fileRemoved'
,
(
path
)
=>
{
this
.
fileRemovedEvent
(
path
)
})
//
this._deps.localhostExplorer.event.register('errored', (event) => { this.removeTabsOf(this._deps.localhostExplorer) })
this
.
_deps
.
localhostExplorer
.
event
.
register
(
'errored'
,
(
event
)
=>
{
this
.
removeTabsOf
(
this
.
_deps
.
localhostExplorer
)
})
//
this._deps.localhostExplorer.event.register('closed', (event) => { this.removeTabsOf(this._deps.localhostExplorer) })
this
.
_deps
.
localhostExplorer
.
event
.
register
(
'closed'
,
(
event
)
=>
{
this
.
removeTabsOf
(
this
.
_deps
.
localhostExplorer
)
})
this
.
getCurrentFile
=
this
.
file
this
.
getCurrentFile
=
this
.
file
this
.
getFile
=
this
.
readFile
this
.
getFile
=
this
.
readFile
this
.
getFolder
=
this
.
readdir
this
.
getFolder
=
this
.
readdir
...
...
src/app/files/remixDProvider.js
View file @
b437dd18
...
@@ -111,10 +111,11 @@ module.exports = class RemixDProvider {
...
@@ -111,10 +111,11 @@ module.exports = class RemixDProvider {
}
}
set
(
path
,
content
,
cb
)
{
set
(
path
,
content
,
cb
)
{
var
unprefixedpath
=
this
.
removePrefix
(
path
)
const
unprefixedpath
=
this
.
removePrefix
(
path
)
this
.
_appManager
.
call
(
'remixd'
,
'set'
,
{
path
:
unprefixedpath
,
content
:
content
},
(
error
,
result
)
=>
{
this
.
_appManager
.
call
(
'remixd'
,
'set'
,
{
path
:
unprefixedpath
,
content
:
content
}).
then
((
result
)
=>
{
if
(
cb
)
return
cb
(
error
,
result
)
if
(
cb
)
return
cb
(
null
,
result
)
var
path
=
this
.
type
+
'/'
+
unprefixedpath
const
path
=
this
.
type
+
'/'
+
unprefixedpath
this
.
event
.
trigger
(
'fileChanged'
,
[
path
])
this
.
event
.
trigger
(
'fileChanged'
,
[
path
])
})
})
return
true
return
true
...
...
src/app/files/remixd-handle.js
View file @
b437dd18
...
@@ -37,7 +37,7 @@ export class RemixdHandle extends WebsocketPlugin {
...
@@ -37,7 +37,7 @@ export class RemixdHandle extends WebsocketPlugin {
}
}
deactivate
()
{
deactivate
()
{
super
.
deactivate
()
if
(
super
.
socket
)
super
.
deactivate
()
this
.
locahostProvider
.
close
((
error
)
=>
{
this
.
locahostProvider
.
close
((
error
)
=>
{
if
(
error
)
console
.
log
(
error
)
if
(
error
)
console
.
log
(
error
)
})
})
...
@@ -47,7 +47,7 @@ export class RemixdHandle extends WebsocketPlugin {
...
@@ -47,7 +47,7 @@ export class RemixdHandle extends WebsocketPlugin {
this
.
connectToLocalhost
()
this
.
connectToLocalhost
()
}
}
canceled
()
{
async
canceled
()
{
this
.
appManager
.
ensureDeactivated
(
'remixd'
)
this
.
appManager
.
ensureDeactivated
(
'remixd'
)
}
}
...
@@ -57,7 +57,7 @@ export class RemixdHandle extends WebsocketPlugin {
...
@@ -57,7 +57,7 @@ export class RemixdHandle extends WebsocketPlugin {
*
*
* @param {String} txHash - hash of the transaction
* @param {String} txHash - hash of the transaction
*/
*/
async
connectToLocalhost
()
{
connectToLocalhost
()
{
let
connection
=
(
error
)
=>
{
let
connection
=
(
error
)
=>
{
if
(
error
)
{
if
(
error
)
{
console
.
log
(
error
)
console
.
log
(
error
)
...
...
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