コード例 #1
0
 @Override
 protected Point getInitialSize() {
   Point size = super.getInitialSize();
   if (size.x < MIN_WIDTH) {
     size.x = MIN_WIDTH;
   }
   if (size.y < MIN_HEIGHT) {
     size.y = MIN_HEIGHT;
   }
   return size;
 }
コード例 #2
0
 private void updatePoint(MouseEvent e) {
   p.x = e.x;
   p.y = e.y;
 }