I want to delete A toolbutton,which is created dynamically.
So first wwe want to identify which toolbutton is active and then delete it.
The following code can't identify the active tool button and even delete it.
here unselectedButtinMap[instance] displays the lastcreated button. but the sender function gives the windows id.
So they wont match and can't delete the QToolButton.
foreach(QString instance, unselectButtonMap.keys())
{
if(unselectButtonMap[instance] == QObject::sender())
{
QMessageBox::warning(0,tr("Warning"),tr("do you want to delete the folder"));
unselectButtonMap[instance]->hide;
}}
Can any one suggest any other method?
Also suggest a method to delete the QToolButton.
Thanks in advance
Bookmarks