コード例 #1
0
		public void SetBrush(IEditorBrush brush)
		{
			if (CurrentBrush != null)
				CurrentBrush.Dispose();

			CurrentBrush = brush ?? defaultBrush;
		}
コード例 #2
0
        public void SetBrush(IEditorBrush brush)
        {
            if (CurrentBrush != null)
            {
                CurrentBrush.Dispose();
            }

            CurrentBrush = brush ?? defaultBrush;
        }
コード例 #3
0
        public EditorViewportControllerWidget(World world, WorldRenderer worldRenderer)
        {
            this.worldRenderer  = worldRenderer;
            tooltipContainer    = Exts.Lazy(() => Ui.Root.Get <TooltipContainerWidget>(TooltipContainer));
            CurrentBrush        = DefaultBrush = new EditorDefaultBrush(this, worldRenderer);
            editorActionManager = world.WorldActor.Trait <EditorActionManager>();

            editorActionManager.OnChange += EditorActionManagerOnChange;
        }
コード例 #4
0
        public EditorViewportControllerWidget(World world, WorldRenderer worldRenderer)
        {
            this.worldRenderer  = worldRenderer;
            tooltipContainer    = Exts.Lazy(() => Ui.Root.Get <TooltipContainerWidget>(TooltipContainer));
            CurrentBrush        = DefaultBrush = new EditorDefaultBrush(this, worldRenderer);
            editorActionManager = world.WorldActor.Trait <EditorActionManager>();

            editorActionManager.OnChange += EditorActionManagerOnChange;

            // Allow zooming out to full map size
            worldRenderer.Viewport.UnlockMinimumZoom(0.25f);
        }
コード例 #5
0
 public EditorViewportControllerWidget(World world, WorldRenderer worldRenderer)
 {
     this.worldRenderer = worldRenderer;
     tooltipContainer   = Exts.Lazy(() => Ui.Root.Get <TooltipContainerWidget>(TooltipContainer));
     CurrentBrush       = defaultBrush = new EditorDefaultBrush(this, worldRenderer);
 }
コード例 #6
0
		public EditorViewportControllerWidget(World world, WorldRenderer worldRenderer)
		{
			this.worldRenderer = worldRenderer;
			tooltipContainer = Exts.Lazy(() => Ui.Root.Get<TooltipContainerWidget>(TooltipContainer));
			CurrentBrush = defaultBrush = new EditorDefaultBrush(this, worldRenderer);
		}
コード例 #7
0
        public void SetBrush(IEditorBrush brush)
        {
            CurrentBrush?.Dispose();

            CurrentBrush = brush ?? DefaultBrush;
        }
コード例 #8
0
 public void SetBrush(IEditorBrush brush)
 {
     CurrentBrush = brush ?? defaultBrush;
 }
コード例 #9
0
 public void SetBrush(IEditorBrush brush)
 {
     CurrentBrush = brush ?? defaultBrush;
 }