TechDraw: Remove redundant apply button. (Fix #21792)

This commit is contained in:
Ryan Kembrey
2025-06-19 20:54:28 +10:00
committed by Chris Hennes
parent 51184b99d5
commit a3fb529bc8
2 changed files with 4 additions and 9 deletions

View File

@@ -777,12 +777,10 @@ QString TaskProjGroup::formatVector(Base::Vector3d vec)
}
void TaskProjGroup::saveButtons(QPushButton* btnOK,
QPushButton* btnCancel,
QPushButton* btnApply)
QPushButton* btnCancel)
{
m_btnOK = btnOK;
m_btnCancel = btnCancel;
m_btnApply = btnApply;
}
@@ -887,8 +885,7 @@ void TaskDlgProjGroup::modifyStandardButtons(QDialogButtonBox* box)
{
QPushButton* btnOK = box->button(QDialogButtonBox::Ok);
QPushButton* btnCancel = box->button(QDialogButtonBox::Cancel);
QPushButton* btnApply = box->button(QDialogButtonBox::Apply);
widget->saveButtons(btnOK, btnCancel, btnApply);
widget->saveButtons(btnOK, btnCancel);
}
//==== calls from the TaskView ===============================================================

View File

@@ -61,8 +61,7 @@ public:
virtual bool apply();
void modifyStandardButtons(QDialogButtonBox* box);
void saveButtons(QPushButton* btnOK,
QPushButton* btnCancel,
QPushButton* btnApply);
QPushButton* btnCancel);
void updateTask();
// Sets the numerator and denominator widgets to match newScale
@@ -126,7 +125,6 @@ private:
QPushButton* m_btnOK{nullptr};
QPushButton* m_btnCancel{nullptr};
QPushButton* m_btnApply{nullptr};
std::vector<App::DocumentObject*> m_saveSource;
std::string m_saveProjType;
@@ -151,7 +149,7 @@ public:
TechDraw::DrawView* getView() const { return view; }
QDialogButtonBox::StandardButtons getStandardButtons() const override
{ return QDialogButtonBox::Ok | QDialogButtonBox::Apply | QDialogButtonBox::Cancel; }
{ return QDialogButtonBox::Ok | QDialogButtonBox::Cancel; }
void modifyStandardButtons(QDialogButtonBox* box) override;
/// is called the TaskView when the dialog is opened