From ec4358c796648cc83368e643a06fe8be28700217 Mon Sep 17 00:00:00 2001 From: stefan <stefan@5a81b35b-ba03-0410-adc8-b2c5c5119f08> Date: Mon, 3 May 2010 10:53:02 +0000 Subject: [PATCH] Adapt export of SequenceViewerV2 to new sip style git-svn-id: https://dng.biozentrum.unibas.ch/svn/openstructure/trunk@2156 5a81b35b-ba03-0410-adc8-b2c5c5119f08 --- modules/gui/pymod/export_sequence_viewer.cc | 14 +++++++++----- modules/gui/pymod/export_sequence_viewerV2.cc | 14 +++++++++----- 2 files changed, 18 insertions(+), 10 deletions(-) diff --git a/modules/gui/pymod/export_sequence_viewer.cc b/modules/gui/pymod/export_sequence_viewer.cc index 72102350f..e6127166c 100644 --- a/modules/gui/pymod/export_sequence_viewer.cc +++ b/modules/gui/pymod/export_sequence_viewer.cc @@ -18,18 +18,22 @@ //------------------------------------------------------------------------------ #include <boost/python.hpp> -#include "sequence_viewer_proxyV2.hh" +#include <ost/gui/sequence_viewer/sequence_viewer.hh> + +#include "sip_handler.hh" using namespace boost::python; using namespace ost; using namespace ost::gui; -void export_SequenceViewerV2() +void export_SequenceViewer() { - class_<SequenceViewerProxyV2, bases<SipHandlerBase> >("SequenceViewerV2", init<>()) - .def("Show", &SequenceViewerProxyV2::Show) - .def("Hide", &SequenceViewerProxyV2::Hide) + class_<SequenceViewer, boost::noncopyable >("SequenceViewer", no_init) + .def("Show", &SequenceViewer::show) + .def("Hide", &SequenceViewer::hide) + .def("GetQObject",&get_py_qobject<SequenceViewer>) + .add_property("qobject", &get_py_qobject<SequenceViewer>) ; } diff --git a/modules/gui/pymod/export_sequence_viewerV2.cc b/modules/gui/pymod/export_sequence_viewerV2.cc index cc53523e6..cd010952f 100644 --- a/modules/gui/pymod/export_sequence_viewerV2.cc +++ b/modules/gui/pymod/export_sequence_viewerV2.cc @@ -18,18 +18,22 @@ //------------------------------------------------------------------------------ #include <boost/python.hpp> -#include "sequence_viewer_proxy.hh" +#include <ost/gui/sequence/sequence_viewer.hh> + +#include "sip_handler.hh" using namespace boost::python; using namespace ost; using namespace ost::gui; -void export_SequenceViewer() +void export_SequenceViewerV2() { - class_<SequenceViewerProxy, bases<SipHandlerBase> >("SequenceViewer") - .def("Show", &SequenceViewerProxy::Show) - .def("Hide", &SequenceViewerProxy::Hide) + class_<SequenceViewerV2, boost::noncopyable >("SequenceViewerV2",init<>()) + .def("Show", &SequenceViewerV2::show) + .def("Hide", &SequenceViewerV2::hide) + .def("GetQObject",&get_py_qobject<SequenceViewerV2>) + .add_property("qobject", &get_py_qobject<SequenceViewerV2>) ; } -- GitLab