// Lets the above panes stay at the top.
gridConstraints.weighty = 1.0;
mainPanel.add(Box.createVerticalGlue(), gridConstraints);
// Connect the listeners
new SingleDockGroup(this, menuItem);
networkView.provideObservable().addObserver(this);
// Add the dock to the docking manager
DefaultLayoutDockingManager.getInstance().addView(this,
DockArea.NORTH_EAST, false, 3);