2 name: "blerg.Controls",
5 classes: "blerg-controls",
10 {name: "loggedOutControls", components: [
11 {tag: "form", onsubmit: "doLogin", classes: "login", components: [
12 {kind: "onyx.Groupbox", components: [
13 {kind: "onyx.InputDecorator", components: [
14 {name: "username", kind: "onyx.Input", placeholder: "Username"}
16 {kind: "onyx.InputDecorator", components: [
17 {name: "password", kind: "onyx.Input", placeholder: "Password", type: "password"}
20 {kind: "onyx.Button", content: "Login", onclick: "doLogin"}
23 {name: "loggedInControls", showing: false, components: [
25 {kind: "onyx.Toolbar", components: [
26 {kind: "onyx.Button", content: "Write", onClick: "writeClicked"},
27 {kind: "onyx.Button", content: "Hearsay", onClick: "chatterClicked"},
28 {kind: "onyx.Button", content: "Stalking", onClick: "feedClicked"}
31 {name: "rssButton", showing: false, kind: "blerg.Link", components: [
32 {kind: "Image", src: "/images/rss.png", width: 16, height: 16},
33 {noDom: true, content: " RSS"}
38 showRSS: function(url) {
39 this.$.rssButton.show();
41 this.$.rssButton.setAttribute('href', url);
44 this.$.rssButton.hide();
46 loggedInChanged: function() {
48 this.$.loggedOutControls.hide();
49 this.$.loggedInControls.show();
51 this.$.loggedOutControls.show();
52 this.$.loggedInControls.hide();
56 this.bubble('onTryLogin', {
57 username: this.$.username.getValue(),
58 password: this.$.password.getValue()