Package pivot.wtk

Examples of pivot.wtk.Rollup


    }

    public void setUseBullet(boolean useBullet) {
        this.useBullet = useBullet;

        Rollup rollup = (Rollup)getComponent();
        if (rollup.getContent() == null) {
            rollupButton.repaint();
        }
    }
View Full Code Here


            return height;
        }

        @Override
        public void start(TransitionListener transitionListener) {
            Rollup rollup = (Rollup)getComponent();
            originalPreferredHeight = rollup.isPreferredHeightSet() ?
                rollup.getPreferredHeight() : -1;

            super.start(transitionListener);
        }
View Full Code Here

            super.start(transitionListener);
        }

        @Override
        public void stop() {
            Rollup rollup = (Rollup)getComponent();
            rollup.setPreferredHeight(originalPreferredHeight);

            super.stop();
        }
View Full Code Here

        public void layout() {
            // No-op
        }

        public void paint(Graphics2D graphics) {
            Rollup rollup = (Rollup)TerraRollupSkin.this.getComponent();

            graphics.setStroke(new BasicStroke(0));
            graphics.setPaint(buttonColor);
            graphics.setRenderingHint(RenderingHints.KEY_ANTIALIASING,
                RenderingHints.VALUE_ANTIALIAS_ON);

            if (rollup.getContent() == null && useBullet) {
                // Paint the bullet
                RoundRectangle2D.Double shape = new RoundRectangle2D.Double(1, 1, 4, 4, 2, 2);
                graphics.draw(shape);
                graphics.fill(shape);
            } else if (rollup.isExpanded()) {
                // Paint the collapse image
                int[] xPoints = {0, 3, 6};
                int[] yPoints = {0, 6, 0};
                graphics.fillPolygon(xPoints, yPoints, 3);
                graphics.drawPolygon(xPoints, yPoints, 3);
View Full Code Here

            }
        }

        @Override
        public boolean mouseClick(Component component, Mouse.Button button, int x, int y, int count) {
            Rollup rollup = (Rollup)TerraRollupSkin.this.getComponent();
            rollup.setExpanded(!rollup.isExpanded());
            return true;
        }
View Full Code Here

        public boolean mouseClick(Component component, Mouse.Button button, int x, int y, int count) {
            boolean consumed = false;

            if (headingToggles) {
                Rollup rollup = (Rollup)getComponent();
                rollup.setExpanded(!rollup.isExpanded());
                consumed = true;
            }

            return consumed;
        }
View Full Code Here

    implements RollupListener, RollupStateListener {
    @Override
    public void install(Component component) {
        super.install(component);

        Rollup rollup = (Rollup)component;
        rollup.getRollupListeners().add(this);
        rollup.getRollupStateListeners().add(this);
    }
View Full Code Here

        rollup.getRollupStateListeners().add(this);
    }

    @Override
    public void uninstall() {
        Rollup rollup = (Rollup)getComponent();
        rollup.getRollupListeners().remove(this);
        rollup.getRollupStateListeners().remove(this);

        super.uninstall();
    }
View Full Code Here

TOP

Related Classes of pivot.wtk.Rollup

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.