Ejemplo n.º 1
0
        /// <summary>
        /// Invoked when the application is launched normally by the end user.
        /// Database migration is performed if necessary.
        /// </summary>
        private void MigrateDatabase(DeskberryContext db)
        {
            var localPath = ApplicationData.Current.LocalFolder.Path + @"\deskberry.db";
            var fInfo     = new FileInfo(localPath);

            if (!fInfo.Exists)
            {
                db.Database.Migrate();
            }
        }
Ejemplo n.º 2
0
        /// <summary>
        /// Initializes the singleton application object.  This is the first line of authored code
        /// executed, and as such is the logical equivalent of main() or WinMain().
        /// </summary>
        public App()
        {
            // Syncfusion key
            Syncfusion.Licensing.SyncfusionLicenseProvider.RegisterLicense("MjQ3MzU2QDMxMzgyZTMxMmUzMFk3T0E4L09Pb1lyYmpqd25jM3RNNzZmSXVkTFJDeXRhSDNzVEYwQ01MZE09");

            this.InitializeComponent();
            this.Suspending += OnSuspending;

            MainContainer.RegisterService();
            _Context = MainContainer.Container.GetService <DeskberryContext>();
        }
Ejemplo n.º 3
0
 public FavoriteService(DeskberryContext context)
 {
     _context = context;
 }
Ejemplo n.º 4
0
 public AvatarService(DeskberryContext context)
 {
     _context = context;
 }
Ejemplo n.º 5
0
 public HomePageService(DeskberryContext context) => _context = context;
Ejemplo n.º 6
0
 public AccountService(DeskberryContext context)
 {
     _context         = context;
     _passwordManager = new PasswordManager();
 }
Ejemplo n.º 7
0
 public NoteService(DeskberryContext context)
 {
     _context = context;
 }