summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorThierry Vignaud <thierry.vignaud@gmail.com>2013-08-30 16:20:40 +0200
committerThierry Vignaud <thierry.vignaud@gmail.com>2013-11-24 21:28:36 +0100
commit45338bd2f691b8fc61665daefd2bd30767bf742d (patch)
tree4eaa4c7b7a226d752b49dc45d7030ab878842a61
parent527a624d8825348bcd9bd2ec0005409a89230315 (diff)
downloaddrakx-45338bd2f691b8fc61665daefd2bd30767bf742d.tar
drakx-45338bd2f691b8fc61665daefd2bd30767bf742d.tar.gz
drakx-45338bd2f691b8fc61665daefd2bd30767bf742d.tar.bz2
drakx-45338bd2f691b8fc61665daefd2bd30767bf742d.tar.xz
drakx-45338bd2f691b8fc61665daefd2bd30767bf742d.zip
(root_window_size) introduce it
-rw-r--r--perl-install/mygtk3.pm6
1 files changed, 6 insertions, 0 deletions
diff --git a/perl-install/mygtk3.pm b/perl-install/mygtk3.pm
index 6d75baec7..ccbd23e27 100644
--- a/perl-install/mygtk3.pm
+++ b/perl-install/mygtk3.pm
@@ -1491,6 +1491,12 @@ sub root_window() {
$root ||= Gtk3::Gdk::get_default_root_window();
}
+sub root_window_size() {
+ state $root;
+ $root ||= [Gtk3::Gdk::Screen::width, Gtk3::Gdk::Screen::height];
+ @$root;
+}
+
sub rgb2color {
my ($r, $g, $b) = @_;
my $color = Gtk3::Gdk::Color->new($r, $g, $b);