modernize C++: use using
This commit is contained in:
@@ -24,10 +24,20 @@
|
||||
#ifndef APP_DOCUMENTOBSERVERPYTHON_H
|
||||
#define APP_DOCUMENTOBSERVERPYTHON_H
|
||||
|
||||
#include <FCGlobal.h>
|
||||
#include <boost/signals2.hpp>
|
||||
#include <CXX/Objects.hxx>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
|
||||
namespace App
|
||||
{
|
||||
|
||||
class Document;
|
||||
class DocumentObject;
|
||||
class ExtensionContainer;
|
||||
class Property;
|
||||
|
||||
/**
|
||||
* The DocumentObserverPython class is used to notify registered Python instances
|
||||
* whenever something happens to a document, like creation, destruction, adding or
|
||||
@@ -111,13 +121,13 @@ private:
|
||||
Py::Object inst;
|
||||
static std::vector<DocumentObserverPython*> _instances;
|
||||
|
||||
typedef struct PythonObject {
|
||||
using Connection = struct PythonObject {
|
||||
boost::signals2::scoped_connection slot;
|
||||
Py::Object py;
|
||||
PyObject* ptr() {
|
||||
return py.ptr();
|
||||
}
|
||||
} Connection;
|
||||
};
|
||||
|
||||
Connection pyCreatedDocument;
|
||||
Connection pyDeletedDocument;
|
||||
|
||||
Reference in New Issue
Block a user