From 951960e052a0536b318661873ea615ab2cf34ed6 Mon Sep 17 00:00:00 2001
From: thomascube <thomas@roundcube.net>
Date: Thu, 28 Jul 2011 04:40:43 -0400
Subject: [PATCH] Delay window.print() on Safari browsers

---
 program/js/app.js |    5 ++++-
 1 files changed, 4 insertions(+), 1 deletions(-)

diff --git a/program/js/app.js b/program/js/app.js
index 81bee6c..1814bed 100644
--- a/program/js/app.js
+++ b/program/js/app.js
@@ -252,7 +252,10 @@
         }
         // show printing dialog
         else if (this.env.action == 'print' && this.env.uid)
-          window.print();
+          if (bw.safari)
+            window.setTimeout('window.print()', 10);
+          else
+            window.print();
 
         // get unread count for each mailbox
         if (this.gui_objects.mailboxlist) {

--
Gitblit v1.9.1