X-Git-Url: http://git.bytex64.net/?a=blobdiff_plain;f=www%2Fjssrc%2Fblerg%2FBlerg.js;h=22bfddbd0f772c98c58316852c6d03401122a1f9;hb=3e5f69d01b9488475413d4ecce8161ab7a889ca2;hp=af0f688461a381b5288bd200c94a74f9ec44bb03;hpb=f5eba55960cba26d820f88144776f7177db92c0b;p=blerg.git diff --git a/www/jssrc/blerg/Blerg.js b/www/jssrc/blerg/Blerg.js index af0f688..22bfddb 100644 --- a/www/jssrc/blerg/Blerg.js +++ b/www/jssrc/blerg/Blerg.js @@ -8,13 +8,14 @@ enyo.kind({ onTryLogin: "tryLogin", onTryLogout: "tryLogout", onSetTitle: "setTitle", - onPostVisibility: "postVisibilityUpdate" + onPostVisibility: "postVisibilityUpdate", + onReload: "sendReload" }, components: [ {classes: "blerg-header", components: [ {name: "title", kind: "blerg.Title"}, {name: "controls", kind: "blerg.Controls"}, - {style: "clear: both"}, + {style: "clear: both;"}, {name: "post", kind: "blerg.Post", showing: false}, {name: "help", kind: "blerg.Help"} ]}, @@ -36,10 +37,10 @@ enyo.kind({ document.body.addEventListener('keyup', function(event) { if (event.shiftKey && event.keyCode == 32) { - this.$.post.show(); + this.waterfall('onPostVisibility', {showing: true}); event.stopPropagation(); } - }, false); + }.bind(this), false); }, hashCheck: function() { if (location.hash != this.lastHash) { @@ -88,5 +89,8 @@ enyo.kind({ postVisibilityUpdate: function(inSender, inEvent) { this.$.post.waterfall('onPostVisibility', inEvent); this.$.controls.waterfall('onPostVisibility', inEvent); + }, + sendReload: function() { + this.$.main.waterfall('onReload'); } });