Пример #1
0
        private void ShowTextureSelector_Click(object sender, RoutedEventArgs e)
        {
            var texturePreviewSelector = new TexturePreviewSelector();
            var wnd = new ChildWindow(texturePreviewSelector);

            wnd.Owner = this.GetWindow();
            wnd.Show();
        }
Пример #2
0
        private void ShowMeshSelector_Click(object sender, RoutedEventArgs e)
        {
            var meshPreviewSelector = new MeshPreviewSelector();
            var wnd = new ChildWindow(meshPreviewSelector);

            wnd.Owner = this.GetWindow();
            wnd.Show();
        }
Пример #3
0
        private void SelectTexture_Click(object sender, RoutedEventArgs e)
        {
            var wnd = new ChildWindow();

            wnd.Owner = this.GetWindow();

            var textureSelector = new TexturePreviewSelector();

            textureSelector.Canceled += (s, ea) => {
                wnd.Close();
            };
            textureSelector.TextureSelected += (s, ea) => {
                wnd.Close();
                Texture = ea.Value;
            };

            wnd.Content = textureSelector;
            wnd.Show();
        }