Home | News | Projects | Releases
Bugs | RFE | Repositories | Help
frmEventEditor: Set calendar ID when editing event
[xestiacalendar/.git] / source / forms / eventeditor / frmEventEditor.h
1 // frmEventEditor.h - frmEventEditor form functions header.
2 //
3 // (c) 2016-2017 Xestia Software Development.
4 //
5 // This file is part of Xestia Calendar.
6 //
7 // Xestia Calendar is free software: you can redistribute it and/or modify
8 // it under the terms of the GNU General Public License as published by the
9 // Free Software Foundation, version 3 of the license.
10 //
11 // Xestia Calendar is distributed in the hope that it will be useful,
12 // but WITHOUT ANY WARRANTY; without even the implied warranty of
13 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 // GNU General Public License for more details.
15 //
16 // You should have received a copy of the GNU General Public License along
17 // with Xestia Calendar. If not, see <http://www.gnu.org/licenses/>
19 #ifndef __frmEventEditor__
20 #define __frmEventEditor__
22 /**
23 @file
24 Subclass of frmEventEditorADT, which is generated by wxFormBuilder.
25 */
27 #include <vector>
28 #include <string>
29 #include <sstream>
31 #include "../../AppXestiaCalendar.h"
33 #include "uuid.h"
34 #include "random.h"
35 #include "structs.h"
36 #include "events.h"
37 #include "dirs.h"
38 #include "preferences.h"
40 #include "../../libraries/CalendarDataStorage/CalendarDataStorage.h"
41 #include "../../objects/calendarevent/CalendarEvent.h"
43 //// end generated include
45 /** Implementing frmEventEditorADT */
46 class frmEventEditor : public frmEventEditorADT
47 {
48         private:
49                 CalendarDataStorage *dataStorage = nullptr;
50                 CalendarEventObject eventData;
51                 vector<int> calendarIDList;
52                 bool editMode = false;
53                 int eventID = 0;
54                 int calendarID = 0;
55                 string eventFilePath;
56                 void SaveContact();
57                 XCALPreferences *preferences;
58                 void SetDefaultDateTime();
59         protected:
60                 void SaveContact(wxCommandEvent &event);
61                 void SaveNewContact(wxCommandEvent &event);
62                 void CloseWindow(wxCommandEvent &event);
63                 void CutText(wxCommandEvent &event);
64                 void CopyText(wxCommandEvent &event);
65                 void PasteText(wxCommandEvent &event);
66                 bool ProcessEvent(wxEvent& event);
67         public:
68                 /** Constructor */
69                 frmEventEditor( wxWindow* parent );
70                 void SetupForm(CalendarDataStorage *dataStorage, XCALPreferences *preferences);
71                 void SetEditMode(bool editMode);
72                 void SetEventID(int eventID);
73         //// end generated class members
74         
75 };
77 #endif // __frmEventEditor__
Xestia Software Development
Yn Maystri
© 2006 - 2019 Xestia Software Development
Software

Xestia Address Book
Xestia Calendar
Development

Xestia Gelforn
Everything else

About
News
Privacy Policy