Home | News | Projects | Releases
Bugs | RFE | Repositories | Help
Added copyright and license header to the C++ files and headers in the top source...
[xestiaab/.git] / source / frmMain.h
index 1838300..7c8c625 100644 (file)
@@ -1,3 +1,21 @@
+// frmMain.h - Main window header form.
+//
+// (c) 2012-2015 Xestia Software Development.
+//
+// This file is part of Xestia Address Book.
+//
+// Xestia Address Book is free software: you can redistribute it and/or modify
+// it under the terms of the GNU General Public License as published by the
+// Free Software Foundation, version 3 of the license.
+//
+// Xestia Address Book is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+// GNU General Public License for more details.
+//
+// You should have received a copy of the GNU General Public License along
+// with Xestia Address Book. If not, see <http://www.gnu.org/licenses/>
+
 #ifndef __frmMain__
 #define __frmMain__
 
@@ -22,9 +40,10 @@ Subclass of frmMainADT, which is generated by wxFormBuilder.
 #include "common/timers.h"
 #include "common/events.h"
 #include "common/etag.h"
-#include "widgets/XABAccountView.h"
 #include "bitmaps.h"
 #include "common/sslcertstructs.h"
+#include "widgets/XABContactMenu.h"
+#include "widgets/XABAccountView.h"
 
 //// end generated include
 
@@ -32,7 +51,10 @@ DECLARE_EVENT_TYPE(CE_UPDATECONTACTLIST, wxID_ANY)
 DECLARE_EVENT_TYPE(CE_UPDATEACCOUNTLIST, wxID_ANY)
 DECLARE_EVENT_TYPE(SE_UPDATECONTACTNOTIF, wxID_ANY)
 DECLARE_EVENT_TYPE(CE_OPENCONTACT, wxID_ANY)
+DECLARE_EVENT_TYPE(CE_OPENCONTACTLIST, wxID_ANY)
+DECLARE_EVENT_TYPE(CE_NEWCONTACT, wxID_ANY)
 DECLARE_EVENT_TYPE(CE_EDITCONTACT, wxID_ANY)
+DECLARE_EVENT_TYPE(CE_DELETECONTACT, wxID_ANY)
 DECLARE_EVENT_TYPE(CE_REVEALCONTACT, wxID_ANY)
 DECLARE_EVENT_TYPE(CE_REMOVESEARCH, wxID_ANY)
 DECLARE_EVENT_TYPE(CE_REMOVECONTACT, wxID_ANY)
@@ -48,6 +70,9 @@ DECLARE_EVENT_TYPE(CONNSTAT_UPDATE, wxID_ANY);
 DECLARE_EVENT_TYPE(INVALIDSSLCERT, wxID_ANY);
 DECLARE_EVENT_TYPE(GETSELECTEDLIST, wxID_ANY);
 DECLARE_EVENT_TYPE(SYNCACCOUNT, wxID_ANY);
+DECLARE_EVENT_TYPE(IMPORT_RESULTSSHOW, wxID_ANY);
+DECLARE_EVENT_TYPE(RELOADCONTACTLIST, wxID_ANY);
+DECLARE_EVENT_TYPE(REFRESHADDRESSBOOK, wxID_ANY);
 
 struct UCNotif{
        wxString ContactAccount;
@@ -151,8 +176,10 @@ class frmMain : public frmMainADT
                int ContactUID = 0;
                int ContactEditorUID = 0;
                int WindowMenuItemID = 0;
+               XABContactMenu *ContactMenu = new XABContactMenu(XABCONTACTMENU_MAIN); 
        protected:
                // Handlers for frmMainADT events.
+               void QuitApp( wxCloseEvent& event );
                void QuitApp( wxCommandEvent& event );
                void QuitApp();
                void ShowAboutWindow( wxCommandEvent& event );
@@ -160,14 +187,15 @@ class frmMain : public frmMainADT
                void OpenNewABDialog( wxCommandEvent& event );
                void LoadPreferences( wxActivateEvent& event );
                void LoadPreferences();
-               void LoadContactList( wxTreeEvent& event );
                void ShowContactInfo( wxListEvent& event );
-               void OpenContactInfo( wxListEvent& event );
+               void OpenContactInfoList( wxListEvent& event );
+               void OpenContactInfoList( wxCommandEvent& event );
                void OpenContactInfo( wxCommandEvent& event );
                void ShowContactEditorNew( wxCommandEvent& event );             
                void ShowContactEditorEdit( wxCommandEvent& event );
                void RefreshAddressBook( wxCommandEvent& event );
-               void ShowActivityWindow( wxCommandEvent& event );               
+               void ShowActivityWindow( wxCommandEvent& event );
+               void LoadContactList( wxTreeEvent& event );             
                wxTreeItemId FindItemNamed(wxTreeCtrl &tree, 
                              const std::wstring &name);
                void ConflictResolution( wxCommandEvent& event );
@@ -210,6 +238,8 @@ class frmMain : public frmMainADT
                void GetSelectedList( wxCommandEvent& event );
                void SyncAccount( wxCommandEvent& event );
                void ShowHelp( wxCommandEvent& event );
+               void ShowContactMenu( wxMouseEvent& event );
+               void ProcessMenuItemClick( wxCommandEvent &event );
        public:
                /** Constructor */
                frmMain( wxWindow* parent );
@@ -223,6 +253,8 @@ class frmMain : public frmMainADT
                void ResumeAllTimers();
                void UpdateSSLAccountStatus(int AccountID, int SSLStatus, SSLCertCollection SSLCertInc);
                void GetListControl(wxListCtrl *lstContactsPtr, wxArrayString *ContactsFileIndexPtr);
+               void ShowImportResults( wxCommandEvent& event );
+               void ReloadContactList( wxCommandEvent& event );
                XABViewMode GetViewMode();
                DECLARE_EVENT_TABLE()
 
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