Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Bug 368875 - Clone Repository buttons inaccessible. Fix the scoping e…
…rror I introduced while consolidating code.
  • Loading branch information
sfmccourt committed Jan 26, 2012
1 parent 4af8e94 commit a82f626
Showing 1 changed file with 8 additions and 7 deletions.
Expand Up @@ -92,7 +92,6 @@ define(['require', 'dojo', 'dijit', 'orion/commands', 'orion/util', 'orion/textv
}
if (this.parameterArea) {
var focusNode = fillFunction(this.parameterArea);

if (!dojo.byId("parameterClose") && this.dismissArea) {
// add the close button if the fill function did not.
var spacer = dojo.create("span", null, this.dismissArea, "last");
Expand Down Expand Up @@ -202,8 +201,8 @@ define(['require', 'dojo', 'dijit', 'orion/commands', 'orion/util', 'orion/textv
});
var spacer;
var parentDismiss = parameterArea;
var finish = function () {
this._collectAndCall(commandInvocation, parameterArea);
var finish = function (collector) {
collector._collectAndCall(commandInvocation, parameterArea);
localClose();
};

Expand All @@ -218,13 +217,13 @@ define(['require', 'dojo', 'dijit', 'orion/commands', 'orion/util', 'orion/textv
options.title = "More options...";
dojo.connect(options, "onclick", dojo.hitch(this, function() {
commandInvocation.parameters.optionsRequested = true;
finish();
finish(this);
}));
// onClick events do not register for spans when using the keyboard without a screen reader
dojo.connect(options, "onkeypress", dojo.hitch(this, function (e) {
if(e.keyCode === dojo.keys.ENTER) {
commandInvocation.parameters.optionsRequested = true;
finish();
finish(this);
}
}));
}
Expand All @@ -236,11 +235,13 @@ define(['require', 'dojo', 'dijit', 'orion/commands', 'orion/util', 'orion/textv
ok.title = "Submit";
dojo.addClass(ok, "core-sprite-ok");
dojo.addClass(ok, "dismiss");
dojo.connect(ok, "onclick", dojo.hitch(this, finish));
dojo.connect(ok, "onclick", dojo.hitch(this, function() {
finish(this);
}));
// onClick events do not register for spans when using the keyboard without a screen reader
dojo.connect(ok, "onkeypress", dojo.hitch(this, function (e) {
if(e.keyCode === dojo.keys.ENTER) {
finish();
finish(this);
}
}));

Expand Down

0 comments on commit a82f626

Please sign in to comment.