tahoma2d/toonz/sources/include/toonzqt/stylenameeditor.h

37 lines
694 B
C
Raw Normal View History

2016-05-17 03:04:11 +12:00
#pragma once
2016-03-19 06:57:51 +13:00
#ifndef STYLENAMEEDITOR_H
#define STYLENAMEEDITOR_H
#include <QDialog>
class QLineEdit;
class QPushButton;
class TPaletteHandle;
class StyleNameEditor final : public QDialog // singleton
2016-03-19 06:57:51 +13:00
{
2016-06-15 18:43:10 +12:00
Q_OBJECT
2016-03-19 06:57:51 +13:00
2016-06-15 18:43:10 +12:00
TPaletteHandle *m_paletteHandle;
2016-03-19 06:57:51 +13:00
2016-06-15 18:43:10 +12:00
QLineEdit *m_styleName;
QPushButton *m_okButton, *m_applyButton, *m_cancelButton;
2016-03-19 06:57:51 +13:00
public:
2016-06-15 18:43:10 +12:00
StyleNameEditor(QWidget *parent = 0);
void setPaletteHandle(TPaletteHandle *ph);
2016-03-19 06:57:51 +13:00
protected:
2016-06-19 20:06:29 +12:00
void showEvent(QShowEvent *) override;
void hideEvent(QHideEvent *) override;
void enterEvent(QEvent *) override;
2016-03-19 06:57:51 +13:00
protected slots:
2016-06-15 18:43:10 +12:00
void onStyleSwitched();
void onOkPressed();
void onApplyPressed();
void onCancelPressed();
2016-03-19 06:57:51 +13:00
};
#endif