App: minor fix of spacing
This commit is contained in:
parent
26bb702ff6
commit
ecbb576330
|
@ -109,7 +109,7 @@ using namespace zipios;
|
||||||
|
|
||||||
#if FC_DEBUG
|
#if FC_DEBUG
|
||||||
# define FC_LOGFEATUREUPDATE
|
# define FC_LOGFEATUREUPDATE
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
// typedef boost::property<boost::vertex_root_t, DocumentObject* > VertexProperty;
|
// typedef boost::property<boost::vertex_root_t, DocumentObject* > VertexProperty;
|
||||||
typedef boost::adjacency_list <
|
typedef boost::adjacency_list <
|
||||||
|
@ -1507,7 +1507,7 @@ void Document::restore (void)
|
||||||
// without GUI. But if available then follow after all data files of the App document.
|
// without GUI. But if available then follow after all data files of the App document.
|
||||||
signalRestoreDocument(reader);
|
signalRestoreDocument(reader);
|
||||||
reader.readFiles(zipstream);
|
reader.readFiles(zipstream);
|
||||||
|
|
||||||
// reset all touched
|
// reset all touched
|
||||||
for (std::map<std::string,DocumentObject*>::iterator It= d->objectMap.begin();It!=d->objectMap.end();++It) {
|
for (std::map<std::string,DocumentObject*>::iterator It= d->objectMap.begin();It!=d->objectMap.end();++It) {
|
||||||
It->second->connectRelabelSignals();
|
It->second->connectRelabelSignals();
|
||||||
|
@ -1530,7 +1530,7 @@ bool Document::isSaved() const
|
||||||
* matches with the file name where the document is stored to.
|
* matches with the file name where the document is stored to.
|
||||||
* In contrast to Label the method getName() returns the internal name of the document that only
|
* In contrast to Label the method getName() returns the internal name of the document that only
|
||||||
* matches with Label when loading or creating a document because then both are set to the same value.
|
* matches with Label when loading or creating a document because then both are set to the same value.
|
||||||
* Since the internal name cannot be changed during runtime it must differ from the Label after saving
|
* Since the internal name cannot be changed during runtime it must differ from the Label after saving
|
||||||
* the document the first time or saving it under a new file name.
|
* the document the first time or saving it under a new file name.
|
||||||
* @ note More than one document can have the same label name.
|
* @ note More than one document can have the same label name.
|
||||||
* @ note The internal is always guaranteed to be unique because @ref Application::newDocument() checks
|
* @ note The internal is always guaranteed to be unique because @ref Application::newDocument() checks
|
||||||
|
@ -1627,7 +1627,7 @@ Document::getDependencyList(const std::vector<App::DocumentObject*>& objs) const
|
||||||
Vertex v = add_vertex(DepList);
|
Vertex v = add_vertex(DepList);
|
||||||
ObjectMap[*it] = v;
|
ObjectMap[*it] = v;
|
||||||
VertexMap[v] = *it;
|
VertexMap[v] = *it;
|
||||||
}
|
}
|
||||||
|
|
||||||
for (std::vector<DocumentObject*>::const_iterator it = d->objectArray.begin(); it != d->objectArray.end();++it) {
|
for (std::vector<DocumentObject*>::const_iterator it = d->objectArray.begin(); it != d->objectArray.end();++it) {
|
||||||
std::vector<DocumentObject*> outList = (*it)->getOutList();
|
std::vector<DocumentObject*> outList = (*it)->getOutList();
|
||||||
|
@ -2099,7 +2099,7 @@ void Document::remObject(const char* sName)
|
||||||
|
|
||||||
// Before deleting we must nullify all dependant objects
|
// Before deleting we must nullify all dependant objects
|
||||||
breakDependency(pos->second, true);
|
breakDependency(pos->second, true);
|
||||||
|
|
||||||
//and remove the tip if needed
|
//and remove the tip if needed
|
||||||
if(Tip.getValue() && strcmp(Tip.getValue()->getNameInDocument(), sName)==0) {
|
if(Tip.getValue() && strcmp(Tip.getValue()->getNameInDocument(), sName)==0) {
|
||||||
Tip.setValue(nullptr);
|
Tip.setValue(nullptr);
|
||||||
|
@ -2156,7 +2156,7 @@ void Document::_remObject(DocumentObject* pcObject)
|
||||||
signalDeletedObject(*pcObject);
|
signalDeletedObject(*pcObject);
|
||||||
// TODO Check me if it's needed (2015-09-01, Fat-Zer)
|
// TODO Check me if it's needed (2015-09-01, Fat-Zer)
|
||||||
pcObject->StatusBits.reset (ObjectStatus::Delete); // Unset the bit to be on the safe side
|
pcObject->StatusBits.reset (ObjectStatus::Delete); // Unset the bit to be on the safe side
|
||||||
|
|
||||||
//remove the tip if needed
|
//remove the tip if needed
|
||||||
if(Tip.getValue() == pcObject) {
|
if(Tip.getValue() == pcObject) {
|
||||||
Tip.setValue(nullptr);
|
Tip.setValue(nullptr);
|
||||||
|
|
|
@ -85,7 +85,7 @@ public:
|
||||||
PropertyUUID Uid;
|
PropertyUUID Uid;
|
||||||
/** License string
|
/** License string
|
||||||
* Holds the short license string for the Item, e.g. CC-BY
|
* Holds the short license string for the Item, e.g. CC-BY
|
||||||
* for the Creative Commons license suit.
|
* for the Creative Commons license suit.
|
||||||
*/
|
*/
|
||||||
App::PropertyString License;
|
App::PropertyString License;
|
||||||
/// License descripton/contract URL
|
/// License descripton/contract URL
|
||||||
|
@ -121,7 +121,7 @@ public:
|
||||||
boost::signal<void (const App::Document&)> signalRedo;
|
boost::signal<void (const App::Document&)> signalRedo;
|
||||||
/** signal on load/save document
|
/** signal on load/save document
|
||||||
* this signal is given when the document gets streamed.
|
* this signal is given when the document gets streamed.
|
||||||
* you can use this hook to write additional information in
|
* you can use this hook to write additional information in
|
||||||
* the file (like the Gui::Document it does).
|
* the file (like the Gui::Document it does).
|
||||||
*/
|
*/
|
||||||
boost::signal<void (Base::Writer &)> signalSaveDocument;
|
boost::signal<void (Base::Writer &)> signalSaveDocument;
|
||||||
|
@ -248,16 +248,16 @@ public:
|
||||||
/** @name methods for the UNDO REDO and Transaction handling */
|
/** @name methods for the UNDO REDO and Transaction handling */
|
||||||
//@{
|
//@{
|
||||||
/// switch the level of Undo/Redo
|
/// switch the level of Undo/Redo
|
||||||
void setUndoMode(int iMode);
|
void setUndoMode(int iMode);
|
||||||
/// switch the level of Undo/Redo
|
/// switch the level of Undo/Redo
|
||||||
int getUndoMode(void) const;
|
int getUndoMode(void) const;
|
||||||
/// switch the tranaction mode
|
/// switch the tranaction mode
|
||||||
void setTransactionMode(int iMode);
|
void setTransactionMode(int iMode);
|
||||||
/// Open a new command Undo/Redo, an UTF-8 name can be specified
|
/// Open a new command Undo/Redo, an UTF-8 name can be specified
|
||||||
void openTransaction(const char* name=0);
|
void openTransaction(const char* name=0);
|
||||||
// Commit the Command transaction. Do nothing If there is no Command transaction open.
|
// Commit the Command transaction. Do nothing If there is no Command transaction open.
|
||||||
void commitTransaction();
|
void commitTransaction();
|
||||||
/// Abort the actually running transaction.
|
/// Abort the actually running transaction.
|
||||||
void abortTransaction();
|
void abortTransaction();
|
||||||
/// Check if a transaction is open
|
/// Check if a transaction is open
|
||||||
bool hasPendingTransaction() const;
|
bool hasPendingTransaction() const;
|
||||||
|
@ -312,7 +312,7 @@ public:
|
||||||
friend class Transaction;
|
friend class Transaction;
|
||||||
friend class TransactionObject;
|
friend class TransactionObject;
|
||||||
|
|
||||||
/// Destruction
|
/// Destruction
|
||||||
virtual ~Document();
|
virtual ~Document();
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
|
|
|
@ -59,7 +59,7 @@ DocumentObject::DocumentObject(void)
|
||||||
DocumentObject::~DocumentObject(void)
|
DocumentObject::~DocumentObject(void)
|
||||||
{
|
{
|
||||||
if (!PythonObject.is(Py::_None())){
|
if (!PythonObject.is(Py::_None())){
|
||||||
// Remark: The API of Py::Object has been changed to set whether the wrapper owns the passed
|
// Remark: The API of Py::Object has been changed to set whether the wrapper owns the passed
|
||||||
// Python object or not. In the constructor we forced the wrapper to own the object so we need
|
// Python object or not. In the constructor we forced the wrapper to own the object so we need
|
||||||
// not to dec'ref the Python object any more.
|
// not to dec'ref the Python object any more.
|
||||||
// But we must still invalidate the Python object because it need not to be
|
// But we must still invalidate the Python object because it need not to be
|
||||||
|
@ -115,7 +115,7 @@ const char* DocumentObject::getStatusString(void) const
|
||||||
const char *DocumentObject::getNameInDocument(void) const
|
const char *DocumentObject::getNameInDocument(void) const
|
||||||
{
|
{
|
||||||
// Note: It can happen that we query the internal name of an object even if it is not
|
// Note: It can happen that we query the internal name of an object even if it is not
|
||||||
// part of a document (anymore). This is the case e.g. if we have a reference in Python
|
// part of a document (anymore). This is the case e.g. if we have a reference in Python
|
||||||
// to an object that has been removed from the document. In this case we should rather
|
// to an object that has been removed from the document. In this case we should rather
|
||||||
// return 0.
|
// return 0.
|
||||||
//assert(pcNameInDocument);
|
//assert(pcNameInDocument);
|
||||||
|
@ -221,7 +221,7 @@ PyObject *DocumentObject::getPyObject(void)
|
||||||
// ref counter is set to 1
|
// ref counter is set to 1
|
||||||
PythonObject = Py::Object(new DocumentObjectPy(this),true);
|
PythonObject = Py::Object(new DocumentObjectPy(this),true);
|
||||||
}
|
}
|
||||||
return Py::new_reference_to(PythonObject);
|
return Py::new_reference_to(PythonObject);
|
||||||
}
|
}
|
||||||
|
|
||||||
std::vector<PyObject *> DocumentObject::getPySubObjects(const std::vector<std::string>&) const
|
std::vector<PyObject *> DocumentObject::getPySubObjects(const std::vector<std::string>&) const
|
||||||
|
|
Loading…
Reference in New Issue
Block a user