diff options
author | toma <toma@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2009-11-25 17:56:58 +0000 |
---|---|---|
committer | toma <toma@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2009-11-25 17:56:58 +0000 |
commit | e9ae80694875f869892f13f4fcaf1170a00dea41 (patch) | |
tree | aa2f8d8a217e2d376224c8d46b7397b68d35de2d /quanta/scripts/externalpreview.sh | |
download | tdewebdev-e9ae80694875f869892f13f4fcaf1170a00dea41.tar.gz tdewebdev-e9ae80694875f869892f13f4fcaf1170a00dea41.zip |
Copy the KDE 3.5 branch to branches/trinity for new KDE 3.5 features.
BUG:215923
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdewebdev@1054174 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'quanta/scripts/externalpreview.sh')
-rw-r--r-- | quanta/scripts/externalpreview.sh | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/quanta/scripts/externalpreview.sh b/quanta/scripts/externalpreview.sh new file mode 100644 index 00000000..9bc67fa7 --- /dev/null +++ b/quanta/scripts/externalpreview.sh @@ -0,0 +1,22 @@ +#!/bin/bash +#Previews the current document in Mozilla/Netscape/Opera, depending +#on the last two arguments (browsername, newtab command). +#Might be adjusted in the feature to support more browsers. +pid=$1 +currentURL="" +if test $pid == "unique" +then + currentURL=`dcop quanta WindowManagerIf saveCurrentFile` + shift +else + currentURL=`dcop quanta-$pid WindowManagerIf saveCurrentFile` +fi +browser=$2 +newTab=$3 +if test $currentURL +then + if ! $browser -remote "openURL($currentURL,$newTab)" + then + $browser $currentURL + fi +fi
\ No newline at end of file |