Changeset 1152 for trunk


Ignore:
Timestamp:
09/19/18 11:54:36 (6 years ago)
Author:
bln4
Message:

org.expeditee.items.Widgets.SwingWidget

-> Adjusted the painting process for SwingWidgets to better match the process expected by the GraphicsManager

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/expeditee/items/widgets/SwingWidget.java

    r1143 r1152  
    109109
    110110                Graphics2D g = SwingMiscManager.getIfUsingSwingGraphicsManager().getCurrentSurface();
    111 
    112                 final Point location = _swingComponent.getLocation();
    113                 int x = location.x;
    114                 int y = location.y;
    115111               
    116                 g.translate(x, y);
    117112                paintSwingWidget(g);
    118                 g.translate(-x, -y);
    119113        }
    120114       
     
    122116        protected void paintSwingWidget(Graphics2D g)
    123117        {
     118                final Point location = _swingComponent.getLocation();
     119                int x = location.x;
     120                int y = location.y;
     121                g.translate(x, y);
    124122                _swingComponent.paint(g);
     123                g.translate(-x, -y);
    125124        }
    126125       
Note: See TracChangeset for help on using the changeset viewer.