[LYN-2520] Gem Catalog - Gem Inspector / Info Panel (#718)
* [LYN-2520] Gem Catalog - Gem Inspector / Info Panel * Extended the gem info with a directory and documentation link, binary size in bytes and added some helper functions. * Added the gem inspector widget that hooks into the selection model. * Info panel is vertically scrollable and based on the UX designs. * Added a gem sub widget which holds several gem tags, a title and a description and is reused for the depending and conflicting gems. * Extended the gem model with several new roles and data elements. * Added more gem info test data before we got access to the real data.
This commit is contained in:
@@ -14,6 +14,7 @@
|
||||
|
||||
#if !defined(Q_MOC_RUN)
|
||||
#include "GemInfo.h"
|
||||
#include <QAbstractItemModel>
|
||||
#include <QStandardItemModel>
|
||||
#include <QItemSelectionModel>
|
||||
#endif
|
||||
@@ -32,11 +33,19 @@ namespace O3DE::ProjectManager
|
||||
void AddGem(const GemInfo& gemInfo);
|
||||
void Clear();
|
||||
|
||||
QString GetName(const QModelIndex& modelIndex) const;
|
||||
QString GetCreator(const QModelIndex& modelIndex) const;
|
||||
GemInfo::Platforms GetPlatforms(const QModelIndex& modelIndex) const;
|
||||
QString GetSummary(const QModelIndex& modelIndex) const;
|
||||
bool IsAdded(const QModelIndex& modelIndex) const;
|
||||
static QString GetName(const QModelIndex& modelIndex);
|
||||
static QString GetCreator(const QModelIndex& modelIndex);
|
||||
static GemInfo::Platforms GetPlatforms(const QModelIndex& modelIndex);
|
||||
static QString GetSummary(const QModelIndex& modelIndex);
|
||||
static bool IsAdded(const QModelIndex& modelIndex);
|
||||
static QString GetDirectoryLink(const QModelIndex& modelIndex);
|
||||
static QString GetDocLink(const QModelIndex& modelIndex);
|
||||
static QStringList GetDependingGems(const QModelIndex& modelIndex);
|
||||
static QStringList GetConflictingGems(const QModelIndex& modelIndex);
|
||||
static QString GetVersion(const QModelIndex& modelIndex);
|
||||
static QString GetLastUpdated(const QModelIndex& modelIndex);
|
||||
static int GetBinarySizeInKB(const QModelIndex& modelIndex);
|
||||
static QStringList GetFeatures(const QModelIndex& modelIndex);
|
||||
|
||||
private:
|
||||
enum UserRole
|
||||
@@ -45,7 +54,15 @@ namespace O3DE::ProjectManager
|
||||
RoleCreator,
|
||||
RolePlatforms,
|
||||
RoleSummary,
|
||||
RoleIsAdded
|
||||
RoleIsAdded,
|
||||
RoleDirectoryLink,
|
||||
RoleDocLink,
|
||||
RoleDependingGems,
|
||||
RoleConflictingGems,
|
||||
RoleVersion,
|
||||
RoleLastUpdated,
|
||||
RoleBinarySize,
|
||||
RoleFeatures,
|
||||
};
|
||||
|
||||
QItemSelectionModel* m_selectionModel = nullptr;
|
||||
|
||||
Reference in New Issue
Block a user