Esempio n. 1
0
        private void OnScaleFactorMessage(ScaleFactorMessage message)
        {
            Action action = () =>
            {
                var dialog = new ScaleFactorDialog(this, message.SizeX, message.SizeY, message.SizeZ);

                if (dialog.ShowDialog() == true)
                {
                    message.ScaleX    = dialog.ScaleX;
                    message.ScaleY    = dialog.ScaleY;
                    message.ScaleZ    = dialog.ScaleZ;
                    message.ScaleType = dialog.ScaleType;
                    message.Changed   = true;
                }
                else
                {
                    message.Changed = false;
                }
            };

            this.Dispatcher.Invoke(action);
        }
        private void OnScaleFactorMessage(ScaleFactorMessage message)
        {
            Action action = () =>
            {
                var dialog = new ScaleFactorDialog(this, message.SizeX, message.SizeY, message.SizeZ);

                if (dialog.ShowDialog() == true)
                {
                    message.ScaleX = dialog.ScaleX;
                    message.ScaleY = dialog.ScaleY;
                    message.ScaleZ = dialog.ScaleZ;
                    message.ScaleType = dialog.ScaleType;
                    message.Changed = true;
                }
                else
                {
                    message.Changed = false;
                }
            };

            this.Dispatcher.Invoke(action);
        }