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

Examples of org.apache.isis.viewer.dnd.view.View


        spy.open();
    }

    public void sizeChange() {
        initSize();
        final View subviews[] = rootView.getSubviews();
        for (final View subview : subviews) {
            subview.invalidateLayout();
        }

        final Bounds bounds = new Bounds(internalDisplaySize);
View Full Code Here


        scheduleRepaint();
    }

    public void showDialog(final MessageContent content) {
        final ViewRequirement requirement = new ViewRequirement(content, ViewRequirement.OPEN);
        final View view = Toolkit.getViewFactory().createView(requirement);
        rootView.getWorkspace().addDialog(view, new Placement(Placement.CENTER));
        scheduleRepaint();
    }
View Full Code Here

        return requirement.isTextParseable() && ((TextParseableContent) requirement.getContent()).getNoLines() == 1;
    }

    @Override
    public View createView(final Content content, final Axes axes, final int sequence) {
        final View field = new TextFieldResizeBorder(new SingleLineTextField((TextParseableContent) content, this, true));
        if (content.isOptionEnabled()) {
            return new OpenValueDropDownBorder(field);
        } else {
            return field;
        }
View Full Code Here

        this.isVertical = isVertical;
    }

    @Override
    public void update(final ObjectAdapter object) {
        final View p = getParent();
        if (p != null) {
            p.invalidateLayout();
        }
    }
View Full Code Here

                final ObjectAdapter object = ((ObjectContent) content).getObject();
                if (busy.contains(object)) {
                    return true;
                }
            }
            final View parent = view.getParent();
            return parent != null && isBusy(parent);
        }
        return false;
    }
View Full Code Here

    @Override
    public void viewMenuOptions(final UserActionSet menuOptions) {
        super.viewMenuOptions(menuOptions);
        final UserActionSet subOptions = menuOptions.addNewActionSet("Elements as");
        final View firstSubview = getSubviews()[0];
        final int status = ViewRequirement.OPEN | ViewRequirement.CLOSED | ViewRequirement.SUBVIEW | ViewRequirement.FIXED;
        final ViewRequirement viewRequirement = new ViewRequirement(firstSubview.getContent(), status);
        final Enumeration<ViewSpecification> possibleViews = Toolkit.getViewFactory().availableViews(viewRequirement);
        while (possibleViews.hasMoreElements()) {
            addElementAsOption(subOptions, possibleViews.nextElement());
        }
    }
View Full Code Here

        @Override
        public void execute(final Workspace workspace, final View view, final Location at) {
            save(view);
            // by recreating the view the transient border is removed
            final ViewSpecification spec = view.getSpecification();
            final View newView = spec.createView(view.getContent(), view.getViewAxes(), -1);
            workspace.replaceView(view, newView);
        }
View Full Code Here

        super.viewMenuOptions(menuOptions);

        menuOptions.add(new UserActionAbstract("Hide") {
            @Override
            public void execute(final Workspace workspace, final View view, final Location at) {
                final View parent = wrappedView.getParent();
                wrappedView = new BlankView(getContent());
                wrappedView.setParent(parent);
                wrappedView.setView(ConfigurableFieldBorder.this);
                invalidateLayout();
            }
View Full Code Here

                if (specification != getSpecification()) {
                    final UserAction viewAs = new ReplaceViewOption(specification) {
                        @Override
                        protected void replace(final View view, final View withReplacement) {
                            final View parent = wrappedView.getParent();
                            wrappedView = LabelBorder.createFieldLabelBorder(view.getParent().getViewAxes().getAxis(LabelAxis.class), withReplacement);
                            wrappedView.setParent(parent);
                            wrappedView.setView(ConfigurableFieldBorder.this);
                            invalidateLayout();
                        }
View Full Code Here

        markDamaged();
    }

    @Override
    public DragEvent dragStart(final DragStart drag) {
        final View subview = subviewFor(drag.getLocation());
        if (subview != null) {
            drag.subtract(subview.getLocation());
            return subview.dragStart(drag);
        } else {
            if (drag.isCtrl()) {
                final View dragOverlay = new DragViewOutline(getView());
                return new ViewDragImpl(this, new Offset(drag.getLocation()), dragOverlay);
            } else {
                return Toolkit.getViewFactory().createDragContentOutline(this, drag.getLocation());
            }
        }
View Full Code Here

TOP

Related Classes of org.apache.isis.viewer.dnd.view.View

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.