1
0
Fork 0
mirror of https://github.com/OpenMW/openmw.git synced 2025-02-03 03:15:43 +00:00
openmw/apps/opencs/view/world/tablesubview.hpp

70 lines
1.4 KiB
C++
Raw Normal View History

#ifndef CSV_WORLD_TABLESUBVIEW_H
#define CSV_WORLD_TABLESUBVIEW_H
2012-12-11 12:22:43 +00:00
#include "../doc/subview.hpp"
class QModelIndex;
2021-07-24 20:00:25 +00:00
class QWidget;
2014-01-20 15:17:49 +00:00
namespace CSMWorld
{
class IdTable;
}
2012-12-11 12:22:43 +00:00
namespace CSMDoc
{
class Document;
}
2014-04-13 14:40:41 +00:00
namespace CSVFilter
{
class FilterBox;
}
namespace CSVWorld
{
class Table;
2013-07-25 12:29:56 +00:00
class TableBottomBox;
2013-07-26 10:42:15 +00:00
class CreatorFactoryBase;
2012-12-11 12:22:43 +00:00
class TableSubView : public CSVDoc::SubView
{
2022-09-22 18:26:05 +00:00
Q_OBJECT
2022-09-22 18:26:05 +00:00
Table* mTable;
TableBottomBox* mBottom;
CSVFilter::FilterBox* mFilterBox;
bool mShowOptions;
QWidget* mOptions;
2022-09-22 18:26:05 +00:00
public:
TableSubView(const CSMWorld::UniversalId& id, CSMDoc::Document& document,
const CreatorFactoryBase& creatorFactory, bool sorting);
2022-09-22 18:26:05 +00:00
void setEditLock(bool locked) override;
2013-07-25 12:29:56 +00:00
2022-09-22 18:26:05 +00:00
void setStatusBar(bool show) override;
2013-07-25 12:29:56 +00:00
2022-09-22 18:26:05 +00:00
void useHint(const std::string& hint) override;
2014-01-27 18:40:05 +00:00
2022-09-22 18:26:05 +00:00
protected:
bool eventFilter(QObject* object, QEvent* event) override;
2014-04-13 14:40:41 +00:00
2022-09-22 18:26:05 +00:00
signals:
void cloneRequest(const std::string&, const CSMWorld::UniversalId::Type);
2014-02-21 11:48:39 +00:00
2022-09-22 18:26:05 +00:00
private slots:
2022-09-22 18:26:05 +00:00
void editRequest(const CSMWorld::UniversalId& id, const std::string& hint);
void cloneRequest(const CSMWorld::UniversalId& toClone);
void createFilterRequest(std::vector<CSMWorld::UniversalId>& types, Qt::DropAction action);
void toggleOptions();
2022-09-22 18:26:05 +00:00
public slots:
2022-09-22 18:26:05 +00:00
void requestFocus(const std::string& id);
};
}
#endif