X-Git-Url: http://git.bytex64.net/?a=blobdiff_plain;f=www%2Fjssrc%2Fblerg%2FBlerg.js;h=4a951140810b036ceb47f42beccb22b1b394a124;hb=476c970903c4f3d29a8da3fa7c6f6f237745a8b7;hp=6eac0d89b61b63a63d6953a4b842067bfd05a9e9;hpb=4377f9e224f34c05e7a5de04f390bb2a0cabf6eb;p=blerg.git diff --git a/www/jssrc/blerg/Blerg.js b/www/jssrc/blerg/Blerg.js index 6eac0d8..4a95114 100644 --- a/www/jssrc/blerg/Blerg.js +++ b/www/jssrc/blerg/Blerg.js @@ -1,21 +1,26 @@ +// Listen for onsubmit events +enyo.dispatcher.listen(document, "submit"); + enyo.kind({ name: "blerg.Blerg", kind: "Control", lastHash: null, - pathHandlers: [ blerg.User, blerg.Tag, blerg.Feed, blerg.ExternalURLPost, blerg.Welcome ], + pathHandlers: [ blerg.User, blerg.Tag, blerg.Feed, blerg.ExternalURLPost, blerg.Welcome, blerg.AccountCenter, blerg.Recovery ], handlers: { onStartSignup: "showSignupDialog", onTryLogin: "tryLogin", onTryLogout: "tryLogout", onSetTitle: "setTitle", onPostVisibility: "postVisibilityUpdate", - onReload: "sendReload" + onReload: "sendReload", + onShowChangePassword: "showChangePassword", + onAuthFailure: "authFailure" }, 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"} ]}, @@ -92,5 +97,11 @@ enyo.kind({ }, sendReload: function() { this.$.main.waterfall('onReload'); + }, + showChangePassword: function() { + this.$.passwdDialog.show(); + }, + authFailure: function(inSender, inEvent) { + this.logout(); } });