// Compiled by ClojureScript 0.0-2138
goog.provide('lt.objs.eval');
goog.require('cljs.core');
goog.require('lt.util.cljs');
goog.require('crate.binding');
goog.require('lt.objs.menu');
goog.require('lt.objs.sidebar.command');
goog.require('lt.objs.files');
goog.require('lt.util.dom');
goog.require('lt.objs.platform');
goog.require('lt.objs.popup');
goog.require('lt.objs.popup');
goog.require('cljs.reader');
goog.require('crate.core');
goog.require('lt.objs.notifos');
goog.require('lt.objs.notifos');
goog.require('lt.util.dom');
goog.require('lt.objs.editor.pool');
goog.require('clojure.string');
goog.require('lt.objs.canvas');
goog.require('lt.util.cljs');
goog.require('lt.objs.platform');
goog.require('lt.objs.menu');
goog.require('lt.objs.files');
goog.require('lt.objs.clients');
goog.require('clojure.string');
goog.require('crate.binding');
goog.require('lt.objs.editor');
goog.require('lt.objs.canvas');
goog.require('lt.object');
goog.require('cljs.reader');
goog.require('lt.object');
goog.require('lt.objs.console');
goog.require('lt.objs.console');
goog.require('crate.core');
goog.require('lt.objs.clients');
goog.require('lt.objs.editor.pool');
goog.require('lt.objs.sidebar.command');
goog.require('lt.objs.editor');
/**
* @param {...*} var_args
*/
lt.objs.eval.button = (function() { 
var button__delegate = function (label,p__8453){var vec__8461 = p__8453;var cb = cljs.core.nth.call(null,vec__8461,0,null);var e__3325__auto__ = crate.core.html.call(null,new cljs.core.PersistentVector(null, 2, 5, cljs.core.PersistentVector.EMPTY_NODE, [new cljs.core.Keyword(null,"div.button.right","div.button.right",629503503),label], null));var seq__8462_8468 = cljs.core.seq.call(null,cljs.core.partition.call(null,2,new cljs.core.PersistentVector(null, 2, 5, cljs.core.PersistentVector.EMPTY_NODE, [new cljs.core.Keyword(null,"click","click",1108654330),(function (){if(cljs.core.truth_(cb))
{return cb.call(null);
} else
{return null;
}
})], null)));var chunk__8463_8469 = null;var count__8464_8470 = 0;var i__8465_8471 = 0;while(true){
if((i__8465_8471 < count__8464_8470))
{var vec__8466_8472 = cljs.core._nth.call(null,chunk__8463_8469,i__8465_8471);var ev__3326__auto___8473 = cljs.core.nth.call(null,vec__8466_8472,0,null);var func__3327__auto___8474 = cljs.core.nth.call(null,vec__8466_8472,1,null);lt.util.dom.on.call(null,e__3325__auto__,ev__3326__auto___8473,func__3327__auto___8474);
{
var G__8475 = seq__8462_8468;
var G__8476 = chunk__8463_8469;
var G__8477 = count__8464_8470;
var G__8478 = (i__8465_8471 + 1);
seq__8462_8468 = G__8475;
chunk__8463_8469 = G__8476;
count__8464_8470 = G__8477;
i__8465_8471 = G__8478;
continue;
}
} else
{var temp__4092__auto___8479 = cljs.core.seq.call(null,seq__8462_8468);if(temp__4092__auto___8479)
{var seq__8462_8480__$1 = temp__4092__auto___8479;if(cljs.core.chunked_seq_QMARK_.call(null,seq__8462_8480__$1))
{var c__4262__auto___8481 = cljs.core.chunk_first.call(null,seq__8462_8480__$1);{
var G__8482 = cljs.core.chunk_rest.call(null,seq__8462_8480__$1);
var G__8483 = c__4262__auto___8481;
var G__8484 = cljs.core.count.call(null,c__4262__auto___8481);
var G__8485 = 0;
seq__8462_8468 = G__8482;
chunk__8463_8469 = G__8483;
count__8464_8470 = G__8484;
i__8465_8471 = G__8485;
continue;
}
} else
{var vec__8467_8486 = cljs.core.first.call(null,seq__8462_8480__$1);var ev__3326__auto___8487 = cljs.core.nth.call(null,vec__8467_8486,0,null);var func__3327__auto___8488 = cljs.core.nth.call(null,vec__8467_8486,1,null);lt.util.dom.on.call(null,e__3325__auto__,ev__3326__auto___8487,func__3327__auto___8488);
{
var G__8489 = cljs.core.next.call(null,seq__8462_8480__$1);
var G__8490 = null;
var G__8491 = 0;
var G__8492 = 0;
seq__8462_8468 = G__8489;
chunk__8463_8469 = G__8490;
count__8464_8470 = G__8491;
i__8465_8471 = G__8492;
continue;
}
}
} else
{}
}
break;
}
return e__3325__auto__;
};
var button = function (label,var_args){
var p__8453 = null;if (arguments.length > 1) {
  p__8453 = cljs.core.array_seq(Array.prototype.slice.call(arguments, 1),0);} 
return button__delegate.call(this,label,p__8453);};
button.cljs$lang$maxFixedArity = 1;
button.cljs$lang$applyTo = (function (arglist__8493){
var label = cljs.core.first(arglist__8493);
var p__8453 = cljs.core.rest(arglist__8493);
return button__delegate(label,p__8453);
});
button.cljs$core$IFn$_invoke$arity$variadic = button__delegate;
return button;
})()
;
lt.objs.eval.unescape_unicode = (function unescape_unicode(s){return clojure.string.replace.call(null,s,/\\x(..)/,(function (res,r){return String.fromCharCode(parseInt(r,16));
}));
});
var ev_id_8494 = cljs.core.atom.call(null,0);lt.objs.eval.append_source_file = (function append_source_file(code,file){return [cljs.core.str(code),cljs.core.str("\n\n//# sourceURL="),cljs.core.str((function (){var or__3520__auto__ = file;if(cljs.core.truth_(or__3520__auto__))
{return or__3520__auto__;
} else
{return "evalresult";
}
})()),cljs.core.str("[eval"),cljs.core.str(cljs.core.swap_BANG_.call(null,ev_id_8494,cljs.core.inc)),cljs.core.str("]")].join('');
});
lt.objs.eval.pad = (function pad(code,lines){return [cljs.core.str(cljs.core.reduce.call(null,cljs.core.str,cljs.core.repeat.call(null,lines,"\n"))),cljs.core.str(code)].join('');
});
lt.objs.eval.cljs_result_format = (function cljs_result_format(n){if(cljs.core.coll_QMARK_.call(null,n))
{return cljs.core.pr_str.call(null,n);
} else
{if(cljs.core.fn_QMARK_.call(null,n))
{return [cljs.core.str("(fn "),cljs.core.str(n.name),cljs.core.str(" ..)")].join('');
} else
{if((n == null))
{return "nil";
} else
{if(cljs.core._EQ_.call(null,cljs.core.pr_str.call(null,n),"#<[object Object]>"))
{return lt.objs.console.inspect.call(null,n);
} else
{if(new cljs.core.Keyword(null,"else","else",1017020587))
{return cljs.core.pr_str.call(null,n);
} else
{return null;
}
}
}
}
}
});
lt.objs.eval.__BEH__on_selected_cb = (function __BEH__on_selected_cb(obj,client){var cb = cljs.core.deref.call(null,obj).call(null,new cljs.core.Keyword(null,"cb","cb",1013907409));return cb.call(null,client);
});
lt.object.behavior_STAR_.call(null,new cljs.core.Keyword("lt.objs.eval","on-selected-cb","lt.objs.eval/on-selected-cb",1941170511),new cljs.core.Keyword(null,"reaction","reaction",4441361819),lt.objs.eval.__BEH__on_selected_cb,new cljs.core.Keyword(null,"triggers","triggers",2516997421),new cljs.core.PersistentHashSet(null, new cljs.core.PersistentArrayMap(null, 1, [new cljs.core.Keyword(null,"selected","selected",2205476365),null], null), null));
lt.objs.eval.__BEH__on_selected_destroy = (function __BEH__on_selected_destroy(obj,client){return lt.object.raise.call(null,obj,new cljs.core.Keyword(null,"destroy","destroy",2571277164));
});
lt.object.behavior_STAR_.call(null,new cljs.core.Keyword("lt.objs.eval","on-selected-destroy","lt.objs.eval/on-selected-destroy",4250002546),new cljs.core.Keyword(null,"reaction","reaction",4441361819),lt.objs.eval.__BEH__on_selected_destroy,new cljs.core.Keyword(null,"triggers","triggers",2516997421),new cljs.core.PersistentHashSet(null, new cljs.core.PersistentArrayMap(null, 1, [new cljs.core.Keyword(null,"selected","selected",2205476365),null], null), null));
lt.objs.eval.eval_queue = cljs.core.atom.call(null,cljs.core.PersistentVector.EMPTY);
lt.objs.eval.__BEH__queue_on_no_client = (function __BEH__queue_on_no_client(this$,queue_item){return cljs.core.swap_BANG_.call(null,lt.objs.eval.eval_queue,cljs.core.conj,queue_item);
});
lt.object.behavior_STAR_.call(null,new cljs.core.Keyword("lt.objs.eval","queue-on-no-client","lt.objs.eval/queue-on-no-client",3460059553),new cljs.core.Keyword(null,"reaction","reaction",4441361819),lt.objs.eval.__BEH__queue_on_no_client,new cljs.core.Keyword(null,"triggers","triggers",2516997421),new cljs.core.PersistentHashSet(null, new cljs.core.PersistentArrayMap(null, 1, [new cljs.core.Keyword(null,"no-client","no-client",4161042633),null], null), null));
lt.objs.eval.__BEH__alert_on_no_client = (function __BEH__alert_on_no_client(this$){return lt.objs.popup.popup_BANG_.call(null,new cljs.core.PersistentArrayMap(null, 3, [new cljs.core.Keyword(null,"header","header",4087600639),"No client available.",new cljs.core.Keyword(null,"body","body",1016933652),"We don't know what kind of client you want for this one. Try starting a client by choosing one of the connection types in the connect panel.",new cljs.core.Keyword(null,"buttons","buttons",1255256819),new cljs.core.PersistentVector(null, 1, 5, cljs.core.PersistentVector.EMPTY_NODE, [new cljs.core.PersistentArrayMap(null, 2, [new cljs.core.Keyword(null,"label","label",1116631654),"Connect a client",new cljs.core.Keyword(null,"action","action",3885920680),(function (){return lt.objs.sidebar.command.exec_BANG_.call(null,new cljs.core.Keyword(null,"show-add-connection","show-add-connection",3671605196));
})], null)], null)], null));
});
lt.object.behavior_STAR_.call(null,new cljs.core.Keyword("lt.objs.eval","alert-on-no-client","lt.objs.eval/alert-on-no-client",3202745142),new cljs.core.Keyword(null,"reaction","reaction",4441361819),lt.objs.eval.__BEH__alert_on_no_client,new cljs.core.Keyword(null,"triggers","triggers",2516997421),new cljs.core.PersistentHashSet(null, new cljs.core.PersistentArrayMap(null, 1, [new cljs.core.Keyword(null,"no-client","no-client",4161042633),null], null), null));
lt.objs.eval.__BEH__queue_BANG_ = (function __BEH__queue_BANG_(this$,queue_item){return cljs.core.swap_BANG_.call(null,lt.objs.eval.eval_queue,cljs.core.conj,queue_item);
});
lt.object.behavior_STAR_.call(null,new cljs.core.Keyword("lt.objs.eval","queue!","lt.objs.eval/queue!",3205931164),new cljs.core.Keyword(null,"reaction","reaction",4441361819),lt.objs.eval.__BEH__queue_BANG_,new cljs.core.Keyword(null,"triggers","triggers",2516997421),new cljs.core.PersistentHashSet(null, new cljs.core.PersistentArrayMap(null, 1, [new cljs.core.Keyword(null,"queue!","queue!",4360174754),null], null), null));
lt.objs.eval.drain = (function drain(queue){return cljs.core.vec.call(null,cljs.core.remove.call(null,(function (cur){var vec__8497 = cur;var _ = cljs.core.nth.call(null,vec__8497,0,null);var ___$1 = cljs.core.nth.call(null,vec__8497,1,null);var cb = cljs.core.nth.call(null,vec__8497,2,null);var vec__8498 = cljs.core.apply.call(null,lt.objs.clients.discover,cur);var result = cljs.core.nth.call(null,vec__8498,0,null);var client = cljs.core.nth.call(null,vec__8498,1,null);if(cljs.core._EQ_.call(null,new cljs.core.Keyword(null,"found","found",1111526132),result))
{cb.call(null,client);
return true;
} else
{return null;
}
}),queue));
});
lt.objs.eval.__BEH__on_connect_check_queue = (function __BEH__on_connect_check_queue(this$){return cljs.core.swap_BANG_.call(null,lt.objs.eval.eval_queue,lt.objs.eval.drain);
});
lt.object.behavior_STAR_.call(null,new cljs.core.Keyword("lt.objs.eval","on-connect-check-queue","lt.objs.eval/on-connect-check-queue",2429838903),new cljs.core.Keyword(null,"reaction","reaction",4441361819),lt.objs.eval.__BEH__on_connect_check_queue,new cljs.core.Keyword(null,"triggers","triggers",2516997421),new cljs.core.PersistentHashSet(null, new cljs.core.PersistentArrayMap(null, 1, [new cljs.core.Keyword(null,"connect","connect",1965255772),null], null), null));
lt.object.object_STAR_.call(null,new cljs.core.Keyword("lt.objs.eval","evaler","lt.objs.eval/evaler",3546586565),new cljs.core.Keyword(null,"tags","tags",1017456523),new cljs.core.PersistentHashSet(null, new cljs.core.PersistentArrayMap(null, 1, [new cljs.core.Keyword(null,"evaler","evaler",4017420731),null], null), null),new cljs.core.Keyword(null,"init","init",1017141378),(function (){return null;
}));
lt.objs.eval.evaler = lt.object.create.call(null,new cljs.core.Keyword("lt.objs.eval","evaler","lt.objs.eval/evaler",3546586565));
lt.object.add_behavior_BANG_.call(null,lt.objs.clients.clients,new cljs.core.Keyword("lt.objs.eval","on-connect-check-queue","lt.objs.eval/on-connect-check-queue",2429838903));
lt.objs.eval.try_read = (function try_read(r){try{return cljs.reader.read_string.call(null,r);
}catch (e8500){var e = e8500;return lt.objs.console.error.call(null,e);
}});
lt.objs.eval.find_client = (function find_client(p__8501){var map__8507 = p__8501;var map__8507__$1 = ((cljs.core.seq_QMARK_.call(null,map__8507))?cljs.core.apply.call(null,cljs.core.hash_map,map__8507):map__8507);var opts = map__8507__$1;var create = cljs.core.get.call(null,map__8507__$1,new cljs.core.Keyword(null,"create","create",3956577390));var key = cljs.core.get.call(null,map__8507__$1,new cljs.core.Keyword(null,"key","key",1014010321));var info = cljs.core.get.call(null,map__8507__$1,new cljs.core.Keyword(null,"info","info",1017141280));var command = cljs.core.get.call(null,map__8507__$1,new cljs.core.Keyword(null,"command","command",1964298941));var origin = cljs.core.get.call(null,map__8507__$1,new cljs.core.Keyword(null,"origin","origin",4300251800));var vec__8508 = lt.objs.clients.discover.call(null,command,info);var result = cljs.core.nth.call(null,vec__8508,0,null);var client = cljs.core.nth.call(null,vec__8508,1,null);var key__$1 = (function (){var or__3520__auto__ = key;if(cljs.core.truth_(or__3520__auto__))
{return or__3520__auto__;
} else
{return new cljs.core.Keyword(null,"default","default",2558708147);
}
})();var pred__8509 = cljs.core._EQ_;var expr__8510 = result;if(cljs.core.truth_(pred__8509.call(null,new cljs.core.Keyword(null,"none","none",1017291434),expr__8510)))
{if(cljs.core.truth_(create))
{return create.call(null,opts);
} else
{lt.objs.notifos.done_working.call(null);
lt.object.raise.call(null,lt.objs.eval.evaler,new cljs.core.Keyword(null,"no-client","no-client",4161042633),opts);
return lt.objs.clients.placeholder.call(null);
}
} else
{if(cljs.core.truth_(pred__8509.call(null,new cljs.core.Keyword(null,"found","found",1111526132),expr__8510)))
{return client;
} else
{if(cljs.core.truth_(pred__8509.call(null,new cljs.core.Keyword(null,"select","select",4402849902),expr__8510)))
{lt.object.raise.call(null,lt.objs.eval.evaler,new cljs.core.Keyword(null,"select-client","select-client",4292921646),client,(function (client__$1){lt.objs.clients.swap_client_BANG_.call(null,key__$1.call(null,new cljs.core.Keyword(null,"client","client",3951159101).cljs$core$IFn$_invoke$arity$1(cljs.core.deref.call(null,origin))),client__$1);
return lt.object.update_BANG_.call(null,origin,new cljs.core.PersistentVector(null, 1, 5, cljs.core.PersistentVector.EMPTY_NODE, [new cljs.core.Keyword(null,"client","client",3951159101)], null),cljs.core.assoc,key__$1,client__$1);
}));
return lt.objs.clients.placeholder.call(null);
} else
{throw (new Error([cljs.core.str("No matching clause: "),cljs.core.str(expr__8510)].join('')));
}
}
}
});
lt.objs.eval.get_client_BANG_ = (function get_client_BANG_(p__8512){var map__8514 = p__8512;var map__8514__$1 = ((cljs.core.seq_QMARK_.call(null,map__8514))?cljs.core.apply.call(null,cljs.core.hash_map,map__8514):map__8514);var opts = map__8514__$1;var create = cljs.core.get.call(null,map__8514__$1,new cljs.core.Keyword(null,"create","create",3956577390));var key = cljs.core.get.call(null,map__8514__$1,new cljs.core.Keyword(null,"key","key",1014010321));var command = cljs.core.get.call(null,map__8514__$1,new cljs.core.Keyword(null,"command","command",1964298941));var origin = cljs.core.get.call(null,map__8514__$1,new cljs.core.Keyword(null,"origin","origin",4300251800));var key__$1 = (function (){var or__3520__auto__ = key;if(cljs.core.truth_(or__3520__auto__))
{return or__3520__auto__;
} else
{return new cljs.core.Keyword(null,"default","default",2558708147);
}
})();var cur = key__$1.call(null,new cljs.core.Keyword(null,"client","client",3951159101).cljs$core$IFn$_invoke$arity$1(cljs.core.deref.call(null,origin)));if(cljs.core.truth_((function (){var and__3508__auto__ = cur;if(cljs.core.truth_(and__3508__auto__))
{return lt.objs.clients.available_QMARK_.call(null,cur);
} else
{return and__3508__auto__;
}
})()))
{return cur;
} else
{var neue = lt.objs.eval.find_client.call(null,opts);lt.object.update_BANG_.call(null,origin,new cljs.core.PersistentVector(null, 1, 5, cljs.core.PersistentVector.EMPTY_NODE, [new cljs.core.Keyword(null,"client","client",3951159101)], null),cljs.core.assoc,key__$1,neue);
lt.object.raise.call(null,origin,new cljs.core.Keyword(null,"set-client","set-client",2248164104),neue);
return neue;
}
});
lt.objs.eval.__GT_result_class = (function __GT_result_class(this$,trunc){return [cljs.core.str(new cljs.core.Keyword(null,"class","class",1108647146).cljs$core$IFn$_invoke$arity$1(this$)),cljs.core.str("-result result-mark"),cljs.core.str((cljs.core.truth_((function (){var or__3520__auto__ = new cljs.core.Keyword(null,"open","open",1017321916).cljs$core$IFn$_invoke$arity$1(this$);if(cljs.core.truth_(or__3520__auto__))
{return or__3520__auto__;
} else
{return cljs.core.not.call(null,trunc);
}
})())?" open":null))].join('');
});
lt.objs.eval.truncate_result = (function() {
var truncate_result = null;
var truncate_result__1 = (function (r){return truncate_result.call(null,r,null);
});
var truncate_result__2 = (function (r,opts){if(typeof r === 'string')
{var nl = r.indexOf("\n");var len = (((nl > -1))?nl:new cljs.core.Keyword(null,"trunc-length","trunc-length",2555961753).cljs$core$IFn$_invoke$arity$2(opts,50));if((cljs.core.count.call(null,r) > len))
{return [cljs.core.str(cljs.core.subs.call(null,r,0,len)),cljs.core.str(" \u2026")].join('');
} else
{return r;
}
} else
{return null;
}
});
truncate_result = function(r,opts){
switch(arguments.length){
case 1:
return truncate_result__1.call(this,r);
case 2:
return truncate_result__2.call(this,r,opts);
}
throw(new Error('Invalid arity: ' + arguments.length));
};
truncate_result.cljs$core$IFn$_invoke$arity$1 = truncate_result__1;
truncate_result.cljs$core$IFn$_invoke$arity$2 = truncate_result__2;
return truncate_result;
})()
;
lt.objs.eval.__GT_inline_res = (function __GT_inline_res(this$,info){var e__3325__auto__ = crate.core.html.call(null,(function (){var r = new cljs.core.Keyword(null,"result","result",4374444943).cljs$core$IFn$_invoke$arity$1(info);var truncated = lt.objs.eval.truncate_result.call(null,r,info);return new cljs.core.PersistentVector(null, 4, 5, cljs.core.PersistentVector.EMPTY_NODE, [new cljs.core.Keyword(null,"span","span",1017440956),new cljs.core.PersistentArrayMap(null, 1, [new cljs.core.Keyword(null,"class","class",1108647146),crate.binding.bound.call(null,this$,((function (r,truncated){
return (function (p1__8515_SHARP_){return lt.objs.eval.__GT_result_class.call(null,p1__8515_SHARP_,truncated);
});})(r,truncated))
)], null),(cljs.core.truth_(truncated)?new cljs.core.PersistentVector(null, 2, 5, cljs.core.PersistentVector.EMPTY_NODE, [new cljs.core.Keyword(null,"span.truncated","span.truncated",906070412),truncated], null):null),new cljs.core.PersistentVector(null, 2, 5, cljs.core.PersistentVector.EMPTY_NODE, [new cljs.core.Keyword(null,"span.full","span.full",4619654693),r], null)], null);
})());var seq__8522_8528 = cljs.core.seq.call(null,cljs.core.partition.call(null,2,new cljs.core.PersistentVector(null, 8, 5, cljs.core.PersistentVector.EMPTY_NODE, [new cljs.core.Keyword(null,"mousewheel","mousewheel",2043515208),(function (e){return lt.util.dom.stop_propagation.call(null,e);
}),new cljs.core.Keyword(null,"click","click",1108654330),(function (e){lt.util.dom.prevent.call(null,e);
return lt.object.raise.call(null,this$,new cljs.core.Keyword(null,"click","click",1108654330));
}),new cljs.core.Keyword(null,"contextmenu","contextmenu",911789824),(function (e){lt.util.dom.prevent.call(null,e);
return lt.object.raise.call(null,this$,new cljs.core.Keyword(null,"menu!","menu!",1117686292),e);
}),new cljs.core.Keyword(null,"dblclick","dblclick",3463991820),(function (e){lt.util.dom.prevent.call(null,e);
return lt.object.raise.call(null,this$,new cljs.core.Keyword(null,"double-click","double-click",956590078));
})], null)));var chunk__8523_8529 = null;var count__8524_8530 = 0;var i__8525_8531 = 0;while(true){
if((i__8525_8531 < count__8524_8530))
{var vec__8526_8532 = cljs.core._nth.call(null,chunk__8523_8529,i__8525_8531);var ev__3326__auto___8533 = cljs.core.nth.call(null,vec__8526_8532,0,null);var func__3327__auto___8534 = cljs.core.nth.call(null,vec__8526_8532,1,null);lt.util.dom.on.call(null,e__3325__auto__,ev__3326__auto___8533,func__3327__auto___8534);
{
var G__8535 = seq__8522_8528;
var G__8536 = chunk__8523_8529;
var G__8537 = count__8524_8530;
var G__8538 = (i__8525_8531 + 1);
seq__8522_8528 = G__8535;
chunk__8523_8529 = G__8536;
count__8524_8530 = G__8537;
i__8525_8531 = G__8538;
continue;
}
} else
{var temp__4092__auto___8539 = cljs.core.seq.call(null,seq__8522_8528);if(temp__4092__auto___8539)
{var seq__8522_8540__$1 = temp__4092__auto___8539;if(cljs.core.chunked_seq_QMARK_.call(null,seq__8522_8540__$1))
{var c__4262__auto___8541 = cljs.core.chunk_first.call(null,seq__8522_8540__$1);{
var G__8542 = cljs.core.chunk_rest.call(null,seq__8522_8540__$1);
var G__8543 = c__4262__auto___8541;
var G__8544 = cljs.core.count.call(null,c__4262__auto___8541);
var G__8545 = 0;
seq__8522_8528 = G__8542;
chunk__8523_8529 = G__8543;
count__8524_8530 = G__8544;
i__8525_8531 = G__8545;
continue;
}
} else
{var vec__8527_8546 = cljs.core.first.call(null,seq__8522_8540__$1);var ev__3326__auto___8547 = cljs.core.nth.call(null,vec__8527_8546,0,null);var func__3327__auto___8548 = cljs.core.nth.call(null,vec__8527_8546,1,null);lt.util.dom.on.call(null,e__3325__auto__,ev__3326__auto___8547,func__3327__auto___8548);
{
var G__8549 = cljs.core.next.call(null,seq__8522_8540__$1);
var G__8550 = null;
var G__8551 = 0;
var G__8552 = 0;
seq__8522_8528 = G__8549;
chunk__8523_8529 = G__8550;
count__8524_8530 = G__8551;
i__8525_8531 = G__8552;
continue;
}
}
} else
{}
}
break;
}
return e__3325__auto__;
});
lt.objs.eval.__BEH__result_menu_PLUS_ = (function __BEH__result_menu_PLUS_(this$,items){return cljs.core.conj.call(null,items,new cljs.core.PersistentArrayMap(null, 3, [new cljs.core.Keyword(null,"label","label",1116631654),"Remove result",new cljs.core.Keyword(null,"order","order",1119910592),1,new cljs.core.Keyword(null,"click","click",1108654330),(function (){return lt.object.raise.call(null,this$,new cljs.core.Keyword(null,"clear!","clear!",3951036134));
})], null),new cljs.core.PersistentArrayMap(null, 3, [new cljs.core.Keyword(null,"label","label",1116631654),"Copy result",new cljs.core.Keyword(null,"order","order",1119910592),2,new cljs.core.Keyword(null,"click","click",1108654330),(function (){return lt.object.raise.call(null,this$,new cljs.core.Keyword(null,"copy","copy",1016963815));
})], null));
});
lt.object.behavior_STAR_.call(null,new cljs.core.Keyword("lt.objs.eval","result-menu+","lt.objs.eval/result-menu+",3431235704),new cljs.core.Keyword(null,"reaction","reaction",4441361819),lt.objs.eval.__BEH__result_menu_PLUS_,new cljs.core.Keyword(null,"triggers","triggers",2516997421),new cljs.core.PersistentHashSet(null, new cljs.core.PersistentArrayMap(null, 1, [new cljs.core.Keyword(null,"menu+","menu+",1117686302),null], null), null));
lt.objs.eval.__BEH__expand_on_click = (function __BEH__expand_on_click(this$){lt.object.merge_BANG_.call(null,this$,new cljs.core.PersistentArrayMap(null, 1, [new cljs.core.Keyword(null,"open","open",1017321916),true], null));
return lt.object.raise.call(null,this$,new cljs.core.Keyword(null,"changed","changed",1752847910));
});
lt.object.behavior_STAR_.call(null,new cljs.core.Keyword("lt.objs.eval","expand-on-click","lt.objs.eval/expand-on-click",541363545),new cljs.core.Keyword(null,"reaction","reaction",4441361819),lt.objs.eval.__BEH__expand_on_click,new cljs.core.Keyword(null,"triggers","triggers",2516997421),new cljs.core.PersistentHashSet(null, new cljs.core.PersistentArrayMap(null, 2, [new cljs.core.Keyword(null,"expand!","expand!",3999393849),null,new cljs.core.Keyword(null,"click","click",1108654330),null], null), null));
lt.objs.eval.__BEH__shrink_on_double_click = (function __BEH__shrink_on_double_click(this$){lt.object.merge_BANG_.call(null,this$,new cljs.core.PersistentArrayMap(null, 1, [new cljs.core.Keyword(null,"open","open",1017321916),false], null));
lt.object.raise.call(null,this$,new cljs.core.Keyword(null,"changed","changed",1752847910));
return lt.objs.editor.focus.call(null,new cljs.core.Keyword(null,"ed","ed",1013907473).cljs$core$IFn$_invoke$arity$1(cljs.core.deref.call(null,this$)));
});
lt.object.behavior_STAR_.call(null,new cljs.core.Keyword("lt.objs.eval","shrink-on-double-click","lt.objs.eval/shrink-on-double-click",3353397618),new cljs.core.Keyword(null,"reaction","reaction",4441361819),lt.objs.eval.__BEH__shrink_on_double_click,new cljs.core.Keyword(null,"triggers","triggers",2516997421),new cljs.core.PersistentHashSet(null, new cljs.core.PersistentArrayMap(null, 2, [new cljs.core.Keyword(null,"double-click","double-click",956590078),null,new cljs.core.Keyword(null,"shrink!","shrink!",3083562666),null], null), null));
lt.objs.eval.__BEH__destroy_on_cleared = (function __BEH__destroy_on_cleared(this$){return lt.object.destroy_BANG_.call(null,this$);
});
lt.object.behavior_STAR_.call(null,new cljs.core.Keyword("lt.objs.eval","destroy-on-cleared","lt.objs.eval/destroy-on-cleared",4445067485),new cljs.core.Keyword(null,"reaction","reaction",4441361819),lt.objs.eval.__BEH__destroy_on_cleared,new cljs.core.Keyword(null,"triggers","triggers",2516997421),new cljs.core.PersistentHashSet(null, new cljs.core.PersistentArrayMap(null, 1, [new cljs.core.Keyword(null,"cleared","cleared",1870681886),null], null), null));
lt.objs.eval.__BEH__clear_mark = (function __BEH__clear_mark(this$){if(cljs.core.truth_(cljs.core.deref.call(null,new cljs.core.Keyword(null,"ed","ed",1013907473).cljs$core$IFn$_invoke$arity$1(cljs.core.deref.call(null,this$)))))
{CodeMirror.off(new cljs.core.Keyword(null,"line","line",1017226086).cljs$core$IFn$_invoke$arity$1(cljs.core.deref.call(null,this$)),"change",new cljs.core.Keyword(null,"listener","listener",2360064038).cljs$core$IFn$_invoke$arity$1(cljs.core.deref.call(null,this$)));
CodeMirror.off(new cljs.core.Keyword(null,"line","line",1017226086).cljs$core$IFn$_invoke$arity$1(cljs.core.deref.call(null,this$)),"delete",new cljs.core.Keyword(null,"delete","delete",3973413149).cljs$core$IFn$_invoke$arity$1(cljs.core.deref.call(null,this$)));
new cljs.core.Keyword(null,"mark","mark",1017248319).cljs$core$IFn$_invoke$arity$1(cljs.core.deref.call(null,this$)).clear();
lt.object.raise.call(null,this$,new cljs.core.Keyword(null,"clear","clear",1108650431));
return lt.object.raise.call(null,this$,new cljs.core.Keyword(null,"cleared","cleared",1870681886));
} else
{return null;
}
});
lt.object.behavior_STAR_.call(null,new cljs.core.Keyword("lt.objs.eval","clear-mark","lt.objs.eval/clear-mark",1960624569),new cljs.core.Keyword(null,"reaction","reaction",4441361819),lt.objs.eval.__BEH__clear_mark,new cljs.core.Keyword(null,"triggers","triggers",2516997421),new cljs.core.PersistentHashSet(null, new cljs.core.PersistentArrayMap(null, 1, [new cljs.core.Keyword(null,"clear!","clear!",3951036134),null], null), null));
lt.objs.eval.__BEH__copy_result = (function __BEH__copy_result(this$){return lt.objs.platform.copy.call(null,new cljs.core.Keyword(null,"result","result",4374444943).cljs$core$IFn$_invoke$arity$1(cljs.core.deref.call(null,this$)));
});
lt.object.behavior_STAR_.call(null,new cljs.core.Keyword("lt.objs.eval","copy-result","lt.objs.eval/copy-result",4462509297),new cljs.core.Keyword(null,"reaction","reaction",4441361819),lt.objs.eval.__BEH__copy_result,new cljs.core.Keyword(null,"triggers","triggers",2516997421),new cljs.core.PersistentHashSet(null, new cljs.core.PersistentArrayMap(null, 1, [new cljs.core.Keyword(null,"copy","copy",1016963815),null], null), null));
lt.objs.eval.__BEH__changed = (function __BEH__changed(this$){return new cljs.core.Keyword(null,"mark","mark",1017248319).cljs$core$IFn$_invoke$arity$1(cljs.core.deref.call(null,this$)).changed();
});
lt.object.behavior_STAR_.call(null,new cljs.core.Keyword("lt.objs.eval","changed","lt.objs.eval/changed",710785568),new cljs.core.Keyword(null,"reaction","reaction",4441361819),lt.objs.eval.__BEH__changed,new cljs.core.Keyword(null,"triggers","triggers",2516997421),new cljs.core.PersistentHashSet(null, new cljs.core.PersistentArrayMap(null, 1, [new cljs.core.Keyword(null,"changed","changed",1752847910),null], null), null));
lt.objs.eval.__BEH__update_BANG_ = (function __BEH__update_BANG_(this$,res){var content = lt.object.__GT_content.call(null,this$);var full = lt.util.dom.$.call(null,new cljs.core.Keyword(null,".full",".full",1059540783),content);var scroll = lt.util.dom.scroll_top.call(null,full);var temp__4092__auto___8553 = lt.objs.eval.truncate_result.call(null,res);if(cljs.core.truth_(temp__4092__auto___8553))
{var t_8554 = temp__4092__auto___8553;var temp__4092__auto___8555__$1 = lt.util.dom.$.call(null,new cljs.core.Keyword(null,".truncated",".truncated",2172167874),content);if(cljs.core.truth_(temp__4092__auto___8555__$1))
{var trunc_8556 = temp__4092__auto___8555__$1;lt.util.dom.html.call(null,trunc_8556,t_8554);
} else
{}
} else
{}
lt.util.dom.html.call(null,full,res);
return lt.util.dom.scroll_top.call(null,full,scroll);
});
lt.object.behavior_STAR_.call(null,new cljs.core.Keyword("lt.objs.eval","update!","lt.objs.eval/update!",2489665524),new cljs.core.Keyword(null,"reaction","reaction",4441361819),lt.objs.eval.__BEH__update_BANG_,new cljs.core.Keyword(null,"triggers","triggers",2516997421),new cljs.core.PersistentHashSet(null, new cljs.core.PersistentArrayMap(null, 1, [new cljs.core.Keyword(null,"update!","update!",779473898),null], null), null));
lt.objs.eval.new_line_change = new cljs.core.PersistentVector(null, 2, 5, cljs.core.PersistentVector.EMPTY_NODE, ["",""], null);
lt.objs.eval.__BEH__move_mark = (function __BEH__move_mark(this$,ch){if(cljs.core.truth_(ch))
{var orig = new cljs.core.Keyword(null,"mark","mark",1017248319).cljs$core$IFn$_invoke$arity$1(cljs.core.deref.call(null,this$));var loc = orig.find();var cur_line = lt.objs.editor.lh__GT_line.call(null,new cljs.core.Keyword(null,"ed","ed",1013907473).cljs$core$IFn$_invoke$arity$1(cljs.core.deref.call(null,this$)),new cljs.core.Keyword(null,"line","line",1017226086).cljs$core$IFn$_invoke$arity$1(cljs.core.deref.call(null,this$)));if((cljs.core.not.call(null,loc)) || (cljs.core.empty_QMARK_.call(null,new cljs.core.Keyword(null,"line","line",1017226086).cljs$core$IFn$_invoke$arity$1(cljs.core.deref.call(null,this$)).text)))
{return lt.object.raise.call(null,this$,new cljs.core.Keyword(null,"clear!","clear!",3951036134));
} else
{if((((loc.line > ch.to.line)) && (cljs.core.empty_QMARK_.call(null,clojure.string.trim.call(null,lt.objs.editor.line.call(null,new cljs.core.Keyword(null,"ed","ed",1013907473).cljs$core$IFn$_invoke$arity$1(cljs.core.deref.call(null,this$)),loc.line))))) || ((((ch.to.ch >= loc.ch)) && (cljs.core._EQ_.call(null,ch.to.line,loc.line))) || ((ch.to.line > ch.from.line))))
{lt.object.merge_BANG_.call(null,this$,new cljs.core.PersistentArrayMap(null, 1, [new cljs.core.Keyword(null,"mark","mark",1017248319),lt.objs.editor.bookmark.call(null,lt.objs.editor.__GT_cm_ed.call(null,new cljs.core.Keyword(null,"ed","ed",1013907473).cljs$core$IFn$_invoke$arity$1(cljs.core.deref.call(null,this$))),new cljs.core.PersistentArrayMap(null, 1, [new cljs.core.Keyword(null,"line","line",1017226086),cur_line], null),new cljs.core.PersistentArrayMap(null, 2, [new cljs.core.Keyword(null,"widget","widget",4520824246),lt.object.__GT_content.call(null,this$),new cljs.core.Keyword(null,"insertLeft","insertLeft",1979827666),true], null))], null));
if(cljs.core.truth_(orig))
{return orig.clear();
} else
{return null;
}
} else
{return null;
}
}
} else
{return null;
}
});
lt.object.behavior_STAR_.call(null,new cljs.core.Keyword("lt.objs.eval","move-mark","lt.objs.eval/move-mark",1501429445),new cljs.core.Keyword(null,"reaction","reaction",4441361819),lt.objs.eval.__BEH__move_mark,new cljs.core.Keyword(null,"triggers","triggers",2516997421),new cljs.core.PersistentHashSet(null, new cljs.core.PersistentArrayMap(null, 1, [new cljs.core.Keyword(null,"move!","move!",1117991394),null], null), null));
lt.object.object_STAR_.call(null,new cljs.core.Keyword("lt.objs.eval","inline-result","lt.objs.eval/inline-result",1807255869),new cljs.core.Keyword(null,"triggers","triggers",2516997421),new cljs.core.PersistentHashSet(null, new cljs.core.PersistentArrayMap(null, 3, [new cljs.core.Keyword(null,"double-click","double-click",956590078),null,new cljs.core.Keyword(null,"click","click",1108654330),null,new cljs.core.Keyword(null,"clear!","clear!",3951036134),null], null), null),new cljs.core.Keyword(null,"tags","tags",1017456523),new cljs.core.PersistentHashSet(null, new cljs.core.PersistentArrayMap(null, 2, [new cljs.core.Keyword(null,"inline.result","inline.result",1543983236),null,new cljs.core.Keyword(null,"inline","inline",4124874251),null], null), null),new cljs.core.Keyword(null,"init","init",1017141378),(function (this$,info){var temp__4092__auto__ = lt.objs.editor.__GT_cm_ed.call(null,new cljs.core.Keyword(null,"ed","ed",1013907473).cljs$core$IFn$_invoke$arity$1(info));if(cljs.core.truth_(temp__4092__auto__))
{var ed = temp__4092__auto__;var content = lt.objs.eval.__GT_inline_res.call(null,this$,info);var delete$ = ((function (content){
return (function (_){return lt.object.raise.call(null,this$,new cljs.core.Keyword(null,"clear!","clear!",3951036134));
});})(content))
;var listener = ((function (content,delete$){
return (function (line,change){return lt.object.raise.call(null,this$,new cljs.core.Keyword(null,"move!","move!",1117991394),change);
});})(content,delete$))
;CodeMirror.on(new cljs.core.Keyword(null,"line","line",1017226086).cljs$core$IFn$_invoke$arity$1(info),"change",listener);
CodeMirror.on(new cljs.core.Keyword(null,"line","line",1017226086).cljs$core$IFn$_invoke$arity$1(info),"delete",delete$);
lt.object.merge_BANG_.call(null,this$,cljs.core.assoc.call(null,info,new cljs.core.Keyword(null,"listener","listener",2360064038),listener,new cljs.core.Keyword(null,"delete","delete",3973413149),delete$,new cljs.core.Keyword(null,"mark","mark",1017248319),lt.objs.editor.bookmark.call(null,ed,new cljs.core.PersistentArrayMap(null, 1, [new cljs.core.Keyword(null,"line","line",1017226086),new cljs.core.Keyword(null,"line","line",1017226086).cljs$core$IFn$_invoke$arity$1(new cljs.core.Keyword(null,"loc","loc",1014011570).cljs$core$IFn$_invoke$arity$1(info))], null),new cljs.core.PersistentArrayMap(null, 2, [new cljs.core.Keyword(null,"widget","widget",4520824246),content,new cljs.core.Keyword(null,"insertLeft","insertLeft",1979827666),true], null))));
return content;
} else
{return null;
}
}));
lt.objs.eval.__BEH__inline_results = (function __BEH__inline_results(this$,res,loc,opts){var ed = new cljs.core.Keyword(null,"ed","ed",1013907473).cljs$core$IFn$_invoke$arity$1(cljs.core.deref.call(null,this$));var type = (function (){var or__3520__auto__ = new cljs.core.Keyword(null,"type","type",1017479852).cljs$core$IFn$_invoke$arity$1(opts);if(cljs.core.truth_(or__3520__auto__))
{return or__3520__auto__;
} else
{return new cljs.core.Keyword(null,"inline","inline",4124874251);
}
})();var line = lt.objs.editor.line_handle.call(null,ed,new cljs.core.Keyword(null,"line","line",1017226086).cljs$core$IFn$_invoke$arity$1(loc));var res_obj = lt.object.create.call(null,new cljs.core.Keyword("lt.objs.eval","inline-result","lt.objs.eval/inline-result",1807255869),new cljs.core.PersistentArrayMap(null, 6, [new cljs.core.Keyword(null,"ed","ed",1013907473),this$,new cljs.core.Keyword(null,"class","class",1108647146),cljs.core.name.call(null,type),new cljs.core.Keyword(null,"opts","opts",1017322386),opts,new cljs.core.Keyword(null,"result","result",4374444943),res,new cljs.core.Keyword(null,"loc","loc",1014011570),loc,new cljs.core.Keyword(null,"line","line",1017226086),line], null));var temp__4092__auto___8570 = cljs.core.get.call(null,cljs.core.deref.call(null,this$).call(null,new cljs.core.Keyword(null,"widgets","widgets",2354242081)),new cljs.core.PersistentVector(null, 2, 5, cljs.core.PersistentVector.EMPTY_NODE, [line,type], null));if(cljs.core.truth_(temp__4092__auto___8570))
{var prev_8571 = temp__4092__auto___8570;if(cljs.core.truth_(new cljs.core.Keyword(null,"open","open",1017321916).cljs$core$IFn$_invoke$arity$1(cljs.core.deref.call(null,prev_8571))))
{lt.object.merge_BANG_.call(null,res_obj,new cljs.core.PersistentArrayMap(null, 1, [new cljs.core.Keyword(null,"open","open",1017321916),true], null));
} else
{}
lt.object.raise.call(null,prev_8571,new cljs.core.Keyword(null,"clear!","clear!",3951036134));
} else
{}
if(cljs.core.truth_(new cljs.core.Keyword(null,"start-line","start-line",3689311729).cljs$core$IFn$_invoke$arity$1(loc)))
{var seq__8564_8572 = cljs.core.seq.call(null,cljs.core.map.call(null,(function (p1__8557_SHARP_){return cljs.core.get.call(null,cljs.core.deref.call(null,this$).call(null,new cljs.core.Keyword(null,"widgets","widgets",2354242081)),new cljs.core.PersistentVector(null, 2, 5, cljs.core.PersistentVector.EMPTY_NODE, [lt.objs.editor.line_handle.call(null,ed,p1__8557_SHARP_),type], null));
}),cljs.core.range.call(null,new cljs.core.Keyword(null,"start-line","start-line",3689311729).cljs$core$IFn$_invoke$arity$1(loc),new cljs.core.Keyword(null,"line","line",1017226086).cljs$core$IFn$_invoke$arity$1(loc))));var chunk__8566_8573 = null;var count__8567_8574 = 0;var i__8568_8575 = 0;while(true){
if((i__8568_8575 < count__8567_8574))
{var widget_8576 = cljs.core._nth.call(null,chunk__8566_8573,i__8568_8575);if(cljs.core.truth_(widget_8576))
{lt.object.raise.call(null,widget_8576,new cljs.core.Keyword(null,"clear!","clear!",3951036134));
{
var G__8577 = seq__8564_8572;
var G__8578 = chunk__8566_8573;
var G__8579 = count__8567_8574;
var G__8580 = (i__8568_8575 + 1);
seq__8564_8572 = G__8577;
chunk__8566_8573 = G__8578;
count__8567_8574 = G__8579;
i__8568_8575 = G__8580;
continue;
}
} else
{{
var G__8581 = seq__8564_8572;
var G__8582 = chunk__8566_8573;
var G__8583 = count__8567_8574;
var G__8584 = (i__8568_8575 + 1);
seq__8564_8572 = G__8581;
chunk__8566_8573 = G__8582;
count__8567_8574 = G__8583;
i__8568_8575 = G__8584;
continue;
}
}
} else
{var temp__4092__auto___8585 = cljs.core.seq.call(null,seq__8564_8572);if(temp__4092__auto___8585)
{var seq__8564_8586__$1 = temp__4092__auto___8585;if(cljs.core.chunked_seq_QMARK_.call(null,seq__8564_8586__$1))
{var c__4262__auto___8587 = cljs.core.chunk_first.call(null,seq__8564_8586__$1);{
var G__8588 = cljs.core.chunk_rest.call(null,seq__8564_8586__$1);
var G__8589 = c__4262__auto___8587;
var G__8590 = cljs.core.count.call(null,c__4262__auto___8587);
var G__8591 = 0;
seq__8564_8572 = G__8588;
chunk__8566_8573 = G__8589;
count__8567_8574 = G__8590;
i__8568_8575 = G__8591;
continue;
}
} else
{var widget_8592 = cljs.core.first.call(null,seq__8564_8586__$1);if(cljs.core.truth_(widget_8592))
{lt.object.raise.call(null,widget_8592,new cljs.core.Keyword(null,"clear!","clear!",3951036134));
{
var G__8593 = cljs.core.next.call(null,seq__8564_8586__$1);
var G__8594 = null;
var G__8595 = 0;
var G__8596 = 0;
seq__8564_8572 = G__8593;
chunk__8566_8573 = G__8594;
count__8567_8574 = G__8595;
i__8568_8575 = G__8596;
continue;
}
} else
{{
var G__8597 = cljs.core.next.call(null,seq__8564_8586__$1);
var G__8598 = null;
var G__8599 = 0;
var G__8600 = 0;
seq__8564_8572 = G__8597;
chunk__8566_8573 = G__8598;
count__8567_8574 = G__8599;
i__8568_8575 = G__8600;
continue;
}
}
}
} else
{}
}
break;
}
} else
{}
return lt.object.update_BANG_.call(null,this$,new cljs.core.PersistentVector(null, 1, 5, cljs.core.PersistentVector.EMPTY_NODE, [new cljs.core.Keyword(null,"widgets","widgets",2354242081)], null),cljs.core.assoc,new cljs.core.PersistentVector(null, 2, 5, cljs.core.PersistentVector.EMPTY_NODE, [line,type], null),res_obj);
});
lt.object.behavior_STAR_.call(null,new cljs.core.Keyword("lt.objs.eval","inline-results","lt.objs.eval/inline-results",3940069422),new cljs.core.Keyword(null,"reaction","reaction",4441361819),lt.objs.eval.__BEH__inline_results,new cljs.core.Keyword(null,"triggers","triggers",2516997421),new cljs.core.PersistentHashSet(null, new cljs.core.PersistentArrayMap(null, 1, [new cljs.core.Keyword(null,"editor.result","editor.result",4030217008),null], null), null));
lt.objs.eval.__GT_spacing = (function __GT_spacing(text){if(cljs.core.truth_(text))
{return cljs.core.first.call(null,cljs.core.re_seq.call(null,/^\s+/,text));
} else
{return null;
}
});
lt.objs.eval.__GT_underline_result = (function __GT_underline_result(this$,info){var e__3325__auto__ = crate.core.html.call(null,new cljs.core.PersistentVector(null, 4, 5, cljs.core.PersistentVector.EMPTY_NODE, [new cljs.core.Keyword(null,"div","div",1014003715),new cljs.core.PersistentArrayMap(null, 1, [new cljs.core.Keyword(null,"class","class",1108647146),[cljs.core.str("underline-result "),cljs.core.str((cljs.core.truth_(new cljs.core.Keyword(null,"class","class",1108647146).cljs$core$IFn$_invoke$arity$1(info))?new cljs.core.Keyword(null,"class","class",1108647146).cljs$core$IFn$_invoke$arity$1(info):null))].join('')], null),new cljs.core.PersistentVector(null, 2, 5, cljs.core.PersistentVector.EMPTY_NODE, [new cljs.core.Keyword(null,"span.spacer","span.spacer",4763675330),lt.objs.eval.__GT_spacing.call(null,lt.objs.editor.line.call(null,new cljs.core.Keyword(null,"ed","ed",1013907473).cljs$core$IFn$_invoke$arity$1(info),new cljs.core.Keyword(null,"line","line",1017226086).cljs$core$IFn$_invoke$arity$1(new cljs.core.Keyword(null,"loc","loc",1014011570).cljs$core$IFn$_invoke$arity$1(info))))], null),new cljs.core.PersistentVector(null, 2, 5, cljs.core.PersistentVector.EMPTY_NODE, [new cljs.core.Keyword(null,"pre","pre",1014015509),new cljs.core.Keyword(null,"result","result",4374444943).cljs$core$IFn$_invoke$arity$1(info)], null)], null));var seq__8607_8613 = cljs.core.seq.call(null,cljs.core.partition.call(null,2,new cljs.core.PersistentVector(null, 6, 5, cljs.core.PersistentVector.EMPTY_NODE, [new cljs.core.Keyword(null,"click","click",1108654330),(function (e){lt.util.dom.prevent.call(null,e);
return lt.object.raise.call(null,this$,new cljs.core.Keyword(null,"click","click",1108654330));
}),new cljs.core.Keyword(null,"contextmenu","contextmenu",911789824),(function (e){lt.util.dom.prevent.call(null,e);
return lt.object.raise.call(null,this$,new cljs.core.Keyword(null,"menu!","menu!",1117686292),e);
}),new cljs.core.Keyword(null,"dblclick","dblclick",3463991820),(function (e){lt.util.dom.prevent.call(null,e);
return lt.object.raise.call(null,this$,new cljs.core.Keyword(null,"double-click","double-click",956590078));
})], null)));var chunk__8608_8614 = null;var count__8609_8615 = 0;var i__8610_8616 = 0;while(true){
if((i__8610_8616 < count__8609_8615))
{var vec__8611_8617 = cljs.core._nth.call(null,chunk__8608_8614,i__8610_8616);var ev__3326__auto___8618 = cljs.core.nth.call(null,vec__8611_8617,0,null);var func__3327__auto___8619 = cljs.core.nth.call(null,vec__8611_8617,1,null);lt.util.dom.on.call(null,e__3325__auto__,ev__3326__auto___8618,func__3327__auto___8619);
{
var G__8620 = seq__8607_8613;
var G__8621 = chunk__8608_8614;
var G__8622 = count__8609_8615;
var G__8623 = (i__8610_8616 + 1);
seq__8607_8613 = G__8620;
chunk__8608_8614 = G__8621;
count__8609_8615 = G__8622;
i__8610_8616 = G__8623;
continue;
}
} else
{var temp__4092__auto___8624 = cljs.core.seq.call(null,seq__8607_8613);if(temp__4092__auto___8624)
{var seq__8607_8625__$1 = temp__4092__auto___8624;if(cljs.core.chunked_seq_QMARK_.call(null,seq__8607_8625__$1))
{var c__4262__auto___8626 = cljs.core.chunk_first.call(null,seq__8607_8625__$1);{
var G__8627 = cljs.core.chunk_rest.call(null,seq__8607_8625__$1);
var G__8628 = c__4262__auto___8626;
var G__8629 = cljs.core.count.call(null,c__4262__auto___8626);
var G__8630 = 0;
seq__8607_8613 = G__8627;
chunk__8608_8614 = G__8628;
count__8609_8615 = G__8629;
i__8610_8616 = G__8630;
continue;
}
} else
{var vec__8612_8631 = cljs.core.first.call(null,seq__8607_8625__$1);var ev__3326__auto___8632 = cljs.core.nth.call(null,vec__8612_8631,0,null);var func__3327__auto___8633 = cljs.core.nth.call(null,vec__8612_8631,1,null);lt.util.dom.on.call(null,e__3325__auto__,ev__3326__auto___8632,func__3327__auto___8633);
{
var G__8634 = cljs.core.next.call(null,seq__8607_8625__$1);
var G__8635 = null;
var G__8636 = 0;
var G__8637 = 0;
seq__8607_8613 = G__8634;
chunk__8608_8614 = G__8635;
count__8609_8615 = G__8636;
i__8610_8616 = G__8637;
continue;
}
}
} else
{}
}
break;
}
return e__3325__auto__;
});
lt.object.object_STAR_.call(null,new cljs.core.Keyword("lt.objs.eval","underline-result","lt.objs.eval/underline-result",1485297066),new cljs.core.Keyword(null,"tags","tags",1017456523),new cljs.core.PersistentHashSet(null, new cljs.core.PersistentArrayMap(null, 2, [new cljs.core.Keyword(null,"inline.underline-result","inline.underline-result",1936787557),null,new cljs.core.Keyword(null,"inline","inline",4124874251),null], null), null),new cljs.core.Keyword(null,"init","init",1017141378),(function (this$,info){var content = lt.objs.eval.__GT_underline_result.call(null,this$,info);var delete$ = ((function (content){
return (function (_){return lt.object.raise.call(null,this$,new cljs.core.Keyword(null,"clear!","clear!",3951036134));
});})(content))
;var listener = ((function (content,delete$){
return (function (line,change){return lt.object.raise.call(null,this$,new cljs.core.Keyword(null,"move!","move!",1117991394),change);
});})(content,delete$))
;CodeMirror.on(new cljs.core.Keyword(null,"line","line",1017226086).cljs$core$IFn$_invoke$arity$1(info),"change",listener);
CodeMirror.on(new cljs.core.Keyword(null,"line","line",1017226086).cljs$core$IFn$_invoke$arity$1(info),"delete",delete$);
lt.object.merge_BANG_.call(null,this$,cljs.core.assoc.call(null,info,new cljs.core.Keyword(null,"widget","widget",4520824246),lt.objs.editor.line_widget.call(null,lt.objs.editor.__GT_cm_ed.call(null,new cljs.core.Keyword(null,"ed","ed",1013907473).cljs$core$IFn$_invoke$arity$1(info)),new cljs.core.Keyword(null,"line","line",1017226086).cljs$core$IFn$_invoke$arity$1(new cljs.core.Keyword(null,"loc","loc",1014011570).cljs$core$IFn$_invoke$arity$1(info)),content,new cljs.core.PersistentArrayMap(null, 2, [new cljs.core.Keyword(null,"coverGutter","coverGutter",510635812),false,new cljs.core.Keyword(null,"above","above",1106515727),new cljs.core.Keyword(null,"above","above",1106515727).cljs$core$IFn$_invoke$arity$1(info)], null))));
return content;
}));
lt.objs.eval.__BEH__underline_results = (function __BEH__underline_results(this$,res,loc,opts){var ed = new cljs.core.Keyword(null,"ed","ed",1013907473).cljs$core$IFn$_invoke$arity$1(cljs.core.deref.call(null,this$));var line = lt.objs.editor.line_handle.call(null,ed,new cljs.core.Keyword(null,"line","line",1017226086).cljs$core$IFn$_invoke$arity$1(loc));var res_obj = lt.object.create.call(null,new cljs.core.Keyword("lt.objs.eval","underline-result","lt.objs.eval/underline-result",1485297066),new cljs.core.PersistentArrayMap(null, 5, [new cljs.core.Keyword(null,"ed","ed",1013907473),this$,new cljs.core.Keyword(null,"opts","opts",1017322386),opts,new cljs.core.Keyword(null,"result","result",4374444943),res,new cljs.core.Keyword(null,"loc","loc",1014011570),loc,new cljs.core.Keyword(null,"line","line",1017226086),line], null));var temp__4092__auto___8651 = cljs.core.get.call(null,cljs.core.deref.call(null,this$).call(null,new cljs.core.Keyword(null,"widgets","widgets",2354242081)),new cljs.core.PersistentVector(null, 2, 5, cljs.core.PersistentVector.EMPTY_NODE, [line,new cljs.core.Keyword(null,"underline","underline",4281907774)], null));if(cljs.core.truth_(temp__4092__auto___8651))
{var prev_8652 = temp__4092__auto___8651;if(cljs.core.truth_(new cljs.core.Keyword(null,"open","open",1017321916).cljs$core$IFn$_invoke$arity$1(cljs.core.deref.call(null,prev_8652))))
{lt.object.merge_BANG_.call(null,res_obj,new cljs.core.PersistentArrayMap(null, 1, [new cljs.core.Keyword(null,"open","open",1017321916),true], null));
} else
{}
lt.object.raise.call(null,prev_8652,new cljs.core.Keyword(null,"clear!","clear!",3951036134));
} else
{}
if(cljs.core.truth_(new cljs.core.Keyword(null,"start-line","start-line",3689311729).cljs$core$IFn$_invoke$arity$1(loc)))
{var seq__8645_8653 = cljs.core.seq.call(null,cljs.core.map.call(null,(function (p1__8638_SHARP_){return cljs.core.get.call(null,cljs.core.deref.call(null,this$).call(null,new cljs.core.Keyword(null,"widgets","widgets",2354242081)),new cljs.core.PersistentVector(null, 2, 5, cljs.core.PersistentVector.EMPTY_NODE, [lt.objs.editor.line_handle.call(null,ed,p1__8638_SHARP_),new cljs.core.Keyword(null,"underline","underline",4281907774)], null));
}),cljs.core.range.call(null,new cljs.core.Keyword(null,"start-line","start-line",3689311729).cljs$core$IFn$_invoke$arity$1(loc),new cljs.core.Keyword(null,"line","line",1017226086).cljs$core$IFn$_invoke$arity$1(loc))));var chunk__8647_8654 = null;var count__8648_8655 = 0;var i__8649_8656 = 0;while(true){
if((i__8649_8656 < count__8648_8655))
{var widget_8657 = cljs.core._nth.call(null,chunk__8647_8654,i__8649_8656);if(cljs.core.truth_(widget_8657))
{lt.object.raise.call(null,widget_8657,new cljs.core.Keyword(null,"clear!","clear!",3951036134));
{
var G__8658 = seq__8645_8653;
var G__8659 = chunk__8647_8654;
var G__8660 = count__8648_8655;
var G__8661 = (i__8649_8656 + 1);
seq__8645_8653 = G__8658;
chunk__8647_8654 = G__8659;
count__8648_8655 = G__8660;
i__8649_8656 = G__8661;
continue;
}
} else
{{
var G__8662 = seq__8645_8653;
var G__8663 = chunk__8647_8654;
var G__8664 = count__8648_8655;
var G__8665 = (i__8649_8656 + 1);
seq__8645_8653 = G__8662;
chunk__8647_8654 = G__8663;
count__8648_8655 = G__8664;
i__8649_8656 = G__8665;
continue;
}
}
} else
{var temp__4092__auto___8666 = cljs.core.seq.call(null,seq__8645_8653);if(temp__4092__auto___8666)
{var seq__8645_8667__$1 = temp__4092__auto___8666;if(cljs.core.chunked_seq_QMARK_.call(null,seq__8645_8667__$1))
{var c__4262__auto___8668 = cljs.core.chunk_first.call(null,seq__8645_8667__$1);{
var G__8669 = cljs.core.chunk_rest.call(null,seq__8645_8667__$1);
var G__8670 = c__4262__auto___8668;
var G__8671 = cljs.core.count.call(null,c__4262__auto___8668);
var G__8672 = 0;
seq__8645_8653 = G__8669;
chunk__8647_8654 = G__8670;
count__8648_8655 = G__8671;
i__8649_8656 = G__8672;
continue;
}
} else
{var widget_8673 = cljs.core.first.call(null,seq__8645_8667__$1);if(cljs.core.truth_(widget_8673))
{lt.object.raise.call(null,widget_8673,new cljs.core.Keyword(null,"clear!","clear!",3951036134));
{
var G__8674 = cljs.core.next.call(null,seq__8645_8667__$1);
var G__8675 = null;
var G__8676 = 0;
var G__8677 = 0;
seq__8645_8653 = G__8674;
chunk__8647_8654 = G__8675;
count__8648_8655 = G__8676;
i__8649_8656 = G__8677;
continue;
}
} else
{{
var G__8678 = cljs.core.next.call(null,seq__8645_8667__$1);
var G__8679 = null;
var G__8680 = 0;
var G__8681 = 0;
seq__8645_8653 = G__8678;
chunk__8647_8654 = G__8679;
count__8648_8655 = G__8680;
i__8649_8656 = G__8681;
continue;
}
}
}
} else
{}
}
break;
}
} else
{}
return lt.object.update_BANG_.call(null,this$,new cljs.core.PersistentVector(null, 1, 5, cljs.core.PersistentVector.EMPTY_NODE, [new cljs.core.Keyword(null,"widgets","widgets",2354242081)], null),cljs.core.assoc,new cljs.core.PersistentVector(null, 2, 5, cljs.core.PersistentVector.EMPTY_NODE, [line,new cljs.core.Keyword(null,"underline","underline",4281907774)], null),res_obj);
});
lt.object.behavior_STAR_.call(null,new cljs.core.Keyword("lt.objs.eval","underline-results","lt.objs.eval/underline-results",4366201201),new cljs.core.Keyword(null,"reaction","reaction",4441361819),lt.objs.eval.__BEH__underline_results,new cljs.core.Keyword(null,"triggers","triggers",2516997421),new cljs.core.PersistentHashSet(null, new cljs.core.PersistentArrayMap(null, 1, [new cljs.core.Keyword(null,"editor.result.underline","editor.result.underline",541343758),null], null), null));
lt.objs.eval.__GT_exception_class = (function __GT_exception_class(this$){return [cljs.core.str("inline-exception "),cljs.core.str((cljs.core.truth_(new cljs.core.Keyword(null,"open","open",1017321916).cljs$core$IFn$_invoke$arity$1(this$))?"open":null))].join('');
});
lt.objs.eval.__GT_inline_exception = (function __GT_inline_exception(this$,info){var e__3325__auto__ = crate.core.html.call(null,new cljs.core.PersistentVector(null, 4, 5, cljs.core.PersistentVector.EMPTY_NODE, [new cljs.core.Keyword(null,"div","div",1014003715),new cljs.core.PersistentArrayMap(null, 1, [new cljs.core.Keyword(null,"class","class",1108647146),crate.binding.bound.call(null,this$,lt.objs.eval.__GT_exception_class)], null),new cljs.core.PersistentVector(null, 2, 5, cljs.core.PersistentVector.EMPTY_NODE, [new cljs.core.Keyword(null,"span.spacer","span.spacer",4763675330),lt.objs.eval.__GT_spacing.call(null,lt.objs.editor.line.call(null,new cljs.core.Keyword(null,"ed","ed",1013907473).cljs$core$IFn$_invoke$arity$1(info),new cljs.core.Keyword(null,"line","line",1017226086).cljs$core$IFn$_invoke$arity$1(new cljs.core.Keyword(null,"loc","loc",1014011570).cljs$core$IFn$_invoke$arity$1(info))))], null),new cljs.core.PersistentVector(null, 2, 5, cljs.core.PersistentVector.EMPTY_NODE, [new cljs.core.Keyword(null,"pre","pre",1014015509),[cljs.core.str(new cljs.core.Keyword(null,"ex","ex",1013907493).cljs$core$IFn$_invoke$arity$1(info))].join('')], null)], null));var seq__8688_8694 = cljs.core.seq.call(null,cljs.core.partition.call(null,2,new cljs.core.PersistentVector(null, 6, 5, cljs.core.PersistentVector.EMPTY_NODE, [new cljs.core.Keyword(null,"click","click",1108654330),(function (){return lt.object.raise.call(null,this$,new cljs.core.Keyword(null,"click","click",1108654330));
}),new cljs.core.Keyword(null,"contextmenu","contextmenu",911789824),(function (e){return lt.object.raise.call(null,this$,new cljs.core.Keyword(null,"menu!","menu!",1117686292),e);
}),new cljs.core.Keyword(null,"dblclick","dblclick",3463991820),(function (){return lt.object.raise.call(null,this$,new cljs.core.Keyword(null,"double-click","double-click",956590078));
})], null)));var chunk__8689_8695 = null;var count__8690_8696 = 0;var i__8691_8697 = 0;while(true){
if((i__8691_8697 < count__8690_8696))
{var vec__8692_8698 = cljs.core._nth.call(null,chunk__8689_8695,i__8691_8697);var ev__3326__auto___8699 = cljs.core.nth.call(null,vec__8692_8698,0,null);var func__3327__auto___8700 = cljs.core.nth.call(null,vec__8692_8698,1,null);lt.util.dom.on.call(null,e__3325__auto__,ev__3326__auto___8699,func__3327__auto___8700);
{
var G__8701 = seq__8688_8694;
var G__8702 = chunk__8689_8695;
var G__8703 = count__8690_8696;
var G__8704 = (i__8691_8697 + 1);
seq__8688_8694 = G__8701;
chunk__8689_8695 = G__8702;
count__8690_8696 = G__8703;
i__8691_8697 = G__8704;
continue;
}
} else
{var temp__4092__auto___8705 = cljs.core.seq.call(null,seq__8688_8694);if(temp__4092__auto___8705)
{var seq__8688_8706__$1 = temp__4092__auto___8705;if(cljs.core.chunked_seq_QMARK_.call(null,seq__8688_8706__$1))
{var c__4262__auto___8707 = cljs.core.chunk_first.call(null,seq__8688_8706__$1);{
var G__8708 = cljs.core.chunk_rest.call(null,seq__8688_8706__$1);
var G__8709 = c__4262__auto___8707;
var G__8710 = cljs.core.count.call(null,c__4262__auto___8707);
var G__8711 = 0;
seq__8688_8694 = G__8708;
chunk__8689_8695 = G__8709;
count__8690_8696 = G__8710;
i__8691_8697 = G__8711;
continue;
}
} else
{var vec__8693_8712 = cljs.core.first.call(null,seq__8688_8706__$1);var ev__3326__auto___8713 = cljs.core.nth.call(null,vec__8693_8712,0,null);var func__3327__auto___8714 = cljs.core.nth.call(null,vec__8693_8712,1,null);lt.util.dom.on.call(null,e__3325__auto__,ev__3326__auto___8713,func__3327__auto___8714);
{
var G__8715 = cljs.core.next.call(null,seq__8688_8706__$1);
var G__8716 = null;
var G__8717 = 0;
var G__8718 = 0;
seq__8688_8694 = G__8715;
chunk__8689_8695 = G__8716;
count__8690_8696 = G__8717;
i__8691_8697 = G__8718;
continue;
}
}
} else
{}
}
break;
}
return e__3325__auto__;
});
lt.objs.eval.__BEH__ex_shrink_on_double_click = (function __BEH__ex_shrink_on_double_click(this$){lt.objs.editor.focus.call(null,new cljs.core.Keyword(null,"ed","ed",1013907473).cljs$core$IFn$_invoke$arity$1(cljs.core.deref.call(null,this$)));
return lt.object.raise.call(null,this$,new cljs.core.Keyword(null,"clear!","clear!",3951036134));
});
lt.object.behavior_STAR_.call(null,new cljs.core.Keyword("lt.objs.eval","ex-shrink-on-double-click","lt.objs.eval/ex-shrink-on-double-click",626922428),new cljs.core.Keyword(null,"reaction","reaction",4441361819),lt.objs.eval.__BEH__ex_shrink_on_double_click,new cljs.core.Keyword(null,"triggers","triggers",2516997421),new cljs.core.PersistentHashSet(null, new cljs.core.PersistentArrayMap(null, 2, [new cljs.core.Keyword(null,"double-click","double-click",956590078),null,new cljs.core.Keyword(null,"shrink!","shrink!",3083562666),null], null), null));
lt.objs.eval.__BEH__ex_clear = (function __BEH__ex_clear(this$){if(cljs.core.truth_(lt.objs.editor.__GT_cm_ed.call(null,new cljs.core.Keyword(null,"ed","ed",1013907473).cljs$core$IFn$_invoke$arity$1(cljs.core.deref.call(null,this$)))))
{lt.objs.editor.remove_line_widget.call(null,lt.objs.editor.__GT_cm_ed.call(null,new cljs.core.Keyword(null,"ed","ed",1013907473).cljs$core$IFn$_invoke$arity$1(cljs.core.deref.call(null,this$))),new cljs.core.Keyword(null,"widget","widget",4520824246).cljs$core$IFn$_invoke$arity$1(cljs.core.deref.call(null,this$)));
} else
{}
lt.object.raise.call(null,this$,new cljs.core.Keyword(null,"clear","clear",1108650431));
return lt.object.raise.call(null,this$,new cljs.core.Keyword(null,"cleared","cleared",1870681886));
});
lt.object.behavior_STAR_.call(null,new cljs.core.Keyword("lt.objs.eval","ex-clear","lt.objs.eval/ex-clear",1010359327),new cljs.core.Keyword(null,"reaction","reaction",4441361819),lt.objs.eval.__BEH__ex_clear,new cljs.core.Keyword(null,"triggers","triggers",2516997421),new cljs.core.PersistentHashSet(null, new cljs.core.PersistentArrayMap(null, 1, [new cljs.core.Keyword(null,"clear!","clear!",3951036134),null], null), null));
lt.objs.eval.__BEH__ex_menu_PLUS_ = (function __BEH__ex_menu_PLUS_(this$,items){return cljs.core.conj.call(null,items,new cljs.core.PersistentArrayMap(null, 2, [new cljs.core.Keyword(null,"label","label",1116631654),"Remove exception",new cljs.core.Keyword(null,"click","click",1108654330),(function (){return lt.object.raise.call(null,this$,new cljs.core.Keyword(null,"clear!","clear!",3951036134));
})], null),new cljs.core.PersistentArrayMap(null, 2, [new cljs.core.Keyword(null,"label","label",1116631654),"Copy exception",new cljs.core.Keyword(null,"click","click",1108654330),(function (){return lt.object.raise.call(null,this$,new cljs.core.Keyword(null,"copy","copy",1016963815));
})], null));
});
lt.object.behavior_STAR_.call(null,new cljs.core.Keyword("lt.objs.eval","ex-menu+","lt.objs.eval/ex-menu+",1003388030),new cljs.core.Keyword(null,"reaction","reaction",4441361819),lt.objs.eval.__BEH__ex_menu_PLUS_,new cljs.core.Keyword(null,"triggers","triggers",2516997421),new cljs.core.PersistentHashSet(null, new cljs.core.PersistentArrayMap(null, 1, [new cljs.core.Keyword(null,"menu+","menu+",1117686302),null], null), null));
lt.objs.eval.__BEH__copy_exception = (function __BEH__copy_exception(this$){return lt.objs.platform.copy.call(null,new cljs.core.Keyword(null,"ex","ex",1013907493).cljs$core$IFn$_invoke$arity$1(cljs.core.deref.call(null,this$)));
});
lt.object.behavior_STAR_.call(null,new cljs.core.Keyword("lt.objs.eval","copy-exception","lt.objs.eval/copy-exception",3421301619),new cljs.core.Keyword(null,"reaction","reaction",4441361819),lt.objs.eval.__BEH__copy_exception,new cljs.core.Keyword(null,"triggers","triggers",2516997421),new cljs.core.PersistentHashSet(null, new cljs.core.PersistentArrayMap(null, 1, [new cljs.core.Keyword(null,"copy","copy",1016963815),null], null), null));
lt.object.object_STAR_.call(null,new cljs.core.Keyword("lt.objs.eval","inline-exception","lt.objs.eval/inline-exception",2990080407),new cljs.core.Keyword(null,"triggers","triggers",2516997421),new cljs.core.PersistentHashSet(null, new cljs.core.PersistentArrayMap(null, 3, [new cljs.core.Keyword(null,"double-click","double-click",956590078),null,new cljs.core.Keyword(null,"click","click",1108654330),null,new cljs.core.Keyword(null,"clear!","clear!",3951036134),null], null), null),new cljs.core.Keyword(null,"tags","tags",1017456523),new cljs.core.PersistentHashSet(null, new cljs.core.PersistentArrayMap(null, 2, [new cljs.core.Keyword(null,"inline.exception","inline.exception",3303739052),null,new cljs.core.Keyword(null,"inline","inline",4124874251),null], null), null),new cljs.core.Keyword(null,"init","init",1017141378),(function (this$,info){if(cljs.core.not.call(null,new cljs.core.Keyword(null,"line","line",1017226086).cljs$core$IFn$_invoke$arity$1(new cljs.core.Keyword(null,"loc","loc",1014011570).cljs$core$IFn$_invoke$arity$1(info))))
{return lt.objs.notifos.set_msg_BANG_.call(null,[cljs.core.str(new cljs.core.Keyword(null,"ex","ex",1013907493).cljs$core$IFn$_invoke$arity$1(info))].join(''),new cljs.core.PersistentArrayMap(null, 1, [new cljs.core.Keyword(null,"class","class",1108647146),"error"], null));
} else
{var content = lt.objs.eval.__GT_inline_exception.call(null,this$,info);lt.object.merge_BANG_.call(null,this$,cljs.core.assoc.call(null,info,new cljs.core.Keyword(null,"widget","widget",4520824246),lt.objs.editor.line_widget.call(null,lt.objs.editor.__GT_cm_ed.call(null,new cljs.core.Keyword(null,"ed","ed",1013907473).cljs$core$IFn$_invoke$arity$1(info)),new cljs.core.Keyword(null,"line","line",1017226086).cljs$core$IFn$_invoke$arity$1(new cljs.core.Keyword(null,"loc","loc",1014011570).cljs$core$IFn$_invoke$arity$1(info)),content,new cljs.core.PersistentArrayMap(null, 1, [new cljs.core.Keyword(null,"coverGutter","coverGutter",510635812),false], null))));
return content;
}
}));
lt.objs.eval.__BEH__inline_exceptions = (function __BEH__inline_exceptions(this$,ex,loc){if(cljs.core.truth_((function (){var and__3508__auto__ = ex;if(cljs.core.truth_(and__3508__auto__))
{var and__3508__auto____$1 = loc;if(cljs.core.truth_(and__3508__auto____$1))
{return (new cljs.core.Keyword(null,"line","line",1017226086).cljs$core$IFn$_invoke$arity$1(loc) >= 0);
} else
{return and__3508__auto____$1;
}
} else
{return and__3508__auto__;
}
})()))
{var ed = new cljs.core.Keyword(null,"ed","ed",1013907473).cljs$core$IFn$_invoke$arity$1(cljs.core.deref.call(null,this$));var line = lt.objs.editor.line_handle.call(null,ed,new cljs.core.Keyword(null,"line","line",1017226086).cljs$core$IFn$_invoke$arity$1(loc));var ex_obj = lt.object.create.call(null,new cljs.core.Keyword("lt.objs.eval","inline-exception","lt.objs.eval/inline-exception",2990080407),new cljs.core.PersistentArrayMap(null, 4, [new cljs.core.Keyword(null,"ed","ed",1013907473),this$,new cljs.core.Keyword(null,"ex","ex",1013907493),ex,new cljs.core.Keyword(null,"loc","loc",1014011570),loc,new cljs.core.Keyword(null,"line","line",1017226086),line], null));var seq__8742_8764 = cljs.core.seq.call(null,new cljs.core.PersistentVector(null, 2, 5, cljs.core.PersistentVector.EMPTY_NODE, [cljs.core.get.call(null,cljs.core.deref.call(null,this$).call(null,new cljs.core.Keyword(null,"widgets","widgets",2354242081)),new cljs.core.PersistentVector(null, 2, 5, cljs.core.PersistentVector.EMPTY_NODE, [line,new cljs.core.Keyword(null,"inline","inline",4124874251)], null)),cljs.core.get.call(null,cljs.core.deref.call(null,this$).call(null,new cljs.core.Keyword(null,"widgets","widgets",2354242081)),new cljs.core.PersistentVector(null, 2, 5, cljs.core.PersistentVector.EMPTY_NODE, [line,new cljs.core.Keyword(null,"underline","underline",4281907774)], null))], null));var chunk__8744_8765 = null;var count__8745_8766 = 0;var i__8746_8767 = 0;while(true){
if((i__8746_8767 < count__8745_8766))
{var prev_8768 = cljs.core._nth.call(null,chunk__8744_8765,i__8746_8767);if(cljs.core.truth_(prev_8768))
{if(cljs.core.truth_(new cljs.core.Keyword(null,"open","open",1017321916).cljs$core$IFn$_invoke$arity$1(cljs.core.deref.call(null,prev_8768))))
{lt.object.merge_BANG_.call(null,ex_obj,new cljs.core.PersistentArrayMap(null, 1, [new cljs.core.Keyword(null,"open","open",1017321916),true], null));
} else
{}
lt.object.raise.call(null,prev_8768,new cljs.core.Keyword(null,"clear!","clear!",3951036134));
{
var G__8769 = seq__8742_8764;
var G__8770 = chunk__8744_8765;
var G__8771 = count__8745_8766;
var G__8772 = (i__8746_8767 + 1);
seq__8742_8764 = G__8769;
chunk__8744_8765 = G__8770;
count__8745_8766 = G__8771;
i__8746_8767 = G__8772;
continue;
}
} else
{{
var G__8773 = seq__8742_8764;
var G__8774 = chunk__8744_8765;
var G__8775 = count__8745_8766;
var G__8776 = (i__8746_8767 + 1);
seq__8742_8764 = G__8773;
chunk__8744_8765 = G__8774;
count__8745_8766 = G__8775;
i__8746_8767 = G__8776;
continue;
}
}
} else
{var temp__4092__auto___8777 = cljs.core.seq.call(null,seq__8742_8764);if(temp__4092__auto___8777)
{var seq__8742_8778__$1 = temp__4092__auto___8777;if(cljs.core.chunked_seq_QMARK_.call(null,seq__8742_8778__$1))
{var c__4262__auto___8779 = cljs.core.chunk_first.call(null,seq__8742_8778__$1);{
var G__8780 = cljs.core.chunk_rest.call(null,seq__8742_8778__$1);
var G__8781 = c__4262__auto___8779;
var G__8782 = cljs.core.count.call(null,c__4262__auto___8779);
var G__8783 = 0;
seq__8742_8764 = G__8780;
chunk__8744_8765 = G__8781;
count__8745_8766 = G__8782;
i__8746_8767 = G__8783;
continue;
}
} else
{var prev_8784 = cljs.core.first.call(null,seq__8742_8778__$1);if(cljs.core.truth_(prev_8784))
{if(cljs.core.truth_(new cljs.core.Keyword(null,"open","open",1017321916).cljs$core$IFn$_invoke$arity$1(cljs.core.deref.call(null,prev_8784))))
{lt.object.merge_BANG_.call(null,ex_obj,new cljs.core.PersistentArrayMap(null, 1, [new cljs.core.Keyword(null,"open","open",1017321916),true], null));
} else
{}
lt.object.raise.call(null,prev_8784,new cljs.core.Keyword(null,"clear!","clear!",3951036134));
{
var G__8785 = cljs.core.next.call(null,seq__8742_8778__$1);
var G__8786 = null;
var G__8787 = 0;
var G__8788 = 0;
seq__8742_8764 = G__8785;
chunk__8744_8765 = G__8786;
count__8745_8766 = G__8787;
i__8746_8767 = G__8788;
continue;
}
} else
{{
var G__8789 = cljs.core.next.call(null,seq__8742_8778__$1);
var G__8790 = null;
var G__8791 = 0;
var G__8792 = 0;
seq__8742_8764 = G__8789;
chunk__8744_8765 = G__8790;
count__8745_8766 = G__8791;
i__8746_8767 = G__8792;
continue;
}
}
}
} else
{}
}
break;
}
if(cljs.core.truth_(new cljs.core.Keyword(null,"start-line","start-line",3689311729).cljs$core$IFn$_invoke$arity$1(loc)))
{var seq__8748_8793 = cljs.core.seq.call(null,new cljs.core.PersistentVector(null, 2, 5, cljs.core.PersistentVector.EMPTY_NODE, [new cljs.core.Keyword(null,"inline","inline",4124874251),new cljs.core.Keyword(null,"underline","underline",4281907774)], null));var chunk__8755_8794 = null;var count__8756_8795 = 0;var i__8757_8796 = 0;while(true){
if((i__8757_8796 < count__8756_8795))
{var type_8797 = cljs.core._nth.call(null,chunk__8755_8794,i__8757_8796);var seq__8758_8798 = cljs.core.seq.call(null,cljs.core.map.call(null,((function (seq__8748_8793,chunk__8755_8794,count__8756_8795,i__8757_8796,type_8797){
return (function (p1__8719_SHARP_){return cljs.core.get.call(null,cljs.core.deref.call(null,this$).call(null,new cljs.core.Keyword(null,"widgets","widgets",2354242081)),new cljs.core.PersistentVector(null, 2, 5, cljs.core.PersistentVector.EMPTY_NODE, [lt.objs.editor.line_handle.call(null,ed,p1__8719_SHARP_),type_8797], null));
});})(seq__8748_8793,chunk__8755_8794,count__8756_8795,i__8757_8796,type_8797))
,cljs.core.range.call(null,new cljs.core.Keyword(null,"start-line","start-line",3689311729).cljs$core$IFn$_invoke$arity$1(loc),new cljs.core.Keyword(null,"line","line",1017226086).cljs$core$IFn$_invoke$arity$1(loc))));var chunk__8760_8799 = null;var count__8761_8800 = 0;var i__8762_8801 = 0;while(true){
if((i__8762_8801 < count__8761_8800))
{var widget_8802 = cljs.core._nth.call(null,chunk__8760_8799,i__8762_8801);if(cljs.core.truth_(widget_8802))
{lt.object.raise.call(null,widget_8802,new cljs.core.Keyword(null,"clear!","clear!",3951036134));
{
var G__8803 = seq__8758_8798;
var G__8804 = chunk__8760_8799;
var G__8805 = count__8761_8800;
var G__8806 = (i__8762_8801 + 1);
seq__8758_8798 = G__8803;
chunk__8760_8799 = G__8804;
count__8761_8800 = G__8805;
i__8762_8801 = G__8806;
continue;
}
} else
{{
var G__8807 = seq__8758_8798;
var G__8808 = chunk__8760_8799;
var G__8809 = count__8761_8800;
var G__8810 = (i__8762_8801 + 1);
seq__8758_8798 = G__8807;
chunk__8760_8799 = G__8808;
count__8761_8800 = G__8809;
i__8762_8801 = G__8810;
continue;
}
}
} else
{var temp__4092__auto___8811 = cljs.core.seq.call(null,seq__8758_8798);if(temp__4092__auto___8811)
{var seq__8758_8812__$1 = temp__4092__auto___8811;if(cljs.core.chunked_seq_QMARK_.call(null,seq__8758_8812__$1))
{var c__4262__auto___8813 = cljs.core.chunk_first.call(null,seq__8758_8812__$1);{
var G__8814 = cljs.core.chunk_rest.call(null,seq__8758_8812__$1);
var G__8815 = c__4262__auto___8813;
var G__8816 = cljs.core.count.call(null,c__4262__auto___8813);
var G__8817 = 0;
seq__8758_8798 = G__8814;
chunk__8760_8799 = G__8815;
count__8761_8800 = G__8816;
i__8762_8801 = G__8817;
continue;
}
} else
{var widget_8818 = cljs.core.first.call(null,seq__8758_8812__$1);if(cljs.core.truth_(widget_8818))
{lt.object.raise.call(null,widget_8818,new cljs.core.Keyword(null,"clear!","clear!",3951036134));
{
var G__8819 = cljs.core.next.call(null,seq__8758_8812__$1);
var G__8820 = null;
var G__8821 = 0;
var G__8822 = 0;
seq__8758_8798 = G__8819;
chunk__8760_8799 = G__8820;
count__8761_8800 = G__8821;
i__8762_8801 = G__8822;
continue;
}
} else
{{
var G__8823 = cljs.core.next.call(null,seq__8758_8812__$1);
var G__8824 = null;
var G__8825 = 0;
var G__8826 = 0;
seq__8758_8798 = G__8823;
chunk__8760_8799 = G__8824;
count__8761_8800 = G__8825;
i__8762_8801 = G__8826;
continue;
}
}
}
} else
{}
}
break;
}
{
var G__8827 = seq__8748_8793;
var G__8828 = chunk__8755_8794;
var G__8829 = count__8756_8795;
var G__8830 = (i__8757_8796 + 1);
seq__8748_8793 = G__8827;
chunk__8755_8794 = G__8828;
count__8756_8795 = G__8829;
i__8757_8796 = G__8830;
continue;
}
} else
{var temp__4092__auto___8831 = cljs.core.seq.call(null,seq__8748_8793);if(temp__4092__auto___8831)
{var seq__8748_8832__$1 = temp__4092__auto___8831;if(cljs.core.chunked_seq_QMARK_.call(null,seq__8748_8832__$1))
{var c__4262__auto___8833 = cljs.core.chunk_first.call(null,seq__8748_8832__$1);{
var G__8834 = cljs.core.chunk_rest.call(null,seq__8748_8832__$1);
var G__8835 = c__4262__auto___8833;
var G__8836 = cljs.core.count.call(null,c__4262__auto___8833);
var G__8837 = 0;
seq__8748_8793 = G__8834;
chunk__8755_8794 = G__8835;
count__8756_8795 = G__8836;
i__8757_8796 = G__8837;
continue;
}
} else
{var type_8838 = cljs.core.first.call(null,seq__8748_8832__$1);var seq__8749_8839 = cljs.core.seq.call(null,cljs.core.map.call(null,((function (seq__8748_8793,chunk__8755_8794,count__8756_8795,i__8757_8796,type_8838,seq__8748_8832__$1,temp__4092__auto___8831){
return (function (p1__8719_SHARP_){return cljs.core.get.call(null,cljs.core.deref.call(null,this$).call(null,new cljs.core.Keyword(null,"widgets","widgets",2354242081)),new cljs.core.PersistentVector(null, 2, 5, cljs.core.PersistentVector.EMPTY_NODE, [lt.objs.editor.line_handle.call(null,ed,p1__8719_SHARP_),type_8838], null));
});})(seq__8748_8793,chunk__8755_8794,count__8756_8795,i__8757_8796,type_8838,seq__8748_8832__$1,temp__4092__auto___8831))
,cljs.core.range.call(null,new cljs.core.Keyword(null,"start-line","start-line",3689311729).cljs$core$IFn$_invoke$arity$1(loc),new cljs.core.Keyword(null,"line","line",1017226086).cljs$core$IFn$_invoke$arity$1(loc))));var chunk__8751_8840 = null;var count__8752_8841 = 0;var i__8753_8842 = 0;while(true){
if((i__8753_8842 < count__8752_8841))
{var widget_8843 = cljs.core._nth.call(null,chunk__8751_8840,i__8753_8842);if(cljs.core.truth_(widget_8843))
{lt.object.raise.call(null,widget_8843,new cljs.core.Keyword(null,"clear!","clear!",3951036134));
{
var G__8844 = seq__8749_8839;
var G__8845 = chunk__8751_8840;
var G__8846 = count__8752_8841;
var G__8847 = (i__8753_8842 + 1);
seq__8749_8839 = G__8844;
chunk__8751_8840 = G__8845;
count__8752_8841 = G__8846;
i__8753_8842 = G__8847;
continue;
}
} else
{{
var G__8848 = seq__8749_8839;
var G__8849 = chunk__8751_8840;
var G__8850 = count__8752_8841;
var G__8851 = (i__8753_8842 + 1);
seq__8749_8839 = G__8848;
chunk__8751_8840 = G__8849;
count__8752_8841 = G__8850;
i__8753_8842 = G__8851;
continue;
}
}
} else
{var temp__4092__auto___8852__$1 = cljs.core.seq.call(null,seq__8749_8839);if(temp__4092__auto___8852__$1)
{var seq__8749_8853__$1 = temp__4092__auto___8852__$1;if(cljs.core.chunked_seq_QMARK_.call(null,seq__8749_8853__$1))
{var c__4262__auto___8854 = cljs.core.chunk_first.call(null,seq__8749_8853__$1);{
var G__8855 = cljs.core.chunk_rest.call(null,seq__8749_8853__$1);
var G__8856 = c__4262__auto___8854;
var G__8857 = cljs.core.count.call(null,c__4262__auto___8854);
var G__8858 = 0;
seq__8749_8839 = G__8855;
chunk__8751_8840 = G__8856;
count__8752_8841 = G__8857;
i__8753_8842 = G__8858;
continue;
}
} else
{var widget_8859 = cljs.core.first.call(null,seq__8749_8853__$1);if(cljs.core.truth_(widget_8859))
{lt.object.raise.call(null,widget_8859,new cljs.core.Keyword(null,"clear!","clear!",3951036134));
{
var G__8860 = cljs.core.next.call(null,seq__8749_8853__$1);
var G__8861 = null;
var G__8862 = 0;
var G__8863 = 0;
seq__8749_8839 = G__8860;
chunk__8751_8840 = G__8861;
count__8752_8841 = G__8862;
i__8753_8842 = G__8863;
continue;
}
} else
{{
var G__8864 = cljs.core.next.call(null,seq__8749_8853__$1);
var G__8865 = null;
var G__8866 = 0;
var G__8867 = 0;
seq__8749_8839 = G__8864;
chunk__8751_8840 = G__8865;
count__8752_8841 = G__8866;
i__8753_8842 = G__8867;
continue;
}
}
}
} else
{}
}
break;
}
{
var G__8868 = cljs.core.next.call(null,seq__8748_8832__$1);
var G__8869 = null;
var G__8870 = 0;
var G__8871 = 0;
seq__8748_8793 = G__8868;
chunk__8755_8794 = G__8869;
count__8756_8795 = G__8870;
i__8757_8796 = G__8871;
continue;
}
}
} else
{}
}
break;
}
} else
{}
return lt.object.update_BANG_.call(null,this$,new cljs.core.PersistentVector(null, 1, 5, cljs.core.PersistentVector.EMPTY_NODE, [new cljs.core.Keyword(null,"widgets","widgets",2354242081)], null),cljs.core.assoc,new cljs.core.PersistentVector(null, 2, 5, cljs.core.PersistentVector.EMPTY_NODE, [line,new cljs.core.Keyword(null,"inline","inline",4124874251)], null),ex_obj);
} else
{return null;
}
});
lt.object.behavior_STAR_.call(null,new cljs.core.Keyword("lt.objs.eval","inline-exceptions","lt.objs.eval/inline-exceptions",2489921844),new cljs.core.Keyword(null,"reaction","reaction",4441361819),lt.objs.eval.__BEH__inline_exceptions,new cljs.core.Keyword(null,"triggers","triggers",2516997421),new cljs.core.PersistentHashSet(null, new cljs.core.PersistentArrayMap(null, 1, [new cljs.core.Keyword(null,"editor.exception","editor.exception",3983021184),null], null), null));
lt.objs.eval.__BEH__eval_on_change = (function __BEH__eval_on_change(this$){return lt.object.raise.call(null,this$,new cljs.core.Keyword(null,"eval","eval",1017029646));
});
lt.object.behavior_STAR_.call(null,new cljs.core.Keyword("lt.objs.eval","eval-on-change","lt.objs.eval/eval-on-change",2788474585),new cljs.core.Keyword(null,"reaction","reaction",4441361819),lt.objs.eval.__BEH__eval_on_change,new cljs.core.Keyword(null,"desc","desc",1016984067),"Editor: Eval when the editor changes",new cljs.core.Keyword(null,"triggers","triggers",2516997421),new cljs.core.PersistentHashSet(null, new cljs.core.PersistentArrayMap(null, 1, [new cljs.core.Keyword(null,"change","change",3947235106),null], null), null),new cljs.core.Keyword(null,"type","type",1017479852),new cljs.core.Keyword(null,"user","user",1017503549),new cljs.core.Keyword(null,"debounce","debounce",1556599227),300);
lt.objs.sidebar.command.command.call(null,new cljs.core.PersistentArrayMap(null, 3, [new cljs.core.Keyword(null,"command","command",1964298941),new cljs.core.Keyword(null,"clear-inline-results","clear-inline-results",1542062004),new cljs.core.Keyword(null,"desc","desc",1016984067),"Eval: Clear inline results",new cljs.core.Keyword(null,"exec","exec",1017031683),(function (){var temp__4092__auto__ = lt.objs.editor.pool.last_active.call(null);if(cljs.core.truth_(temp__4092__auto__))
{var ed = temp__4092__auto__;var seq__8872 = cljs.core.seq.call(null,new cljs.core.Keyword(null,"widgets","widgets",2354242081).cljs$core$IFn$_invoke$arity$1(cljs.core.deref.call(null,ed)));var chunk__8873 = null;var count__8874 = 0;var i__8875 = 0;while(true){
if((i__8875 < count__8874))
{var vec__8876 = cljs.core._nth.call(null,chunk__8873,i__8875);var _ = cljs.core.nth.call(null,vec__8876,0,null);var w = cljs.core.nth.call(null,vec__8876,1,null);lt.object.raise.call(null,w,new cljs.core.Keyword(null,"clear!","clear!",3951036134));
{
var G__8878 = seq__8872;
var G__8879 = chunk__8873;
var G__8880 = count__8874;
var G__8881 = (i__8875 + 1);
seq__8872 = G__8878;
chunk__8873 = G__8879;
count__8874 = G__8880;
i__8875 = G__8881;
continue;
}
} else
{var temp__4092__auto____$1 = cljs.core.seq.call(null,seq__8872);if(temp__4092__auto____$1)
{var seq__8872__$1 = temp__4092__auto____$1;if(cljs.core.chunked_seq_QMARK_.call(null,seq__8872__$1))
{var c__4262__auto__ = cljs.core.chunk_first.call(null,seq__8872__$1);{
var G__8882 = cljs.core.chunk_rest.call(null,seq__8872__$1);
var G__8883 = c__4262__auto__;
var G__8884 = cljs.core.count.call(null,c__4262__auto__);
var G__8885 = 0;
seq__8872 = G__8882;
chunk__8873 = G__8883;
count__8874 = G__8884;
i__8875 = G__8885;
continue;
}
} else
{var vec__8877 = cljs.core.first.call(null,seq__8872__$1);var _ = cljs.core.nth.call(null,vec__8877,0,null);var w = cljs.core.nth.call(null,vec__8877,1,null);lt.object.raise.call(null,w,new cljs.core.Keyword(null,"clear!","clear!",3951036134));
{
var G__8886 = cljs.core.next.call(null,seq__8872__$1);
var G__8887 = null;
var G__8888 = 0;
var G__8889 = 0;
seq__8872 = G__8886;
chunk__8873 = G__8887;
count__8874 = G__8888;
i__8875 = G__8889;
continue;
}
}
} else
{return null;
}
}
break;
}
} else
{return null;
}
})], null));
lt.objs.sidebar.command.command.call(null,new cljs.core.PersistentArrayMap(null, 3, [new cljs.core.Keyword(null,"command","command",1964298941),new cljs.core.Keyword(null,"eval-editor","eval-editor",2482317104),new cljs.core.Keyword(null,"desc","desc",1016984067),"Eval: Eval editor contents",new cljs.core.Keyword(null,"exec","exec",1017031683),(function (){var temp__4092__auto__ = lt.objs.editor.pool.last_active.call(null);if(cljs.core.truth_(temp__4092__auto__))
{var ed = temp__4092__auto__;return lt.object.raise.call(null,ed,new cljs.core.Keyword(null,"eval","eval",1017029646));
} else
{return null;
}
})], null));
lt.objs.sidebar.command.command.call(null,new cljs.core.PersistentArrayMap(null, 3, [new cljs.core.Keyword(null,"command","command",1964298941),new cljs.core.Keyword(null,"eval-editor-form","eval-editor-form",4138964197),new cljs.core.Keyword(null,"desc","desc",1016984067),"Eval: Eval a form in editor",new cljs.core.Keyword(null,"exec","exec",1017031683),(function (){var temp__4092__auto__ = lt.objs.editor.pool.last_active.call(null);if(cljs.core.truth_(temp__4092__auto__))
{var ed = temp__4092__auto__;return lt.object.raise.call(null,ed,new cljs.core.Keyword(null,"eval.one","eval.one",1173589382));
} else
{return null;
}
})], null));
lt.objs.sidebar.command.command.call(null,new cljs.core.PersistentArrayMap(null, 4, [new cljs.core.Keyword(null,"command","command",1964298941),new cljs.core.Keyword(null,"eval.custom","eval.custom",3328560245),new cljs.core.Keyword(null,"desc","desc",1016984067),"Eval: Eval custom expression in editor",new cljs.core.Keyword(null,"hidden","hidden",4091384092),true,new cljs.core.Keyword(null,"exec","exec",1017031683),(function (exp,opts){var temp__4092__auto__ = lt.objs.editor.pool.last_active.call(null);if(cljs.core.truth_(temp__4092__auto__))
{var ed = temp__4092__auto__;return lt.object.raise.call(null,ed,new cljs.core.Keyword(null,"eval.custom","eval.custom",3328560245),exp,opts);
} else
{return null;
}
})], null));
lt.objs.sidebar.command.command.call(null,new cljs.core.PersistentArrayMap(null, 3, [new cljs.core.Keyword(null,"command","command",1964298941),new cljs.core.Keyword(null,"eval.cancel-all!","eval.cancel-all!",3689151283),new cljs.core.Keyword(null,"desc","desc",1016984067),"Eval: Cancel evaluation for the current client",new cljs.core.Keyword(null,"exec","exec",1017031683),(function (){var temp__4092__auto__ = lt.objs.editor.pool.last_active.call(null);if(cljs.core.truth_(temp__4092__auto__))
{var ed = temp__4092__auto__;if(cljs.core.truth_(new cljs.core.Keyword(null,"client","client",3951159101).cljs$core$IFn$_invoke$arity$1(cljs.core.deref.call(null,ed))))
{var seq__8890 = cljs.core.seq.call(null,new cljs.core.Keyword(null,"client","client",3951159101).cljs$core$IFn$_invoke$arity$1(cljs.core.deref.call(null,ed)));var chunk__8891 = null;var count__8892 = 0;var i__8893 = 0;while(true){
if((i__8893 < count__8892))
{var vec__8894 = cljs.core._nth.call(null,chunk__8891,i__8893);var _ = cljs.core.nth.call(null,vec__8894,0,null);var client = cljs.core.nth.call(null,vec__8894,1,null);lt.objs.clients.cancel_all_BANG_.call(null,client);
{
var G__8896 = seq__8890;
var G__8897 = chunk__8891;
var G__8898 = count__8892;
var G__8899 = (i__8893 + 1);
seq__8890 = G__8896;
chunk__8891 = G__8897;
count__8892 = G__8898;
i__8893 = G__8899;
continue;
}
} else
{var temp__4092__auto____$1 = cljs.core.seq.call(null,seq__8890);if(temp__4092__auto____$1)
{var seq__8890__$1 = temp__4092__auto____$1;if(cljs.core.chunked_seq_QMARK_.call(null,seq__8890__$1))
{var c__4262__auto__ = cljs.core.chunk_first.call(null,seq__8890__$1);{
var G__8900 = cljs.core.chunk_rest.call(null,seq__8890__$1);
var G__8901 = c__4262__auto__;
var G__8902 = cljs.core.count.call(null,c__4262__auto__);
var G__8903 = 0;
seq__8890 = G__8900;
chunk__8891 = G__8901;
count__8892 = G__8902;
i__8893 = G__8903;
continue;
}
} else
{var vec__8895 = cljs.core.first.call(null,seq__8890__$1);var _ = cljs.core.nth.call(null,vec__8895,0,null);var client = cljs.core.nth.call(null,vec__8895,1,null);lt.objs.clients.cancel_all_BANG_.call(null,client);
{
var G__8904 = cljs.core.next.call(null,seq__8890__$1);
var G__8905 = null;
var G__8906 = 0;
var G__8907 = 0;
seq__8890 = G__8904;
chunk__8891 = G__8905;
count__8892 = G__8906;
i__8893 = G__8907;
continue;
}
}
} else
{return null;
}
}
break;
}
} else
{return null;
}
} else
{return null;
}
})], null));
lt.objs.sidebar.command.command.call(null,new cljs.core.PersistentArrayMap(null, 3, [new cljs.core.Keyword(null,"command","command",1964298941),new cljs.core.Keyword(null,"editor.disconnect-clients","editor.disconnect-clients",1348759402),new cljs.core.Keyword(null,"desc","desc",1016984067),"Editor: Disconnect clients attached to editor",new cljs.core.Keyword(null,"exec","exec",1017031683),(function (){var temp__4092__auto__ = lt.objs.editor.pool.last_active.call(null);if(cljs.core.truth_(temp__4092__auto__))
{var ed = temp__4092__auto__;var seq__8908 = cljs.core.seq.call(null,cljs.core.vals.call(null,new cljs.core.Keyword(null,"client","client",3951159101).cljs$core$IFn$_invoke$arity$1(cljs.core.deref.call(null,ed))));var chunk__8909 = null;var count__8910 = 0;var i__8911 = 0;while(true){
if((i__8911 < count__8910))
{var client = cljs.core._nth.call(null,chunk__8909,i__8911);lt.objs.clients.close_BANG_.call(null,client);
{
var G__8912 = seq__8908;
var G__8913 = chunk__8909;
var G__8914 = count__8910;
var G__8915 = (i__8911 + 1);
seq__8908 = G__8912;
chunk__8909 = G__8913;
count__8910 = G__8914;
i__8911 = G__8915;
continue;
}
} else
{var temp__4092__auto____$1 = cljs.core.seq.call(null,seq__8908);if(temp__4092__auto____$1)
{var seq__8908__$1 = temp__4092__auto____$1;if(cljs.core.chunked_seq_QMARK_.call(null,seq__8908__$1))
{var c__4262__auto__ = cljs.core.chunk_first.call(null,seq__8908__$1);{
var G__8916 = cljs.core.chunk_rest.call(null,seq__8908__$1);
var G__8917 = c__4262__auto__;
var G__8918 = cljs.core.count.call(null,c__4262__auto__);
var G__8919 = 0;
seq__8908 = G__8916;
chunk__8909 = G__8917;
count__8910 = G__8918;
i__8911 = G__8919;
continue;
}
} else
{var client = cljs.core.first.call(null,seq__8908__$1);lt.objs.clients.close_BANG_.call(null,client);
{
var G__8920 = cljs.core.next.call(null,seq__8908__$1);
var G__8921 = null;
var G__8922 = 0;
var G__8923 = 0;
seq__8908 = G__8920;
chunk__8909 = G__8921;
count__8910 = G__8922;
i__8911 = G__8923;
continue;
}
}
} else
{return null;
}
}
break;
}
} else
{return null;
}
})], null));
