summaryrefslogtreecommitdiffabout
path: root/microkde/kresources
Side-by-side diff
Diffstat (limited to 'microkde/kresources') (more/less context) (show whitespace changes)
-rw-r--r--microkde/kresources/managerimpl.cpp9
-rw-r--r--microkde/kresources/resource.cpp7
2 files changed, 14 insertions, 2 deletions
diff --git a/microkde/kresources/managerimpl.cpp b/microkde/kresources/managerimpl.cpp
index 1baa6be..785b6b4 100644
--- a/microkde/kresources/managerimpl.cpp
+++ b/microkde/kresources/managerimpl.cpp
@@ -250,18 +250,23 @@ Resource* ManagerImpl::readResourceConfig( const QString& identifier,
{
kdDebug() << "ManagerImpl::readResourceConfig() " << identifier << endl;
// qDebug("ManagerImpl::readResourceConfig() %s", identifier.latin1());
mConfig->setGroup( "Resource_" + identifier );
-
+#ifdef _WIN32_
+ // we use plugins on win32. the group is stored in a static variable
+ // such that gourp info not avail on win32 plugins
+ // to fix that, it would be a looooot of work
+ mConfig->setTempGroup( "Resource_" + identifier );
+#endif
QString type = mConfig->readEntry( "ResourceType" );
QString name = mConfig->readEntry( "ResourceName" );
Resource *resource = mFactory->resource( type, mConfig );
if ( !resource ) {
- kdDebug(5650) << "Failed to create resource with id " << identifier << endl;
+ qDebug("Failed to create resource with id %s ",identifier.latin1() );
return 0;
}
if ( resource->identifier().isEmpty() )
resource->setIdentifier( identifier );
diff --git a/microkde/kresources/resource.cpp b/microkde/kresources/resource.cpp
index 7827a67..991d53d 100644
--- a/microkde/kresources/resource.cpp
+++ b/microkde/kresources/resource.cpp
@@ -50,12 +50,19 @@ Resource::Resource( const KConfig* config )
d->mOpenCount = 0;
d->mIsOpen = false;
//US compiler claimed that const discards qualifier
KConfig* cfg = (KConfig*)config;
if ( cfg ) {
+#ifdef _WIN32_
+ // we use plugins on win32. the group is stored in a static variable
+ // such that group info not available on win32 plugins
+ // to fix that, it would be a looooot of work
+ if ( !cfg->tempGroup().isEmpty() )
+ cfg->setGroup( cfg->tempGroup() );
+#endif
d->mType = cfg->readEntry( "ResourceType" );
d->mName = cfg->readEntry( "ResourceName" );
d->mReadOnly = cfg->readBoolEntry( "ResourceIsReadOnly", false );
d->mActive = cfg->readBoolEntry( "ResourceIsActive", true );
d->mIdentifier = cfg->readEntry( "ResourceIdentifier" );
} else {