summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPascal Rigaux <pixel@mandriva.com>2008-01-23 11:19:41 +0000
committerPascal Rigaux <pixel@mandriva.com>2008-01-23 11:19:41 +0000
commit378cf6e8d966283db0e05c4727867a53c94c5663 (patch)
tree414c4be9074d52db50d0e798b5d69ca1c90ec774
parente3445ee77906f98107f37ed8fdb3d20eeb07322a (diff)
downloaddrakx-kbd-mouse-x11-378cf6e8d966283db0e05c4727867a53c94c5663.tar
drakx-kbd-mouse-x11-378cf6e8d966283db0e05c4727867a53c94c5663.tar.gz
drakx-kbd-mouse-x11-378cf6e8d966283db0e05c4727867a53c94c5663.tar.bz2
drakx-kbd-mouse-x11-378cf6e8d966283db0e05c4727867a53c94c5663.tar.xz
drakx-kbd-mouse-x11-378cf6e8d966283db0e05c4727867a53c94c5663.zip
- XFdrake:
o if the EDID gives a valid EISA_ID, a valid 16/10 preferred resolution, but no HorizSync/VertRefresh, use a generic flat panel HorizSync/VertRefresh reproduced on a Elonex PLC - MSI Notebook PR600, EISA_ID CMO1526
-rw-r--r--NEWS4
-rw-r--r--lib/Xconfig/monitor.pm18
2 files changed, 18 insertions, 4 deletions
diff --git a/NEWS b/NEWS
index 96b0b90..1ea2d57 100644
--- a/NEWS
+++ b/NEWS
@@ -1,3 +1,7 @@
+- XFdrake:
+ o if the EDID gives a valid EISA_ID, a valid 16/10 preferred resolution, but
+ no HorizSync/VertRefresh, use a generic flat panel HorizSync/VertRefresh
+
Version 0.42 - 22 January 2008
- XFdrake:
diff --git a/lib/Xconfig/monitor.pm b/lib/Xconfig/monitor.pm
index 6d67478..1e7795f 100644
--- a/lib/Xconfig/monitor.pm
+++ b/lib/Xconfig/monitor.pm
@@ -164,8 +164,14 @@ sub configure_automatic {
add2hash($monitor, $mon);
log::l("EISA_ID corresponds to: $monitor->{ModelName}");
} elsif (!$monitor->{HorizSync} || !$monitor->{VertRefresh}) {
- log::l("unknown EISA_ID and partial DDC probe, so unknown monitor");
- delete @$monitor{'VendorName', 'ModelName', 'EISA_ID'};
+ if ($monitor->{preferred_resolution}
+ && Xconfig::xfree::resolution2ratio($monitor->{preferred_resolution}) eq '16/10') {
+ log::l("no HorizSync nor VertRefresh, using preferred resolution (hopefully this is a flat panel)");
+ add2hash($monitor, generic_flat_panel($monitor->{preferred_resolution}));
+ } else {
+ log::l("unknown EISA_ID and partial DDC probe, so unknown monitor");
+ delete @$monitor{'VendorName', 'ModelName', 'EISA_ID'};
+ }
}
} elsif ($monitor->{VendorName}) {
if (my $mon = find { $_->{VendorName} eq $monitor->{VendorName} && $_->{ModelName} eq $monitor->{ModelName} } monitors_db()) {
@@ -271,7 +277,7 @@ sub probe_using_X {
$resolution = eval($resolution) or return;
if (my $res = $resolution->[0]{preferred_resolution}) {
- generic_flat_panel_($res->{X}, $res->{Y});
+ generic_flat_panel($res);
} else {
log::l("at least one EDID was found in Xorg.log, so let Xorg autodetect the monitor");
{ VendorName => "Plug'n Play" };
@@ -280,11 +286,15 @@ sub probe_using_X {
sub probe_DMI() {
my $res = detect_devices::probe_unique_name('Resolution');
- $res && generic_flat_panel($res);
+ $res && generic_flat_panel_txt($res);
}
sub generic_flat_panel {
my ($resolution) = @_;
+ generic_flat_panel_($resolution->{X}, $resolution->{Y});
+}
+sub generic_flat_panel_txt {
+ my ($resolution) = @_;
my ($X, $Y) = $resolution =~ /(\d+)x(\d+)/ or log::l("bad resolution $resolution"), return;
generic_flat_panel_($X, $Y);
}