public LevelDocument( ) { InitializeComponent( ); _viewport = new ViewportControl( ); _viewport.Dock = DockStyle.Fill; this.Controls.Add( _viewport ); }
public LevelTabPage( LevelEd level ) { viewport = new ViewportControl( ); this.BorderStyle = BorderStyle.FixedSingle; this.Controls.Add( viewport ); viewport.Dock = DockStyle.Fill; this.Text = level.Name; this._level = level; }
private void InitGlobalProperties( ) { _popUpWindow = new PopUpWindow( this ); _tempViewport = new ViewportControl( ); _tempViewport.Location = new System.Drawing.Point( -20, 12 ); Controls.Add( _tempViewport ); _itemSelectionTool.Click += new EventHandler( _tools.SelectionTool_Click ); _itemToggleGrid.Click += new EventHandler( _tools.ToggleGrid_Click ); _itemToggleZones.Click += new EventHandler( _tools.ToggleZones_Click ); _itemToggleLight.Click += new EventHandler( _tools.ToggleLight_Click ); _itemToggleEffects.Click += new EventHandler( _tools.ToggleEffects_Click ); this.Text = Consts.Editor.TITLE; _undoProvider = new UndoProvider( ); _undoProvider.CanRedoChanged += new EventHandler( UndoProvider_CanRedoChanged ); _undoProvider.CanUndoChanged += new EventHandler( UndoProvider_CanUndoChanged ); }