001    /*
002     * $Id: DefaultSplitPaneModel.java 3100 2008-10-14 22:33:10Z rah003 $
003     *
004     * Copyright 2006 Sun Microsystems, Inc., 4150 Network Circle,
005     * Santa Clara, California 95054, U.S.A. All rights reserved.
006     *
007     * This library is free software; you can redistribute it and/or
008     * modify it under the terms of the GNU Lesser General Public
009     * License as published by the Free Software Foundation; either
010     * version 2.1 of the License, or (at your option) any later version.
011     *
012     * This library is distributed in the hope that it will be useful,
013     * but WITHOUT ANY WARRANTY; without even the implied warranty of
014     * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
015     * Lesser General Public License for more details.
016     *
017     * You should have received a copy of the GNU Lesser General Public
018     * License along with this library; if not, write to the Free Software
019     * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
020     */
021    package org.jdesktop.swingx.multisplitpane;
022    
023    import org.jdesktop.swingx.MultiSplitLayout.Divider;
024    import org.jdesktop.swingx.MultiSplitLayout.Leaf;
025    import org.jdesktop.swingx.MultiSplitLayout.Split;
026    /**
027     * A simplified SplitPaneLayout for common split pane needs. A common multi splitpane
028     * need is:
029     *
030     * +-----------+-----------+
031     * |           |           |
032     * |           +-----------+
033     * |           |           |
034     * +-----------+-----------+
035     *
036     * @author rbair
037     */
038    public class DefaultSplitPaneModel extends Split {
039        public static final String LEFT = "left";
040        public static final String TOP = "top";
041        public static final String BOTTOM = "bottom";
042        
043        /** Creates a new instance of DefaultSplitPaneLayout */
044        public DefaultSplitPaneModel() {
045            Split row = new Split();
046            Split col = new Split();
047            col.setRowLayout(false);
048            setChildren(new Leaf(LEFT), new Divider(), col);
049            col.setChildren(new Leaf(TOP), new Divider(), new Leaf(BOTTOM));
050        }
051        
052    }