From 896d2de281bc59c45654bd781a75aad9a96ad834 Mon Sep 17 00:00:00 2001
From: Jake <jake.read@cba.mit.edu>
Date: Thu, 28 Mar 2019 10:07:34 -0400
Subject: [PATCH] hello nautilus inside of cuttlefish

---
 bootstrap.js                  |  3 ++-
 gogetter.js                   |  1 +
 hunks/comm/websocketclient.js |  2 +-
 hunks/link.js                 |  4 ++--
 hunks/{hidden => }/view.js    | 17 +++++++++++------
 programs/mvnv.json            |  2 +-
 style.css                     |  6 +++++-
 7 files changed, 23 insertions(+), 12 deletions(-)
 rename hunks/{hidden => }/view.js (98%)

diff --git a/bootstrap.js b/bootstrap.js
index f2ee890..cf278ed 100644
--- a/bootstrap.js
+++ b/bootstrap.js
@@ -32,9 +32,10 @@ let View = {}
 
 window.onload = () => {
     console.log('BOOTUP')
-    NROL.addHunk('hidden/view', 'TLView').then((view) => {
+    NROL.addHunk('view', 'TLView').then((view) => {
         console.log('ADDHUNK VIEW RESOLVES')
         View = view
+        $(View.dom).attr('id', 'NROLVIEW')
         $('#wrapper').get(0).append(View.dom)
     }).then(() => {
         NROL.addLink(View.id, 'msgs', NROL.id, 'msgs')
diff --git a/gogetter.js b/gogetter.js
index 9fc2ba7..ed0dae9 100644
--- a/gogetter.js
+++ b/gogetter.js
@@ -52,6 +52,7 @@ function GoGetter() {
                     // now, writing menu options for each path 
                     // sort alphabetically 
                     returned.sort()
+                    //console.log('GG returns this', JSON.parse(JSON.stringify(returned)))
                     resolve(returned)
                 }
             }
diff --git a/hunks/comm/websocketclient.js b/hunks/comm/websocketclient.js
index 934dbbb..1fafe9c 100644
--- a/hunks/comm/websocketclient.js
+++ b/hunks/comm/websocketclient.js
@@ -24,7 +24,7 @@ function WebSocketClient() {
     this.outbuffer = new Array()
 
     this.init = () => {
-        //startWs()
+        startWs()
     }
 
     let startWs = () => {
diff --git a/hunks/link.js b/hunks/link.js
index 6b977f6..61f196c 100644
--- a/hunks/link.js
+++ b/hunks/link.js
@@ -142,13 +142,13 @@ function Link() {
             // if there's a message on the input, and the downstream is clear,
             if (inports[i].io && inports[i].dss === 'open') {
                 // we can send it, and reset to await an ack
-                console.log('i', typeof i)
+                this.log('i', typeof i)
                 let dsmsg = {
                     msg: inports[i].get(),
                     port: parseInt(i),
                     isAck: false,
                 }
-                console.log('LNK MSG OUT', dsmsg)
+                this.log('LNK MSG OUT', dsmsg)
                 inports[i].dss = 'await ack'
                 outbuffer.push(dsmsg)
             } else {
diff --git a/hunks/hidden/view.js b/hunks/view.js
similarity index 98%
rename from hunks/hidden/view.js
rename to hunks/view.js
index f734935..ce6afc0 100644
--- a/hunks/hidden/view.js
+++ b/hunks/view.js
@@ -1,13 +1,19 @@
 /* 
 
-NROL39
+VIEW
 
-... is this a hunk ? or a nested object in the manager ... 
+ - scrape to manager, 
+ - manager gogetter ... and then, hello click 
+ - and then, nicely: 
+ - also - link for flowcontrol when downstream non-conn ? the init-over-link question? a few states ... 
+ - div structure ... ? open something up just barely, to test node and scraper 
+ - beer 2 celly 
+ - div structure: the div(div) scaling unfuckery 
 
 */
 
-import { Hunkify, Input, Output, State } from '../hunks.js'
-import * as BZ from '../../bztools.js'
+import { Hunkify, Input, Output, State } from './hunks.js'
+import * as BZ from '../bztools.js'
 
 function View() {
     Hunkify(this, 'View')
@@ -34,8 +40,7 @@ function View() {
         // so this is kind of like the 'window.onload' function
         this.log('hello ui')
         // for nested dom elements,
-        this.dom = $('<div>').attr('id', this.id).addClass('view').get(0)
-        //$(this.dom).append('anything')
+        this.dom = $('<div>').addClass('view').get(0)
 
         // zoom the context 
         this.dom.addEventListener('wheel', mouseWheelListener)
diff --git a/programs/mvnv.json b/programs/mvnv.json
index 42dfc45..7d04021 100644
--- a/programs/mvnv.json
+++ b/programs/mvnv.json
@@ -22,7 +22,7 @@
         "id": "wsclient"
     },
     {
-        "name": "hidden/view",
+        "name": "view",
         "id": "nautilusview"
     }],
     "links": [
diff --git a/style.css b/style.css
index 3977c35..f251a1d 100644
--- a/style.css
+++ b/style.css
@@ -36,9 +36,13 @@ body {
 	margin: 0px;
 }
 
-.view {
+#NROLVIEW {
 	height: 100%;
 	width: 100%;
+}
+
+.view {
+	height: 400px;
 	background: #d6d6d6;
 	/*background-image:url("background.png");*/
 	/*background-origin: content-box;*/
-- 
GitLab