summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAurélien Lefebvre <alefebvre@mandriva.com>2009-09-11 15:46:53 +0000
committerAurélien Lefebvre <alefebvre@mandriva.com>2009-09-11 15:46:53 +0000
commit6bf0d7b2c99cbd9fcde479ee07065d3cddf83c35 (patch)
treee919aaf9621e929ea85357ef9255dfcd75df1993
parent16c9668b8f20a4b1a7aa83eddf04272c3af0f35e (diff)
downloaddrakx-kbd-mouse-x11-6bf0d7b2c99cbd9fcde479ee07065d3cddf83c35.tar
drakx-kbd-mouse-x11-6bf0d7b2c99cbd9fcde479ee07065d3cddf83c35.tar.gz
drakx-kbd-mouse-x11-6bf0d7b2c99cbd9fcde479ee07065d3cddf83c35.tar.bz2
drakx-kbd-mouse-x11-6bf0d7b2c99cbd9fcde479ee07065d3cddf83c35.tar.xz
drakx-kbd-mouse-x11-6bf0d7b2c99cbd9fcde479ee07065d3cddf83c35.zip
- XFdrake:
o fix DontZap option issue with old xorg.conf files
-rw-r--r--NEWS3
-rw-r--r--lib/Xconfig/various.pm11
2 files changed, 11 insertions, 3 deletions
diff --git a/NEWS b/NEWS
index 8417c74..4671c24 100644
--- a/NEWS
+++ b/NEWS
@@ -1,3 +1,6 @@
+- XFdrake:
+ o fix DontZap option issue with old xorg.conf files
+
Version 0.78 - 9 September 2009
- XFdrake:
diff --git a/lib/Xconfig/various.pm b/lib/Xconfig/various.pm
index f1c3517..027ac76 100644
--- a/lib/Xconfig/various.pm
+++ b/lib/Xconfig/various.pm
@@ -23,7 +23,7 @@ sub info {
my $device = eval { $raw_X->get_device } || {};
my $mouse = eval { first($raw_X->get_mice) } || {};
- $info .= N("Disable Ctrl-Alt-Backspace: %s\n", configure_ServerFlag($raw_X, 'DontZap') eq 'True' ? N("yes") : N("no"));
+ $info .= N("Disable Ctrl-Alt-Backspace: %s\n", configure_ServerFlag($raw_X, 'DontZap') eq 'False' ? N("no") : N("yes"));
$info .= N("3D hardware acceleration: %s\n", translate(bool2yesno($card->{use_DRI_GLX} || $card->{DRI_GLX_SPECIAL})));
$info .= N("Keyboard layout: %s\n", $keyboard->{XkbLayout});
$info .= N("Mouse type: %s\n", $mouse->{Protocol});
@@ -88,7 +88,7 @@ sub various {
RenderAccel => !$card->{Options}{RenderAccel},
),
HWCursor => !$card->{Options}{SWCursor},
- DontZap => (configure_ServerFlag($raw_X, 'DontZap') eq 'True' ? 1 : 0),
+ DontZap => (configure_ServerFlag($raw_X, 'DontZap') eq 'False' ? 0 : 1),
if_($card->{DRI_GLX} || $use_DRI_GLX, use_DRI_GLX => $use_DRI_GLX),
),
};
@@ -339,7 +339,12 @@ sub configure_ServerFlag {
my ($raw_X, $option, $value) = @_;
my $ServerFlags = $raw_X->get_Section('ServerFlags');
my $option_ref = $ServerFlags->{$option}->[0];
- $option_ref->{val} = $value if $value;
+ if ($value) {
+ $option_ref->{val} = $value;
+ $option_ref->{commented} = 0;
+ $option_ref->{Option} = 1;
+ }
+ return undef if $option_ref->{commented} eq 1;
$option_ref->{val};
}