示例#1
0
 public FileTypeRadio(NewFileWin frame, string text, string groupName)
 {
     m_frame = frame;
     InitializeComponent();
     mx_radio.Content = text;
     mx_radio.GroupName = groupName;
 }
示例#2
0
 public NewFileWin(string path, bool isProj = false)
 {
     s_pW = this;
     m_curFileType = null;
     m_isProj = isProj;
     InitializeComponent();
     this.Owner = MainWindow.s_pW;
     if (isProj)
     {
         mx_projFrame.Visibility = System.Windows.Visibility.Visible;
         mx_fileFrame.Visibility = System.Windows.Visibility.Collapsed;
     }
     else
     {
         mx_projFrame.Visibility = System.Windows.Visibility.Collapsed;
         mx_fileFrame.Visibility = System.Windows.Visibility.Visible;
     }
     if (Directory.Exists(path))
     {
         m_tmplPath = path;
         refreshFolder(m_tmplPath, mx_tree, m_isProj, true, true, addTmplToRadioGroup);
     }
     else
     {
         MessageBox.Show("模板目录(" + path + ")不存在,UI编辑器可能已经损坏。", "错误", MessageBoxButton.OK, MessageBoxImage.Error);
     }
 }
示例#3
0
 private void mx_newFile_Click(object sender, RoutedEventArgs e)
 {
     NewFileWin winNewFile = new NewFileWin(".\\data\\Template\\");
     winNewFile.ShowDialog();
 }
示例#4
0
 private void mx_root_Unloaded(object sender, RoutedEventArgs e)
 {
     s_pW = null;
 }