예제 #1
0
    public void draw(Canvas canvas) {
      if (matrix != null) {
        canvas.concat(matrix);
      }

      graphics = AndroidGraphics.fromGraphics(canvas, this, graphics);

      final iPlatformComponentPainter cp = componentPainter;

      if (cp == null) {
        super.draw(canvas);
      } else {
        cp.paint(
            graphics,
            getScrollX(),
            getScrollY(),
            getWidth(),
            getHeight(),
            iPlatformPainter.UNKNOWN,
            false);
        super.draw(canvas);
        cp.paint(
            graphics,
            getScrollX(),
            getScrollY(),
            getWidth(),
            getHeight(),
            iPlatformPainter.UNKNOWN,
            true);
      }

      graphics.clear();
    }
예제 #2
0
  @Override
  protected void paintComponent(Graphics g) {
    iPlatformComponentPainter cp = getComponentPainter();

    if (cp != null) {
      float height = getHeight();
      float width = getWidth();

      cp.paint(graphics, 0, 0, width, height, iPainter.HORIZONTAL, false);
    }

    super.paintComponent(g);
  }
예제 #3
0
  @Override
  protected void paintChildren(Graphics g) {
    super.paintChildren(graphics.getGraphics());

    iPlatformComponentPainter cp = getComponentPainter();

    if (cp != null) {
      float height = getHeight();
      float width = getWidth();

      cp.paint(graphics, 0, 0, width, height, iPainter.HORIZONTAL, true);
    }
  }