import com.google.gwt.core.client.GWT;
import com.google.gwt.user.client.ui.Widget;
import com.vaadin.terminal.gwt.client.ui.VFilterSelectPaintable;
-import com.vaadin.terminal.gwt.client.ui.VHorizontalSplitPanelPaintable;
import com.vaadin.terminal.gwt.client.ui.VListSelectPaintable;
import com.vaadin.terminal.gwt.client.ui.VUnknownComponentPaintable;
-import com.vaadin.terminal.gwt.client.ui.VVerticalSplitPanelPaintable;
public class WidgetSet {
return VListSelectPaintable.class;
}
}
- } else if (widgetClass == VHorizontalSplitPanelPaintable.class
- && uidl.hasAttribute("vertical")) {
- return VVerticalSplitPanelPaintable.class;
}
-
return widgetClass;
}
*/
if (fullyqualifiedName.equals("com.vaadin.ui.Select")) {
loadImplementation(VListSelectPaintable.class);
- } else if (fullyqualifiedName.equals("com.vaadin.ui.SplitPanel")) {
- loadImplementation(VVerticalSplitPanelPaintable.class);
}
return implementationByServerSideClassName;
import com.vaadin.terminal.Sizeable.Unit;
import com.vaadin.ui.AbstractOrderedLayout;
+import com.vaadin.ui.AbstractSplitPanel;
import com.vaadin.ui.Component;
import com.vaadin.ui.ComponentContainer;
import com.vaadin.ui.CustomComponent;
import com.vaadin.ui.GridLayout.Area;
import com.vaadin.ui.Layout;
import com.vaadin.ui.Panel;
-import com.vaadin.ui.SplitPanel;
import com.vaadin.ui.TabSheet;
import com.vaadin.ui.VerticalLayout;
import com.vaadin.ui.Window;
}
}
- if (parent instanceof Panel || parent instanceof SplitPanel
+ if (parent instanceof Panel || parent instanceof AbstractSplitPanel
|| parent instanceof TabSheet
|| parent instanceof CustomComponent) {
// height undefined, we know how how component works and no
* the component width
*/
return hasNonRelativeWidthComponent((Form) parent);
- } else if (parent instanceof SplitPanel
+ } else if (parent instanceof AbstractSplitPanel
|| parent instanceof TabSheet
|| parent instanceof CustomComponent) {
// FIXME Could we use com.vaadin package name here and
+++ /dev/null
-/*
-@VaadinApache2LicenseForJavaFiles@
- */
-
-package com.vaadin.ui;
-
-import com.vaadin.terminal.PaintException;
-import com.vaadin.terminal.PaintTarget;
-import com.vaadin.terminal.gwt.client.ui.VHorizontalSplitPanelPaintable;
-import com.vaadin.ui.ClientWidget.LoadStyle;
-
-/**
- * SplitPanel.
- *
- * <code>SplitPanel</code> is a component container, that can contain two
- * components (possibly containers) which are split by divider element.
- *
- * @author Vaadin Ltd.
- * @version
- * @VERSION@
- * @since 5.0
- * @deprecated in 6.5. Use {@link HorizontalSplitPanel} or
- * {@link VerticalSplitPanel} instead.
- */
-@Deprecated
-@ClientWidget(value = VHorizontalSplitPanelPaintable.class, loadStyle = LoadStyle.EAGER)
-public class SplitPanel extends AbstractSplitPanel {
-
- /* Predefined orientations */
-
- /**
- * Components are to be laid out vertically.
- */
- public static final int ORIENTATION_VERTICAL = 0;
-
- /**
- * Components are to be laid out horizontally.
- */
- public static final int ORIENTATION_HORIZONTAL = 1;
-
- /**
- * Orientation of the layout.
- */
- private int orientation;
-
- /**
- * Creates a new split panel. The orientation of the panels is
- * <code>ORIENTATION_VERTICAL</code>.
- */
- public SplitPanel() {
- super();
- orientation = ORIENTATION_VERTICAL;
- setSizeFull();
- }
-
- /**
- * Create a new split panels. The orientation of the panel is given as
- * parameters.
- *
- * @param orientation
- * the Orientation of the layout.
- */
- public SplitPanel(int orientation) {
- this();
- setOrientation(orientation);
- }
-
- /**
- * Paints the content of this component.
- *
- * @param target
- * the Paint Event.
- * @throws PaintException
- * if the paint operation failed.
- */
- @Override
- public void paintContent(PaintTarget target) throws PaintException {
- super.paintContent(target);
-
- if (orientation == ORIENTATION_VERTICAL) {
- target.addAttribute("vertical", true);
- }
-
- }
-
- /**
- * Gets the orientation of the split panel.
- *
- * @return the Value of property orientation.
- *
- */
- public int getOrientation() {
- return orientation;
- }
-
- /**
- * Sets the orientation of the split panel.
- *
- * @param orientation
- * the New value of property orientation.
- */
- public void setOrientation(int orientation) {
-
- // Checks the validity of the argument
- if (orientation < ORIENTATION_VERTICAL
- || orientation > ORIENTATION_HORIZONTAL) {
- throw new IllegalArgumentException();
- }
-
- this.orientation = orientation;
- requestRepaint();
- }
-
-}
import com.vaadin.ui.LoginForm;
import com.vaadin.ui.PopupView;
import com.vaadin.ui.Root;
-import com.vaadin.ui.SplitPanel;
import com.vaadin.ui.VerticalSplitPanel;
import com.vaadin.ui.Window;
public static List<Class<? extends ComponentContainer>> getComponentContainersSupportingUnlimitedNumberOfComponents() {
List<Class<? extends ComponentContainer>> classes = getComponentContainersSupportingAddRemoveComponent();
- classes.remove(SplitPanel.class);
classes.remove(VerticalSplitPanel.class);
classes.remove(HorizontalSplitPanel.class);
classes.remove(Window.class);
+++ /dev/null
-package com.vaadin.tests.components.splitpanel;\r
-\r
-import java.util.LinkedHashMap;\r
-\r
-import com.vaadin.ui.SplitPanel;\r
-\r
-@SuppressWarnings("deprecation")\r
-public class SplitPanels extends AbstractSplitPanelTest<SplitPanel> {\r
-\r
- private Command<SplitPanel, Integer> orientationCommand = new Command<SplitPanel, Integer>() {\r
-\r
- public void execute(SplitPanel c, Integer value, Object data) {\r
- c.setOrientation(value);\r
- }\r
- };\r
-\r
- @Override\r
- protected Class<SplitPanel> getTestClass() {\r
- return SplitPanel.class;\r
- }\r
-\r
- @Override\r
- protected void createActions() {\r
- super.createActions();\r
- createOrientationSelect(CATEGORY_FEATURES);\r
-\r
- }\r
-\r
- private void createOrientationSelect(String category) {\r
- LinkedHashMap<String, Integer> options = new LinkedHashMap<String, Integer>();\r
- options.put("Horizontal", SplitPanel.ORIENTATION_HORIZONTAL);\r
- options.put("Vertical", SplitPanel.ORIENTATION_VERTICAL);\r
- createSelectAction("Orientation", category, options, "Horizontal",\r
- orientationCommand);\r
-\r
- }\r
-}\r