diff options
author | Pascal Rigaux <pixel@mandriva.com> | 2008-09-25 14:50:01 +0000 |
---|---|---|
committer | Pascal Rigaux <pixel@mandriva.com> | 2008-09-25 14:50:01 +0000 |
commit | 4ee2149bc75d82352deb4902eb88a37b184bcecb (patch) | |
tree | 67f846a4397cf658c41809e9f01891a3b40b87f3 /lib | |
parent | ade8f5686b4bab9830a0ec2524959598fa57b37c (diff) | |
download | drakx-kbd-mouse-x11-4ee2149bc75d82352deb4902eb88a37b184bcecb.tar drakx-kbd-mouse-x11-4ee2149bc75d82352deb4902eb88a37b184bcecb.tar.gz drakx-kbd-mouse-x11-4ee2149bc75d82352deb4902eb88a37b184bcecb.tar.bz2 drakx-kbd-mouse-x11-4ee2149bc75d82352deb4902eb88a37b184bcecb.tar.xz drakx-kbd-mouse-x11-4ee2149bc75d82352deb4902eb88a37b184bcecb.zip |
create XxY() and use it
Diffstat (limited to 'lib')
-rw-r--r-- | lib/Xconfig/resolution_and_depth.pm | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/Xconfig/resolution_and_depth.pm b/lib/Xconfig/resolution_and_depth.pm index 39ba7b9..5b43691 100644 --- a/lib/Xconfig/resolution_and_depth.pm +++ b/lib/Xconfig/resolution_and_depth.pm @@ -65,6 +65,8 @@ sub size2default_resolution { $monitorSize2resolution{round($size)} || ($size < 13 ? "640x480" : "1600x1200"); } +sub XxY { &Xconfig::xfree::XxY } + sub to_string { my ($resolution) = @_; $resolution or return ''; @@ -237,7 +239,7 @@ sub set_resolution { if (!$resolution->{automatic}) { my $ratio = Xconfig::xfree::resolution2ratio($resolution, 'non-strict'); - @other = uniq_ { $_->{X} . 'x' . $_->{Y} } @other; + @other = uniq_ { XxY($_) } @other; @other = grep { $_->{X} < $resolution->{X} } @other; @other = filter_on_ratio($ratio, @other); |