diff --git a/ChangeLog b/ChangeLog index 37589dfb6..be8c221b4 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,20 @@ 2010-10-26 Wolfgang Sourdeau + * UI/WebServerResources/UIxPreferences.js: added code to handle + the new "Contacts Options" tab, in particular the contacts + categories. + + * UI/PreferencesUI/UIxPreferences.m (-languageCategories): renamed + to "_languageCalendarCategories" as it is a private method. The + dictionary key has also been renamed to + "calendar_category_labels" since we now handle contact categories + too. + (-calendarCategoriesValue, -setCalendarCategoriesValue:): renamed + from "categories" method. + (-contactsCategoryList, -contactsCategoriesValue) + (-setContactsCategoriesValue:): new methods for handling contacts + categories in the preferences. Transfers are in JSON. + * UI/WebServerResources/UIxContactEditor.js: (saveCategories) (appendCategoryInput, onComboButtonClick, onCategoryInputChange) (onCategoryInputFocus, regenerateCategoriesMenu) diff --git a/UI/PreferencesUI/BrazilianPortuguese.lproj/Localizable.strings b/UI/PreferencesUI/BrazilianPortuguese.lproj/Localizable.strings index be0e8057b..c7cce40d9 100644 --- a/UI/PreferencesUI/BrazilianPortuguese.lproj/Localizable.strings +++ b/UI/PreferencesUI/BrazilianPortuguese.lproj/Localizable.strings @@ -5,6 +5,7 @@ /* tabs */ "General" = "Geral"; "Calendar Options" = "Calendário"; +"Contacts Options" = "Contacts Options"; "Mail Options" = "Correio"; "IMAP Accounts" = "IMAP Accounts"; "Vacation" = "Vacation"; @@ -16,6 +17,9 @@ "Add" = "Add"; "Delete" = "Delete"; +/* contacts categories */ +"contacts_category_labels" = "Colleague, Competitor, Customer, Friend, Family, Business Partner, Provider, Press, VIP"; + /* vacation (auto-reply) */ "Enable vacation auto reply" = "Enable vacation auto reply"; "Auto reply message :" = "AutoResponder somente uma vez a cada remetente com o seguinte texto :"; @@ -153,7 +157,7 @@ /* Event+task categories */ "category_none" = "Nenhum"; -"category_labels" = "Aniversário,Negócios,Ligações,Concorrência,Cliente,Favoritos,Acompanhamento,Presentes,Feriados,Idéias,Meeting,Problemas,Miscelânea,Pessoal,Projetos,Feriado público,Posição,Fornecedores,Viagem,Férias"; +"calendar_category_labels" = "Aniversário,Negócios,Ligações,Concorrência,Cliente,Favoritos,Acompanhamento,Presentes,Feriados,Idéias,Meeting,Problemas,Miscelânea,Pessoal,Projetos,Feriado público,Posição,Fornecedores,Viagem,Férias"; /* Default module */ "Calendar" = "Calendar"; diff --git a/UI/PreferencesUI/Catalan.lproj/Localizable.strings b/UI/PreferencesUI/Catalan.lproj/Localizable.strings index c1d99fbec..6bf26e7d1 100644 --- a/UI/PreferencesUI/Catalan.lproj/Localizable.strings +++ b/UI/PreferencesUI/Catalan.lproj/Localizable.strings @@ -5,6 +5,7 @@ /* tabs */ "General" = "General"; "Calendar Options" = "Opcions de calendari"; +"Contacts Options" = "Contacts Options"; "Mail Options" = "Opcions de correu"; "IMAP Accounts" = "Comptes IMAP"; "Vacation" = "Vacances"; @@ -16,6 +17,9 @@ "Add" = "Afegir"; "Delete" = "Esborrar"; +/* contacts categories */ +"contacts_category_labels" = "Colleague, Competitor, Customer, Friend, Family, Business Partner, Provider, Press, VIP"; + /* vacation (auto-reply) */ "Enable vacation auto reply" = "Activar resposta automàtica"; "Auto reply message :" = "Respondre automàticament una sola vegada a cada remitent amb aquest text: "; @@ -155,7 +159,7 @@ /* Event+task categories */ "category_none" = "Cap"; -"category_labels" = "Aniversari,Natalici,Negocis,Telefonades,Clients,Competició,Feina,Favorits,Seguiment,Regals,Festes,Idees,Reunió,Assumptes,Altres,Personal,Projectes,Vacances públiques,Estat,Proveïdors,Viatges,Vacances"; +"calendar_category_labels" = "Aniversari,Natalici,Negocis,Telefonades,Clients,Competició,Feina,Favorits,Seguiment,Regals,Festes,Idees,Reunió,Assumptes,Altres,Personal,Projectes,Vacances públiques,Estat,Proveïdors,Viatges,Vacances"; /* Default module */ "Calendar" = "Calendari"; diff --git a/UI/PreferencesUI/Czech.lproj/Localizable.strings b/UI/PreferencesUI/Czech.lproj/Localizable.strings index a18d343d2..e38985351 100644 --- a/UI/PreferencesUI/Czech.lproj/Localizable.strings +++ b/UI/PreferencesUI/Czech.lproj/Localizable.strings @@ -5,6 +5,7 @@ /* tabs */ "General" = "Obecný"; "Calendar Options" = "Možnosti kalendáře"; +"Contacts Options" = "Contacts Options"; "Mail Options" = "Možnosti pošty"; "IMAP Accounts" = "IMAP Accounts"; "Vacation" = "Nepřítomnost"; @@ -16,6 +17,9 @@ "Add" = "Přidat"; "Delete" = "Smazat"; +/* contacts categories */ +"contacts_category_labels" = "Colleague, Competitor, Customer, Friend, Family, Business Partner, Provider, Press, VIP"; + /* vacation (auto-reply) */ "Enable vacation auto reply" = "Zapnout odpovědi v nepřítomnosti"; "Auto reply message :" = "Zpráva zasílaná v nepřítomnosti :"; @@ -153,7 +157,7 @@ /* Event+task categories */ "category_none" = "Žádný"; -"category_labels" = "Výročí,Narozeniny,Obchod,Hovory,Klienti,Soutěže,Zákazník,Oblíbené,Sledování,Dárky,Volno,Nápady,Meeting,Problémy,Různé,Osobní,Projekty,Veřejné prázdniny,Stav,Dodavatelé,Cesta,Dovolená"; +"calendar_category_labels" = "Výročí,Narozeniny,Obchod,Hovory,Klienti,Soutěže,Zákazník,Oblíbené,Sledování,Dárky,Volno,Nápady,Meeting,Problémy,Různé,Osobní,Projekty,Veřejné prázdniny,Stav,Dodavatelé,Cesta,Dovolená"; /* Default module */ "Calendar" = "Kalendář"; diff --git a/UI/PreferencesUI/Dutch.lproj/Localizable.strings b/UI/PreferencesUI/Dutch.lproj/Localizable.strings index 24702f28f..a41cdc332 100644 --- a/UI/PreferencesUI/Dutch.lproj/Localizable.strings +++ b/UI/PreferencesUI/Dutch.lproj/Localizable.strings @@ -5,6 +5,7 @@ /* tabs */ "General" = "Algemeen"; "Calendar Options" = "Agenda"; +"Contacts Options" = "Contacts Options"; "Mail Options" = "E-mail"; "IMAP Accounts" = "IMAP Accounts"; "Vacation" = "Vacation"; @@ -16,6 +17,9 @@ "Add" = "Add"; "Delete" = "Delete"; +/* contacts categories */ +"contacts_category_labels" = "Colleague, Competitor, Customer, Friend, Family, Business Partner, Provider, Press, VIP"; + /* vacation (auto-reply) */ "Enable vacation auto reply" = "Enable vacation auto reply"; "Auto reply message :" = "Automatisch eenmalig met het volgende bericht beantwoorden:"; @@ -153,7 +157,7 @@ /* Event+task categories */ "category_none" = "Geen categorie"; -"category_labels" = "Cliënten,Concurrentie,Diversen,Favorieten,Giften,Ideeën,Klant,Kwesties,Leveranciers,Nationale feestdag,Persoonlijk,Projecten,Meeting,Reizen,Status,Telefoongesprekken,Trouwdag,Vakantie,Verjaardag,Vervolggesprek,Vrije dagen,Zaken"; +"calendar_category_labels" = "Cliënten,Concurrentie,Diversen,Favorieten,Giften,Ideeën,Klant,Kwesties,Leveranciers,Nationale feestdag,Persoonlijk,Projecten,Meeting,Reizen,Status,Telefoongesprekken,Trouwdag,Vakantie,Verjaardag,Vervolggesprek,Vrije dagen,Zaken"; /* Default module */ "Calendar" = "Calendar"; diff --git a/UI/PreferencesUI/English.lproj/Localizable.strings b/UI/PreferencesUI/English.lproj/Localizable.strings index e30ac0065..8f4feb579 100644 --- a/UI/PreferencesUI/English.lproj/Localizable.strings +++ b/UI/PreferencesUI/English.lproj/Localizable.strings @@ -5,6 +5,7 @@ /* tabs */ "General" = "General"; "Calendar Options" = "Calendar Options"; +"Contacts Options" = "Contacts Options"; "Mail Options" = "Mail Options"; "IMAP Accounts" = "IMAP Accounts"; "Vacation" = "Vacation"; @@ -16,6 +17,9 @@ "Add" = "Add"; "Delete" = "Delete"; +/* contacts categories */ +"contacts_category_labels" = "Colleague, Competitor, Customer, Friend, Family, Business Partner, Provider, Press, VIP"; + /* vacation (auto-reply) */ "Enable vacation auto reply" = "Enable vacation auto reply"; "Auto reply message :" = "Auto reply message :"; @@ -153,7 +157,7 @@ /* Event+task categories */ "category_none" = "None"; -"category_labels" = "Anniversary,Birthday,Business,Calls,Clients,Competition,Customer,Favorites,Follow up,Gifts,Holidays,Ideas,Meeting,Issues,Miscellaneous,Personal,Projects,Public Holiday,Status,Suppliers,Travel,Vacation"; +"calendar_category_labels" = "Anniversary,Birthday,Business,Calls,Clients,Competition,Customer,Favorites,Follow up,Gifts,Holidays,Ideas,Meeting,Issues,Miscellaneous,Personal,Projects,Public Holiday,Status,Suppliers,Travel,Vacation"; /* Default module */ "Calendar" = "Calendar"; diff --git a/UI/PreferencesUI/French.lproj/Localizable.strings b/UI/PreferencesUI/French.lproj/Localizable.strings index 9a33d6b61..424bc2ba4 100644 --- a/UI/PreferencesUI/French.lproj/Localizable.strings +++ b/UI/PreferencesUI/French.lproj/Localizable.strings @@ -5,6 +5,7 @@ /* tabs */ "General" = "Général"; "Calendar Options" = "Calendrier"; +"Contacts Options" = "Contacts"; "Mail Options" = "Courrier"; "IMAP Accounts" = "Comptes IMAP"; "Vacation" = "Absence prolongée"; @@ -16,6 +17,9 @@ "Add" = "Ajouter"; "Delete" = "Supprimer"; +/* contacts categories */ +"contacts_category_labels" = "Ami, Client, Collègue, Concurrent, Famille, Fournisseur, Partenaire d'affaire, Presse, VIP"; + /* vacation (auto-reply) */ "Enable vacation auto reply" = "Activer message d'absense prolongée"; "Auto reply message :" = "Message de réponse automatique :"; @@ -151,7 +155,7 @@ /* Event+task categories */ "category_none" = "Aucune"; -"category_labels" = "Anniversaire,Affaire,Appels,Clients,Compétitions,Congrès,Consommation,Préférés,Suivis,Cadeaux,Congés,Idées,Problèmes,Réunion,Divers,Personnel,Projets,Jour férié,Statut,Fournisseurs,Voyages,Professionnel"; +"calendar_category_labels" = "Anniversaire,Affaire,Appels,Clients,Compétitions,Congrès,Consommation,Préférés,Suivis,Cadeaux,Congés,Idées,Problèmes,Réunion,Divers,Personnel,Projets,Jour férié,Statut,Fournisseurs,Voyages,Professionnel"; /* Default module */ "Calendar" = "Agenda"; diff --git a/UI/PreferencesUI/German.lproj/Localizable.strings b/UI/PreferencesUI/German.lproj/Localizable.strings index afdf4a8c2..cfb939155 100644 --- a/UI/PreferencesUI/German.lproj/Localizable.strings +++ b/UI/PreferencesUI/German.lproj/Localizable.strings @@ -5,6 +5,7 @@ /* tabs */ "General" = "Allgemein"; "Calendar Options" = "Kalender"; +"Contacts Options" = "Contacts Options"; "Mail Options" = "E-Mail"; "IMAP Accounts" = "IMAP-Konten"; "Vacation" = "Abwesenheit"; @@ -16,6 +17,9 @@ "Add" = "Hinzufügen"; "Delete" = "Löschen"; +/* contacts categories */ +"contacts_category_labels" = "Geschäftspartner, Familie, Freund, Kollegin, Konkurrenten, Kunden, Lieferant, Presse, VIP"; + /* vacation (auto-reply) */ "Enable vacation auto reply" = "Automatische Abwesenheitsantwort aktivieren"; "Auto reply message :" = "Folgende Antwort wird automatisch einmal an jeden Absender gesendet:"; @@ -152,7 +156,7 @@ /* Event+task categories */ "category_none" = "Keine"; -"category_labels" = "Jubiläum,Geburtstag,Geschäft,Anrufe,Klienten,Konkurrenz,Kunde,Favoriten,Nachgehen,Geschenke,Ferien,Ideen,Meeting,Fragen,Verschiedenes,Persönlich,Projekte,Feiertag,Status,Lieferanten,Reise,Urlaub"; +"calendar_category_labels" = "Jubiläum,Geburtstag,Geschäft,Anrufe,Klienten,Konkurrenz,Kunde,Favoriten,Nachgehen,Geschenke,Ferien,Ideen,Meeting,Fragen,Verschiedenes,Persönlich,Projekte,Feiertag,Status,Lieferanten,Reise,Urlaub"; /* Default module */ "Calendar" = "Kalender"; diff --git a/UI/PreferencesUI/Hungarian.lproj/Localizable.strings b/UI/PreferencesUI/Hungarian.lproj/Localizable.strings index 24fba5e78..46d64c3f8 100644 --- a/UI/PreferencesUI/Hungarian.lproj/Localizable.strings +++ b/UI/PreferencesUI/Hungarian.lproj/Localizable.strings @@ -5,6 +5,7 @@ /* tabs */ "General" = "Általános"; "Calendar Options" = "Naptár"; +"Contacts Options" = "Contacts Options"; "Mail Options" = "Levelezés"; "IMAP Accounts" = "IMAP Accounts"; "Password" = "Jelszó"; @@ -14,8 +15,25 @@ "Add" = "Add"; "Delete" = "Delete"; -/* ooo */ -"Auto reply messsage :" = "Automatikus válasz minden feladónak csak egy alkalommal :"; +/* contacts categories */ +"contacts_category_labels" = "Colleague, Competitor, Customer, Friend, Family, Business Partner, Provider, Press, VIP"; + +/* vacation (auto-reply) */ +"Enable vacation auto reply" = "Enable vacation auto reply"; +"Auto reply message :" = "Automatikus válasz minden feladónak csak egy alkalommal :"; +"Email addresses (separated by commas) :" = "Email addresses (separated by commas) :"; +"Add default email addresses" = "Add default email addresses"; +"Days between responses :" = "Days between responses :"; +"Do not send responses to mailing lists" = "Do not send responses to mailing lists"; +"Please specify your message and your email addresses for which you want to enable auto reply." += "Please specify your message and your email addresses for which you want to enable auto reply."; + +/* forward messages */ +"Forward incoming messages" = "Forward incoming messages"; +"Forward to address :" = "Forward to address :"; +"Keep a copy" = "Keep a copy"; +"Please specify an address to which you want to forward your messages." += "Please specify an address to which you want to forward your messages."; /* d & t */ "Current Time Zone :" = "Időzóna :"; @@ -137,7 +155,7 @@ /* Event+task categories */ "category_none" = "Nincs"; -"category_labels" = "Évforduló,Születésnap,Üzleti,Meghívás,Ügyfelek,Versenytársak,Vevő,Kedvencek,Nyomonkövetés,Ajándékozás,Szabadság,Ötletek,Meeting,Ügyek,Egyéb,Személyes,Projektek,Állami ünnep,Állapot,Szállítók,Utazás,Szünidő"; +"calendar_category_labels" = "Évforduló,Születésnap,Üzleti,Meghívás,Ügyfelek,Versenytársak,Vevő,Kedvencek,Nyomonkövetés,Ajándékozás,Szabadság,Ötletek,Meeting,Ügyek,Egyéb,Személyes,Projektek,Állami ünnep,Állapot,Szállítók,Utazás,Szünidő"; /* Default module */ "Calendar" = "Calendar"; diff --git a/UI/PreferencesUI/Italian.lproj/Localizable.strings b/UI/PreferencesUI/Italian.lproj/Localizable.strings index dbcf031e9..6b96ca699 100644 --- a/UI/PreferencesUI/Italian.lproj/Localizable.strings +++ b/UI/PreferencesUI/Italian.lproj/Localizable.strings @@ -5,6 +5,7 @@ /* tabs */ "General" = "Generale"; "Calendar Options" = "Opzioni calendario"; +"Contacts Options" = "Contacts Options"; "Mail Options" = "Opzioni di posta"; "Signature" = "Firma"; "Vacation" = "Risponditore automatico"; @@ -17,6 +18,9 @@ "Add" = "Aggiungi"; "Delete" = "Cancella"; +/* contacts categories */ +"contacts_category_labels" = "Colleague, Competitor, Customer, Friend, Family, Business Partner, Provider, Press, VIP"; + /* vacation (auto-reply) */ "Enable vacation auto reply" = "Abilita il risponditore automatico"; "Auto reply message :" = "Rispondi automaticamente solo una volta ad ogni mittente usando questo testo:"; @@ -143,7 +147,7 @@ /* Event+task categories */ "category_none" = "Nessuna"; -"category_labels" = "Anniversari,Compleanni,Lavoro,Chiamate,Clienti,Competizioni,Compratori,Preferiti,Incontri,Regali,Vacanze,Idee,Meeting,Problemi,Varie,Personale,Progetti,Giorno festivo,Stato,Fornitori,Viaggio,Chiusura"; +"calendar_category_labels" = "Anniversari,Compleanni,Lavoro,Chiamate,Clienti,Competizioni,Compratori,Preferiti,Incontri,Regali,Vacanze,Idee,Meeting,Problemi,Varie,Personale,Progetti,Giorno festivo,Stato,Fornitori,Viaggio,Chiusura"; /* Default module */ "Calendar" = "Calendario"; diff --git a/UI/PreferencesUI/Polish.lproj/Localizable.strings b/UI/PreferencesUI/Polish.lproj/Localizable.strings index 6f744cbf2..0560982b4 100644 --- a/UI/PreferencesUI/Polish.lproj/Localizable.strings +++ b/UI/PreferencesUI/Polish.lproj/Localizable.strings @@ -5,6 +5,7 @@ /* tabs */ "General" = "Ogólne"; "Calendar Options" = "Opcje kalendarza"; +"Contacts Options" = "Contacts Options"; "Mail Options" = "Opcje poczty"; "Signature" = "Podpis"; "Vacation" = "Nieobecność"; @@ -17,6 +18,9 @@ "Add" = "Dodaj"; "Delete" = "Usuń"; +/* contacts categories */ +"contacts_category_labels" = "Colleague, Competitor, Customer, Friend, Family, Business Partner, Provider, Press, VIP"; + /* vacation (auto-reply) */ "Enable vacation auto reply" = "Włącz autoodpowiedź podczas nieobecności"; "Auto reply message :" = "Treść autoodpowiedzi :"; @@ -143,7 +147,7 @@ /* Event+task categories */ "category_none" = "Brak"; -"category_labels" = "Rocznica,Urodziny,Biznes,Telefony,Klienci,Konkurencja,Klient,Ulubione,Nawiązanie,Podarunki,Święta,Idee,Spotkania,Problemy,Różne,Osobiste,Projekty,Święta,Status,Dostawcy,Podróż,Wakacje"; +"calendar_category_labels" = "Rocznica,Urodziny,Biznes,Telefony,Klienci,Konkurencja,Klient,Ulubione,Nawiązanie,Podarunki,Święta,Idee,Spotkania,Problemy,Różne,Osobiste,Projekty,Święta,Status,Dostawcy,Podróż,Wakacje"; /* Default module */ "Calendar" = "Kalendarz"; diff --git a/UI/PreferencesUI/Russian.lproj/Localizable.strings b/UI/PreferencesUI/Russian.lproj/Localizable.strings index 73844890b..40c23bd90 100644 --- a/UI/PreferencesUI/Russian.lproj/Localizable.strings +++ b/UI/PreferencesUI/Russian.lproj/Localizable.strings @@ -5,6 +5,7 @@ /* tabs */ "General" = "Общее"; "Calendar Options" = "Календарь"; +"Contacts Options" = "Contacts Options"; "Mail Options" = "Почта"; "IMAP Accounts" = "IMAP Accounts"; "Vacation" = "Vacation"; @@ -16,6 +17,9 @@ "Add" = "Add"; "Delete" = "Delete"; +/* contacts categories */ +"contacts_category_labels" = "Colleague, Competitor, Customer, Friend, Family, Business Partner, Provider, Press, VIP"; + /* vacation (auto-reply) */ "Enable vacation auto reply" = "Enable vacation auto reply"; "Auto reply message :" = "Автоматически посылать этот текст каждому отправителю один раз :"; @@ -158,7 +162,7 @@ /* Event+task categories */ "category_none" = "None"; -"category_labels" = "Anniversary,Birthday,Business,Calls,Clients,Competition,Customer,Favorites,Follow up,Gifts,Holidays,Ideas,Meeting,Issues,Miscellaneous,Personal,Projects,Public Holiday,Status,Suppliers,Travel,Vacation"; +"calendar_category_labels" = "Anniversary,Birthday,Business,Calls,Clients,Competition,Customer,Favorites,Follow up,Gifts,Holidays,Ideas,Meeting,Issues,Miscellaneous,Personal,Projects,Public Holiday,Status,Suppliers,Travel,Vacation"; /* Default module */ "Calendar" = "Calendar"; diff --git a/UI/PreferencesUI/Spanish.lproj/Localizable.strings b/UI/PreferencesUI/Spanish.lproj/Localizable.strings index b56bf4e94..c9f3caa3e 100644 --- a/UI/PreferencesUI/Spanish.lproj/Localizable.strings +++ b/UI/PreferencesUI/Spanish.lproj/Localizable.strings @@ -5,6 +5,7 @@ /* tabs */ "General" = "General"; "Calendar Options" = "Opciones de calendario"; +"Contacts Options" = "Contacts Options"; "Mail Options" = "Opciones de correo"; "IMAP Accounts" = "IMAP Accounts"; "Vacation" = "Vacation"; @@ -16,6 +17,9 @@ "Add" = "Add"; "Delete" = "Delete"; +/* contacts categories */ +"contacts_category_labels" = "Colleague, Competitor, Customer, Friend, Family, Business Partner, Provider, Press, VIP"; + /* vacation (auto-reply) */ "Enable vacation auto reply" = "Enable vacation auto reply"; "Auto reply message :" = "Responder automáticamente una sola vez a cada remitente con el siguiente texto: "; @@ -155,7 +159,7 @@ /* Event+task categories */ "category_none" = "Ninguna"; -"category_labels" = "Aniversario,Cumpleaños,Negocios,Llamadas,Clientes,Competición,Trabajo,Favoritos,Seguimiento,Regalos,Fiestas,Ideas,Meeting,Asuntos,Varios,Personal,Proyectos,Vacaciones públicas,Estado,Proveedores,Viajes,Vacaciones"; +"calendar_category_labels" = "Aniversario,Cumpleaños,Negocios,Llamadas,Clientes,Competición,Trabajo,Favoritos,Seguimiento,Regalos,Fiestas,Ideas,Meeting,Asuntos,Varios,Personal,Proyectos,Vacaciones públicas,Estado,Proveedores,Viajes,Vacaciones"; /* Default module */ "Calendar" = "Calendar"; diff --git a/UI/PreferencesUI/Swedish.lproj/Localizable.strings b/UI/PreferencesUI/Swedish.lproj/Localizable.strings index 09b5b8642..184044c93 100644 --- a/UI/PreferencesUI/Swedish.lproj/Localizable.strings +++ b/UI/PreferencesUI/Swedish.lproj/Localizable.strings @@ -5,6 +5,7 @@ /* tabs */ "General" = "Allmänt"; "Calendar Options" = "Kalenderinställningar"; +"Contacts Options" = "Contacts Options"; "Mail Options" = "E-postinställningar"; "IMAP Accounts" = "IMAP Accounts"; "Vacation" = "Frånvaro"; @@ -16,6 +17,9 @@ "Add" = "Lägg till"; "Delete" = "Ta bort"; +/* contacts categories */ +"contacts_category_labels" = "Colleague, Competitor, Customer, Friend, Family, Business Partner, Provider, Press, VIP"; + /* vacation (auto-reply) */ "Enable vacation auto reply" = "Aktivera frånvaro auto-svar"; "Auto reply message :" = "Auto-svar meddelande:"; @@ -153,7 +157,7 @@ /* Event+task categories */ "category_none" = "Ingen"; -"category_labels" = "Arbete,Diverse,Favoriter,Födelsedagar,Helgdagar,Idéer,Kunder,Ledighet,Leverantörer,Personligt,Presenter,Projekt,Meeting,Resor,Status,Telefonsamtal,Tävlingar,Uppföljning,Ärenden"; +"calendar_category_labels" = "Arbete,Diverse,Favoriter,Födelsedagar,Helgdagar,Idéer,Kunder,Ledighet,Leverantörer,Personligt,Presenter,Projekt,Meeting,Resor,Status,Telefonsamtal,Tävlingar,Uppföljning,Ärenden"; /* Default module */ "Calendar" = "Kalender"; diff --git a/UI/PreferencesUI/UIxPreferences.h b/UI/PreferencesUI/UIxPreferences.h index a724635e2..54465623b 100644 --- a/UI/PreferencesUI/UIxPreferences.h +++ b/UI/PreferencesUI/UIxPreferences.h @@ -35,9 +35,10 @@ id item; SOGoUser *user; NSDictionary *locale; + NSString *category; NSArray *calendarCategories; NSDictionary *calendarCategoriesColors; - NSString *category; + NSArray *contactsCategories; NSString *defaultCategoryColor; SOGoUserDefaults *userDefaults; NSCalendarDate *today; diff --git a/UI/PreferencesUI/UIxPreferences.m b/UI/PreferencesUI/UIxPreferences.m index ecf2909f0..77893bc63 100644 --- a/UI/PreferencesUI/UIxPreferences.m +++ b/UI/PreferencesUI/UIxPreferences.m @@ -22,7 +22,6 @@ #import #import -#import #import #import #import /* for locale strings */ @@ -36,7 +35,6 @@ #import #import #import -#import #import #import #import @@ -123,6 +121,7 @@ [calendarCategoriesColors release]; [defaultCategoryColor release]; [category release]; + [contactsCategories release]; [forwardOptions release]; [daysOfWeek release]; [locale release]; @@ -672,13 +671,13 @@ - (void) setSieveFiltersValue: (NSString *) newValue { - NSScanner *jsonScanner; - - if ([newValue hasPrefix: @"["]) + sieveFilters = [newValue objectFromJSONString]; + if (sieveFilters) { - jsonScanner = [NSScanner scannerWithString: newValue]; - [jsonScanner scanJSONArray: &sieveFilters]; - [sieveFilters retain]; + if ([sieveFilters isKindOfClass: [NSArray class]]) + [sieveFilters retain]; + else + sieveFilters = nil; } } @@ -967,23 +966,23 @@ return [locale objectForKey: @"NSLocaleCode"]; } -- (NSArray *) languageCategories +- (NSArray *) _languageCalendarCategories { NSArray *categoryLabels; - categoryLabels = [[self labelForKey: @"category_labels"] + categoryLabels = [[self labelForKey: @"calendar_category_labels"] componentsSeparatedByString: @","]; return [categoryLabels trimmedComponents]; } -- (NSArray *) categoryList +- (NSArray *) calendarCategoryList { if (!calendarCategories) { ASSIGN (calendarCategories, [userDefaults calendarCategories]); if (!calendarCategories) - ASSIGN (calendarCategories, [self languageCategories]); + ASSIGN (calendarCategories, [self _languageCalendarCategories]); } return [calendarCategories @@ -1022,23 +1021,62 @@ return categoryColor; } -- (NSString *) categoriesValue +- (NSString *) calendarCategoriesValue { return @""; } -- (void) setCategoriesValue: (NSString *) value +- (void) setCalendarCategoriesValue: (NSString *) value { NSDictionary *newColors; - newColors = [NSMutableDictionary dictionaryWithJSONString: value]; - if (newColors) + newColors = [value objectFromJSONString]; + if (newColors && [newColors isKindOfClass: [NSDictionary class]]) { [userDefaults setCalendarCategories: [newColors allKeys]]; [userDefaults setCalendarCategoriesColors: newColors]; } } +- (NSArray *) _languageContactsCategories +{ + NSArray *categoryLabels; + + categoryLabels = [[self labelForKey: @"contacts_category_labels"] + componentsSeparatedByString: @","]; + if (!categoryLabels) + categoryLabels = [NSArray array]; + + return [categoryLabels trimmedComponents]; +} + +- (NSArray *) contactsCategoryList +{ + if (!contactsCategories) + { + ASSIGN (contactsCategories, [userDefaults contactsCategories]); + if (!contactsCategories) + ASSIGN (contactsCategories, [self _languageContactsCategories]); + } + + return [contactsCategories + sortedArrayUsingSelector: @selector (localizedCaseInsensitiveCompare:)]; +} + +- (NSString *) contactsCategoriesValue +{ + return @""; +} + +- (void) setContactsCategoriesValue: (NSString *) value +{ + NSArray *newCategories; + + newCategories = [value objectFromJSONString]; + if (newCategories && [newCategories isKindOfClass: [NSArray class]]) + [userDefaults setContactsCategories: newCategories]; +} + - (NSArray *) languages { return [[SOGoSystemDefaults sharedSystemDefaults] @@ -1284,11 +1322,9 @@ - (void) setMailAccounts: (NSString *) newMailAccounts { NSArray *accounts; - NSScanner *scanner; int max; - scanner = [NSScanner scannerWithString: newMailAccounts]; - [scanner scanJSONArray: &accounts]; + accounts = [newMailAccounts objectFromJSONString]; if (accounts && [accounts isKindOfClass: [NSArray class]]) { max = [accounts count]; diff --git a/UI/PreferencesUI/Ukrainian.lproj/Localizable.strings b/UI/PreferencesUI/Ukrainian.lproj/Localizable.strings index 622e7dccd..f7d96e859 100644 --- a/UI/PreferencesUI/Ukrainian.lproj/Localizable.strings +++ b/UI/PreferencesUI/Ukrainian.lproj/Localizable.strings @@ -5,6 +5,7 @@ /* tabs */ "General" = "Загальне"; "Calendar Options" = "Календар"; +"Contacts Options" = "Contacts Options"; "Mail Options" = "Пошта"; "IMAP Accounts" = "IMAP-записи"; "Vacation" = "Відпустка"; @@ -18,6 +19,9 @@ "Cancel" = "Скасувати"; "OK" = "Добре"; +/* contacts categories */ +"contacts_category_labels" = "Colleague, Competitor, Customer, Friend, Family, Business Partner, Provider, Press, VIP"; + /* vacation (auto-reply) */ "Enable vacation auto reply" = "Увімкнути повідомлення про мою відсутність"; "Auto reply message :" = "Текст автоматичної відповіді:"; @@ -155,7 +159,7 @@ /* Event+task categories */ "category_none" = "Без категорії"; -"category_labels" = "Важливий день,День народження,Справи,Дзвінки,Клієнти,Поточне,Користувачі,Обране,Продовження,Подарунки,Свято,Думки,Зустріч,Питання,Різне,Особисте,Проекти,Публічне свято,Поточне,Постачальники,Поїздка,Відпустка"; +"calendar_category_labels" = "Важливий день,День народження,Справи,Дзвінки,Клієнти,Поточне,Користувачі,Обране,Продовження,Подарунки,Свято,Думки,Зустріч,Питання,Різне,Особисте,Проекти,Публічне свято,Поточне,Постачальники,Поїздка,Відпустка"; /* Default module */ "Calendar" = "Календар"; diff --git a/UI/PreferencesUI/Welsh.lproj/Localizable.strings b/UI/PreferencesUI/Welsh.lproj/Localizable.strings index 252dffa22..ba9e931be 100644 --- a/UI/PreferencesUI/Welsh.lproj/Localizable.strings +++ b/UI/PreferencesUI/Welsh.lproj/Localizable.strings @@ -5,6 +5,7 @@ /* tabs */ "General" = "Cyffredinol"; "Calendar Options" = "Opsiynau Calendr"; +"Contacts Options" = "Contacts Options"; "Mail Options" = "Opsiynau Ebost"; "IMAP Accounts" = "IMAP Accounts"; "Vacation" = "Vacation"; @@ -16,6 +17,9 @@ "Add" = "Add"; "Delete" = "Delete"; +/* contacts categories */ +"contacts_category_labels" = "Colleague, Competitor, Customer, Friend, Family, Business Partner, Provider, Press, VIP"; + /* vacation (auto-reply) */ "Enable vacation auto reply" = "Enable vacation auto reply"; "Auto reply message :" = "Ymateb Awtomatig unwaith yn unig i pob anfonwr gyda'r testun canlynol :"; @@ -153,7 +157,7 @@ /* Event+task categories */ "category_none" = "Dim"; -"category_labels" = "Amrywiol,Anrhegion,Busnes,Canlyniadau,Clientau,Cwsmer,Cyflenwyr,Cystadleuaeth,Dilyn lan,Ffefrynnau,Galwadau,Gwyliau,Meeting,Gwyliau Cyhoeddus,Penblwydd,Personol,Projectau,Statws,Syniadau,Teithio"; +"calendar_category_labels" = "Amrywiol,Anrhegion,Busnes,Canlyniadau,Clientau,Cwsmer,Cyflenwyr,Cystadleuaeth,Dilyn lan,Ffefrynnau,Galwadau,Gwyliau,Meeting,Gwyliau Cyhoeddus,Penblwydd,Personol,Projectau,Statws,Syniadau,Teithio"; /* Default module */ "Calendar" = "Calendar"; diff --git a/UI/Templates/ContactsUI/UIxContactEditor.wox b/UI/Templates/ContactsUI/UIxContactEditor.wox index 91360ae76..f498774d4 100644 --- a/UI/Templates/ContactsUI/UIxContactEditor.wox +++ b/UI/Templates/ContactsUI/UIxContactEditor.wox @@ -10,8 +10,10 @@ title="name" const:popup="YES" > -
+ +
@@ -27,6 +29,8 @@
  • +
  • +
  • @@ -171,6 +175,21 @@
  • +
    +
    +
    + + + +
    +
    diff --git a/UI/Templates/PreferencesUI/UIxPreferences.wox b/UI/Templates/PreferencesUI/UIxPreferences.wox index e0c903700..f0fdfe50c 100644 --- a/UI/Templates/PreferencesUI/UIxPreferences.wox +++ b/UI/Templates/PreferencesUI/UIxPreferences.wox @@ -24,6 +24,8 @@
  • @@ -101,8 +103,8 @@ string="itemFirstWeekText" selection="userFirstWeek" />
    -
    +
    - +
    - -
    + +
    + +
    + + + + + + + +
    +
    + + +
    +