start moving this towards sensibility

not much to see yet, but people are looking at this and understandably
scratching their head since it's not obvious that a lot of this was
sketching versus implementing... well, that's starting to change.

svn path=/trunk/KDE/kdebase/workspace/plasma/lib/; revision=576845
This commit is contained in:
Aaron J. Seigo 2006-08-24 22:52:05 +00:00
parent f2f121c254
commit e3fd26c7bd
3 changed files with 6 additions and 11 deletions

View File

@ -47,7 +47,7 @@ class Applet::Private
{
foreach (const QString& engine, loadedEngines)
{
Interface::interface()->unloadDataEngine(engine);
Interface::self()->unloadDataEngine(engine);
}
}
@ -88,13 +88,11 @@ KSharedConfig::Ptr Applet::appletConfig() const
return d->appletConfig;
}
KSharedConfig::Ptr Applet::globalAppletConfig() const
KSharedConfig::Ptr Applet::AppletConfig() const
{
if (!d->globalConfig)
{
QString file = locateLocal("config",
"plasma_" + globalName() + "rc",
true);
QString file = locateLocal("config", "plasma_" + globalName() + "rc");
d->globalConfig = KSharedConfig::openConfig(file, false, true);
}

View File

@ -67,12 +67,11 @@ class DataEngine : public QObject
void ref();
void deref();
bool used();
protected:
virtual void init();
virtual void cleanup();
virtual DataEngine* engine() = 0;
virtual
private:
QAtomic ref;
@ -89,5 +88,3 @@ class DataEngine : public QObject
#endif // multiple inclusion guard
#endif

View File

@ -25,10 +25,10 @@ namespace Plasma
class Interface
{
public:
static Interface* interface() { return m_interface; }
static Interface* self() { return m_interface; }
virtual bool loadDataEngine(const QString& name) = 0;
virtual bool unloadDataEngine(const QString& name) = 0;
virtual void unloadDataEngine(const QString& name) = 0;
protected:
Interface() : m_interface(0) {}