blob: 30efb7e09eb06f401ac62434f5c0ffc37bcfa412 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
|
// Copyright (C) 2024 The Qt Company Ltd.
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only WITH Qt-GPL-exception-1.0
#pragma once
#include "buildsettings.h"
#include <projectexplorer/buildconfiguration.h>
#include <utils/aspects.h>
#include <utils/layoutbuilder.h>
#include <QPointer>
#include <QPushButton>
#include <QWidget>
namespace ProjectExplorer {
class Project;
}
namespace Coco::Internal {
class CocoProjectWidget : public QWidget
{
Q_OBJECT
public:
enum ConfigurationState { configDone, configEdited, configRunning, configStopped };
explicit CocoProjectWidget(ProjectExplorer::Project *project, ProjectExplorer::BuildConfiguration *buildConfig);
protected:
void showEvent(QShowEvent *event) override;
public slots:
void buildSystemUpdated(ProjectExplorer::BuildSystem *bs);
void configurationErrorOccurred(const QString &error);
private slots:
void onCoverageGroupBoxClicked();
void onSaveButtonClicked();
void onRevertButtonClicked();
void onExcludeFileButtonClicked();
void onExcludeDirButtonClicked();
void onTweaksButtonClicked();
void onTextChanged();
private:
void displayChanges();
void reloadSettings();
void addCocoOption(QString option);
void setState(ConfigurationState state);
void readSelectionDir();
void writeSelectionDir(const QString &path);
void setTweaksVisible(bool on);
void setMessageLabel(const Utils::InfoLabel::InfoType type, const QString &text);
void clearMessageLabel();
Utils::TextDisplay m_configerrorLabel;
Utils::BoolAspect m_coverageGroupBoxEnabled;
Layouting::Group m_coverageGroupbox{};
Utils::StringAspect m_optionEdit;
Layouting::PushButton m_tweaksButton{};
Utils::TextDisplay m_tweaksDescriptionLabel;
Utils::StringAspect m_tweaksEdit;
Utils::StringAspect m_fileNameLabel;
Utils::TextDisplay m_messageLabel;
QPushButton m_revertButton;
QPushButton m_saveButton;
Utils::StringAspect m_changesText;
ProjectExplorer::Project *m_project;
QPointer<BuildSettings> m_buildSettings;
QString m_selectionDirectory;
ConfigurationState m_configState = configDone;
QString m_buildConfigurationName;
};
} // namespace Coco::Internal
|