1
0
mirror of https://github.com/owncloudarchive/contacts.git synced 2024-12-01 13:24:10 +01:00
This commit is contained in:
Nicolas Mora 2013-11-08 11:20:25 -05:00
commit 90e8773ec3
15 changed files with 352 additions and 235 deletions

View File

@ -36,7 +36,9 @@
"Edit profile picture" => "Redigér profilbillede",
"Crop photo" => "Beskær billede",
"Is this correct?" => "Er dette korrekt?",
"Error parsing date: {date}" => "Fejl under læsning af dato: {date}",
"# groups" => "# grupper",
"Error parsing birthday {bday}: {error}" => "Fejl under læsning af fødselsdato: {bday}: {error}",
"Some contacts are marked for deletion, but not deleted yet. Please wait for them to be deleted." => "Nogle kontakter er markeret til sletning, men er endnu ikke slettet. Vent venligst på, at de bliver slettet.",
"Click to undo deletion of {num} contacts" => "Klik for at fortryde sletning af {num} kontakter",
"Cancelled deletion of {num} contacts" => "annullerede sletning af {num} kontakter",
@ -144,6 +146,7 @@
"Error moving file to imports folder." => "Kunne ikke flytte filer til importmappe.",
"You do not have permissions to import into this address book." => "Du har ikke rettigheder til at importere til denne adressebog",
"File name missing from request." => "Filnavn mangler fra forespørgsel.",
"Progress key missing from request." => "Fremskridts nøglen mangler fra anmodningen.",
"Attempt to access blacklisted file:" => "Forsøg på at tilgå sortlistet fil:",
"No contacts found in: " => "Ingen kontaktpersoner fundet i:",
"No key is given." => "Ingen værdi er givet.",
@ -214,6 +217,7 @@
"Edit current photo" => "Rediger nuværende foto",
"Upload new photo" => "Upload nyt foto",
"Select photo from ownCloud" => "Vælg foto fra ownCloud",
"Name" => "Navn",
"First name" => "Fornavn",
"Additional names" => "Mellemnavne",
"Last name" => "Efternavn",
@ -269,6 +273,5 @@
"iOS/OS X" => "iOS/OS X",
"Addressbooks" => "Adressebøger",
"New Address Book" => "Ny adressebog",
"Name" => "Navn",
"Description" => "Beskrivelse"
);

View File

@ -8,6 +8,7 @@
# claus_chr <claus_chr@webspeed.dk>, 2013
# claus_chr <claus_chr@webspeed.dk>, 2012
# cronner <cronner@gmail.com>, 2012
# kaffeldt <kasper.affeldt@gmail.com>, 2013
# mikkel_ilu <mikkelbjerglarsen@gmail.com>, 2011
# Morten Juhl-Johansen Zölde-Fejér <morten@writtenandread.net>, 2011-2012
# Ole Holm Frandsen <froksen@gmail.com>, 2012-2013
@ -19,10 +20,10 @@
msgid ""
msgstr ""
"Project-Id-Version: ownCloud\n"
"Report-Msgid-Bugs-To: http://bugs.owncloud.org/\n"
"POT-Creation-Date: 2013-10-29 04:34-0400\n"
"PO-Revision-Date: 2013-10-28 10:42+0000\n"
"Last-Translator: Ole Holm Frandsen <froksen@gmail.com>\n"
"Report-Msgid-Bugs-To: translations@owncloud.org\n"
"POT-Creation-Date: 2013-11-06 19:39-0500\n"
"PO-Revision-Date: 2013-11-03 19:10+0000\n"
"Last-Translator: kaffeldt <kasper.affeldt@gmail.com>\n"
"Language-Team: Danish (http://www.transifex.com/projects/p/owncloud/language/da/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
@ -122,7 +123,7 @@ msgstr "Indfletning lykkedes ikke. Fejl ved gemning af kontakt."
msgid "Select photo"
msgstr "Vælg foto"
#: js/app.js:678 js/app.js:1590
#: js/app.js:678 js/app.js:1570
msgid "Network or server error. Please inform administrator."
msgstr "Netværks- eller serverfejl: Informér administrator."
@ -134,46 +135,46 @@ msgstr "Fejl ved tilføjelse til gruppe."
msgid "Error removing from group."
msgstr "Fejl ved fjernelse fra gruppe."
#: js/app.js:1095
#: js/app.js:1104
msgid "Error setting {name} as favorite."
msgstr "Kunne ikke indstille {name} som favorit."
#: js/app.js:1234 js/app.js:1238 templates/contacts.php:182
#: js/app.js:1243 js/app.js:1247 templates/contacts.php:182
msgid "Merge contacts"
msgstr "Sammenlæg kontakter"
#: js/app.js:1260 js/app.js:1313 js/settings.js:120 templates/contacts.php:321
#: js/app.js:1269 js/app.js:1322 js/settings.js:120 templates/contacts.php:321
#: templates/settings.php:62
msgid "Cancel"
msgstr "Annuller"
#: js/app.js:1287 templates/contacts.php:163
#: js/app.js:1296 templates/contacts.php:163
msgid "Add group"
msgstr "Tilføj gruppe"
#: js/app.js:1291
#: js/app.js:1300
msgid "OK"
msgstr "OK"
#: js/app.js:1391
#: js/app.js:1394
msgid "Could not find contact: {id}"
msgstr "Kunne ikke finde kontakt: {id}"
#: js/app.js:1437
#: js/app.js:1417
msgid "No files selected for upload."
msgstr "Der er ikke valgt nogen filer at uploade."
#: js/app.js:1447
#: js/app.js:1427
msgid ""
"The file you are trying to upload exceed the maximum size for file uploads "
"on this server."
msgstr "Dr."
#: js/app.js:1548
#: js/app.js:1528
msgid "Edit profile picture"
msgstr "Redigér profilbillede"
#: js/app.js:1552
#: js/app.js:1532
msgid "Crop photo"
msgstr "Beskær billede"
@ -181,29 +182,29 @@ msgstr "Beskær billede"
msgid "Is this correct?"
msgstr "Er dette korrekt?"
#: js/contacts.js:858
#: js/contacts.js:856
msgid "Error parsing date: {date}"
msgstr ""
msgstr "Fejl under læsning af dato: {date}"
#: js/contacts.js:1055
#: js/contacts.js:1053
msgid "# groups"
msgstr "# grupper"
#: js/contacts.js:1127
#: js/contacts.js:1125
msgid "Error parsing birthday {bday}: {error}"
msgstr ""
msgstr "Fejl under læsning af fødselsdato: {bday}: {error}"
#: js/contacts.js:2163
#: js/contacts.js:2162
msgid ""
"Some contacts are marked for deletion, but not deleted yet. Please wait for "
"them to be deleted."
msgstr "Nogle kontakter er markeret til sletning, men er endnu ikke slettet. Vent venligst på, at de bliver slettet."
#: js/contacts.js:2174
#: js/contacts.js:2173
msgid "Click to undo deletion of {num} contacts"
msgstr "Klik for at fortryde sletning af {num} kontakter"
#: js/contacts.js:2183
#: js/contacts.js:2182
msgid "Cancelled deletion of {num} contacts"
msgstr "annullerede sletning af {num} kontakter"
@ -366,7 +367,7 @@ msgstr "Du har ikke rettigheder til at føje kontaktpersoner til denne adressebo
msgid "The backend for this address book does not support adding contacts"
msgstr "Denne adressebogs system understøtter ikke tilføjelse af kontakter"
#: lib/addressbook.php:240 lib/addressbook.php:266 lib/contact.php:248
#: lib/addressbook.php:240 lib/addressbook.php:266 lib/contact.php:245
msgid "You do not have permissions to delete this contact"
msgstr "Du har ikke rettigheder til at slette denne kontaktperson"
@ -394,35 +395,35 @@ msgstr "Du har ikke rettigheder til at slette denne adressebog"
msgid "Address book not found"
msgstr "Adressebog ikke fundet"
#: lib/contact.php:114 lib/contact.php:161
#: lib/contact.php:111 lib/contact.php:158
msgid "You do not have permissions to see this contact"
msgstr "Du har ikke rettigheder til at se denne kontaktperson"
#: lib/contact.php:263
#: lib/contact.php:260
msgid "You do not have permissions to update this contact"
msgstr "Du har ikke rettigheder til at opdatere denne kontaktperson"
#: lib/contact.php:274
#: lib/contact.php:271
msgid "The backend for this contact does not support updating it"
msgstr "Systemet for denne kontakt understøtter ikke opdatering"
#: lib/contact.php:292
#: lib/contact.php:289
msgid "This backend not support adding contacts"
msgstr "Dette system understøtter ikke tilføjelse af kontakter"
#: lib/contact.php:402 lib/contact.php:419
#: lib/contact.php:399 lib/contact.php:416
msgid "Property not found"
msgstr "Egenskab ikke fundet"
#: lib/contact.php:467
#: lib/contact.php:464
msgid " Missing IM parameter for: "
msgstr "Manglende IM-parameter for:"
#: lib/contact.php:475
#: lib/contact.php:472
msgid "Unknown IM: "
msgstr "Ukendt IM:"
#: lib/contact.php:788
#: lib/contact.php:742
msgid "{name}'s Birthday"
msgstr "{name}s fødselsdag"
@ -653,7 +654,7 @@ msgstr "Filnavn mangler fra forespørgsel."
#: lib/controller/importcontroller.php:167
#: lib/controller/importcontroller.php:283
msgid "Progress key missing from request."
msgstr ""
msgstr "Fremskridts nøglen mangler fra anmodningen."
#: lib/controller/importcontroller.php:173
msgid "Attempt to access blacklisted file:"
@ -943,6 +944,10 @@ msgstr "Upload nyt foto"
msgid "Select photo from ownCloud"
msgstr "Vælg foto fra ownCloud"
#: templates/contacts.php:233 templates/settings.php:59
msgid "Name"
msgstr "Navn"
#: templates/contacts.php:239 templates/contacts.php:240
msgid "First name"
msgstr "Fornavn"
@ -1165,10 +1170,6 @@ msgstr "Adressebøger"
msgid "New Address Book"
msgstr "Ny adressebog"
#: templates/settings.php:59
msgid "Name"
msgstr "Navn"
#: templates/settings.php:60
msgid "Description"
msgstr "Beskrivelse"

View File

@ -5,6 +5,7 @@
"Importing..." => "Inportatzen",
"Imported {count} of {total} contacts" => "{total} kontaktuetatik {count} inportatuak",
"Indexing contacts" => "Kontaktuak indexatzen",
"Error." => "Akatsa.",
"Add to..." => "Gehitu hemen...",
"Remove from..." => "Ezabatu hemendik...",
"Add group..." => "Gehitu taldea...",
@ -13,13 +14,16 @@
"Network or server error. Please inform administrator." => "Errore bat izan da sare edo zerbitzarian. Mesedez abisatu administradorea.",
"Error adding to group." => "Errore bat izan da taldera gehitzean.",
"Error removing from group." => "Errore bat izan da taldetik kentzean.",
"Merge contacts" => "Kontaktuak batu",
"Cancel" => "Ezeztatu",
"Add group" => "Gehitu taldea",
"OK" => "Ados",
"Could not find contact: {id}" => "Ezin izan dugu kontaktua topatu: {id}",
"No files selected for upload." => "Ez duzu igotzeko fitxategirik hautatu.",
"The file you are trying to upload exceed the maximum size for file uploads on this server." => "Igo nahi duzun fitxategia zerbitzariak onartzen duen tamaina baino handiagoa da.",
"Edit profile picture" => "Editatu profilaren argazkia",
"Is this correct?" => "Hau zuzena al da?",
"# groups" => "# taldeak",
"Some contacts are marked for deletion, but not deleted yet. Please wait for them to be deleted." => "Kontaktu batzuk ezabatzeko markatuta daude, baina oraindik ez dira ezabatu. Mesedez itxoin ezabatu arte.",
"Click to undo deletion of {num} contacts" => "Klikatu {num} kontaktuen ezabaketa desegiteko",
"Add" => "Gehitu",
@ -28,7 +32,9 @@
"Couldn't get contact list." => "Ezin izan da kontaktuen zerrenda lortu.",
"Contact is not in this group." => "Kontaktua ez dago talde honetan.",
"Contacts are not in this group." => "Kontaktuak ez daude talde honetan.",
"Failed renaming group: {error}" => "Talderan izena aldatzen huts egin dugu: {error}",
"A group named {group} already exists" => "{group} izeneko taldea dagoeneko existitzen da",
"Failed adding group: {error}" => "Ezin izan dugu taldea gehitu: {error}",
"All" => "Denak",
"Favorites" => "Gogokoak",
"Shared by {owner}" => "{owner}-k partekatuta",
@ -124,6 +130,7 @@
"Edit current photo" => "Editatu oraingo argazkia",
"Upload new photo" => "Igo argazki berria",
"Select photo from ownCloud" => "Hautatu argazki bat ownCloudetik",
"Name" => "Izena",
"First name" => "Izena",
"Additional names" => "Tarteko izenak",
"Last name" => "Abizena",
@ -166,6 +173,5 @@
"iOS/OS X" => "iOS/OS X",
"Addressbooks" => "Helbide Liburuak",
"New Address Book" => "Helbide-liburu berria",
"Name" => "Izena",
"Description" => "Deskribapena"
);

View File

@ -6,14 +6,15 @@
# asieriko <asieriko@gmail.com>, 2013
# asieriko <asieriko@gmail.com>, 2012
# asieriko <asieriko@gmail.com>, 2011
# Debatik mundura!, 2013
# Piarres Beobide <pi@beobide.net>, 2012
msgid ""
msgstr ""
"Project-Id-Version: ownCloud\n"
"Report-Msgid-Bugs-To: http://bugs.owncloud.org/\n"
"POT-Creation-Date: 2013-10-29 04:34-0400\n"
"PO-Revision-Date: 2013-10-28 10:42+0000\n"
"Last-Translator: I Robot <owncloud-bot@tmit.eu>\n"
"Report-Msgid-Bugs-To: translations@owncloud.org\n"
"POT-Creation-Date: 2013-11-06 19:39-0500\n"
"PO-Revision-Date: 2013-11-05 11:00+0000\n"
"Last-Translator: Debatik mundura!\n"
"Language-Team: Basque (http://www.transifex.com/projects/p/owncloud/language/eu/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
@ -71,7 +72,7 @@ msgstr ""
#: js/app.js:226
msgid "Error."
msgstr ""
msgstr "Akatsa."
#: js/app.js:317 js/app.js:331
msgid "Add to..."
@ -113,7 +114,7 @@ msgstr ""
msgid "Select photo"
msgstr "Hautatu argazkia"
#: js/app.js:678 js/app.js:1590
#: js/app.js:678 js/app.js:1570
msgid "Network or server error. Please inform administrator."
msgstr "Errore bat izan da sare edo zerbitzarian. Mesedez abisatu administradorea."
@ -125,46 +126,46 @@ msgstr "Errore bat izan da taldera gehitzean."
msgid "Error removing from group."
msgstr "Errore bat izan da taldetik kentzean."
#: js/app.js:1095
#: js/app.js:1104
msgid "Error setting {name} as favorite."
msgstr ""
#: js/app.js:1234 js/app.js:1238 templates/contacts.php:182
#: js/app.js:1243 js/app.js:1247 templates/contacts.php:182
msgid "Merge contacts"
msgstr ""
msgstr "Kontaktuak batu"
#: js/app.js:1260 js/app.js:1313 js/settings.js:120 templates/contacts.php:321
#: js/app.js:1269 js/app.js:1322 js/settings.js:120 templates/contacts.php:321
#: templates/settings.php:62
msgid "Cancel"
msgstr "Ezeztatu"
#: js/app.js:1287 templates/contacts.php:163
#: js/app.js:1296 templates/contacts.php:163
msgid "Add group"
msgstr "Gehitu taldea"
#: js/app.js:1291
#: js/app.js:1300
msgid "OK"
msgstr "Ados"
#: js/app.js:1391
#: js/app.js:1394
msgid "Could not find contact: {id}"
msgstr ""
msgstr "Ezin izan dugu kontaktua topatu: {id}"
#: js/app.js:1437
#: js/app.js:1417
msgid "No files selected for upload."
msgstr "Ez duzu igotzeko fitxategirik hautatu."
#: js/app.js:1447
#: js/app.js:1427
msgid ""
"The file you are trying to upload exceed the maximum size for file uploads "
"on this server."
msgstr "Igo nahi duzun fitxategia zerbitzariak onartzen duen tamaina baino handiagoa da."
#: js/app.js:1548
#: js/app.js:1528
msgid "Edit profile picture"
msgstr "Editatu profilaren argazkia"
#: js/app.js:1552
#: js/app.js:1532
msgid "Crop photo"
msgstr ""
@ -172,29 +173,29 @@ msgstr ""
msgid "Is this correct?"
msgstr "Hau zuzena al da?"
#: js/contacts.js:858
#: js/contacts.js:856
msgid "Error parsing date: {date}"
msgstr ""
#: js/contacts.js:1055
#: js/contacts.js:1053
msgid "# groups"
msgstr ""
msgstr "# taldeak"
#: js/contacts.js:1127
#: js/contacts.js:1125
msgid "Error parsing birthday {bday}: {error}"
msgstr ""
#: js/contacts.js:2163
#: js/contacts.js:2162
msgid ""
"Some contacts are marked for deletion, but not deleted yet. Please wait for "
"them to be deleted."
msgstr "Kontaktu batzuk ezabatzeko markatuta daude, baina oraindik ez dira ezabatu. Mesedez itxoin ezabatu arte."
#: js/contacts.js:2174
#: js/contacts.js:2173
msgid "Click to undo deletion of {num} contacts"
msgstr "Klikatu {num} kontaktuen ezabaketa desegiteko"
#: js/contacts.js:2183
#: js/contacts.js:2182
msgid "Cancelled deletion of {num} contacts"
msgstr ""
@ -224,7 +225,7 @@ msgstr "Kontaktuak ez daude talde honetan."
#: js/groups.js:566
msgid "Failed renaming group: {error}"
msgstr ""
msgstr "Talderan izena aldatzen huts egin dugu: {error}"
#: js/groups.js:597
msgid "A group named {group} already exists"
@ -238,7 +239,7 @@ msgstr ""
#: js/groups.js:645
msgid "Failed adding group: {error}"
msgstr ""
msgstr "Ezin izan dugu taldea gehitu: {error}"
#: js/groups.js:657
msgid "All"
@ -357,7 +358,7 @@ msgstr ""
msgid "The backend for this address book does not support adding contacts"
msgstr ""
#: lib/addressbook.php:240 lib/addressbook.php:266 lib/contact.php:248
#: lib/addressbook.php:240 lib/addressbook.php:266 lib/contact.php:245
msgid "You do not have permissions to delete this contact"
msgstr ""
@ -385,35 +386,35 @@ msgstr ""
msgid "Address book not found"
msgstr ""
#: lib/contact.php:114 lib/contact.php:161
#: lib/contact.php:111 lib/contact.php:158
msgid "You do not have permissions to see this contact"
msgstr ""
#: lib/contact.php:263
#: lib/contact.php:260
msgid "You do not have permissions to update this contact"
msgstr ""
#: lib/contact.php:274
#: lib/contact.php:271
msgid "The backend for this contact does not support updating it"
msgstr ""
#: lib/contact.php:292
#: lib/contact.php:289
msgid "This backend not support adding contacts"
msgstr ""
#: lib/contact.php:402 lib/contact.php:419
#: lib/contact.php:399 lib/contact.php:416
msgid "Property not found"
msgstr ""
#: lib/contact.php:467
#: lib/contact.php:464
msgid " Missing IM parameter for: "
msgstr ""
#: lib/contact.php:475
#: lib/contact.php:472
msgid "Unknown IM: "
msgstr "BM ezezaguna:"
#: lib/contact.php:788
#: lib/contact.php:742
msgid "{name}'s Birthday"
msgstr "{name}ren jaioteguna"
@ -934,6 +935,10 @@ msgstr "Igo argazki berria"
msgid "Select photo from ownCloud"
msgstr "Hautatu argazki bat ownCloudetik"
#: templates/contacts.php:233 templates/settings.php:59
msgid "Name"
msgstr "Izena"
#: templates/contacts.php:239 templates/contacts.php:240
msgid "First name"
msgstr "Izena"
@ -1156,10 +1161,6 @@ msgstr "Helbide Liburuak"
msgid "New Address Book"
msgstr "Helbide-liburu berria"
#: templates/settings.php:59
msgid "Name"
msgstr "Izena"
#: templates/settings.php:60
msgid "Description"
msgstr "Deskribapena"

View File

@ -2,16 +2,28 @@
"Contacts" => "Kontakter",
"Save" => "Späicheren",
"Uploading..." => "Upload...",
"Importing..." => "Gett importéiert...",
"Error." => "Fehler.",
"Add group..." => "Grupp bäisetzen...",
"Select photo" => "Foto auswielen",
"Cancel" => "Ofbriechen",
"Add group" => "Grupp bäisetzen",
"OK" => "OK",
"# groups" => "# Gruppen",
"Add" => "Dobäisetzen",
"All" => "All",
"Favorites" => "Favoriten",
"Import" => "Importeieren",
"Close" => "Zoumaachen",
"Error" => "Feeler",
"Download" => "Download",
"Edit" => "Editéieren",
"Delete" => "Läschen",
"More..." => "Méi...",
"Less..." => "Manner...",
"Unknown error" => "Et ass en onbekannte Fehler opgetrueden",
"{name}'s Birthday" => "{name} säi Gebuertsdag",
"Error saving contact." => "Feeler beim Späichere vum Kontakt.",
"Information about vCard is incorrect. Please reload the page." => "Informatioun iwwert vCard ass net richteg. Lued d'Säit wegl nei.",
"There is no error, the file uploaded with success" => "Keen Feeler, Datei ass komplett ropgelueden ginn",
"The uploaded file exceeds the upload_max_filesize directive in php.ini" => "Déi ropgelueden Datei ass méi grouss wei d'upload_max_filesize Eegenschaft an der php.ini",
@ -19,11 +31,27 @@
"The uploaded file was only partially uploaded" => "Déi ropgelueden Datei ass nëmmen hallef ropgelueden ginn",
"No file was uploaded" => "Et ass kee Fichier ropgeluede ginn",
"Missing a temporary folder" => "Et feelt en temporären Dossier",
"No photo path was submitted." => "Et gouf kee Foto-Pfad iwwerdroen.",
"File doesn't exist:" => "Fichier existéiert net:",
"Error loading image." => "Fehler beim lueden vum Bild.",
"Error cropping image" => "Feeler beim Schneide vum Bild",
"Error resizing image" => "Feeler beim Redimensionnéiere vum Bild",
"Error getting PHOTO property." => "Feeler beim Luede vun der PHOTO-Eegeschaft.",
"Failed to write to disk" => "Konnt net op den Disk schreiwen",
"Contact" => "Kontakt",
"Other" => "Aner",
"Jabber" => "Jabber",
"AIM" => "AIM",
"MSN" => "MSN",
"Twitter" => "Twitter",
"GoogleTalk" => "GoogleTalk",
"Facebook" => "Facebook",
"XMPP" => "XMPP",
"ICQ" => "ICQ",
"Yahoo" => "Yahoo",
"Skype" => "Skype",
"QQ" => "QQ",
"GaduGadu" => "GaduGadu",
"Work" => "Aarbecht",
"Home" => "Doheem",
"Mobile" => "GSM",
@ -34,8 +62,20 @@
"Video" => "Video",
"Pager" => "Pager",
"Internet" => "Internet",
"Friends" => "Frënn",
"Family" => "Famill",
"New Contact" => "Neie Kontakt",
"Group name" => "Gruppe Numm",
"New Group" => "Nei Grupp",
"Groups" => "Gruppen",
"Add new contact" => "Neie Kontakt bäisetzen",
"Add contact" => "Kontakt bäisetzen",
"Delete group" => "D'Grupp läaschen",
"Rename group" => "D'Grupp em-benennen",
"Name" => "Numm",
"First name" => "Virnumm",
"Additional names" => "Weider Nimm",
"Last name" => "Famillje Numm",
"Nickname" => "Spëtznumm",
"Enter nickname" => "Gëff e Spëtznumm an",
"Title" => "Titel",
@ -43,22 +83,29 @@
"Birthday" => "Gebuertsdaag",
"Phone" => "Telefon",
"Email" => "Email",
"Instant Messaging" => "Instant Messaging",
"Address" => "Adress",
"Note" => "Note",
"Web site" => "Web site",
"Delete contact" => "Kontakt läschen",
"Enter phone number" => "Telefonsnummer aginn",
"Delete phone number" => "Telefonsnummer läschen",
"View on map" => "Op da Kaart uweisen",
"1600 Pennsylvania Avenue, NW" => "1600 Pennsylvania Avenue, NW",
"20500" => "20500",
"Washington, DC" => "Washington, DC",
"City" => "Staat",
"District of Columbia" => "District of Columbia",
"USA" => "USA",
"Country" => "Land",
"Active" => "Aktiv",
"Share" => "Deelen",
"Export" => "Exporteieren",
"CardDAV link" => "CardDav Link",
"more info" => "méi Informatiounen",
"Primary address (Kontact et al)" => "Primair address (Kontact et al)",
"iOS/OS X" => "iOS/OS X",
"Addressbooks" => "Adressbicher ",
"New Address Book" => "Neit Adressbuch",
"Name" => "Numm",
"Description" => "Beschreiwung"
);

View File

@ -5,14 +5,15 @@
# Translators:
# llaera <llaera@outlook.com>, 2013
# Michel Weimerskirch <michel@weimerskirch.net>, 2013
# sim0n <sim0n@trypill.org>, 2013
# sim0n <sim0n@trypill.org>, 2011, 2012
msgid ""
msgstr ""
"Project-Id-Version: ownCloud\n"
"Report-Msgid-Bugs-To: http://bugs.owncloud.org/\n"
"POT-Creation-Date: 2013-10-29 04:34-0400\n"
"PO-Revision-Date: 2013-10-28 10:42+0000\n"
"Last-Translator: I Robot <owncloud-bot@tmit.eu>\n"
"Report-Msgid-Bugs-To: translations@owncloud.org\n"
"POT-Creation-Date: 2013-11-06 19:39-0500\n"
"PO-Revision-Date: 2013-11-03 21:00+0000\n"
"Last-Translator: sim0n <sim0n@trypill.org>\n"
"Language-Team: Luxembourgish (http://www.transifex.com/projects/p/owncloud/language/lb/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
@ -34,7 +35,7 @@ msgstr "Upload..."
#: js/addressbooks.js:301 js/loader.js:68
msgid "Importing..."
msgstr ""
msgstr "Gett importéiert..."
#: js/addressbooks.js:324
msgid "Preparing..."
@ -70,7 +71,7 @@ msgstr ""
#: js/app.js:226
msgid "Error."
msgstr ""
msgstr "Fehler."
#: js/app.js:317 js/app.js:331
msgid "Add to..."
@ -82,7 +83,7 @@ msgstr ""
#: js/app.js:338
msgid "Add group..."
msgstr ""
msgstr "Grupp bäisetzen..."
#: js/app.js:468
msgid "Invalid URL: \"{url}\""
@ -110,9 +111,9 @@ msgstr ""
#: js/app.js:602
msgid "Select photo"
msgstr ""
msgstr "Foto auswielen"
#: js/app.js:678 js/app.js:1590
#: js/app.js:678 js/app.js:1570
msgid "Network or server error. Please inform administrator."
msgstr ""
@ -124,46 +125,46 @@ msgstr ""
msgid "Error removing from group."
msgstr ""
#: js/app.js:1095
#: js/app.js:1104
msgid "Error setting {name} as favorite."
msgstr ""
#: js/app.js:1234 js/app.js:1238 templates/contacts.php:182
#: js/app.js:1243 js/app.js:1247 templates/contacts.php:182
msgid "Merge contacts"
msgstr ""
#: js/app.js:1260 js/app.js:1313 js/settings.js:120 templates/contacts.php:321
#: js/app.js:1269 js/app.js:1322 js/settings.js:120 templates/contacts.php:321
#: templates/settings.php:62
msgid "Cancel"
msgstr "Ofbriechen"
#: js/app.js:1287 templates/contacts.php:163
#: js/app.js:1296 templates/contacts.php:163
msgid "Add group"
msgstr ""
msgstr "Grupp bäisetzen"
#: js/app.js:1291
#: js/app.js:1300
msgid "OK"
msgstr "OK"
#: js/app.js:1391
#: js/app.js:1394
msgid "Could not find contact: {id}"
msgstr ""
#: js/app.js:1437
#: js/app.js:1417
msgid "No files selected for upload."
msgstr ""
#: js/app.js:1447
#: js/app.js:1427
msgid ""
"The file you are trying to upload exceed the maximum size for file uploads "
"on this server."
msgstr ""
#: js/app.js:1548
#: js/app.js:1528
msgid "Edit profile picture"
msgstr ""
#: js/app.js:1552
#: js/app.js:1532
msgid "Crop photo"
msgstr ""
@ -171,29 +172,29 @@ msgstr ""
msgid "Is this correct?"
msgstr ""
#: js/contacts.js:858
#: js/contacts.js:856
msgid "Error parsing date: {date}"
msgstr ""
#: js/contacts.js:1055
#: js/contacts.js:1053
msgid "# groups"
msgstr ""
msgstr "# Gruppen"
#: js/contacts.js:1127
#: js/contacts.js:1125
msgid "Error parsing birthday {bday}: {error}"
msgstr ""
#: js/contacts.js:2163
#: js/contacts.js:2162
msgid ""
"Some contacts are marked for deletion, but not deleted yet. Please wait for "
"them to be deleted."
msgstr ""
#: js/contacts.js:2174
#: js/contacts.js:2173
msgid "Click to undo deletion of {num} contacts"
msgstr ""
#: js/contacts.js:2183
#: js/contacts.js:2182
msgid "Cancelled deletion of {num} contacts"
msgstr ""
@ -241,11 +242,11 @@ msgstr ""
#: js/groups.js:657
msgid "All"
msgstr ""
msgstr "All"
#: js/groups.js:672 js/groups.js:675
msgid "Favorites"
msgstr ""
msgstr "Favoriten"
#: js/groups.js:736
msgid "Shared by {owner}"
@ -322,11 +323,11 @@ msgstr "Läschen"
#: js/settings.js:159 templates/settings.php:66
msgid "More..."
msgstr ""
msgstr "Méi..."
#: js/settings.js:162
msgid "Less..."
msgstr ""
msgstr "Manner..."
#: js/storage.js:30
msgid "Server error! Please inform system administator"
@ -356,7 +357,7 @@ msgstr ""
msgid "The backend for this address book does not support adding contacts"
msgstr ""
#: lib/addressbook.php:240 lib/addressbook.php:266 lib/contact.php:248
#: lib/addressbook.php:240 lib/addressbook.php:266 lib/contact.php:245
msgid "You do not have permissions to delete this contact"
msgstr ""
@ -366,7 +367,7 @@ msgstr ""
#: lib/addressbook.php:290
msgid "Unknown error"
msgstr ""
msgstr "Et ass en onbekannte Fehler opgetrueden"
#: lib/addressbook.php:332
msgid "The backend for this address book does not support updating"
@ -384,35 +385,35 @@ msgstr ""
msgid "Address book not found"
msgstr ""
#: lib/contact.php:114 lib/contact.php:161
#: lib/contact.php:111 lib/contact.php:158
msgid "You do not have permissions to see this contact"
msgstr ""
#: lib/contact.php:263
#: lib/contact.php:260
msgid "You do not have permissions to update this contact"
msgstr ""
#: lib/contact.php:274
#: lib/contact.php:271
msgid "The backend for this contact does not support updating it"
msgstr ""
#: lib/contact.php:292
#: lib/contact.php:289
msgid "This backend not support adding contacts"
msgstr ""
#: lib/contact.php:402 lib/contact.php:419
#: lib/contact.php:399 lib/contact.php:416
msgid "Property not found"
msgstr ""
#: lib/contact.php:467
#: lib/contact.php:464
msgid " Missing IM parameter for: "
msgstr ""
#: lib/contact.php:475
#: lib/contact.php:472
msgid "Unknown IM: "
msgstr ""
#: lib/contact.php:788
#: lib/contact.php:742
msgid "{name}'s Birthday"
msgstr "{name} säi Gebuertsdag"
@ -448,7 +449,7 @@ msgstr ""
#: lib/controller/addressbookcontroller.php:285
#: lib/controller/contactphotocontroller.php:332
msgid "Error saving contact."
msgstr ""
msgstr "Feeler beim Späichere vum Kontakt."
#: lib/controller/addressbookcontroller.php:289
msgid "Error removing contact from other address book."
@ -547,7 +548,7 @@ msgstr ""
#: lib/controller/contactphotocontroller.php:191
msgid "No photo path was submitted."
msgstr ""
msgstr "Et gouf kee Foto-Pfad iwwerdroen."
#: lib/controller/contactphotocontroller.php:198
msgid "File doesn't exist:"
@ -568,15 +569,15 @@ msgstr ""
#: lib/controller/contactphotocontroller.php:292
msgid "Error cropping image"
msgstr ""
msgstr "Feeler beim Schneide vum Bild"
#: lib/controller/contactphotocontroller.php:297
msgid "Error resizing image"
msgstr ""
msgstr "Feeler beim Redimensionnéiere vum Bild"
#: lib/controller/contactphotocontroller.php:315
msgid "Error getting PHOTO property."
msgstr ""
msgstr "Feeler beim Luede vun der PHOTO-Eegeschaft."
#: lib/controller/groupcontroller.php:57 lib/controller/groupcontroller.php:79
msgid "No group name given."
@ -681,7 +682,7 @@ msgstr ""
#: lib/utils/properties.php:66
msgid "Jabber"
msgstr ""
msgstr "Jabber"
#: lib/utils/properties.php:71
msgid "Internet call"
@ -689,47 +690,47 @@ msgstr ""
#: lib/utils/properties.php:76
msgid "AIM"
msgstr ""
msgstr "AIM"
#: lib/utils/properties.php:81
msgid "MSN"
msgstr ""
msgstr "MSN"
#: lib/utils/properties.php:86
msgid "Twitter"
msgstr ""
msgstr "Twitter"
#: lib/utils/properties.php:91
msgid "GoogleTalk"
msgstr ""
msgstr "GoogleTalk"
#: lib/utils/properties.php:96
msgid "Facebook"
msgstr ""
msgstr "Facebook"
#: lib/utils/properties.php:101
msgid "XMPP"
msgstr ""
msgstr "XMPP"
#: lib/utils/properties.php:106
msgid "ICQ"
msgstr ""
msgstr "ICQ"
#: lib/utils/properties.php:111
msgid "Yahoo"
msgstr ""
msgstr "Yahoo"
#: lib/utils/properties.php:116
msgid "Skype"
msgstr ""
msgstr "Skype"
#: lib/utils/properties.php:121
msgid "QQ"
msgstr ""
msgstr "QQ"
#: lib/utils/properties.php:126
msgid "GaduGadu"
msgstr ""
msgstr "GaduGadu"
#: lib/utils/properties.php:153 lib/utils/properties.php:161
#: lib/utils/properties.php:172 lib/utils/properties.php:189
@ -775,23 +776,23 @@ msgstr "Internet"
#: lib/utils/properties.php:187
msgid "Friends"
msgstr ""
msgstr "Frënn"
#: lib/utils/properties.php:188
msgid "Family"
msgstr ""
msgstr "Famill"
#: templates/contacts.php:6
msgid "New Contact"
msgstr ""
msgstr "Neie Kontakt"
#: templates/contacts.php:10
msgid "Group name"
msgstr ""
msgstr "Gruppe Numm"
#: templates/contacts.php:10
msgid "New Group"
msgstr ""
msgstr "Nei Grupp"
#: templates/contacts.php:19
msgid "Address books"
@ -876,7 +877,7 @@ msgstr ""
#: templates/contacts.php:114
msgid "Add new contact"
msgstr ""
msgstr "Neie Kontakt bäisetzen"
#: templates/contacts.php:116
msgid "Add new addressbook"
@ -895,15 +896,15 @@ msgstr ""
#: templates/contacts.php:127
msgid "Add contact"
msgstr ""
msgstr "Kontakt bäisetzen"
#: templates/contacts.php:174
msgid "Delete group"
msgstr ""
msgstr "D'Grupp läaschen"
#: templates/contacts.php:175
msgid "Rename group"
msgstr ""
msgstr "D'Grupp em-benennen"
#: templates/contacts.php:183
msgid "Which contact should the data be merged into?"
@ -933,9 +934,13 @@ msgstr ""
msgid "Select photo from ownCloud"
msgstr ""
#: templates/contacts.php:233 templates/settings.php:59
msgid "Name"
msgstr "Numm"
#: templates/contacts.php:239 templates/contacts.php:240
msgid "First name"
msgstr ""
msgstr "Virnumm"
#: templates/contacts.php:244 templates/contacts.php:245
msgid "Additional names"
@ -943,7 +948,7 @@ msgstr "Weider Nimm"
#: templates/contacts.php:249 templates/contacts.php:250
msgid "Last name"
msgstr ""
msgstr "Famillje Numm"
#: templates/contacts.php:257
msgid "Select groups"
@ -1003,7 +1008,7 @@ msgstr "Email"
#: templates/contacts.php:332
msgid "Instant Messaging"
msgstr ""
msgstr "Instant Messaging"
#: templates/contacts.php:333
msgid "Address"
@ -1015,7 +1020,7 @@ msgstr "Note"
#: templates/contacts.php:335
msgid "Web site"
msgstr ""
msgstr "Web site"
#: templates/contacts.php:337
msgid "Delete contact"
@ -1069,7 +1074,7 @@ msgstr ""
#: templates/contacts.php:410
msgid "1600 Pennsylvania Avenue, NW"
msgstr ""
msgstr "1600 Pennsylvania Avenue, NW"
#: templates/contacts.php:411
msgid "Street address"
@ -1077,7 +1082,7 @@ msgstr ""
#: templates/contacts.php:415
msgid "20500"
msgstr ""
msgstr "20500"
#: templates/contacts.php:416
msgid "Postal code"
@ -1085,7 +1090,7 @@ msgstr ""
#: templates/contacts.php:418
msgid "Washington, DC"
msgstr ""
msgstr "Washington, DC"
#: templates/contacts.php:419
msgid "City"
@ -1093,7 +1098,7 @@ msgstr "Staat"
#: templates/contacts.php:423
msgid "District of Columbia"
msgstr ""
msgstr "District of Columbia"
#: templates/contacts.php:424
msgid "State or province"
@ -1101,7 +1106,7 @@ msgstr ""
#: templates/contacts.php:428
msgid "USA"
msgstr ""
msgstr "USA"
#: templates/contacts.php:429
msgid "Country"
@ -1129,7 +1134,7 @@ msgstr "Exporteieren"
#: templates/contacts.php:466
msgid "CardDAV link"
msgstr ""
msgstr "CardDav Link"
#: templates/settings.php:3
msgid "CardDAV syncing addresses"
@ -1155,10 +1160,6 @@ msgstr "Adressbicher "
msgid "New Address Book"
msgstr "Neit Adressbuch"
#: templates/settings.php:59
msgid "Name"
msgstr "Numm"
#: templates/settings.php:60
msgid "Description"
msgstr "Beschreiwung"

View File

@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: ownCloud contacts 5.0.0\n"
"Report-Msgid-Bugs-To: translations@owncloud.org\n"
"POT-Creation-Date: 2013-11-03 10:35-0500\n"
"POT-Creation-Date: 2013-11-06 19:39-0500\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"
@ -353,7 +353,7 @@ msgstr ""
msgid "The backend for this address book does not support adding contacts"
msgstr ""
#: lib/addressbook.php:240 lib/addressbook.php:266 lib/contact.php:248
#: lib/addressbook.php:240 lib/addressbook.php:266 lib/contact.php:245
msgid "You do not have permissions to delete this contact"
msgstr ""
@ -381,35 +381,35 @@ msgstr ""
msgid "Address book not found"
msgstr ""
#: lib/contact.php:114 lib/contact.php:161
#: lib/contact.php:111 lib/contact.php:158
msgid "You do not have permissions to see this contact"
msgstr ""
#: lib/contact.php:263
#: lib/contact.php:260
msgid "You do not have permissions to update this contact"
msgstr ""
#: lib/contact.php:274
#: lib/contact.php:271
msgid "The backend for this contact does not support updating it"
msgstr ""
#: lib/contact.php:292
#: lib/contact.php:289
msgid "This backend not support adding contacts"
msgstr ""
#: lib/contact.php:402 lib/contact.php:419
#: lib/contact.php:399 lib/contact.php:416
msgid "Property not found"
msgstr ""
#: lib/contact.php:467
#: lib/contact.php:464
msgid " Missing IM parameter for: "
msgstr ""
#: lib/contact.php:475
#: lib/contact.php:472
msgid "Unknown IM: "
msgstr ""
#: lib/contact.php:788
#: lib/contact.php:742
msgid "{name}'s Birthday"
msgstr ""

View File

@ -248,6 +248,18 @@ abstract class AbstractBackend {
public function lastModifiedAddressBook($addressbookid) {
}
/**
* @brief 'touch' an address book.
*
* If implemented this method must mark the address books
* modification date so lastModifiedAddressBook() can be
* used to invalidate the cache.
*
* @param string $addressbookid
*/
public function setModifiedAddressBook($addressbookid) {
}
/**
* Returns all contacts for a specific addressbook id.
*
@ -375,7 +387,7 @@ abstract class AbstractBackend {
$key = $this->combinedKey($addressBookId);
$key = 'active_' . $key;
return (\OCP\Config::getUserValue($this->userid, 'contacts', $key, 'true') === 'true');
return !!(\OCP\Config::getUserValue($this->userid, 'contacts', $key, 1));
}
/**
@ -388,7 +400,8 @@ abstract class AbstractBackend {
$key = $this->combinedKey($addressBookId);
$key = 'active_' . $key;
return \OCP\Config::setUserValue($this->userid, 'contacts', $key, $active);
$this->setModifiedAddressBook($addressBookId);
return \OCP\Config::setUserValue($this->userid, 'contacts', $key, (int)$active);
}
/**

View File

@ -324,7 +324,7 @@ class Database extends AbstractBackend {
* @param integer $id
* @return boolean
*/
public function touchAddressBook($id) {
public function setModifiedAddressBook($id) {
$query = 'UPDATE `' . $this->addressBooksTableName
. '` SET `ctag` = ? + 1 WHERE `id` = ?';
if(!isset(self::$preparedQueries['touchaddressbook'])) {
@ -552,9 +552,9 @@ class Database extends AbstractBackend {
}
$newid = \OCP\DB::insertid($this->cardsTableName);
$this->touchAddressBook($addressbookid);
$this->setModifiedAddressBook($addressbookid);
\OCP\Util::emitHook('OCA\Contacts', 'post_createContact',
array('id' => $newid, 'parent' => $addressbookid, 'contact' => $contact)
array('id' => $newid, 'parent' => $addressbookid, 'backend' => $this->name, 'contact' => $contact)
);
return (string)$newid;
}
@ -564,7 +564,7 @@ class Database extends AbstractBackend {
*
* @param string $addressbookid
* @param mixed $id Contact ID
* @param mixed $contact
* @param VCard|string $contact
* @param array $options - Optional (backend specific options)
* @see getContact
* @return bool
@ -636,10 +636,16 @@ class Database extends AbstractBackend {
return false;
}
$this->touchAddressBook($addressbookid);
$this->setModifiedAddressBook($addressbookid);
if(!$isBatch) {
\OCP\Util::emitHook('OCA\Contacts', 'post_updateContact',
array('id' => $id, 'parent' => $addressbookid, 'contact' => $contact, 'carddav' => $isCardDAV)
array(
'backend' => $this->name,
'addressBookId' => $addressbookid,
'contactId' => $id,
'contact' => $contact,
'carddav' => $isCardDAV
)
);
}
return true;
@ -708,7 +714,7 @@ class Database extends AbstractBackend {
. $id, \OCP\Util::DEBUG);
return false;
}
$this->touchAddressBook($addressbookid);
$this->setModifiedAddressBook($addressbookid);
return true;
}

View File

@ -22,7 +22,8 @@
namespace OCA\Contacts;
use Sabre\VObject\Property;
use Sabre\VObject\Property,
OCA\Contacts\Utils\Properties;
/**
* Subclass this class or implement IPIMObject interface for PIM objects
@ -705,7 +706,14 @@ class Contact extends VObject\VCard implements IPIMObject {
}
parent::__unset($key);
if($key === 'PHOTO') {
$this->cacheThumbnail(null, true);
Properties::cacheThumbnail(
$this->getBackend()->name,
$this->getParent()->getId(),
$this->getId(),
null,
null,
array('remove' => true)
);
}
$this->setSaved(false);
}
@ -765,4 +773,5 @@ class Contact extends VObject\VCard implements IPIMObject {
return $vcal;
}
}
}

View File

@ -331,7 +331,14 @@ class ContactPhotoController extends Controller {
if(!$contact->save()) {
return $response->bailOut(App::$l10n->t('Error saving contact.'));
}
$thumbnail = $contact->cacheThumbnail($image);
$thumbnail = Properties::cacheThumbnail(
$params['backend'],
$params['addressBookId']
$params['contactId'],
$image
);
$response->setData(array(
'status' => 'success',
'data' => array(

View File

@ -117,16 +117,23 @@ class Hooks{
public static function contactUpdated($parameters) {
//\OCP\Util::writeLog('contacts', __METHOD__.' parameters: '.print_r($parameters, true), \OCP\Util::DEBUG);
$contact = $parameters['contact'];
Utils\Properties::updateIndex($parameters['id'], $contact);
Utils\Properties::updateIndex($parameters['contactId'], $contact);
// If updated via CardDAV we don't know if PHOTO has changed
if(isset($parameters['carddav']) && $parameters['carddav']) {
if(isset($contact->PHOTO) || isset($contact->LOGO)) {
$contact->cacheThumbnail(null, false, true);
Utils\Properties::cacheThumbnail(
$parameters['backend'],
$parameters['addressBookId'],
$parameters['contactId'],
null,
$contact,
array('update' => true)
);
}
$tagMgr = \OC::$server->getTagManager()->load('contact');
$tagMgr->purgeObjects(array($parameters['id']));
$tagMgr->purgeObjects(array($parameters['contactId']));
if(isset($contact->CATEGORIES)) {
$tagMgr->addMultiple($contact->CATEGORIES->getParts(), true, $parameters['id']);
$tagMgr->addMultiple($contact->CATEGORIES->getParts(), true, $parameters['contactId']);
}
}
}

View File

@ -24,7 +24,8 @@
namespace OCA\Contacts\Utils;
use OCA\Contacts\VObject;
use OCA\Contacts\Contact;
use OCA\Contacts\Contact,
OCA\Contacts\Utils\Properties;
/**
* This class serializes properties, components an
@ -90,7 +91,13 @@ class JSONSerializer {
$details = array();
if(isset($contact->PHOTO) || isset($contact->LOGO)) {
$details['thumbnail'] = $contact->cacheThumbnail();
$details['thumbnail'] = Properties::cacheThumbnail(
$contact->getBackend()->name,
$contact->getParent()->getId(),
$contact->getId(),
null,
$contact
);
}
foreach($contact->children as $property) {

View File

@ -22,10 +22,15 @@
namespace OCA\Contacts\Utils;
use OCA\Contacts\App;
Properties::$l10n = \OCP\Util::getL10N('contacts');
Class Properties {
const THUMBNAIL_PREFIX = 'contact-thumbnail-';
const THUMBNAIL_SIZE = 28;
private static $deleteindexstmt;
private static $updateindexstmt;
protected static $cardsTableName = '*PREFIX*contacts_cards';
@ -276,4 +281,54 @@ Class Properties {
}
}
}
public static function cacheThumbnail($backendName, $addressBookId, $contactId,
\OCP\Image $image = null, $vcard = null, $options = array()) {
$cache = \OC::$server->getCache();
$key = self::THUMBNAIL_PREFIX . $backendName . '::' . $addressBookId . '::' . $contactId;
//$cache->remove($key);
if($cache->hasKey($key) && $image === null
&& (isset($options['remove']) && $options['remove'] === false)
&& (isset($options['update']) && $options['update'] === false)) {
return $cache->get($key);
}
if(isset($options['remove']) && $options['remove']) {
$cache->remove($key);
if(!isset($options['update']) || !$options['update']) {
return false;
}
}
if(is_null($image)) {
if(is_null($vcard)) {
$app = new App();
$vcard = $app->getContact($backendName, $addressBookId, $contactId);
}
$image = new \OCP\Image();
if(!isset($vcard->PHOTO) && !isset($vcard->LOGO)) {
return false;
}
if(!$image->loadFromBase64((string)$vcard->PHOTO)) {
if(!$image->loadFromBase64((string)$vcard->LOGO)) {
return false;
}
}
}
if(!$image->centerCrop()) {
\OCP\Util::writeLog('contacts',
__METHOD__ .'. Couldn\'t crop thumbnail for ID ' . $key,
\OCP\Util::ERROR);
return false;
}
if(!$image->resize(self::THUMBNAIL_SIZE)) {
\OCP\Util::writeLog('contacts',
__METHOD__ . '. Couldn\'t resize thumbnail for ID ' . $key,
\OCP\Util::ERROR);
return false;
}
// Cache as base64 for around a month
$cache->set($key, strval($image), 3000000);
\OCP\Util::writeLog('contacts', 'Caching ' . $key, \OCP\Util::DEBUG);
return $cache->get($key);
}
}

View File

@ -35,9 +35,6 @@ use Sabre\VObject;
*/
class VCard extends VObject\Component\VCard {
const THUMBNAIL_PREFIX = 'contact-thumbnail-';
const THUMBNAIL_SIZE = 28;
/**
* The following constants are used by the validate() method.
*/
@ -308,47 +305,4 @@ class VCard extends VObject\Component\VCard {
return $this->groups;
}
// TODO: Cleanup these parameters and move method to Utils class
public function cacheThumbnail(\OCP\Image $image = null, $remove = false, $update = false) {
$key = self::THUMBNAIL_PREFIX . $this->combinedKey();
//\OC_Cache::remove($key);
if(\OC_Cache::hasKey($key) && $image === null && $remove === false && $update === false) {
return \OC_Cache::get($key);
}
if($remove) {
\OC_Cache::remove($key);
if(!$update) {
return false;
}
}
if(is_null($image)) {
$this->retrieve();
$image = new \OCP\Image();
if(!isset($this->PHOTO) && !isset($this->LOGO)) {
return false;
}
if(!$image->loadFromBase64((string)$this->PHOTO)) {
if(!$image->loadFromBase64((string)$this->LOGO)) {
return false;
}
}
}
if(!$image->centerCrop()) {
\OCP\Util::writeLog('contacts',
__METHOD__ .'. Couldn\'t crop thumbnail for ID ' . $key,
\OCP\Util::ERROR);
return false;
}
if(!$image->resize(self::THUMBNAIL_SIZE)) {
\OCP\Util::writeLog('contacts',
__METHOD__ . '. Couldn\'t resize thumbnail for ID ' . $key,
\OCP\Util::ERROR);
return false;
}
// Cache as base64 for around a month
\OC_Cache::set($key, strval($image), 3000000);
\OCP\Util::writeLog('contacts', 'Caching ' . $key, \OCP\Util::DEBUG);
return \OC_Cache::get($key);
}
}