new Editor(app, engine, view)
- Description:
Code editor rendering
Parameters:
Name | Type | Description |
---|---|---|
app |
Simplicite.Ajax | Ajax service |
engine |
Simplicite.UI.Engine | Main controller |
view |
Simplicite.UI.View.Main | View services |
Methods
changed()
- Description:
Change event on tab
compare(left, right, save)
- Description:
Compare sources with 2 ACE editors
Parameters:
Name | Type | Description |
---|---|---|
left |
Object | left editor parameters { content, editable, copyLinkEnabled... } |
right |
Object | right editor parameters |
save |
function | optional callback(src) to apply changes in caller |
display(ctn, p, cbk)
- Description:
Display the editor form
Parameters:
Name | Type | Description |
---|---|---|
ctn |
jQuery | container |
p |
Object | optional parameters |
cbk |
function | optional callback |
explorer(ctn, modules)
- Description:
Source explorer
Parameters:
Name | Type | Description |
---|---|---|
ctn |
jQuery | Container |
modules |
Object | list of modules/object/doc [{ id, module, open, items:[{ object, label, field, open, list:[{ id, label, docId }] }] }] |
formatActive()
- Description:
Format active tab
openAce(key, x)
- Description:
Ace editor
Parameters:
Name | Type | Description |
---|---|---|
key |
string | tab unique key |
x |
Object | tab definition and db source item {tab, item} |
openActive()
- Description:
Open active object
save(e, cbk, log)
- Description:
Save a tab
Parameters:
Name | Type | Description |
---|---|---|
e |
Object | tab definition |
cbk |
function | optional callback |
log |
Object | save all context to return errors |
saveActive()
- Description:
Save active tab
saveAll()
- Description:
Save all tabs