1
0
Fork 0
mirror of https://github.com/OpenMW/openmw.git synced 2025-01-24 23:23:54 +00:00
openmw/apps/opencs/view/widget/scenetoolbar.hpp

43 lines
829 B
C++
Raw Normal View History

#ifndef CSV_WIDGET_SCENETOOLBAR_H
#define CSV_WIDGET_SCENETOOLBAR_H
#include <QWidget>
class QVBoxLayout;
namespace CSVWidget
{
class SceneTool;
class SceneToolbar : public QWidget
{
2022-09-22 18:26:05 +00:00
Q_OBJECT
2022-09-22 18:26:05 +00:00
QVBoxLayout* mLayout;
int mButtonSize;
int mIconSize;
2022-09-22 18:26:05 +00:00
protected:
void focusInEvent(QFocusEvent* event) override;
2022-09-22 18:26:05 +00:00
public:
SceneToolbar(int buttonSize, QWidget* parent = nullptr);
2022-09-22 18:26:05 +00:00
/// If insertPoint==0, insert \a tool at the end of the scrollbar. Otherwise
/// insert tool after \a insertPoint.
void addTool(SceneTool* tool, SceneTool* insertPoint = nullptr);
2022-09-22 18:26:05 +00:00
void removeTool(SceneTool* tool);
2022-09-22 18:26:05 +00:00
int getButtonSize() const;
2022-09-22 18:26:05 +00:00
int getIconSize() const;
2022-09-22 18:26:05 +00:00
signals:
2014-04-03 11:00:19 +00:00
2022-09-22 18:26:05 +00:00
void focusSceneRequest();
};
}
#endif