Bounds checking in GridPanel.h