summaryrefslogtreecommitdiffstats
path: root/konq-plugins/mediarealfolder/kio_media_realfolder
diff options
context:
space:
mode:
Diffstat (limited to 'konq-plugins/mediarealfolder/kio_media_realfolder')
-rwxr-xr-xkonq-plugins/mediarealfolder/kio_media_realfolder20
1 files changed, 20 insertions, 0 deletions
diff --git a/konq-plugins/mediarealfolder/kio_media_realfolder b/konq-plugins/mediarealfolder/kio_media_realfolder
new file mode 100755
index 0000000..cbb3d06
--- /dev/null
+++ b/konq-plugins/mediarealfolder/kio_media_realfolder
@@ -0,0 +1,20 @@
+#! /usr/bin/env perl
+
+use warnings;
+use strict;
+
+my @parts = split(/\//, $ARGV[0]);
+
+my $medium = $parts[$#parts];
+
+open(IN, "-|") || exec "dcop", "kded", "mediamanager", "properties", $medium;
+my @prop = <IN>;
+close(IN);
+
+if ($prop[6] =~ /^\//)
+{
+ my $mountpoint = $prop[6];
+ chomp($mountpoint);
+ exec "kfmclient", "exec", "file://$mountpoint/";
+}
+