Home | News | Projects | Releases
Bugs | RFE | Repositories | Help
Updated TEL processing when saving a contact with frmContactEditor
[xestiaab/.git] / source / contacteditor / frmContactEditor-Business.cpp
1 // frmContactEditorBusiness.cpp - frmContactEditor Business 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::AddBusinessNickname( wxCommandEvent& event )
37 {
38     int intResult = 0;
39     
40     frmContactEditorNickname *frameCENickname = new frmContactEditorNickname ( this );
41     frameCENickname->SetEditorMode(FALSE, CE_WORK);
42     intResult = GetLastInt(&ContactEditorData.BusinessNicknamesList);
43     frameCENickname->SetupPointers(&ContactEditorData.BusinessNicknamesList,
44                                    &ContactEditorData.BusinessNicknamesListAltID,
45                                    &ContactEditorData.BusinessNicknamesListPID,
46                                    &ContactEditorData.BusinessNicknamesListType,
47                                    &ContactEditorData.BusinessNicknamesListLanguage,
48                                    &ContactEditorData.BusinessNicknamesListTokens,
49                                    &ContactEditorData.BusinessNicknamesListPref,
50                                    lboBusinessNicknames,
51                                    (intValueSeek));
52     frameCENickname->ShowModal();
53     delete frameCENickname;
54     frameCENickname = NULL;
55 }
57 void frmContactEditor::ModifyBusinessNickname( wxCommandEvent& event )
58 {
59     long longSelected = -1;
60     int intSelectedData = 0;
61     
62     if (!GetSelectedItem(lboBusinessNicknames,
63                          &longSelected,
64                          &intSelectedData)){
65         return;
66     }
67     
68     frmContactEditorNickname *frameCENickname = new frmContactEditorNickname ( this );
69     frameCENickname->SetupPointers(&ContactEditorData.BusinessNicknamesList,
70                                    &ContactEditorData.BusinessNicknamesListAltID,
71                                    &ContactEditorData.BusinessNicknamesListPID,
72                                    &ContactEditorData.BusinessNicknamesListType,
73                                    &ContactEditorData.BusinessNicknamesListLanguage,
74                                    &ContactEditorData.BusinessNicknamesListTokens,
75                                    &ContactEditorData.BusinessNicknamesListPref,
76                                    lboBusinessNicknames,
77                                    intSelectedData);
78     frameCENickname->SetEditorMode(TRUE, CE_WORK);
79     frameCENickname->ShowModal();
80     delete frameCENickname;
81     frameCENickname = NULL;
82 }
84 void frmContactEditor::DeleteBusinessNickname( wxCommandEvent& event )
85 {
86     long longSelected = -1;
87     int intSelectedData = 0;
88     
89     if (!GetSelectedItem(lboBusinessNicknames,
90                          &longSelected,
91                          &intSelectedData)){
92         return;
93     }
94     
95     lboBusinessNicknames->DeleteItem(longSelected);
96     
97     DeleteMapData(intSelectedData,
98                   &ContactEditorData.BusinessNicknamesList,
99                   &ContactEditorData.BusinessNicknamesListLanguage,
100                   &ContactEditorData.BusinessNicknamesListAltID,
101                   &ContactEditorData.BusinessNicknamesListPID,
102                   &ContactEditorData.BusinessNicknamesListTokens,
103                   &ContactEditorData.BusinessNicknamesListType,
104                   &ContactEditorData.BusinessNicknamesListPref);
107 void frmContactEditor::AddBusinessAddress( wxCommandEvent& event )
109     int intResult = 0;
110     
111     frmContactEditorAddress *frameCEAddress = new frmContactEditorAddress ( this );
112     frameCEAddress->SetEditorMode(FALSE, CE_WORK);
113     intResult = GetLastInt(&ContactEditorData.BusinessAddressList);
114     frameCEAddress->SetupPointers(&ContactEditorData.BusinessAddressList,
115                                   &ContactEditorData.BusinessAddressListTown,
116                                   &ContactEditorData.BusinessAddressListCounty,
117                                   &ContactEditorData.BusinessAddressListPostCode,
118                                   &ContactEditorData.BusinessAddressListCountry,
119                                   &ContactEditorData.BusinessAddressListLabel,
120                                   &ContactEditorData.BusinessAddressListLang,
121                                   &ContactEditorData.BusinessAddressListAltID,
122                                   &ContactEditorData.BusinessAddressListPID,
123                                   &ContactEditorData.BusinessAddressListTokens,
124                                   &ContactEditorData.BusinessAddressListGeo,
125                                   &ContactEditorData.BusinessAddressListTimezone,
126                                   &ContactEditorData.BusinessAddressListType,
127                                   &ContactEditorData.BusinessAddressListMediatype,
128                                   &ContactEditorData.BusinessAddressListPref,
129                                   lboBusinessAddresses,
130                                   (intValueSeek));
131     frameCEAddress->ShowModal();
132     delete frameCEAddress;
133     frameCEAddress = NULL;
136 void frmContactEditor::ModifyBusinessAddress( wxCommandEvent& event )
138     long longSelected = -1;
139     int intSelectedData = 0;
140     
141     if (!GetSelectedItem(lboBusinessAddresses,
142                          &longSelected,
143                          &intSelectedData)){
144         return;
145     }
146     
147     frmContactEditorAddress *frameCEAddress = new frmContactEditorAddress ( this );
148     frameCEAddress->SetupPointers(&ContactEditorData.BusinessAddressList,
149                                   &ContactEditorData.BusinessAddressListTown,
150                                   &ContactEditorData.BusinessAddressListCounty,
151                                   &ContactEditorData.BusinessAddressListPostCode,
152                                   &ContactEditorData.BusinessAddressListCountry,
153                                   &ContactEditorData.BusinessAddressListLabel,
154                                   &ContactEditorData.BusinessAddressListLang,
155                                   &ContactEditorData.BusinessAddressListAltID,
156                                   &ContactEditorData.BusinessAddressListPID,
157                                   &ContactEditorData.BusinessAddressListTokens,
158                                   &ContactEditorData.BusinessAddressListGeo,
159                                   &ContactEditorData.BusinessAddressListTimezone,
160                                   &ContactEditorData.BusinessAddressListType,
161                                   &ContactEditorData.BusinessAddressListMediatype,
162                                   &ContactEditorData.BusinessAddressListPref,
163                                   lboBusinessAddresses,
164                                   intSelectedData);
165     frameCEAddress->SetEditorMode(TRUE, CE_WORK);
166     frameCEAddress->ShowModal();
167     delete frameCEAddress;
168     frameCEAddress = NULL;
171 void frmContactEditor::DeleteBusinessAddress( wxCommandEvent& event )
173     long longSelected = -1;
174     int intSelectedData = 0;
175     
176     if (!GetSelectedItem(lboBusinessAddresses,
177                          &longSelected,
178                          &intSelectedData)){
179         return;
180     }
181     
182     lboBusinessAddresses->DeleteItem(longSelected);
183     DeleteMapData(intSelectedData, &ContactEditorData.BusinessAddressList,
184                   &ContactEditorData.BusinessAddressListTown, &ContactEditorData.BusinessAddressListCounty,
185                   &ContactEditorData.BusinessAddressListPostCode, &ContactEditorData.BusinessAddressListCountry,
186                   &ContactEditorData.BusinessAddressList, &ContactEditorData.BusinessAddressListLabel,
187                   &ContactEditorData.BusinessAddressListLang, &ContactEditorData.BusinessAddressListAltID,
188                   &ContactEditorData.BusinessAddressListPID, &ContactEditorData.BusinessAddressListTokens,
189                   &ContactEditorData.BusinessAddressListGeo, &ContactEditorData.BusinessAddressListTimezone,
190                   &ContactEditorData.BusinessAddressListType, &ContactEditorData.BusinessAddressListMediatype,
191                   &ContactEditorData.BusinessAddressListPref);
192     
195 void frmContactEditor::AddBusinessEmail( wxCommandEvent& event )
197     int intResult = 0;
198     
199     frmContactEditorEmail *frameCEEmail = new frmContactEditorEmail ( this );
200     frameCEEmail->SetEditorMode(FALSE, CE_WORK);
201     intResult = GetLastInt(&ContactEditorData.BusinessAddressList);
202     frameCEEmail->SetupPointers(&ContactEditorData.BusinessEmailList,
203                                 &ContactEditorData.BusinessEmailListAltID,
204                                 &ContactEditorData.BusinessEmailListPID,
205                                 &ContactEditorData.BusinessEmailListType,
206                                 &ContactEditorData.BusinessEmailListTokens,
207                                 &ContactEditorData.BusinessEmailListPref,
208                                 lboBusinessEmail,
209                                 (intValueSeek));
210     frameCEEmail->ShowModal();
211     delete frameCEEmail;
212     frameCEEmail = NULL;
215 void frmContactEditor::ModifyBusinessEmail( wxCommandEvent& event )
217     long longSelected = -1;
218     int intSelectedData = 0;
219     
220     if (!GetSelectedItem(lboBusinessEmail,
221                          &longSelected,
222                          &intSelectedData)){
223         return;
224     }
225     
226     frmContactEditorEmail *frameCEEmail = new frmContactEditorEmail ( this );
227     frameCEEmail->SetupPointers(&ContactEditorData.BusinessEmailList,
228                                 &ContactEditorData.BusinessEmailListAltID,
229                                 &ContactEditorData.BusinessEmailListPID,
230                                 &ContactEditorData.BusinessEmailListType,
231                                 &ContactEditorData.BusinessEmailListTokens,
232                                 &ContactEditorData.BusinessEmailListPref,
233                                 lboBusinessEmail,
234                                 intSelectedData);
235     frameCEEmail->SetEditorMode(TRUE, CE_WORK);
236     frameCEEmail->ShowModal();
237     delete frameCEEmail;
238     frameCEEmail = NULL;
241 void frmContactEditor::DeleteBusinessEmail( wxCommandEvent& event )
243     long longSelected = -1;
244     int intSelectedData = 0;
245     
246     if (!GetSelectedItem(lboBusinessEmail,
247                          &longSelected,
248                          &intSelectedData)){
249         return;
250     }
251     
252     lboBusinessEmail->DeleteItem(longSelected);
253     
254     DeleteMapData(intSelectedData, &ContactEditorData.BusinessEmailList,
255                   &ContactEditorData.BusinessEmailListAltID, &ContactEditorData.BusinessEmailListPID,
256                   &ContactEditorData.BusinessEmailListType, &ContactEditorData.BusinessEmailListTokens,
257                   &ContactEditorData.BusinessEmailListPref);
258     
261 void frmContactEditor::AddBusinessIM( wxCommandEvent& event )
263     int intResult = 0;
264     
265     frmContactEditorIM *frameCEIM = new frmContactEditorIM ( this );
266     frameCEIM->SetEditorMode(FALSE, CE_WORK);
267     intResult = GetLastInt(&ContactEditorData.BusinessIMList);
268     frameCEIM->SetupPointers(&ContactEditorData.BusinessIMList,
269                              &ContactEditorData.BusinessIMListAltID,
270                              &ContactEditorData.BusinessIMListPID,
271                              &ContactEditorData.BusinessIMListType,
272                              &ContactEditorData.BusinessIMListTypeInfo,
273                              &ContactEditorData.BusinessIMListTokens,
274                              &ContactEditorData.BusinessIMListMediatype,
275                              &ContactEditorData.BusinessIMListPref,
276                              lboBusinessIM,
277                              (intValueSeek));
278     frameCEIM->ShowModal();
279     delete frameCEIM;
280     frameCEIM = NULL;
283 void frmContactEditor::ModifyBusinessIM( wxCommandEvent& event )
285     long longSelected = -1;
286     int intSelectedData = 0;
287     
288     if (!GetSelectedItem(lboBusinessIM,
289                          &longSelected,
290                          &intSelectedData)){
291         return;
292     }
293     
294     frmContactEditorIM *frameCEIM = new frmContactEditorIM ( this );
295     frameCEIM->SetupPointers(&ContactEditorData.BusinessIMList,
296                              &ContactEditorData.BusinessIMListAltID,
297                              &ContactEditorData.BusinessIMListPID,
298                              &ContactEditorData.BusinessIMListType,
299                              &ContactEditorData.BusinessIMListTypeInfo,
300                              &ContactEditorData.BusinessIMListTokens,
301                              &ContactEditorData.BusinessIMListMediatype,
302                              &ContactEditorData.BusinessIMListPref,
303                              lboBusinessIM,
304                              intSelectedData);
305     frameCEIM->SetEditorMode(TRUE, CE_WORK);
306     frameCEIM->ShowModal();
307     delete frameCEIM;
308     frameCEIM = NULL;
311 void frmContactEditor::DeleteBusinessIM( wxCommandEvent& event )
313     long longSelected = -1;
314     int intSelectedData = 0;
315     
316     if (!GetSelectedItem(lboBusinessIM,
317                          &longSelected,
318                          &intSelectedData)){
319         return;
320     }
321     
322     lboBusinessIM->DeleteItem(longSelected);
323     
324     DeleteMapData(intSelectedData, &ContactEditorData.BusinessIMList,
325                   &ContactEditorData.BusinessIMListAltID, &ContactEditorData.BusinessIMListPID,
326                   &ContactEditorData.BusinessIMListType, &ContactEditorData.BusinessIMListTypeInfo,
327                   &ContactEditorData.BusinessIMListTokens, &ContactEditorData.BusinessIMListMediatype, 
328                   &ContactEditorData.BusinessIMListPref);
329     
332 void frmContactEditor::AddBusinessTelephone( wxCommandEvent& event )
334     int intResult = 0;
335     
336     frmContactEditorTelephone *frameCETel = new frmContactEditorTelephone ( this );
337     frameCETel->SetEditorMode(FALSE, CE_WORK);
338     intResult = GetLastInt(&ContactEditorData.BusinessTelephoneList);
339     frameCETel->SetupPointers(&ContactEditorData.BusinessTelephoneList,
340                               &ContactEditorData.BusinessTelephoneListAltID,
341                               &ContactEditorData.BusinessTelephoneListPID,
342                               &ContactEditorData.BusinessTelephoneListType,
343                               &ContactEditorData.BusinessTelephoneListTypeInfo,
344                               &ContactEditorData.BusinessTelephoneListTokens,
345                               &ContactEditorData.BusinessTelephoneListPref,
346                               lboBusinessTelephone,
347                               (intValueSeek));
348     frameCETel->ShowModal();
349     delete frameCETel;
350     frameCETel = NULL;
353 void frmContactEditor::ModifyBusinessTelephone( wxCommandEvent& event )
355     long longSelected = -1;
356     int intSelectedData = 0;
357     
358     if (!GetSelectedItem(lboBusinessTelephone,
359                          &longSelected,
360                          &intSelectedData)){
361         return;
362     }
363     
364     frmContactEditorTelephone *frameCETel = new frmContactEditorTelephone ( this );
365     frameCETel->SetupPointers(&ContactEditorData.BusinessTelephoneList,
366                               &ContactEditorData.BusinessTelephoneListAltID,
367                               &ContactEditorData.BusinessTelephoneListPID,
368                               &ContactEditorData.BusinessTelephoneListType,
369                               &ContactEditorData.BusinessTelephoneListTypeInfo,
370                               &ContactEditorData.BusinessTelephoneListTokens,
371                               &ContactEditorData.BusinessTelephoneListPref,
372                               lboBusinessTelephone,
373                               intSelectedData);
374     frameCETel->SetEditorMode(TRUE, CE_WORK);
375     frameCETel->ShowModal();
376     delete frameCETel;
377     frameCETel = NULL;
380 void frmContactEditor::DeleteBusinessTelephone( wxCommandEvent& event )
382     long longSelected = -1;
383     int intSelectedData = 0;
384     
385     if (!GetSelectedItem(lboBusinessTelephone,
386                          &longSelected,
387                          &intSelectedData)){
388         return;
389     }
390     
391     lboBusinessTelephone->DeleteItem(longSelected);
392     
393     DeleteMapData(intSelectedData, &ContactEditorData.BusinessTelephoneList,
394                   &ContactEditorData.BusinessTelephoneListAltID, &ContactEditorData.BusinessTelephoneListPID,
395                   &ContactEditorData.BusinessTelephoneListType, &ContactEditorData.BusinessTelephoneListTypeInfo,
396                   &ContactEditorData.BusinessTelephoneListTokens, &ContactEditorData.BusinessTelephoneListPref);
397     
400 void frmContactEditor::AddBusinessLanguage( wxCommandEvent& event )
402     int intResult = 0;
403     
404     frmContactEditorLanguages *frameCELang = new frmContactEditorLanguages ( this );
405     frameCELang->SetEditorMode(FALSE, CE_WORK);
406     intResult = GetLastInt(&ContactEditorData.BusinessLanguageList);
407     frameCELang->SetupPointers(&ContactEditorData.BusinessLanguageList,
408                                &ContactEditorData.BusinessLanguageListAltID,
409                                &ContactEditorData.BusinessLanguageListPID,
410                                &ContactEditorData.BusinessLanguageListType,
411                                &ContactEditorData.BusinessLanguageListTokens,
412                                &ContactEditorData.BusinessLanguageListPref,
413                                lboBusinessLanguages,
414                                (intValueSeek));
415     frameCELang->ShowModal();
416     delete frameCELang;
417     frameCELang = NULL;
420 void frmContactEditor::ModifyBusinessLanguage( wxCommandEvent& event )
422     long longSelected = -1;
423     int intSelectedData = 0;
424     
425     if (!GetSelectedItem(lboBusinessLanguages,
426                          &longSelected,
427                          &intSelectedData)){
428         return;
429     }
430     
431     frmContactEditorLanguages *frameCELang = new frmContactEditorLanguages ( this );
432     frameCELang->SetupPointers(&ContactEditorData.BusinessLanguageList,
433                                &ContactEditorData.BusinessLanguageListAltID,
434                                &ContactEditorData.BusinessLanguageListPID,
435                                &ContactEditorData.BusinessLanguageListType,
436                                &ContactEditorData.BusinessLanguageListTokens,
437                                &ContactEditorData.BusinessLanguageListPref,
438                                lboBusinessLanguages,
439                                intSelectedData);
440     frameCELang->SetEditorMode(TRUE, CE_WORK);
441     frameCELang->ShowModal();
442     delete frameCELang;
443     frameCELang = NULL;
446 void frmContactEditor::DeleteBusinessLanguage( wxCommandEvent& event )
448     long longSelected = -1;
449     int intSelectedData = 0;
450     
451     if (!GetSelectedItem(lboBusinessLanguages,
452                          &longSelected,
453                          &intSelectedData)){
454         return;
455     }
456     
457     lboBusinessLanguages->DeleteItem(longSelected);
458     
459     DeleteMapData(intSelectedData, &ContactEditorData.BusinessLanguageList,
460                   &ContactEditorData.BusinessLanguageListAltID, &ContactEditorData.BusinessLanguageListPID,
461                   &ContactEditorData.BusinessLanguageListType, &ContactEditorData.BusinessLanguageListTokens,
462                   &ContactEditorData.BusinessLanguageListPref);
463     
466 void frmContactEditor::AddBusinessTimezone( wxCommandEvent& event )
468     int intResult = 0;
469     
470     frmContactEditorTimezones *frameCETZ = new frmContactEditorTimezones ( this );
471     frameCETZ->SetEditorMode(FALSE, CE_WORK);
472     intResult = GetLastInt(&ContactEditorData.BusinessTZList);
473     frameCETZ->SetupPointers(&ContactEditorData.BusinessTZList,
474                              &ContactEditorData.BusinessTZListAltID,
475                              &ContactEditorData.BusinessTZListPID,
476                              &ContactEditorData.BusinessTZListType,
477                              &ContactEditorData.BusinessTZListTokens,
478                              &ContactEditorData.BusinessTZListMediatype,
479                              &ContactEditorData.BusinessTZListPref,
480                              lboBusinessTimezones,
481                              (intValueSeek));
482     frameCETZ->ShowModal();
483     delete frameCETZ;
484     frameCETZ = NULL;
487 void frmContactEditor::ModifyBusinessTimezone( wxCommandEvent& event )
489     long longSelected = -1;
490     int intSelectedData = 0;
491     
492     if (!GetSelectedItem(lboBusinessTimezones,
493                          &longSelected,
494                          &intSelectedData)){
495         return;
496     }
497     
498     frmContactEditorTimezones *frameCETZ = new frmContactEditorTimezones ( this );
499     frameCETZ->SetupPointers(&ContactEditorData.BusinessTZList,
500                              &ContactEditorData.BusinessTZListAltID,
501                              &ContactEditorData.BusinessTZListPID,
502                              &ContactEditorData.BusinessTZListType,
503                              &ContactEditorData.BusinessTZListTokens,
504                              &ContactEditorData.BusinessTZListMediatype,
505                              &ContactEditorData.BusinessTZListPref,
506                              lboBusinessTimezones,
507                              intSelectedData);
508     frameCETZ->SetEditorMode(TRUE, CE_WORK);
509     frameCETZ->ShowModal();
510     delete frameCETZ;
511     frameCETZ = NULL;
514 void frmContactEditor::DeleteBusinessTimezone( wxCommandEvent& event )
516     long longSelected = -1;
517     int intSelectedData = 0;
518     
519     if (!GetSelectedItem(lboBusinessTimezones,
520                          &longSelected,
521                          &intSelectedData)){
522         return;
523     }
524     
525     lboBusinessTimezones->DeleteItem(longSelected);
526     
527     DeleteMapData(intSelectedData, &ContactEditorData.BusinessTZList,
528                   &ContactEditorData.BusinessTZListAltID, &ContactEditorData.BusinessTZListPID,
529                   &ContactEditorData.BusinessTZListType, &ContactEditorData.BusinessTZListTokens,
530                   &ContactEditorData.BusinessTZListMediatype, &ContactEditorData.BusinessTZListPref);
531     
534 void frmContactEditor::AddBusinessGeoposition( wxCommandEvent& event )
536     int intResult = 0;
537     
538     frmContactEditorGeoposition *frameCEGeo = new frmContactEditorGeoposition ( this );
539     frameCEGeo->SetEditorMode(FALSE, CE_WORK);
540     intResult = GetLastInt(&ContactEditorData.BusinessGeographyList);
541     frameCEGeo->SetupPointers(&ContactEditorData.BusinessGeographyList,
542                               &ContactEditorData.BusinessGeographyListAltID,
543                               &ContactEditorData.BusinessGeographyListPID,
544                               &ContactEditorData.BusinessGeographyListType,
545                               &ContactEditorData.BusinessGeographyListDataType,
546                               &ContactEditorData.BusinessGeographyListTokens,
547                               &ContactEditorData.BusinessGeographyListMediatype,
548                               &ContactEditorData.BusinessGeographyListPref,
549                               lboBusinessGeoposition,
550                               (intValueSeek));
551     frameCEGeo->ShowModal();
552     delete frameCEGeo;
553     frameCEGeo = NULL;
556 void frmContactEditor::ModifyBusinessGeoposition( wxCommandEvent& event )
558     long longSelected = -1;
559     int intSelectedData = 0;
560     
561     if (!GetSelectedItem(lboBusinessGeoposition,
562                          &longSelected,
563                          &intSelectedData)){
564         return;
565     }
566     
567     frmContactEditorGeoposition *frameCEGeo = new frmContactEditorGeoposition ( this );
568     frameCEGeo->SetupPointers(&ContactEditorData.BusinessGeographyList,
569                               &ContactEditorData.BusinessGeographyListAltID,
570                               &ContactEditorData.BusinessGeographyListPID,
571                               &ContactEditorData.BusinessGeographyListType,
572                               &ContactEditorData.BusinessGeographyListDataType,
573                               &ContactEditorData.BusinessGeographyListTokens,
574                               &ContactEditorData.BusinessGeographyListMediatype,
575                               &ContactEditorData.BusinessGeographyListPref,
576                               lboBusinessGeoposition,
577                               intSelectedData);
578     frameCEGeo->SetEditorMode(TRUE, CE_WORK);
579     frameCEGeo->ShowModal();
580     delete frameCEGeo;
581     frameCEGeo = NULL;
584 void frmContactEditor::DeleteBusinessGeoposition( wxCommandEvent& event )
586     long longSelected = -1;
587     int intSelectedData = 0;
588     
589     if (!GetSelectedItem(lboBusinessGeoposition,
590                          &longSelected,
591                          &intSelectedData)){
592         return;
593     }
594     
595     lboBusinessGeoposition->DeleteItem(longSelected);
596     
597     DeleteMapData(intSelectedData, &ContactEditorData.BusinessGeographyList,
598                   &ContactEditorData.BusinessGeographyListAltID, &ContactEditorData.BusinessGeographyListPID,
599                   &ContactEditorData.BusinessGeographyListType, &ContactEditorData.BusinessGeographyListDataType,
600                   &ContactEditorData.BusinessGeographyListTokens, &ContactEditorData.BusinessGeographyListMediatype, 
601                   &ContactEditorData.BusinessGeographyListPref);
602     
605 void frmContactEditor::AddBusinessWebsite( wxCommandEvent& event )
607     int intResult = 0;
608     
609     frmContactEditorWebsites *frameCEWeb = new frmContactEditorWebsites ( this );
610     frameCEWeb->SetEditorMode(FALSE, CE_WORK);
611     intResult = GetLastInt(&ContactEditorData.BusinessWebsiteList);
612     frameCEWeb->SetupPointers(&ContactEditorData.BusinessWebsiteList,
613                               &ContactEditorData.BusinessWebsiteListAltID,
614                               &ContactEditorData.BusinessWebsiteListPID,
615                               &ContactEditorData.BusinessWebsiteListType,
616                               &ContactEditorData.BusinessWebsiteListTokens,
617                               &ContactEditorData.BusinessWebsiteListMediatype,
618                               &ContactEditorData.BusinessWebsiteListPref,
619                               lboBusinessWebsites,
620                               (intValueSeek));
621     frameCEWeb->ShowModal();
622     delete frameCEWeb;
623     frameCEWeb = NULL;
626 void frmContactEditor::ModifyBusinessWebsite( wxCommandEvent& event )
628     long longSelected = -1;
629     int intSelectedData = 0;
630     
631     if (!GetSelectedItem(lboBusinessWebsites,
632                          &longSelected,
633                          &intSelectedData)){
634         return;
635     }
636     
637     frmContactEditorWebsites *frameCEWeb = new frmContactEditorWebsites ( this );
638     frameCEWeb->SetupPointers(&ContactEditorData.BusinessWebsiteList,
639                               &ContactEditorData.BusinessWebsiteListAltID,
640                               &ContactEditorData.BusinessWebsiteListPID,
641                               &ContactEditorData.BusinessWebsiteListType,
642                               &ContactEditorData.BusinessWebsiteListTokens,
643                               &ContactEditorData.BusinessWebsiteListMediatype,
644                               &ContactEditorData.BusinessWebsiteListPref,
645                               lboBusinessWebsites,
646                               intSelectedData);
647     frameCEWeb->SetEditorMode(TRUE, CE_WORK);
648     frameCEWeb->ShowModal();
649     delete frameCEWeb;
650     frameCEWeb = NULL;
653 void frmContactEditor::DeleteBusinessWebsite( wxCommandEvent& event )
655     long longSelected = -1;
656     int intSelectedData = 0;
657     
658     if (!GetSelectedItem(lboBusinessWebsites,
659                          &longSelected,
660                          &intSelectedData)){
661         return;
662     }
663     
664     lboBusinessWebsites->DeleteItem(longSelected);
665     
666     DeleteMapData(intSelectedData, &ContactEditorData.BusinessWebsiteList,
667                   &ContactEditorData.BusinessWebsiteListAltID, &ContactEditorData.BusinessWebsiteListPID,
668                   &ContactEditorData.BusinessWebsiteListType, &ContactEditorData.BusinessWebsiteListTokens,
669                   &ContactEditorData.BusinessWebsiteListMediatype, &ContactEditorData.BusinessWebsiteListPref);
670     
673 void frmContactEditor::AddBusinessTitle( wxCommandEvent& event )
675     int intResult = 0;
676     
677     frmContactEditorTitles *frameCETitle = new frmContactEditorTitles ( this );
678     frameCETitle->SetEditorMode(FALSE, CE_WORK);
679     intResult = GetLastInt(&ContactEditorData.BusinessTitleList);
680     frameCETitle->SetupPointers(&ContactEditorData.BusinessTitleList,
681                                 &ContactEditorData.BusinessTitleListLanguage,
682                                 &ContactEditorData.BusinessTitleListAltID,
683                                 &ContactEditorData.BusinessTitleListPID,
684                                 &ContactEditorData.BusinessTitleListType,
685                                 &ContactEditorData.BusinessTitleListTokens,
686                                 &ContactEditorData.BusinessTitleListPref,
687                                 lboBusinessTitles,
688                                 (intValueSeek));
689     frameCETitle->ShowModal();
690     delete frameCETitle;
691     frameCETitle = NULL;
694 void frmContactEditor::ModifyBusinessTitle( wxCommandEvent& event )
696     long longSelected = -1;
697     int intSelectedData = 0;
698     
699     if (!GetSelectedItem(lboBusinessTitles,
700                          &longSelected,
701                          &intSelectedData)){
702         return;
703     }
704     
705     frmContactEditorTitles *frameCETitle = new frmContactEditorTitles ( this );
706     frameCETitle->SetupPointers(&ContactEditorData.BusinessTitleList,
707                                 &ContactEditorData.BusinessTitleListLanguage,
708                                 &ContactEditorData.BusinessTitleListAltID,
709                                 &ContactEditorData.BusinessTitleListPID,
710                                 &ContactEditorData.BusinessTitleListType,
711                                 &ContactEditorData.BusinessTitleListTokens,
712                                 &ContactEditorData.BusinessTitleListPref,
713                                 lboBusinessTitles,
714                                 intSelectedData);
715     frameCETitle->SetEditorMode(TRUE, CE_WORK);
716     frameCETitle->ShowModal();
717     delete frameCETitle;
718     frameCETitle = NULL;
721 void frmContactEditor::DeleteBusinessTitle( wxCommandEvent& event )
723     long longSelected = -1;
724     int intSelectedData = 0;
725     
726     if (!GetSelectedItem(lboBusinessTitles,
727                          &longSelected,
728                          &intSelectedData)){
729         return;
730     }
731     
732     lboTitles->DeleteItem(longSelected);
733     
734     DeleteMapData(intSelectedData, &ContactEditorData.BusinessTitleList,
735                   &ContactEditorData.BusinessTitleListLanguage, &ContactEditorData.BusinessTitleListAltID,
736                   &ContactEditorData.BusinessTitleListPID, &ContactEditorData.BusinessTitleListType,
737                   &ContactEditorData.BusinessTitleListTokens, &ContactEditorData.BusinessTitleListPref);
738     
741 void frmContactEditor::AddBusinessRole( wxCommandEvent& event )
743     int intResult = 0;
744     
745     frmContactEditorRoles *frameCERole = new frmContactEditorRoles ( this );
746     frameCERole->SetEditorMode(FALSE, CE_WORK);
747     intResult = GetLastInt(&ContactEditorData.BusinessRoleList);
748     frameCERole->SetupPointers(&ContactEditorData.BusinessRoleList,
749                                &ContactEditorData.BusinessRoleListLanguage,
750                                &ContactEditorData.BusinessRoleListAltID,
751                                &ContactEditorData.BusinessRoleListPID,
752                                &ContactEditorData.BusinessRoleListType,
753                                &ContactEditorData.BusinessRoleListTokens,
754                                &ContactEditorData.BusinessRoleListPref,
755                                lboBusinessRoles,
756                                (intValueSeek));
757     frameCERole->ShowModal();
758     delete frameCERole;
759     frameCERole = NULL;
762 void frmContactEditor::ModifyBusinessRole( wxCommandEvent& event )
764     long longSelected = -1;
765     int intSelectedData = 0;
766     
767     if (!GetSelectedItem(lboBusinessRoles,
768                          &longSelected,
769                          &intSelectedData)){
770         return;
771     }
772     
773     frmContactEditorRoles *frameCERole = new frmContactEditorRoles ( this );
774     frameCERole->SetupPointers(&ContactEditorData.BusinessRoleList,
775                                &ContactEditorData.BusinessRoleListLanguage,
776                                &ContactEditorData.BusinessRoleListAltID,
777                                &ContactEditorData.BusinessRoleListPID,
778                                &ContactEditorData.BusinessRoleListType,
779                                &ContactEditorData.BusinessRoleListTokens,
780                                &ContactEditorData.BusinessRoleListPref,
781                                lboBusinessRoles,
782                                intSelectedData);
783     frameCERole->SetEditorMode(TRUE, CE_WORK);
784     frameCERole->ShowModal();
785     delete frameCERole;
786     frameCERole = NULL;
789 void frmContactEditor::DeleteBusinessRole( wxCommandEvent& event )
791     long longSelected = -1;
792     int intSelectedData = 0;
793     
794     if (!GetSelectedItem(lboBusinessRoles,
795                          &longSelected,
796                          &intSelectedData)){
797         return;
798     }
799     
800     lboBusinessRoles->DeleteItem(longSelected);
801     
802     DeleteMapData(intSelectedData, &ContactEditorData.BusinessRoleList,
803                   &ContactEditorData.BusinessRoleListLanguage, &ContactEditorData.BusinessRoleListAltID,
804                   &ContactEditorData.BusinessRoleListPID, &ContactEditorData.BusinessRoleListType,
805                   &ContactEditorData.BusinessRoleListTokens, &ContactEditorData.BusinessRoleListPref);
806     
809 void frmContactEditor::AddBusinessOrganisation( wxCommandEvent& event )
811     int intResult = 0;
812     
813     frmContactEditorOrganisations *frameCEOrg = new frmContactEditorOrganisations ( this );
814     frameCEOrg->SetEditorMode(FALSE, CE_WORK);
815     intResult = GetLastInt(&ContactEditorData.BusinessOrganisationsList);
816     frameCEOrg->SetupPointers(&ContactEditorData.BusinessOrganisationsList,
817                               &ContactEditorData.BusinessOrganisationsListLanguage,
818                               &ContactEditorData.BusinessOrganisationsListSortAs,
819                               &ContactEditorData.BusinessOrganisationsListAltID,
820                               &ContactEditorData.BusinessOrganisationsListPID,
821                               &ContactEditorData.BusinessOrganisationsListType,
822                               &ContactEditorData.BusinessOrganisationsListTokens,
823                               &ContactEditorData.BusinessOrganisationsListPref,
824                               lboBusinessOrganisations,
825                               (intValueSeek));
826     frameCEOrg->ShowModal();
827     delete frameCEOrg;
828     frameCEOrg = NULL;
831 void frmContactEditor::ModifyBusinessOrganisation( wxCommandEvent& event )
833     long longSelected = -1;
834     int intSelectedData = 0;
835     
836     if (!GetSelectedItem(lboBusinessOrganisations,
837                          &longSelected,
838                          &intSelectedData)){
839         return;
840     }
841     
842     frmContactEditorOrganisations *frameCEOrg = new frmContactEditorOrganisations ( this );
843     frameCEOrg->SetupPointers(&ContactEditorData.BusinessOrganisationsList,
844                               &ContactEditorData.BusinessOrganisationsListLanguage,
845                               &ContactEditorData.BusinessOrganisationsListSortAs,
846                               &ContactEditorData.BusinessOrganisationsListAltID,
847                               &ContactEditorData.BusinessOrganisationsListPID,
848                               &ContactEditorData.BusinessOrganisationsListType,
849                               &ContactEditorData.BusinessOrganisationsListTokens,
850                               &ContactEditorData.BusinessOrganisationsListPref,
851                               lboBusinessOrganisations,
852                               intSelectedData);
853     frameCEOrg->SetEditorMode(TRUE, CE_WORK);
854     frameCEOrg->ShowModal();
855     delete frameCEOrg;
856     frameCEOrg = NULL;
859 void frmContactEditor::DeleteBusinessOrganisation( wxCommandEvent& event )
861     long longSelected = -1;
862     int intSelectedData = 0;
863     
864     if (!GetSelectedItem(lboBusinessOrganisations,
865                          &longSelected,
866                          &intSelectedData)){
867         return;
868     }
869     
870     lboBusinessOrganisations->DeleteItem(longSelected);
871     
872     DeleteMapData(intSelectedData, &ContactEditorData.BusinessOrganisationsList,
873                   &ContactEditorData.BusinessOrganisationsListLanguage, &ContactEditorData.BusinessOrganisationsListSortAs,
874                   &ContactEditorData.BusinessOrganisationsListAltID, &ContactEditorData.BusinessOrganisationsListPID,
875                   &ContactEditorData.BusinessOrganisationsListType, &ContactEditorData.BusinessOrganisationsListTokens,
876                   &ContactEditorData.BusinessOrganisationsListPref);
877     
880 void frmContactEditor::AddBusinessNote( wxCommandEvent& event )
882     int intResult = 0;
883     
884     frmContactEditorNotes *frameCENote = new frmContactEditorNotes ( this );
885     frameCENote->SetEditorMode(FALSE, CE_WORK);
886     intResult = GetLastInt(&ContactEditorData.BusinessNoteList);
887     frameCENote->SetupPointers(&ContactEditorData.BusinessNoteList,
888                                &ContactEditorData.BusinessNoteListLanguage,
889                                &ContactEditorData.BusinessNoteListAltID,
890                                &ContactEditorData.BusinessNoteListPID,
891                                &ContactEditorData.BusinessNoteListType,
892                                &ContactEditorData.BusinessNoteListTokens,
893                                &ContactEditorData.BusinessNoteListPref,
894                                lboBusinessNotes,
895                                (intValueSeek));
896     frameCENote->ShowModal();
897     delete frameCENote;
898     frameCENote = NULL;
901 void frmContactEditor::ModifyBusinessNote( wxCommandEvent& event )
903     long longSelected = -1;
904     int intSelectedData = 0;
905     
906     if (!GetSelectedItem(lboBusinessNotes,
907                          &longSelected,
908                          &intSelectedData)){
909         return;
910     }
911     
912     frmContactEditorNotes *frameCENote = new frmContactEditorNotes ( this );
913     frameCENote->SetupPointers(&ContactEditorData.BusinessNoteList,
914                                &ContactEditorData.BusinessNoteListLanguage,
915                                &ContactEditorData.BusinessNoteListAltID,
916                                &ContactEditorData.BusinessNoteListPID,
917                                &ContactEditorData.BusinessNoteListType,
918                                &ContactEditorData.BusinessNoteListTokens,
919                                &ContactEditorData.BusinessNoteListPref,
920                                lboBusinessNotes,
921                                intSelectedData);
922     frameCENote->SetEditorMode(TRUE, CE_WORK);
923     frameCENote->ShowModal();
924     delete frameCENote;
925     frameCENote = NULL;
928 void frmContactEditor::DeleteBusinessNote( wxCommandEvent& event )
930     long longSelected = -1;
931     int intSelectedData = 0;
932     
933     if (!GetSelectedItem(lboBusinessNotes,
934                          &longSelected,
935                          &intSelectedData)){
936         return;
937     }
938     
939     lboBusinessNotes->DeleteItem(longSelected);
940     
941     DeleteMapData(intSelectedData, &ContactEditorData.BusinessNoteList,
942                   &ContactEditorData.BusinessNoteListLanguage, &ContactEditorData.BusinessNoteListAltID,
943                   &ContactEditorData.BusinessNoteListPID, &ContactEditorData.BusinessNoteListType,
944                   &ContactEditorData.BusinessNoteListTokens, &ContactEditorData.BusinessNoteListPref);
945     
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