Saving is called by calling coroutine on Shell (SaveDocument), which is delegated to ActiveItem of TabVM, i.e. The problem is that when document VM is being closed and user chooses to save, I get InvalidOperationException from List's Enumerator, because TabViewModel's Items property changes (LoadSaveVM is shown to handle saving). when document has been changed, it is marked as dirty, thus when closing it, user is asked, if he/she wants to save it, don't save it, or cancel closing.Īll of this is handled through Caliburn.Micro's regular framework ( IGuardClose, DefaultCloseStrategy, Conductor, etc.). Document VM, which is itself Conductor of IScreen objects, however uses child VM to display data of the document.Įverything worked pretty much, until now. VM of document in turn relies on LoadSaveVM for loading and saving of the document. I have shell, which contains TabViewModel (separately as property, and displayed in View through ContentControl).
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |