Prism/fix create project bugs (#7539)
* Don't show ${Name} gems and fix template names
Signed-off-by: Alex Peterson <26804013+AMZN-alexpete@users.noreply.github.com>
* Fix overlay size so it doesn't overlap parent border
Signed-off-by: Alex Peterson <26804013+AMZN-alexpete@users.noreply.github.com>
* Hide warning when building
Signed-off-by: Alex Peterson <26804013+AMZN-alexpete@users.noreply.github.com>
* Fix gem download fail due to param type change
Signed-off-by: Alex Peterson <26804013+AMZN-alexpete@users.noreply.github.com>
* Restore missing functionionality for gem repos
Signed-off-by: Alex Peterson <26804013+AMZN-alexpete@users.noreply.github.com>
* Use the parent's width for the gem inspector
Signed-off-by: Alex Peterson <26804013+AMZN-alexpete@users.noreply.github.com>
* Restore regressed code for gem repos and folders
Signed-off-by: Alex Peterson <26804013+AMZN-alexpete@users.noreply.github.com>
* Revert home folder override
Signed-off-by: Alex Peterson <26804013+AMZN-alexpete@users.noreply.github.com>
This commit is contained in:
@@ -482,10 +482,10 @@ QTabBar::tab:focus {
|
||||
|
||||
#labelButtonOverlay {
|
||||
background-color: rgba(50,50,50,200);
|
||||
min-width:210px;
|
||||
max-width:210px;;
|
||||
min-height:278px;
|
||||
max-height:278px;
|
||||
min-width:208px;
|
||||
max-width:208px;;
|
||||
min-height:270px;
|
||||
max-height:270px;
|
||||
}
|
||||
|
||||
QProgressBar {
|
||||
|
||||
@@ -81,7 +81,7 @@ namespace O3DE::ProjectManager
|
||||
m_rightPanelStack = new QStackedWidget(this);
|
||||
m_rightPanelStack->setFixedWidth(sidePanelWidth);
|
||||
|
||||
m_gemInspector = new GemInspector(m_gemModel, this);
|
||||
m_gemInspector = new GemInspector(m_gemModel, m_rightPanelStack);
|
||||
|
||||
connect(m_gemInspector, &GemInspector::TagClicked, [=](const Tag& tag) { SelectGem(tag.id); });
|
||||
connect(m_gemInspector, &GemInspector::UpdateGem, this, &GemCatalogScreen::UpdateGem);
|
||||
@@ -233,7 +233,12 @@ namespace O3DE::ProjectManager
|
||||
const QVector<GemInfo>& gemInfos = allGemInfosResult.GetValue();
|
||||
for (const GemInfo& gemInfo : gemInfos)
|
||||
{
|
||||
gemInfoHash.insert(gemInfo.m_name, gemInfo);
|
||||
// ${Name} is a special name used for templates and should be ignored
|
||||
// eventually we should handle this in Python instead of here
|
||||
if (gemInfo.m_name != "${Name}")
|
||||
{
|
||||
gemInfoHash.insert(gemInfo.m_name, gemInfo);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -503,7 +508,10 @@ namespace O3DE::ProjectManager
|
||||
const QVector<GemInfo>& allGemInfos = allGemInfosResult.GetValue();
|
||||
for (const GemInfo& gemInfo : allGemInfos)
|
||||
{
|
||||
m_gemModel->AddGem(gemInfo);
|
||||
if (gemInfo.m_name != "${Name}")
|
||||
{
|
||||
m_gemModel->AddGem(gemInfo);
|
||||
}
|
||||
}
|
||||
|
||||
const AZ::Outcome<QVector<GemInfo>, AZStd::string>& allRepoGemInfosResult = PythonBindingsInterface::Get()->GetGemInfosForAllRepos();
|
||||
|
||||
@@ -30,6 +30,10 @@ namespace O3DE::ProjectManager
|
||||
setVerticalScrollBarPolicy(Qt::ScrollBarAsNeeded);
|
||||
|
||||
m_mainWidget = new QWidget();
|
||||
if (parent)
|
||||
{
|
||||
m_mainWidget->setFixedWidth(parent->width());
|
||||
}
|
||||
setWidget(m_mainWidget);
|
||||
|
||||
m_mainLayout = new QVBoxLayout();
|
||||
|
||||
@@ -207,6 +207,7 @@ namespace O3DE::ProjectManager
|
||||
{
|
||||
m_templateDisplayName = new QLabel(this);
|
||||
m_templateDisplayName->setObjectName("displayName");
|
||||
m_templateDisplayName->setWordWrap(true);
|
||||
templateDetailsLayout->addWidget(m_templateDisplayName);
|
||||
|
||||
m_templateSummary = new QLabel(this);
|
||||
|
||||
@@ -330,6 +330,11 @@ namespace O3DE::ProjectManager
|
||||
|
||||
void ProjectButton::ShowWarning(bool show, const QString& warning)
|
||||
{
|
||||
if (show)
|
||||
{
|
||||
// hide any overlay text, we cannot show the warning and an overlay at the same time
|
||||
m_projectImageLabel->GetOverlayLabel()->setVisible(false);
|
||||
}
|
||||
m_projectImageLabel->GetWarningLabel()->setTextInteractionFlags(Qt::LinksAccessibleByMouse);
|
||||
m_projectImageLabel->GetWarningLabel()->setText(warning);
|
||||
m_projectImageLabel->GetWarningLabel()->setVisible(show);
|
||||
@@ -362,6 +367,9 @@ namespace O3DE::ProjectManager
|
||||
m_projectImageLabel->SetOverlayText(tr("Building...\n\n"));
|
||||
m_projectMenuButton->setVisible(false);
|
||||
|
||||
// hide the warning label about this project needing to be built while building
|
||||
ShowWarning(false, "");
|
||||
|
||||
QProgressBar* progressBar = m_projectImageLabel->GetProgressBar();
|
||||
progressBar->setVisible(true);
|
||||
progressBar->setValue(0);
|
||||
|
||||
@@ -38,6 +38,7 @@ namespace O3DE::ProjectManager
|
||||
|
||||
QLabel* label = new QLabel(labelText, this);
|
||||
label->setObjectName("templateLabel");
|
||||
label->setWordWrap(true);
|
||||
vLayout->addWidget(label);
|
||||
|
||||
connect(this, &QAbstractButton::toggled, this, &TemplateButton::onToggled);
|
||||
|
||||
Reference in New Issue
Block a user