feat(misc): a bunch of crude UI/UX tweaks
- display add time for later use - basic keyboard navigation support - remember last-used server address - show connection error when attempt to connect to server
This commit is contained in:
@ -8,6 +8,7 @@ ComicItem::ComicItem(QJsonObject jsonObj, const QString &name)
|
||||
setData(jsonObj["num_pages"].toInt(), PageCountRole);
|
||||
setData(jsonObj["current_page"].toInt(), CurrentPageRole);
|
||||
setData(jsonObj["type"].toInt(), TypeRole);
|
||||
setData(jsonObj["added"].toInteger(), AddedTimeRole);
|
||||
}
|
||||
|
||||
QHash<int, QByteArray> ComicItem::roleNames()
|
||||
@ -19,5 +20,6 @@ QHash<int, QByteArray> ComicItem::roleNames()
|
||||
{ComicItem::PageCountRole, "pageCount"},
|
||||
{ComicItem::CurrentPageRole, "currentPage"},
|
||||
{ComicItem::TypeRole, "type"},
|
||||
{ComicItem::AddedTimeRole, "addedTime"},
|
||||
};
|
||||
}
|
||||
|
@ -14,6 +14,7 @@ public:
|
||||
PageCountRole,
|
||||
CurrentPageRole,
|
||||
TypeRole,
|
||||
AddedTimeRole,
|
||||
};
|
||||
Q_ENUM(Roles)
|
||||
|
||||
|
Reference in New Issue
Block a user