mirror of
https://github.com/Rockbox/rockbox.git
synced 2025-11-15 16:12:28 -05:00
Theme Editor: Got project viewer displaying WPS files
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@26731 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
parent
70b9ab484f
commit
1cc95c541b
4 changed files with 121 additions and 4 deletions
|
|
@ -23,11 +23,12 @@
|
|||
#define PROJECTFILES_H
|
||||
|
||||
#include "projectmodel.h"
|
||||
#include <QHash>
|
||||
|
||||
class ProjectFiles : public ProjectNode
|
||||
{
|
||||
public:
|
||||
ProjectFiles(ProjectNode* parent);
|
||||
ProjectFiles(QHash<QString, QString>& settings, ProjectNode* parent);
|
||||
virtual ~ProjectFiles();
|
||||
|
||||
virtual ProjectNode* parent() const;
|
||||
|
|
@ -43,4 +44,26 @@ private:
|
|||
|
||||
};
|
||||
|
||||
/* A class to enumerate a single file */
|
||||
class ProjectFile: public ProjectNode
|
||||
{
|
||||
public:
|
||||
ProjectFile(QString file, ProjectNode* parent);
|
||||
virtual ~ProjectFile();
|
||||
|
||||
virtual ProjectNode* parent() const{ return parentLink; }
|
||||
virtual ProjectNode* child(int row) const{ return 0; }
|
||||
virtual int numChildren() const{ return 0; }
|
||||
virtual int row() const{
|
||||
return parentLink->indexOf(const_cast<ProjectFile*>(this));
|
||||
}
|
||||
virtual QVariant data(int column) const;
|
||||
virtual Qt::ItemFlags flags(int column) const;
|
||||
virtual void activated();
|
||||
|
||||
private:
|
||||
ProjectNode* parentLink;
|
||||
QString file;
|
||||
};
|
||||
|
||||
#endif // PROJECTFILES_H
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue