diff options
author | Pascal Rigaux <pixel@mandriva.com> | 2007-09-25 13:30:16 +0000 |
---|---|---|
committer | Pascal Rigaux <pixel@mandriva.com> | 2007-09-25 13:30:16 +0000 |
commit | 135f853a2609856021c1f81d9e95bcc63f4e73b5 (patch) | |
tree | b99859aa43bfe278cd21d19be5aaa2d02cde597e /lib/Xconfig/main.pm | |
parent | 20620f0ed07df3a9548219e7b0697faa970a2ed9 (diff) | |
download | drakx-kbd-mouse-x11-135f853a2609856021c1f81d9e95bcc63f4e73b5.tar drakx-kbd-mouse-x11-135f853a2609856021c1f81d9e95bcc63f4e73b5.tar.gz drakx-kbd-mouse-x11-135f853a2609856021c1f81d9e95bcc63f4e73b5.tar.bz2 drakx-kbd-mouse-x11-135f853a2609856021c1f81d9e95bcc63f4e73b5.tar.xz drakx-kbd-mouse-x11-135f853a2609856021c1f81d9e95bcc63f4e73b5.zip |
- cleanup
- don't export_to_install_X unset things
(will help for next commits)
Diffstat (limited to 'lib/Xconfig/main.pm')
-rw-r--r-- | lib/Xconfig/main.pm | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/lib/Xconfig/main.pm b/lib/Xconfig/main.pm index 6b871ec..cc31fc6 100644 --- a/lib/Xconfig/main.pm +++ b/lib/Xconfig/main.pm @@ -223,9 +223,10 @@ sub write { sub export_to_install_X { my ($X) = @_; - $::o->{X}{resolution_wanted} = $X->{resolutions}[0]{X} . 'x' . $X->{resolutions}[0]{Y}; - $::o->{X}{default_depth} = $X->{resolutions}[0]{Depth}; - $::o->{X}{bios_vga_mode} = $X->{resolutions}[0]{bios}; + my $resolution = $X->{resolutions}[0]; + $::o->{X}{resolution_wanted} = $resolution->{X} . 'x' . $resolution->{Y} if $resolution->{X}; + $::o->{X}{default_depth} = $resolution->{Depth} if $resolution->{Depth}; + $::o->{X}{bios_vga_mode} = $resolution->{bios} if $resolution->{bios}; $::o->{X}{monitors} = $X->{monitors} if $X->{monitors}[0]{manually_chosen} && $X->{monitors}[0]{vendor} ne "Plug'n Play"; $::o->{X}{card} = $X->{card} if $X->{card}{manually_chosen}; $::o->{X}{Xinerama} = 1 if $X->{card}{Xinerama}; @@ -234,7 +235,7 @@ sub export_to_install_X { sub check_valid { my ($raw_X) = @_; - my %sections = map { + my %_sections = map { my @l = $raw_X->get_Sections($_) or return "missing section $_"; $_ => \@l; } qw(InputDevice Monitor Device Screen ServerLayout); |