qBittorrent/qcm/qt4.qcm
2011-01-01 17:14:52 +00:00

26 lines
692 B
Text

/*
-----BEGIN QCMOD-----
name: Qt >= 4.5
arg: enable-debug, Enable debug mode
arg: disable-gui, Disable qBittorrent Graphical user interface for headless running
-----END QCMOD-----
*/
class qc_qt4 : public ConfObj
{
public:
qc_qt4(Conf *c) : ConfObj(c) {}
QString name() const { return "Qt >= 4.5"; }
QString shortname() const { return "Qt 4.5"; }
bool exec()
{
// NOX mode
if(!conf->getenv("QC_DISABLE_GUI").isEmpty()) {
conf->addExtra("CONFIG += nox");
}
// Debug mode
if(!conf->getenv("QC_ENABLE_DEBUG").isEmpty()) {
conf->addExtra("CONFIG += debug");
}
return(QT_VERSION >= 0x040500);
}
};