public UndoEntryInfo(UndoEntry entry)
        {
            InitializeComponent();

            _entry = entry;

            this.Get <TextBlock>("Description").Text = _entry.Description;
        }
Exemple #2
0
        public void Contents_Insert(int index, UndoEntry entry)
        {
            UndoEntryInfo viewer = new UndoEntryInfo(entry);

            viewer.Selected += UndoEntry_Select;

            Contents.Children.Insert(index, viewer);

            if (index <= current)
            {
                current++;
            }
            if (index <= saved)
            {
                saved++;
            }

            Dispatcher.UIThread.Post(() => ScrollViewer.Offset = ScrollViewer.Offset.WithY(Contents.Bounds.Height), DispatcherPriority.Background);
        }
 void Unloaded(object sender, VisualTreeAttachmentEventArgs e)
 {
     Selected = null;
     _entry   = null;
 }