Ejemplo n.º 1
0
        public void Translate( IControl control, Vector2 translationVector )
        {
            if ( translationVector.Equal( Vector2.Zero, Constans.Epsilon ) )
            {
                return;
            }

            var translationMatrix = Matrix.CreateTranslation( translationVector.ToVector3() );
            if ( this._selectedControls.Contains( control ) )
            {
                this._selectedControls.ForEach( s => s.TranslateWithoutNotification( translationMatrix ) );
                this._selectedControls.ForEach( s => s.Invalidate() );
            }
            else
            {
                control.Translate( translationMatrix );
            }
        }