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
e804389d
Commit
e804389d
authored
Aug 31, 2021
by
yann300
Committed by
davidzagi93@gmail.com
Sep 14, 2021
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix registering 'contentChanged' event
parent
c3f88464
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
9 deletions
+5
-9
compiler-api.ts
apps/solidity-compiler/src/app/compiler-api.ts
+5
-9
No files found.
apps/solidity-compiler/src/app/compiler-api.ts
View file @
e804389d
...
@@ -158,11 +158,11 @@ export const CompilerApiMixin = (Base) => class extends Base {
...
@@ -158,11 +158,11 @@ export const CompilerApiMixin = (Base) => class extends Base {
}
}
listenToEvents
()
{
listenToEvents
()
{
this
.
data
.
eventHandlers
.
onContentChanged
=
()
=>
{
this
.
on
(
'editor'
,
'contentChanged'
,
()
=>
{
this
.
emit
(
'statusChanged'
,
{
key
:
'edited'
,
title
:
'the content has changed, needs recompilation'
,
type
:
'info'
})
this
.
emit
(
'statusChanged'
,
{
key
:
'edited'
,
title
:
'the content has changed, needs recompilation'
,
type
:
'info'
})
}
if
(
this
.
onContentChanged
)
this
.
onContentChanged
()
this
.
on
(
'editor'
,
'contentChanged'
,
this
.
data
.
eventHandlers
.
onContentChanged
)
}
)
this
.
data
.
eventHandlers
.
onLoadingCompiler
=
()
=>
{
this
.
data
.
eventHandlers
.
onLoadingCompiler
=
()
=>
{
this
.
data
.
loading
=
true
this
.
data
.
loading
=
true
this
.
emit
(
'statusChanged'
,
{
key
:
'loading'
,
title
:
'loading compiler...'
,
type
:
'info'
})
this
.
emit
(
'statusChanged'
,
{
key
:
'loading'
,
title
:
'loading compiler...'
,
type
:
'info'
})
...
@@ -195,11 +195,7 @@ export const CompilerApiMixin = (Base) => class extends Base {
...
@@ -195,11 +195,7 @@ export const CompilerApiMixin = (Base) => class extends Base {
this
.
on
(
'editor'
,
'sessionSwitched'
,
()
=>
{
this
.
on
(
'editor'
,
'sessionSwitched'
,
()
=>
{
if
(
this
.
onSessionSwitched
)
this
.
onSessionSwitched
()
if
(
this
.
onSessionSwitched
)
this
.
onSessionSwitched
()
})
})
this
.
on
(
'editor'
,
'contentChanged'
,
()
=>
{
if
(
this
.
onContentChanged
)
this
.
onContentChanged
()
})
this
.
compileTabLogic
.
event
.
on
(
'startingCompilation'
,
this
.
data
.
eventHandlers
.
onStartingCompilation
)
this
.
compileTabLogic
.
event
.
on
(
'startingCompilation'
,
this
.
data
.
eventHandlers
.
onStartingCompilation
)
this
.
compileTabLogic
.
event
.
on
(
'removeAnnotations'
,
this
.
data
.
eventHandlers
.
onRemoveAnnotations
)
this
.
compileTabLogic
.
event
.
on
(
'removeAnnotations'
,
this
.
data
.
eventHandlers
.
onRemoveAnnotations
)
...
...
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