summaryrefslogtreecommitdiff
path: root/frontend/gamma/js/Clipperz/PM/UI/Web/Components/CardDialogRecordDirectLoginComponent.js
Side-by-side diff
Diffstat (limited to 'frontend/gamma/js/Clipperz/PM/UI/Web/Components/CardDialogRecordDirectLoginComponent.js') (more/less context) (ignore whitespace changes)
-rw-r--r--frontend/gamma/js/Clipperz/PM/UI/Web/Components/CardDialogRecordDirectLoginComponent.js26
1 files changed, 10 insertions, 16 deletions
diff --git a/frontend/gamma/js/Clipperz/PM/UI/Web/Components/CardDialogRecordDirectLoginComponent.js b/frontend/gamma/js/Clipperz/PM/UI/Web/Components/CardDialogRecordDirectLoginComponent.js
index 2e61f5f..0cee650 100644
--- a/frontend/gamma/js/Clipperz/PM/UI/Web/Components/CardDialogRecordDirectLoginComponent.js
+++ b/frontend/gamma/js/Clipperz/PM/UI/Web/Components/CardDialogRecordDirectLoginComponent.js
@@ -1,82 +1,79 @@
/*
-Copyright 2008-2011 Clipperz Srl
+Copyright 2008-2013 Clipperz Srl
-This file is part of Clipperz Community Edition.
-Clipperz Community Edition is an online password manager.
+This file is part of Clipperz, the online password manager.
For further information about its features and functionalities please
refer to http://www.clipperz.com.
-* Clipperz Community Edition is free software: you can redistribute
- it and/or modify it under the terms of the GNU Affero General Public
- License as published by the Free Software Foundation, either version
- 3 of the License, or (at your option) any later version.
+* Clipperz is free software: you can redistribute it and/or modify it
+ under the terms of the GNU Affero General Public License as published
+ by the Free Software Foundation, either version 3 of the License, or
+ (at your option) any later version.
-* Clipperz Community Edition is distributed in the hope that it will
- be useful, but WITHOUT ANY WARRANTY; without even the implied
- warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
+* Clipperz is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
See the GNU Affero General Public License for more details.
* You should have received a copy of the GNU Affero General Public
- License along with Clipperz Community Edition. If not, see
- <http://www.gnu.org/licenses/>.
+ License along with Clipperz. If not, see http://www.gnu.org/licenses/.
*/
Clipperz.Base.module('Clipperz.PM.UI.Web.Components');
Clipperz.PM.UI.Web.Components.CardDialogRecordDirectLoginComponent = function(args) {
args = args || {};
Clipperz.PM.UI.Web.Components.CardDialogRecordDirectLoginComponent.superclass.constructor.apply(this, arguments);
this._reference = args.reference || Clipperz.Base.exception.raise('MandatoryParameter');
this._faviconComponent = null;
return this;
}
//=============================================================================
Clipperz.Base.extend(Clipperz.PM.UI.Web.Components.CardDialogRecordDirectLoginComponent, Clipperz.PM.UI.Common.Components.BaseComponent, {
//-------------------------------------------------------------------------
'toString': function () {
return "Clipperz.PM.UI.Web.Components.CardDialogRecordDirectLoginComponent component";
},
//-------------------------------------------------------------------------
'reference': function () {
return this._reference;
},
//-------------------------------------------------------------------------
'renderSelf': function() {
-//console.log(">>> CardDialogRecordDirectLoginComponent.renderSelf");
this.append(this.element(), [
{tag:'div', cls:'cardDialogRecordDirectLoginComponent_favicon', children:[
{tag:'img', cls:'favicon', id:this.getId('favicon')}
]},
{tag:'div', cls:'cardDialogRecordDirectLoginComponent_label', children:[
{tag:'input', id:this.getId('label'), type:'text'}
]},
{tag:'div', cls:'open', children:[
{tag:'span', children:[
{tag:'a', href:'open', id:this.getId('open'), html:'&nbsp;'}
]}
]},
{tag:'div', cls:'edit', children:[
{tag:'span', children:[
{tag:'a', href:'edit', id:this.getId('edit'), html:"edit"}
]}
]},
{tag:'div', cls:'delete', children:[
{tag:'span', children:[
{tag:'a', href:'delete', id:this.getId('delete'), html:"delete"}
]}
]}
/*
{tag:'td', cls:'fieldState'},
@@ -96,84 +93,81 @@ Clipperz.Base.extend(Clipperz.PM.UI.Web.Components.CardDialogRecordDirectLoginCo
{tag:'span', children:[
{tag:'a', href:'#', id:this.getId('delete'), html:"delete"}
]}
]}
]}
*/
]);
MochiKit.Signal.connect(this.getId('label'), 'onkeyup', MochiKit.Base.partial(MochiKit.Signal.signal, this, 'changedValue'));
MochiKit.Signal.connect(this.getId('open'), 'onclick', this, 'openDirectLogin');
MochiKit.Signal.connect(this.getId('edit'), 'onclick', this, 'editDirectLogin');
MochiKit.Signal.connect(this.getId('delete'), 'onclick', this, 'deleteDirectLogin');
},
//-------------------------------------------------------------------------
'shouldShowElementWhileRendering': function () {
return false;
},
//-------------------------------------------------------------------------
'faviconComponent': function () {
if (this._faviconComponent == null) {
-//console.log("created the FAVICON component");
this._faviconComponent = new Clipperz.PM.UI.Common.Components.FaviconComponent({element:this.getId('favicon')});
}
return this._faviconComponent;
},
//=========================================================================
'label': function () {
return this.getElement('label').value;
},
'setLabel': function (aValue) {
this.getElement('label').value = Clipperz.Base.sanitizeString(aValue);
},
//-------------------------------------------------------------------------
'favicon': function () {
// return this.getElement('favicon').src;
return this.faviconComponent().src();
},
'setFavicon': function (aValue) {
// this.getElement('favicon').src = Clipperz.Base.sanitizeString(aValue);
this.faviconComponent().setSrc(Clipperz.Base.sanitizeString(aValue));
},
//=========================================================================
'openDirectLogin': function (anEvent) {
anEvent.preventDefault();
MochiKit.Signal.signal(this, 'openDirectLogin', this.reference());
},
//-------------------------------------------------------------------------
'editDirectLogin': function (anEvent) {
anEvent.preventDefault();
MochiKit.Signal.signal(this, 'editDirectLogin', this.reference());
-//console.log("EDIT DIRECT LOGIN");
},
//-------------------------------------------------------------------------
'deleteDirectLogin': function (anEvent) {
anEvent.preventDefault();
MochiKit.Signal.signal(this, 'deleteDirectLogin', this.reference());
-//console.log("DELETE DIRECT LOGIN");
},
//=========================================================================
__syntaxFix__: "syntax fix"
});