View Issue Details
| ID | Project | Category | View Status | Date Submitted | Last Update |
|---|---|---|---|---|---|
| 0006474 | Scribus | Plug-ins | public | 2007-11-12 01:40 | 2007-11-13 23:20 |
| Reporter | h_a_j_s | Assigned To | subik | ||
| Priority | normal | Severity | minor | Reproducibility | always |
| Status | closed | Resolution | fixed | ||
| Product Version | 1.3.5svn | ||||
| Fixed in Version | 1.3.5svn | ||||
| Summary | 0006474: myplugin failed to compile and | ||||
| Description | The example plugin "myplugin" does not compile and work after adding it with ADD_SUBDIRECTORY(myplugin) in scribus/plugins/CMakeLists.txt | ||||
| Additional Information | I fixed it. The attached patch correctly creates the moc-files so that all symbols are available. Additionally I changed the code to remove the dependency on Qt3Suppport. | ||||
| Tags | No tags attached. | ||||
| Attached Files | myplugin.patch (1,118 bytes)
diff -u trunk/scribus/plugins/myplugin/CMakeLists.txt work/scribus/plugins/myplugin/CMakeLists.txt
--- trunk/scribus/plugins/myplugin/CMakeLists.txt 2007-11-12 02:13:54.000000000 +0100
+++ work/scribus/plugins/myplugin/CMakeLists.txt 2007-11-12 02:04:26.000000000 +0100
@@ -15,7 +15,7 @@
SET(SCRIBUS_MY_PLUGIN "myplugin")
-SCRIBUS_QT_WRAP_CPP(MY_PLUGIN_MOC_SOURCES ${MY_PLUGIN_MOC_CLASSES})
+QT4_WRAP_CPP(MY_PLUGIN_MOC_SOURCES ${MY_PLUGIN_MOC_CLASSES})
ADD_LIBRARY(${SCRIBUS_MY_PLUGIN} MODULE ${MY_PLUGIN_SOURCES} ${MY_PLUGIN_MOC_SOURCES})
diff -u trunk/scribus/plugins/myplugin/mypluginimpl.cpp work/scribus/plugins/myplugin/mypluginimpl.cpp
--- trunk/scribus/plugins/myplugin/mypluginimpl.cpp 2007-11-12 02:13:54.000000000 +0100
+++ work/scribus/plugins/myplugin/mypluginimpl.cpp 2007-11-12 01:46:54.000000000 +0100
@@ -11,8 +11,9 @@
#include <QMessageBox>
// Initialize members here, if any
-MyPluginImpl::MyPluginImpl() : QObject(0, "MyPluginImpl")
+MyPluginImpl::MyPluginImpl() : QObject(0)
{
+ setObjectName("MyPluginImpl");
}
bool MyPluginImpl::run(const QString & target, ScribusDoc* doc)
myplugin2.patch (1,657 bytes)
diff -u trunk/scribus/plugins/myplugin/CMakeLists.txt work/scribus/plugins/myplugin/CMakeLists.txt
--- trunk/scribus/plugins/myplugin/CMakeLists.txt 2007-11-12 02:13:54.000000000 +0100
+++ work/scribus/plugins/myplugin/CMakeLists.txt 2007-11-12 02:04:26.000000000 +0100
@@ -15,7 +15,7 @@
SET(SCRIBUS_MY_PLUGIN "myplugin")
-SCRIBUS_QT_WRAP_CPP(MY_PLUGIN_MOC_SOURCES ${MY_PLUGIN_MOC_CLASSES})
+QT4_WRAP_CPP(MY_PLUGIN_MOC_SOURCES ${MY_PLUGIN_MOC_CLASSES})
ADD_LIBRARY(${SCRIBUS_MY_PLUGIN} MODULE ${MY_PLUGIN_SOURCES} ${MY_PLUGIN_MOC_SOURCES})
diff -u trunk/scribus/plugins/myplugin/myplugin.h work/scribus/plugins/myplugin/myplugin.h
--- trunk/scribus/plugins/myplugin/myplugin.h 2007-11-12 02:13:54.000000000 +0100
+++ work/scribus/plugins/myplugin/myplugin.h 2007-11-12 02:55:43.000000000 +0100
@@ -4,8 +4,8 @@
a copyright and/or license notice that predates the release of Scribus 1.3.2
for which a new license (GPL+exception) is in place.
*/
-#ifndef COLORWHEEL_H
-#define COLORWHEEL_H
+#ifndef MYPLUGIN_H
+#define MYPLUGIN_H
#include "pluginapi.h"
#include "scplugin.h"
diff -u trunk/scribus/plugins/myplugin/mypluginimpl.cpp work/scribus/plugins/myplugin/mypluginimpl.cpp
--- trunk/scribus/plugins/myplugin/mypluginimpl.cpp 2007-11-12 02:13:54.000000000 +0100
+++ work/scribus/plugins/myplugin/mypluginimpl.cpp 2007-11-12 01:46:54.000000000 +0100
@@ -11,8 +11,9 @@
#include <QMessageBox>
// Initialize members here, if any
-MyPluginImpl::MyPluginImpl() : QObject(0, "MyPluginImpl")
+MyPluginImpl::MyPluginImpl() : QObject(0)
{
+ setObjectName("MyPluginImpl");
}
bool MyPluginImpl::run(const QString & target, ScribusDoc* doc)
| ||||
| Patch | |||||
| Date Modified | Username | Field | Change |
|---|---|---|---|
| 2007-11-12 01:40 | h_a_j_s | New Issue | |
| 2007-11-12 01:40 | h_a_j_s | File Added: myplugin.patch | |
| 2007-11-12 01:59 | h_a_j_s | File Added: myplugin2.patch | |
| 2007-11-12 01:59 | h_a_j_s | Note Added: 0017901 | |
| 2007-11-12 09:40 | subik | Status | new => assigned |
| 2007-11-12 09:40 | subik | Assigned To | => subik |
| 2007-11-12 09:45 | subik | Status | assigned => resolved |
| 2007-11-12 09:45 | subik | Fixed in Version | => 1.3.5svn |
| 2007-11-12 09:45 | subik | Resolution | open => fixed |
| 2007-11-12 09:45 | subik | Note Added: 0017902 | |
| 2007-11-13 23:20 | cbradney | Status | resolved => closed |