# HG changeset patch # User rbernard # Date 1264023179 -3600 # Node ID 36165e7cd1f05327b605a1e35d76f7d44a5430f2 # Parent f2ba05546abc8657e4fb5458f385f5aab10954d3 i18n typo diff -r f2ba05546abc -r 36165e7cd1f0 src/cm/client.py --- a/src/cm/client.py Wed Jan 20 20:45:52 2010 +0100 +++ b/src/cm/client.py Wed Jan 20 22:32:59 2010 +0100 @@ -183,7 +183,7 @@ ret['errors'] = errors else : # INSERT - # TODO check version still exist ... + # TODO check version is latest (if boolean #comment = Comment.objects.get(id=edit_comment_id) comment = Comment.objects.get(key=comment_key) if change_state : # moderation action diff -r f2ba05546abc -r 36165e7cd1f0 src/cm/locale/en/LC_MESSAGES/django.po --- a/src/cm/locale/en/LC_MESSAGES/django.po Wed Jan 20 20:45:52 2010 +0100 +++ b/src/cm/locale/en/LC_MESSAGES/django.po Wed Jan 20 22:32:59 2010 +0100 @@ -8,7 +8,7 @@ msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2010-01-15 13:15+0100\n" +"POT-Creation-Date: 2010-01-20 22:03+0100\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" @@ -61,7 +61,7 @@ msgid "unknown" msgstr "" -#: models.py:175 views/create.py:30 views/create.py:45 views/texts.py:613 +#: models.py:175 views/create.py:30 views/create.py:45 views/texts.py:611 msgid "Title" msgstr "" @@ -73,7 +73,7 @@ msgid "Content" msgstr "" -#: models.py:178 models.py:579 +#: models.py:178 models.py:594 msgid "Tags" msgstr "" @@ -85,121 +85,121 @@ msgid "Moderation a posteriori?" msgstr "" -#: models.py:274 +#: models.py:280 msgid "Format:" msgstr "" -#: models.py:341 +#: models.py:356 #, python-format msgid "%(workspace_name)s's workspace" msgstr "" -#: models.py:482 +#: models.py:497 msgid "name" msgstr "" -#: models.py:483 +#: models.py:498 msgid "description" msgstr "" -#: models.py:573 +#: models.py:588 msgid "Allow contact" msgstr "" -#: models.py:573 +#: models.py:588 msgid "Allow email messages from other users" msgstr "" -#: models.py:574 +#: models.py:589 msgid "Preferred language" msgstr "" -#: models.py:577 +#: models.py:592 msgid "Suspended access" msgstr "" -#: models.py:601 +#: models.py:616 msgid "suspended" msgstr "" -#: models.py:603 +#: models.py:618 msgid "waiting approval" msgstr "" -#: models.py:609 +#: models.py:624 msgid "pending" msgstr "" -#: models.py:624 +#: models.py:639 msgid "Invitation" msgstr "" -#: models.py:692 +#: models.py:707 #, python-format msgid "Text %(link_to_text)s edited" msgstr "" -#: models.py:693 +#: models.py:708 #, python-format msgid "Text %(link_to_text)s edited (new version created)" msgstr "" -#: models.py:694 +#: models.py:709 #, python-format msgid "Text %(link_to_text)s added" msgstr "" -#: models.py:695 +#: models.py:710 #, python-format msgid "Text %(link_to_text)s removed" msgstr "" -#: models.py:696 +#: models.py:711 #, python-format msgid "Comment %(link_to_comment)s added on text %(link_to_text)s" msgstr "" -#: models.py:697 +#: models.py:712 #, python-format msgid "Comment %(link_to_comment)s removed from text %(link_to_text)s" msgstr "" -#: models.py:698 +#: models.py:713 #, python-format msgid "User %(username)s added" msgstr "" -#: models.py:699 +#: models.py:714 #, python-format msgid "User %(username)s access to workspace enabled" msgstr "" -#: models.py:700 +#: models.py:715 #, python-format msgid "User %(username)s access to workspace refused" msgstr "" -#: models.py:701 +#: models.py:716 #, python-format msgid "User %(username)s access to workspace suspended" msgstr "" -#: models.py:702 +#: models.py:717 #, python-format msgid "User %(username)s access to workspace activated" msgstr "" -#: models.py:703 +#: models.py:718 #, python-format msgid "User %(username)s has activated his account" msgstr "" -#: models.py:758 models.py:766 +#: models.py:773 models.py:781 #, python-format msgid "by \"%(username)s\"" msgstr "" -#: models.py:760 +#: models.py:775 #, python-format msgid "%(time_since)s ago" msgstr "" @@ -685,7 +685,7 @@ msgstr "Ajouter un utilisateur" #: templates/site/profile.html:26 templates/site/text_create_content.html:45 -#: templates/site/text_create_upload.html:40 templates/site/text_edit.html:34 +#: templates/site/text_create_upload.html:40 templates/site/text_edit.html:36 #: templates/site/text_settings.html:23 templates/site/text_share.html:153 #: templates/site/user_activate.html:27 templates/site/user_list.html:210 #: templates/site/layout/base_workspace_form.html:32 @@ -951,7 +951,7 @@ #: templates/site/text_share.html:87 msgid "" "The 'Workspace role' is the global role that applies to every text, you can " -"give a user a particular role on this text using the 'local role' column on " +"give a user a particular role on this text using the 'text role' column on " "the right" msgstr "" @@ -960,12 +960,13 @@ msgstr "" #: templates/site/text_share.html:88 -msgid "Local role" -msgstr "" +#, fuzzy +msgid "Text role" +msgstr "Rôle sur le texte" #: templates/site/text_share.html:101 #, python-format -msgid "This role has been overriden on this text by a local role: %(rolename)s" +msgid "This role has been overriden on this text by a text role: %(rolename)s" msgstr "" #: templates/site/text_share.html:128 templates/site/user_edit.html:6 @@ -1203,7 +1204,7 @@ msgid "The title of your text" msgstr "" -#: views/create.py:71 views/create.py:108 +#: views/create.py:70 views/create.py:107 #, python-format msgid "Text \"%(text_title)s\" has been created" msgstr "" @@ -1272,7 +1273,7 @@ msgid "Private notifications feed reseted." msgstr "" -#: views/site.py:81 views/texts.py:132 views/user.py:522 +#: views/site.py:81 views/texts.py:132 views/user.py:520 msgid "You're logged in!" msgstr "" @@ -1348,32 +1349,32 @@ msgid "%(nb_texts)i text(s) deleted" msgstr "" -#: views/texts.py:211 +#: views/texts.py:210 #, python-format msgid "Text %(text_title)s deleted" msgstr "" -#: views/texts.py:617 +#: views/texts.py:615 msgid "Note (optional)" msgstr "" -#: views/texts.py:620 +#: views/texts.py:618 msgid "Add a note to explain the modifications made to the text" msgstr "" -#: views/texts.py:630 +#: views/texts.py:628 msgid "New version (optional)" msgstr "" -#: views/texts.py:633 +#: views/texts.py:631 msgid "Create a new version of this text (recommended)" msgstr "" -#: views/texts.py:636 +#: views/texts.py:634 msgid "Keep comments (optional)" msgstr "" -#: views/texts.py:639 +#: views/texts.py:637 msgid "Keep comments (if not affected by the edit)" msgstr "" @@ -1390,12 +1391,12 @@ msgid "A new version (copied from version %(version_id)s) has been created" msgstr "" -#: views/texts.py:857 views/user.py:79 views/user.py:99 +#: views/texts.py:859 views/user.py:79 views/user.py:99 #, python-format msgid "%(count)i user(s) role modified" msgstr "" -#: views/texts.py:915 +#: views/texts.py:917 msgid "Text settings updated" msgstr "" @@ -1502,49 +1503,49 @@ msgid "Profile updated" msgstr "" -#: views/user.py:434 +#: views/user.py:432 msgid "Anonymous user role modified." msgstr "" -#: views/user.py:456 +#: views/user.py:454 msgid "User modified" msgstr "" -#: views/user.py:471 +#: views/user.py:469 msgid "Subject" msgstr "" -#: views/user.py:472 +#: views/user.py:470 msgid "Subject of the email" msgstr "" -#: views/user.py:475 +#: views/user.py:473 msgid "Body" msgstr "" -#: views/user.py:476 +#: views/user.py:474 msgid "Body of the email" msgstr "" -#: views/user.py:496 +#: views/user.py:494 msgid "Email sent." msgstr "" -#: views/user.py:516 +#: views/user.py:514 msgid "This account is suspended, contact the workspace administrator." msgstr "" -#: views/user.py:547 +#: views/user.py:545 msgid "You've been logged out." msgstr "" -#: views/user.py:563 +#: views/user.py:561 msgid "" "You've been registered, you will receive a confirmation mail once a " "moderator has approved your membership." msgstr "" -#: views/user.py:566 +#: views/user.py:564 msgid "" "You've been registered, please check your email for the confirm message." msgstr "" diff -r f2ba05546abc -r 36165e7cd1f0 src/cm/locale/en/LC_MESSAGES/djangojs.po --- a/src/cm/locale/en/LC_MESSAGES/djangojs.po Wed Jan 20 20:45:52 2010 +0100 +++ b/src/cm/locale/en/LC_MESSAGES/djangojs.po Wed Jan 20 22:32:59 2010 +0100 @@ -8,7 +8,7 @@ msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2010-01-15 09:45+0100\n" +"POT-Creation-Date: 2010-01-20 21:53+0100\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" @@ -53,12 +53,13 @@ msgstr "" #: media/js/client/c_client-min.js:1 media/js/client/c_interface_forms.js:14 -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:395 +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:407 msgid "Save" msgstr "" #: media/js/client/c_client-min.js:1 media/js/client/c_interface_forms.js:14 #: media/js/client/f_client-min.js:1 media/js/client/f_printDialog.js:100 +#: media/js/site/text_edit.js:93 msgid "Cancel" msgstr "" @@ -73,7 +74,7 @@ #: media/js/client/c_dlg_intercept.js:48 media/js/client/c_dlg_intercept.js:50 #: media/js/client/c_dlg_intercept.js:52 media/js/client/c_sync.js:223 -#: media/js/site/text_edit.js:84 +#: media/js/site/text_edit.js:85 media/js/site/text_edit.js.py:98 msgid "Warning" msgstr "" @@ -153,15 +154,21 @@ msgid "show scope" msgstr "" -#: media/js/client/c_icomment.js:274 +#: media/js/client/c_icomment.js:27 +msgid "" +"Comment is detached: it was created on a previous version and text it " +"applied to has been modified or removed." +msgstr "" + +#: media/js/client/c_icomment.js:295 msgid "last modified on %(date)s" msgstr "" -#: media/js/client/c_icomment.js:277 +#: media/js/client/c_icomment.js:298 msgid "Permalink to this comment" msgstr "" -#: media/js/client/c_icomment.js:280 +#: media/js/client/c_icomment.js:301 msgid "by %(name)s, created on %(date)s" msgstr "" @@ -179,12 +186,12 @@ #: media/js/client/c_sync.js:129 msgid "" -"Do you want to subscribe to all replies notifications in discussions you " +"Do you want to be notified of all replies in all discussions you " "participated in?" msgstr "" #: media/js/client/c_sync.js:129 -msgid "Follow up" +msgid "Reply Notification" msgstr "" #: media/js/client/c_sync.js:201 media/js/client/c_sync.js.py:208 @@ -276,7 +283,7 @@ msgstr "" #: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:85 -#: media/js/site/f_text_view_frame.js:395 +#: media/js/site/f_text_view_frame.js:407 msgid "Reset" msgstr "" @@ -320,101 +327,105 @@ msgid "view all comments" msgstr "" -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:182 -msgid "toggle advance interface" -msgstr "" - -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:183 +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:184 msgid "print document with/without comments" msgstr "" -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:184 +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:185 msgid "export document with/without comments" msgstr "" -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:187 +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:186 +msgid "toggle full screen view" +msgstr "" + +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:188 msgid "add a comment" msgstr "" -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:203 +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:204 msgid "filter:" msgstr "" -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:208 +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:209 msgid "browse by:" msgstr "" -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:210 -msgid "location" -msgstr "" - #: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:211 +msgid "location" +msgstr "" + +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:212 msgid "modification" msgstr "" -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:354 +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:332 +msgid "thread discussions" +msgstr "" + +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:366 msgid "Text style" msgstr "" -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:399 +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:411 msgid "Animation duration" msgstr "" -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:408 +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:420 msgid "(0.001 to 1 second)" msgstr "" -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:434 +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:446 msgid "preferences reset (will apply on next load)" msgstr "" -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:440 +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:452 msgid "preferences saved (will apply on next load)" msgstr "" -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:544 +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:556 msgid "filter reset" msgstr "" -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:554 +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:566 msgid "filter applied" msgstr "" -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:560 +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:572 msgid "discussion" msgid_plural "discussions" msgstr[0] "" msgstr[1] "" -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:564 +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:576 msgid "comment" msgid_plural "comments" msgstr[0] "" msgstr[1] "" -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:567 +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:579 msgid " reply" msgid_plural " replies" msgstr[0] "" msgstr[1] "" -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:589 +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:601 msgid "all" msgstr "" -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:607 +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:619 msgid "last 24 hours (%(nb_comments)s)" msgid_plural "last %(nb_days)s days (%(nb_comments)s)" msgstr[0] "" msgstr[1] "" -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:721 -#: media/js/site/text_edit.js:78 +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:733 +#: media/js/site/text_edit.js:79 msgid "No" msgstr "" -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:722 -#: media/js/site/text_edit.js:79 +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:734 +#: media/js/site/text_edit.js:80 msgid "Yes" msgstr "" @@ -519,52 +530,50 @@ msgid "code" msgstr "" -#: media/js/site/f_text_view_frame.js:185 -msgid "toggle full screen view" +#: media/js/site/f_text_view_frame.js:182 +msgid "view all detached comments" msgstr "" -#: media/js/site/f_text_view_frame.js:186 +#: media/js/site/f_text_view_frame.js:183 +msgid "toggle advance interface" +msgstr "" + +#: media/js/site/f_text_view_frame.js:187 msgid "text feed" msgstr "" -#: media/js/site/f_text_view_frame.js:317 +#: media/js/site/f_text_view_frame.js:329 msgid "unthread discussions" msgstr "" -#: media/js/site/f_text_view_frame.js:320 -msgid "thread discussions" +#: media/js/site/text_edit.js:9 +msgid "" +"Should these comments be detached (i.e. kept with no scope) or removed from " +"new version?" msgstr "" -#: media/js/site/text_edit.js:26 -msgid "" -"%(nb_comments)s comment will be removed because the text it applies to has " -"been changed." -msgid_plural "" -"%(nb_comments)s comments will be removed because the text they apply to has " -"been changed." +#: media/js/site/text_edit.js:27 media/js/site/text_edit.js.py:44 +msgid "%(nb_comments)s comment applies to text that was modified." +msgid_plural "%(nb_comments)s comments apply to text that was modified." msgstr[0] "" msgstr[1] "" -#: media/js/site/text_edit.js:30 media/js/site/text_edit.js.py:49 -#: media/js/site/text_edit.js:66 +#: media/js/site/text_edit.js:48 +msgid "(We suggest you create a new version)" +msgstr "" + +#: media/js/site/text_edit.js:65 +msgid "You chose not to create a new version all comments will be deleted" +msgstr "" + +#: media/js/site/text_edit.js:67 msgid "Do you want to continue?" msgstr "" -#: media/js/site/text_edit.js:43 -msgid "" -"%(nb_comments)s comment will be lost because the text it applies to has been " -"changed." -msgid_plural "" -"%(nb_comments)s comments will be lost because the text they apply to has " -"been changed." -msgstr[0] "" -msgstr[1] "" - -#: media/js/site/text_edit.js:47 -msgid "(We suggest you create a new version)" +#: media/js/site/text_edit.js:91 +msgid "Detach" msgstr "" -#: media/js/site/text_edit.js:64 -msgid "" -"Since you chose not to create a new version all comments will be deleted" +#: media/js/site/text_edit.js:92 +msgid "Remove" msgstr "" diff -r f2ba05546abc -r 36165e7cd1f0 src/cm/locale/fr/LC_MESSAGES/django.po --- a/src/cm/locale/fr/LC_MESSAGES/django.po Wed Jan 20 20:45:52 2010 +0100 +++ b/src/cm/locale/fr/LC_MESSAGES/django.po Wed Jan 20 22:32:59 2010 +0100 @@ -1,24 +1,28 @@ -# SOME DESCRIPTIVE TITLE. +# translation of django.po to # Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER # This file is distributed under the same license as the PACKAGE package. -# FIRST AUTHOR , YEAR. # +# renaud bernard , 2010. msgid "" msgstr "" -"Project-Id-Version: PACKAGE VERSION\n" +"Project-Id-Version: django\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2010-01-15 13:16+0100\n" -"PO-Revision-Date: 2010-01-15 13:17+0100\n" -"Last-Translator: dev \n" -"Language-Team: LANGUAGE \n" +"POT-Creation-Date: 2010-01-20 22:03+0100\n" +"PO-Revision-Date: 2010-01-20 21:42+0100\n" +"Last-Translator: renaud bernard \n" +"Language-Team: \n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=2; plural=(n > 1);\n" +"X-Generator: KBabel 1.11.4\n" #: client.py:25 -msgid "A selection is required. Select in the text the part your comment applies to." -msgstr "Une portée est obligatoire. Sélectionner dans le texte la partie sur laquelle porte votre commentaire." +msgid "" +"A selection is required. Select in the text the part your comment applies to." +msgstr "" +"Une portée est obligatoire. Sélectionner dans le texte la partie sur " +"laquelle porte votre commentaire." #: client.py:133 msgid "name is required" @@ -44,8 +48,7 @@ msgid "comment removed" msgstr "commentaire supprimé" -#: client.py:208 -#: client.py:273 +#: client.py:208 client.py:273 msgid "comment saved" msgstr "commentaire sauvé" @@ -61,10 +64,7 @@ msgid "unknown" msgstr "inconnu" -#: models.py:175 -#: views/create.py:30 -#: views/create.py:45 -#: views/texts.py:613 +#: models.py:175 views/create.py:30 views/create.py:45 views/texts.py:611 msgid "Title" msgstr "Titre" @@ -72,18 +72,15 @@ msgid "Format" msgstr "Format" -#: models.py:177 -#: views/texts.py:702 +#: models.py:177 views/texts.py:702 msgid "Content" msgstr "Texte" -#: models.py:178 -#: models.py:579 +#: models.py:178 models.py:594 msgid "Tags" msgstr "Tags" -#: models.py:180 -#: views/user.py:218 +#: models.py:180 views/user.py:218 msgid "Note" msgstr "Note" @@ -91,122 +88,122 @@ msgid "Moderation a posteriori?" msgstr "Modération a posteriori ?" -#: models.py:274 +#: models.py:280 msgid "Format:" msgstr "Format :" -#: models.py:341 +#: models.py:356 #, python-format msgid "%(workspace_name)s's workspace" msgstr "espace de travail : %(workspace_name)s" -#: models.py:482 +#: models.py:497 msgid "name" msgstr "nom" -#: models.py:483 +#: models.py:498 msgid "description" msgstr "description" -#: models.py:573 +#: models.py:588 msgid "Allow contact" msgstr "Autorise à être contacté" -#: models.py:573 +#: models.py:588 msgid "Allow email messages from other users" -msgstr "Autoriser les participants de l'espace de travail à vous envoyer un email" +msgstr "" +"Autoriser les participants de l'espace de travail à vous envoyer un email" -#: models.py:574 +#: models.py:589 msgid "Preferred language" msgstr "Langage de préférence" -#: models.py:577 +#: models.py:592 msgid "Suspended access" msgstr "Accès désactivé" -#: models.py:601 +#: models.py:616 msgid "suspended" msgstr "désactivé" -#: models.py:603 +#: models.py:618 msgid "waiting approval" msgstr "en attente d'approbation" -#: models.py:609 +#: models.py:624 msgid "pending" msgstr "en attente" -#: models.py:624 +#: models.py:639 msgid "Invitation" msgstr "Invitation" -#: models.py:692 +#: models.py:707 #, python-format msgid "Text %(link_to_text)s edited" msgstr "Le texte %(link_to_text)s a été édité" -#: models.py:693 +#: models.py:708 #, python-format msgid "Text %(link_to_text)s edited (new version created)" msgstr "Le texte %(link_to_text)s a été édité (nouvelle version créée)" -#: models.py:694 +#: models.py:709 #, python-format msgid "Text %(link_to_text)s added" msgstr "Le texte %(link_to_text)s a été ajouté" -#: models.py:695 +#: models.py:710 #, python-format msgid "Text %(link_to_text)s removed" msgstr "Le texte %(link_to_text)s a été supprimé" -#: models.py:696 +#: models.py:711 #, python-format msgid "Comment %(link_to_comment)s added on text %(link_to_text)s" msgstr "Commentaire %(link_to_comment)s ajouté sur le texte %(link_to_text)s" -#: models.py:697 +#: models.py:712 #, python-format msgid "Comment %(link_to_comment)s removed from text %(link_to_text)s" msgstr "Commentaire %(link_to_comment)s supprimé du texte %(link_to_text)s" -#: models.py:698 +#: models.py:713 #, python-format msgid "User %(username)s added" msgstr "L'utilisateur %(username)s a été ajouté" -#: models.py:699 +#: models.py:714 #, python-format msgid "User %(username)s access to workspace enabled" msgstr "Accès de utilisateur %(username)s à l'espace de travail activé" -#: models.py:700 +#: models.py:715 #, python-format msgid "User %(username)s access to workspace refused" msgstr "Accès de utilisateur %(username)s à l'espace de travail suspendu" -#: models.py:701 +#: models.py:716 #, python-format msgid "User %(username)s access to workspace suspended" msgstr "Accès de utilisateur %(username)s à l'espace de travail suspendu" -#: models.py:702 +#: models.py:717 #, python-format msgid "User %(username)s access to workspace activated" msgstr "Accès de utilisateur %(username)s à l'espace de travail activé" -#: models.py:703 +#: models.py:718 #, python-format msgid "User %(username)s has activated his account" msgstr "L'utilisateur %(username)s a activé son compte" -#: models.py:758 -#: models.py:766 +#: models.py:773 models.py:781 #, python-format msgid "by \"%(username)s\"" msgstr "par \"%(username)s\"" -#: models.py:760 +#: models.py:775 #, python-format msgid "%(time_since)s ago" msgstr "il y a %(time_since)s" @@ -243,8 +240,7 @@ msgid "Norwegian" msgstr "Norvégien" -#: static_i18n.py:6 -#: static_i18n.py:11 +#: static_i18n.py:6 static_i18n.py:11 msgid "Observer" msgstr "Observateur" @@ -356,8 +352,7 @@ msgid "An error has occurred." msgstr "Une erreur s'est produite." -#: templates/site/activate.html:10 -#: templates/site/user_activate.html:10 +#: templates/site/activate.html:10 templates/site/user_activate.html:10 #: views/user.py:325 msgid "Activate your account" msgstr "Activer votre compte" @@ -366,8 +361,7 @@ msgid "Activate" msgstr "Activer" -#: templates/site/contact.html:6 -#: templates/site/layout/footer.html:9 +#: templates/site/contact.html:6 templates/site/layout/footer.html:9 #: templates/site/macros/user_actions.html:20 msgid "Contact" msgstr "Contact" @@ -378,20 +372,15 @@ #: templates/site/contact.html:26 #: templates/site/notifications_desactivate.html:32 -#: templates/site/settings.html:23 -#: templates/site/text_create_content.html:47 -#: templates/site/text_create_upload.html:42 -#: templates/site/user_add.html:34 -#: templates/site/user_add_text.html:38 -#: templates/site/user_contact.html:25 -#: templates/site/user_edit.html:29 -#: templates/site/user_mass_add.html:34 +#: templates/site/settings.html:23 templates/site/text_create_content.html:47 +#: templates/site/text_create_upload.html:42 templates/site/user_add.html:34 +#: templates/site/user_add_text.html:38 templates/site/user_contact.html:25 +#: templates/site/user_edit.html:29 templates/site/user_mass_add.html:34 #: templates/site/user_mass_add_text.html:38 msgid "Cancel" msgstr "Annuler" -#: templates/site/dashboard.html:12 -#: templates/site/macros/main_tabs.html:10 +#: templates/site/dashboard.html:12 templates/site/macros/main_tabs.html:10 msgid "Dashboard" msgstr "Tableau de bord" @@ -399,20 +388,16 @@ msgid "Actions" msgstr "Actions" -#: templates/site/dashboard.html:48 -#: templates/site/text_create_content.html:4 +#: templates/site/dashboard.html:48 templates/site/text_create_content.html:4 #: templates/site/text_create_content.html:28 -#: templates/site/text_create_upload.html:26 -#: templates/site/text_list.html:40 +#: templates/site/text_create_upload.html:26 templates/site/text_list.html:40 #: templates/site/layout/header.html:10 msgid "Write a text" msgstr "Ecrire un texte" -#: templates/site/dashboard.html:49 -#: templates/site/text_create_content.html:30 +#: templates/site/dashboard.html:49 templates/site/text_create_content.html:30 #: templates/site/text_create_upload.html:4 -#: templates/site/text_create_upload.html:28 -#: templates/site/text_list.html:42 +#: templates/site/text_create_upload.html:28 templates/site/text_list.html:42 #: templates/site/layout/header.html:11 msgid "Upload a text" msgstr "Charger un texte" @@ -442,13 +427,11 @@ msgid "user %(user)s awaits approval" msgstr "l'utilisateur %(user)s est en attente d'approbation" -#: templates/site/dashboard.html:80 -#: templates/site/dashboard.html.py:126 +#: templates/site/dashboard.html:80 templates/site/dashboard.html.py:126 msgid "approve" msgstr "accepter" -#: templates/site/dashboard.html:80 -#: templates/site/dashboard.html.py:126 +#: templates/site/dashboard.html:80 templates/site/dashboard.html.py:126 msgid "refuse" msgstr "refuser" @@ -458,21 +441,26 @@ #: templates/site/dashboard.html:85 #: templates/site/macros/user_moderation.html:8 -msgid "Are you sure you want to approve this user's membership to the workspace?" -msgstr "Etes-vous sûr de vouloir accepter l'accès de cet utilisateur à l'espace de travail ?" +msgid "" +"Are you sure you want to approve this user's membership to the workspace?" +msgstr "" +"Etes-vous sûr de vouloir accepter l'accès de cet utilisateur à l'espace de " +"travail ?" #: templates/site/dashboard.html:94 #: templates/site/macros/user_moderation.html:17 -msgid "Are you sure you want to refuse this user's membership to the workspace?" -msgstr "Etes-vous sûr de vouloir refuser l'accès de cet utilisateur à l'espace de travail ?" +msgid "" +"Are you sure you want to refuse this user's membership to the workspace?" +msgstr "" +"Etes-vous sûr de vouloir refuser l'accès de cet utilisateur à l'espace de " +"travail ?" #: templates/site/dashboard.html:106 #, python-format msgid "registered %(duration)s ago" msgstr "enregistré il y a %(duration)s" -#: templates/site/dashboard.html:120 -#: templates/site/dashboard.html.py:126 +#: templates/site/dashboard.html:120 templates/site/dashboard.html.py:126 msgid "comment" msgstr "commentaire" @@ -497,8 +485,7 @@ msgid "Are you sure you want to refuse this comment?" msgstr "Etes vous sûr de vouloir refuser ce commentaire ?" -#: templates/site/dashboard.html:166 -#: templates/site/dashboard.html.py:199 +#: templates/site/dashboard.html:166 templates/site/dashboard.html.py:199 #, python-format msgid "modified %(duration)s ago" msgstr "modifié il y a %(duration)s" @@ -507,21 +494,18 @@ msgid "Recent texts" msgstr "Textes récents" -#: templates/site/dashboard.html:184 -#: templates/site/macros/paginator.html:9 +#: templates/site/dashboard.html:184 templates/site/macros/paginator.html:9 msgid "all" msgstr "tous" -#: templates/site/dashboard.html:199 -#: templates/site/macros/text_meta.html:4 +#: templates/site/dashboard.html:199 templates/site/macros/text_meta.html:4 #, python-format msgid "%(nb_comments)s comment" msgid_plural "%(nb_comments)s comments" msgstr[0] "%(nb_comments)s commentaire" msgstr[1] "%(nb_comments)s commentaires" -#: templates/site/dashboard.html:204 -#: templates/site/text_list.html:221 +#: templates/site/dashboard.html:204 templates/site/text_list.html:221 msgid "No texts yet" msgstr "Aucun texte" @@ -545,10 +529,8 @@ msgid "Access" msgstr "Accès" -#: templates/site/dashboard.html:231 -#: templates/site/dashboard.html.py:242 -#: templates/site/text_list.html:206 -#: templates/site/user_list.html:158 +#: templates/site/dashboard.html:231 templates/site/dashboard.html.py:242 +#: templates/site/text_list.html:206 templates/site/user_list.html:158 #: templates/site/user_list.html.py:188 msgid "Loading..." msgstr "Chargement ..." @@ -565,8 +547,7 @@ msgid "texts" msgstr "textes" -#: templates/site/dashboard.html:262 -#: templates/site/text_list.html:139 +#: templates/site/dashboard.html:262 templates/site/text_list.html:139 msgid "comments" msgstr "commentaires" @@ -595,26 +576,21 @@ msgid "No comments yet" msgstr "Aucun commentaire" -#: templates/site/followup.html:7 -#: templates/site/macros/main_tabs.html:16 +#: templates/site/followup.html:7 templates/site/macros/main_tabs.html:16 #: templates/site/macros/text_tabs.html:22 msgid "Followup" msgstr "Suivi" -#: templates/site/followup.html:20 -#: templates/site/text_followup.html:22 +#: templates/site/followup.html:20 templates/site/text_followup.html:22 msgid "Feeds" msgstr "Flux" -#: templates/site/followup.html:22 -#: templates/site/text_followup.html:24 +#: templates/site/followup.html:22 templates/site/text_followup.html:24 msgid "Public feed" msgstr "Flux public" -#: templates/site/followup.html:22 -#: templates/site/followup.html.py:35 -#: templates/site/help.html:6 -#: templates/site/text_embed.html:26 +#: templates/site/followup.html:22 templates/site/followup.html.py:35 +#: templates/site/help.html:6 templates/site/text_embed.html:26 #: templates/site/layout/footer.html:26 #: templates/site/macros/form_fields.html:15 msgid "Help" @@ -628,8 +604,7 @@ msgid "This is the public feed for the workspace." msgstr "Ceci est le flux public de l'espace de travail." -#: templates/site/followup.html:35 -#: templates/site/text_followup.html:37 +#: templates/site/followup.html:35 templates/site/text_followup.html:37 msgid "Private feed" msgstr "Flux privé" @@ -638,16 +613,19 @@ msgstr "Flux privé de l'espace de travail" #: templates/site/followup.html:43 -msgid "This is the private feed for the workspace. Don't share this address with others unless you want them to see all activities on the workspace." -msgstr "Ceci est le flux privé de l'espace de travail. Ne partagez cette adresse que si vous voulez que d'autres que vous-même puissent suivre toutes les activités de l'espace de travail." +msgid "" +"This is the private feed for the workspace. Don't share this address with " +"others unless you want them to see all activities on the workspace." +msgstr "" +"Ceci est le flux privé de l'espace de travail. Ne partagez cette adresse que " +"si vous voulez que d'autres que vous-même puissent suivre toutes les " +"activités de l'espace de travail." -#: templates/site/followup.html:45 -#: templates/site/text_followup.html:47 +#: templates/site/followup.html:45 templates/site/text_followup.html:47 msgid "Reset private feed url" msgstr "Réinitialiser l'adresse du flux privé" -#: templates/site/followup.html:49 -#: templates/site/text_followup.html:51 +#: templates/site/followup.html:49 templates/site/text_followup.html:51 msgid "Activate private feed" msgstr "Activer le flux privé" @@ -655,8 +633,7 @@ msgid "The private feed for this workspace is not yet activated." msgstr "Le flux privé de cet espace de travail n'est pas encore activé." -#: templates/site/followup.html:55 -#: templates/site/text_followup.html:58 +#: templates/site/followup.html:55 templates/site/text_followup.html:58 msgid "Email notifications" msgstr "Notifications par email" @@ -665,11 +642,14 @@ msgstr "S'abonner aux notifications de l'espace de travail" #: templates/site/followup.html:62 -msgid "Subscribe to all replies notifications in discussions where you have participated" -msgstr "S'abonner aux notifications concernant les commentaires ou réponses dans les discussions auxquelles vous avez participé" +msgid "" +"Subscribe to all replies notifications in discussions where you have " +"participated" +msgstr "" +"S'abonner aux notifications concernant les commentaires ou réponses dans les " +"discussions auxquelles vous avez participé" -#: templates/site/login.html:8 -#: templates/site/login_form.html:19 +#: templates/site/login.html:8 templates/site/login_form.html:19 #: templates/site/layout/header.html:17 msgid "Login" msgstr "Se connecter" @@ -679,8 +659,7 @@ msgid "%(wname)s Login" msgstr "Se connecter à %(wname)s" -#: templates/site/login_form.html:20 -#: templates/site/register.html:8 +#: templates/site/login_form.html:20 templates/site/register.html:8 #: templates/site/layout/header.html:18 msgid "Register" msgstr "S'enregistrer" @@ -710,20 +689,15 @@ msgid "Desactivate" msgstr "Désactiver" -#: templates/site/profile.html:6 -#: templates/site/profile.html.py:14 +#: templates/site/profile.html:6 templates/site/profile.html.py:14 #, python-format msgid "Your profile (%(username)s)" msgstr "Votre profil (%(username)s)" -#: templates/site/profile.html:26 -#: templates/site/text_create_content.html:45 -#: templates/site/text_create_upload.html:40 -#: templates/site/text_edit.html:34 -#: templates/site/text_settings.html:23 -#: templates/site/text_share.html:153 -#: templates/site/user_activate.html:27 -#: templates/site/user_list.html:210 +#: templates/site/profile.html:26 templates/site/text_create_content.html:45 +#: templates/site/text_create_upload.html:40 templates/site/text_edit.html:36 +#: templates/site/text_settings.html:23 templates/site/text_share.html:153 +#: templates/site/user_activate.html:27 templates/site/user_list.html:210 #: templates/site/layout/base_workspace_form.html:32 msgid "Save" msgstr "Enregistrer" @@ -733,20 +707,22 @@ msgid "%(wname)s Registration" msgstr "S'enregistrer sur %(wname)s" -#: templates/site/settings.html:5 -#: templates/site/text_list.html:181 +#: templates/site/settings.html:5 templates/site/text_list.html:181 #: templates/site/macros/main_tabs.html:14 #: templates/site/macros/text_tabs.html:19 msgid "Settings" msgstr "Paramètres" #: templates/site/settings.html:32 -msgid "Are you sure you want to change the role model? All roles (except managers) will be resetted!" -msgstr "Etes-vous sur de vouloir modifier le modèle des rôles ? Tous les roles actifs (excepté les gestionnaires) seront remis à zéro !" +msgid "" +"Are you sure you want to change the role model? All roles (except managers) " +"will be resetted!" +msgstr "" +"Etes-vous sur de vouloir modifier le modèle des rôles ? Tous les roles " +"actifs (excepté les gestionnaires) seront remis à zéro !" #: templates/site/text_create_content.html:26 -#: templates/site/text_create_upload.html:24 -#: templates/site/text_list.html:37 +#: templates/site/text_create_upload.html:24 templates/site/text_list.html:37 msgid "Text list" msgstr "Textes" @@ -759,16 +735,26 @@ msgstr "Encapsulation du texte" #: templates/site/text_embed.html:25 -msgid "Copy this code into your site to display text with comments. Users will also be able to add comments from your site depending an anonymous users' roles." -msgstr "Copier ce code dans votre site pour afficher le texte et ses commentaires. Les utilisateurs pourront ajouter leurs commentaires (si vous avez activé cette possiblité)." +msgid "" +"Copy this code into your site to display text with comments. Users will also " +"be able to add comments from your site depending an anonymous users' roles." +msgstr "" +"Copier ce code dans votre site pour afficher le texte et ses commentaires. " +"Les utilisateurs pourront ajouter leurs commentaires (si vous avez activé " +"cette possiblité)." #: templates/site/text_embed.html:33 msgid "Warning:" msgstr "Attention: " #: templates/site/text_embed.html:33 -msgid "You won't successfully embed the text before you give anonymous users a role allowing them to view the text." -msgstr "Vous ne pourrez pas encapsuler votre texte dans un site externe si vous ne donnez pas aux utilisateurs anonymes un rôle leur permettant de voir le texte." +msgid "" +"You won't successfully embed the text before you give anonymous users a role " +"allowing them to view the text." +msgstr "" +"Vous ne pourrez pas encapsuler votre texte dans un site externe si vous ne " +"donnez pas aux utilisateurs anonymes un rôle leur permettant de voir le " +"texte." #: templates/site/text_followup.html:7 msgid "Text followup" @@ -788,16 +774,25 @@ msgstr "Flux privé du texte" #: templates/site/text_followup.html:45 -msgid "This is the private feed for the text. Don't share this address with others unless you want them to see all activities on this text." -msgstr "Ceci est le flux privé du texte. Ne partagez cette adresse que si vous voulez que d'autres que vous-même puissent suivre toutes les activités du texte." +msgid "" +"This is the private feed for the text. Don't share this address with others " +"unless you want them to see all activities on this text." +msgstr "" +"Ceci est le flux privé du texte. Ne partagez cette adresse que si vous " +"voulez que d'autres que vous-même puissent suivre toutes les activités du " +"texte." #: templates/site/text_followup.html:53 msgid "The private feed for this text is not yet activated." msgstr "Le flux privé de ce texte n'est pas encore activé." #: templates/site/text_followup.html:61 -msgid "You will receive text notifications because you subscribed to notifications at the workspace level" -msgstr "Vous recevrez les notifications de ce texte parce que vous vous êtes abonné aux notifications au niveau de l'espace de travail tout entier" +msgid "" +"You will receive text notifications because you subscribed to notifications " +"at the workspace level" +msgstr "" +"Vous recevrez les notifications de ce texte parce que vous vous êtes abonné " +"aux notifications au niveau de l'espace de travail tout entier" #: templates/site/text_followup.html:64 msgid "Subscribe to all text notifications" @@ -837,8 +832,7 @@ msgid "Differences between version #%(v1_nid)s and version #%(v2_nid)s:" msgstr "Différences entre les versions n°%(v1_nid)s et n°%(v2_nid)s :" -#: templates/site/text_history.html:73 -#: templates/site/text_history.html:85 +#: templates/site/text_history.html:73 templates/site/text_history.html:85 #: templates/site/text_history.html:91 #, python-format msgid "Version #%(version_number)s created on %(date)s" @@ -852,49 +846,39 @@ msgid "Texts" msgstr "Textes" -#: templates/site/text_list.html:47 -#: templates/site/text_share.html:35 -#: templates/site/user_list.html:7 -#: templates/site/user_list.html.py:32 -#: templates/site/user_list.html:40 -#: templates/site/user_list.html.py:116 +#: templates/site/text_list.html:47 templates/site/text_share.html:35 +#: templates/site/user_list.html:7 templates/site/user_list.html.py:32 +#: templates/site/user_list.html:40 templates/site/user_list.html.py:116 msgid "People' list" msgstr "Liste des utilisateurs" -#: templates/site/text_list.html:50 -#: templates/site/text_share.html:40 +#: templates/site/text_list.html:50 templates/site/text_share.html:40 #: templates/site/user_list.html:45 msgid "Filter by tag:" msgstr "Filtrer avec le mot-clé" -#: templates/site/text_list.html:52 -#: templates/site/text_share.html:42 +#: templates/site/text_list.html:52 templates/site/text_share.html:42 #: templates/site/user_list.html:47 msgid "All" msgstr "Tous" -#: templates/site/text_list.html:79 -#: templates/site/user_list.html:72 +#: templates/site/text_list.html:79 templates/site/user_list.html:72 msgid "Bulk Actions" msgstr "Actions multiples" -#: templates/site/text_list.html:80 -#: templates/site/text_list.html.py:161 +#: templates/site/text_list.html:80 templates/site/text_list.html.py:161 msgid "Delete" msgstr "Supprimer" -#: templates/site/text_list.html:83 -#: templates/site/user_list.html:81 +#: templates/site/text_list.html:83 templates/site/user_list.html:81 msgid "Apply" msgstr "Appliquer" -#: templates/site/text_list.html:104 -#: templates/site/user_list.html:102 +#: templates/site/text_list.html:104 templates/site/user_list.html:102 msgid "Are you sure?" msgstr "Etes vous sûr ?" -#: templates/site/text_list.html:136 -#: templates/site/macros/text_tabs.html:10 +#: templates/site/text_list.html:136 templates/site/macros/text_tabs.html:10 msgid "Text" msgstr "Texte" @@ -906,8 +890,7 @@ msgid "Modified" msgstr "Modifié" -#: templates/site/text_list.html:140 -#: templates/site/user_list.html:136 +#: templates/site/text_list.html:140 templates/site/user_list.html:136 msgid "Last week activity" msgstr "Activités de la dernière semaine" @@ -926,8 +909,7 @@ msgid "View" msgstr "Voir" -#: templates/site/text_list.html:160 -#: templates/site/macros/text_tabs.html:12 +#: templates/site/text_list.html:160 templates/site/macros/text_tabs.html:12 #: templates/site/macros/user_actions.html:19 msgid "Edit" msgstr "Editer" @@ -944,81 +926,71 @@ msgid "Edit user" msgstr "Editer l'utilisateur" -#: templates/site/text_share.html:27 -#: templates/site/user_add.html:20 -#: templates/site/user_add_text.html:23 -#: templates/site/user_contact.html:19 -#: templates/site/user_edit.html:20 -#: templates/site/user_mass_add.html:20 +#: templates/site/text_share.html:27 templates/site/user_add.html:20 +#: templates/site/user_add_text.html:23 templates/site/user_contact.html:19 +#: templates/site/user_edit.html:20 templates/site/user_mass_add.html:20 #: templates/site/user_mass_add_text.html:23 msgid "Users' list" msgstr "Liste des utilisateurs" -#: templates/site/text_share.html:29 -#: templates/site/user_add.html:6 -#: templates/site/user_add.html.py:22 -#: templates/site/user_add_text.html:6 -#: templates/site/user_add_text.html:25 -#: templates/site/user_contact.html:19 -#: templates/site/user_edit.html:22 -#: templates/site/user_list.html:34 +#: templates/site/text_share.html:29 templates/site/user_add.html:6 +#: templates/site/user_add.html.py:22 templates/site/user_add_text.html:6 +#: templates/site/user_add_text.html:25 templates/site/user_contact.html:19 +#: templates/site/user_edit.html:22 templates/site/user_list.html:34 #: templates/site/user_mass_add.html:22 #: templates/site/user_mass_add_text.html:6 #: templates/site/user_mass_add_text.html:25 msgid "Add a new user" msgstr "Ajouter un utilisateur" -#: templates/site/text_share.html:31 -#: templates/site/user_add.html:24 -#: templates/site/user_add_text.html:27 -#: templates/site/user_list.html:36 -#: templates/site/user_mass_add.html:6 -#: templates/site/user_mass_add.html:24 +#: templates/site/text_share.html:31 templates/site/user_add.html:24 +#: templates/site/user_add_text.html:27 templates/site/user_list.html:36 +#: templates/site/user_mass_add.html:6 templates/site/user_mass_add.html:24 #: templates/site/user_mass_add_text.html:27 msgid "Add users in bulk" msgstr "Ajouter des utilisateurs en masse" -#: templates/site/text_share.html:38 -#: templates/site/user_list.html:43 +#: templates/site/text_share.html:38 templates/site/user_list.html:43 msgid "Hide suspended users" msgstr "Masquer les utilisateurs désactivés" -#: templates/site/text_share.html:38 -#: templates/site/user_list.html:43 +#: templates/site/text_share.html:38 templates/site/user_list.html:43 msgid "Display suspended users" msgstr "Afficher les utilisateurs désactivés" -#: templates/site/text_share.html:86 -#: templates/site/user_list.html:132 +#: templates/site/text_share.html:86 templates/site/user_list.html:132 msgid "User" msgstr "Utilisateur" #: templates/site/text_share.html:87 -msgid "The 'Workspace role' is the global role that applies to every text, you can give a user a particular role on this text using the 'local role' column on the right" -msgstr "Le 'rôle dans l'espace de travail' est le rôle global qui s'applique à tous les textes, vous pouvez donner à un utilisateur particulier un rôle différent sur ce texte via la colonne 'rôle local' à droite" +msgid "" +"The 'Workspace role' is the global role that applies to every text, you can " +"give a user a particular role on this text using the 'text role' column on " +"the right" +msgstr "" +"Le 'rôle dans l'espace de travail' est le rôle global qui s'applique à tous " +"les textes. Vous pouvez donner à un utilisateur particulier un rôle " +"différent sur ce texte via la colonne 'rôle sur le texte' à droite" #: templates/site/text_share.html:87 msgid "Workspace role" msgstr "Rôle dans l'espace de travail" #: templates/site/text_share.html:88 -msgid "Local role" -msgstr "Rôle local" +msgid "Text role" +msgstr "Rôle sur le texte" #: templates/site/text_share.html:101 #, python-format -msgid "This role has been overriden on this text by a local role: %(rolename)s" -msgstr "Ce rôle a été surchargé par un rôle local : %(rolename)s" +msgid "This role has been overriden on this text by a text role: %(rolename)s" +msgstr "Ce rôle a été surchargé par un rôle sur le texte : %(rolename)s" -#: templates/site/text_share.html:128 -#: templates/site/user_edit.html:6 -#: templates/site/user_edit.html.py:24 -#: templates/site/user_list.html:177 +#: templates/site/text_share.html:128 templates/site/user_edit.html:6 +#: templates/site/user_edit.html.py:24 templates/site/user_list.html:177 msgid "Edit anonymous users" msgstr "Editer 'l'utilisateur anonyme'" -#: templates/site/text_share.html:128 -#: templates/site/user_list.html:177 +#: templates/site/text_share.html:128 templates/site/user_list.html:177 msgid "Anonymous users" msgstr "Utilisateurs anonymes" @@ -1059,18 +1031,20 @@ "The user will receive an email invitation to join the workspace.\n" "You can customize the email sent by using the 'Note' field bellow." msgstr "" -"L'utilisateur recevra un email d'invitation à rejoindre l'espace de travail.\n" +"L'utilisateur recevra un email d'invitation à rejoindre l'espace de " +"travail.\n" "Vous pouvez personnaliser cet email en utilisant le champ 'Note' ci-dessous." #: templates/site/user_add_text.html:29 msgid "The user will receive an email invitation to join the workspace." -msgstr "L'utilisateur recevra un email d'invitation à rejoindre l'espace de travail." +msgstr "" +"L'utilisateur recevra un email d'invitation à rejoindre l'espace de travail." -#: templates/site/user_add_text.html:30 -#: templates/site/user_mass_add.html:27 +#: templates/site/user_add_text.html:30 templates/site/user_mass_add.html:27 #: templates/site/user_mass_add_text.html:30 msgid "You can customize the email sent by using the 'Note' field bellow." -msgstr "Vous pouvez personnaliser cet email en utilisant le champ 'Note' ci-dessous." +msgstr "" +"Vous pouvez personnaliser cet email en utilisant le champ 'Note' ci-dessous." #: templates/site/user_contact.html:6 msgid "Contact user" @@ -1081,19 +1055,16 @@ msgid "Contact user %(username)s" msgstr "Contacter l'utilisateur %(username)s" -#: templates/site/user_edit.html:6 -#: templates/site/user_edit.html.py:24 +#: templates/site/user_edit.html:6 templates/site/user_edit.html.py:24 #, python-format msgid "Edit user %(username)s" msgstr "Editer l'utilisateur %(username)s" -#: templates/site/user_list.html:73 -#: templates/site/macros/user_actions.html:28 +#: templates/site/user_list.html:73 templates/site/macros/user_actions.html:28 msgid "Suspend access" msgstr "Désactiver l'accès" -#: templates/site/user_list.html:74 -#: templates/site/macros/user_actions.html:23 +#: templates/site/user_list.html:74 templates/site/macros/user_actions.html:23 msgid "Enable access" msgstr "Activer l'accès" @@ -1102,8 +1073,7 @@ msgid "Change role to %(role_name)s" msgstr "Modifier le rôle en %(role_name)s" -#: templates/site/user_list.html:133 -#: views/user.py:278 +#: templates/site/user_list.html:133 views/user.py:278 msgid "Email" msgstr "Email" @@ -1118,7 +1088,9 @@ #: templates/site/user_mass_add.html:26 #: templates/site/user_mass_add_text.html:29 msgid "The users will receive an email invitation to join the workspace." -msgstr "Les utilisateurs recevront un email d'invitation à rejoindre l'espace de travail." +msgstr "" +"Les utilisateurs recevront un email d'invitation à rejoindre l'espace de " +"travail." #: templates/site/layout/base_text.html:16 #: templates/site/layout/base_workspace.html:14 @@ -1180,8 +1152,12 @@ msgstr "par %(name)s le %(date)s" #: templates/site/macros/text_editor.html:38 -msgid "You have attempted to leave this page. Unsaved changes will be lost. Are you sure you want to exit this page?" -msgstr "Vous avez tenté de quitter la page. Les modifications non sauvegardées seront perdues. Etes vous sûr de vouloir quitter cette page ?" +msgid "" +"You have attempted to leave this page. Unsaved changes will be lost. Are you " +"sure you want to exit this page?" +msgstr "" +"Vous avez tenté de quitter la page. Les modifications non sauvegardées " +"seront perdues. Etes vous sûr de vouloir quitter cette page ?" #: templates/site/macros/text_tabs.html:15 msgid "People" @@ -1211,15 +1187,21 @@ #: templates/site/macros/user_actions.html:38 msgid "Are you sure you want to suspend this user's access to the workspace?" -msgstr "Etes vous sûr de vouloir désactiver l'accès de cet utilisateur à l'espace de travail ?" +msgstr "" +"Etes vous sûr de vouloir désactiver l'accès de cet utilisateur à l'espace de " +"travail ?" #: templates/site/macros/user_actions.html:47 msgid "Are you sure you want to enable this user's access to the workspace?" -msgstr "Etes vous sûr de vouloir activer l'accès de cet utilisateur à l'espace de travail ?" +msgstr "" +"Etes vous sûr de vouloir activer l'accès de cet utilisateur à l'espace de " +"travail ?" #: templates/site/macros/user_actions.html:56 msgid "Are you sure you want to send this user an invitation to the workspace?" -msgstr "Etes vous sûr de vouloir envoyer à cet utilisateur une invitation à rejoindre l'espace de travail ?" +msgstr "" +"Etes vous sûr de vouloir envoyer à cet utilisateur une invitation à " +"rejoindre l'espace de travail ?" #: templates/site/macros/user_moderation.html:3 msgid "Approve" @@ -1238,8 +1220,11 @@ msgstr "Charger un fichier (optionnel)" #: views/create.py:27 -msgid "Upload a file from your computer instead of using the direct input above" -msgstr "Charger un fichier de votre ordinateur plutôt que d'utiliser le champ de saisie ci-dessus" +msgid "" +"Upload a file from your computer instead of using the direct input above" +msgstr "" +"Charger un fichier de votre ordinateur plutôt que d'utiliser le champ de " +"saisie ci-dessus" #: views/create.py:38 msgid "You should specify a file to upload." @@ -1249,8 +1234,7 @@ msgid "The title of your text" msgstr "Le titre de votre texte" -#: views/create.py:71 -#: views/create.py:108 +#: views/create.py:70 views/create.py:107 #, python-format msgid "Text \"%(text_title)s\" has been created" msgstr "Le texte \"%(text_title)s\" a été créé" @@ -1295,8 +1279,7 @@ msgid "Private activity feed for text %(text_title)s" msgstr "Flux public pour le texte %(text_title)s" -#: views/followup.py:31 -#: views/followup.py:80 +#: views/followup.py:31 views/followup.py:80 msgid "Private feed activated." msgstr "Flux privé activé." @@ -1320,9 +1303,7 @@ msgid "Private notifications feed reseted." msgstr "Flux privé réinitialisé." -#: views/site.py:81 -#: views/texts.py:132 -#: views/user.py:522 +#: views/site.py:81 views/texts.py:132 views/user.py:520 msgid "You're logged in!" msgstr "Vous êtes connecté !" @@ -1367,16 +1348,24 @@ msgstr "S'enregistrer sur l'espace de travail" #: views/site.py:160 -msgid "Can users register themselves into the workspace? (if not, only invitations by managers can create new users)" -msgstr "Les utilisateurs peuvent-ils s'enregistrer sur l'espace de travail ? (dans le cas contraire l'ajout d'utilisateurs à l'espace de travail peut seulement se faire par l'envoi d'invitations par les gestionnaires)" +msgid "" +"Can users register themselves into the workspace? (if not, only invitations " +"by managers can create new users)" +msgstr "" +"Les utilisateurs peuvent-ils s'enregistrer sur l'espace de travail ? (dans " +"le cas contraire l'ajout d'utilisateurs à l'espace de travail peut seulement " +"se faire par l'envoi d'invitations par les gestionnaires)" #: views/site.py:164 msgid "Workspace registration moderation" msgstr "Modération de l'enregistrement sur l'espace de travail" #: views/site.py:165 -msgid "Should new users be moderated (registration will require manager's approval)" -msgstr "Les nouveaux utilisateurs doivent-ils être modérés (l'enregistrement exigera alors l'approbation par un gestionnaire)" +msgid "" +"Should new users be moderated (registration will require manager's approval)" +msgstr "" +"Les nouveaux utilisateurs doivent-ils être modérés (l'enregistrement exigera " +"alors l'approbation par un gestionnaire)" #: views/site.py:169 msgid "Role model" @@ -1395,34 +1384,35 @@ msgid "%(nb_texts)i text(s) deleted" msgstr "%(nb_texts)i texte(s) supprimés" -#: views/texts.py:211 +#: views/texts.py:210 #, python-format msgid "Text %(text_title)s deleted" msgstr "texte %(text_title)s supprimé" -#: views/texts.py:617 +#: views/texts.py:615 msgid "Note (optional)" msgstr "Note (facultative)" -#: views/texts.py:620 +#: views/texts.py:618 msgid "Add a note to explain the modifications made to the text" msgstr "Ajouter une note pour expliquer les modifications apportées au texte" -#: views/texts.py:630 +#: views/texts.py:628 msgid "New version (optional)" msgstr "Nouvelle version (facultative)" -#: views/texts.py:633 +#: views/texts.py:631 msgid "Create a new version of this text (recommended)" msgstr "créér une nouvelle version de ce texte (recommandé)" -#: views/texts.py:636 +#: views/texts.py:634 msgid "Keep comments (optional)" msgstr "Conserver les commentaires (facultatif)" -#: views/texts.py:639 +#: views/texts.py:637 msgid "Keep comments (if not affected by the edit)" -msgstr "Conserver les commentaires dont la portée n'a pas été affectée par l'édition" +msgstr "" +"Conserver les commentaires dont la portée n'a pas été affectée par l'édition" #: views/texts.py:700 msgid "Name (optional)" @@ -1435,16 +1425,15 @@ #: views/texts.py:751 #, python-format msgid "A new version (copied from version %(version_id)s) has been created" -msgstr "Une nouvelle version (copiée depuis la version %(version_id)s) a été créée" +msgstr "" +"Une nouvelle version (copiée depuis la version %(version_id)s) a été créée" -#: views/texts.py:857 -#: views/user.py:79 -#: views/user.py:99 +#: views/texts.py:859 views/user.py:79 views/user.py:99 #, python-format msgid "%(count)i user(s) role modified" msgstr "%(count)i rôle(s) d'utilisateur modifié(s)" -#: views/texts.py:915 +#: views/texts.py:917 msgid "Text settings updated" msgstr "Paramètres mis à jour" @@ -1472,15 +1461,23 @@ #: views/user.py:164 msgid "Add multiples emails one per line (or separated by \",\" or \";\")" -msgstr "Ajouter des emails multiples (un par ligne ou séparés par \",\" or \";\")" +msgstr "" +"Ajouter des emails multiples (un par ligne ou séparés par \",\" or \";\")" #: views/user.py:181 msgid "Workspace level role" msgstr "Rôle dans l'espace de travail" #: views/user.py:182 -msgid "This role will apply to every text in the workspace. To share only a (few) texts with this user, you can leave this blank and delegate roles on texts once the user is created." -msgstr "Ce rôle s'appliquera à tous les textes dans l'espace de travail. Pour partager seulement quelques textes avec cet utilisateur, vous pouvez laisser ce champ vide et déléguer les rôles sur les textes une fois l'utilisateur créé." +msgid "" +"This role will apply to every text in the workspace. To share only a (few) " +"texts with this user, you can leave this blank and delegate roles on texts " +"once the user is created." +msgstr "" +"Ce rôle s'appliquera à tous les textes dans l'espace de travail. Pour " +"partager seulement quelques textes avec cet utilisateur, vous pouvez laisser " +"ce champ vide et déléguer les rôles sur les textes une fois l'utilisateur " +"créé." #: views/user.py:198 msgid "Text level role" @@ -1511,8 +1508,7 @@ msgid "This username is already in use. Please supply a different username." msgstr "Ce nom d'utilisateur est déjà utilisé. Merci d'en fournir un autre." -#: views/user.py:315 -#: views/user.py:331 +#: views/user.py:315 views/user.py:331 msgid "Your account has been activated. You're now logged-in." msgstr "Votre compte a été activé. Vous êtes maintenant connecté." @@ -1549,161 +1545,53 @@ msgid "Profile updated" msgstr "Profil mis à jour" -#: views/user.py:434 +#: views/user.py:432 msgid "Anonymous user role modified." msgstr "Role de l'utilisateur anonyme modifié." -#: views/user.py:456 +#: views/user.py:454 msgid "User modified" msgstr "Utilisateur modifié" -#: views/user.py:471 +#: views/user.py:469 msgid "Subject" msgstr "Sujet" -#: views/user.py:472 +#: views/user.py:470 msgid "Subject of the email" msgstr "Sujet du message" -#: views/user.py:475 +#: views/user.py:473 msgid "Body" msgstr "Corps" -#: views/user.py:476 +#: views/user.py:474 msgid "Body of the email" msgstr "Corps du message" -#: views/user.py:496 +#: views/user.py:494 msgid "Email sent." msgstr "Email envoyé." -#: views/user.py:516 +#: views/user.py:514 msgid "This account is suspended, contact the workspace administrator." -msgstr "Ce compte est désactivé, veuillez contacter le gestionnaire de l'espace de travail." +msgstr "" +"Ce compte est désactivé, veuillez contacter le gestionnaire de l'espace de " +"travail." -#: views/user.py:547 +#: views/user.py:545 msgid "You've been logged out." msgstr "Vous êtes déconnecté." -#: views/user.py:563 -msgid "You've been registered, you will receive a confirmation mail once a moderator has approved your membership." -msgstr "Enregistrement réussi, vous recevrez un message de confirmation quand un gestionnaire de l'espace de travail aura activé votre compte." - -#: views/user.py:566 -msgid "You've been registered, please check your email for the confirm message." -msgstr "Enregistrement réussi, un message de confirmation vous a été envoyé" +#: views/user.py:561 +msgid "" +"You've been registered, you will receive a confirmation mail once a " +"moderator has approved your membership." +msgstr "" +"Enregistrement réussi, vous recevrez un message de confirmation quand un " +"gestionnaire de l'espace de travail aura activé votre compte." -#~ msgid "You've been invited to join the workspace %(workspace_name)s." -#~ msgstr "" -#~ "Vous avez été invité à rejoindre l'espace de travail %(workspace_name)s." -#~ msgid "" -#~ "Click the following link to complete your registration and access the " -#~ "workspace:" -#~ msgstr "" -#~ "Cliquer le lien suivant pour terminer votre enregistrement et accéder à " -#~ "l'espace de travail :" -#~ msgid "" -#~ "If you'd like to unsubscribe from this notification, click the following " -#~ "link: %(SITE_URL)s%(desactivate_notification_url)s." -#~ msgstr "" -#~ "Si vous voulez vous désabonner de cette notification, cliquez sur le lien " -#~ "suivant : %(SITE_URL)s%(desactivate_notification_url)s." -#~ msgid "Contact from user: %(name)s / %(email)s" -#~ msgstr "Contact de l'utilisateur : %(name)s / %(email)s" -#~ msgid "Your text \"%(title)s\" has been created." -#~ msgstr "Votre texte \"%(title)s\" a été créé." -#~ msgid "To publish it click on the following link:" -#~ msgstr "Pour le publier, cliquez sur le lien suivant :" -#~ msgid "" -#~ "{nb_comments} comment(s) will be removed because the text they apply to " -#~ "has been changed. Do you want to continue?" -#~ msgstr "" -#~ "{nb_comments} commentaire(s) vont être supprimés parce que le texte a " -#~ "changé. Continuer ?" -#~ msgid "{nb_comments} comment(s) will be lost, do you want to continue?" -#~ msgstr "{nb_comments} commentaire(s) vont être perdus, continuer ?" -#~ msgid "We suggest you create a new version" -#~ msgstr "Nous vous suggérons de créer une nouvelle version" -#~ msgid "" -#~ "Since you chose not to create a new version all comments will be deleted, " -#~ "do you want to continue?" -#~ msgstr "" -#~ "Tous les commentaires vont être supprimés parce que vous avez choisi de " -#~ "ne pas créer une nouvelle version, continuer ?" -#~ msgid "Notifications" -#~ msgstr "Notifications" -#~ msgid "Authors:" -#~ msgstr "Auteurs :" -#~ msgid "authors" -#~ msgstr "auteurs" -#~ msgid "Actions:" -#~ msgstr "Actions :" -#~ msgid "%(title)s / version #%(version_number)s" -#~ msgstr "%(title)s / version n°%(version_number)s" -#~ msgid "created %(date)s" -#~ msgstr "créé le %(date)s" -#~ msgid "Preview text" -#~ msgstr "Prévisualiser le texte" -#~ msgid "Add user" -#~ msgstr "Ajouter un utilisateur" -#~ msgid "User added" -#~ msgstr "Utilisateur ajouté" -#~ msgid "All (x)" -#~ msgstr "Tous (x)" -#~ msgid "None (0)" -#~ msgstr "Aucun (0)" -#~ msgid "Currently filtered ones (n)" -#~ msgstr "Ceux actuellement filtrés (n)" -#~ msgid "Your name (will be used as text creator)" -#~ msgstr "Votre nom (sera utilisé comme créateur du texte)" -#~ msgid "Your email won't be public, you'll just receive notifications" -#~ msgstr "" -#~ "Votre email ne sera pas rendu public, vous recevrez seulement des " -#~ "notifications" -#~ msgid "You specified a file to upload. The content should be empty." -#~ msgstr "" -#~ "Vous avez fourni un fichier à charger sur le site. Le contenu du texte " -#~ "dans le formulaire doit donc être vide." -#~ msgid "You should specify a title for your text" -#~ msgstr "Le titre du texte est obligatoire." -#~ msgid "Add a new text" -#~ msgstr "Ajouter un nouveau texte" -#~ msgid "Preview/Edit text" -#~ msgstr "Prévisualiser/Editer le texte" -#~ msgid "Back" -#~ msgstr "Retour" -#~ msgid "Preview text again" -#~ msgstr "Prévisualiser le texte à nouveau" - -#, fuzzy -#~ msgid "Public activity feed for workspace %(workspace_name)s" -#~ msgstr "Flux d'activité de l'espace de travail %(workspace_name)s" - -#, fuzzy -#~ msgid "Private activity feed for workspace %(workspace_name)s" -#~ msgstr "Flux d'activité de l'espace de travail %(workspace_name)s" -#~ msgid "Notifications activated." -#~ msgstr "Notifications activées." -#~ msgid "Notifications desactivated." -#~ msgstr "Notifications désactivées." - -#, fuzzy -#~ msgid "%(wname)s Notification desactivation" -#~ msgstr "Notifications désactivées." -#~ msgid "Title:" -#~ msgstr "Titre :" -#~ msgid "Content:" -#~ msgstr "Texte :" -#~ msgid "Note:" -#~ msgstr "Note :" -#~ msgid "" -#~ "Are you sure you want to disable this user's access to the workspace?" -#~ msgstr "" -#~ "Etes vous sûr de vouloir désactiver l'accès de cet utilisateur à l'espace " -#~ "de travail ?" -#~ msgid "" -#~ "Are you sure you want to refuse this user\t's membership to the workspace?" -#~ msgstr "" -#~ "Etes vous sûr de vouloir refuser l'accès de cet utilisateur à l'espace de " -#~ "travail ?" - +#: views/user.py:564 +msgid "" +"You've been registered, please check your email for the confirm message." +msgstr "Enregistrement réussi, un message de confirmation vous a été envoyé" diff -r f2ba05546abc -r 36165e7cd1f0 src/cm/locale/fr/LC_MESSAGES/djangojs.po --- a/src/cm/locale/fr/LC_MESSAGES/djangojs.po Wed Jan 20 20:45:52 2010 +0100 +++ b/src/cm/locale/fr/LC_MESSAGES/djangojs.po Wed Jan 20 22:32:59 2010 +0100 @@ -3,13 +3,13 @@ # This file is distributed under the same license as the PACKAGE package. # # renaud bernard , 2009. -# renaud bernard , 2009. +# renaud bernard , 2009, 2010. msgid "" msgstr "" "Project-Id-Version: djangojs\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2010-01-15 09:45+0100\n" -"PO-Revision-Date: 2009-12-14 17:55+0100\n" +"POT-Creation-Date: 2010-01-20 21:53+0100\n" +"PO-Revision-Date: 2010-01-20 21:59+0100\n" "Last-Translator: renaud bernard \n" "Language-Team: \n" "MIME-Version: 1.0\n" @@ -55,12 +55,13 @@ msgstr "Le commentaire s'appliquera à cet extrait sélectionné dans le texte :" #: media/js/client/c_client-min.js:1 media/js/client/c_interface_forms.js:14 -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:395 +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:407 msgid "Save" msgstr "Sauver" #: media/js/client/c_client-min.js:1 media/js/client/c_interface_forms.js:14 #: media/js/client/f_client-min.js:1 media/js/client/f_printDialog.js:100 +#: media/js/site/text_edit.js:93 msgid "Cancel" msgstr "Annuler" @@ -75,7 +76,7 @@ #: media/js/client/c_dlg_intercept.js:48 media/js/client/c_dlg_intercept.js:50 #: media/js/client/c_dlg_intercept.js:52 media/js/client/c_sync.js:223 -#: media/js/site/text_edit.js:84 +#: media/js/site/text_edit.js:85 media/js/site/text_edit.js.py:98 msgid "Warning" msgstr "Avertissement" @@ -155,15 +156,24 @@ msgid "show scope" msgstr "afficher la portée" -#: media/js/client/c_icomment.js:274 +#: media/js/client/c_icomment.js:27 + +msgid "" +"Comment is detached: it was created on a previous version and text it " +"applied to has been modified or removed." +msgstr "" +"Ce commentaire est détaché : il a été créé sur une version précédente et le " +"texte auquel il s'appliquait a été modifié ou supprimé." + +#: media/js/client/c_icomment.js:295 msgid "last modified on %(date)s" msgstr "dernière modification le %(date)s" -#: media/js/client/c_icomment.js:277 +#: media/js/client/c_icomment.js:298 msgid "Permalink to this comment" msgstr "Lien permanent vers ce commentaire" -#: media/js/client/c_icomment.js:280 +#: media/js/client/c_icomment.js:301 msgid "by %(name)s, created on %(date)s" msgstr "par %(name)s, crée le %(date)s" @@ -181,15 +191,15 @@ #: media/js/client/c_sync.js:129 msgid "" -"Do you want to subscribe to all replies notifications in discussions you " +"Do you want to be notified of all replies in all discussions you " "participated in?" msgstr "" -"Voulez-vous vous abonner aux notifications portant sur les discussions " +"Voulez-vous vous abonner aux notifications portant sur toutes les discussions " "auxquelles vous avez participé ?" #: media/js/client/c_sync.js:129 -msgid "Follow up" -msgstr "Suivi" +msgid "Reply Notification" +msgstr "Notification des réponses" #: media/js/client/c_sync.js:201 media/js/client/c_sync.js.py:208 msgid "could not save comment" @@ -280,7 +290,7 @@ msgstr "Rechercher" #: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:85 -#: media/js/site/f_text_view_frame.js:395 +#: media/js/site/f_text_view_frame.js:407 msgid "Reset" msgstr "Réinitialiser" @@ -324,101 +334,107 @@ msgid "view all comments" msgstr "voir tous les commentaires" -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:182 -msgid "toggle advance interface" -msgstr "voir/cacher l'interface avancée" - -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:183 +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:184 msgid "print document with/without comments" msgstr "imprimer le document (avec ou sans les commentaires)" -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:184 +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:185 msgid "export document with/without comments" msgstr "exporter le document (avec ou sans les commentaires)" -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:187 +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:186 +msgid "toggle full screen view" +msgstr "passer en mode plein écran" + +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:188 msgid "add a comment" msgstr "ajouter un commentaire" -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:203 +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:204 msgid "filter:" msgstr "filtre :" -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:208 +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:209 msgid "browse by:" msgstr "parcourir par :" -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:210 +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:211 msgid "location" msgstr "emplacement" -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:211 +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:212 msgid "modification" msgstr "modification" -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:354 +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:332 +msgid "thread discussions" +msgstr "" +"décaler les réponses aux commentaires pour mettre en évidence le fil de la " +"discussion" + +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:366 msgid "Text style" msgstr "Style du texte" -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:399 +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:411 msgid "Animation duration" msgstr "Durée des animations" -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:408 +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:420 msgid "(0.001 to 1 second)" msgstr "(0.001 à 1 seconde)" -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:434 +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:446 msgid "preferences reset (will apply on next load)" msgstr "préférences réinitialisées (s'appliqueront au prochain chargement)" -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:440 +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:452 msgid "preferences saved (will apply on next load)" msgstr "préférences sauvées (s'appliqueront au prochain chargement)" -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:544 +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:556 msgid "filter reset" msgstr "filtre réinitialisé" -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:554 +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:566 msgid "filter applied" msgstr "filtre activé" -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:560 +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:572 msgid "discussion" msgid_plural "discussions" msgstr[0] "discussion" msgstr[1] "discussions" -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:564 +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:576 msgid "comment" msgid_plural "comments" msgstr[0] "commentaire" msgstr[1] "commentaires" -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:567 +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:579 msgid " reply" msgid_plural " replies" msgstr[0] " réponse" msgstr[1] " réponses" -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:589 +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:601 msgid "all" msgstr "tous" -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:607 +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:619 msgid "last 24 hours (%(nb_comments)s)" msgid_plural "last %(nb_days)s days (%(nb_comments)s)" msgstr[0] "dernières 24 heures (%(nb_comments)s)" msgstr[1] "derniers %(nb_days)s jours (%(nb_comments)s)" -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:721 -#: media/js/site/text_edit.js:78 +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:733 +#: media/js/site/text_edit.js:79 msgid "No" msgstr "Non" -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:722 -#: media/js/site/text_edit.js:79 +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:734 +#: media/js/site/text_edit.js:80 msgid "Yes" msgstr "Oui" @@ -523,66 +539,55 @@ msgid "code" msgstr "code" -#: media/js/site/f_text_view_frame.js:185 -msgid "toggle full screen view" -msgstr "passer en mode plein écran" +#: media/js/site/f_text_view_frame.js:182 +msgid "view all detached comments" +msgstr "voir tous les commentaires détachés" -#: media/js/site/f_text_view_frame.js:186 +#: media/js/site/f_text_view_frame.js:183 +msgid "toggle advance interface" +msgstr "voir/cacher l'interface avancée" + +#: media/js/site/f_text_view_frame.js:187 msgid "text feed" msgstr "fil du texte" -#: media/js/site/f_text_view_frame.js:317 +#: media/js/site/f_text_view_frame.js:329 msgid "unthread discussions" msgstr "" "aligner les réponses aux commentaires sur la gauche pour rendre possible la " "lecture du texte" -#: media/js/site/f_text_view_frame.js:320 -msgid "thread discussions" -msgstr "" -"décaler les réponses aux commentaires pour mettre en évidence le fil de la " -"discussion" - -#: media/js/site/text_edit.js:26 +#: media/js/site/text_edit.js:9 msgid "" -"%(nb_comments)s comment will be removed because the text it applies to has " -"been changed." -msgid_plural "" -"%(nb_comments)s comments will be removed because the text they apply to has " -"been changed." -msgstr[0] "" -"%(nb_comments)s commentaire sera supprimé parce que le texte auquel il " -"s'applique a été modifié." -msgstr[1] "" -"%(nb_comments)s commentaires seront supprimés parce que le texte auquel ils " -"s'appliquent a été modifié." +"Should these comments be detached (i.e. kept with no scope) or removed from " +"new version?" +msgstr "Ces commentaires doivent ils être détachés (i.e. conservés sans portée) ou supprimés de la nouvelle version ?" + +#: media/js/site/text_edit.js:27 media/js/site/text_edit.js.py:44 +msgid "%(nb_comments)s comment applies to text that was modified." +msgid_plural "%(nb_comments)s comments apply to text that was modified." +msgstr[0] "%(nb_comments)s commentaire s'applique à du texte qui a été modifié." +msgstr[1] "%(nb_comments)s commentaires s'appliquent à du texte qui a été modifié." -#: media/js/site/text_edit.js:30 media/js/site/text_edit.js.py:49 -#: media/js/site/text_edit.js:66 +#: media/js/site/text_edit.js:48 +msgid "(We suggest you create a new version)" +msgstr "(Nous vous suggérons de créer une nouvelle version)" + +#: media/js/site/text_edit.js:65 +msgid "You chose not to create a new version all comments will be deleted" +msgstr "" +"Comme vous avez choisi de ne pas créer de nouvelle version, tous les " +"commentaires seront supprimés" + +#: media/js/site/text_edit.js:67 msgid "Do you want to continue?" msgstr "Voulez vous continuer ?" -#: media/js/site/text_edit.js:43 -msgid "" -"%(nb_comments)s comment will be lost because the text it applies to has been " -"changed." -msgid_plural "" -"%(nb_comments)s comments will be lost because the text they apply to has " -"been changed." -msgstr[0] "" -"%(nb_comments)s commentaire sera supprimé parce que le texte auquel il " -"s'applique a été modifié." -msgstr[1] "" -"%(nb_comments)s commentaires seront supprimés parce que le texte auquel ils " -"s'appliquent a été modifié." +#: media/js/site/text_edit.js:91 +msgid "Detach" +msgstr "Détacher" -#: media/js/site/text_edit.js:47 -msgid "(We suggest you create a new version)" -msgstr "(Nous vous suggérons de créer une nouvelle version)" +#: media/js/site/text_edit.js:92 +msgid "Remove" +msgstr "Supprimer" -#: media/js/site/text_edit.js:64 -msgid "" -"Since you chose not to create a new version all comments will be deleted" -msgstr "" -"Comme vous avez choisi de ne pas créer de nouvelle version, tous les " -"commentaires seront perdus" diff -r f2ba05546abc -r 36165e7cd1f0 src/cm/locale/no/LC_MESSAGES/django.po --- a/src/cm/locale/no/LC_MESSAGES/django.po Wed Jan 20 20:45:52 2010 +0100 +++ b/src/cm/locale/no/LC_MESSAGES/django.po Wed Jan 20 22:32:59 2010 +0100 @@ -7,7 +7,7 @@ msgstr "" "Project-Id-Version: COMT\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2010-01-16 17:56+0100\n" +"POT-Creation-Date: 2010-01-20 22:02+0100\n" "PO-Revision-Date: 2010-01-16 18:00+0100\n" "Last-Translator: Kirill Miazine \n" "Language-Team: \n" @@ -21,8 +21,8 @@ msgid "" "A selection is required. Select in the text the part your comment applies to." msgstr "" -"Et område i teksten må merkes. Merk et område i teksten som din merknad " -"skal gjelde" +"Et område i teksten må merkes. Merk et område i teksten som din merknad skal " +"gjelde" #: client.py:133 msgid "name is required" @@ -64,7 +64,7 @@ msgid "unknown" msgstr "ukjent" -#: models.py:175 views/create.py:30 views/create.py:45 views/texts.py:613 +#: models.py:175 views/create.py:30 views/create.py:45 views/texts.py:611 msgid "Title" msgstr "Overskrift" @@ -76,7 +76,7 @@ msgid "Content" msgstr "Innhold" -#: models.py:178 models.py:579 +#: models.py:178 models.py:594 msgid "Tags" msgstr "Etiketter" @@ -88,121 +88,121 @@ msgid "Moderation a posteriori?" msgstr "Godkjenning i ettertid?" -#: models.py:274 +#: models.py:280 msgid "Format:" msgstr "Format:" -#: models.py:341 +#: models.py:356 #, python-format msgid "%(workspace_name)s's workspace" msgstr "Arbeidsområde til %(workspace_name)s" -#: models.py:482 +#: models.py:497 msgid "name" msgstr "navn" -#: models.py:483 +#: models.py:498 msgid "description" msgstr "beskrivelse" -#: models.py:573 +#: models.py:588 msgid "Allow contact" msgstr "Tillatt kontakt" -#: models.py:573 +#: models.py:588 msgid "Allow email messages from other users" msgstr "Motta epost fra andre brukere" -#: models.py:574 +#: models.py:589 msgid "Preferred language" msgstr "Foretrukket språk" -#: models.py:577 +#: models.py:592 msgid "Suspended access" msgstr "Sperret tilgang" -#: models.py:601 +#: models.py:616 msgid "suspended" msgstr "sperret" -#: models.py:603 +#: models.py:618 msgid "waiting approval" msgstr "venter på godkjenning" -#: models.py:609 +#: models.py:624 msgid "pending" msgstr "pågående" -#: models.py:624 +#: models.py:639 msgid "Invitation" msgstr "Invitasjon" -#: models.py:692 +#: models.py:707 #, python-format msgid "Text %(link_to_text)s edited" msgstr "Tekst %(link_to_text)s endret" -#: models.py:693 +#: models.py:708 #, python-format msgid "Text %(link_to_text)s edited (new version created)" msgstr "Tekst %(link_to_text)s endret (ny versjon opprettet)" -#: models.py:694 +#: models.py:709 #, python-format msgid "Text %(link_to_text)s added" msgstr "Tekst %(link_to_text)s lagt til" -#: models.py:695 +#: models.py:710 #, python-format msgid "Text %(link_to_text)s removed" msgstr "Tekst %(link_to_text)s slettet" -#: models.py:696 +#: models.py:711 #, python-format msgid "Comment %(link_to_comment)s added on text %(link_to_text)s" msgstr "Merknad %(link_to_comment)s lagt til teksten %(link_to_text)s" -#: models.py:697 +#: models.py:712 #, python-format msgid "Comment %(link_to_comment)s removed from text %(link_to_text)s" msgstr "Merknad %(link_to_comment)s slettet fra teksten %(link_to_text)s" -#: models.py:698 +#: models.py:713 #, python-format msgid "User %(username)s added" msgstr "Bruker %(username)s opprettet" -#: models.py:699 +#: models.py:714 #, python-format msgid "User %(username)s access to workspace enabled" msgstr "Aktivert tilgang for brukeren %(username)s" -#: models.py:700 +#: models.py:715 #, python-format msgid "User %(username)s access to workspace refused" msgstr "Nektet tilgang for brukeren %(username)s" -#: models.py:701 +#: models.py:716 #, python-format msgid "User %(username)s access to workspace suspended" msgstr "Stoppet tilgang for brukeren %(username)s" -#: models.py:702 +#: models.py:717 #, python-format msgid "User %(username)s access to workspace activated" msgstr "Aktivert tilgang for brukeren %(username)s" -#: models.py:703 +#: models.py:718 #, python-format msgid "User %(username)s has activated his account" msgstr "Bruker %(username)s har aktivert kontoen" -#: models.py:758 models.py:766 +#: models.py:773 models.py:781 #, python-format msgid "by \"%(username)s\"" msgstr "av %(username)s" -#: models.py:760 +#: models.py:775 #, python-format msgid "%(time_since)s ago" msgstr "for %(time_since)s siden" @@ -613,8 +613,8 @@ "others unless you want them to see all activities on the workspace." msgstr "" "Dette er den private strømmen for arbeidsområdet. Ikke del adressen for " -"denne strømmen med andre, men mindre du ønsker at de skal kunne se alt " -"som skjer på arbeidsområdet." +"denne strømmen med andre, men mindre du ønsker at de skal kunne se alt som " +"skjer på arbeidsområdet." #: templates/site/followup.html:45 templates/site/text_followup.html:47 msgid "Reset private feed url" @@ -688,7 +688,7 @@ msgstr "Din profil (%(username)s)" #: templates/site/profile.html:26 templates/site/text_create_content.html:45 -#: templates/site/text_create_upload.html:40 templates/site/text_edit.html:34 +#: templates/site/text_create_upload.html:40 templates/site/text_edit.html:36 #: templates/site/text_settings.html:23 templates/site/text_share.html:153 #: templates/site/user_activate.html:27 templates/site/user_list.html:210 #: templates/site/layout/base_workspace_form.html:32 @@ -733,8 +733,8 @@ "be able to add comments from your site depending an anonymous users' roles." msgstr "" "Kopier denne koden til din side for å vise teksten med merknader. Avhengig " -"av rettighetene til anonyme brukere, vil andre muligens også kunne kommentere " -"teksten direkte fra din side." +"av rettighetene til anonyme brukere, vil andre muligens også kunne " +"kommentere teksten direkte fra din side." #: templates/site/text_embed.html:33 msgid "Warning:" @@ -954,9 +954,10 @@ msgstr "Bruker" #: templates/site/text_share.html:87 +#, fuzzy msgid "" "The 'Workspace role' is the global role that applies to every text, you can " -"give a user a particular role on this text using the 'local role' column on " +"give a user a particular role on this text using the 'text role' column on " "the right" msgstr "" "Rollen 'Rolle for arbeidsområde' er en global rolle, som vil anvendes på " @@ -968,12 +969,13 @@ msgstr "Rolle for arbeidsområde" #: templates/site/text_share.html:88 -msgid "Local role" +#, fuzzy +msgid "Text role" msgstr "Tekstrolle" #: templates/site/text_share.html:101 -#, python-format -msgid "This role has been overriden on this text by a local role: %(rolename)s" +#, fuzzy, python-format +msgid "This role has been overriden on this text by a text role: %(rolename)s" msgstr "Denne rollen viker for en lokal rolle for teksten: %(rolename)s" #: templates/site/text_share.html:128 templates/site/user_edit.html:6 @@ -1215,7 +1217,7 @@ msgid "The title of your text" msgstr "Overskriften for din tekst" -#: views/create.py:71 views/create.py:108 +#: views/create.py:70 views/create.py:107 #, python-format msgid "Text \"%(text_title)s\" has been created" msgstr "Teksten %(text_title)s har blitt opprettet" @@ -1365,32 +1367,32 @@ msgid "%(nb_texts)i text(s) deleted" msgstr "%(nb_texts)i tekst(er) slettet" -#: views/texts.py:211 +#: views/texts.py:210 #, python-format msgid "Text %(text_title)s deleted" msgstr "Tekstet %(text_title)s slettet" -#: views/texts.py:617 +#: views/texts.py:615 msgid "Note (optional)" msgstr "Kommentar (valgfritt)" -#: views/texts.py:620 +#: views/texts.py:618 msgid "Add a note to explain the modifications made to the text" msgstr "Legg til en kommentar for å beskrive foretatte endringer i teksten" -#: views/texts.py:630 +#: views/texts.py:628 msgid "New version (optional)" msgstr "Ny versjon (valgfritt)" -#: views/texts.py:633 +#: views/texts.py:631 msgid "Create a new version of this text (recommended)" msgstr "Opprett ny versjon av teksten (anbefales)" -#: views/texts.py:636 +#: views/texts.py:634 msgid "Keep comments (optional)" msgstr "Behold merknader (valgfritt)" -#: views/texts.py:639 +#: views/texts.py:637 msgid "Keep comments (if not affected by the edit)" msgstr "Behold merknadene (dersom de ikke er påvirket av endringene i teksten)" @@ -1573,3 +1575,6 @@ msgid "" "You've been registered, please check your email for the confirm message." msgstr "Du er blitt registert. Se din epost for en melding med bekreftelsen." + +#~ msgid "Local role" +#~ msgstr "Tekstrolle" diff -r f2ba05546abc -r 36165e7cd1f0 src/cm/locale/no/LC_MESSAGES/djangojs.po --- a/src/cm/locale/no/LC_MESSAGES/djangojs.po Wed Jan 20 20:45:52 2010 +0100 +++ b/src/cm/locale/no/LC_MESSAGES/djangojs.po Wed Jan 20 22:32:59 2010 +0100 @@ -7,7 +7,7 @@ msgstr "" "Project-Id-Version: COMT\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2010-01-16 17:57+0100\n" +"POT-Creation-Date: 2010-01-20 21:53+0100\n" "PO-Revision-Date: 2010-01-16 18:00+0100\n" "Last-Translator: Kirill Miazine \n" "Language-Team: \n" @@ -54,12 +54,13 @@ msgstr "Merknaden vil gjelde følgende tekstområde:" #: media/js/client/c_client-min.js:1 media/js/client/c_interface_forms.js:14 -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:395 +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:407 msgid "Save" msgstr "Lagre" #: media/js/client/c_client-min.js:1 media/js/client/c_interface_forms.js:14 #: media/js/client/f_client-min.js:1 media/js/client/f_printDialog.js:100 +#: media/js/site/text_edit.js:93 msgid "Cancel" msgstr "Avbryt" @@ -74,7 +75,7 @@ #: media/js/client/c_dlg_intercept.js:48 media/js/client/c_dlg_intercept.js:50 #: media/js/client/c_dlg_intercept.js:52 media/js/client/c_sync.js:223 -#: media/js/site/text_edit.js:84 +#: media/js/site/text_edit.js:85 media/js/site/text_edit.js.py:98 msgid "Warning" msgstr "Advarsel" @@ -154,15 +155,21 @@ msgid "show scope" msgstr "vis rekkevidde" -#: media/js/client/c_icomment.js:274 +#: media/js/client/c_icomment.js:27 +msgid "" +"Comment is detached: it was created on a previous version and text it " +"applied to has been modified or removed." +msgstr "" + +#: media/js/client/c_icomment.js:295 msgid "last modified on %(date)s" msgstr "sist endret %(date)s" -#: media/js/client/c_icomment.js:277 +#: media/js/client/c_icomment.js:298 msgid "Permalink to this comment" msgstr "Fast adresse til denne merknaden" -#: media/js/client/c_icomment.js:280 +#: media/js/client/c_icomment.js:301 msgid "by %(name)s, created on %(date)s" msgstr "av %(name)s, opprettet %(date)s" @@ -179,16 +186,18 @@ msgstr "ingen filtrerte merknader igjen" #: media/js/client/c_sync.js:129 +#, fuzzy msgid "" -"Do you want to subscribe to all replies notifications in discussions you " +"Do you want to be notified of all replies in all discussions you " "participated in?" msgstr "" "Ønsker du å abonnere på varsler for alle svar i diskusjoner hvor du har " "deltatt?" #: media/js/client/c_sync.js:129 -msgid "Follow up" -msgstr "Følg opp" +#, fuzzy +msgid "Reply Notification" +msgstr "endring" #: media/js/client/c_sync.js:201 media/js/client/c_sync.js.py:208 msgid "could not save comment" @@ -202,7 +211,7 @@ msgid "could not remove comment" msgstr "kunne ikke slette merknad" -#: media/js/client/f_client-min.js:1 +#: media/js/client/f_client-min.js:1 media/js/client/f_message.js:17 msgid "loading..." msgstr "laster..." @@ -279,7 +288,7 @@ msgstr "Søk" #: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:85 -#: media/js/site/f_text_view_frame.js:395 +#: media/js/site/f_text_view_frame.js:407 msgid "Reset" msgstr "Nullstill" @@ -323,101 +332,105 @@ msgid "view all comments" msgstr "se alle merknader" -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:182 -msgid "toggle advance interface" -msgstr "slå på/av avansert grensesnitt" - -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:183 +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:184 msgid "print document with/without comments" msgstr "skriv ut dokument med/uten merknader" -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:184 +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:185 msgid "export document with/without comments" msgstr "eksporter dokument med/uten merknader" -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:187 +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:186 +msgid "toggle full screen view" +msgstr "slå på/av visning på full side" + +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:188 msgid "add a comment" msgstr "opprett merknad" -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:203 +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:204 msgid "filter:" msgstr "filter:" -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:208 +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:209 msgid "browse by:" msgstr "navigasjon etter:" -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:210 +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:211 msgid "location" msgstr "plassering" -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:211 +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:212 msgid "modification" msgstr "endring" -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:354 +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:332 +msgid "thread discussions" +msgstr "vis diskusjonstråder" + +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:366 msgid "Text style" msgstr "Stil" -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:399 +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:411 msgid "Animation duration" msgstr "Varighet for animasjon" -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:408 +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:420 msgid "(0.001 to 1 second)" msgstr "(fra 0.001 til 1 sekund)" -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:434 +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:446 msgid "preferences reset (will apply on next load)" msgstr "innstillinger nullstilt (aktiveres ved neste innlasting)" -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:440 +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:452 msgid "preferences saved (will apply on next load)" msgstr "innstillinger lagret (aktiveres ved neste innlasting)" -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:544 +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:556 msgid "filter reset" msgstr "filter nullstilt" -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:554 +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:566 msgid "filter applied" msgstr "filtrert" -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:560 +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:572 msgid "discussion" msgid_plural "discussions" msgstr[0] "diskusjon" msgstr[1] "diskusjoner" -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:564 +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:576 msgid "comment" msgid_plural "comments" msgstr[0] "merknad" msgstr[1] "merknader" -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:567 +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:579 msgid " reply" msgid_plural " replies" msgstr[0] " svar" msgstr[1] " svar" -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:589 +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:601 msgid "all" msgstr "alle" -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:607 +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:619 msgid "last 24 hours (%(nb_comments)s)" msgid_plural "last %(nb_days)s days (%(nb_comments)s)" msgstr[0] "siste 24 timer (%(nb_comments)s)" msgstr[1] "siste %(nb_days)s dager (%(nb_comments)s)" -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:721 -#: media/js/site/text_edit.js:78 +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:733 +#: media/js/site/text_edit.js:79 msgid "No" msgstr "Nei" -#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:722 -#: media/js/site/text_edit.js:79 +#: media/js/client/f_client-min.js:1 media/js/site/f_text_view_frame.js:734 +#: media/js/site/text_edit.js:80 msgid "Yes" msgstr "Ja" @@ -522,61 +535,75 @@ msgid "code" msgstr "kode" -#: media/js/site/f_text_view_frame.js:185 -msgid "toggle full screen view" -msgstr "slå på/av visning på full side" +#: media/js/site/f_text_view_frame.js:182 +#, fuzzy +msgid "view all detached comments" +msgstr "se alle merknader" -#: media/js/site/f_text_view_frame.js:186 +#: media/js/site/f_text_view_frame.js:183 +msgid "toggle advance interface" +msgstr "slå på/av avansert grensesnitt" + +#: media/js/site/f_text_view_frame.js:187 msgid "text feed" msgstr "textstrøm" -#: media/js/site/f_text_view_frame.js:317 +#: media/js/site/f_text_view_frame.js:329 msgid "unthread discussions" msgstr "skjul diskusjonstråder" -#: media/js/site/f_text_view_frame.js:320 -msgid "thread discussions" -msgstr "vis diskusjonstråder" - -#: media/js/site/text_edit.js:26 +#: media/js/site/text_edit.js:9 msgid "" -"%(nb_comments)s comment will be removed because the text it applies to has " -"been changed." -msgid_plural "" -"%(nb_comments)s comments will be removed because the text they apply to has " -"been changed." +"Should these comments be detached (i.e. kept with no scope) or removed from " +"new version?" +msgstr "" + +#: media/js/site/text_edit.js:27 media/js/site/text_edit.js.py:44 +#, fuzzy +msgid "%(nb_comments)s comment applies to text that was modified." +msgid_plural "%(nb_comments)s comments apply to text that was modified." msgstr[0] "" -"%(nb_comments)s merknad vil bli slettet, fordi teksten som den er knyttet til " +"%(nb_comments)s merknad vil bli tapt, fordi teksten som den er knyttet til " "har blitt endret." msgstr[1] "" -"%(nb_comments)s merknader vil bli slettet, fordi teksten som de er knyttet til " +"%(nb_comments)s merknader vil bli tapt, fordi teksten som de er knyttet til " "har blitt endret." -#: media/js/site/text_edit.js:30 media/js/site/text_edit.js.py:49 -#: media/js/site/text_edit.js:66 +#: media/js/site/text_edit.js:48 +msgid "(We suggest you create a new version)" +msgstr "(Vi anbefaler at du oppretter en ny versjon)" + +#: media/js/site/text_edit.js:65 +#, fuzzy +msgid "You chose not to create a new version all comments will be deleted" +msgstr "" +"Siden du ikke ønsket å opprette en ny versjon, vil alle merknader bli slettet" + +#: media/js/site/text_edit.js:67 msgid "Do you want to continue?" msgstr "Ønsker du å fortsette?" -#: media/js/site/text_edit.js:43 -msgid "" -"%(nb_comments)s comment will be lost because the text it applies to has been " -"changed." -msgid_plural "" -"%(nb_comments)s comments will be lost because the text they apply to has " -"been changed." -msgstr[0] "" -"%(nb_comments)s merknad vil bli tapt, fordi teksten som den er knyttet til har " -"blitt endret." -msgstr[1] "" -"%(nb_comments)s merknader vil bli tapt, fordi teksten som de er knyttet til har " -"blitt endret." +#: media/js/site/text_edit.js:91 +#, fuzzy +msgid "Detach" +msgstr "Søk" + +#: media/js/site/text_edit.js:92 +msgid "Remove" +msgstr "" + +#~ msgid "Follow up" +#~ msgstr "Følg opp" -#: media/js/site/text_edit.js:47 -msgid "(We suggest you create a new version)" -msgstr "(Vi anbefaler at du oppretter en ny versjon)" - -#: media/js/site/text_edit.js:64 -msgid "" -"Since you chose not to create a new version all comments will be deleted" -msgstr "" -"Siden du ikke ønsket å opprette en ny versjon, vil alle merknader bli slettet" +#~ msgid "" +#~ "%(nb_comments)s comment will be removed because the text it applies to " +#~ "has been changed." +#~ msgid_plural "" +#~ "%(nb_comments)s comments will be removed because the text they apply to " +#~ "has been changed." +#~ msgstr[0] "" +#~ "%(nb_comments)s merknad vil bli slettet, fordi teksten som den er knyttet " +#~ "til har blitt endret." +#~ msgstr[1] "" +#~ "%(nb_comments)s merknader vil bli slettet, fordi teksten som de er " +#~ "knyttet til har blitt endret." diff -r f2ba05546abc -r 36165e7cd1f0 src/cm/media/js/client/c_client-min.js --- a/src/cm/media/js/client/c_client-min.js Wed Jan 20 20:45:52 2010 +0100 +++ b/src/cm/media/js/client/c_client-min.js Wed Jan 20 22:32:59 2010 +0100 @@ -1,1 +1,1 @@ -gNewReplyHost=null;gNewReply=null;instanciateNewReplyForm=function(i){if(gNewReply==null){gNewReply={val:{name:gPrefs.get("user","name"),email:gPrefs.get("user","email"),title:"",content:"",tags:""},ids:{name:gPrefs.get("user","name"),email:gPrefs.get("user","email"),title:"",content:"",tags:"",formId:CY.guid(),nameInputId:CY.guid(),emailInputId:CY.guid(),titleInputId:CY.guid(),contentInputId:CY.guid(),keyInputId:CY.guid(),formatInputId:CY.guid(),tagsInputId:CY.guid(),parentCommentId:CY.guid(),addBtnId:CY.guid(),cancelBtnId:CY.guid()},handlers:{}};}gNewReplyHost=i;var b='
'+gettext("New reply")+"
";var e=gFormHtml.formStart.replace("###",gNewReply.ids["formId"]);if(!sv_loggedIn){e=e+gFormHtml.nameInput.replace("###",gNewReply.ids["nameInputId"])+gFormHtml.emailInput.replace("###",gNewReply.ids["emailInputId"]);}e=e+gFormHtml.titleInput.replace("###",gNewReply.ids["titleInputId"])+gFormHtml.contentInput.replace("###",gNewReply.ids["contentInputId"])+gFormHtml.tagsInput.replace("###",gNewReply.ids["tagsInputId"]);e=e+gFormHtml.hidden.replace("###",gNewReply.ids["keyInputId"]).replace("???","comment_key");e=e+gFormHtml.hidden.replace("###",gNewReply.ids["formatInputId"]).replace("???","format");e=e+gFormHtml.hidden.replace("###",gNewReply.ids["parentCommentId"]).replace("???","reply_to_id");var h=gFormHtml.btns.replace("###",gNewReply.ids["addBtnId"]).replace("???",gNewReply.ids["cancelBtnId"]);gNewReplyHost.overlay.setStdModContent(CY.WidgetStdMod.FOOTER,b+e+h);var c=gNewReplyHost.overlay.getStdModNode(CY.WidgetStdMod.FOOTER);var f=gDb.getComment(i.commentId);var a="Re: ";var g=(gNewReply.val["title"]==""||gNewReply.val["title"].substring(0,a.length)==a)?a+f.title:gNewReply.val["title"];if(!sv_loggedIn){c.query(".n_name").set("value",gNewReply.val["name"]);c.query(".n_email").set("value",gNewReply.val["email"]);}c.query(".n_title").set("value",g);c.query(".n_content").set("value",gNewReply.val["content"]);c.query(".n_tags").set("value",gNewReply.val["tags"]);c.query("#"+gNewReply.ids["parentCommentId"]).set("value",i.commentId);c.query("#"+gNewReply.ids["formatInputId"]).set("value",gConf.defaultCommentFormat);gNewReplyHost.overlay.get("contentBox").query(".c-reply").addClass("displaynone");gNewReply.handlers["addBtnId"]=CY.on("click",onAddNewReplyClick,"#"+gNewReply.ids["addBtnId"]);gNewReply.handlers["cancelBtnId"]=CY.on("click",onCancelNewReplyClick,"#"+gNewReply.ids["cancelBtnId"]);var d=gLayout.getTopICommentsWidth();changeFormFieldsWidth(gNewReply.ids["formId"],d);};cleanNewReplyForm=function(){if(gNewReplyHost!=null){var a=gNewReplyHost.overlay.getStdModNode(CY.WidgetStdMod.FOOTER);a.queryAll(".comment_input").set("value","");}};cancelNewReplyForm=function(){if(gNewReplyHost!=null){for(var b in gNewReply.handlers){if(gNewReply.handlers[b]!=null){gNewReply.handlers[b].detach();gNewReply.handlers[b]=null;}}gNewReplyHost.overlay.get("contentBox").query(".c-reply").removeClass("displaynone");var a=gNewReplyHost.overlay.getStdModNode(CY.WidgetStdMod.FOOTER);if(!sv_loggedIn){gNewReply.val["name"]=a.query(".n_name").get("value");gNewReply.val["email"]=a.query(".n_email").get("value");}gNewReply.val["title"]=a.query(".n_title").get("value");gNewReply.val["content"]=a.query(".n_content").get("value");gNewReply.val["tags"]=a.query(".n_tags").get("value");a.set("innerHTML","");gNewReplyHost=null;}};onAddNewReplyClick=function(){if(!sv_loggedIn){var b=CY.get("#"+gNewReply.ids["nameInputId"]).get("value");gPrefs.persist("user","name",b);var a=CY.get("#"+gNewReply.ids["emailInputId"]).get("value");gPrefs.persist("user","email",a);}gSync.saveComment(gNewReply.ids["formId"]);};onCancelNewReplyClick=function(){gSync.cancelReply();};getWrapperAncestor=function(a){var b=a;while(b!=null){if(CY.DOM.hasClass(b,"c-s")){return b;}b=b.parentNode;}return null;};hasWrapperAncestor=function(a){return(getWrapperAncestor(a)!=null);};getSelectionInfo=function(){var J=null,m=null,D=0,c=0,h="";if(window.getSelection){var r=window.getSelection();if(r.rangeCount>0){var l=r.getRangeAt(0);h=l.toString();if(h!=""){var E=document.createRange();E.setStart(r.anchorNode,r.anchorOffset);E.collapse(true);var B=document.createRange();B.setEnd(r.focusNode,r.focusOffset);B.collapse(false);var I=(B.compareBoundaryPoints(2,E)==1);J=(I)?r.anchorNode.parentNode:r.focusNode.parentNode;innerStartNode=(I)?r.anchorNode:r.focusNode;m=(I)?r.focusNode.parentNode:r.anchorNode.parentNode;innerEndNode=(I)?r.focusNode:r.anchorNode;D=(I)?r.anchorOffset:r.focusOffset;c=(I)?r.focusOffset:r.anchorOffset;if(!hasWrapperAncestor(m)&&hasWrapperAncestor(J)){var z=document.createRange();z.setStart(innerStartNode,D);var b=getWrapperAncestor(J);var q=b;z.setEndAfter(q);var f=parseInt(b.id.substring("sv_".length));while(z.toString().lengthv.compareBoundaryPoints(2,l))){J=k.firstChild;D=0;m=F.lastChild;c=CY.DOM.getText(F).length;w=true;break;}}if(w){break;}}}}}E.detach();B.detach();}else{return null;}}else{return null;}}else{if(document.selection){var d=document.selection.createRange();if(d.text.length==0){return null;}var a=d.parentElement();var H=d.duplicate();var u=d.duplicate();H.collapse(true);u.collapse(false);J=H.parentElement();while(H.moveStart("character",-1)!=0){if(H.parentElement()!=J){break;}D++;}m=u.parentElement();while(u.moveEnd("character",-1)!=0){if(u.parentElement()!=m){break;}c++;}h=d.text;}}if(!hasWrapperAncestor(J)||!hasWrapperAncestor(m)){return null;}return{text:h,start:{elt:J,offset:D},end:{elt:m,offset:c}};};gNoSelectionYet=gettext("No selection yet");gFormHtml={formStart:'
',nameInput:gettext("Username:")+'
',emailInput:gettext("E-mail address:")+'
',titleInput:gettext("Title:")+'
',contentInput:gettext("Content:")+'
',tagsInput:gettext("Tag:")+'
',hidden:'',formEnd:"
",changeScope:'
'+gettext("Modify comment's scope:")+'
',headerTitle:'
',currentSel:'
'+gettext("Comment will apply to this selection:")+'
'+gNoSelectionYet+"
#hiddeninput#
",btns:'
',closeIcon:'      '};getHtml=function(f){ret={};ret.headerContent="";if("closeBtnId" in f){ret.headerContent+=gFormHtml.closeIcon.replace("###",f.closeBtnId);}ret.headerContent+=gFormHtml.headerTitle.replace("###",f.formTitleId);var b="";if("changeScopeInputId" in f){b=gFormHtml.changeScope.replace("###",f.changeScopeInputId);}var e="
"+gFormHtml.hidden.replace("###",f.selectionPlaceId).replace("???","selection_place")+"
";var a=gFormHtml.currentSel.replace("###",f.currentSelId).replace("???",f.currentSelIdI).replace("#hiddeninput#",e);var d=gFormHtml.btns.replace("###",f.addBtnId).replace("???",f.cancelBtnId);var c=gFormHtml.formStart.replace("###",f.formId)+b+a;if("nameInputId" in f){c=c+gFormHtml.nameInput.replace("###",f.nameInputId);}if("emailInputId" in f){c=c+gFormHtml.emailInput.replace("###",f.emailInputId);}c=c+gFormHtml.titleInput.replace("###",f.titleInputId)+gFormHtml.contentInput.replace("###",f.contentInputId)+gFormHtml.tagsInput.replace("###",f.tagsInputId);c=c+gFormHtml.hidden.replace("###",f.formatInputId).replace("???","format");c=c+gFormHtml.hidden.replace("###",f.startWrapperInputId).replace("???","start_wrapper");c=c+gFormHtml.hidden.replace("###",f.endWrapperInputId).replace("???","end_wrapper");c=c+gFormHtml.hidden.replace("###",f.startOffsetInputId).replace("???","start_offset");c=c+gFormHtml.hidden.replace("###",f.endOffsetInputId).replace("???","end_offset");c=c+gFormHtml.hidden.replace("###",f.keyId).replace("???","comment_key");c=c+gFormHtml.hidden.replace("###",f.editCommentId).replace("???","edit_comment_id");c=c+d+gFormHtml.formEnd;ret.bodyContent=c;return ret;};changeFormFieldsWidth=function(d,c){var a=(c-20)+"px";var b=CY.all("#"+d+" input[type='text']");if(b!=null){b.setStyle("width",a);}b=CY.all("#"+d+" textarea");if(b!=null){b.setStyle("width",a);}};addFormErrMsg=function(j,g,d){var f=document.getElementById(j);var b,h,c,a;for(b=0,a=f.elements.length;b";var n=gFormHtml.formStart.replace("###",gNewReply.ids.formId);if(!sv_loggedIn){n=n+gFormHtml.nameInput.replace("###",gNewReply.ids.nameInputId)+gFormHtml.emailInput.replace("###",gNewReply.ids.emailInputId);}n=n+gFormHtml.titleInput.replace("###",gNewReply.ids.titleInputId)+gFormHtml.contentInput.replace("###",gNewReply.ids.contentInputId)+gFormHtml.tagsInput.replace("###",gNewReply.ids.tagsInputId);n=n+gFormHtml.hidden.replace("###",gNewReply.ids.keyInputId).replace("???","comment_key");n=n+gFormHtml.hidden.replace("###",gNewReply.ids.formatInputId).replace("???","format");n=n+gFormHtml.hidden.replace("###",gNewReply.ids.parentCommentId).replace("???","reply_to_id");var k=gFormHtml.btns.replace("###",gNewReply.ids.addBtnId).replace("???",gNewReply.ids.cancelBtnId);gNewReplyHost.overlay.setStdModContent(CY.WidgetStdMod.FOOTER,q+n+k);var p=gNewReplyHost.overlay.getStdModNode(CY.WidgetStdMod.FOOTER);var m=gDb.getComment(j.commentId);var r="Re: ";var l=(gNewReply.val.title==""||gNewReply.val.title.substring(0,r.length)==r)?r+m.title:gNewReply.val.title;if(!sv_loggedIn){p.query(".n_name").set("value",gNewReply.val.name);p.query(".n_email").set("value",gNewReply.val.email);}p.query(".n_title").set("value",l);p.query(".n_content").set("value",gNewReply.val.content);p.query(".n_tags").set("value",gNewReply.val.tags);p.query("#"+gNewReply.ids.parentCommentId).set("value",j.commentId);p.query("#"+gNewReply.ids.formatInputId).set("value",gConf.defaultCommentFormat);gNewReplyHost.overlay.get("contentBox").query(".c-reply").addClass("displaynone");gNewReply.handlers.addBtnId=CY.on("click",onAddNewReplyClick,"#"+gNewReply.ids.addBtnId);gNewReply.handlers.cancelBtnId=CY.on("click",onCancelNewReplyClick,"#"+gNewReply.ids.cancelBtnId);var o=gLayout.getTopICommentsWidth();changeFormFieldsWidth(gNewReply.ids.formId,o);};cleanNewReplyForm=function(){if(gNewReplyHost!=null){var b=gNewReplyHost.overlay.getStdModNode(CY.WidgetStdMod.FOOTER);b.queryAll(".comment_input").set("value","");}};cancelNewReplyForm=function(){if(gNewReplyHost!=null){for(var c in gNewReply.handlers){if(gNewReply.handlers[c]!=null){gNewReply.handlers[c].detach();gNewReply.handlers[c]=null;}}gNewReplyHost.overlay.get("contentBox").query(".c-reply").removeClass("displaynone");var d=gNewReplyHost.overlay.getStdModNode(CY.WidgetStdMod.FOOTER);if(!sv_loggedIn){gNewReply.val.name=d.query(".n_name").get("value");gNewReply.val.email=d.query(".n_email").get("value");}gNewReply.val.title=d.query(".n_title").get("value");gNewReply.val.content=d.query(".n_content").get("value");gNewReply.val.tags=d.query(".n_tags").get("value");d.set("innerHTML","");gNewReplyHost=null;}};onAddNewReplyClick=function(){if(!sv_loggedIn){var c=CY.get("#"+gNewReply.ids.nameInputId).get("value");gPrefs.persist("user","name",c);var d=CY.get("#"+gNewReply.ids.emailInputId).get("value");gPrefs.persist("user","email",d);}gSync.saveComment(gNewReply.ids.formId);};onCancelNewReplyClick=function(){gSync.cancelReply();};getWrapperAncestor=function(d){var c=d;while(c!=null){if(CY.DOM.hasClass(c,"c-s")){return c;}c=c.parentNode;}return null;};hasWrapperAncestor=function(b){return(getWrapperAncestor(b)!=null);};getSelectionInfo=function(){var j=null,ac=null,T=0,aj=0,af="";if(window.getSelection){var V=window.getSelection();if(V.rangeCount>0){var ad=V.getRangeAt(0);af=ad.toString();if(af!=""){var R=document.createRange();R.setStart(V.anchorNode,V.anchorOffset);R.collapse(true);var W=document.createRange();W.setEnd(V.focusNode,V.focusOffset);W.collapse(false);var K=(W.compareBoundaryPoints(2,R)==1);j=(K)?V.anchorNode.parentNode:V.focusNode.parentNode;innerStartNode=(K)?V.anchorNode:V.focusNode;ac=(K)?V.focusNode.parentNode:V.anchorNode.parentNode;innerEndNode=(K)?V.focusNode:V.anchorNode;T=(K)?V.anchorOffset:V.focusOffset;aj=(K)?V.focusOffset:V.anchorOffset;if(!hasWrapperAncestor(ac)&&hasWrapperAncestor(j)){var e=document.createRange();e.setStart(innerStartNode,T);var ak=getWrapperAncestor(j);var X=ak;e.setEndAfter(X);var ah=parseInt(ak.id.substring("sv_".length));while(e.toString().lengthN.compareBoundaryPoints(2,ad))){j=ae.firstChild;T=0;ac=Q.lastChild;aj=CY.DOM.getText(Q).length;M=true;break;}}if(M){break;}}}}}R.detach();W.detach();}else{return null;}}else{return null;}}else{if(document.selection){var ai=document.selection.createRange();if(ai.text.length==0){return null;}var al=ai.parentElement();var L=ai.duplicate();var P=ai.duplicate();L.collapse(true);P.collapse(false);j=L.parentElement();while(L.moveStart("character",-1)!=0){if(L.parentElement()!=j){break;}T++;}ac=P.parentElement();while(P.moveEnd("character",-1)!=0){if(P.parentElement()!=ac){break;}aj++;}af=ai.text;}}if(!hasWrapperAncestor(j)||!hasWrapperAncestor(ac)){return null;}return{text:af,start:{elt:j,offset:T},end:{elt:ac,offset:aj}};};gNoSelectionYet=gettext("No selection yet");gFormHtml={formStart:'
',nameInput:gettext("Username:")+'
',emailInput:gettext("E-mail address:")+'
',titleInput:gettext("Title:")+'
',contentInput:gettext("Content:")+'
',tagsInput:gettext("Tag:")+'
',hidden:'',formEnd:"
",changeScope:'
'+gettext("Modify comment's scope:")+'
',headerTitle:'
',currentSel:'
'+gettext("Comment will apply to this selection:")+'
'+gNoSelectionYet+"
#hiddeninput#
",btns:'
',closeIcon:'      '};getHtml=function(i){ret={};ret.headerContent="";if("closeBtnId" in i){ret.headerContent+=gFormHtml.closeIcon.replace("###",i.closeBtnId);}ret.headerContent+=gFormHtml.headerTitle.replace("###",i.formTitleId);var g="";if("changeScopeInputId" in i){g=gFormHtml.changeScope.replace("###",i.changeScopeInputId);}var j="
"+gFormHtml.hidden.replace("###",i.selectionPlaceId).replace("???","selection_place")+"
";var h=gFormHtml.currentSel.replace("###",i.currentSelId).replace("???",i.currentSelIdI).replace("#hiddeninput#",j);var k=gFormHtml.btns.replace("###",i.addBtnId).replace("???",i.cancelBtnId);var l=gFormHtml.formStart.replace("###",i.formId)+g+h;if("nameInputId" in i){l=l+gFormHtml.nameInput.replace("###",i.nameInputId);}if("emailInputId" in i){l=l+gFormHtml.emailInput.replace("###",i.emailInputId);}l=l+gFormHtml.titleInput.replace("###",i.titleInputId)+gFormHtml.contentInput.replace("###",i.contentInputId)+gFormHtml.tagsInput.replace("###",i.tagsInputId);l=l+gFormHtml.hidden.replace("###",i.formatInputId).replace("???","format");l=l+gFormHtml.hidden.replace("###",i.startWrapperInputId).replace("???","start_wrapper");l=l+gFormHtml.hidden.replace("###",i.endWrapperInputId).replace("???","end_wrapper");l=l+gFormHtml.hidden.replace("###",i.startOffsetInputId).replace("???","start_offset");l=l+gFormHtml.hidden.replace("###",i.endOffsetInputId).replace("???","end_offset");l=l+gFormHtml.hidden.replace("###",i.keyId).replace("???","comment_key");l=l+gFormHtml.hidden.replace("###",i.editCommentId).replace("???","edit_comment_id");l=l+k+gFormHtml.formEnd;ret.bodyContent=l;return ret;};changeFormFieldsWidth=function(g,h){var f=(h-20)+"px";var e=CY.all("#"+g+" input[type='text']");if(e!=null){e.setStyle("width",f);}e=CY.all("#"+g+" textarea");if(e!=null){e.setStyle("width",f);}};addFormErrMsg=function(k,m,o){var n=document.getElementById(k);var e,l,p,i;for(e=0,i=n.elements.length;eb){var a=i.substring(0,(i.substring(0,b/2)).lastIndexOf(" "));var d=i.substring(i.length-b/2);var c=d.substring(d.indexOf(" "));f=a+" ... "+c;}var e=_convertSelectionFromCCToCS(h.start);var g=_convertSelectionFromCCToCS(h.end);_updateICommentFormSelection(gICommentForm,f,e,g);if(gEdit!=null){_updateICommentFormSelection(gEdit.ids,f,e,g);}positionICommentForm();}};showICommentForm=function(){removeFormErrMsg(gICommentForm.formId);if(!sv_loggedIn){if(CY.get("#"+gICommentForm.nameInputId).get("value")==""){CY.get("#"+gICommentForm.nameInputId).set("value",gPrefs.get("user","name"));}if(CY.get("#"+gICommentForm.emailInputId).get("value")==""){CY.get("#"+gICommentForm.emailInputId).set("value",gPrefs.get("user","email"));}}gIComments.hide();positionICommentForm();gICommentForm.overlay.show();CY.get("#"+gICommentForm.titleInputId).focus();};isICommentFormVisible=function(){if(gICommentForm!=null){return gICommentForm.overlay.get("visible");}return false;};positionICommentForm=function(){if(gICommentForm!=null){var b=gICommentForm.overlay;var a=b.get("boundingBox");var c=a.get("offsetHeight");var e=a.get("winHeight");var d=gICommentForm.position;if(c>e){d=[CY.WidgetPositionExt.BL,CY.WidgetPositionExt.BL];}b.set("align",{points:d});a.setX(a.getX()+gConf.iCommentLeftPadding);}};_changeIds=function(a,b){if(a.id){a.id=a.id+b;}var d=a.firstChild;while(d!=null){_changeIds(d,b);d=d.nextSibling;}};suffix=0;domDuplicate=function(a){var b=a.cloneNode(true);suffix++;_changeIds(b,"-"+suffix);return b;};getDuplicated=function(a){return document.getElementById(a.id+"-"+suffix);};logSel=function(a){log("text :"+a.text+", start id : "+a.start["elt"].id+" , start offset : "+a.start["offset"]+" , end id : "+a.end["elt"].id+"end offset : "+a.end["offset"]);};log=function(b){var a=document.getElementById("log");a.innerHTML=a.innerHTML+"
  • "+b+"
  • ";};urlEncode=function(h){if(!h){return"";}var c=[];for(var f in h){var e=h[f],b=encodeURIComponent(f);var g=typeof e;if(g=="undefined"){c.push(b,"=&");}else{if(g!="function"&&g!="object"){c.push(b,"=",encodeURIComponent(e),"&");}else{if(CY.Lang.isArray(e)){if(e.length){for(var d=0,a=e.length;de[d]){b=e[g];e[g]=e[d];e[d]=b;}return;}a=e[parseInt((g+d)/2)];e[parseInt((g+d)/2)]=e[g];e[g]=a;c=g+1;f=d;do{while(c<=f&&e[c]<=a){c++;}while(e[f]>a){f--;}if(cm[l.id]){m[l.id]=d;}}}for(var b in m){var h=this.allCommentsByDbId[b].id;var r=false;for(var k=0,c=n.length;k0){a=a.concat(this.getThreads(c[b].replies));}}return a;},_getPath:function(b,e){var a=[e];var d=e;while(d.reply_to_id!=null){d=b[d.reply_to_id];a.push(d);}return a;},getPath:function(a){return this._getPath(this.commentsByDbId,a);},getComment:function(a){return this.commentsByDbId[a];},getCommentByKey:function(a){for(var c in this.commentsByDbId){var b=this.commentsByDbId[c];if(b.key==a){return b;}}return null;},isChild:function(d,b){var c=this.commentsByDbId[d];var a=(d==b);while((!a)&&(c.reply_to_id!=null)){c=this.commentsByDbId[c.reply_to_id];a=(c.id==b);}return a;},browsingIndex:function(b){var c={};for(var a in this.ordered_comment_ids){var d=CY.Array.filter(this.ordered_comment_ids[a],function(e){return(e in this.commentsByDbId);},this);c[a]=CY.Array.indexOf(d,b);}return c;},browse:function(b,f,c){var a=this.ordered_comment_ids[b];if(a.length>0){var g=-1;if((f=="prev")||(f=="next")){for(var e=0;e=0)&&(ea.length){break;}}CY.error("internal error in db browse (could not find any filtered comment)");}return null;},computeFilterResults:function(n){var a={};if(n){for(key in n){if(key.indexOf("filter_")==0){a[key.substr("filter_".length)]=n[key];}}}else{if(gLayout.isInFrame()){a=parent.f_getFrameFilterData();}}var v=[];var w=[];var b="";if("name" in a){b=a.name;}this.filterByName(b,v,w);var p=[];var c=[];var C="";if("date" in a){C=a.date;}this.filterByDate(C,p,c);var g=[];var f=[];var t="";if("text" in a){t=a.text;}this.filterByText(t,g,f);var x=[];var m=[];var A="";if("tag" in a){A=a.tag;}this.filterByTag(A,x,m);var u=[];var e=[];var k="";if("state" in a){k=a.state;}this.filterByState(k,u,e);var d=[];var z=[];for(var y=0,j=v.length;yc){if(e.reply_to_id==null){d.push(e.id);}else{a.push(e.id);}}}},getCommentsAndRepliesCounts:function(d){var b=0;var f=0;var a=(d)?this.allComments:this.comments;var e=this.getThreads(a);for(var c=0;c0){b.showReadRepliesLnk();}else{b.hideReadRepliesLnk();}},remove:function(a){this._remove(this._getChildren(a));},close:function(a){CY.Array.each(this._getChildren(a),function(b){b.hide();});},open:function(a){CY.Array.each(this._getChildren(a),function(b){b.show();});},fetch:function(b){for(var a=0;a=0)&&e<=(this._c.length-1);){var c=this._c[e];if(c.commentId!=null&&c.isVisible()){a=a||(gDb.isChild(c.commentId,this._topActiveCommentDbId));if(a&&(!gDb.isChild(c.commentId,this._topActiveCommentDbId))){this.activate(c.commentId);return true;}}e=(d==0)?e+1:e-1;}}}return false;},browse:function(b,c){var a=c;if((c=="prev")&&!this.isAnyActive()){a="last";}if((c=="next")&&!this.isAnyActive()){a="first";}return gDb.browse(b,a,this._topActiveCommentDbId);}};gEditICommentHost=null;gEdit=null;dbgc=null;showEditForm=function(a){if(gEdit==null){gEdit={ids:{formId:CY.guid(),formTitleId:CY.guid(),nameInputId:CY.guid(),emailInputId:CY.guid(),titleInputId:CY.guid(),contentInputId:CY.guid(),tagsInputId:CY.guid(),formatInputId:CY.guid(),startWrapperInputId:CY.guid(),endWrapperInputId:CY.guid(),startOffsetInputId:CY.guid(),endOffsetInputId:CY.guid(),changeScopeInputId:CY.guid(),changeScopeInputWrapper:CY.guid(),selectionPlaceId:CY.guid(),keyId:CY.guid(),editCommentId:CY.guid(),currentSelId:CY.guid(),currentSelIdI:CY.guid(),addBtnId:CY.guid(),cancelBtnId:CY.guid()},handlers:{}};}gEditICommentHost=a;gEditICommentHost.hideContent();var c=getHtml(gEdit.ids);var b='
    '+c.headerContent+"
    ";var e='
    '+c.bodyContent+"
    ";gEditICommentHost.overlay.setStdModContent(CY.WidgetStdMod.HEADER,CY.Node.create(b),CY.WidgetStdMod.AFTER);gEditICommentHost.overlay.setStdModContent(CY.WidgetStdMod.BODY,CY.Node.create(e),CY.WidgetStdMod.AFTER);CY.get("#"+gEdit.ids["formTitleId"]).set("innerHTML",gettext("Edit comment"));var f=gDb.getComment(gEditICommentHost.commentId);CY.get("#"+gEdit.ids["editCommentId"]).set("value",f.id);CY.get("#"+gEdit.ids["keyId"]).set("value",f.key);CY.get("#"+gEdit.ids["changeScopeInputId"]+" input").set("checked",false);if(f.reply_to_id!=null){CY.get("#"+gEdit.ids["changeScopeInputId"]).addClass("displaynone");}changeScopeFormClick();CY.get("#"+gEdit.ids["nameInputId"]).set("value",f.name);CY.get("#"+gEdit.ids["emailInputId"]).set("value",f.email);if(f.logged_author){CY.get("#"+gEdit.ids["nameInputId"]).setAttribute("disabled",true);CY.get("#"+gEdit.ids["emailInputId"]).setAttribute("disabled",true);}CY.get("#"+gEdit.ids["titleInputId"]).set("value",f.title);CY.get("#"+gEdit.ids["contentInputId"]).set("value",f.content);CY.get("#"+gEdit.ids["tagsInputId"]).set("value",f.tags);CY.get("#"+gEdit.ids["formatInputId"]).set("value",gConf.defaultCommentFormat);var d=gLayout.getTopICommentsWidth();changeFormFieldsWidth(gEdit.ids["formId"],d);gEdit.handlers["addBtnId"]=CY.on("click",onEditSaveClick,"#"+gEdit.ids["addBtnId"]);gEdit.handlers["cancelBtnId"]=CY.on("click",onEditCancelClick,"#"+gEdit.ids["cancelBtnId"]);gEdit.handlers["changeScope"]=CY.on("click",onChangeScopeClick,"#"+gEdit.ids["changeScopeInputId"]);};onEditSaveClick=function(a){if(readyForAction()){gSync.editComment();}};onEditCancelClick=function(a){if(readyForAction()){gSync.cancelEdit();}};onChangeScopeClick=function(){if(readyForAction()){gSync.changeScopeFormClick();}};changeScopeFormClick=function(){var a=CY.get("#"+gEdit.ids["currentSelId"]);if(CY.get("#"+gEdit.ids["changeScopeInputId"]+" input").get("checked")){a.removeClass("displaynone");}else{a.addClass("displaynone");}};cancelEditForm=function(){if(gEditICommentHost!=null){for(var b in gEdit.handlers){if(gEdit.handlers[b]!=null){gEdit.handlers[b].detach();gEdit.handlers[b]=null;}}var a=gEditICommentHost.overlay.get("contentBox").query(".icomment-edit-body");a.get("parentNode").removeChild(a);a=gEditICommentHost.overlay.get("contentBox").query(".icomment-edit-header");a.get("parentNode").removeChild(a);gEditICommentHost.showContent();gEditICommentHost=null;}};Preferences=function(){this.prefs={};};Preferences.prototype={init:function(){this._read();},_read:function(){for(var b in gConf.defaultPrefs){this.prefs[b]={};for(var a in gConf.defaultPrefs[b]){var c=null;if(b=="user"&&(a=="name"||a=="email")){c=CY.Cookie.get("user_"+a);}else{c=CY.Cookie.getSub(b,a);}this.prefs[b][a]=(c==null)?gConf.defaultPrefs[b][a]:c;}}},persist:function(b,a,d){var c={path:"/",expires:(new Date()).setFullYear(2100,0,1)};if(b=="user"&&(a=="name"||a=="email")){CY.Cookie.set("user_"+a,d,c);}else{CY.Cookie.setSub(b,a,d,c);}this.prefs[b][a]=d;},get:function(b,a){return this.prefs[b][a];},readDefault:function(b,a){return gConf.defaultPrefs[b][a];},reset:function(a){for(var b=0;b
    '+t+'
    -X',bodyContent:'"});this.overlay.get("contentBox").addClass("c-comment");this.overlay.render("#leftcolumn");this.animation=new CY.Anim({node:this.overlay.get("boundingBox"),duration:gPrefs.get("general","animduration"),easing:CY.Easing.easeOut});this.overlay.get("contentBox").query(".c-close").on("click",this.onCloseCommentClick,this);this.overlay.get("contentBox").query(".c-moderate").on("click",this.onModerateCommentClick,this);this.overlay.get("contentBox").query(".c-state-pending").on("click",this.onPendingCommentClick,this);this.overlay.get("contentBox").query(".c-state-approved").on("click",this.onApprovedCommentClick,this);this.overlay.get("contentBox").query(".c-state-unapproved").on("click",this.onUnapprovedCommentClick,this);this.overlay.get("contentBox").query(".c-state-cancel").on("click",this.onCancelStateChangeClick,this);this.overlay.get("contentBox").query(".c-edit").on("click",this.onEditCommentClick,this);this.overlay.get("contentBox").query(".c-delete").on("click",this.onDeleteCommentClick,this);this.overlay.get("contentBox").query(".c-reply").on("click",this.onReplyCommentClick,this);this.overlay.get("contentBox").query(".c-readreplies").on("click",this.onReadRepliesCommentClick,this);this.overlay.get("contentBox").query(".icomment-header").on("mouseenter",this.onMouseEnterHeader,this);this.overlay.get("contentBox").query(".icomment-header").on("mouseleave",this.onMouseLeaveHeader,this);this.overlay.get("contentBox").on("click",this.onCommentClick,this);};IComment.prototype={onCloseCommentClick:function(a){a.halt();if(readyForAction()&&this.isVisible()){gSync.closeComment(this);}},onModerateCommentClick:function(a){a.halt();if(readyForAction()&&this.isVisible()){this.overlay.get("contentBox").query(".c-iactions").addClass("displaynone");this.overlay.get("contentBox").query(".c-state-actions").removeClass("displaynone");}},onPendingCommentClick:function(a){a.halt();if(readyForAction()&&this.isVisible()){gSync.moderateComment(this,"pending");}},onApprovedCommentClick:function(a){a.halt();if(readyForAction()&&this.isVisible()){gSync.moderateComment(this,"approved");}},onUnapprovedCommentClick:function(a){a.halt();if(readyForAction()&&this.isVisible()){gSync.moderateComment(this,"unapproved");}},onCancelStateChangeClick:function(a){a.halt();if(readyForAction()&&this.isVisible()){this.overlay.get("contentBox").query(".c-iactions").removeClass("displaynone");this.overlay.get("contentBox").query(".c-state-actions").addClass("displaynone");}},onDeleteCommentClick:function(a){a.halt();if(readyForAction()&&this.isVisible()){gSync.removeComment(this);}},onEditCommentClick:function(a){a.halt();if(readyForAction()&&this.isVisible()){gSync.showEditForm(this);}},onReplyCommentClick:function(a){a.halt();if(readyForAction()&&this.isVisible()){gSync.showReplyForm(this);}},onReadRepliesCommentClick:function(a){a.halt();if(readyForAction()&&this.isVisible()){gSync.openComment(this);}},onCommentClick:function(d){if(readyForAction()&&this.isVisible()){if(d.target.get("target")=="_blank"){var c=d.target;var g=sv_site_url+sv_text_view_show_comment_url;if(c.get("href").indexOf(g)==0){var b=(new RegExp("comment_key=([^&]*)","g")).exec(c.get("href"));if(b!=null){var a=b[1];var f=gDb.getCommentByKey(a);if(f!=null){d.halt();if(!c.hasClass("c-permalink")){checkForOpenedDialog(null,function(){gSync.showSingleComment(f);});}}}}}else{if(gShowingAllComments){if(!this._isHostingAForm()){var f=gDb.getComment(this.commentId);checkForOpenedDialog(null,function(){if(f!=null){gSync.showSingleComment(f);}});}}else{gSync.activate(this);}}}},onMouseEnterHeader:function(){if(readyForAction()&&this.isVisible()){this.overlay.get("contentBox").query(".c-permalink").removeClass("displaynone");}},onMouseLeaveHeader:function(){if(readyForAction()&&this.isVisible()){this.overlay.get("contentBox").query(".c-permalink").addClass("displaynone");}},setWidth:function(a){this.overlay.get("boundingBox").setStyle("width",a+"px");},activate:function(){this.overlay.get("boundingBox").addClass("c-focus-comment");},deactivate:function(){this.overlay.get("boundingBox").removeClass("c-focus-comment");},hide:function(){if(gIComments.isTopActive(this.commentId)){if(!gIComments.activateVisibleNext()){gIComments.deactivate();}}if(this.isVisible()){this.overlay.hide();this.overlay.blur();}},hideContent:function(){this.overlay.get("contentBox").query(".icomment-header").addClass("displaynone");this.overlay.get("contentBox").query(".icomment-body").addClass("displaynone");},showContent:function(){this.overlay.get("contentBox").query(".icomment-header").removeClass("displaynone");this.overlay.get("contentBox").query(".icomment-body").removeClass("displaynone");},isVisible:function(){return this.overlay.get("visible");},show:function(){this.hideReadRepliesLnk();return this.overlay.show();},showReadRepliesLnk:function(){this.overlay.get("contentBox").query(".c-readreplies").removeClass("displaynone");},hideReadRepliesLnk:function(){this.overlay.get("contentBox").query(".c-readreplies").addClass("displaynone");},changeModeration:function(b){var a=this.overlay.get("contentBox").query(".c-moderate");a.set("innerHTML",gettext(b.state));a.removeClass("c-state-approved");a.removeClass("c-state-pending");a.removeClass("c-state-unapproved");a.addClass("c-state-"+b.state);this.overlay.get("contentBox").query(".c-iactions").removeClass("displaynone");this.overlay.get("contentBox").query(".c-state-actions").addClass("displaynone");},isfetched:function(){return(this.commentId!=null);},unfetch:function(){this.commentId=null;},fetch:function(h){this.commentId=h.id;var b=this.overlay.get("boundingBox");if(h.start_wrapper!=-1){b.addClass("c-has-scope");b.removeClass("c-has-no-scope");}else{b.addClass("c-has-no-scope");b.removeClass("c-has-scope");}if(h.reply_to_id!=null){b.addClass("c-is-reply");}else{b.removeClass("c-is-reply");}var f=interpolate(gettext("last modified on %(date)s"),{date:h.modified_user_str},true);var k=(h.modified==h.created)?"":' * ';var i=gettext("Permalink to this comment");var n='¶ ';var j=interpolate(gettext("by %(name)s, created on %(date)s"),{name:h.name,date:h.created_user_str},true);var c='
    '+h.title+n+'
    '+j+"
    ";var d=CY.Node.create(c);var o=b.query(".c-header");if(o==null){b.query(".icomment-header").insertBefore(d,b.one(".c-iactions"));}else{o.get("parentNode").replaceChild(d,o);}var g=CY.Node.create('
    tags:'+h.tags+"
    ");var m=b.query(".c-tags");if(m==null){b.query(".icomment-header").appendChild(g);}else{m.get("parentNode").replaceChild(g,m);}if(h.tags==""){g.addClass("displaynone");}var e=CY.Node.create(''+h.content_html+"");var a=b.query(".c-content");if(a==null){b.query(".icomment-body").appendChild(e);}else{a.get("parentNode").replaceChild(e,a);}b.query(".c-permalink").set("href",sv_site_url+h.permalink);this.changeModeration(h);var l=b.queryAll(".c-content a");if(l!=null){l.setAttribute("target","_blank");}l=b.queryAll(".c-header-title a");if(l!=null){l.setAttribute("target","_blank");}this.permAdapt(h);},permAdapt:function(e){var b=this.overlay.get("contentBox").query(".c-delete");if(b){if(!e.can_delete){b.addClass("displaynone");}else{b.removeClass("displaynone");}}var a=this.overlay.get("contentBox").query(".c-edit");if(a){if(!e.can_edit){a.addClass("displaynone");}else{a.removeClass("displaynone");}}var d=this.overlay.get("contentBox").query(".c-reply");if(d){if(!hasPerm("can_create_comment")){d.addClass("displaynone");}else{d.removeClass("displaynone");}}var c=this.overlay.get("contentBox").query(".c-moderate");if(c){if(!e.can_moderate){c.addClass("displaynone");}else{c.removeClass("displaynone");}}},setThreadPad:function(a){this.overlay.get("contentBox").query(".yui-widget-hd").setStyle("paddingLeft",a+"px");this.overlay.get("contentBox").query(".yui-widget-bd").setStyle("paddingLeft",a+"px");},setPosition:function(b){var a=this.overlay.get("boundingBox");a.setStyle("opacity",1);a.setXY(b);},getPosition:function(b){var a=this.overlay.get("boundingBox");return a.getXY();},onAnimationEnd:function(){if(!CY.Lang.isUndefined(this["animation-handle"])&&!CY.Lang.isNull(this["animation-handle"])){this["animation-handle"].detach();this["animation-handle"]=null;}gIComments.signalAnimationEnd();if(gIComments.animationsEnded()){gIComments.whenAnimationsEnd();}},setAnimationToPosition:function(b){var a=this.overlay.get("boundingBox");if(gPrefs.get("general","animduration")<0.011){a.setXY(b);}this.animation.set("to",{xy:b});this.animation.set("duration",gPrefs.get("general","animduration"));this["animation-handle"]=this.animation.on("end",this.onAnimationEnd,this);return this.animation;},setWidth:function(b){var a=this.overlay.get("boundingBox");a.setStyle("width",b+"px");},getHeight:function(){return this.overlay.get("boundingBox").get("offsetHeight");},scrollIntoView:function(){if(!this.overlay.get("contentBox").inViewportRegion()){this.overlay.get("contentBox").scrollIntoView(true);}},_isHostingAForm:function(){return(this.isVisible()&&((gNewReplyHost!=null&&gNewReplyHost==this)||(gEditICommentHost!=null&&gEditICommentHost==this)));}};_afterDlg=function(d){var a=d[0];var c=d[1];var b=d[2];a.call(c,b);};_abortNewCommentConfirmed=function(a){if(isICommentFormVisible()){if(gLayout.isInFrame()){gSync.hideICommentForm({fn:function(){_afterDlg(a);}});gSync.resume();}}};_abortNewReplyConfirmed=function(a){if(gNewReplyHost!=null){if(gLayout.isInFrame()){cancelNewReplyForm();_afterDlg(a);}}};_abortNewEditConfirmed=function(a){if(gEditICommentHost!=null){if(gLayout.isInFrame()){cancelEditForm();_afterDlg(a);}}};checkForOpenedDialog=function(e,b,d,c){var a=[];if(e!=null){a=CY.Array.map(gDb.getThreads([gDb.getComment(e.commentId)]),function(f){return f.id;});}if(isICommentFormVisible()||(gNewReplyHost!=null&&(e==null||CY.Array.indexOf(a,gNewReplyHost.commentId)!=-1))||(gEditICommentHost!=null&&(e==null||CY.Array.indexOf(a,gEditICommentHost.commentId)!=-1))){if(gLayout.isInFrame()){if(isICommentFormVisible()){parent.f_yesNoDialog(gettext("New comment will be canceled, continue?"),gettext("Warning"),null,null,null,_abortNewCommentConfirmed,this,[b,d,c]);}else{if(gNewReplyHost!=null){parent.f_yesNoDialog(gettext("Started reply will be canceled, continue?"),gettext("Warning"),null,null,null,_abortNewReplyConfirmed,this,[b,d,c]);}else{if(gEditICommentHost!=null){parent.f_yesNoDialog(gettext("Started comment edition will be canceled, continue?"),gettext("Warning"),null,null,null,_abortNewEditConfirmed,this,[b,d,c]);}}}}}else{b.call(d,[]);}};hasPerm=function(a){return(-1!=CY.Array.indexOf(sv_user_permissions,a));};gShowingAllComments=false;Sync=function(){this._q=null;this._iPreventClick=false;};Sync.prototype={init:function(a){this._q=new CY.AsyncQueue();},setPreventClickOn:function(){CY.log("setPreventClickOn !");if(gLayout.isInFrame()){parent.f_interfaceFreeze();}this._iPreventClick=true;},setPreventClickOff:function(){CY.log("setPreventClickOff !");if(gLayout.isInFrame()){parent.f_interfaceUnfreeze();}this._iPreventClick=false;},removeCommentRet:function(b){var d=b.successfull;var a=(d)?b.failure["iComment"]:b.success["iComment"];if(d){var c=b.returned["filterData"];if(gLayout.isInFrame()){parent.f_updateFilterData(c);}var f=gIComments.getTopPosition()[1];var e=gDb.getComment(a.commentId);this._q.add(function(){unpaintCommentScope(e);gIComments.close(e.id);gIComments.remove(e.id);if(e.reply_to_id!=null){gIComments.refresh(e.reply_to_id);}gDb.del(e);if(gLayout.isInFrame()){if(gDb.comments.length==0&&gDb.allComments.length!=0){parent.f_enqueueMsg(gettext("no filtered comments left"));parent.resetFilter();}else{var g=gDb.computeFilterResults();updateFilterResultsCount(g.nbDiscussions,g.nbComments,g.nbReplies);}}});this._animateTo(f);}this._q.add({fn:CY.bind(this.setPreventClickOff,this)});this.resume();},moderateCommentRet:function(c){var e=c.successfull;var a=(e)?c.failure["iComment"]:c.success["iComment"];if(e){var b=c.returned;var f=b.comment;gDb.upd(f);var d=gLayout.isInFrame()&&!parent.f_isFrameFilterFieldsInit();if(d){parent.resetFilter();this._showSingleComment(f);}else{a.changeModeration(f);}}this._q.add({fn:CY.bind(this.setPreventClickOff,this)});this.resume();},saveCommentRet:function(h){var i=h.successfull;if(i){var l=h.success["formId"];var g=h.returned;removeFormErrMsg(l);if("errors" in g){var k=g.errors;for(var d in k){addFormErrMsg(l,d,k[d]);}this._animateToTop();}else{var b=function(){return(gNewReply!=null)&&(l==gNewReply.ids["formId"]);};var c=function(){return(gICommentForm!=null)&&(l==gICommentForm.formId);};var e=function(){return(gEdit!=null)&&(l==gEdit.ids["formId"]);};if(c()){this.hideICommentForm(cleanICommentForm());}else{if(e()){this._hideEditForm();}else{if(b()){this._hideNewReplyForm();}}}if("ask_for_notification" in g){if(g.ask_for_notification){parent.f_yesNoDialog(gettext("Do you want to subscribe to all replies notifications in discussions you participated in?"),gettext("Follow up"),function(){var m={method:"POST",data:urlEncode({fun:"ownNotify",key:sv_key,version_key:sv_version_key,email:g.email,active:false})};CY.io(sv_client_url,m);},this,null,function(){var m={method:"POST",data:urlEncode({fun:"ownNotify",key:sv_key,version_key:sv_version_key,email:g.email,active:true})};CY.io(sv_client_url,m);},this,null);}}if("comment" in g){var f=g.comment;gDb.upd(f);var a=gLayout.isInFrame()&&!parent.f_isFrameFilterFieldsInit();if(a){parent.resetFilter();}else{if(f.reply_to_id==null){unpaintCommentScope(f);paintCommentScope(f);}}var j=g.filterData;if(gLayout.isInFrame()){parent.f_updateFilterData(j);updateResetFilterResultsCount();}if(b()){if(!a){this._insertReply(f);}}else{this._showSingleComment(f);}}else{this._animateToTop();}}}else{this._q.add({id:"expl",fn:function(){CY.log("in example .........");}});this._q.promote("expl");}this._q.add({fn:CY.bind(this.setPreventClickOff,this)});this.resume();},example:function(){CY.log("in example .........");},moderateComment:function(a,b){var c=gDb.getComment(a.commentId);this._q.add({fn:CY.bind(this.setPreventClickOn,this)},{autoContinue:false,fn:CY.bind(doExchange,null,"editComment",{comment_key:c.key,state:b},null,this.moderateCommentRet,this,{iComment:a},gettext("could not save comment"))}).run();},_saveComment:function(b,a){this._q.add({fn:CY.bind(this.setPreventClickOn,this)},{autoContinue:false,fn:CY.bind(doExchange,null,b,{},a,this.saveCommentRet,this,{formId:a},gettext("could not save comment"))}).run();},editComment:function(){this._saveComment("editComment",gEdit.ids["formId"]);},saveComment:function(a){this._saveComment("addComment",a);},removeComment:function(a){checkForOpenedDialog(a,function(){if(gLayout.isInFrame()){parent.f_yesNoDialog(gettext("Are you sure you want to delete this comment?"),gettext("Warning"),function(){this.animateToTop();},this,null,function(){var b=gDb.getComment(a.commentId);this._q.add({fn:CY.bind(this.setPreventClickOn,this)},{autoContinue:false,fn:CY.bind(doExchange,null,"removeComment",{comment_key:b.key},null,this.removeCommentRet,this,{iComment:a},gettext("could not remove comment"))}).run();},this,null);}},this,null);},resume:function(b,a){this._q.run();},resetAutoContinue:function(a){this._q.getCallback(a).autoContinue=true;},hideICommentForm:function(a){this._q.add({autoContinue:false,fn:CY.bind(gICommentForm.animationHide.run,gICommentForm.animationHide)});if(a){this._q.add(a);}},showCommentForm:function(a){checkForOpenedDialog(null,function(){this._q.add({fn:CY.bind(this.setPreventClickOn,this)});this._q.add({fn:function(){if(a==null){var b=getSelectionInfo();updateICommentFormSelection(b);}showICommentForm(a);}});this._q.add({autoContinue:false,fn:CY.bind(gICommentForm.animationShow.run,gICommentForm.animationShow)},{fn:CY.bind(this.setPreventClickOff,this)}).run();},this,null);},showEditForm:function(a){checkForOpenedDialog(null,function(){this._q.add({fn:CY.bind(this.setPreventClickOn,this)});this._q.add({fn:function(){showEditForm(a);}});this._animateToTop();this._q.add({fn:CY.bind(this.setPreventClickOff,this)});this._q.run();},this,null);},showReplyForm:function(a){checkForOpenedDialog(null,function(){this._q.add({fn:CY.bind(this.setPreventClickOn,this)});this._q.add({fn:function(){instanciateNewReplyForm(a);}});this._animateToTop();this._q.add({fn:CY.bind(this.setPreventClickOff,this)});this._q.run();},this,null);},cancelICommentForm:function(){this._q.add({fn:CY.bind(this.setPreventClickOn,this)});this.hideICommentForm();this._q.add({fn:CY.bind(this.setPreventClickOff,this)});this._q.run();},cancelEdit:function(){this._q.add({fn:CY.bind(this.setPreventClickOn,this)});this._q.add({fn:function(){cancelEditForm();}});this._animateToTop();this._q.add({fn:CY.bind(this.setPreventClickOff,this)});this._q.run();},cancelReply:function(){this._q.add({fn:CY.bind(this.setPreventClickOn,this)});this._q.add({fn:function(){cancelNewReplyForm();}});this._animateToTop();this._q.add({fn:CY.bind(this.setPreventClickOff,this)});this._q.run();},changeScopeFormClick:function(){this._q.add({fn:CY.bind(this.setPreventClickOn,this)});this._q.add({fn:function(){changeScopeFormClick();}});this._animateToTop();this._q.add({fn:CY.bind(this.setPreventClickOff,this)});this._q.run();},_hideNewReplyForm:function(){this._q.add({fn:function(){cleanNewReplyForm();cancelNewReplyForm();}});},_hideEditForm:function(){this._q.add({fn:function(){cancelEditForm();}});},_insertReply:function(a){this._q.add({fn:function(){var g=gDb.getComment(a.reply_to_id);var e=gDb.getThreads([g]);var c=e[e.length-2];var d=gIComments.insertAfter(c,a);var h=gIComments.getPosition(a.reply_to_id);d.setPosition(h);var b=gDb.getPath(a);var f=b[b.length-1];if(gIComments.isTopActive(f.id)){d.activate();}d.show();}});this._animateToTop();},_showSingleComment:function(d){if(d!=null){var c=gDb.getPath(d);var b=c[c.length-1];var a=0;if(d.start_wrapper!=-1){a=CY.get(".c-id-"+b.id).getY();}else{a=CY.get("document").get("scrollTop");}this._showComments([b.id],a,false);if(b.replies.length>0){this._animateTo(a);}}},showSingleComment:function(a){this._q.add({fn:CY.bind(this.setPreventClickOn,this)});this._showSingleComment(a);this._q.add({fn:CY.bind(this.setPreventClickOff,this)});this._q.run();},browse:function(a,b){var c=gIComments.browse(a,b);if(c!=null){this.showSingleComment(c);}},_showComments:function(c,b,a){this._q.add({fn:function(){gShowingAllComments=a;gIComments.hide();var d=CY.Array.map(c,function(g){return gDb.getComment(g);});var f=gDb.getThreads(d);gIComments.fetch(f);if(c.length>0){if(a){CY.get("document").set("scrollTop",0);}else{gIComments.activate(c[0]);var e=CY.get(".c-id-"+c[0]);if(e&&!e.inViewportRegion()){e.scrollIntoView(true);}}}gIComments.setPosition([gConf.iCommentLeftPadding,b]);gIComments.show();}});},_animateTo:function(a){this._q.add({fn:function(){gIComments.setAnimationToPositions(a);}},{id:"animationRun",autoContinue:false,fn:CY.bind(gIComments.runAnimations,gIComments)});},_animateToTop:function(){var a=gIComments.getTopPosition();if(a!=null){this._animateTo(a[1]);}},animateToTop:function(){this._q.add({fn:CY.bind(this.setPreventClickOn,this)});this._animateToTop();this._q.add({fn:CY.bind(this.setPreventClickOff,this)});this._q.run();},showAllComments:function(){checkForOpenedDialog(null,function(){gShowingAllComments=true;var a=CY.Array.map(gDb.comments,function(b){return b.id;});this.showComments(a,[0,0],true);},this,null);},showScopeRemovedComments:function(){checkForOpenedDialog(null,function(){gShowingAllComments=true;var b=CY.Array.filter(gDb.comments,function(c){return(c.start_wrapper==-1);});var a=CY.Array.map(b,function(d){return d.id;});this.showComments(a,[0,0],true);},this,null);},showComments:function(c,b,a){checkForOpenedDialog(null,function(){this._q.add({fn:CY.bind(this.setPreventClickOn,this)});this._showComments(c,b[1],a);this._animateTo(b[1]);this._q.add({fn:CY.bind(this.setPreventClickOff,this)});this._q.run();},this,null);},openComment:function(a){this._q.add({fn:CY.bind(this.setPreventClickOn,this)});var b=gIComments.getTopPosition()[1];this._q.add({fn:function(){gIComments.open(a.commentId);gIComments.refresh(a.commentId);}});this._animateTo(b);this._q.add({fn:CY.bind(this.setPreventClickOff,this)});this._q.run();},closeComment:function(a){checkForOpenedDialog(a,function(){this._q.add({fn:CY.bind(this.setPreventClickOn,this)});var b=gIComments.getTopPosition()[1];this._q.add({fn:function(){var c=gDb.getComment(a.commentId);gIComments.close(a.commentId);if(c.reply_to_id!=null){gIComments.refresh(c.reply_to_id);}}});this._animateTo(b);this._q.add({fn:CY.bind(this.setPreventClickOff,this)});this._q.run();},this,null);},activate:function(a){gIComments.activate(a.commentId);}};readyForAction=function(){return !gSync._iPreventClick;};paintCommentScope=function(b){if(b.reply_to_id==null&&b.start_wrapper!=-1){var a={start:{elt:document.getElementById("sv_"+b.start_wrapper),offset:b.start_offset},end:{elt:document.getElementById("sv_"+b.end_wrapper),offset:b.end_offset}};if(document.getElementById("sv_"+b.start_wrapper)==null){warn_server({from:"paintCommentScope",start_wrapper:b.start_wrapper});}else{if(document.getElementById("sv_"+b.end_wrapper)==null){warn_server({from:"paintCommentScope",end_wrapper:b.end_wrapper});}else{a.start=_convertSelectionFromCSToCC(a.start);a.end=_convertSelectionFromCSToCC(a.end);renderComment(a,b.id);}}}};getCommentIdsFromClasses=function(b){var a=[];var e=b.className.split(" ");for(var d=0,c=e.length;d=d.offset){a.elt=e;a.offset=d.offset-b;break;}e=e.nextSibling;}return a;};unpaintCommentScope=function(k){var j=k.id;var r="c-id-"+j;var m=[];var t=CY.all("."+r);if(t!=null){for(var h=0,d=t.size();h0){checkForOpenedDialog(null,function(){gSync.showComments(a,[f.pageX,f.pageY],false);});}}}}};gLastScrollTime=null;checkForAlignement=function(){var a=(new Date()).getTime();if((gLastScrollTime!=null)&&(a-gLastScrollTime)>200){positionICommentForm();gLastScrollTime=null;}};onFrameScroll=function(){gLastScrollTime=(new Date()).getTime();};browse=function(a,b){gSync.browse(a,b);};initialConnect=function(){CY.on("mouseup",onTextMouseUp,"#textcontainer");gTimer=CY.Lang.later(200,this,checkForAlignement,[],true);CY.on("scroll",onFrameScroll,window,this,true);CY.on("resize",onFrameScroll,window,this,true);};preventLinksInText=function(){var a=function(c){c.preventDefault();var b=c.target;while(b!=null&&b.get("href")==null){b=b.get("parentNode");}if(b!=null&&b.get("href")!=null){window.open(b.get("href"));}};CY.all("#textcontainer a").on("click",a);};onDomReady=function(b){preventLinksInText();var a=new CY.AsyncQueue();a.add({fn:function(){if(gLayout.isInComentSite()){parent.toInitialSize();}if(sv_withComments){instanciateICommentForm();}},timeout:5},{fn:function(){gGETValues=CY.JSON.parse(sv_get_params);CY.get("#maincontainer").setStyle("display","block");CY.get("#textcontainer").setStyle("display","block");var e=(sv_withComments)?gPrefs.get("layout","comments_col_width"):0;var d=sliderValToPx(e);gLayout.setLeftColumnWidth(d);if(gLayout.isInFrame()){parent.f_initFrame();parent.f_layoutFrames();if(sv_withComments){parent.f_fillTopToolbar();if(hasPerm("can_create_comment")){parent.$("#add_comment_btn").removeClass("initially_hidden");}parent.f_fillFilterTab();parent.f_fillPreferencesTab();var c=CY.JSON.parse(sv_filter_data);parent.f_updateFilterData(c);parent.f_setFilterValue(gGETValues);}parent.f_fillTextPreferencesTab();}if(gLayout.isInComentSite()){parent.$("#c_fullscreen_btn").show();}else{parent.$("#c_fullscreen_btn").hide();}},timeout:5},{fn:function(){if(sv_withComments){reinit(gGETValues);initialConnect();}},timeout:5},{fn:function(){if(gLayout.isInFrame()){parent.f_interfaceUnfreeze();parent.f_removeLoadingMsg();}if("comment_key" in gGETValues){var c=gGETValues.comment_key;var f=gDb.getCommentByKey(c);if(f!=null){var e=gDb.getPath(f);var d=e[e.length-1];gSync.showSingleComment(d);}}}});a.run();};c_persistPreference=function(b,a,c){gPrefs.persist(b,a,c);};c_readDefaultPreference=function(b,a){return gConf.defaultPrefs[b][a];};c_readPreference=function(b,a){return gPrefs.get(b,a);};c_resetPreferences=function(a){gPrefs.reset(a);};c_applyTextStyle=function(a){CY.use(a);};sliderValToPx=function(d){var a=CY.DOM.winWidth();if(gLayout.isInFrame()){a=parent.$(parent).width();}var b=d/100;b=Math.min(b,gConf.sliderFixedMin);b=Math.max(b,gConf.sliderFixedMax);var c=b*a;return Math.floor(c);};c_setCommentsColWidth=function(c){var a=sliderValToPx(c);gLayout.setLeftColumnWidth(a);var b=gLayout.getTopICommentsWidthFromWidth(a);gIComments.setWidth(b);gICommentForm.overlay.get("boundingBox").setStyle("width",b+"px");changeFormFieldsWidth(gICommentForm.formId,b);if(gNewReply){changeFormFieldsWidth(gNewReply.ids["formId"],b);}if(gEdit){changeFormFieldsWidth(gEdit.ids["formId"],b);}}; \ No newline at end of file +gNewReplyHost=null;gNewReply=null;instanciateNewReplyForm=function(i){if(gNewReply==null){gNewReply={val:{name:gPrefs.get("user","name"),email:gPrefs.get("user","email"),title:"",content:"",tags:""},ids:{name:gPrefs.get("user","name"),email:gPrefs.get("user","email"),title:"",content:"",tags:"",formId:CY.guid(),nameInputId:CY.guid(),emailInputId:CY.guid(),titleInputId:CY.guid(),contentInputId:CY.guid(),keyInputId:CY.guid(),formatInputId:CY.guid(),tagsInputId:CY.guid(),parentCommentId:CY.guid(),addBtnId:CY.guid(),cancelBtnId:CY.guid()},handlers:{}};}gNewReplyHost=i;var b='
    '+gettext("New reply")+"
    ";var e=gFormHtml.formStart.replace("###",gNewReply.ids["formId"]);if(!sv_loggedIn){e=e+gFormHtml.nameInput.replace("###",gNewReply.ids["nameInputId"])+gFormHtml.emailInput.replace("###",gNewReply.ids["emailInputId"]);}e=e+gFormHtml.titleInput.replace("###",gNewReply.ids["titleInputId"])+gFormHtml.contentInput.replace("###",gNewReply.ids["contentInputId"])+gFormHtml.tagsInput.replace("###",gNewReply.ids["tagsInputId"]);e=e+gFormHtml.hidden.replace("###",gNewReply.ids["keyInputId"]).replace("???","comment_key");e=e+gFormHtml.hidden.replace("###",gNewReply.ids["formatInputId"]).replace("???","format");e=e+gFormHtml.hidden.replace("###",gNewReply.ids["parentCommentId"]).replace("???","reply_to_id");var h=gFormHtml.btns.replace("###",gNewReply.ids["addBtnId"]).replace("???",gNewReply.ids["cancelBtnId"]);gNewReplyHost.overlay.setStdModContent(CY.WidgetStdMod.FOOTER,b+e+h);var c=gNewReplyHost.overlay.getStdModNode(CY.WidgetStdMod.FOOTER);var f=gDb.getComment(i.commentId);var a="Re: ";var g=(gNewReply.val["title"]==""||gNewReply.val["title"].substring(0,a.length)==a)?a+f.title:gNewReply.val["title"];if(!sv_loggedIn){c.query(".n_name").set("value",gNewReply.val["name"]);c.query(".n_email").set("value",gNewReply.val["email"]);}c.query(".n_title").set("value",g);c.query(".n_content").set("value",gNewReply.val["content"]);c.query(".n_tags").set("value",gNewReply.val["tags"]);c.query("#"+gNewReply.ids["parentCommentId"]).set("value",i.commentId);c.query("#"+gNewReply.ids["formatInputId"]).set("value",gConf.defaultCommentFormat);gNewReplyHost.overlay.get("contentBox").query(".c-reply").addClass("displaynone");gNewReply.handlers["addBtnId"]=CY.on("click",onAddNewReplyClick,"#"+gNewReply.ids["addBtnId"]);gNewReply.handlers["cancelBtnId"]=CY.on("click",onCancelNewReplyClick,"#"+gNewReply.ids["cancelBtnId"]);var d=gLayout.getTopICommentsWidth();changeFormFieldsWidth(gNewReply.ids["formId"],d);};cleanNewReplyForm=function(){if(gNewReplyHost!=null){var a=gNewReplyHost.overlay.getStdModNode(CY.WidgetStdMod.FOOTER);a.queryAll(".comment_input").set("value","");}};cancelNewReplyForm=function(){if(gNewReplyHost!=null){for(var b in gNewReply.handlers){if(gNewReply.handlers[b]!=null){gNewReply.handlers[b].detach();gNewReply.handlers[b]=null;}}gNewReplyHost.overlay.get("contentBox").query(".c-reply").removeClass("displaynone");var a=gNewReplyHost.overlay.getStdModNode(CY.WidgetStdMod.FOOTER);if(!sv_loggedIn){gNewReply.val["name"]=a.query(".n_name").get("value");gNewReply.val["email"]=a.query(".n_email").get("value");}gNewReply.val["title"]=a.query(".n_title").get("value");gNewReply.val["content"]=a.query(".n_content").get("value");gNewReply.val["tags"]=a.query(".n_tags").get("value");a.set("innerHTML","");gNewReplyHost=null;}};onAddNewReplyClick=function(){if(!sv_loggedIn){var b=CY.get("#"+gNewReply.ids["nameInputId"]).get("value");gPrefs.persist("user","name",b);var a=CY.get("#"+gNewReply.ids["emailInputId"]).get("value");gPrefs.persist("user","email",a);}gSync.saveComment(gNewReply.ids["formId"]);};onCancelNewReplyClick=function(){gSync.cancelReply();};getWrapperAncestor=function(a){var b=a;while(b!=null){if(CY.DOM.hasClass(b,"c-s")){return b;}b=b.parentNode;}return null;};hasWrapperAncestor=function(a){return(getWrapperAncestor(a)!=null);};getSelectionInfo=function(){var J=null,m=null,D=0,c=0,h="";if(window.getSelection){var r=window.getSelection();if(r.rangeCount>0){var l=r.getRangeAt(0);h=l.toString();if(h!=""){var E=document.createRange();E.setStart(r.anchorNode,r.anchorOffset);E.collapse(true);var B=document.createRange();B.setEnd(r.focusNode,r.focusOffset);B.collapse(false);var I=(B.compareBoundaryPoints(2,E)==1);J=(I)?r.anchorNode.parentNode:r.focusNode.parentNode;innerStartNode=(I)?r.anchorNode:r.focusNode;m=(I)?r.focusNode.parentNode:r.anchorNode.parentNode;innerEndNode=(I)?r.focusNode:r.anchorNode;D=(I)?r.anchorOffset:r.focusOffset;c=(I)?r.focusOffset:r.anchorOffset;if(!hasWrapperAncestor(m)&&hasWrapperAncestor(J)){var z=document.createRange();z.setStart(innerStartNode,D);var b=getWrapperAncestor(J);var q=b;z.setEndAfter(q);var f=parseInt(b.id.substring("sv_".length));while(z.toString().lengthv.compareBoundaryPoints(2,l))){J=k.firstChild;D=0;m=F.lastChild;c=CY.DOM.getText(F).length;w=true;break;}}if(w){break;}}}}}E.detach();B.detach();}else{return null;}}else{return null;}}else{if(document.selection){var d=document.selection.createRange();if(d.text.length==0){return null;}var a=d.parentElement();var H=d.duplicate();var u=d.duplicate();H.collapse(true);u.collapse(false);J=H.parentElement();while(H.moveStart("character",-1)!=0){if(H.parentElement()!=J){break;}D++;}m=u.parentElement();while(u.moveEnd("character",-1)!=0){if(u.parentElement()!=m){break;}c++;}h=d.text;}}if(!hasWrapperAncestor(J)||!hasWrapperAncestor(m)){return null;}return{text:h,start:{elt:J,offset:D},end:{elt:m,offset:c}};};gNoSelectionYet=gettext("No selection yet");gFormHtml={formStart:'
    ',nameInput:gettext("Username:")+'
    ',emailInput:gettext("E-mail address:")+'
    ',titleInput:gettext("Title:")+'
    ',contentInput:gettext("Content:")+'
    ',tagsInput:gettext("Tag:")+'
    ',hidden:'',formEnd:"
    ",changeScope:'
    '+gettext("Modify comment's scope:")+'
    ',headerTitle:'
    ',currentSel:'
    '+gettext("Comment will apply to this selection:")+'
    '+gNoSelectionYet+"
    #hiddeninput#
    ",btns:'
    ',closeIcon:'      '};getHtml=function(f){ret={};ret.headerContent="";if("closeBtnId" in f){ret.headerContent+=gFormHtml.closeIcon.replace("###",f.closeBtnId);}ret.headerContent+=gFormHtml.headerTitle.replace("###",f.formTitleId);var b="";if("changeScopeInputId" in f){b=gFormHtml.changeScope.replace("###",f.changeScopeInputId);}var e="
    "+gFormHtml.hidden.replace("###",f.selectionPlaceId).replace("???","selection_place")+"
    ";var a=gFormHtml.currentSel.replace("###",f.currentSelId).replace("???",f.currentSelIdI).replace("#hiddeninput#",e);var d=gFormHtml.btns.replace("###",f.addBtnId).replace("???",f.cancelBtnId);var c=gFormHtml.formStart.replace("###",f.formId)+b+a;if("nameInputId" in f){c=c+gFormHtml.nameInput.replace("###",f.nameInputId);}if("emailInputId" in f){c=c+gFormHtml.emailInput.replace("###",f.emailInputId);}c=c+gFormHtml.titleInput.replace("###",f.titleInputId)+gFormHtml.contentInput.replace("###",f.contentInputId)+gFormHtml.tagsInput.replace("###",f.tagsInputId);c=c+gFormHtml.hidden.replace("###",f.formatInputId).replace("???","format");c=c+gFormHtml.hidden.replace("###",f.startWrapperInputId).replace("???","start_wrapper");c=c+gFormHtml.hidden.replace("###",f.endWrapperInputId).replace("???","end_wrapper");c=c+gFormHtml.hidden.replace("###",f.startOffsetInputId).replace("???","start_offset");c=c+gFormHtml.hidden.replace("###",f.endOffsetInputId).replace("???","end_offset");c=c+gFormHtml.hidden.replace("###",f.keyId).replace("???","comment_key");c=c+gFormHtml.hidden.replace("###",f.editCommentId).replace("???","edit_comment_id");c=c+d+gFormHtml.formEnd;ret.bodyContent=c;return ret;};changeFormFieldsWidth=function(d,c){var a=(c-20)+"px";var b=CY.all("#"+d+" input[type='text']");if(b!=null){b.setStyle("width",a);}b=CY.all("#"+d+" textarea");if(b!=null){b.setStyle("width",a);}};addFormErrMsg=function(j,g,d){var f=document.getElementById(j);var b,h,c,a;for(b=0,a=f.elements.length;b";var n=gFormHtml.formStart.replace("###",gNewReply.ids.formId);if(!sv_loggedIn){n=n+gFormHtml.nameInput.replace("###",gNewReply.ids.nameInputId)+gFormHtml.emailInput.replace("###",gNewReply.ids.emailInputId);}n=n+gFormHtml.titleInput.replace("###",gNewReply.ids.titleInputId)+gFormHtml.contentInput.replace("###",gNewReply.ids.contentInputId)+gFormHtml.tagsInput.replace("###",gNewReply.ids.tagsInputId);n=n+gFormHtml.hidden.replace("###",gNewReply.ids.keyInputId).replace("???","comment_key");n=n+gFormHtml.hidden.replace("###",gNewReply.ids.formatInputId).replace("???","format");n=n+gFormHtml.hidden.replace("###",gNewReply.ids.parentCommentId).replace("???","reply_to_id");var k=gFormHtml.btns.replace("###",gNewReply.ids.addBtnId).replace("???",gNewReply.ids.cancelBtnId);gNewReplyHost.overlay.setStdModContent(CY.WidgetStdMod.FOOTER,q+n+k);var p=gNewReplyHost.overlay.getStdModNode(CY.WidgetStdMod.FOOTER);var m=gDb.getComment(j.commentId);var r="Re: ";var l=(gNewReply.val.title==""||gNewReply.val.title.substring(0,r.length)==r)?r+m.title:gNewReply.val.title;if(!sv_loggedIn){p.query(".n_name").set("value",gNewReply.val.name);p.query(".n_email").set("value",gNewReply.val.email);}p.query(".n_title").set("value",l);p.query(".n_content").set("value",gNewReply.val.content);p.query(".n_tags").set("value",gNewReply.val.tags);p.query("#"+gNewReply.ids.parentCommentId).set("value",j.commentId);p.query("#"+gNewReply.ids.formatInputId).set("value",gConf.defaultCommentFormat);gNewReplyHost.overlay.get("contentBox").query(".c-reply").addClass("displaynone");gNewReply.handlers.addBtnId=CY.on("click",onAddNewReplyClick,"#"+gNewReply.ids.addBtnId);gNewReply.handlers.cancelBtnId=CY.on("click",onCancelNewReplyClick,"#"+gNewReply.ids.cancelBtnId);var o=gLayout.getTopICommentsWidth();changeFormFieldsWidth(gNewReply.ids.formId,o);};cleanNewReplyForm=function(){if(gNewReplyHost!=null){var b=gNewReplyHost.overlay.getStdModNode(CY.WidgetStdMod.FOOTER);b.queryAll(".comment_input").set("value","");}};cancelNewReplyForm=function(){if(gNewReplyHost!=null){for(var c in gNewReply.handlers){if(gNewReply.handlers[c]!=null){gNewReply.handlers[c].detach();gNewReply.handlers[c]=null;}}gNewReplyHost.overlay.get("contentBox").query(".c-reply").removeClass("displaynone");var d=gNewReplyHost.overlay.getStdModNode(CY.WidgetStdMod.FOOTER);if(!sv_loggedIn){gNewReply.val.name=d.query(".n_name").get("value");gNewReply.val.email=d.query(".n_email").get("value");}gNewReply.val.title=d.query(".n_title").get("value");gNewReply.val.content=d.query(".n_content").get("value");gNewReply.val.tags=d.query(".n_tags").get("value");d.set("innerHTML","");gNewReplyHost=null;}};onAddNewReplyClick=function(){if(!sv_loggedIn){var c=CY.get("#"+gNewReply.ids.nameInputId).get("value");gPrefs.persist("user","name",c);var d=CY.get("#"+gNewReply.ids.emailInputId).get("value");gPrefs.persist("user","email",d);}gSync.saveComment(gNewReply.ids.formId);};onCancelNewReplyClick=function(){gSync.cancelReply();};getWrapperAncestor=function(d){var c=d;while(c!=null){if(CY.DOM.hasClass(c,"c-s")){return c;}c=c.parentNode;}return null;};hasWrapperAncestor=function(b){return(getWrapperAncestor(b)!=null);};getSelectionInfo=function(){var j=null,ac=null,T=0,aj=0,af="";if(window.getSelection){var V=window.getSelection();if(V.rangeCount>0){var ad=V.getRangeAt(0);af=ad.toString();if(af!=""){var R=document.createRange();R.setStart(V.anchorNode,V.anchorOffset);R.collapse(true);var W=document.createRange();W.setEnd(V.focusNode,V.focusOffset);W.collapse(false);var K=(W.compareBoundaryPoints(2,R)==1);j=(K)?V.anchorNode.parentNode:V.focusNode.parentNode;innerStartNode=(K)?V.anchorNode:V.focusNode;ac=(K)?V.focusNode.parentNode:V.anchorNode.parentNode;innerEndNode=(K)?V.focusNode:V.anchorNode;T=(K)?V.anchorOffset:V.focusOffset;aj=(K)?V.focusOffset:V.anchorOffset;if(!hasWrapperAncestor(ac)&&hasWrapperAncestor(j)){var e=document.createRange();e.setStart(innerStartNode,T);var ak=getWrapperAncestor(j);var X=ak;e.setEndAfter(X);var ah=parseInt(ak.id.substring("sv_".length));while(e.toString().lengthN.compareBoundaryPoints(2,ad))){j=ae.firstChild;T=0;ac=Q.lastChild;aj=CY.DOM.getText(Q).length;M=true;break;}}if(M){break;}}}}}R.detach();W.detach();}else{return null;}}else{return null;}}else{if(document.selection){var ai=document.selection.createRange();if(ai.text.length==0){return null;}var al=ai.parentElement();var L=ai.duplicate();var P=ai.duplicate();L.collapse(true);P.collapse(false);j=L.parentElement();while(L.moveStart("character",-1)!=0){if(L.parentElement()!=j){break;}T++;}ac=P.parentElement();while(P.moveEnd("character",-1)!=0){if(P.parentElement()!=ac){break;}aj++;}af=ai.text;}}if(!hasWrapperAncestor(j)||!hasWrapperAncestor(ac)){return null;}return{text:af,start:{elt:j,offset:T},end:{elt:ac,offset:aj}};};gNoSelectionYet=gettext("No selection yet");gFormHtml={formStart:'
    ',nameInput:gettext("Username:")+'
    ',emailInput:gettext("E-mail address:")+'
    ',titleInput:gettext("Title:")+'
    ',contentInput:gettext("Content:")+'
    ',tagsInput:gettext("Tag:")+'
    ',hidden:'',formEnd:"
    ",changeScope:'
    '+gettext("Modify comment's scope:")+'
    ',headerTitle:'
    ',currentSel:'
    '+gettext("Comment will apply to this selection:")+'
    '+gNoSelectionYet+"
    #hiddeninput#
    ",btns:'
    ',closeIcon:'      '};getHtml=function(i){ret={};ret.headerContent="";if("closeBtnId" in i){ret.headerContent+=gFormHtml.closeIcon.replace("###",i.closeBtnId);}ret.headerContent+=gFormHtml.headerTitle.replace("###",i.formTitleId);var g="";if("changeScopeInputId" in i){g=gFormHtml.changeScope.replace("###",i.changeScopeInputId);}var j="
    "+gFormHtml.hidden.replace("###",i.selectionPlaceId).replace("???","selection_place")+"
    ";var h=gFormHtml.currentSel.replace("###",i.currentSelId).replace("???",i.currentSelIdI).replace("#hiddeninput#",j);var k=gFormHtml.btns.replace("###",i.addBtnId).replace("???",i.cancelBtnId);var l=gFormHtml.formStart.replace("###",i.formId)+g+h;if("nameInputId" in i){l=l+gFormHtml.nameInput.replace("###",i.nameInputId);}if("emailInputId" in i){l=l+gFormHtml.emailInput.replace("###",i.emailInputId);}l=l+gFormHtml.titleInput.replace("###",i.titleInputId)+gFormHtml.contentInput.replace("###",i.contentInputId)+gFormHtml.tagsInput.replace("###",i.tagsInputId);l=l+gFormHtml.hidden.replace("###",i.formatInputId).replace("???","format");l=l+gFormHtml.hidden.replace("###",i.startWrapperInputId).replace("???","start_wrapper");l=l+gFormHtml.hidden.replace("###",i.endWrapperInputId).replace("???","end_wrapper");l=l+gFormHtml.hidden.replace("###",i.startOffsetInputId).replace("???","start_offset");l=l+gFormHtml.hidden.replace("###",i.endOffsetInputId).replace("???","end_offset");l=l+gFormHtml.hidden.replace("###",i.keyId).replace("???","comment_key");l=l+gFormHtml.hidden.replace("###",i.editCommentId).replace("???","edit_comment_id");l=l+k+gFormHtml.formEnd;ret.bodyContent=l;return ret;};changeFormFieldsWidth=function(g,h){var f=(h-20)+"px";var e=CY.all("#"+g+" input[type='text']");if(e!=null){e.setStyle("width",f);}e=CY.all("#"+g+" textarea");if(e!=null){e.setStyle("width",f);}};addFormErrMsg=function(k,m,o){var n=document.getElementById(k);var e,l,p,i;for(e=0,i=n.elements.length;eb){var a=i.substring(0,(i.substring(0,b/2)).lastIndexOf(" "));var d=i.substring(i.length-b/2);var c=d.substring(d.indexOf(" "));f=a+" ... "+c;}var e=_convertSelectionFromCCToCS(h.start);var g=_convertSelectionFromCCToCS(h.end);_updateICommentFormSelection(gICommentForm,f,e,g);if(gEdit!=null){_updateICommentFormSelection(gEdit.ids,f,e,g);}positionICommentForm();}};showICommentForm=function(){removeFormErrMsg(gICommentForm.formId);if(!sv_loggedIn){if(CY.get("#"+gICommentForm.nameInputId).get("value")==""){CY.get("#"+gICommentForm.nameInputId).set("value",gPrefs.get("user","name"));}if(CY.get("#"+gICommentForm.emailInputId).get("value")==""){CY.get("#"+gICommentForm.emailInputId).set("value",gPrefs.get("user","email"));}}gIComments.hide();positionICommentForm();gICommentForm.overlay.show();CY.get("#"+gICommentForm.titleInputId).focus();};isICommentFormVisible=function(){if(gICommentForm!=null){return gICommentForm.overlay.get("visible");}return false;};positionICommentForm=function(){if(gICommentForm!=null){var b=gICommentForm.overlay;var a=b.get("boundingBox");var c=a.get("offsetHeight");var e=a.get("winHeight");var d=gICommentForm.position;if(c>e){d=[CY.WidgetPositionExt.BL,CY.WidgetPositionExt.BL];}b.set("align",{points:d});a.setX(a.getX()+gConf.iCommentLeftPadding);}};_changeIds=function(a,b){if(a.id){a.id=a.id+b;}var d=a.firstChild;while(d!=null){_changeIds(d,b);d=d.nextSibling;}};suffix=0;domDuplicate=function(a){var b=a.cloneNode(true);suffix++;_changeIds(b,"-"+suffix);return b;};getDuplicated=function(a){return document.getElementById(a.id+"-"+suffix);};logSel=function(a){log("text :"+a.text+", start id : "+a.start["elt"].id+" , start offset : "+a.start["offset"]+" , end id : "+a.end["elt"].id+"end offset : "+a.end["offset"]);};log=function(b){var a=document.getElementById("log");a.innerHTML=a.innerHTML+"
  • "+b+"
  • ";};urlEncode=function(h){if(!h){return"";}var c=[];for(var f in h){var e=h[f],b=encodeURIComponent(f);var g=typeof e;if(g=="undefined"){c.push(b,"=&");}else{if(g!="function"&&g!="object"){c.push(b,"=",encodeURIComponent(e),"&");}else{if(CY.Lang.isArray(e)){if(e.length){for(var d=0,a=e.length;de[d]){b=e[g];e[g]=e[d];e[d]=b;}return;}a=e[parseInt((g+d)/2)];e[parseInt((g+d)/2)]=e[g];e[g]=a;c=g+1;f=d;do{while(c<=f&&e[c]<=a){c++;}while(e[f]>a){f--;}if(cm[l.id]){m[l.id]=d;}}}for(var b in m){var h=this.allCommentsByDbId[b].id;var r=false;for(var k=0,c=n.length;k0){a=a.concat(this.getThreads(c[b].replies));}}return a;},_getPath:function(b,e){var a=[e];var d=e;while(d.reply_to_id!=null){d=b[d.reply_to_id];a.push(d);}return a;},getPath:function(a){return this._getPath(this.commentsByDbId,a);},getComment:function(a){return this.commentsByDbId[a];},getCommentByKey:function(a){for(var c in this.commentsByDbId){var b=this.commentsByDbId[c];if(b.key==a){return b;}}return null;},isChild:function(d,b){var c=this.commentsByDbId[d];var a=(d==b);while((!a)&&(c.reply_to_id!=null)){c=this.commentsByDbId[c.reply_to_id];a=(c.id==b);}return a;},browsingIndex:function(b){var c={};for(var a in this.ordered_comment_ids){var d=CY.Array.filter(this.ordered_comment_ids[a],function(e){return(e in this.commentsByDbId);},this);c[a]=CY.Array.indexOf(d,b);}return c;},browse:function(b,f,c){var a=this.ordered_comment_ids[b];if(a.length>0){var g=-1;if((f=="prev")||(f=="next")){for(var e=0;e=0)&&(ea.length){break;}}CY.error("internal error in db browse (could not find any filtered comment)");}return null;},computeFilterResults:function(n){var a={};if(n){for(key in n){if(key.indexOf("filter_")==0){a[key.substr("filter_".length)]=n[key];}}}else{if(gLayout.isInFrame()){a=parent.f_getFrameFilterData();}}var v=[];var w=[];var b="";if("name" in a){b=a.name;}this.filterByName(b,v,w);var p=[];var c=[];var C="";if("date" in a){C=a.date;}this.filterByDate(C,p,c);var g=[];var f=[];var t="";if("text" in a){t=a.text;}this.filterByText(t,g,f);var x=[];var m=[];var A="";if("tag" in a){A=a.tag;}this.filterByTag(A,x,m);var u=[];var e=[];var k="";if("state" in a){k=a.state;}this.filterByState(k,u,e);var d=[];var z=[];for(var y=0,j=v.length;yc){if(e.reply_to_id==null){d.push(e.id);}else{a.push(e.id);}}}},getCommentsAndRepliesCounts:function(d){var b=0;var f=0;var a=(d)?this.allComments:this.comments;var e=this.getThreads(a);for(var c=0;c0){b.showReadRepliesLnk();}else{b.hideReadRepliesLnk();}},remove:function(a){this._remove(this._getChildren(a));},close:function(a){CY.Array.each(this._getChildren(a),function(b){b.hide();});},open:function(a){CY.Array.each(this._getChildren(a),function(b){b.show();});},fetch:function(b){for(var a=0;a=0)&&e<=(this._c.length-1);){var c=this._c[e];if(c.commentId!=null&&c.isVisible()){a=a||(gDb.isChild(c.commentId,this._topActiveCommentDbId));if(a&&(!gDb.isChild(c.commentId,this._topActiveCommentDbId))){this.activate(c.commentId);return true;}}e=(d==0)?e+1:e-1;}}}return false;},browse:function(b,c){var a=c;if((c=="prev")&&!this.isAnyActive()){a="last";}if((c=="next")&&!this.isAnyActive()){a="first";}return gDb.browse(b,a,this._topActiveCommentDbId);}};gEditICommentHost=null;gEdit=null;dbgc=null;showEditForm=function(a){if(gEdit==null){gEdit={ids:{formId:CY.guid(),formTitleId:CY.guid(),nameInputId:CY.guid(),emailInputId:CY.guid(),titleInputId:CY.guid(),contentInputId:CY.guid(),tagsInputId:CY.guid(),formatInputId:CY.guid(),startWrapperInputId:CY.guid(),endWrapperInputId:CY.guid(),startOffsetInputId:CY.guid(),endOffsetInputId:CY.guid(),changeScopeInputId:CY.guid(),changeScopeInputWrapper:CY.guid(),selectionPlaceId:CY.guid(),keyId:CY.guid(),editCommentId:CY.guid(),currentSelId:CY.guid(),currentSelIdI:CY.guid(),addBtnId:CY.guid(),cancelBtnId:CY.guid()},handlers:{}};}gEditICommentHost=a;gEditICommentHost.hideContent();var c=getHtml(gEdit.ids);var b='
    '+c.headerContent+"
    ";var e='
    '+c.bodyContent+"
    ";gEditICommentHost.overlay.setStdModContent(CY.WidgetStdMod.HEADER,CY.Node.create(b),CY.WidgetStdMod.AFTER);gEditICommentHost.overlay.setStdModContent(CY.WidgetStdMod.BODY,CY.Node.create(e),CY.WidgetStdMod.AFTER);CY.get("#"+gEdit.ids["formTitleId"]).set("innerHTML",gettext("Edit comment"));var f=gDb.getComment(gEditICommentHost.commentId);CY.get("#"+gEdit.ids["editCommentId"]).set("value",f.id);CY.get("#"+gEdit.ids["keyId"]).set("value",f.key);CY.get("#"+gEdit.ids["changeScopeInputId"]+" input").set("checked",false);if(f.reply_to_id!=null){CY.get("#"+gEdit.ids["changeScopeInputId"]).addClass("displaynone");}changeScopeFormClick();CY.get("#"+gEdit.ids["nameInputId"]).set("value",f.name);CY.get("#"+gEdit.ids["emailInputId"]).set("value",f.email);if(f.logged_author){CY.get("#"+gEdit.ids["nameInputId"]).setAttribute("disabled",true);CY.get("#"+gEdit.ids["emailInputId"]).setAttribute("disabled",true);}CY.get("#"+gEdit.ids["titleInputId"]).set("value",f.title);CY.get("#"+gEdit.ids["contentInputId"]).set("value",f.content);CY.get("#"+gEdit.ids["tagsInputId"]).set("value",f.tags);CY.get("#"+gEdit.ids["formatInputId"]).set("value",gConf.defaultCommentFormat);var d=gLayout.getTopICommentsWidth();changeFormFieldsWidth(gEdit.ids["formId"],d);gEdit.handlers["addBtnId"]=CY.on("click",onEditSaveClick,"#"+gEdit.ids["addBtnId"]);gEdit.handlers["cancelBtnId"]=CY.on("click",onEditCancelClick,"#"+gEdit.ids["cancelBtnId"]);gEdit.handlers["changeScope"]=CY.on("click",onChangeScopeClick,"#"+gEdit.ids["changeScopeInputId"]);};onEditSaveClick=function(a){if(readyForAction()){gSync.editComment();}};onEditCancelClick=function(a){if(readyForAction()){gSync.cancelEdit();}};onChangeScopeClick=function(){if(readyForAction()){gSync.changeScopeFormClick();}};changeScopeFormClick=function(){var a=CY.get("#"+gEdit.ids["currentSelId"]);if(CY.get("#"+gEdit.ids["changeScopeInputId"]+" input").get("checked")){a.removeClass("displaynone");}else{a.addClass("displaynone");}};cancelEditForm=function(){if(gEditICommentHost!=null){for(var b in gEdit.handlers){if(gEdit.handlers[b]!=null){gEdit.handlers[b].detach();gEdit.handlers[b]=null;}}var a=gEditICommentHost.overlay.get("contentBox").query(".icomment-edit-body");a.get("parentNode").removeChild(a);a=gEditICommentHost.overlay.get("contentBox").query(".icomment-edit-header");a.get("parentNode").removeChild(a);gEditICommentHost.showContent();gEditICommentHost=null;}};Preferences=function(){this.prefs={};};Preferences.prototype={init:function(){this._read();},_read:function(){for(var b in gConf.defaultPrefs){this.prefs[b]={};for(var a in gConf.defaultPrefs[b]){var c=null;if(b=="user"&&(a=="name"||a=="email")){c=CY.Cookie.get("user_"+a);}else{c=CY.Cookie.getSub(b,a);}this.prefs[b][a]=(c==null)?gConf.defaultPrefs[b][a]:c;}}},persist:function(b,a,d){var c={path:"/",expires:(new Date()).setFullYear(2100,0,1)};if(b=="user"&&(a=="name"||a=="email")){CY.Cookie.set("user_"+a,d,c);}else{CY.Cookie.setSub(b,a,d,c);}this.prefs[b][a]=d;},get:function(b,a){return this.prefs[b][a];},readDefault:function(b,a){return gConf.defaultPrefs[b][a];},reset:function(a){for(var b=0;b
    '+t+'
    -X',bodyContent:'"});this.overlay.get("contentBox").addClass("c-comment");this.overlay.render("#leftcolumn");this.animation=new CY.Anim({node:this.overlay.get("boundingBox"),duration:gPrefs.get("general","animduration"),easing:CY.Easing.easeOut});this.overlay.get("contentBox").query(".c-close").on("click",this.onCloseCommentClick,this);this.overlay.get("contentBox").query(".c-moderate").on("click",this.onModerateCommentClick,this);this.overlay.get("contentBox").query(".c-state-pending").on("click",this.onPendingCommentClick,this);this.overlay.get("contentBox").query(".c-state-approved").on("click",this.onApprovedCommentClick,this);this.overlay.get("contentBox").query(".c-state-unapproved").on("click",this.onUnapprovedCommentClick,this);this.overlay.get("contentBox").query(".c-state-cancel").on("click",this.onCancelStateChangeClick,this);this.overlay.get("contentBox").query(".c-edit").on("click",this.onEditCommentClick,this);this.overlay.get("contentBox").query(".c-delete").on("click",this.onDeleteCommentClick,this);this.overlay.get("contentBox").query(".c-reply").on("click",this.onReplyCommentClick,this);this.overlay.get("contentBox").query(".c-readreplies").on("click",this.onReadRepliesCommentClick,this);this.overlay.get("contentBox").query(".icomment-header").on("mouseenter",this.onMouseEnterHeader,this);this.overlay.get("contentBox").query(".icomment-header").on("mouseleave",this.onMouseLeaveHeader,this);this.overlay.get("contentBox").on("click",this.onCommentClick,this);};IComment.prototype={onCloseCommentClick:function(a){a.halt();if(readyForAction()&&this.isVisible()){gSync.closeComment(this);}},onModerateCommentClick:function(a){a.halt();if(readyForAction()&&this.isVisible()){this.overlay.get("contentBox").query(".c-iactions").addClass("displaynone");this.overlay.get("contentBox").query(".c-state-actions").removeClass("displaynone");}},onPendingCommentClick:function(a){a.halt();if(readyForAction()&&this.isVisible()){gSync.moderateComment(this,"pending");}},onApprovedCommentClick:function(a){a.halt();if(readyForAction()&&this.isVisible()){gSync.moderateComment(this,"approved");}},onUnapprovedCommentClick:function(a){a.halt();if(readyForAction()&&this.isVisible()){gSync.moderateComment(this,"unapproved");}},onCancelStateChangeClick:function(a){a.halt();if(readyForAction()&&this.isVisible()){this.overlay.get("contentBox").query(".c-iactions").removeClass("displaynone");this.overlay.get("contentBox").query(".c-state-actions").addClass("displaynone");}},onDeleteCommentClick:function(a){a.halt();if(readyForAction()&&this.isVisible()){gSync.removeComment(this);}},onEditCommentClick:function(a){a.halt();if(readyForAction()&&this.isVisible()){gSync.showEditForm(this);}},onReplyCommentClick:function(a){a.halt();if(readyForAction()&&this.isVisible()){gSync.showReplyForm(this);}},onReadRepliesCommentClick:function(a){a.halt();if(readyForAction()&&this.isVisible()){gSync.openComment(this);}},onCommentClick:function(d){if(readyForAction()&&this.isVisible()){if(d.target.get("target")=="_blank"){var c=d.target;var g=sv_site_url+sv_text_view_show_comment_url;if(c.get("href").indexOf(g)==0){var b=(new RegExp("comment_key=([^&]*)","g")).exec(c.get("href"));if(b!=null){var a=b[1];var f=gDb.getCommentByKey(a);if(f!=null){d.halt();if(!c.hasClass("c-permalink")){checkForOpenedDialog(null,function(){gSync.showSingleComment(f);});}}}}}else{if(gShowingAllComments){if(!this._isHostingAForm()){var f=gDb.getComment(this.commentId);checkForOpenedDialog(null,function(){if(f!=null){gSync.showSingleComment(f);}});}}else{gSync.activate(this);}}}},onMouseEnterHeader:function(){if(readyForAction()&&this.isVisible()){this.overlay.get("contentBox").query(".c-permalink").removeClass("displaynone");}},onMouseLeaveHeader:function(){if(readyForAction()&&this.isVisible()){this.overlay.get("contentBox").query(".c-permalink").addClass("displaynone");}},setWidth:function(a){this.overlay.get("boundingBox").setStyle("width",a+"px");},activate:function(){this.overlay.get("boundingBox").addClass("c-focus-comment");},deactivate:function(){this.overlay.get("boundingBox").removeClass("c-focus-comment");},hide:function(){if(gIComments.isTopActive(this.commentId)){if(!gIComments.activateVisibleNext()){gIComments.deactivate();}}if(this.isVisible()){this.overlay.hide();this.overlay.blur();}},hideContent:function(){this.overlay.get("contentBox").query(".icomment-header").addClass("displaynone");this.overlay.get("contentBox").query(".icomment-body").addClass("displaynone");},showContent:function(){this.overlay.get("contentBox").query(".icomment-header").removeClass("displaynone");this.overlay.get("contentBox").query(".icomment-body").removeClass("displaynone");},isVisible:function(){return this.overlay.get("visible");},show:function(){this.hideReadRepliesLnk();return this.overlay.show();},showReadRepliesLnk:function(){this.overlay.get("contentBox").query(".c-readreplies").removeClass("displaynone");},hideReadRepliesLnk:function(){this.overlay.get("contentBox").query(".c-readreplies").addClass("displaynone");},changeModeration:function(b){var a=this.overlay.get("contentBox").query(".c-moderate");a.set("innerHTML",gettext(b.state));a.removeClass("c-state-approved");a.removeClass("c-state-pending");a.removeClass("c-state-unapproved");a.addClass("c-state-"+b.state);this.overlay.get("contentBox").query(".c-iactions").removeClass("displaynone");this.overlay.get("contentBox").query(".c-state-actions").addClass("displaynone");},isfetched:function(){return(this.commentId!=null);},unfetch:function(){this.commentId=null;},fetch:function(h){this.commentId=h.id;var b=this.overlay.get("boundingBox");if(h.start_wrapper!=-1){b.addClass("c-has-scope");b.removeClass("c-has-no-scope");}else{b.addClass("c-has-no-scope");b.removeClass("c-has-scope");}if(h.reply_to_id!=null){b.addClass("c-is-reply");}else{b.removeClass("c-is-reply");}var f=interpolate(gettext("last modified on %(date)s"),{date:h.modified_user_str},true);var k=(h.modified==h.created)?"":' * ';var i=gettext("Permalink to this comment");var n='¶ ';var j=interpolate(gettext("by %(name)s, created on %(date)s"),{name:h.name,date:h.created_user_str},true);var c='
    '+h.title+n+'
    '+j+"
    ";var d=CY.Node.create(c);var o=b.query(".c-header");if(o==null){b.query(".icomment-header").insertBefore(d,b.one(".c-iactions"));}else{o.get("parentNode").replaceChild(d,o);}var g=CY.Node.create('
    tags:'+h.tags+"
    ");var m=b.query(".c-tags");if(m==null){b.query(".icomment-header").appendChild(g);}else{m.get("parentNode").replaceChild(g,m);}if(h.tags==""){g.addClass("displaynone");}var e=CY.Node.create(''+h.content_html+"");var a=b.query(".c-content");if(a==null){b.query(".icomment-body").appendChild(e);}else{a.get("parentNode").replaceChild(e,a);}b.query(".c-permalink").set("href",sv_site_url+h.permalink);this.changeModeration(h);var l=b.queryAll(".c-content a");if(l!=null){l.setAttribute("target","_blank");}l=b.queryAll(".c-header-title a");if(l!=null){l.setAttribute("target","_blank");}this.permAdapt(h);},permAdapt:function(e){var b=this.overlay.get("contentBox").query(".c-delete");if(b){if(!e.can_delete){b.addClass("displaynone");}else{b.removeClass("displaynone");}}var a=this.overlay.get("contentBox").query(".c-edit");if(a){if(!e.can_edit){a.addClass("displaynone");}else{a.removeClass("displaynone");}}var d=this.overlay.get("contentBox").query(".c-reply");if(d){if(!hasPerm("can_create_comment")){d.addClass("displaynone");}else{d.removeClass("displaynone");}}var c=this.overlay.get("contentBox").query(".c-moderate");if(c){if(!e.can_moderate){c.addClass("displaynone");}else{c.removeClass("displaynone");}}},setThreadPad:function(a){this.overlay.get("contentBox").query(".yui-widget-hd").setStyle("paddingLeft",a+"px");this.overlay.get("contentBox").query(".yui-widget-bd").setStyle("paddingLeft",a+"px");},setPosition:function(b){var a=this.overlay.get("boundingBox");a.setStyle("opacity",1);a.setXY(b);},getPosition:function(b){var a=this.overlay.get("boundingBox");return a.getXY();},onAnimationEnd:function(){if(!CY.Lang.isUndefined(this["animation-handle"])&&!CY.Lang.isNull(this["animation-handle"])){this["animation-handle"].detach();this["animation-handle"]=null;}gIComments.signalAnimationEnd();if(gIComments.animationsEnded()){gIComments.whenAnimationsEnd();}},setAnimationToPosition:function(b){var a=this.overlay.get("boundingBox");if(gPrefs.get("general","animduration")<0.011){a.setXY(b);}this.animation.set("to",{xy:b});this.animation.set("duration",gPrefs.get("general","animduration"));this["animation-handle"]=this.animation.on("end",this.onAnimationEnd,this);return this.animation;},setWidth:function(b){var a=this.overlay.get("boundingBox");a.setStyle("width",b+"px");},getHeight:function(){return this.overlay.get("boundingBox").get("offsetHeight");},scrollIntoView:function(){if(!this.overlay.get("contentBox").inViewportRegion()){this.overlay.get("contentBox").scrollIntoView(true);}},_isHostingAForm:function(){return(this.isVisible()&&((gNewReplyHost!=null&&gNewReplyHost==this)||(gEditICommentHost!=null&&gEditICommentHost==this)));}};_afterDlg=function(d){var a=d[0];var c=d[1];var b=d[2];a.call(c,b);};_abortNewCommentConfirmed=function(a){if(isICommentFormVisible()){if(gLayout.isInFrame()){gSync.hideICommentForm({fn:function(){_afterDlg(a);}});gSync.resume();}}};_abortNewReplyConfirmed=function(a){if(gNewReplyHost!=null){if(gLayout.isInFrame()){cancelNewReplyForm();_afterDlg(a);}}};_abortNewEditConfirmed=function(a){if(gEditICommentHost!=null){if(gLayout.isInFrame()){cancelEditForm();_afterDlg(a);}}};checkForOpenedDialog=function(e,b,d,c){var a=[];if(e!=null){a=CY.Array.map(gDb.getThreads([gDb.getComment(e.commentId)]),function(f){return f.id;});}if(isICommentFormVisible()||(gNewReplyHost!=null&&(e==null||CY.Array.indexOf(a,gNewReplyHost.commentId)!=-1))||(gEditICommentHost!=null&&(e==null||CY.Array.indexOf(a,gEditICommentHost.commentId)!=-1))){if(gLayout.isInFrame()){if(isICommentFormVisible()){parent.f_yesNoDialog(gettext("New comment will be canceled, continue?"),gettext("Warning"),null,null,null,_abortNewCommentConfirmed,this,[b,d,c]);}else{if(gNewReplyHost!=null){parent.f_yesNoDialog(gettext("Started reply will be canceled, continue?"),gettext("Warning"),null,null,null,_abortNewReplyConfirmed,this,[b,d,c]);}else{if(gEditICommentHost!=null){parent.f_yesNoDialog(gettext("Started comment edition will be canceled, continue?"),gettext("Warning"),null,null,null,_abortNewEditConfirmed,this,[b,d,c]);}}}}}else{b.call(d,[]);}};hasPerm=function(a){return(-1!=CY.Array.indexOf(sv_user_permissions,a));};gShowingAllComments=false;Sync=function(){this._q=null;this._iPreventClick=false;};Sync.prototype={init:function(a){this._q=new CY.AsyncQueue();},setPreventClickOn:function(){CY.log("setPreventClickOn !");if(gLayout.isInFrame()){parent.f_interfaceFreeze();}this._iPreventClick=true;},setPreventClickOff:function(){CY.log("setPreventClickOff !");if(gLayout.isInFrame()){parent.f_interfaceUnfreeze();}this._iPreventClick=false;},removeCommentRet:function(b){var d=b.successfull;var a=(d)?b.failure["iComment"]:b.success["iComment"];if(d){var c=b.returned["filterData"];if(gLayout.isInFrame()){parent.f_updateFilterData(c);}var f=gIComments.getTopPosition()[1];var e=gDb.getComment(a.commentId);this._q.add(function(){unpaintCommentScope(e);gIComments.close(e.id);gIComments.remove(e.id);if(e.reply_to_id!=null){gIComments.refresh(e.reply_to_id);}gDb.del(e);if(gLayout.isInFrame()){if(gDb.comments.length==0&&gDb.allComments.length!=0){parent.f_enqueueMsg(gettext("no filtered comments left"));parent.resetFilter();}else{var g=gDb.computeFilterResults();updateFilterResultsCount(g.nbDiscussions,g.nbComments,g.nbReplies);}}});this._animateTo(f);}this._q.add({fn:CY.bind(this.setPreventClickOff,this)});this.resume();},moderateCommentRet:function(c){var e=c.successfull;var a=(e)?c.failure["iComment"]:c.success["iComment"];if(e){var b=c.returned;var f=b.comment;gDb.upd(f);var d=gLayout.isInFrame()&&!parent.f_isFrameFilterFieldsInit();if(d){parent.resetFilter();this._showSingleComment(f);}else{a.changeModeration(f);}}this._q.add({fn:CY.bind(this.setPreventClickOff,this)});this.resume();},saveCommentRet:function(h){var i=h.successfull;if(i){var l=h.success["formId"];var g=h.returned;removeFormErrMsg(l);if("errors" in g){var k=g.errors;for(var d in k){addFormErrMsg(l,d,k[d]);}this._animateToTop();}else{var b=function(){return(gNewReply!=null)&&(l==gNewReply.ids["formId"]);};var c=function(){return(gICommentForm!=null)&&(l==gICommentForm.formId);};var e=function(){return(gEdit!=null)&&(l==gEdit.ids["formId"]);};if(c()){this.hideICommentForm(cleanICommentForm());}else{if(e()){this._hideEditForm();}else{if(b()){this._hideNewReplyForm();}}}if("ask_for_notification" in g){if(g.ask_for_notification){parent.f_yesNoDialog(gettext("Do you want to be notified of all replies in all discussions you participated in?"),gettext("Reply notification"),function(){var m={method:"POST",data:urlEncode({fun:"ownNotify",key:sv_key,version_key:sv_version_key,email:g.email,active:false})};CY.io(sv_client_url,m);},this,null,function(){var m={method:"POST",data:urlEncode({fun:"ownNotify",key:sv_key,version_key:sv_version_key,email:g.email,active:true})};CY.io(sv_client_url,m);},this,null);}}if("comment" in g){var f=g.comment;gDb.upd(f);var a=gLayout.isInFrame()&&!parent.f_isFrameFilterFieldsInit();if(a){parent.resetFilter();}else{if(f.reply_to_id==null){unpaintCommentScope(f);paintCommentScope(f);}}var j=g.filterData;if(gLayout.isInFrame()){parent.f_updateFilterData(j);updateResetFilterResultsCount();}if(b()){if(!a){this._insertReply(f);}}else{this._showSingleComment(f);}}else{this._animateToTop();}}}else{this._q.add({id:"expl",fn:function(){CY.log("in example .........");}});this._q.promote("expl");}this._q.add({fn:CY.bind(this.setPreventClickOff,this)});this.resume();},example:function(){CY.log("in example .........");},moderateComment:function(a,b){var c=gDb.getComment(a.commentId);this._q.add({fn:CY.bind(this.setPreventClickOn,this)},{autoContinue:false,fn:CY.bind(doExchange,null,"editComment",{comment_key:c.key,state:b},null,this.moderateCommentRet,this,{iComment:a},gettext("could not save comment"))}).run();},_saveComment:function(b,a){this._q.add({fn:CY.bind(this.setPreventClickOn,this)},{autoContinue:false,fn:CY.bind(doExchange,null,b,{},a,this.saveCommentRet,this,{formId:a},gettext("could not save comment"))}).run();},editComment:function(){this._saveComment("editComment",gEdit.ids["formId"]);},saveComment:function(a){this._saveComment("addComment",a);},removeComment:function(a){checkForOpenedDialog(a,function(){if(gLayout.isInFrame()){parent.f_yesNoDialog(gettext("Are you sure you want to delete this comment?"),gettext("Warning"),function(){this.animateToTop();},this,null,function(){var b=gDb.getComment(a.commentId);this._q.add({fn:CY.bind(this.setPreventClickOn,this)},{autoContinue:false,fn:CY.bind(doExchange,null,"removeComment",{comment_key:b.key},null,this.removeCommentRet,this,{iComment:a},gettext("could not remove comment"))}).run();},this,null);}},this,null);},resume:function(b,a){this._q.run();},resetAutoContinue:function(a){this._q.getCallback(a).autoContinue=true;},hideICommentForm:function(a){this._q.add({autoContinue:false,fn:CY.bind(gICommentForm.animationHide.run,gICommentForm.animationHide)});if(a){this._q.add(a);}},showCommentForm:function(a){checkForOpenedDialog(null,function(){this._q.add({fn:CY.bind(this.setPreventClickOn,this)});this._q.add({fn:function(){if(a==null){var b=getSelectionInfo();updateICommentFormSelection(b);}showICommentForm(a);}});this._q.add({autoContinue:false,fn:CY.bind(gICommentForm.animationShow.run,gICommentForm.animationShow)},{fn:CY.bind(this.setPreventClickOff,this)}).run();},this,null);},showEditForm:function(a){checkForOpenedDialog(null,function(){this._q.add({fn:CY.bind(this.setPreventClickOn,this)});this._q.add({fn:function(){showEditForm(a);}});this._animateToTop();this._q.add({fn:CY.bind(this.setPreventClickOff,this)});this._q.run();},this,null);},showReplyForm:function(a){checkForOpenedDialog(null,function(){this._q.add({fn:CY.bind(this.setPreventClickOn,this)});this._q.add({fn:function(){instanciateNewReplyForm(a);}});this._animateToTop();this._q.add({fn:CY.bind(this.setPreventClickOff,this)});this._q.run();},this,null);},cancelICommentForm:function(){this._q.add({fn:CY.bind(this.setPreventClickOn,this)});this.hideICommentForm();this._q.add({fn:CY.bind(this.setPreventClickOff,this)});this._q.run();},cancelEdit:function(){this._q.add({fn:CY.bind(this.setPreventClickOn,this)});this._q.add({fn:function(){cancelEditForm();}});this._animateToTop();this._q.add({fn:CY.bind(this.setPreventClickOff,this)});this._q.run();},cancelReply:function(){this._q.add({fn:CY.bind(this.setPreventClickOn,this)});this._q.add({fn:function(){cancelNewReplyForm();}});this._animateToTop();this._q.add({fn:CY.bind(this.setPreventClickOff,this)});this._q.run();},changeScopeFormClick:function(){this._q.add({fn:CY.bind(this.setPreventClickOn,this)});this._q.add({fn:function(){changeScopeFormClick();}});this._animateToTop();this._q.add({fn:CY.bind(this.setPreventClickOff,this)});this._q.run();},_hideNewReplyForm:function(){this._q.add({fn:function(){cleanNewReplyForm();cancelNewReplyForm();}});},_hideEditForm:function(){this._q.add({fn:function(){cancelEditForm();}});},_insertReply:function(a){this._q.add({fn:function(){var g=gDb.getComment(a.reply_to_id);var e=gDb.getThreads([g]);var c=e[e.length-2];var d=gIComments.insertAfter(c,a);var h=gIComments.getPosition(a.reply_to_id);d.setPosition(h);var b=gDb.getPath(a);var f=b[b.length-1];if(gIComments.isTopActive(f.id)){d.activate();}d.show();}});this._animateToTop();},_showSingleComment:function(d){if(d!=null){var c=gDb.getPath(d);var b=c[c.length-1];var a=0;if(d.start_wrapper!=-1){a=CY.get(".c-id-"+b.id).getY();}else{a=CY.get("document").get("scrollTop");}this._showComments([b.id],a,false);if(b.replies.length>0){this._animateTo(a);}}},showSingleComment:function(a){this._q.add({fn:CY.bind(this.setPreventClickOn,this)});this._showSingleComment(a);this._q.add({fn:CY.bind(this.setPreventClickOff,this)});this._q.run();},browse:function(a,b){var c=gIComments.browse(a,b);if(c!=null){this.showSingleComment(c);}},_showComments:function(c,b,a){this._q.add({fn:function(){gShowingAllComments=a;gIComments.hide();var d=CY.Array.map(c,function(g){return gDb.getComment(g);});var f=gDb.getThreads(d);gIComments.fetch(f);if(c.length>0){if(a){CY.get("document").set("scrollTop",0);}else{gIComments.activate(c[0]);var e=CY.get(".c-id-"+c[0]);if(e&&!e.inViewportRegion()){e.scrollIntoView(true);}}}gIComments.setPosition([gConf.iCommentLeftPadding,b]);gIComments.show();}});},_animateTo:function(a){this._q.add({fn:function(){gIComments.setAnimationToPositions(a);}},{id:"animationRun",autoContinue:false,fn:CY.bind(gIComments.runAnimations,gIComments)});},_animateToTop:function(){var a=gIComments.getTopPosition();if(a!=null){this._animateTo(a[1]);}},animateToTop:function(){this._q.add({fn:CY.bind(this.setPreventClickOn,this)});this._animateToTop();this._q.add({fn:CY.bind(this.setPreventClickOff,this)});this._q.run();},showAllComments:function(){checkForOpenedDialog(null,function(){gShowingAllComments=true;var a=CY.Array.map(gDb.comments,function(b){return b.id;});this.showComments(a,[0,0],true);},this,null);},showScopeRemovedComments:function(){checkForOpenedDialog(null,function(){gShowingAllComments=true;var b=CY.Array.filter(gDb.comments,function(c){return(c.start_wrapper==-1);});var a=CY.Array.map(b,function(d){return d.id;});this.showComments(a,[0,0],true);},this,null);},showComments:function(c,b,a){checkForOpenedDialog(null,function(){this._q.add({fn:CY.bind(this.setPreventClickOn,this)});this._showComments(c,b[1],a);this._animateTo(b[1]);this._q.add({fn:CY.bind(this.setPreventClickOff,this)});this._q.run();},this,null);},openComment:function(a){this._q.add({fn:CY.bind(this.setPreventClickOn,this)});var b=gIComments.getTopPosition()[1];this._q.add({fn:function(){gIComments.open(a.commentId);gIComments.refresh(a.commentId);}});this._animateTo(b);this._q.add({fn:CY.bind(this.setPreventClickOff,this)});this._q.run();},closeComment:function(a){checkForOpenedDialog(a,function(){this._q.add({fn:CY.bind(this.setPreventClickOn,this)});var b=gIComments.getTopPosition()[1];this._q.add({fn:function(){var c=gDb.getComment(a.commentId);gIComments.close(a.commentId);if(c.reply_to_id!=null){gIComments.refresh(c.reply_to_id);}}});this._animateTo(b);this._q.add({fn:CY.bind(this.setPreventClickOff,this)});this._q.run();},this,null);},activate:function(a){gIComments.activate(a.commentId);}};readyForAction=function(){return !gSync._iPreventClick;};paintCommentScope=function(b){if(b.reply_to_id==null&&b.start_wrapper!=-1){var a={start:{elt:document.getElementById("sv_"+b.start_wrapper),offset:b.start_offset},end:{elt:document.getElementById("sv_"+b.end_wrapper),offset:b.end_offset}};if(document.getElementById("sv_"+b.start_wrapper)==null){warn_server({from:"paintCommentScope",start_wrapper:b.start_wrapper});}else{if(document.getElementById("sv_"+b.end_wrapper)==null){warn_server({from:"paintCommentScope",end_wrapper:b.end_wrapper});}else{a.start=_convertSelectionFromCSToCC(a.start);a.end=_convertSelectionFromCSToCC(a.end);renderComment(a,b.id);}}}};getCommentIdsFromClasses=function(b){var a=[];var e=b.className.split(" ");for(var d=0,c=e.length;d=d.offset){a.elt=e;a.offset=d.offset-b;break;}e=e.nextSibling;}return a;};unpaintCommentScope=function(k){var j=k.id;var r="c-id-"+j;var m=[];var t=CY.all("."+r);if(t!=null){for(var h=0,d=t.size();h0){checkForOpenedDialog(null,function(){gSync.showComments(a,[f.pageX,f.pageY],false);});}}}}};gLastScrollTime=null;checkForAlignement=function(){var a=(new Date()).getTime();if((gLastScrollTime!=null)&&(a-gLastScrollTime)>200){positionICommentForm();gLastScrollTime=null;}};onFrameScroll=function(){gLastScrollTime=(new Date()).getTime();};browse=function(a,b){gSync.browse(a,b);};initialConnect=function(){CY.on("mouseup",onTextMouseUp,"#textcontainer");gTimer=CY.Lang.later(200,this,checkForAlignement,[],true);CY.on("scroll",onFrameScroll,window,this,true);CY.on("resize",onFrameScroll,window,this,true);};preventLinksInText=function(){var a=function(c){c.preventDefault();var b=c.target;while(b!=null&&b.get("href")==null){b=b.get("parentNode");}if(b!=null&&b.get("href")!=null){window.open(b.get("href"));}};CY.all("#textcontainer a").on("click",a);};onDomReady=function(b){preventLinksInText();var a=new CY.AsyncQueue();a.add({fn:function(){if(gLayout.isInComentSite()){parent.toInitialSize();}if(sv_withComments){instanciateICommentForm();}},timeout:5},{fn:function(){gGETValues=CY.JSON.parse(sv_get_params);CY.get("#maincontainer").setStyle("display","block");CY.get("#textcontainer").setStyle("display","block");var e=(sv_withComments)?gPrefs.get("layout","comments_col_width"):0;var d=sliderValToPx(e);gLayout.setLeftColumnWidth(d);if(gLayout.isInFrame()){parent.f_initFrame();parent.f_layoutFrames();if(sv_withComments){parent.f_fillTopToolbar();if(hasPerm("can_create_comment")){parent.$("#add_comment_btn").removeClass("initially_hidden");}parent.f_fillFilterTab();parent.f_fillPreferencesTab();var c=CY.JSON.parse(sv_filter_data);parent.f_updateFilterData(c);parent.f_setFilterValue(gGETValues);}parent.f_fillTextPreferencesTab();}if(gLayout.isInComentSite()){parent.$("#c_fullscreen_btn").show();}else{parent.$("#c_fullscreen_btn").hide();}},timeout:5},{fn:function(){if(sv_withComments){reinit(gGETValues);initialConnect();}},timeout:5},{fn:function(){if(gLayout.isInFrame()){parent.f_interfaceUnfreeze();parent.f_removeLoadingMsg();}if("comment_key" in gGETValues){var c=gGETValues.comment_key;var f=gDb.getCommentByKey(c);if(f!=null){var e=gDb.getPath(f);var d=e[e.length-1];gSync.showSingleComment(d);}}}});a.run();};c_persistPreference=function(b,a,c){gPrefs.persist(b,a,c);};c_readDefaultPreference=function(b,a){return gConf.defaultPrefs[b][a];};c_readPreference=function(b,a){return gPrefs.get(b,a);};c_resetPreferences=function(a){gPrefs.reset(a);};c_applyTextStyle=function(a){CY.use(a);};sliderValToPx=function(d){var a=CY.DOM.winWidth();if(gLayout.isInFrame()){a=parent.$(parent).width();}var b=d/100;b=Math.min(b,gConf.sliderFixedMin);b=Math.max(b,gConf.sliderFixedMax);var c=b*a;return Math.floor(c);};c_setCommentsColWidth=function(c){var a=sliderValToPx(c);gLayout.setLeftColumnWidth(a);var b=gLayout.getTopICommentsWidthFromWidth(a);gIComments.setWidth(b);gICommentForm.overlay.get("boundingBox").setStyle("width",b+"px");changeFormFieldsWidth(gICommentForm.formId,b);if(gNewReply){changeFormFieldsWidth(gNewReply.ids["formId"],b);}if(gEdit){changeFormFieldsWidth(gEdit.ids["formId"],b);}}; \ No newline at end of file diff -r f2ba05546abc -r 36165e7cd1f0 src/cm/media/js/client/c_icomment.js --- a/src/cm/media/js/client/c_icomment.js Wed Jan 20 20:45:52 2010 +0100 +++ b/src/cm/media/js/client/c_icomment.js Wed Jan 20 22:32:59 2010 +0100 @@ -26,7 +26,7 @@ var del = gettext("delete") ; var close = gettext("close") ; var showScope = gettext("show scope") ; - var scopeRemoved = gettext("Comment is detached : it was created on a previous version and text it applied to has been modified or removed.") ; + var scopeRemoved = gettext("Comment is detached: it was created on a previous version and text it applied to has been modified or removed.") ; // no header, no body yet this.overlay = new CY.Overlay( { diff -r f2ba05546abc -r 36165e7cd1f0 src/cm/media/js/client/c_sync.js --- a/src/cm/media/js/client/c_sync.js Wed Jan 20 20:45:52 2010 +0100 +++ b/src/cm/media/js/client/c_sync.js Wed Jan 20 22:32:59 2010 +0100 @@ -127,7 +127,7 @@ if ("ask_for_notification" in ret) { if (ret['ask_for_notification']) { // TODO ask for notification ...or use AUTO_CONTRIB ? - parent.f_yesNoDialog(gettext("Do you want to subscribe to all replies notifications in discussions you participated in?"), gettext("Follow up"), + parent.f_yesNoDialog(gettext("Do you want to be notified of all replies in all discussions you participated in?"), gettext("Reply notification"), function() { // special case : no waiting for the return, no error check, nothing ! var cfg = { method: "POST", diff -r f2ba05546abc -r 36165e7cd1f0 src/cm/media/js/site/text_edit.js --- a/src/cm/media/js/site/text_edit.js Wed Jan 20 20:45:52 2010 +0100 +++ b/src/cm/media/js/site/text_edit.js Wed Jan 20 22:32:59 2010 +0100 @@ -6,7 +6,8 @@ var new_content = $('#id_content').val() var new_format = $('#id_format').val() - + var mess = gettext( 'Should these comments be detached (i.e. kept with no scope) or removed from new version?') ; + if (commentsKept) { var pre_edit_url = tb_conf['pre_edit_url'] ; @@ -27,7 +28,7 @@ '%(nb_comments)s comments apply to text that was modified.', nb_removed) ; message += '
    ' ; - message += gettext( 'Should comments be kept with no scope or entirely removed from new version?') ; + message += mess ; message = interpolate(message,{'nb_comments':nb_removed}, true) ; $('#remove_scope_choice_dlg').html(message) ; @@ -46,7 +47,7 @@ message += '
    ' ; message += gettext( '(We suggest you create a new version)') ; message += '
    ' ; - message += gettext( 'Should comments be kept with no scope or entirely removed?') ; + message += mess ; message = interpolate(message,{'nb_comments':nb_removed}, true) ; $('#remove_scope_choice_dlg').html(message) ; diff -r f2ba05546abc -r 36165e7cd1f0 src/cm/templates/site/help.html --- a/src/cm/templates/site/help.html Wed Jan 20 20:45:52 2010 +0100 +++ b/src/cm/templates/site/help.html Wed Jan 20 22:32:59 2010 +0100 @@ -68,8 +68,8 @@
    Roles are predefined sets of permissions.
    Your text will not be available by public vistors before anonymous users are given a role on the text.
    -
    Local role
    -
    A local role is a role that is set for a specific user on a specific text. It can be used to override a possibly existing workspace-level role or to give a user a role on a text (and not on every text in the workspace).
    +
    Text role
    +
    A text role is a role that is set for a specific user on a specific text. It can be used to override a possibly existing workspace-level role or to give a user a role on a text (and not on every text in the workspace).
    Role model
    A role model is a role set useful in a specific use case
    diff -r f2ba05546abc -r 36165e7cd1f0 src/cm/templates/site/text_share.html --- a/src/cm/templates/site/text_share.html Wed Jan 20 20:45:52 2010 +0100 +++ b/src/cm/templates/site/text_share.html Wed Jan 20 22:32:59 2010 +0100 @@ -84,8 +84,8 @@ {% up_down user__username %}{% blocktrans %}User{% endblocktrans %}{% endup_down %} - {% blocktrans %}Workspace role{% endblocktrans %} - {% up_down role__name %}{% blocktrans %}Local role{% endblocktrans %}{% endup_down %} + {% blocktrans %}Workspace role{% endblocktrans %} + {% up_down role__name %}{% blocktrans %}Text role{% endblocktrans %}{% endup_down %} @@ -98,7 +98,7 @@ {% include "site/macros/user_actions.html" %} - {% if userrole.role and user.get_profile.global_userrole.role %}{% endif %} + {% if userrole.role and user.get_profile.global_userrole.role %}{% endif %} {% if user.get_profile.global_userrole.role %}{{ user.get_profile.global_userrole.role.name_i18n}}{% else %}-{% endif %} diff -r f2ba05546abc -r 36165e7cd1f0 src/cm/templates/site/text_view_comments.html --- a/src/cm/templates/site/text_view_comments.html Wed Jan 20 20:45:52 2010 +0100 +++ b/src/cm/templates/site/text_view_comments.html Wed Jan 20 22:32:59 2010 +0100 @@ -31,8 +31,8 @@ - - + @@ -102,7 +102,7 @@ {% else %} - + {% endif %} diff -r f2ba05546abc -r 36165e7cd1f0 src/cm/templates/site/text_view_frame.html --- a/src/cm/templates/site/text_view_frame.html Wed Jan 20 20:45:52 2010 +0100 +++ b/src/cm/templates/site/text_view_frame.html Wed Jan 20 22:32:59 2010 +0100 @@ -36,7 +36,7 @@ {% else %} - + {% endif %}