Newer
Older
// IDDE sends msgs to manager, does display etc
// starts with a native manager
/* codename NROL39 aka cuttlefish */
/* aka the teuthologist */
// this is toplevel, UI is meta-hunk
// we run loop where UI passes messages to bower manager
// this is like the manager 'bootstrap' file ?
import Manager from './hunks/manager.js'
// this is the TL
// but heirarchichally, we can slave views to managers ...
// views push messages to managers ...
// our invisible overlord
let NROL = new Manager()
function bootloop() {
NROL.loop()
setTimeout(bootloop)
}
// want handles on this we think ?
window.onload = () => {
console.log('BOOTUP')
NROL.addHunk('hidden/view', 'TLView').then((view) => {
View = view
$('#wrapper').get(0).append(View.dom)
}).then(() => {
NROL.addLink(View.id, 'msgs', NROL.id, 'msgs')
}).then(() => {
NROL.addLink(NROL.id, 'msgs', View.id, 'msgs')
// ... how do we setup init routines for views / connections ?
// NROL.describeRunningProgram()
NROL.addProgram('mvnv').then((newHunks) => {
// auto added to view (should be)
}).catch((err) => {
console.log('err on opening bootsrap program', err)