Example #1
0
        public NotesVM()
        {
            NewNoteCommand         = new NewNoteCommand(this);
            NewNotebookCommand     = new NewNotebookCommand(this);
            ExitCommand            = new ExitCommand(this);
            DeleteNoteCommand      = new DeleteNoteCommand(this);
            DeleteNotebookCommand  = new DeleteNotebookCommand(this);
            RenameNoteCommand      = new RenameNoteCommand(this);
            RenameNotebookCommand  = new RenameNotebookCommand(this);
            SaveNoteContentCommand = new SaveNoteContentCommand(this);

            Notes     = new ObservableCollection <Note>();
            Notebooks = new ObservableCollection <Notebook>();

            //TODO: Implement genuine login functionality.
            CurrentUser = new User()
            {
                Id        = 1,
                FirstName = "Alex",
                LastName  = "Barker",
                Username  = "******",
                Email     = "*****@*****.**",
                Password  = "******"
            };

            ReadNotebooks();
        }
Example #2
0
        public NotesVM()
        {
            NewNotebookCommand = new NewNotebookCommand(this);
            NewNoteCommand     = new NewNoteCommand(this);
            Notebooks          = new ObservableCollection <Notebook>();
            Notes = new ObservableCollection <Note>();

            ReadNotebooks();
        }
Example #3
0
        public NotesVM()
        {
            IsEditing          = false;
            NewNotebookCommand = new NewNotebookCommand(this);
            NewNoteCommand     = new NewNoteCommand(this);
            BeginEditCommand   = new BeginEditCommand(this);
            HasEditedCommand   = new HasEditedCommand(this);
            Notebooks          = new ObservableCollection <Notebook>();
            Notes = new ObservableCollection <Note>();

            ReadNotebooks();
            ReadNotes();
        }
Example #4
0
        public NotesVM()
        {
            NewNotebookCommand = new NewNotebookCommand(this);
            NewNoteCommand     = new NewNoteCommand(this);
            BeginEditCommand   = new BeginEditCommand(this);
            HasEditedCommand   = new HasEditedCommand(this);
            DeleteCommand      = new DeleteCommand(this);

            Notebooks = new ObservableCollection <Notebook>();
            Notes     = new ObservableCollection <Note>();

            //ReadNotebooks();
            //ReadNotes();
        }
Example #5
0
        public NotesVM()
        {
            IsEditing = false; //ContextMenu boolean controller

            NewNotebookCommand = new NewNotebookCommand(this);
            NewNoteCommand     = new NewNoteCommand(this);
            BeginEditCommand   = new BeginEditCommand(this);
            HasEditedCommand   = new HasEditedCommand(this);

            //Inicializamos listas
            Notebooks = new ObservableCollection <NotebookModel>();
            Notes     = new ObservableCollection <NoteModel>();

            //Y leemos nada más empezar de la bbdd
            ReadNotebooks();
            ReadNotes();
        }
Example #6
0
        public NotesVM()
        {
            // create tables in db as first task
            DatabaseHelper.CreateTables <Notebook>();
            DatabaseHelper.CreateTables <Note>();

            NewNotebookCommand        = new NewNotebookCommand(this);
            NewNoteCommand            = new NewNoteCommand(this);
            BeginEditCommand          = new BeginEditCommand(this);
            HasEditedCommand          = new HasEditedCommand(this);
            CancelNotebookEditCommand = new CancelNotebookEditCommand();

            HasEditedNoteCommand  = new HasEditedNoteCommand(this);
            CancelNoteEditCommand = new CancelNoteEditCommand();

            Notebooks = new ObservableCollection <Notebook>();
            Notes     = new ObservableCollection <Note>();
        }
Example #7
0
        public NotesVM()
        {
            IsEditing             = false;
            IsEditingNote         = false;
            NewNotebookCommand    = new NewNotebookCommand(this);
            NewNoteCommand        = new NewNoteCommand(this);
            DeleteNotebookCommand = new DeleteNotebookCommand(this);
            DeleteNoteCommand     = new DeleteNoteCommand(this);
            BeginEditCommand      = new BeginEditCommand(this);
            IsEditedCommand       = new IsEditedCommand(this);
            BeginEditNoteCommand  = new BeginEditNoteCommand(this);
            IsEditedNoteCommand   = new IsEditedNoteCommand(this);

            Notebooks = new ObservableCollection <Notebook>();
            Notes     = new ObservableCollection <Note>();
            FontSizes = new List <double>()
            {
                8, 9, 10, 11, 12, 14, 16, 28, 48, 72
            };

            ReadNotebooks();
            ReadNotes();
        }
Example #8
0
 public NotesVM()
 {
     NewNotebookCommand = new NewNotebookCommand(this);
     NewNoteCommand     = new NewNoteCommand(this);
 }