diff options
| author | alec <alec@208e9e7b-5314-0410-a742-e7e81cd9613c> | 2009-04-15 12:40:28 +0000 |
|---|---|---|
| committer | alec <alec@208e9e7b-5314-0410-a742-e7e81cd9613c> | 2009-04-15 12:40:28 +0000 |
| commit | 9479f0f9b01cd53cd35ce2bbf2d346e9927ce133 (patch) | |
| tree | ae5e7ed89943efae8f4c92d8b36e1729a00779ca /roundcubemail/program/js/common.js | |
| parent | 635bd2c5ffdf5f7abeae8fb69fc6d4324481adbe (diff) | |
- fix console for Konqueror
git-svn-id: https://svn.roundcube.net/trunk@2393 208e9e7b-5314-0410-a742-e7e81cd9613c
Diffstat (limited to 'roundcubemail/program/js/common.js')
| -rw-r--r-- | roundcubemail/program/js/common.js | 20 |
1 files changed, 14 insertions, 6 deletions
diff --git a/roundcubemail/program/js/common.js b/roundcubemail/program/js/common.js index 5923989ec..7ec18f205 100644 --- a/roundcubemail/program/js/common.js +++ b/roundcubemail/program/js/common.js @@ -608,20 +608,28 @@ function rcube_console() { this.log = function(msg) { - box = rcube_find_object('console'); + var box = rcube_find_object('console'); - if (box) + if (box) { if (msg.charAt(msg.length-1)=='\n') - box.value += msg+'--------------------------------------\n'; + msg += '--------------------------------------\n'; else - box.value += msg+'\n--------------------------------------\n'; + msg += '\n--------------------------------------\n'; + + // Konqueror (Safari also?) doesn't allows to just change value of hidden element + if (bw.konq) { + box.innerText += msg; + box.value = box.innerText; + } else + box.value += msg; + } }; this.reset = function() { - box = rcube_find_object('console'); + var box = rcube_find_object('console'); if (box) - box.value = ''; + box.innerText = box.value = ''; }; } |
