예제 #1
0
        /// <summary>
        /// Standard TreeView item handler --- navigate to the
        /// "Tag" object if it is not null.
        /// </summary>
        void standard_tv_item_handler(object sender, RoutedEventArgs e)
        {
            e.Handled = true;
            TreeViewItem tv_item = (TreeViewItem)sender;

            if (tv_item.Tag == null)
            {
                return;
            }

            Page page = (Page)tv_item.Tag;

            Output_frame.Navigate(page);
        }
예제 #2
0
        /// <summary>
        /// TreeView item handler for editing backup nodes --- navigate
        /// to the edit_backup_page and initialize it with the backup
        /// object that is stored inside the "Tag" parameter.
        /// </summary>
        void backup_tv_item_handler(object sender, RoutedEventArgs e)
        {
            e.Handled = true;
            TreeViewItem tv_item = (TreeViewItem)sender;

            if (tv_item.Tag == null)
            {
                return;
            }

            Backup backup = (Backup)tv_item.Tag;

            edit_backup_page.load_backup(backup);
            Output_frame.Navigate(edit_backup_page);
        }