示例#1
0
        private void add_Click(object sender, RoutedEventArgs e)
        {
            FilesWindow fwindow = new FilesWindow();

            fwindow.Owner  = MainWindow.MWindow;
            fwindow.number = -1;
            fwindow.setlist(ref filelist);
            fwindow.Show();
        }
示例#2
0
 private void edit_Click(object sender, RoutedEventArgs e)
 {
     if (filelist.SelectedIndex >= 0)
     {
         FilesWindow fwindow = new FilesWindow();
         fwindow.Owner  = MainWindow.MWindow;
         fwindow.number = filelist.SelectedIndex;
         fwindow.setlist(ref filelist);
         fwindow.file    = MainWindow.files[filelist.SelectedIndex].Name;
         fwindow.content = MainWindow.files[filelist.SelectedIndex].Content;
         fwindow.time    = MainWindow.files[filelist.SelectedIndex].Time;
         fwindow.Show();
     }
 }