2020-04-17 00:24:32 +02:00
|
|
|
/* === This file is part of Calamares - <https://github.com/calamares> ===
|
|
|
|
*
|
2020-07-30 10:26:58 +02:00
|
|
|
* SPDX-FileCopyrightText: 2020 Adriaan de Groot <groot@kde.org>
|
|
|
|
* SPDX-License-Identifier: GPL-3.0-or-later
|
2020-04-17 00:24:32 +02:00
|
|
|
*
|
|
|
|
* Calamares is free software: you can redistribute it and/or modify
|
|
|
|
* it under the terms of the GNU General Public License as published by
|
|
|
|
* the Free Software Foundation, either version 3 of the License, or
|
|
|
|
* (at your option) any later version.
|
|
|
|
*
|
|
|
|
* Calamares is distributed in the hope that it will be useful,
|
|
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
|
* GNU General Public License for more details.
|
|
|
|
*
|
|
|
|
* You should have received a copy of the GNU General Public License
|
|
|
|
* along with Calamares. If not, see <http://www.gnu.org/licenses/>.
|
|
|
|
*/
|
|
|
|
|
|
|
|
#ifndef PARTITION_CONFIG_H
|
|
|
|
#define PARTITION_CONFIG_H
|
|
|
|
|
|
|
|
#include "core/PartitionActions.h"
|
|
|
|
|
|
|
|
#include <QObject>
|
|
|
|
#include <QSet>
|
|
|
|
|
|
|
|
class Config : public QObject
|
|
|
|
{
|
|
|
|
Q_OBJECT
|
|
|
|
|
|
|
|
public:
|
2020-05-18 13:07:12 +02:00
|
|
|
Config( QObject* parent );
|
2020-04-17 00:24:32 +02:00
|
|
|
virtual ~Config() = default;
|
|
|
|
|
2020-05-18 13:07:12 +02:00
|
|
|
void setConfigurationMap( const QVariantMap& );
|
|
|
|
void updateGlobalStorage() const;
|
2020-04-17 00:24:32 +02:00
|
|
|
|
2020-07-30 10:26:58 +02:00
|
|
|
PartitionActions::Choices::SwapChoiceSet swapChoices() const { return m_swapChoices; }
|
|
|
|
|
2020-07-30 11:36:59 +02:00
|
|
|
/**
|
|
|
|
* @brief What kind of installation (partitioning) is requested **initially**?
|
|
|
|
*
|
|
|
|
* @return the partitioning choice (may by @c NoChoice)
|
|
|
|
*/
|
|
|
|
PartitionActions::Choices::InstallChoice initialInstallChoice() const { return m_initialInstallChoice; }
|
|
|
|
|
2020-05-18 13:07:12 +02:00
|
|
|
private:
|
2020-05-18 14:12:50 +02:00
|
|
|
PartitionActions::Choices::SwapChoiceSet m_swapChoices;
|
2020-07-30 11:36:59 +02:00
|
|
|
PartitionActions::Choices::InstallChoice m_initialInstallChoice = PartitionActions::Choices::NoChoice;
|
2020-04-17 00:24:32 +02:00
|
|
|
qreal m_requiredStorageGiB = 0.0; // May duplicate setting in the welcome module
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
#endif
|