Merge remote-tracking branch 'refs/remotes/origin/jriegel/NewWinBuild' into jriegel/Rift

This commit is contained in:
jriegel
2014-08-27 17:48:59 +02:00
73 changed files with 12586 additions and 917 deletions

View File

@@ -38,7 +38,8 @@ if(MSVC)
optimized ${SOQT_LIBRARY_RELEASE}
${QT_DEBUG_LIBRARIES}
${QT_LIBRARIES}
QtUiTools.lib
optimized QtUiTools.lib
debug QtUiToolsd.lib
${OPENGL_gl_LIBRARY}
)
else(MSVC)

View File

@@ -115,8 +115,8 @@
#if defined(Q_OS_WIN32)
#define slots
#include <private/qmainwindowlayout_p.h>
#include <private/qwidgetresizehandler_p.h>
//#include <private/qmainwindowlayout_p.h>
//#include <private/qwidgetresizehandler_p.h>
#endif
using namespace Gui;
@@ -412,7 +412,7 @@ MainWindow::MainWindow(QWidget * parent, Qt::WFlags f)
(QString::fromAscii(QT_TRANSLATE_NOOP("QDockWidget","Python console")));
pDockMgr->registerDockWindow("Std_PythonView", pcPython);
#if defined(Q_OS_WIN32)
#if 0 //defined(Q_OS_WIN32) this porsion of code is not able to run with a vanilla Qtlib build on Windows. Since it is not build on Linux I pressume its not needed.... (JR 8.2014)
// add our own QTabBar-derived class to the main window layout
// NOTE: This uses some private stuff from QMainWindow which doesn't
// seem to be accessible on all platforms.

View File

@@ -236,7 +236,7 @@ bool TaskWatcherPython::shouldShow()
try {
if (watcher.hasAttr(std::string("shouldShow"))) {
Py::Callable method(watcher.getAttr(std::string("shouldShow")));
Py::Tuple args(0);
Py::Tuple args;
Py::Boolean ret(method.apply(args));
return (bool)ret;
}
@@ -326,7 +326,7 @@ void TaskDialogPython::open()
try {
if (dlg.hasAttr(std::string("open"))) {
Py::Callable method(dlg.getAttr(std::string("open")));
Py::Tuple args(0);
Py::Tuple args;
method.apply(args);
}
}
@@ -359,7 +359,7 @@ bool TaskDialogPython::accept()
try {
if (dlg.hasAttr(std::string("accept"))) {
Py::Callable method(dlg.getAttr(std::string("accept")));
Py::Tuple args(0);
Py::Tuple args;
Py::Boolean ret(method.apply(args));
return (bool)ret;
}
@@ -378,7 +378,7 @@ bool TaskDialogPython::reject()
try {
if (dlg.hasAttr(std::string("reject"))) {
Py::Callable method(dlg.getAttr(std::string("reject")));
Py::Tuple args(0);
Py::Tuple args;
Py::Boolean ret(method.apply(args));
return (bool)ret;
}
@@ -397,7 +397,7 @@ void TaskDialogPython::helpRequested()
try {
if (dlg.hasAttr(std::string("helpRequested"))) {
Py::Callable method(dlg.getAttr(std::string("helpRequested")));
Py::Tuple args(0);
Py::Tuple args;
method.apply(args);
}
}
@@ -413,7 +413,7 @@ QDialogButtonBox::StandardButtons TaskDialogPython::getStandardButtons(void) con
try {
if (dlg.hasAttr(std::string("getStandardButtons"))) {
Py::Callable method(dlg.getAttr(std::string("getStandardButtons")));
Py::Tuple args(0);
Py::Tuple args;
Py::Int ret(method.apply(args));
int value = (int)ret;
return QDialogButtonBox::StandardButtons(value);
@@ -437,7 +437,7 @@ bool TaskDialogPython::isAllowedAlterDocument(void) const
try {
if (dlg.hasAttr(std::string("isAllowedAlterDocument"))) {
Py::Callable method(dlg.getAttr(std::string("isAllowedAlterDocument")));
Py::Tuple args(0);
Py::Tuple args;
Py::Boolean ret(method.apply(args));
return (bool)ret;
}
@@ -456,7 +456,7 @@ bool TaskDialogPython::isAllowedAlterView(void) const
try {
if (dlg.hasAttr(std::string("isAllowedAlterView"))) {
Py::Callable method(dlg.getAttr(std::string("isAllowedAlterView")));
Py::Tuple args(0);
Py::Tuple args;
Py::Boolean ret(method.apply(args));
return (bool)ret;
}
@@ -475,7 +475,7 @@ bool TaskDialogPython::isAllowedAlterSelection(void) const
try {
if (dlg.hasAttr(std::string("isAllowedAlterSelection"))) {
Py::Callable method(dlg.getAttr(std::string("isAllowedAlterSelection")));
Py::Tuple args(0);
Py::Tuple args;
Py::Boolean ret(method.apply(args));
return (bool)ret;
}
@@ -494,7 +494,7 @@ bool TaskDialogPython::needsFullSpace() const
try {
if (dlg.hasAttr(std::string("needsFullSpace"))) {
Py::Callable method(dlg.getAttr(std::string("needsFullSpace")));
Py::Tuple args(0);
Py::Tuple args;
Py::Boolean ret(method.apply(args));
return (bool)ret;
}

View File

@@ -245,7 +245,7 @@ QIcon ViewProviderPythonFeatureImp::getIcon() const
Py::Object vp = static_cast<App::PropertyPythonObject*>(proxy)->getValue();
if (vp.hasAttr(std::string("getIcon"))) {
Py::Callable method(vp.getAttr(std::string("getIcon")));
Py::Tuple args(0);
Py::Tuple args;
Py::String str(method.apply(args));
std::string content = str.as_std_string();
QPixmap icon;
@@ -296,7 +296,7 @@ std::vector<App::DocumentObject*> ViewProviderPythonFeatureImp::claimChildren(co
Py::Object vp = static_cast<App::PropertyPythonObject*>(proxy)->getValue();
if (vp.hasAttr(std::string("claimChildren"))) {
Py::Callable method(vp.getAttr(std::string("claimChildren")));
Py::Tuple args(0);
Py::Tuple args;
Py::Sequence list(method.apply(args));
for (Py::Sequence::iterator it = list.begin(); it != list.end(); ++it) {
PyObject* item = (*it).ptr();
@@ -528,7 +528,7 @@ void ViewProviderPythonFeatureImp::attach(App::DocumentObject *pcObject)
if (vp.hasAttr(std::string("attach"))) {
if (vp.hasAttr("__object__")) {
Py::Callable method(vp.getAttr(std::string("attach")));
Py::Tuple args(0);
Py::Tuple args;
method.apply(args);
}
else {
@@ -647,7 +647,7 @@ const char* ViewProviderPythonFeatureImp::getDefaultDisplayMode() const
Py::Object vp = static_cast<App::PropertyPythonObject*>(proxy)->getValue();
if (vp.hasAttr(std::string("getDefaultDisplayMode"))) {
Py::Callable method(vp.getAttr(std::string("getDefaultDisplayMode")));
Py::Tuple args(0);
Py::Tuple args;
Py::String str(method.apply(args));
if (str.isUnicode())
str = str.encode("ascii"); // json converts strings into unicode
@@ -676,7 +676,7 @@ std::vector<std::string> ViewProviderPythonFeatureImp::getDisplayModes(void) con
if (vp.hasAttr(std::string("getDisplayModes"))) {
if (vp.hasAttr("__object__")) {
Py::Callable method(vp.getAttr(std::string("getDisplayModes")));
Py::Tuple args(0);
Py::Tuple args;
Py::Sequence list(method.apply(args));
for (Py::Sequence::iterator it = list.begin(); it != list.end(); ++it) {
Py::String str(*it);