PIVariantEditors::FileBase allow user to select relative/absolute mode
This commit is contained in:
@@ -571,7 +571,6 @@ PIVariantEditors::FileBase::FileBase() {
|
||||
edit_widget->layout()->addWidget(b);
|
||||
layout()->setSpacing(0);
|
||||
layout()->addWidget(edit_widget);
|
||||
setFullEditMode(false);
|
||||
}
|
||||
|
||||
|
||||
@@ -606,7 +605,8 @@ void PIVariantEditors::FileBase::applyAttributes(const PIVariantMap & a) {
|
||||
|
||||
|
||||
void PIVariantEditors::FileBase::setFullEditMode(bool on) {
|
||||
edit_widget->setVisible(on);
|
||||
act_save->setVisible(on);
|
||||
act_filter->setVisible(on);
|
||||
}
|
||||
|
||||
|
||||
@@ -618,7 +618,7 @@ void PIVariantEditors::FileBase::createMenu() {
|
||||
act_save = edit_menu.addAction(tr("Existing only"), this, [this](bool on) { is_save = !on; });
|
||||
act_save->setCheckable(true);
|
||||
act_save->setChecked(!is_save);
|
||||
edit_menu.addAction(tr("Set filter ..."), this, [this]() {
|
||||
act_filter = edit_menu.addAction(tr("Set filter ..."), this, [this]() {
|
||||
bool ok = false;
|
||||
QString nf = QInputDialog::getText(nullptr, tr("Select filter"), tr("Input filter:"), QLineEdit::Normal, PI2QString(filter), &ok);
|
||||
if (!ok) return;
|
||||
|
||||
Reference in New Issue
Block a user