goldendict-ng/globalbroadcaster.cpp

23 lines
449 B
C++
Raw Normal View History

#include "globalbroadcaster.h"
#include <QGlobalStatic>
2022-04-23 08:15:23 +00:00
Q_GLOBAL_STATIC( GlobalBroadcaster, bdcaster )
GlobalBroadcaster::GlobalBroadcaster( QObject * parent ) : QObject( parent )
{
}
2022-04-23 08:15:23 +00:00
GlobalBroadcaster * GlobalBroadcaster::instance()
{
return bdcaster;
}
void GlobalBroadcaster::setPreference( Config::Preferences * p )
{
preference = p;
}
Config::Preferences * GlobalBroadcaster::getPreference()
{
return preference;
}
// namespace global