< prev index next >

src/java.desktop/share/classes/com/sun/java/swing/plaf/motif/MotifInternalFrameTitlePane.java

Print this page




 225 
 226     protected void showSystemMenu(){
 227       systemMenu.show(systemButton, 0, BUTTON_SIZE);
 228     }
 229 
 230     protected void hideSystemMenu(){
 231       systemMenu.setVisible(false);
 232     }
 233 
 234     static Dimension buttonDimension = new Dimension(BUTTON_SIZE, BUTTON_SIZE);
 235 
 236     @SuppressWarnings("serial") // Superclass is not serializable across versions
 237     private abstract class FrameButton extends JButton {
 238 
 239         FrameButton() {
 240             super();
 241             setFocusPainted(false);
 242             setBorderPainted(false);
 243         }
 244 

 245         public boolean isFocusTraversable() {
 246             return false;
 247         }
 248 
 249         public void requestFocus() {
 250             // ignore request.
 251         }
 252 
 253         public Dimension getMinimumSize() {
 254             return buttonDimension;
 255         }
 256 
 257         public Dimension getPreferredSize() {
 258             return buttonDimension;
 259         }
 260 
 261         public void paintComponent(Graphics g) {
 262             Dimension d = getSize();
 263             int maxX = d.width - 1;
 264             int maxY = d.height - 1;




 225 
 226     protected void showSystemMenu(){
 227       systemMenu.show(systemButton, 0, BUTTON_SIZE);
 228     }
 229 
 230     protected void hideSystemMenu(){
 231       systemMenu.setVisible(false);
 232     }
 233 
 234     static Dimension buttonDimension = new Dimension(BUTTON_SIZE, BUTTON_SIZE);
 235 
 236     @SuppressWarnings("serial") // Superclass is not serializable across versions
 237     private abstract class FrameButton extends JButton {
 238 
 239         FrameButton() {
 240             super();
 241             setFocusPainted(false);
 242             setBorderPainted(false);
 243         }
 244 
 245         @SuppressWarnings("deprecation")
 246         public boolean isFocusTraversable() {
 247             return false;
 248         }
 249 
 250         public void requestFocus() {
 251             // ignore request.
 252         }
 253 
 254         public Dimension getMinimumSize() {
 255             return buttonDimension;
 256         }
 257 
 258         public Dimension getPreferredSize() {
 259             return buttonDimension;
 260         }
 261 
 262         public void paintComponent(Graphics g) {
 263             Dimension d = getSize();
 264             int maxX = d.width - 1;
 265             int maxY = d.height - 1;


< prev index next >