Exemple #1
0
 public Dimension getBorderSize() {
   if (cc.opts.fullScreen) return new Dimension(0, 0);
   Insets vpInsets = VncViewer.insets;
   Dimension borderSize =
       new Dimension(vpInsets.left + vpInsets.right, vpInsets.top + vpInsets.bottom);
   if (cc.showToolbar) borderSize.height += 22;
   return borderSize;
 }
Exemple #2
0
 public Dimension getAvailableSize() {
   Dimension availableSize = getSize();
   if (!cc.opts.fullScreen) {
     Insets vpInsets = VncViewer.insets;
     availableSize.width -= vpInsets.left + vpInsets.right;
     availableSize.height -= vpInsets.top + vpInsets.bottom;
   }
   if (tb.isVisible()) availableSize.height -= tb.getHeight();
   if (availableSize.width < 0) availableSize.width = 0;
   if (availableSize.height < 0) availableSize.height = 0;
   return availableSize;
 }