Changeset 2714 for trunk/expressoMail1_2/js/jscode/main.js
- Timestamp:
- 05/06/10 09:12:42 (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/expressoMail1_2/js/jscode/main.js
r2656 r2714 290 290 if (typeof(msg_info) != 'object') 291 291 alert(get_lang("Error in show_msg param is not object")); 292 292 293 293 if (msg_info.status_get_msg_info == 'false') 294 294 { … … 296 296 return; 297 297 } 298 299 298 var handler_sendNotification = function(data){ 300 299 if (data) … … 303 302 write_msg(get_lang("Error in SMTP sending read confirmation.")); 304 303 }; 305 304 306 305 if(msg_info.source) 307 306 { 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 307 // Abrindo um e-mail criptografado 308 // Verifica se existe o objeto applet 309 if (!Element('cert_applet')){ 310 // se não existir, mostra mensagem de erro. 311 write_msg(get_lang('The preference "%1" isn\'t enabled.', get_lang('Enable digitally sign/cipher the message?'))); 312 } else { 313 // se existir prepara os dados para serem enviados e chama a 314 // operação na applet 315 316 expresso.connector.showProgressBar(); 317 318 // if ((msg_info.DispositionNotificationTo) && ((msg_info.Unseen == 'U') || (msg_info.Recent == 'N'))){ 319 /* var confNotification = confirm(get_lang("The sender waits your notification of reading. Do you want to confirm this?"), ""); 320 if (confNotification)*/ 321 // cExecute ("expressoMail1_2.imap_functions.send_notification¬ificationto="+msg_info.DispositionNotificationTo+"&subject="+url_encode(msg_info.subject), handler_sendNotification); 322 // } 323 324 Element('cert_applet').doButtonClickAction('decript', 325 msg_info.msg_number, 326 msg_info.source, 327 msg_info.msg_folder); // Passa os dados para a applet 328 } 330 329 return; 331 330 332 331 } 333 332 334 335 if (msg_info.status_get_msg_info == 'false')336 {337 write_msg(get_lang("Problems reading your message")+ ".");338 return;339 }340 341 333 if (msg_info.status == 'false'){ 342 eval(msg_info.command_to_exec);334 delete_border(msg_info.reuse_border); 343 335 } 344 336 else{ 345 346 337 var ID = msg_info.original_ID ? msg_info.original_ID : msg_info.msg_number; 338 var id_msg_read = ID+"_r"; 347 339 348 340 if (preferences.use_shortcuts == '1') … … 350 342 // Call function to draw message 351 343 // If needed, delete old border 352 if (openTab.type[currentTab] == 2 || openTab.type[currentTab] == 3) 353 delete_border(currentTab,'false'); 354 355 356 if(Element("border_id_" + id_msg_read)) 357 alternate_border(id_msg_read); 358 else { 359 var border_id = create_border(msg_info.subject, id_msg_read); 360 if(border_id) 344 if(currentTab) 345 { 346 draw_message(msg_info,currentTab); 347 var unseen_sort = document.getElementById('span_flag_UNSEEN').getAttribute('onclick'); 348 unseen_sort = unseen_sort.toString(); 349 if ( !(unseen_sort.indexOf("'UNSEEN' == 'UNSEEN'") < 0) ) 361 350 { 362 openTab.type[border_id] = 2; 363 draw_message(msg_info,border_id); 364 var unseen_sort = document.getElementById('span_flag_UNSEEN').getAttribute('onclick'); 365 unseen_sort = unseen_sort.toString(); 366 if ( !(unseen_sort.indexOf("'UNSEEN' == 'UNSEEN'") < 0) ) 367 { 368 var sort_type = sort_box_type; 369 sort_box_type = null; 370 sort_box('UNSEEN', sort_type); 371 } 372 } 373 else 374 return; 375 } 351 var sort_type = sort_box_type; 352 sort_box_type = null; 353 sort_box('UNSEEN', sort_type); 354 } 355 } 356 else 357 return; 376 358 377 359 var domains = ""; 378 360 if ((msg_info.DispositionNotificationTo) && (!msg_is_read(ID) || (msg_info.Recent == 'N'))) 379 { 361 { 380 362 if (preferences.notification_domains != undefined && preferences.notification_domains != "") 381 363 { 382 364 domains = preferences.notification_domains.split(','); 383 365 } 384 366 else 385 { 367 { 386 368 var confNotification = true; 387 369 } 388 370 for (var i = 0; i < domains.length; i++) 389 371 if (msg_info.DispositionNotificationTo.match(domains[i]+">")) … … 392 374 break; 393 375 } 394 if (confNotification == undefined) 395 var confNotification = confirm(get_lang("The sender:\n%1\nwaits your notification of reading. Do you want to confirm this?",msg_info.DispositionNotificationTo), ""); 396 376 if (confNotification == undefined) 377 var confNotification = confirm(get_lang("The sender:\n%1\nwaits your notification of reading. Do you want to confirm this?",msg_info.DispositionNotificationTo), ""); 397 378 if (confNotification) 398 379 cExecute ("expressoMail1_2.imap_functions.send_notification¬ificationto="+msg_info.DispositionNotificationTo+"&subject="+url_encode(msg_info.subject), handler_sendNotification); … … 401 382 if (!msg_is_read(ID)) 402 383 { 403 384 set_msg_as_read(ID, true); 404 385 if (msg_info.cacheHit || (!proxy_mensagens.is_local_folder(get_current_folder()) && msg_info.original_ID)) 405 386 { 406 387 set_message_flag(ID, "seen"); // avoid caducous (lazy) data 407 408 388 } 389 } 409 390 } 410 391 }
Note: See TracChangeset
for help on using the changeset viewer.