--- trunk/lib/Frey/Editor.pm 2008/11/18 16:39:13 417
+++ trunk/lib/Frey/Editor.pm 2008/11/29 15:05:55 617
@@ -7,7 +7,7 @@
Support for local editor invocation from web
- $class
+ $class
=head2 url
@@ -23,6 +23,12 @@
=cut
+sub switch_screen {
+ my $cmd = 'xdotool key super+Tab';
+ warn "# switch_screen $cmd";
+ system $cmd;
+}
+
sub command {
my ( $self, $url ) = @_;
$url =~ url_regex;
@@ -32,7 +38,9 @@
$path = $self->class_path( $path ) || $path if ! -e $path;
my $cmd = "$editor $path +$line";
warn "# $url -> system $cmd";
- return $cmd;
+ $self->switch_screen;
+ system $cmd;
+ $self->switch_screen;
}
1;