mirror of
https://github.com/RPCSX/rpcsx.git
synced 2026-03-01 11:04:50 +01:00
* Grid layout * Add Tiny Mode fix scrolling fix maxGamesPerRow calculation * prime empty toolbar * Add Search Bar, Icon Size and List Mode to ToolBar Fix some minor glitches * fix toolbar save and adjust default margin * fix toolbar regression minor simplification in Refresh * Implement search and rename PopulateUI to PopulateGameList * minor refactoring hehehehehehe * Fix crash * refresh speedboost optimizations * Small refactoring of refresh to have default argument of false. * add icons to toolbar * fix scrambed order * search for serial as well
23 lines
682 B
C++
23 lines
682 B
C++
#ifndef GAME_LIST_GRID_DELEGATE
|
|
#define GAME_LIST_GRID_DELEGATE
|
|
|
|
#include <QPainter>
|
|
#include <QAbstractItemDelegate>
|
|
|
|
class game_list_grid_delegate : public QAbstractItemDelegate
|
|
{
|
|
public:
|
|
game_list_grid_delegate(const QSize& imageSize, const qreal& margin_factor, const qreal& margin_ratio, QObject *parent = 0);
|
|
|
|
void paint(QPainter * painter, const QStyleOptionViewItem & option, const QModelIndex & index) const;
|
|
QSize sizeHint(const QStyleOptionViewItem & option, const QModelIndex & index) const;
|
|
void setItemSize(const QSize& size) { m_size = size; };
|
|
virtual ~game_list_grid_delegate();
|
|
private:
|
|
QSize m_size;
|
|
qreal m_margin_factor;
|
|
qreal m_text_factor;
|
|
};
|
|
|
|
#endif
|