1
0
Fork 0
mirror of https://github.com/OpenMW/openmw.git synced 2025-01-20 16:53:55 +00:00
openmw/apps/opencs/model/tools/mergeoperation.hpp

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

44 lines
898 B
C++
Raw Normal View History

#ifndef CSM_TOOLS_MERGEOPERATION_H
#define CSM_TOOLS_MERGEOPERATION_H
#include <memory>
#include <components/to_utf8/to_utf8.hpp>
#include "../doc/operation.hpp"
#include "mergestate.hpp"
namespace CSMDoc
{
class Document;
}
namespace CSMTools
{
class MergeOperation : public CSMDoc::Operation
{
Q_OBJECT
MergeState mState;
public:
MergeOperation(CSMDoc::Document& document, ToUTF8::FromType encoding);
/// \attention Do not call this function while a merge is running.
void setTarget(std::unique_ptr<CSMDoc::Document> document);
protected slots:
void operationDone() override;
signals:
/// \attention When this signal is emitted, *this hands over the ownership of the
/// document. This signal must be handled to avoid a leak.
void mergeDone(CSMDoc::Document* document);
};
}
#endif