Home | News | Projects | Releases
Bugs | RFE | Repositories | Help
Indented code properly contacteditor/frmContactEditor-Home.cpp
[xestiaab/.git] / source / contacteditor / frmContactEditor-Home.cpp
1 // frmContactEditor-Home.cpp - frmContactEditor Home tab subroutines.
2 //
3 // (c) 2012-2016 Xestia Software Development.
4 //
5 // This file is part of Xestia Address Book.
6 //
7 // Xestia Address Book 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 Address Book 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 Address Book. If not, see <http://www.gnu.org/licenses/>
19 #include "frmContactEditor.h"
20 #include "frmContactEditorNickname.h"
21 #include "frmContactEditorAddress.h"
22 #include "frmContactEditorEmail.h"
23 #include "frmContactEditorIM.h"
24 #include "frmContactEditorTelephone.h"
25 #include "frmContactEditorLanguages.h"
26 #include "frmContactEditorTimezones.h"
27 #include "frmContactEditorRelated.h"
28 #include "frmContactEditorWebsites.h"
29 #include "frmContactEditorTitles.h"
30 #include "frmContactEditorRoles.h"
31 #include "frmContactEditorGeoposition.h"
32 #include "frmContactEditorGroups.h"
33 #include "frmContactEditorOrganisations.h"
34 #include "frmContactEditorNotes.h"
36 void frmContactEditor::AddHomeNickname( wxCommandEvent& event )
37 {
38         
39         int intResult = 0;
40     
41         frmContactEditorNickname *frameCENickname = new frmContactEditorNickname ( this );
42         frameCENickname->SetEditorMode(FALSE, CE_HOME);
43         intResult = GetLastInt(&ContactEditorData.HomeNicknamesList);
44         frameCENickname->SetupPointers(&ContactEditorData.HomeNicknamesList,
45                 &ContactEditorData.HomeNicknamesListAltID,
46                 &ContactEditorData.HomeNicknamesListPID,
47                 &ContactEditorData.HomeNicknamesListType,
48                 &ContactEditorData.HomeNicknamesListLanguage,
49                 &ContactEditorData.HomeNicknamesListTokens,
50                 &ContactEditorData.HomeNicknamesListPref,
51                 lboHomeNicknames,
52                 (intValueSeek));
53         frameCENickname->ShowModal();
54         delete frameCENickname;
55         frameCENickname = NULL;
56         
57 }
59 void frmContactEditor::ModifyHomeNickname( wxCommandEvent& event )
60 {
61         
62         long longSelected = -1;
63         int intSelectedData = 0;
64     
65         if (!GetSelectedItem(lboHomeNicknames,
66                 &longSelected,
67                 &intSelectedData)){
68                 return;
69         }
70     
71         frmContactEditorNickname *frameCENickname = new frmContactEditorNickname ( this );
72         frameCENickname->SetupPointers(&ContactEditorData.HomeNicknamesList,
73                 &ContactEditorData.HomeNicknamesListAltID,
74                 &ContactEditorData.HomeNicknamesListPID,
75                 &ContactEditorData.HomeNicknamesListType,
76                 &ContactEditorData.HomeNicknamesListLanguage,
77                 &ContactEditorData.HomeNicknamesListTokens,
78                 &ContactEditorData.HomeNicknamesListPref,
79                 lboHomeNicknames,
80                 intSelectedData);
81         frameCENickname->SetEditorMode(TRUE, CE_HOME);
82         frameCENickname->ShowModal();
83         delete frameCENickname;
84         frameCENickname = NULL;
85         
86 }
88 void frmContactEditor::DeleteHomeNickname( wxCommandEvent& event )
89 {
90     
91         long longSelected = -1;
92         int intSelectedData = 0;
93     
94         if (!GetSelectedItem(lboHomeNicknames,
95                 &longSelected,
96                 &intSelectedData)){
97                 return;
98         }
99     
100         lboHomeNicknames->DeleteItem(longSelected);
101     
102         DeleteMapData(intSelectedData,
103                 &ContactEditorData.HomeNicknamesList,
104                 &ContactEditorData.HomeNicknamesListLanguage,
105                 &ContactEditorData.HomeNicknamesListAltID,
106                 &ContactEditorData.HomeNicknamesListPID,
107                 &ContactEditorData.HomeNicknamesListTokens,
108                 &ContactEditorData.HomeNicknamesListType,
109                 &ContactEditorData.HomeNicknamesListPref);
113 void frmContactEditor::AddHomeAddress( wxCommandEvent& event )
115         
116         int intResult = 0;
117     
118         frmContactEditorAddress *frameCEAddress = new frmContactEditorAddress ( this );
119         frameCEAddress->SetEditorMode(FALSE, CE_HOME);
120         intResult = GetLastInt(&ContactEditorData.HomeAddressList);
121         frameCEAddress->SetupPointers(&ContactEditorData.HomeAddressList,
122                 &ContactEditorData.HomeAddressListTown,
123                 &ContactEditorData.HomeAddressListCounty,
124                 &ContactEditorData.HomeAddressListPostCode,
125                 &ContactEditorData.HomeAddressListCountry,
126                 &ContactEditorData.HomeAddressListLabel,
127                 &ContactEditorData.HomeAddressListLang,
128                 &ContactEditorData.HomeAddressListAltID,
129                 &ContactEditorData.HomeAddressListPID,
130                 &ContactEditorData.HomeAddressListTokens,
131                 &ContactEditorData.HomeAddressListGeo,
132                 &ContactEditorData.HomeAddressListTimezone,
133                 &ContactEditorData.HomeAddressListType,
134                 &ContactEditorData.HomeAddressListMediatype,
135                 &ContactEditorData.HomeAddressListPref,
136                 lboHomeAddresses,
137                 (intValueSeek));
138         frameCEAddress->ShowModal();
139         delete frameCEAddress;
140         frameCEAddress = NULL;
141         
144 void frmContactEditor::ModifyHomeAddress( wxCommandEvent& event )
146         
147         long longSelected = -1;
148         int intSelectedData = 0;
149     
150         if (!GetSelectedItem(lboHomeAddresses,
151                 &longSelected,
152                 &intSelectedData)){
153                 return;
154         }
155     
156         frmContactEditorAddress *frameCEAddress = new frmContactEditorAddress ( this );
157         frameCEAddress->SetupPointers(&ContactEditorData.HomeAddressList,
158                 &ContactEditorData.HomeAddressListTown,
159                 &ContactEditorData.HomeAddressListCounty,
160                 &ContactEditorData.HomeAddressListPostCode,
161                 &ContactEditorData.HomeAddressListCountry,
162                 &ContactEditorData.HomeAddressListLabel,
163                 &ContactEditorData.HomeAddressListLang,
164                 &ContactEditorData.HomeAddressListAltID,
165                 &ContactEditorData.HomeAddressListPID,
166                 &ContactEditorData.HomeAddressListTokens,
167                 &ContactEditorData.HomeAddressListGeo,
168                 &ContactEditorData.HomeAddressListTimezone,
169                 &ContactEditorData.HomeAddressListType,
170                 &ContactEditorData.HomeAddressListMediatype,
171                 &ContactEditorData.HomeAddressListPref,
172                 lboHomeAddresses,
173                 intSelectedData);
174         frameCEAddress->SetEditorMode(TRUE, CE_HOME);
175         frameCEAddress->ShowModal();
176         delete frameCEAddress;
177         frameCEAddress = NULL;
178         
181 void frmContactEditor::DeleteHomeAddress( wxCommandEvent& event )
183     
184         long longSelected = -1;
185         int intSelectedData = 0;
186     
187         if (!GetSelectedItem(lboHomeAddresses,
188                 &longSelected,
189                 &intSelectedData)){
190                 return;
191         }
192     
193         lboHomeAddresses->DeleteItem(longSelected);
194     
195         DeleteMapData(intSelectedData, &ContactEditorData.HomeAddressList,
196                 &ContactEditorData.HomeAddressListTown, &ContactEditorData.HomeAddressListCounty,
197                 &ContactEditorData.HomeAddressListPostCode, &ContactEditorData.HomeAddressListCountry,
198                 &ContactEditorData.HomeAddressList, &ContactEditorData.HomeAddressListLabel,
199                 &ContactEditorData.HomeAddressListLang, &ContactEditorData.HomeAddressListAltID,
200                 &ContactEditorData.HomeAddressListPID, &ContactEditorData.HomeAddressListTokens,
201                 &ContactEditorData.HomeAddressListGeo, &ContactEditorData.HomeAddressListTimezone,
202                 &ContactEditorData.HomeAddressListType, &ContactEditorData.HomeAddressListMediatype,
203                 &ContactEditorData.HomeAddressListPref);
204     
207 void frmContactEditor::AddHomeEmail( wxCommandEvent& event )
209         
210         int intResult = 0;
211     
212         frmContactEditorEmail *frameCEEmail = new frmContactEditorEmail ( this );
213         frameCEEmail->SetEditorMode(FALSE, CE_HOME);
214         intResult = GetLastInt(&ContactEditorData.HomeAddressList);
215         frameCEEmail->SetupPointers(&ContactEditorData.HomeEmailList,
216                 &ContactEditorData.HomeEmailListAltID,
217                 &ContactEditorData.HomeEmailListPID,
218                 &ContactEditorData.HomeEmailListType,
219                 &ContactEditorData.HomeEmailListTokens,
220                 &ContactEditorData.HomeEmailListPref,
221                 lboHomeEmails,
222                 (intValueSeek));
223         frameCEEmail->ShowModal();
224         delete frameCEEmail;
225         frameCEEmail = NULL;
226         
229 void frmContactEditor::ModifyHomeEmail( wxCommandEvent& event )
231         
232         long longSelected = -1;
233         int intSelectedData = 0;
234     
235         if (!GetSelectedItem(lboHomeEmails,
236                 &longSelected,
237                 &intSelectedData)){
238                 return;
239         }
240     
241         frmContactEditorEmail *frameCEEmail = new frmContactEditorEmail ( this );
242         frameCEEmail->SetupPointers(&ContactEditorData.HomeEmailList,
243                 &ContactEditorData.HomeEmailListAltID,
244                 &ContactEditorData.HomeEmailListPID,
245                 &ContactEditorData.HomeEmailListType,
246                 &ContactEditorData.HomeEmailListTokens,
247                 &ContactEditorData.HomeEmailListPref,
248                 lboHomeEmails,
249                 intSelectedData);
250         frameCEEmail->SetEditorMode(TRUE, CE_HOME);
251         frameCEEmail->ShowModal();
252         delete frameCEEmail;
253         frameCEEmail = NULL;
254         
258 void frmContactEditor::DeleteHomeEmail( wxCommandEvent& event )
260         
261         long longSelected = -1;
262         int intSelectedData = 0;
263     
264         if (!GetSelectedItem(lboHomeEmails,
265                 &longSelected,
266                 &intSelectedData)){
267                 return;
268         }
269     
270         lboHomeEmails->DeleteItem(longSelected);
271     
272         DeleteMapData(intSelectedData, &ContactEditorData.HomeEmailList,
273                 &ContactEditorData.HomeEmailListAltID, &ContactEditorData.HomeEmailListPID,
274                 &ContactEditorData.HomeEmailListType, &ContactEditorData.HomeEmailListTokens,
275                 &ContactEditorData.HomeEmailListPref);
276         
280 void frmContactEditor::AddHomeIM( wxCommandEvent& event )
282         
283         int intResult = 0;
284     
285         frmContactEditorIM *frameCEIM = new frmContactEditorIM ( this );
286         frameCEIM->SetEditorMode(FALSE, CE_HOME);
287         intResult = GetLastInt(&ContactEditorData.HomeIMList);
288         frameCEIM->SetupPointers(&ContactEditorData.HomeIMList,
289                 &ContactEditorData.HomeIMListAltID,
290                 &ContactEditorData.HomeIMListPID,
291                 &ContactEditorData.HomeIMListType,
292                 &ContactEditorData.HomeIMListTypeInfo,
293                 &ContactEditorData.HomeIMListTokens,
294                 &ContactEditorData.HomeIMListMediatype,
295                 &ContactEditorData.HomeIMListPref,
296                 lboHomeIM,
297                 (intValueSeek));
298         frameCEIM->ShowModal();
299         delete frameCEIM;
300         frameCEIM = NULL;
301         
304 void frmContactEditor::ModifyHomeIM( wxCommandEvent& event )
306         
307         long longSelected = -1;
308         int intSelectedData = 0;
309     
310         if (!GetSelectedItem(lboHomeIM,
311                 &longSelected,
312                 &intSelectedData)){
313                 return;
314         }
315     
316         frmContactEditorIM *frameCEIM = new frmContactEditorIM ( this );
317         frameCEIM->SetupPointers(&ContactEditorData.HomeIMList,
318                 &ContactEditorData.HomeIMListAltID,
319                 &ContactEditorData.HomeIMListPID,
320                 &ContactEditorData.HomeIMListType,
321                 &ContactEditorData.HomeIMListTypeInfo,
322                 &ContactEditorData.HomeIMListTokens,
323                 &ContactEditorData.HomeIMListMediatype,
324                 &ContactEditorData.HomeIMListPref,
325                 lboHomeIM,
326                 intSelectedData);
327         frameCEIM->SetEditorMode(TRUE, CE_HOME);
328         frameCEIM->ShowModal();
329         delete frameCEIM;
330         frameCEIM = NULL;
331     
334 void frmContactEditor::DeleteHomeIM( wxCommandEvent& event )
337         long longSelected = -1;
338         int intSelectedData = 0;
339     
340         if (!GetSelectedItem(lboHomeIM,
341                 &longSelected,
342                 &intSelectedData)){
343                 return;
344         }
345     
346         lboHomeIM->DeleteItem(longSelected);
347     
348         DeleteMapData(intSelectedData, &ContactEditorData.HomeIMList,
349                 &ContactEditorData.HomeIMListAltID, &ContactEditorData.HomeIMListPID,
350                 &ContactEditorData.HomeIMListType, &ContactEditorData.HomeIMListTypeInfo,
351                 &ContactEditorData.HomeIMListTokens, &ContactEditorData.HomeIMListMediatype, 
352                 &ContactEditorData.HomeIMListPref);
353     
356 void frmContactEditor::AddHomeTelephone( wxCommandEvent& event )
358         
359         int intResult = 0;
360     
361         frmContactEditorTelephone *frameCETel = new frmContactEditorTelephone ( this );
362         frameCETel->SetEditorMode(FALSE, CE_HOME);
363         intResult = GetLastInt(&ContactEditorData.HomeTelephoneList);
364         frameCETel->SetupPointers(&ContactEditorData.HomeTelephoneList,
365                 &ContactEditorData.HomeTelephoneListAltID,
366                 &ContactEditorData.HomeTelephoneListPID,
367                 &ContactEditorData.HomeTelephoneListType,
368                 &ContactEditorData.HomeTelephoneListTypeInfo,
369                 &ContactEditorData.HomeTelephoneListTokens,
370                 &ContactEditorData.HomeTelephoneListPref,
371                 lboHomeTelephone,
372                 (intValueSeek));
373         frameCETel->ShowModal();
374         delete frameCETel;
375         frameCETel = NULL;
376         
379 void frmContactEditor::ModifyHomeTelephone( wxCommandEvent& event )
381         
382         long longSelected = -1;
383         int intSelectedData = 0;
384     
385         if (!GetSelectedItem(lboHomeTelephone,
386                 &longSelected,
387                 &intSelectedData)){
388                 return;
389         }
390     
391         frmContactEditorTelephone *frameCETel = new frmContactEditorTelephone ( this );
392         frameCETel->SetupPointers(&ContactEditorData.HomeTelephoneList,
393                 &ContactEditorData.HomeTelephoneListAltID,
394                 &ContactEditorData.HomeTelephoneListPID,
395                 &ContactEditorData.HomeTelephoneListType,
396                 &ContactEditorData.HomeTelephoneListTypeInfo,
397                 &ContactEditorData.HomeTelephoneListTokens,
398                 &ContactEditorData.HomeTelephoneListPref,
399                 lboHomeTelephone,
400                 intSelectedData);
401         frameCETel->SetEditorMode(TRUE, CE_HOME);
402         frameCETel->ShowModal();
403         delete frameCETel;
404         frameCETel = NULL;
405         
406 }       
408 void frmContactEditor::DeleteHomeTelephone( wxCommandEvent& event )
410         
411         long longSelected = -1;
412         int intSelectedData = 0;
413     
414         if (!GetSelectedItem(lboHomeTelephone,
415                 &longSelected,
416                 &intSelectedData)){
417                 return;
418         }
419     
420         lboHomeTelephone->DeleteItem(longSelected);
421     
422         DeleteMapData(intSelectedData, &ContactEditorData.HomeTelephoneList,
423                 &ContactEditorData.HomeTelephoneListAltID, &ContactEditorData.HomeTelephoneListPID,
424                 &ContactEditorData.HomeTelephoneListType, &ContactEditorData.HomeTelephoneListTypeInfo,
425                 &ContactEditorData.HomeTelephoneListTokens, &ContactEditorData.HomeTelephoneListPref);
426     
429 void frmContactEditor::AddHomeLanguage( wxCommandEvent& event )
431         int intResult = 0;
432     
433         frmContactEditorLanguages *frameCELang = new frmContactEditorLanguages ( this );
434         frameCELang->SetEditorMode(FALSE, CE_HOME);
435         intResult = GetLastInt(&ContactEditorData.HomeLanguageList);
436         
437         frameCELang->SetupPointers(&ContactEditorData.HomeLanguageList,
438                 &ContactEditorData.HomeLanguageListAltID,
439                 &ContactEditorData.HomeLanguageListPID,
440                 &ContactEditorData.HomeLanguageListType,
441                 &ContactEditorData.HomeLanguageListTokens,
442                 &ContactEditorData.HomeLanguageListPref,
443                 lboHomeLanguages,
444                 (intValueSeek));
445         frameCELang->ShowModal();
446         delete frameCELang;
447         frameCELang = NULL;
448         
451 void frmContactEditor::ModifyHomeLanguage( wxCommandEvent& event )
453         
454         long longSelected = -1;
455         int intSelectedData = 0;
456     
457         if (!GetSelectedItem(lboHomeLanguages,
458                 &longSelected,
459                 &intSelectedData)){
460                 return;
461         }
462     
463         frmContactEditorLanguages *frameCELang = new frmContactEditorLanguages ( this );
464         frameCELang->SetupPointers(&ContactEditorData.HomeLanguageList,
465                 &ContactEditorData.HomeLanguageListAltID,
466                 &ContactEditorData.HomeLanguageListPID,
467                 &ContactEditorData.HomeLanguageListType,
468                 &ContactEditorData.HomeLanguageListTokens,
469                 &ContactEditorData.HomeLanguageListPref,
470                 lboHomeLanguages,
471                 intSelectedData);
472         frameCELang->SetEditorMode(TRUE, CE_HOME);
473         frameCELang->ShowModal();
474         delete frameCELang;
475         frameCELang = NULL;
476         
479 void frmContactEditor::DeleteHomeLanguage( wxCommandEvent& event )
481         
482         long longSelected = -1;
483         int intSelectedData = 0;
484     
485         if (!GetSelectedItem(lboHomeLanguages,
486                 &longSelected,
487                 &intSelectedData)){
488                 return;
489         }
490     
491         lboHomeLanguages->DeleteItem(longSelected);
492     
493         DeleteMapData(intSelectedData, &ContactEditorData.HomeLanguageList,
494                 &ContactEditorData.HomeLanguageListAltID, &ContactEditorData.HomeLanguageListPID,
495                 &ContactEditorData.HomeLanguageListType, &ContactEditorData.HomeLanguageListTokens,
496                 &ContactEditorData.HomeLanguageListPref);
497     
500 void frmContactEditor::AddHomeTimezone( wxCommandEvent& event )
502         
503         int intResult = 0;
504     
505         frmContactEditorTimezones *frameCETZ = new frmContactEditorTimezones ( this );
506         frameCETZ->SetEditorMode(FALSE, CE_HOME);
507         intResult = GetLastInt(&ContactEditorData.HomeTZList);
508         frameCETZ->SetupPointers(&ContactEditorData.HomeTZList,
509                 &ContactEditorData.HomeTZListAltID,
510                 &ContactEditorData.HomeTZListPID,
511                 &ContactEditorData.HomeTZListType,
512                 &ContactEditorData.HomeTZListTokens,
513                 &ContactEditorData.HomeTZListMediatype,
514                 &ContactEditorData.HomeTZListPref,
515                 lboHomeTimezones,
516                 (intValueSeek));
517         frameCETZ->ShowModal();
518         delete frameCETZ;
519         frameCETZ = NULL;
520         
523 void frmContactEditor::ModifyHomeTimezone( wxCommandEvent& event )
525         
526         long longSelected = -1;
527         int intSelectedData = 0;
528     
529         if (!GetSelectedItem(lboHomeTimezones,
530                 &longSelected,
531                 &intSelectedData)){
532                 return;
533         }
534     
535         frmContactEditorTimezones *frameCETZ = new frmContactEditorTimezones ( this );
536         frameCETZ->SetupPointers(&ContactEditorData.HomeTZList,
537                 &ContactEditorData.HomeTZListAltID,
538                 &ContactEditorData.HomeTZListPID,
539                 &ContactEditorData.HomeTZListType,
540                 &ContactEditorData.HomeTZListTokens,
541                 &ContactEditorData.HomeTZListMediatype,
542                 &ContactEditorData.HomeTZListPref,
543                 lboHomeTimezones,
544                 intSelectedData);
545         frameCETZ->SetEditorMode(TRUE, CE_HOME);
546         frameCETZ->ShowModal();
547         delete frameCETZ;
548         frameCETZ = NULL;
549         
552 void frmContactEditor::DeleteHomeTimezone( wxCommandEvent& event )
554         long longSelected = -1;
555         int intSelectedData = 0;
556     
557         if (!GetSelectedItem(lboHomeTimezones,
558                 &longSelected,
559                 &intSelectedData)){
560                 return;
561         }
562     
563         lboHomeTimezones->DeleteItem(longSelected);
564     
565         DeleteMapData(intSelectedData, &ContactEditorData.HomeTZList,
566                 &ContactEditorData.HomeTZListAltID, &ContactEditorData.HomeTZListPID,
567                 &ContactEditorData.HomeTZListType, &ContactEditorData.HomeTZListTokens,
568                 &ContactEditorData.HomeTZListMediatype, &ContactEditorData.HomeTZListPref);
569     
572 void frmContactEditor::AddHomeGeoposition( wxCommandEvent& event )
574         
575         int intResult = 0;
576     
577         frmContactEditorGeoposition *frameCEGeo = new frmContactEditorGeoposition ( this );
578         frameCEGeo->SetEditorMode(FALSE, CE_HOME);
579         intResult = GetLastInt(&ContactEditorData.HomeGeographyList);
580         frameCEGeo->SetupPointers(&ContactEditorData.HomeGeographyList,
581                 &ContactEditorData.HomeGeographyListAltID,
582                 &ContactEditorData.HomeGeographyListPID,
583                 &ContactEditorData.HomeGeographyListType,
584                 &ContactEditorData.HomeGeographyListDataType,
585                 &ContactEditorData.HomeGeographyListTokens,
586                 &ContactEditorData.HomeGeographyListMediatype,
587                 &ContactEditorData.HomeGeographyListPref,
588                 lboHomeGeoposition,
589                 (intValueSeek));
590         frameCEGeo->ShowModal();
591         delete frameCEGeo;
592         frameCEGeo = NULL;
593         
596 void frmContactEditor::ModifyHomeGeoposition( wxCommandEvent& event )
598         
599         long longSelected = -1;
600         int intSelectedData = 0;
601     
602         if (!GetSelectedItem(lboHomeGeoposition,
603                 &longSelected,
604                 &intSelectedData)){
605                 return;
606         }
607     
608         frmContactEditorGeoposition *frameCEGeo = new frmContactEditorGeoposition ( this );
609         frameCEGeo->SetupPointers(&ContactEditorData.HomeGeographyList,
610                 &ContactEditorData.HomeGeographyListAltID,
611                 &ContactEditorData.HomeGeographyListPID,
612                 &ContactEditorData.HomeGeographyListType,
613                 &ContactEditorData.HomeGeographyListDataType,
614                 &ContactEditorData.HomeGeographyListTokens,
615                 &ContactEditorData.HomeGeographyListMediatype,
616                 &ContactEditorData.HomeGeographyListPref,
617                 lboHomeGeoposition,
618                 intSelectedData);
619         frameCEGeo->SetEditorMode(TRUE, CE_HOME);
620         frameCEGeo->ShowModal();
621         delete frameCEGeo;
622         frameCEGeo = NULL;
623         
626 void frmContactEditor::DeleteHomeGeoposition( wxCommandEvent& event )
628         
629         long longSelected = -1;
630         int intSelectedData = 0;
631     
632         if (!GetSelectedItem(lboHomeGeoposition,
633                 &longSelected,
634                 &intSelectedData)){
635                 return;
636         }
637     
638         lboHomeGeoposition->DeleteItem(longSelected);
639     
640         DeleteMapData(intSelectedData, &ContactEditorData.HomeGeographyList,
641                 &ContactEditorData.HomeGeographyListAltID, &ContactEditorData.HomeGeographyListPID,
642                 &ContactEditorData.HomeGeographyListType, &ContactEditorData.HomeGeographyListTokens,
643                 &ContactEditorData.HomeGeographyListDataType, &ContactEditorData.HomeGeographyListMediatype, 
644                 &ContactEditorData.HomeGeographyListPref);
645     
648 void frmContactEditor::AddHomeWebsite( wxCommandEvent& event )
650         
651         int intResult = 0;
652     
653         frmContactEditorWebsites *frameCEWeb = new frmContactEditorWebsites ( this );
654         frameCEWeb->SetEditorMode(FALSE, CE_HOME);
655         intResult = GetLastInt(&ContactEditorData.HomeWebsiteList);
656         frameCEWeb->SetupPointers(&ContactEditorData.HomeWebsiteList,
657                 &ContactEditorData.HomeWebsiteListAltID,
658                 &ContactEditorData.HomeWebsiteListPID,
659                 &ContactEditorData.HomeWebsiteListType,
660                 &ContactEditorData.HomeWebsiteListTokens,
661                 &ContactEditorData.HomeWebsiteListMediatype,
662                 &ContactEditorData.HomeWebsiteListPref,
663                 lboHomeWebsites,
664                 (intValueSeek));
665         frameCEWeb->ShowModal();
666         delete frameCEWeb;
667         frameCEWeb = NULL;
668         
671 void frmContactEditor::ModifyHomeWebsite( wxCommandEvent& event )
673         
674         long longSelected = -1;
675         int intSelectedData = 0;
676     
677         if (!GetSelectedItem(lboHomeWebsites,
678                 &longSelected,
679                 &intSelectedData)){
680                 return;
681         }
682     
683         frmContactEditorWebsites *frameCEWeb = new frmContactEditorWebsites ( this );
684         frameCEWeb->SetupPointers(&ContactEditorData.HomeWebsiteList,
685                 &ContactEditorData.HomeWebsiteListAltID,
686                 &ContactEditorData.HomeWebsiteListPID,
687                 &ContactEditorData.HomeWebsiteListType,
688                 &ContactEditorData.HomeWebsiteListTokens,
689                 &ContactEditorData.HomeWebsiteListMediatype,
690                 &ContactEditorData.HomeWebsiteListPref,
691                 lboHomeWebsites,
692                 intSelectedData);
693         frameCEWeb->SetEditorMode(TRUE, CE_HOME);
694         frameCEWeb->ShowModal();
695         delete frameCEWeb;
696         frameCEWeb = NULL;
697         
700 void frmContactEditor::DeleteHomeWebsite( wxCommandEvent& event )
702         
703         long longSelected = -1;
704         int intSelectedData = 0;
705     
706         if (!GetSelectedItem(lboHomeWebsites,
707                 &longSelected,
708                 &intSelectedData)){
709                 return;
710         }
711     
712         lboHomeWebsites->DeleteItem(longSelected);
713     
714         DeleteMapData(intSelectedData, &ContactEditorData.HomeWebsiteList,
715                 &ContactEditorData.HomeWebsiteListAltID, &ContactEditorData.HomeWebsiteListPID,
716                 &ContactEditorData.HomeWebsiteListType, &ContactEditorData.HomeWebsiteListTokens,
717                 &ContactEditorData.HomeWebsiteListMediatype, &ContactEditorData.HomeWebsiteListPref);
718     
721 void frmContactEditor::AddHomeTitle( wxCommandEvent& event )
723         
724         int intResult = 0;
725     
726         frmContactEditorTitles *frameCETitle = new frmContactEditorTitles ( this );
727         frameCETitle->SetEditorMode(FALSE, CE_HOME);
728         intResult = GetLastInt(&ContactEditorData.HomeTitleList);
729         frameCETitle->SetupPointers(&ContactEditorData.HomeTitleList,
730                 &ContactEditorData.HomeTitleListLanguage,
731                 &ContactEditorData.HomeTitleListAltID,
732                 &ContactEditorData.HomeTitleListPID,
733                 &ContactEditorData.HomeTitleListType,
734                 &ContactEditorData.HomeTitleListTokens,
735                 &ContactEditorData.HomeTitleListPref,
736                 lboHomeTitles,
737                 (intValueSeek));
738         frameCETitle->ShowModal();
739         delete frameCETitle;
740         frameCETitle = NULL;
741         
744 void frmContactEditor::ModifyHomeTitle( wxCommandEvent& event )
746         
747         long longSelected = -1;
748         int intSelectedData = 0;
749     
750         if (!GetSelectedItem(lboHomeTitles,
751                 &longSelected,
752                 &intSelectedData)){
753                 return;
754         }
755     
756         frmContactEditorTitles *frameCETitle = new frmContactEditorTitles ( this );
757         frameCETitle->SetupPointers(&ContactEditorData.HomeTitleList,
758                 &ContactEditorData.HomeTitleListLanguage,
759                 &ContactEditorData.HomeTitleListAltID,
760                 &ContactEditorData.HomeTitleListPID,
761                 &ContactEditorData.HomeTitleListType,
762                 &ContactEditorData.HomeTitleListTokens,
763                 &ContactEditorData.HomeTitleListPref,
764                 lboHomeTitles,
765                 intSelectedData);
766         frameCETitle->SetEditorMode(TRUE, CE_HOME);
767         frameCETitle->ShowModal();
768         delete frameCETitle;
769         frameCETitle = NULL;
770         
773 void frmContactEditor::DeleteHomeTitle( wxCommandEvent& event )
775         
776         long longSelected = -1;
777         int intSelectedData = 0;
778     
779         if (!GetSelectedItem(lboHomeTitles,
780                 &longSelected,
781                 &intSelectedData)){
782                 return;
783         }
784     
785         lboHomeTitles->DeleteItem(longSelected);
786     
787         DeleteMapData(intSelectedData, &ContactEditorData.HomeTitleList,
788                 &ContactEditorData.HomeTitleListLanguage, &ContactEditorData.HomeTitleListAltID,
789                 &ContactEditorData.HomeTitleListPID, &ContactEditorData.HomeTitleListType,
790                 &ContactEditorData.HomeTitleListTokens, &ContactEditorData.HomeTitleListPref);
791     
794 void frmContactEditor::AddHomeRole( wxCommandEvent& event )
796         
797         int intResult = 0;
798     
799         frmContactEditorRoles *frameCERole = new frmContactEditorRoles ( this );
800         frameCERole->SetEditorMode(FALSE, CE_HOME);
801         intResult = GetLastInt(&ContactEditorData.HomeRoleList);
802         frameCERole->SetupPointers(&ContactEditorData.HomeRoleList,
803                 &ContactEditorData.HomeRoleListLanguage,
804                 &ContactEditorData.HomeRoleListAltID,
805                 &ContactEditorData.HomeRoleListPID,
806                 &ContactEditorData.HomeRoleListType,
807                 &ContactEditorData.HomeRoleListTokens,
808                 &ContactEditorData.HomeRoleListPref,
809                 lboHomeRoles,
810                 (intValueSeek));
811         frameCERole->ShowModal();
812         delete frameCERole;
813         frameCERole = NULL;
814         
817 void frmContactEditor::ModifyHomeRole( wxCommandEvent& event )
819         
820         long longSelected = -1;
821         int intSelectedData = 0;
822     
823         if (!GetSelectedItem(lboHomeRoles,
824                 &longSelected,
825                 &intSelectedData)){
826                 return;
827         }
828     
829         frmContactEditorRoles *frameCERole = new frmContactEditorRoles ( this );
830         frameCERole->SetupPointers(&ContactEditorData.HomeRoleList,
831                 &ContactEditorData.HomeRoleListLanguage,
832                 &ContactEditorData.HomeRoleListAltID,
833                 &ContactEditorData.HomeRoleListPID,
834                 &ContactEditorData.HomeRoleListType,
835                 &ContactEditorData.HomeRoleListTokens,
836                 &ContactEditorData.HomeRoleListPref,
837                 lboHomeRoles,
838                 intSelectedData);
839         frameCERole->SetEditorMode(TRUE, CE_HOME);
840         frameCERole->ShowModal();
841         delete frameCERole;
842         frameCERole = NULL;
843         
846 void frmContactEditor::DeleteHomeRole( wxCommandEvent& event )
848         
849         long longSelected = -1;
850         int intSelectedData = 0;
851     
852         if (!GetSelectedItem(lboHomeRoles,
853                 &longSelected,
854                 &intSelectedData)){
855                 return;
856         }
857     
858         lboHomeRoles->DeleteItem(longSelected);
859     
860         DeleteMapData(intSelectedData, &ContactEditorData.HomeRoleList,
861                 &ContactEditorData.HomeRoleListLanguage, &ContactEditorData.HomeRoleListAltID,
862                 &ContactEditorData.HomeRoleListPID, &ContactEditorData.HomeRoleListType,
863                 &ContactEditorData.HomeRoleListTokens, &ContactEditorData.HomeRoleListPref);
864     
867 void frmContactEditor::AddHomeOrganisation( wxCommandEvent& event )
869         
870         int intResult = 0;
871     
872         frmContactEditorOrganisations *frameCEOrg = new frmContactEditorOrganisations ( this );
873         frameCEOrg->SetEditorMode(FALSE, CE_HOME);
874         intResult = GetLastInt(&ContactEditorData.HomeOrganisationsList);
875         frameCEOrg->SetupPointers(&ContactEditorData.HomeOrganisationsList,
876                 &ContactEditorData.HomeOrganisationsListLanguage,
877                 &ContactEditorData.HomeOrganisationsListSortAs,
878                 &ContactEditorData.HomeOrganisationsListAltID,
879                 &ContactEditorData.HomeOrganisationsListPID,
880                 &ContactEditorData.HomeOrganisationsListType,
881                 &ContactEditorData.HomeOrganisationsListTokens,
882                 &ContactEditorData.HomeOrganisationsListPref,
883                 lboHomeOrganisations,
884                 (intValueSeek));
885         frameCEOrg->ShowModal();
886         delete frameCEOrg;
887         frameCEOrg = NULL;
888         
891 void frmContactEditor::ModifyHomeOrganisation( wxCommandEvent& event )
893         
894         long longSelected = -1;
895         int intSelectedData = 0;
896     
897         if (!GetSelectedItem(lboHomeOrganisations,
898                 &longSelected,
899                 &intSelectedData)){
900                 return;
901         }
902     
903         frmContactEditorOrganisations *frameCEOrg = new frmContactEditorOrganisations ( this );
904         frameCEOrg->SetupPointers(&ContactEditorData.HomeOrganisationsList,
905                 &ContactEditorData.HomeOrganisationsListLanguage,
906                 &ContactEditorData.HomeOrganisationsListSortAs,
907                 &ContactEditorData.HomeOrganisationsListAltID,
908                 &ContactEditorData.HomeOrganisationsListPID,
909                 &ContactEditorData.HomeOrganisationsListType,
910                 &ContactEditorData.HomeOrganisationsListTokens,
911                 &ContactEditorData.HomeOrganisationsListPref,
912                 lboHomeOrganisations,
913                 intSelectedData);
914         frameCEOrg->SetEditorMode(TRUE, CE_HOME);
915         frameCEOrg->ShowModal();
916         delete frameCEOrg;
917         frameCEOrg = NULL;
918         
921 void frmContactEditor::DeleteHomeOrganisation( wxCommandEvent& event )
923         
924         long longSelected = -1;
925         int intSelectedData = 0;
926     
927         if (!GetSelectedItem(lboHomeOrganisations,
928                 &longSelected,
929                 &intSelectedData)){
930                 return;
931         }
932     
933         lboHomeOrganisations->DeleteItem(longSelected);
935         DeleteMapData(intSelectedData, &ContactEditorData.HomeOrganisationsList,
936                 &ContactEditorData.HomeOrganisationsListLanguage, &ContactEditorData.HomeOrganisationsListSortAs,
937                 &ContactEditorData.HomeOrganisationsListAltID, &ContactEditorData.HomeOrganisationsListPID,
938                 &ContactEditorData.HomeOrganisationsListType, &ContactEditorData.HomeOrganisationsListTokens,
939                 &ContactEditorData.HomeOrganisationsListPref);
940     
943 void frmContactEditor::AddHomeNote( wxCommandEvent& event )
945         
946         int intResult = 0;
947     
948         frmContactEditorNotes *frameCENote = new frmContactEditorNotes ( this );
949         frameCENote->SetEditorMode(FALSE, CE_HOME);
950         intResult = GetLastInt(&ContactEditorData.HomeNoteList);
951         frameCENote->SetupPointers(&ContactEditorData.HomeNoteList,
952                 &ContactEditorData.HomeNoteListLanguage,
953                 &ContactEditorData.HomeNoteListAltID,
954                 &ContactEditorData.HomeNoteListPID,
955                 &ContactEditorData.HomeNoteListType,
956                 &ContactEditorData.HomeNoteListTokens,
957                 &ContactEditorData.HomeNoteListPref,
958                 lboHomeNotes,
959                 (intValueSeek));
960         frameCENote->ShowModal();
961         delete frameCENote;
962         frameCENote = NULL;
963         
966 void frmContactEditor::ModifyHomeNote( wxCommandEvent& event )
968         
969         long longSelected = -1;
970         int intSelectedData = 0;
971     
972         if (!GetSelectedItem(lboHomeNotes,
973                 &longSelected,
974                 &intSelectedData)){
975                 return;
976         }
977     
978         frmContactEditorNotes *frameCENote = new frmContactEditorNotes ( this );
979         frameCENote->SetupPointers(&ContactEditorData.HomeNoteList,
980                 &ContactEditorData.HomeNoteListLanguage,
981                 &ContactEditorData.HomeNoteListAltID,
982                 &ContactEditorData.HomeNoteListPID,
983                 &ContactEditorData.HomeNoteListType,
984                 &ContactEditorData.HomeNoteListTokens,
985                 &ContactEditorData.HomeNoteListPref,
986                 lboHomeNotes,
987                 intSelectedData);
988         frameCENote->SetEditorMode(TRUE, CE_HOME);
989         frameCENote->ShowModal();
990         delete frameCENote;
991         frameCENote = NULL;
992         
995 void frmContactEditor::DeleteHomeNote( wxCommandEvent& event )
997         
998         long longSelected = -1;
999         int intSelectedData = 0;
1000     
1001         if (!GetSelectedItem(lboHomeNotes,
1002                 &longSelected,
1003                 &intSelectedData)){
1004                 return;
1005         }
1006     
1007         lboNotes->DeleteItem(longSelected);
1008     
1009         DeleteMapData(intSelectedData, &ContactEditorData.HomeNoteList,
1010                 &ContactEditorData.HomeNoteListLanguage, &ContactEditorData.HomeNoteListAltID,
1011                 &ContactEditorData.HomeNoteListPID, &ContactEditorData.HomeNoteListType,
1012                 &ContactEditorData.HomeNoteListTokens, &ContactEditorData.HomeNoteListPref);
1013     
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