DesignerAccess.java revision 7c478bd95313f5f23a4c958a745db2134aa03244
/*
* CDDL HEADER START
*
* The contents of this file are subject to the terms of the
* Common Development and Distribution License, Version 1.0 only
* (the "License"). You may not use this file except in compliance
* with the License.
*
* You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
* See the License for the specific language governing permissions
* and limitations under the License.
*
* When distributing Covered Code, include this CDDL HEADER in each
* file and include the License file at usr/src/OPENSOLARIS.LICENSE.
* If applicable, add the following below this CDDL HEADER, with the
* fields enclosed by brackets "[]" replaced with your own identifying
* information: Portions Copyright [yyyy] [name of copyright owner]
*
* CDDL HEADER END
*/
/*
* ident "%Z%%M% %I% %E% SMI"
*
* Copyright (c) 2000 by Sun Microsystems, Inc.
* All rights reserved.
*/
/*
* Copyright (C) 1996 Active Software, Inc.
* All rights reserved.
*
* @(#) DesignerAccess.java 1.25 - last change made 08/07/97
*/
/**
* Accessor class for use by Visual Java. Gives
* access to specific methods in the rt package that are package
* private. The methods in this class should not be used by any other
* application; they are for use by Visual Java only and are subject
* to change.
*
* @version 08/07/97, 1.25
*/
public class DesignerAccess {
//
// Constants
//
public static final int STATUS_BAR = 2002;
//
// Internal "Group" methods
//
return group.getContainer();
}
}
}
}
}
}
group.preValidate();
}
//
// Internal "AttributeManager" methods
//
}
//
// Internal "Root" methods
//
}
{
}
observer) {
}
}
}
}
}
}
}
}
child) {
}
}
}
}
//
// LOADED ROOT
//
/*
* Sets the loaded root flag.
*/
}
//
// Designer classes used by FrameShadow, DialogShadow,
// GBPanel, RootFrame
// and RootDialog.
//
private static Class frameClass;
private static Class dialogClass;
private static Class gbPanelClass;
private static Class rootWindowHelperClass;
frameClass = fc;
}
public static Class getFrameClass() {
return frameClass;
}
dialogClass = dc;
}
public static Class getDialogClass() {
return dialogClass;
}
gbPanelClass = gbc;
}
public static Class getGBPanelClass() {
return gbPanelClass;
}
public static void setRootWindowHelperClass(Class c) {
}
public static Class getRootWindowHelperClass() {
return rootWindowHelperClass;
}
//
// The current working directory for the designer
//
}
return cwd;
}
//
// UNSAVED EDITS REGISTRY
//
/**
* Is true when there are unsaved changes. Isn't going to get used
* unless the visual designer is running.
*/
private static boolean changesMade = false;
/*
* Returns whether there have been any changes made
* since the last save.
*/
public static boolean getChangesMade() {
return (changesMade);
}
/*
* Sets the changes made flag. Set to true when a change is made.
* This needs to set to false at the top-level of the designer's GUI
* whenever a file is opened, a "New" is done, a file is saved, etc.
* This doesn't work all the time, so we might replace it with
* something else in the future.
*/
public static void setChangesMade(boolean b) {
// if (b != changesMade) {
// Error e = new Error("DesignerAccess.changesMade
// switched to " + b);
// e.printStackTrace();
// }
changesMade = b;
}
//
// COMPONENT -> SHADOW HASHTABLE
//
/*
* Storage to map components (keys) to their shadow objects (values)
*/
/*
* Returns the shadow table, which contains components (as keys) and
* their associated shadow objects (as the values.) This one table
* is shared by all of runtime and the visual designer.
* It is used to
* find the Group that should handle the event for a particular
* component
* and to find the shadow object for components in the designer.
*/
public static Hashtable getShadowTable() {
return (shadowTable);
}
/**
* Global lock (for paint workaround.)
*/
/*
*
*/
static public void
designerError = obj;
}
return;
if (designerError != null) {
}
else
{
}
}
}