+ Fix undo/redo issue with pad
This commit is contained in:
parent
e9b275c7e6
commit
6f2f417976
|
@ -474,12 +474,12 @@ TaskDlgPadParameters::~TaskDlgPadParameters()
|
|||
|
||||
void TaskDlgPadParameters::open()
|
||||
{
|
||||
|
||||
QString msg = QObject::tr("Edit pad");
|
||||
Gui::Command::openCommand((const char*)msg.toUtf8());
|
||||
}
|
||||
|
||||
void TaskDlgPadParameters::clicked(int)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
bool TaskDlgPadParameters::accept()
|
||||
|
|
|
@ -63,6 +63,12 @@ void ViewProviderPad::setupContextMenu(QMenu* menu, QObject* receiver, const cha
|
|||
PartGui::ViewProviderPart::setupContextMenu(menu, receiver, member);
|
||||
}
|
||||
|
||||
bool ViewProviderPad::doubleClicked(void)
|
||||
{
|
||||
Gui::Command::doCommand(Gui::Command::Gui,"Gui.activeDocument().setEdit('%s',0)",this->pcObject->getNameInDocument());
|
||||
return true;
|
||||
}
|
||||
|
||||
bool ViewProviderPad::setEdit(int ModNum)
|
||||
{
|
||||
if (ModNum == ViewProvider::Default || ModNum == 1 ) {
|
||||
|
@ -88,8 +94,6 @@ bool ViewProviderPad::setEdit(int ModNum)
|
|||
|
||||
// clear the selection (convenience)
|
||||
Gui::Selection().clearSelection();
|
||||
//if (ModNum == 1)
|
||||
// Gui::Command::openCommand("Change pad parameters");
|
||||
|
||||
// start the edit dialog
|
||||
if (padDlg)
|
||||
|
|
|
@ -41,6 +41,7 @@ public:
|
|||
/// grouping handling
|
||||
std::vector<App::DocumentObject*> claimChildren(void)const;
|
||||
void setupContextMenu(QMenu*, QObject*, const char*);
|
||||
bool doubleClicked();
|
||||
|
||||
virtual bool onDelete(const std::vector<std::string> &);
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user