yacreader/common/yacreader_global.cpp
2014-11-06 09:03:01 -08:00

30 lines
610 B
C++

#include "yacreader_global.h"
#include <QAction>
using namespace YACReader;
QString YACReader::getSettingsPath()
{
#if QT_VERSION >= 0x050000
return QStandardPaths::writableLocation(QStandardPaths::DataLocation);
#else
return QDesktopServices::storageLocation(QDesktopServices::DataLocation);
#endif
}
void YACReader::addSperator(QWidget *w)
{
QAction * separator = new QAction(w);
separator->setSeparator(true);
w->addAction(separator);
}
QAction * YACReader::createSeparator()
{
QAction * a = new QAction(0);
a->setSeparator(true);
return a;
}