src/solaris/classes/sun/awt/X11/XScrollbar.java

Print this page

        

@@ -116,11 +116,13 @@
     }
 
     abstract protected void rebuildArrows();
 
     public void setSize(int width, int height) {
-        if (log.isLoggable(PlatformLogger.FINER)) log.finer("Setting scroll bar " + this + " size to " + width + "x" + height);
+        if (log.isLoggable(PlatformLogger.FINER)) {
+            log.finer("Setting scroll bar " + this + " size to " + width + "x" + height);
+        }
         this.width = width;
         this.height = height;
     }
 
     /**

@@ -162,11 +164,13 @@
      * @param width the width of the scrollbar
      * @param height the height of the scrollbar
      * @param paintAll paint the whole scrollbar if true, just the thumb is false
      */
     void paint(Graphics g, Color colors[], boolean paintAll) {
-        if (log.isLoggable(PlatformLogger.FINER)) log.finer("Painting scrollbar " + this);
+        if (log.isLoggable(PlatformLogger.FINER)) {
+            log.finer("Painting scrollbar " + this);
+        }
 
         boolean useBufferedImage = false;
         Graphics2D g2 = null;
         BufferedImage buffer = null;
         if (!(g instanceof Graphics2D)) {

@@ -333,11 +337,13 @@
 
     /**
      * Tell the scroller to start scrolling.
      */
     void startScrolling() {
+        if (log.isLoggable(PlatformLogger.FINER)) {
         log.finer("Start scrolling on " + this);
+        }
         // Make sure that we scroll at least once
         scroll();
 
         // wake up the scroll repeater
         if (scroller == null) {

@@ -353,11 +359,13 @@
     /**
      * Tell the instance scroller to start scrolling.
      * See 6243382 for more information
      */
     void startScrollingInstance() {
+        if (log.isLoggable(PlatformLogger.FINER)) {
         log.finer("Start scrolling on " + this);
+        }
         // Make sure that we scroll at least once
         scroll();
 
         i_scroller.setScrollbar(this);
         i_scroller.start();

@@ -366,11 +374,13 @@
     /**
      * Tell the instance scroller to stop scrolling.
      * See 6243382 for more information
      */
     void stopScrollingInstance() {
+        if (log.isLoggable(PlatformLogger.FINER)) {
         log.finer("Stop scrolling on " + this);
+        }
 
         i_scroller.stop();
     }
 
     /**