Package org.apache.isis.viewer.dnd.view.border

Examples of org.apache.isis.viewer.dnd.view.border.ScrollBorder


                View cell;
                if (cellContents[cellNo] == null) {
                    cell = new BlankView(new NullContent());
                } else {
                    cell = new CompositeViewUsingBuilder(cellContents[cellNo], null, new Axes(), new StackLayout(), new CollectionElementBuilder(new IconElementFactory()));
                    cell = new ScrollBorder(cell);
                }
                cells[cellNo] = cell;
                addView(cell);
            }
        }
View Full Code Here


public class InternalTableSpecification extends AbstractTableSpecification {
    public InternalTableSpecification() {
        addViewDecorator(new CompositeViewDecorator() {
            @Override
            public View decorate(final View view, final Axes axes) {
                final ScrollBorder scrollingView = new ScrollBorder(view);
                // note - the next call needs to be after the creation of the
                // window border
                // so that it exists when the header is set up
                scrollingView.setTopHeader(new TableHeader(view.getContent(), axes.getAxis(TableAxis.class)));
                scrollingView.setFocusManager(new TableFocusManager(scrollingView));
                return scrollingView;

            }
        });
View Full Code Here

public class WindowTableSpecification extends AbstractTableSpecification {
    public WindowTableSpecification() {
        addViewDecorator(new CompositeViewDecorator() {
            @Override
            public View decorate(final View view, final Axes axes) {
                final ScrollBorder scrollingView = new ScrollBorder(view);
                final View viewWithWindowBorder = scrollingView;
                // note - the next call needs to be after the creation of the
                // window border so
                // that it exists when the header is set up
                scrollingView.setTopHeader(new TableHeader(view.getContent(), axes.getAxis(TableAxis.class)));
                viewWithWindowBorder.setFocusManager(new TableFocusManager(viewWithWindowBorder));
                return viewWithWindowBorder;
            }
        });
View Full Code Here

    private static final UserAction CLOSE_VIEWS_FOR_OBJECT = new CloseAllViewsForObjectOption();
    private static final UserAction CLOSE_OTHER_VIEWS_FOR_OBJECT = new CloseOtherViewsForObjectOption();
    private static final IconizeViewOption iconizeOption = new IconizeViewOption();

    public WindowBorder(final View wrappedView, final boolean scrollable) {
        super(addTransientBorderIfNeccessary(scrollable ? new ScrollBorder(wrappedView) : wrappedView));

        if (isTransient()) {
            setControls(new WindowControl[] { new CloseWindowControl(this) });
        } else {
            setControls(new WindowControl[] { new IconizeWindowControl(this), new ResizeWindowControl(this), new CloseWindowControl(this) });
View Full Code Here

        }, new CancelAction(),

        };

        final DetailedMessageView messageView = new DetailedMessageView(content, this);
        return new ButtonBorder(actions, new ScrollBorder(messageView));
    }
View Full Code Here

    @Test
    public void testScrollBar() {
        final DummyView innerView = new DummyView();
        innerView.setupRequiredSize(new Size(100, 200));
        final View view = new ScrollBorder(innerView);

        ViewAreaType type = view.viewAreaType(new Location(20, 190));
        Assert.assertEquals(ViewAreaType.INTERNAL, type);

        type = view.viewAreaType(new Location(95, 20));
        Assert.assertEquals(ViewAreaType.INTERNAL, type);
    }
View Full Code Here

        topHeader.setupRequiredSize(new Size(0, 20));

        final DummyView leftHeader = new DummyView();
        leftHeader.setupRequiredSize(new Size(30, 0));

        final View scrollBorder = new ScrollBorder(contentView, leftHeader, topHeader);

        scrollBorder.setSize(new Size(100, 200));

        Assert.assertEquals(new Size(300, 400), contentView.getSize());
        Assert.assertEquals(new Size(300, 20), topHeader.getSize());
        Assert.assertEquals(new Size(30, 400), leftHeader.getSize());
View Full Code Here

        topHeader.setupRequiredSize(new Size(0, 20));

        final DummyView leftHeader = new DummyView();
        leftHeader.setupRequiredSize(new Size(30, 0));

        final View scrollBorder = new ScrollBorder(contentView, leftHeader, topHeader);

        scrollBorder.setSize(new Size(100, 200));

    }
View Full Code Here

        addViewDecorator(new CompositeViewDecorator() {
            @Override
            public View decorate(final View view, final Axes axes) {
                final SelectionListAxis axis = axes.getAxis(SelectionListAxis.class);
                final View list = new SelectionListFocusBorder(view, axis);
                return new DisposeOverlay(new BackgroundBorder(new LineBorder(new ScrollBorder(list))), axis);
            }
        });
    }
View Full Code Here

    @Override
    public View createView(final Content content, final Axes axes, final int sequence) {
        final ButtonAction actions[] = new ButtonAction[] { new CloseViewAction() };
        final MessageView messageView = new MessageView((MessageContent) content, this);
        final View dialogView = new ButtonBorder(actions, new ScrollBorder(messageView));
        dialogView.setFocusManager(new SubviewFocusManager(dialogView));
        return dialogView;
    }
View Full Code Here

TOP

Related Classes of org.apache.isis.viewer.dnd.view.border.ScrollBorder

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.