Exemple #1
0
        private static void CreatePropertyGrids()
        {
            #region Camera PropertyGrid
            mCameraPropertyGrid = new CameraPropertyGrid(GuiManager.Cursor);
            GuiManager.AddWindow(mCameraPropertyGrid);
            mCameraPropertyGrid.SelectedObject = SpriteManager.Camera;
            mCameraPropertyGrid.X = mCameraPropertyGrid.ScaleX;
            mCameraPropertyGrid.Y = 40;
            mCameraPropertyGrid.UndoInstructions = UndoManager.Instructions;
            mCameraPropertyGrid.Name             = "Camera";
            mCameraPropertyGrid.Visible          = false;
            #endregion

            #region Scene Camera PropertyGrid
            mSceneCameraPropertyGrid = new CameraBoundsPropertyGrid(EditorData.BoundsCamera);
            // This doesn't get added to the GuiManager because it was created before the pattern was established that PropertyGrids don't add themselves.
            mSceneCameraPropertyGrid.Visible          = false;
            mSceneCameraPropertyGrid.UndoInstructions = UndoManager.Instructions;
            mSceneCameraPropertyGrid.Name             = "Camera Bounds";
            #endregion

            #region EditorPropertiesGrid
            mEditorPropertiesGrid         = new EditorPropertiesGrid();
            mEditorPropertiesGrid.Visible = false;
            #endregion

            #region LineGrid PropertyGrid
            mLineGridPropertyGrid         = new LineGridPropertyGrid(EditorData.LineGrid);
            mLineGridPropertyGrid.Visible = false;

            #endregion
        }
Exemple #2
0
        private static void CreatePropertyGrids()
        {
            #region CamerPropertyGrid
            mCameraPropertyGrid = new CameraPropertyGrid(GuiManager.Cursor);
            GuiManager.AddWindow(mCameraPropertyGrid);
            mCameraPropertyGrid.SelectedObject = SpriteManager.Camera;
            mCameraPropertyGrid.X = mCameraPropertyGrid.ScaleX;
            mCameraPropertyGrid.Y = 40;
            mCameraPropertyGrid.HasCloseButton   = true;
            mCameraPropertyGrid.UndoInstructions =
                UndoManager.Instructions;
            #endregion

            #region NodeNetwork PropertyGrid

            mNodeNetworkPropertyGrid = new NodeNetworkPropertyGrid();
            mNodeNetworkPropertyGrid.SelectedObject = EditorData.NodeNetwork;
            mNodeNetworkPropertyGrid.X = mNodeNetworkPropertyGrid.ScaleX;
            mNodeNetworkPropertyGrid.Y = 61;
            mNodeNetworkPropertyGrid.HasCloseButton   = true;
            mNodeNetworkPropertyGrid.UndoInstructions =
                UndoManager.Instructions;

            #endregion

            #region ScenePropertyGrid

            mScenePropertyGrid = new ScenePropertyGrid(GuiManager.Cursor);
            GuiManager.AddWindow(mScenePropertyGrid);
            mScenePropertyGrid.X = mScenePropertyGrid.ScaleX;
            mScenePropertyGrid.Y = 75.7f;
            mScenePropertyGrid.ShowPropertyGridOnStrongSelect = true;
            mScenePropertyGrid.HasCloseButton   = true;
            mScenePropertyGrid.Visible          = false;
            mScenePropertyGrid.UndoInstructions = UndoManager.Instructions;
            #endregion

            #region ShapeCollectionPropertyGrid

            mShapeCollectionPropertyGrid = new ShapeCollectionPropertyGrid(GuiManager.Cursor);
            GuiManager.AddWindow(mShapeCollectionPropertyGrid);
            mShapeCollectionPropertyGrid.ShowPropertyGridOnStrongSelectAxisAlignedCube      = true;
            mShapeCollectionPropertyGrid.ShowPropertyGridOnStrongSelectAxisAlignedRectangle = true;
            mShapeCollectionPropertyGrid.ShowPropertyGridOnStrongSelectCircle  = true;
            mShapeCollectionPropertyGrid.ShowPropertyGridOnStrongSelectPolygon = true;
            mShapeCollectionPropertyGrid.ShowPropertyGridOnStrongSelectSphere  = true;
            mShapeCollectionPropertyGrid.HasCloseButton   = true;
            mShapeCollectionPropertyGrid.Visible          = false;
            mShapeCollectionPropertyGrid.UndoInstructions = UndoManager.Instructions;
            #endregion

            PropertyGrid.SetNewWindowEvent <FlatRedBall.AI.Pathfinding.PositionedNode>(CreatePositionedNodePropertyGrid);
            PropertyGrid.SetNewWindowEvent <Color>(CreateColorPropertyGrid);

            #region EditorPropertiesGrid
            mEditorPropertiesGrid         = new EditorPropertiesGrid();
            mEditorPropertiesGrid.Visible = false;
            #endregion
        }
Exemple #3
0
        private static void CreatePropertyGrids()
        {
            #region Camera PropertyGrid
            mCameraPropertyGrid = new CameraPropertyGrid(GuiManager.Cursor);
            GuiManager.AddWindow(mCameraPropertyGrid);
            mCameraPropertyGrid.SelectedObject = SpriteManager.Camera;
            mCameraPropertyGrid.X = mCameraPropertyGrid.ScaleX;
            mCameraPropertyGrid.Y = 40;
            mCameraPropertyGrid.UndoInstructions = UndoManager.Instructions;
            mCameraPropertyGrid.Name = "Camera";
            mCameraPropertyGrid.Visible = false;
            #endregion

            #region Scene Camera PropertyGrid
            mSceneCameraPropertyGrid = new CameraBoundsPropertyGrid(EditorData.BoundsCamera);
            // This doesn't get added to the GuiManager because it was created before the pattern was established that PropertyGrids don't add themselves.
            mSceneCameraPropertyGrid.Visible = false;
            mSceneCameraPropertyGrid.UndoInstructions = UndoManager.Instructions;
            mSceneCameraPropertyGrid.Name = "Camera Bounds";
            #endregion

            #region EditorPropertiesGrid
            mEditorPropertiesGrid = new EditorPropertiesGrid();
            mEditorPropertiesGrid.Visible = false;
            #endregion

            #region LineGrid PropertyGrid
            mLineGridPropertyGrid = new LineGridPropertyGrid(EditorData.LineGrid);
            mLineGridPropertyGrid.Visible = false;

            #endregion
        }
Exemple #4
0
        private static void CreatePropertyGrids()
        {
            #region CamerPropertyGrid
            mCameraPropertyGrid = new CameraPropertyGrid(GuiManager.Cursor);
            GuiManager.AddWindow(mCameraPropertyGrid);
            mCameraPropertyGrid.SelectedObject = SpriteManager.Camera;
            mCameraPropertyGrid.X = mCameraPropertyGrid.ScaleX;
            mCameraPropertyGrid.Y = 40;
            mCameraPropertyGrid.HasCloseButton = true;
            mCameraPropertyGrid.UndoInstructions =
                UndoManager.Instructions;
            #endregion

            #region NodeNetwork PropertyGrid

            mNodeNetworkPropertyGrid = new NodeNetworkPropertyGrid();
            mNodeNetworkPropertyGrid.SelectedObject = EditorData.NodeNetwork;
            mNodeNetworkPropertyGrid.X = mNodeNetworkPropertyGrid.ScaleX;
            mNodeNetworkPropertyGrid.Y = 61;
            mNodeNetworkPropertyGrid.HasCloseButton = true;
            mNodeNetworkPropertyGrid.UndoInstructions =
                UndoManager.Instructions;

            #endregion

            #region ScenePropertyGrid

            mScenePropertyGrid = new ScenePropertyGrid(GuiManager.Cursor);
            GuiManager.AddWindow(mScenePropertyGrid);
            mScenePropertyGrid.X = mScenePropertyGrid.ScaleX;
            mScenePropertyGrid.Y = 75.7f;
            mScenePropertyGrid.ShowPropertyGridOnStrongSelect = true;
            mScenePropertyGrid.HasCloseButton = true;
            mScenePropertyGrid.Visible = false;
            mScenePropertyGrid.UndoInstructions = UndoManager.Instructions;
            #endregion

            #region ShapeCollectionPropertyGrid

            mShapeCollectionPropertyGrid = new ShapeCollectionPropertyGrid(GuiManager.Cursor);
            GuiManager.AddWindow(mShapeCollectionPropertyGrid);
            mShapeCollectionPropertyGrid.ShowPropertyGridOnStrongSelectAxisAlignedCube = true;
            mShapeCollectionPropertyGrid.ShowPropertyGridOnStrongSelectAxisAlignedRectangle = true;
            mShapeCollectionPropertyGrid.ShowPropertyGridOnStrongSelectCircle = true;
            mShapeCollectionPropertyGrid.ShowPropertyGridOnStrongSelectPolygon = true;
            mShapeCollectionPropertyGrid.ShowPropertyGridOnStrongSelectSphere = true;
            mShapeCollectionPropertyGrid.HasCloseButton = true;
            mShapeCollectionPropertyGrid.Visible = false;
            mShapeCollectionPropertyGrid.UndoInstructions = UndoManager.Instructions;
            #endregion

            PropertyGrid.SetNewWindowEvent<FlatRedBall.AI.Pathfinding.PositionedNode>(CreatePositionedNodePropertyGrid);
            PropertyGrid.SetNewWindowEvent<Color>(CreateColorPropertyGrid);

            #region EditorPropertiesGrid
            mEditorPropertiesGrid = new EditorPropertiesGrid();
            mEditorPropertiesGrid.Visible = false;
            #endregion
        }