Files
qt-creator/src/plugins/mcusupport/settingshandler.h
Yasser Grimes 7aec8c0b14 McuSupport: Add dialog for Qt MCUs kit creation status and help
The status of automatically created kits or manually updated ones is
displayed in "General Messages" along with other messages making it
difficult to know if something went wrong with kit creation.

To avoid showing a dialog at QtC startup an InfoBar message was added
with a detail button that will open a dialog listing all the messages
with their platform, package and Os providing an easy button to go to
the MCU Option page to fix the package of a help button pointing to the
prerequisites documentation.

Fixes: QTCREATORBUG-28920
Change-Id: I20c30d968fbd2d4c6d10d16504a51e7201a2db3b
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
2023-05-26 07:02:55 +00:00

35 lines
1.0 KiB
C++

// Copyright (C) 2022 The Qt Company Ltd.
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only WITH Qt-GPL-exception-1.0
#pragma once
#include <QSettings>
#include <QSharedPointer>
#include <QString>
namespace Utils {
class FilePath;
} //namespace Utils
namespace McuSupport::Internal {
class SettingsHandler
{
public:
using Ptr = QSharedPointer<SettingsHandler>;
virtual ~SettingsHandler() = default;
virtual Utils::FilePath getPath(const QString &settingsKey,
QSettings::Scope scope,
const Utils::FilePath &m_defaultPath) const;
virtual bool write(const QString &settingsKey,
const Utils::FilePath &path,
const Utils::FilePath &defaultPath) const;
virtual bool isAutomaticKitCreationEnabled() const;
void setAutomaticKitCreation(bool isEnabled);
void setInitialPlatformName(const QString &platform);
QString initialPlatformName() const;
}; //class SettingsHandler
} // namespace McuSupport::Internal