Fix NPE when abandoning a change

We need to deregister the existing key bindings before we clear out
the UI widgets.  This gives the current PatchSetPanel a chance to
degister its navigation keys before we toss its reference.

The NPE here occurred because we tried to deregister the keys,
but the map was already empty, so we no longer had access to the
correct key.

Change-Id: I11a265287b1e61a23fad369b314cc7e6d9ad5524
Signed-off-by: Shawn O. Pearce <sop@google.com>
1 file changed