コード例 #1
0
        void ControllerMainStoreWindow_SaveButtonClicked(object sender, ObjectEventArgs e)
        {
            string message;

            string path = (string)e.Data;

            if (!ControllerXMLManager.TrySerializeToXML(path, controllerBookStore, out message))
            {
                ControlerMessager.ShowMessage(message);
            }
        }
コード例 #2
0
        void ControllerMainStoreWindow_OpenButtonClicked(object sender, ObjectEventArgs e)
        {
            string message;

            string path = (string)e.Data;

            if (!ControllerXMLManager.TryDeserializeFromXML(path, ref controllerBookStore, out message))
            {
                ControlerMessager.ShowError(message);
            }
            else
            {
                ControllerMainStoreWindow.DGVStoreSource = controllerBookStore.StoreBooksBindingList;
            }
        }
コード例 #3
0
 void ControllerMainStoreWindow_AddButtonClicked(object sender, ObjectEventArgs e)
 {
     controllerBookStore.AddBook((T)e.Data);
 }
コード例 #4
0
 void ControllerMainStoreWindow_DeleteButtonClicked(object sender, ObjectEventArgs e)
 {
     controllerBookStore.RemoveBookAt((int)e.Data);
 }
コード例 #5
0
 void ControllerMainStoreWindow_EditButtonClicked(object sender, ObjectEventArgs e)
 {
     ControllerMainStoreWindow.EditingBook = controllerBookStore.ReturnBookAt((int)e.Data);
 }
コード例 #6
0
 void ControllerMainStoreWindow_ErrorOccurred(object sender, ObjectEventArgs e)
 {
     ControlerMessager.ShowError((string)e.Data);
 }