dwb: magnet, ftp and mailto content support
parent
dd2f372e36
commit
99f2578503
|
@ -140,7 +140,7 @@ scroll-step=0.00
|
|||
close-last-tab-policy=clear
|
||||
foreground-color=#ffffff
|
||||
message-delay=2
|
||||
scheme-handler=dwb-scheme
|
||||
scheme-handler=
|
||||
default-font-size=12
|
||||
enable-offline-web-application-cache=true
|
||||
hints-key-lock=250
|
||||
|
|
|
@ -117,14 +117,25 @@ extensions.load("contenthandler", {
|
|||
|
||||
// Handle requests based on URI scheme
|
||||
uriScheme : {
|
||||
//ftp : function(uri) {
|
||||
// if (uri[uri.length-1] == "/")
|
||||
// return "xterm -e 'ncftp " + uri + "'";
|
||||
// else
|
||||
// return "xterm -e 'ncftpget " + uri + "'";
|
||||
//}
|
||||
ftp : function(uri) {
|
||||
if (uri[uri.length-1] == "/")
|
||||
return "xterm -e 'ncftp " + uri + "'";
|
||||
else
|
||||
return "xterm -e 'ncftpget " + uri + "'";
|
||||
},
|
||||
|
||||
magnet: "transmission-remote -a '%u'"
|
||||
// We need to use 'sh -c' since we need to use a pipe so that xclip can
|
||||
// read from stdin
|
||||
mailto : function(uri) {
|
||||
uri=uri.replace(/mailto:/, "")
|
||||
uri=uri.replace(/\?/, " ")
|
||||
return "sh -c ' echo " + uri + " | xclip -i'";
|
||||
},
|
||||
|
||||
// 'trc' is a wrapper script that will launch transmission-daemon if not
|
||||
// already started.
|
||||
// magnet: "transmission-remote -a '%u'"
|
||||
magnet: "trc -a '%u'"
|
||||
},
|
||||
|
||||
// Handle requests based on MIME type
|
||||
|
|
|
@ -12,10 +12,10 @@
|
|||
"blocklist-url": "http://www.example.com/blocklist",
|
||||
"cache-size-mb": 4,
|
||||
"dht-enabled": true,
|
||||
"download-dir": "/home/peter/Downloads",
|
||||
"download-dir": "/home/peter/temp",
|
||||
"download-queue-enabled": true,
|
||||
"download-queue-size": 5,
|
||||
"encryption": 1,
|
||||
"encryption": 2,
|
||||
"idle-seeding-limit": 30,
|
||||
"idle-seeding-limit-enabled": false,
|
||||
"incomplete-dir": "/home/peter/Downloads",
|
||||
|
|
Loading…
Reference in New Issue