From 30617b6fb78c56e76aedd1480429dd4e68da201a Mon Sep 17 00:00:00 2001 From: Timothy Pearson Date: Tue, 24 Apr 2012 19:21:48 -0500 Subject: Fix SAK dialog momentary display when SAK disabled Clean up build warnings in kdesktop --- kdesktop/lock/main.cc | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) (limited to 'kdesktop/lock') diff --git a/kdesktop/lock/main.cc b/kdesktop/lock/main.cc index 225d9c5b4..896defd10 100644 --- a/kdesktop/lock/main.cc +++ b/kdesktop/lock/main.cc @@ -29,6 +29,7 @@ #include #include #include +#include #include @@ -199,7 +200,19 @@ int main( int argc, char **argv ) trinity_desktop_lock_use_system_modal_dialogs = !KDesktopSettings::useUnmanagedLockWindows(); trinity_desktop_lock_delay_screensaver_start = KDesktopSettings::delaySaverStart(); - trinity_desktop_lock_use_sak = KDesktopSettings::useTDESAK(); + + // RAJA + struct stat st; + KSimpleConfig* tdmconfig; + if( stat( KDE_CONFDIR "/tdm/tdmdistrc" , &st ) == 0) { + tdmconfig = new KSimpleConfig( TQString::fromLatin1( KDE_CONFDIR "/tdm/tdmdistrc" )); + } + else { + tdmconfig = new KSimpleConfig( TQString::fromLatin1( KDE_CONFDIR "/tdm/tdmrc" )); + } + tdmconfig->setGroup("X-*-Greeter"); + trinity_desktop_lock_use_sak = tdmconfig->readBoolEntry("UseSAK", true); + delete tdmconfig; if (args->isSet( "internal" )) { while (signalled_run == FALSE) { -- cgit v1.2.1