mirror of
https://gitlab.com/OpenMW/openmw.git
synced 2025-01-26 09:35:28 +00:00
217a4d75b4
Implemented dependency sorting to ensure dependent files appear latest in the list.
43 lines
1.1 KiB
C++
43 lines
1.1 KiB
C++
#ifndef PROFILESCOMBOBOX_HPP
|
|
#define PROFILESCOMBOBOX_HPP
|
|
|
|
#include <QComboBox>
|
|
#include <QStylePainter>
|
|
class QString;
|
|
class QRegExpValidator;
|
|
|
|
namespace ContentSelectorView
|
|
{
|
|
class ProfilesComboBox : public QComboBox
|
|
{
|
|
Q_OBJECT
|
|
public:
|
|
explicit ProfilesComboBox(QWidget *parent = 0);
|
|
void setEditEnabled(bool editable);
|
|
void setPlaceholderText(const QString &text);
|
|
// void indexChanged(int index);
|
|
|
|
signals:
|
|
void signalProfileTextChanged(const QString &item);
|
|
void signalProfileChanged(const QString &previous, const QString ¤t);
|
|
void signalProfileChanged(int index);
|
|
void profileRenamed(const QString &oldName, const QString &newName);
|
|
|
|
private slots:
|
|
|
|
void slotEditingFinished();
|
|
void slotIndexChangedByUser(int index);
|
|
void slotTextChanged(const QString &text);
|
|
|
|
private:
|
|
QString mOldProfile;
|
|
QString mPlaceholderText;
|
|
QRegExpValidator *mValidator;
|
|
|
|
protected:
|
|
void paintEvent(QPaintEvent *);
|
|
};
|
|
}
|
|
|
|
#endif // PROFILESCOMBOBOX_HPP
|