LeechCraft Monocle
0.6.70-18450-gabe19ee3b0
Modular document viewer for LeechCraft
Toggle main menu visibility
Loading...
Searching...
No Matches
isaveabledocument.h
Go to the documentation of this file.
1
/**********************************************************************
2
* LeechCraft - modular cross-platform feature rich internet client.
3
* Copyright (C) 2006-2014 Georg Rudoy
4
*
5
* Distributed under the Boost Software License, Version 1.0.
6
* (See accompanying file LICENSE or copy at https://www.boost.org/LICENSE_1_0.txt)
7
**********************************************************************/
8
9
#pragma once
10
11
#include <QtPlugin>
12
13
namespace
LC
14
{
15
namespace
Monocle
16
{
30
class
ISaveableDocument
31
{
32
protected
:
33
virtual
~ISaveableDocument
() =
default
;
34
public
:
38
struct
SaveQueryResult
39
{
42
bool
CanSave_
;
43
50
QString
Reason_
;
51
};
52
61
virtual
SaveQueryResult
CanSave
()
const
= 0;
62
72
virtual
bool
Save
(
const
QString& path) = 0;
73
};
74
}
75
}
76
77
Q_DECLARE_INTERFACE (
LC::Monocle::ISaveableDocument
,
78
"org.LeechCraft.Monocle.ISaveableDocument/1.0"
)
LC::Monocle::ISaveableDocument
Interface for documents that can be saved.
Definition
isaveabledocument.h:31
LC::Monocle::ISaveableDocument::CanSave
virtual SaveQueryResult CanSave() const =0
Checks whether this document can be saved.
LC::Monocle::ISaveableDocument::~ISaveableDocument
virtual ~ISaveableDocument()=default
LC::Monocle::ISaveableDocument::Save
virtual bool Save(const QString &path)=0
Saves the document at the given path.
LC::Monocle
Definition
coordsbase.h:15
LC
Definition
coordsbase.h:15
LC::Monocle::ISaveableDocument::SaveQueryResult
Describes the result of check for the possibility of saving.
Definition
isaveabledocument.h:39
LC::Monocle::ISaveableDocument::SaveQueryResult::CanSave_
bool CanSave_
Whether the document can be saved.
Definition
isaveabledocument.h:42
LC::Monocle::ISaveableDocument::SaveQueryResult::Reason_
QString Reason_
Human-readable reason string.
Definition
isaveabledocument.h:50
src
plugins
monocle
interfaces
monocle
isaveabledocument.h
Generated by
1.17.0