Skip to content

Commit

Permalink
Resolving Firefox MetricExplorer menu bug (#114)
Browse files Browse the repository at this point in the history
- Typing a '%' character in a form field contained within the
  MetricExplorer chart options menu would not have the desired effect. Instead,
  the whole menu would close and the '%' character would not be recorded in the
  field. The reason for this is because the doRelay handler for the
  chartOptionsMenu.keyNav currently always relays events regardless of whether
  or not the event is an actual keyNav event or not. This updates that handler
  to only call the handler in the case the event is for a keyNav event, thus '%'
  is no longer interpreted as 'left'. This version of the fix was pointed out by
  a code review comment by @jpwhite4.
  • Loading branch information
ryanrath authored Apr 27, 2017
1 parent 4e5606e commit 666188f
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion html/gui/js/modules/metric_explorer/MetricExplorer.js
Original file line number Diff line number Diff line change
Expand Up @@ -5674,7 +5674,12 @@ Ext.extend(XDMoD.Module.MetricExplorer, XDMoD.PortalModule, {
return true;
}

return h.call(this.scope || this, e, this.menu);
// Ensure that we only call the KeyNav handlers if this is a NavKey Press.
if (e.isNavKeyPress()) {
return h.call(this.scope || this, e, this.menu);
}

return true;
};

/**
Expand Down

0 comments on commit 666188f

Please sign in to comment.