[Bug 169333] display setting revert to prev configuration useless
sycao
yinshuiboy at gmail.com
Mon Aug 18 03:40:33 BST 2008
http://bugs.kde.org/show_bug.cgi?id=169333
sycao yinshuiboy gmail com changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |yinshuiboy at gmail.com
--- Comment #1 from sycao <yinshuiboy gmail com> 2008-08-18 04:40:26 CET ---
the problem doesn't show up when using krandrtray, because all changes will
trigger
RandROutput->applyProposed with specific changed argument. but when use
kcmshell4 display,
all changes will trigger m_display->applyProposed with inaccurate changed
argument.
diff -Nur kdebase-workspace-4.1.0-orig/kcontrol/randr/krandrmodule.cpp
kdebase-workspace-4.1.0/kcontrol/randr/krandrmodule.cpp
--- kdebase-workspace-4.1.0-orig/kcontrol/randr/krandrmodule.cpp
2008-08-12 15:49:50.000000000 +0000
+++ kdebase-workspace-4.1.0/kcontrol/randr/krandrmodule.cpp 2008-08-14
11:52:31.000000000 +0000
@@ -39,6 +39,11 @@
: KCModule(KSSFactory::componentData(), parent)
{
m_display = new RandRDisplay();
+ if ( m_display->needsRefresh() )
+ {
+ m_display->refresh();
+ }
+
if (!m_display->isValid())
{
QVBoxLayout *topLayout = new QVBoxLayout(this);
diff -Nur kdebase-workspace-4.1.0-orig/kcontrol/randr/randrconfig.cpp
kdebase-workspace-4.1.0/kcontrol/randr/randrconfig.cpp
--- kdebase-workspace-4.1.0-orig/kcontrol/randr/randrconfig.cpp 2008-08-12
15:49:50.000000000 +0000
+++ kdebase-workspace-4.1.0/kcontrol/randr/randrconfig.cpp 2008-08-14
11:34:12.000000000 +0000
@@ -152,12 +152,22 @@
output->proposeRect(configuredRect);
output->proposeRotation(config->rotation());
output->proposeRefreshRate(config->refreshRate());
+
+ int change = 0;
+ if ( output->rect() != configuredRect )
+ change |= RandR::ChangeRect;
+ if ( output->rotation() != config->rotation() )
+ change |= RandR::ChangeRotation;
+ if ( output->refreshRate() != config->refreshRate() )
+ change |= RandR::ChangeRate;
+ output->applyProposed( RandR::ChangeRect, true );
+
} else { // user wants to disable this output
kDebug() << "Disabling " << output->name();
output->slotDisable();
}
}
- m_display->applyProposed();
+// m_display->applyProposed();
update();
}
--
Configure bugmail: http://bugs.kde.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
More information about the Unassigned-bugs
mailing list