KOrganizer : Fix Get Hot New Stuff
ClosedPublic

Authored by winterz on Mon, Oct 14, 3:00 PM.

Details

Summary
  • the providersurl setting in the .knsrc file was wrong and no longer needed: just use the default
  • need to pass the explicit name of the .knsrc file else KNS3 thinks we want the kontact.knsrc
Test Plan

seems to work now.

Diff Detail

Repository
R210 KOrganizer
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.
winterz created this revision.Mon, Oct 14, 3:00 PM
Restricted Application added a project: KDE PIM. · View Herald TranscriptMon, Oct 14, 3:00 PM
Restricted Application added a subscriber: kde-pim. · View Herald Transcript
winterz requested review of this revision.Mon, Oct 14, 3:00 PM
winterz updated this revision to Diff 67908.Mon, Oct 14, 3:20 PM

save/restore application settings

too bad the KNS3 API doesn't have setFoo() to override these

note to self: KOrganizer should have an easier way to access AboutData so we only need to change the application name, version in that 1 location

Now I think that kns3 must be adapt and not created a workaround for it.

src/actionmanager.cpp
1194

void KAboutData::setApplicationData(const KAboutData &aboutData)
{

if (s_registry->m_appData) {
    *s_registry->m_appData = aboutData;
} else {
    s_registry->m_appData = new KAboutData(aboutData);
}

// For applicationDisplayName & desktopFileName, which are only properties of QGuiApplication,
// we have to try to set them via the property system, as the static getter methods are
// part of QtGui only. Disadvantage: requires an app instance.
// So set either all or none of the properties & warn about it
QCoreApplication *app = QCoreApplication::instance();
if (app) {
    app->setApplicationVersion(aboutData.version());
    app->setApplicationName(aboutData.componentName());
    app->setOrganizationDomain(aboutData.organizationDomain());
    app->setProperty("applicationDisplayName", aboutData.displayName());
    app->setProperty("desktopFileName", aboutData.desktopFileName());
} else {
    qCWarning(KABOUTDATA) << "Could not initialize the equivalent properties of Q*Application: no instance (yet) existing.";
}

}
so I don't see why you want to change diplayname/organization etc.

mlaurent requested changes to this revision.Mon, Oct 14, 3:30 PM
This revision now requires changes to proceed.Mon, Oct 14, 3:30 PM
winterz updated this revision to Diff 67971.Tue, Oct 15, 12:55 PM
winterz edited the summary of this revision. (Show Details)
winterz edited the test plan for this revision. (Show Details)

Thanks to @montel for mentoring me :)

mlaurent accepted this revision.Tue, Oct 15, 12:56 PM
This revision is now accepted and ready to land.Tue, Oct 15, 12:56 PM
This revision was automatically updated to reflect the committed changes.