mirror of
https://gitee.com/akwkevin/aistudio.-wpf.-diagram
synced 2026-04-15 05:36:35 +08:00
项目结构调整
This commit is contained in:
30
Others/gong-wpf-dragdrop/src/Showcase/MainWindow.xaml.cs
Normal file
30
Others/gong-wpf-dragdrop/src/Showcase/MainWindow.xaml.cs
Normal file
@@ -0,0 +1,30 @@
|
||||
using System;
|
||||
using System.Linq;
|
||||
using System.Windows.Controls;
|
||||
using System.Windows;
|
||||
using Showcase.WPF.DragDrop.ViewModels;
|
||||
|
||||
namespace Showcase.WPF.DragDrop
|
||||
{
|
||||
/// <summary>
|
||||
/// Interaction logic for MainWindow.xaml
|
||||
/// </summary>
|
||||
public partial class MainWindow : Window
|
||||
{
|
||||
public MainWindow()
|
||||
{
|
||||
InitializeComponent();
|
||||
this.DataContext = new MainViewModel();
|
||||
this.Loaded += MainWindowLoaded;
|
||||
}
|
||||
|
||||
private void MainWindowLoaded(object sender, RoutedEventArgs e)
|
||||
{
|
||||
var appArgs = Environment.GetCommandLineArgs();
|
||||
if (appArgs.Length > 1 && appArgs[1] == "anotherOne")
|
||||
{
|
||||
this.MainTabControl.SelectedItem = MainTabControl.Items.OfType<TabItem>().FirstOrDefault(t => (string)t.Header == "Mixed");
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user