Skip to content
Permalink
Browse files
Don't show the attribute action popup menu if there are no actions de…
…fined

git-svn-id: http://svn.osgeo.org/qgis/trunk/qgis@5503 c8812cc2-4d05-0410-92ff-de0c093fc19c
  • Loading branch information
g_j_m committed Jun 1, 2006
1 parent d410a8f commit 122a9fc
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 6 deletions.
@@ -316,7 +316,8 @@ void QgsAttributeTable::popupMenu(int row, int col, const QPoint& pos)
// mActionValues vector.
mClickedOnValue = col;

mActionPopup->popup(pos);
if (mActions.size() > 0)
mActionPopup->popup(pos);
}

void QgsAttributeTable::popupItemSelected(QAction* menuAction)
@@ -82,10 +82,6 @@ void QgsIdentifyResults::popupContextMenu(Q3ListViewItem* item,
{
mActionPopup = new QMenu();
QAction *a = mActionPopup->addAction( tr("Run action") );
QFont f = a->font();
f.setBold(true);
a->setFont(f);

mActionPopup->addSeparator();

QgsAttributeAction::aIter iter = mActions.begin();
@@ -132,7 +128,8 @@ void QgsIdentifyResults::popupContextMenu(Q3ListViewItem* item,
child = child->nextSibling();
}

mActionPopup->popup(p);
if (mActions.size() > 0)
mActionPopup->popup(p);
}
// Restore last window position/size and show the window
void QgsIdentifyResults::restorePosition()

0 comments on commit 122a9fc

Please sign in to comment.