Add onFocus callback to popups

This commit is contained in:
RainLoop Team 2013-12-29 00:42:07 +04:00
parent fd2c2346a8
commit 04932fce63
28 changed files with 412 additions and 336 deletions

View file

@ -138,7 +138,10 @@ PopupsIdentityViewModel.prototype.onShow = function (oIdentity)
this.owner(this.id === RL.data().accountEmail());
}
};
PopupsIdentityViewModel.prototype.onFocus = function ()
{
if (!this.owner())
{
this.email.focused(true);
@ -152,7 +155,7 @@ PopupsIdentityViewModel.prototype.onBuild = function ()
var bResult = true;
if (oEvent && Enums.EventKeyCode.Esc === oEvent.keyCode && self.modalVisibility())
{
kn.delegateRun(self, 'cancelCommand');
Utils.delegateRun(self, 'cancelCommand');
bResult = false;
}
return bResult;