1 2 3 4 5 6 7 8 9 10 11 12
#include "plugin.h" #include <QFile> QString plugin1::getResource() { return "hello world"; } #if QT_VERSION < 0x050000 Q_EXPORT_PLUGIN2(Plugin1, plugin1) #endif