Buffer: not copyable, add destructor
This commit is contained in:
parent
12d933d896
commit
bace526fa3
|
@ -29,6 +29,12 @@ Buffer::Buffer(const std::string& name, Type type,
|
||||||
compute_lines();
|
compute_lines();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Buffer::~Buffer()
|
||||||
|
{
|
||||||
|
m_windows.clear();
|
||||||
|
assert(m_modification_listeners.empty());
|
||||||
|
}
|
||||||
|
|
||||||
void Buffer::erase(const BufferIterator& begin, const BufferIterator& end)
|
void Buffer::erase(const BufferIterator& begin, const BufferIterator& end)
|
||||||
{
|
{
|
||||||
append_modification(BufferModification(BufferModification::Erase,
|
append_modification(BufferModification(BufferModification::Erase,
|
||||||
|
|
|
@ -104,6 +104,10 @@ public:
|
||||||
|
|
||||||
Buffer(const std::string& name, Type type,
|
Buffer(const std::string& name, Type type,
|
||||||
const BufferString& initial_content = "");
|
const BufferString& initial_content = "");
|
||||||
|
Buffer(const Buffer&) = delete;
|
||||||
|
Buffer(Buffer&&) = delete;
|
||||||
|
Buffer& operator= (const Buffer&) = delete;
|
||||||
|
~Buffer();
|
||||||
|
|
||||||
void begin_undo_group();
|
void begin_undo_group();
|
||||||
void end_undo_group();
|
void end_undo_group();
|
||||||
|
|
Loading…
Reference in New Issue
Block a user