summaryrefslogtreecommitdiffstats
path: root/perl-install/ugtk2.pm
diff options
context:
space:
mode:
authorThierry Vignaud <tvignaud@mandriva.org>2003-07-10 13:52:36 +0000
committerThierry Vignaud <tvignaud@mandriva.org>2003-07-10 13:52:36 +0000
commit41cdef71c22e93b3b0f52400182271946987af15 (patch)
treee065d0a204d2eae5ca456ba489a2379b6951817e /perl-install/ugtk2.pm
parent250dcb61b6210e1a20dcec6be089f98e9d257610 (diff)
downloaddrakx-41cdef71c22e93b3b0f52400182271946987af15.tar
drakx-41cdef71c22e93b3b0f52400182271946987af15.tar.gz
drakx-41cdef71c22e93b3b0f52400182271946987af15.tar.bz2
drakx-41cdef71c22e93b3b0f52400182271946987af15.tar.xz
drakx-41cdef71c22e93b3b0f52400182271946987af15.zip
- symbolic keys are back
- do not name "use once" variables
Diffstat (limited to 'perl-install/ugtk2.pm')
-rw-r--r--perl-install/ugtk2.pm9
1 files changed, 5 insertions, 4 deletions
diff --git a/perl-install/ugtk2.pm b/perl-install/ugtk2.pm
index 9221a1038..462b25c7f 100644
--- a/perl-install/ugtk2.pm
+++ b/perl-install/ugtk2.pm
@@ -35,6 +35,7 @@ use log;
use common;
use Gtk2;
+use Gtk2::Gdk::Keysyms;
unless ($::no_ugtk_init) {
!check_for_xserver() and die "Cannot be run in console mode.\n";
@@ -542,7 +543,7 @@ sub gtktext_insert {
if ($token->[1]) {
my $tag = $buffer->create_tag(rand());
$tag->set(%{$token->[1]});
- $buffer->apply_tag($tag, $iter1 = $buffer->get_iter_at_offset($c), my $iter2 = $buffer->get_end_iter);
+ $buffer->apply_tag($tag, $iter1 = $buffer->get_iter_at_offset($c), $buffer->get_end_iter);
}
}
} else {
@@ -550,7 +551,7 @@ sub gtktext_insert {
}
#- the following line is needed to move the cursor to the beginning, so that if the
#- textview has a scrollbar, it won't scroll to the bottom when focusing (#3633)
- $buffer->place_cursor(my $iter = $buffer->get_start_iter);
+ $buffer->place_cursor($buffer->get_start_iter);
$textview->set_wrap_mode($opts{wrap_mode} || 'word');
$textview->set_editable($opts{editable} || 0);
$textview->set_cursor_visible($opts{visible} || 0);
@@ -804,7 +805,7 @@ sub new {
$::WizardWindow->set_uposition($::stepswidth + $::windowwidth * 0.04, $::logoheight + $::windowheight * ($::logoheight ? 0.12 : 0.05));
$::WizardWindow->signal_connect(key_press_event => sub {
my (undef, $event) = @_;
- my $d = ${{ 0xFFBF => 'screenshot' }}{$event->keyval}; # GDK_F2 from gdk/gdkkeysyms.h
+ my $d = ${{ $Gtk2::Gdk::Keysyms{F2} => 'screenshot' }}{$event->keyval};
if ($d eq 'screenshot') {
common::take_screenshot();
} elsif (chr($event->keyval) eq 'e' && member('mod1-mask', @{$event->state})) { #- alt-e
@@ -1243,7 +1244,7 @@ sub ask_browse_tree_info_given_widgets {
my $children = sub { map { my $v = $w->{tree_model}->get($_, 0); $v } gtktreeview_children($w->{tree_model}, $_[0]) };
my $toggle = sub {
if (ref($curr) && !$_[0]) {
- $w->{tree}->toggle_expansion(my $path = $w->{tree_model}->get_path($curr));
+ $w->{tree}->toggle_expansion($w->{tree_model}->get_path($curr));
} else {
if (ref $curr) {
my @_a = $children->($curr);