Ignore keyboard shortcut when modal dialog appears.

Ignore keyboard shortcut when modal dialog appears.