2013-09-08 12:31:20 +00:00
|
|
|
#ifndef CSV_DOC_FILEWIDGET_H
|
|
|
|
#define CSV_DOC_FILEWIDGET_H
|
|
|
|
|
2022-10-19 17:02:00 +00:00
|
|
|
#include <QString>
|
2013-09-08 12:31:20 +00:00
|
|
|
#include <QWidget>
|
|
|
|
|
2015-08-06 10:52:10 +00:00
|
|
|
#include <string>
|
|
|
|
|
2013-09-08 12:31:20 +00:00
|
|
|
class QLabel;
|
|
|
|
class QLineEdit;
|
|
|
|
|
|
|
|
namespace CSVDoc
|
|
|
|
{
|
|
|
|
class FileWidget : public QWidget
|
|
|
|
{
|
|
|
|
Q_OBJECT
|
|
|
|
|
|
|
|
bool mAddon;
|
|
|
|
QLineEdit* mInput;
|
|
|
|
QLabel* mType;
|
|
|
|
|
|
|
|
QString getExtension() const;
|
|
|
|
|
|
|
|
public:
|
2020-11-13 07:39:47 +00:00
|
|
|
FileWidget(QWidget* parent = nullptr);
|
2013-09-08 12:31:20 +00:00
|
|
|
|
2020-11-13 07:39:47 +00:00
|
|
|
void setType(bool addon);
|
2013-09-08 12:31:20 +00:00
|
|
|
|
|
|
|
QString getName() const;
|
|
|
|
|
|
|
|
void extensionLabelIsVisible(bool visible);
|
|
|
|
|
2013-09-23 04:52:53 +00:00
|
|
|
void setName(const std::string& text);
|
|
|
|
|
2015-08-06 10:52:10 +00:00
|
|
|
private slots:
|
|
|
|
|
2013-09-08 12:31:20 +00:00
|
|
|
void textChanged(const QString& text);
|
|
|
|
|
2022-09-22 18:26:05 +00:00
|
|
|
signals:
|
2013-09-08 12:31:20 +00:00
|
|
|
|
2013-09-10 14:45:01 +00:00
|
|
|
void nameChanged(const QString& file, bool addon);
|
2013-09-08 12:31:20 +00:00
|
|
|
};
|
|
|
|
}
|
|
|
|
|
|
|
|
#endif
|