Changeset 4472


Ignore:
Timestamp:
05/20/11 12:33:48 (13 years ago)
Author:
airton
Message:

Ticket #1820 - Corrigido o envio de mensagem com imagem no corpo do email - r4450

Location:
sandbox/2.2.0.2/expressoMail1_2/js
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • sandbox/2.2.0.2/expressoMail1_2/js/main.js

    r4457 r4472  
    17741774        { 
    17751775 
    1776                 RichTextEditor.saveFlag = -1; 
     1776                RichTextEditor.saveFlag = 0; 
    17771777                if (! data.append) 
    17781778                        write_msg('ERROR saving your message.'); 
     
    17941794        else 
    17951795        { 
    1796                 RichTextEditor.saveFlag = 1; 
    17971796                openTab.imapUid[border_id] = data.msg_no; 
    17981797                openTab.imapBox[border_id] = data.folder_id; 
     
    18931892                watch_changes_in_msg(border_id); 
    18941893                write_msg(get_lang('Your message was save as draft in folder %1.', lang_folder(folder_name))); 
     1894                setTimeout( function(){ RichTextEditor.saveFlag = 1; }, 1000 ); 
    18951895        }                
    18961896} 
  • sandbox/2.2.0.2/expressoMail1_2/js/rich_text_editor.js

    r4309 r4472  
    467467        RichTextEditor.saveFlag = 0; // See if save function finished 
    468468        var save_link = document.getElementById("save_message_options_"+id); 
    469         //save_link.onclick = function () {}; 
    470469        save_msg(id,true); 
    471         setTimeout("RichTextEditor.insertImgHtml("+id+")",1000); 
    472 } 
    473  
    474 cRichTextEditor.prototype.insertImgHtml = function (id){ 
    475         if (RichTextEditor.saveFlag == 0) 
    476                 setTimeout("RichTextEditor.insertImgHtml("+id+")",500); 
     470        RichTextEditor.insertImgHtml(id);  
     471}  
     472                  
     473                cRichTextEditor.prototype.insertImgHtml = function (id)  
     474                {  
     475                        if ( RichTextEditor.saveFlag == 0 )  
     476                        {  
     477                            setTimeout( function(){ RichTextEditor.insertImgHtml(id); },1000 );  
     478                        }  
    477479        else 
    478                 if (RichTextEditor.saveFlag == 1) 
    479                 { 
    480                         this.editorCommand('Image', './inc/show_embedded_attach.php?msg_folder=INBOX/'+draftsfolder+'&msg_num='+openTab.imapUid[id]+'&msg_part='+(openTab.countFile[id]+1)); 
    481                         // this.editorCommand('Image', '.inc/gotodownload.php?msg_folder="+msg_folder+"&msg_number="+msg_number+"&idx_file="+idx_file+"&msg_part="+msg_part+params')); 
    482                         openTab.toPreserve[id] = true; 
    483                         save_msg(id,true); 
    484                 } 
    485 } 
     480                {  
     481                    if ( RichTextEditor.saveFlag == 1 )  
     482                    {  
     483                        var folderNameDraft = "INBOX" + cyrus_delimiter + draftsfolder;  
     484                        this.editorCommand('Image', './inc/show_embedded_attach.php?msg_folder=' + folderNameDraft + '&msg_num='+openTab.imapUid[id]+'&msg_part='+(openTab.countFile[id]+1)); 
     485                                        openTab.toPreserve[id] = true; 
     486                                        save_msg(id,true); 
     487                                } 
     488} 
     489} 
     490 
    486491 
    487492cRichTextEditor.prototype.insertTableHtml = function (){ 
     
    574579                form_upload.style.left = "5px"; 
    575580                form_upload.name = get_lang("Upload File"); 
    576                 form_upload.style.width = "450px"; 
    577                 form_upload.style.height = "75px"; 
     581                form_upload.style.width = "550px"; 
     582                form_upload.style.height = "100px"; 
    578583                form_upload.innerHTML = get_lang('Select the desired image file')+':<br>'+ 
    579                                                                 '<input name="image_at" maxlength="255" size="40" id="inputFile_img" type="file"><br>' + 
     584                                                                '<input name="image_at" maxlength="255" size="40" id="inputFile_img" type="file"><br/><br/>' + 
    580585                                                                '<input title="' + get_lang('Include') + '"  value="' + get_lang('Include') + '"' + 'type="button" onclick="RichTextEditor.addInputFile();">&nbsp;' + 
    581586                                                                '<input title="' + get_lang('Close') + '"  value="' + get_lang('Close') + '"' + 
Note: See TracChangeset for help on using the changeset viewer.