2 /// \file ContactEditDlg.h
3 /// Dialog class to handle the editing of the Contact record
7 Copyright (C) 2011-2013, Net Direct Inc. (http://www.netdirect.ca/)
9 This program is free software; you can redistribute it and/or modify
10 it under the terms of the GNU General Public License as published by
11 the Free Software Foundation; either version 2 of the License, or
12 (at your option) any later version.
14 This program is distributed in the hope that it will be useful,
15 but WITHOUT ANY WARRANTY; without even the implied warranty of
16 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
18 See the GNU General Public License in the COPYING file at the
19 root directory of this project for more details.
22 #ifndef __BARRYDESKTOP_CONTACT_EDIT_DLG_H__
23 #define __BARRYDESKTOP_CONTACT_EDIT_DLG_H__
25 #include "StringSync.h"
27 #include <barry/barry.h>
28 // begin wxGlade: ::dependencies
29 #include <wx/statline.h>
32 // begin wxGlade: ::extracode
35 class ContactPhotoWidget
;
37 class ContactEditDlg
: public wxDialog
40 // begin wxGlade: ContactEditDlg::ids
44 Barry::Contact
&m_rec
;
45 std::string m_email_list
;
48 // begin wxGlade: ContactEditDlg::methods
49 void set_properties();
54 // begin wxGlade: ContactEditDlg::attributes
55 wxStaticBox
* sizer_8_staticbox
;
56 wxStaticBox
* sizer_7_staticbox
;
57 wxStaticBox
* sizer_2_staticbox
;
58 wxStaticBox
* sizer_6_staticbox
;
59 wxStaticBox
* sizer_5_staticbox
;
60 wxStaticBox
* sizer_9_staticbox
;
61 ContactPhotoWidget
* m_photo
;
62 wxStaticText
* label_13
;
64 wxStaticText
* FirstNameStatic
;
65 wxTextCtrl
* FirstName
;
66 wxStaticText
* LastNameStatic
;
68 wxStaticText
* label_14
;
70 wxStaticText
* label_15
;
72 wxStaticText
* label_9
;
74 wxStaticText
* label_1
;
75 wxTextCtrl
* HomeAddress1
;
76 wxTextCtrl
* HomeAddress2
;
77 wxTextCtrl
* HomeAddress3
;
78 wxStaticText
* label_2
;
80 wxStaticText
* label_3
;
81 wxTextCtrl
* HomeProvince
;
82 wxStaticText
* label_4
;
83 wxTextCtrl
* HomePostalCode
;
84 wxStaticText
* label_5
;
85 wxTextCtrl
* HomeCountry
;
86 wxStaticLine
* static_line_1
;
87 wxStaticLine
* static_line_2
;
88 wxStaticText
* label_6
;
89 wxTextCtrl
* HomePhone
;
90 wxStaticText
* label_7
;
91 wxTextCtrl
* HomePhone2
;
92 wxStaticText
* label_8
;
94 wxStaticText
* label_1_copy
;
95 wxTextCtrl
* WorkAddress1
;
96 wxTextCtrl
* WorkAddress2
;
97 wxTextCtrl
* WorkAddress3
;
98 wxStaticText
* label_2_copy
;
100 wxStaticText
* label_3_copy
;
101 wxTextCtrl
* WorkProvince
;
102 wxStaticText
* label_4_copy
;
103 wxTextCtrl
* WorkPostalCode
;
104 wxStaticText
* label_5_copy
;
105 wxTextCtrl
* WorkCountry
;
106 wxStaticLine
* static_line_1_copy
;
107 wxStaticLine
* static_line_2_copy
;
108 wxStaticText
* label_6_copy
;
109 wxTextCtrl
* WorkPhone
;
110 wxStaticText
* label_7_copy
;
111 wxTextCtrl
* WorkPhone2
;
112 wxStaticText
* label_8_copy
;
114 wxStaticText
* label_17
;
115 wxTextCtrl
* text_ctrl_9
;
116 wxStaticText
* label_18
;
117 wxTextCtrl
* text_ctrl_1
;
118 wxStaticText
* label_19
;
119 wxTextCtrl
* text_ctrl_2
;
120 wxStaticText
* label_20
;
121 wxTextCtrl
* text_ctrl_3
;
122 wxStaticText
* label_21
;
123 wxTextCtrl
* text_ctrl_4
;
124 wxStaticText
* label_22
;
125 wxTextCtrl
* text_ctrl_5
;
126 wxStaticText
* label_23
;
127 wxTextCtrl
* text_ctrl_6
;
128 wxStaticText
* label_24
;
129 wxTextCtrl
* text_ctrl_7
;
130 wxStaticText
* label_25
;
131 wxTextCtrl
* text_ctrl_8
;
132 wxStaticText
* label_10
;
133 wxTextCtrl
* MobilePhone
;
134 wxStaticText
* label_11
;
135 wxTextCtrl
* MobilePhone2
;
136 wxStaticText
* label_12
;
139 wxStaticText
* label_16
;
143 wxSizer
*bottom_buttons
;
145 DECLARE_EVENT_TABLE(); // sets to protected:
148 ContactEditDlg(wxWindow
*parent
, Barry::Contact
&rec
, bool editable
);
152 void OnPhotoButton(wxCommandEvent
&event
);
153 virtual bool TransferDataFromWindow();