4632N/A * Copyright (c) 2011, Oracle and/or its affiliates. All rights reserved. 4632N/A * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4632N/A * This code is free software; you can redistribute it and/or modify it 4632N/A * under the terms of the GNU General Public License version 2 only, as 4632N/A * published by the Free Software Foundation. Oracle designates this 4632N/A * particular file as subject to the "Classpath" exception as provided 4632N/A * by Oracle in the LICENSE file that accompanied this code. 4632N/A * This code is distributed in the hope that it will be useful, but WITHOUT 4632N/A * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4632N/A * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4632N/A * version 2 for more details (a copy is included in the LICENSE file that 4632N/A * You should have received a copy of the GNU General Public License version 4632N/A * 2 along with this work; if not, write to the Free Software Foundation, 4632N/A * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4632N/A * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4632N/A * or visit www.oracle.com if you need additional information or have any 4632N/A * Based on AquaInternalFrameManager 4632N/A * DesktopManager implementation for Aqua 4632N/A * From WindowsDesktopManager: 4632N/A * This class implements a DesktopManager which more closely follows 4632N/A * the MDI model than the DefaultDesktopManager. Unlike the 4632N/A * DefaultDesktopManager policy, MDI requires that the selected 4632N/A * and activated child frames are the same, and that that frame 4632N/A * always be the top-most window. 4632N/A * The maximized state is managed by the DesktopManager with MDI, 4632N/A * instead of just being a property of the individual child frame. 4632N/A * This means that if the currently selected window is maximized 4632N/A * and another window is selected, that new window will be maximized. 4632N/A * We store this value to enforce Mac's single-selection model. 4632N/A /* The list of frames, sorted by order of creation. 4632N/A * This list is necessary because by default the order of 4632N/A * child frames in the JDesktopPane changes during frame 4632N/A * activation (the activated frame is moved to index 0). 4632N/A * We preserve the creation order so that "next" and "previous" 4632N/A * frame actions make sense. 4632N/A // If the icon moved, move the frame to that spot before expanding it 4632N/A // reshape does delta checks for us 4632N/A /** Removes the frame from its parent and adds its desktopIcon to the parent. */ 4632N/A // Same as super except doesn't deactivate it 4632N/A // Position depends on *current* position of frame, unlike super which reuses the first position 4632N/A // WindowsDesktopManager code 4632N/A // If this is the first activation, add to child list. 4632N/A // initialize first frame we find 4632N/A // the "current frame" is no longer in the list 4632N/A * Activate the next child JInternalFrame, as determined by 4632N/A * the frames' Z-order. If there is only one child frame, it 4632N/A * remains activated. If there are no child frames, nothing 4632N/A /** same as above but will activate a frame if none 4632N/A * Activate the previous child JInternalFrame, as determined by 4632N/A * the frames' Z-order. If there is only one child frame, it 4632N/A * remains activated. If there are no child frames, nothing