using Elwig.Helpers;
using System.ComponentModel;
using System.Windows;

namespace Elwig.Windows {
    public abstract class ContextWindow : Window {

        protected readonly AppDbContext Context;

        public ContextWindow() : base() {
            Context = new();
        }

        protected override void OnClosing(CancelEventArgs evt) {
            Context.Dispose();
            base.OnClosing(evt);
        }
    }
}