diff options
Diffstat (limited to 'lib/URLQueue/MainController.pm')
-rw-r--r-- | lib/URLQueue/MainController.pm | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/lib/URLQueue/MainController.pm b/lib/URLQueue/MainController.pm index 1e4dd04..2705b59 100644 --- a/lib/URLQueue/MainController.pm +++ b/lib/URLQueue/MainController.pm @@ -32,6 +32,22 @@ sub drag_motion { $context->status($context->suggested_action,$time); + if (!$self->{_dragging}) { + $self->{input}->set('icon-name'=>'stock_book_open'); + $self->{_dragging}=1; + } + + return 1; +} + +sub drag_leave { + my ($self, $widget, $context, $time) = @_; + + if ($self->{_dragging}) { + $self->{input}->set('icon-name'=>'stock_book_green'); + $self->{_dragging}=0; + } + return 1; } @@ -39,6 +55,7 @@ sub drag_drop { my ($self, $widget, $context, $x, $y, $time) = @_; if (my $atom=$context->targets) { + $self->{input}->set('icon-name'=>'stock_book_yellow'); $widget->drag_get_data($context, $atom, $time); return 1; } @@ -59,6 +76,8 @@ sub drag_data_received { warn "What is $info??"; } + $self->{input}->set('icon-name'=>'stock_book_green'); + return 1; } @@ -75,6 +94,7 @@ sub button_release { my ($self,$widget,$event)=@_; if ($event->button==2) { + $self->{input}->set('icon-name'=>'stock_book_yellow'); my $clipboard=Gtk2::Clipboard->get(Gtk2::Gdk->SELECTION_PRIMARY); $clipboard->request_text(sub{$self->handle_text($_[1])}); return 1; |