From ef918297c8f6ca912fb61028b59f4a049c08683c Mon Sep 17 00:00:00 2001 From: Thierry Vignaud Date: Tue, 12 Nov 2013 01:04:08 +0100 Subject: perlish ->style() => ->get_style() --- perl-install/mygtk3.pm | 2 +- perl-install/standalone/drakclock | 10 +++++----- perl-install/ugtk3.pm | 2 +- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/perl-install/mygtk3.pm b/perl-install/mygtk3.pm index ffcea32c7..c3f48c456 100644 --- a/perl-install/mygtk3.pm +++ b/perl-install/mygtk3.pm @@ -1582,7 +1582,7 @@ sub pixmap_from_pixbuf { my $window = $widget->get_window or internal_error("you can't use this function if the widget is not realised"); my ($width, $height) = ($pixbuf->get_width, $pixbuf->get_height); my $pixmap = Gtk3::Gdk::Pixmap->new($window, $width, $height, $window->get_depth); - $pixbuf->render_to_drawable($pixmap, $widget->style->fg_gc('normal'), 0, 0, 0, 0, $width, $height, 'max', 0, 0); + $pixbuf->render_to_drawable($pixmap, $widget->get_style->fg_gc('normal'), 0, 0, 0, 0, $width, $height, 'max', 0, 0); $pixmap; } diff --git a/perl-install/standalone/drakclock b/perl-install/standalone/drakclock index a61ac98ac..fe072b073 100755 --- a/perl-install/standalone/drakclock +++ b/perl-install/standalone/drakclock @@ -316,7 +316,7 @@ sub determine_radian { sub draw { my ($widget, $event) = @_; my ($x, $y, $width, $height) = $event->area->get_values; - $widget->get_window->draw_drawable($widget->style->fg_gc('normal'), $pixmap, $x, $y, $x, $y, $width, $height); + $widget->get_window->draw_drawable($widget->get_style->fg_gc('normal'), $pixmap, $x, $y, $x, $y, $width, $height); 0; } @@ -344,15 +344,15 @@ sub Repaint { my $dRadians_hour_real = $dRadians_hour + $dRadians_min / 12; my $dRadians_min_real = POSIX::floor($dRadians_min / $PI * 30) * $PI / 30; my $dRadians_sec_real = $dRadians_sec; - my $gc = $drawing_area->style->white_gc; + my $gc = $drawing_area->get_style->white_gc; # fix race on ugtk3->exit that causes a crash (#33894) return 0 if !$gc; - $pixmap->draw_rectangle($drawing_area->style->white_gc, 1, 0, 0, $width, $height); + $pixmap->draw_rectangle($drawing_area->get_style->white_gc, 1, 0, 0, $width, $height); my ($midx, $midy) = ($width / 2, $height / 2); $radius = ($midx < $midy ? $midx : $midy) - 10; - my $gray_gc = $drawing_area->style->bg_gc('normal'); - my $black_gc = $drawing_area->style->black_gc; + my $gray_gc = $drawing_area->get_style->bg_gc('normal'); + my $black_gc = $drawing_area->get_style->black_gc; foreach ([ $gray_gc, 5 ], [ $black_gc, 0 ]) { &DrawTickAt($pixmap, $_->[0], $midx, $midy, $_->[1]); &DrawHour($pixmap, $_->[0], $midx, $midy, $dRadians_hour_real, $_->[1]); diff --git a/perl-install/ugtk3.pm b/perl-install/ugtk3.pm index ea275e5ce..47b91b510 100644 --- a/perl-install/ugtk3.pm +++ b/perl-install/ugtk3.pm @@ -676,7 +676,7 @@ sub set_back_pixbuf { my $window = $widget->get_window; my ($width, $height) = ($pixbuf->get_width, $pixbuf->get_height); my $pixmap = Gtk3::Gdk::Pixmap->new($window, $width, $height, $window->get_depth); - $pixbuf->render_to_drawable($pixmap, $widget->style->fg_gc('normal'), 0, 0, 0, 0, $width, $height, 'max', 0, 0); + $pixbuf->render_to_drawable($pixmap, $widget->get_style->fg_gc('normal'), 0, 0, 0, 0, $width, $height, 'max', 0, 0); $window->set_back_pixmap($pixmap, 0); } -- cgit v1.2.1