Home | News | Projects | Releases
Bugs | RFE | Repositories | Help
utf8: Implemented further UTF8 support
[xestiacalendar/.git] / source / widgets / XCCalendarMonthView.h
1 // XCCalendarDayEntry.cpp - Xestia Calendar XCCalendarMonthView widget class.
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 __WIDGETS_XCCALENDARMONTHVIEW_H__
20 #define __WIDGETS_XCCALENDARMONTHVIEW_H__
22 #include <vector>
23 #include <wx/wx.h>
25 #include "colour.h"
26 #include "text.h"
27 #include "events.h"
28 #include "monthviewgen.h"
29 #include "structs.h"
31 #include "../libraries/CalendarDataStorage/CalendarDataStorage.h"
33 #include "XCCalendarMonthView.h"
34 #include "XCCalendarMonthViewDayTitle.h"
35 #include "XCCalendarDay.h"
36 #include "XCEventMenu.h"
38 class XCCalendarDay;
40 class XCCalendarMonthView: public wxPanel
41 {
42         
43         private:
44                 wxFlexGridSizer *windowSizer = new wxFlexGridSizer(0, 7, 1, 1);
45                 vector<XCCalendarDay*> calendarDayList;
46                 XCCalendarMonthViewDayTitle *mondayText = nullptr;
47                 XCCalendarMonthViewDayTitle *tuesdayText = nullptr;
48                 XCCalendarMonthViewDayTitle *wednesdayText = nullptr;
49                 XCCalendarMonthViewDayTitle *thursdayText = nullptr;
50                 XCCalendarMonthViewDayTitle *fridayText = nullptr;
51                 XCCalendarMonthViewDayTitle *saturdayText = nullptr;
52                 XCCalendarMonthViewDayTitle *sundayText = nullptr;
53                 XCEventMenu *eventMenu = nullptr;
54                 CalendarDataStorage *calendarStorage = nullptr;
55                 
56                 void ProcessGrid(XCCalendarMonthViewGrid *grid, std::vector<int> *hideAccounts, std::vector<int> *hideCalendars);
57         
58         protected:
59                 void HideAccountEntries(wxCommandEvent &accountData);
60                 void ShowAccountEntries(wxCommandEvent &accountData);
61                 void HideCalendarEntries(wxCommandEvent &calendarData);
62                 void ShowCalendarEntries(wxCommandEvent &calendarData);
63                 void DeleteCalendarEntries(wxCommandEvent &calendarData);
64                 void DeleteCalendarEntry(wxCommandEvent &eventData);
65                 void AddCalendarEntry(wxCommandEvent &eventData);
66                 void UpdateCalendarEntry(wxCommandEvent &eventData);
67                 void UpdateCalendarColour(wxCommandEvent &colourData);
68                 void ShowEventMenu(wxCommandEvent &eventData);
69         
70         public:
71                 XCCalendarMonthView(wxWindow *parent, const wxString& title, const wxPoint& pos, const wxSize& size, XCCalendarMonthViewGrid *grid, CalendarDataStorage *dataStorage, std::vector<int> *hideAccounts, std::vector<int> *hideCalendars);
72                 ~XCCalendarMonthView();
74                 void ResizeFrameEvent(wxSizeEvent &sizeEvent);
75                 void DeselectOthersEvent(wxCommandEvent &deselectEvent);
76         
77         DECLARE_EVENT_TABLE()
78         
79 };
81 #endif
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