Dotclear

Changeset 1256:c4a9f61c4cd2


Ignore:
Timestamp:
08/01/13 17:50:58 (11 years ago)
Author:
akewea
Branch:
ticket#1422
Children:
1257:ca39ff0aceae, 1405:4767c2d94902
Message:

ticket#1422: add confirm on post format change.

Files:
4 edited

Legend:

Unmodified
Added
Removed
  • admin/js/_post.js

    r1140 r1256  
    7979          // Get document format and prepare toolbars 
    8080          var formatField = $('#post_format').get(0); 
     81          var last_post_format = $(formatField).val(); 
    8182          $(formatField).change(function() { 
    82                excerptTb.switchMode(this.value); 
    83                contentTb.switchMode(this.value); 
     83               // Confirm post format change 
     84               if(window.confirm(dotclear.msg.confirm_change_post_format_noconvert)){ 
     85                    excerptTb.switchMode(this.value); 
     86                    contentTb.switchMode(this.value); 
     87                    last_post_format = $(this).val(); 
     88               }else{ 
     89                    // Restore last format if change cancelled 
     90                    $(this).val(last_post_format); 
     91               } 
    8492          }); 
    8593           
  • inc/admin/lib.dc.page.php

    r1188 r1256  
    476476          self::jsVar('dotclear.msg.confirm_change_post_format', 
    477477               __('You have unsaved changes. Switch post format will loose these changes. Proceed anyway?')). 
     478          self::jsVar('dotclear.msg.confirm_change_post_format_noconvert', 
     479               __("Warning: post format change will not convert existing content. You will need to apply new format by yourself. Proceed anyway?")). 
    478480          self::jsVar('dotclear.msg.load_enhanced_uploader', 
    479481               __('Loading enhanced uploader, please wait.')). 
  • locales/en/main.po

    r1039 r1256  
    21542154msgstr "" 
    21552155 
     2156msgid "Warning: post format change will not convert existing content. You will need to apply new format by yourself. Proceed anyway?" 
     2157msgstr "" 
     2158 
    21562159msgid "Loading enhanced uploader, please wait." 
    21572160msgstr "" 
  • locales/fr/main.po

    r1250 r1256  
    22642264msgstr "Vous avez des modifications non sauvegardées. Changer de format vous fera perdre ces modifications. Continuer ?" 
    22652265 
     2266msgid "Warning: post format change will not convert existing content. You will need to apply new format by yourself. Proceed anyway?" 
     2267msgstr "Attention : le changement de syntaxe ne transformera pas les balises des contenus déjà saisis. Pensez à les réadapter après cette opération. Confirmez-vous ce changement de syntaxe ?" 
     2268 
    22662269msgid "Loading enhanced uploader, please wait." 
    22672270msgstr "Chargement de l'interface avancée." 
Note: See TracChangeset for help on using the changeset viewer.

Sites map