Changeset 9cdab3 for src/UIElements/Qt4/QtMainWindow.cpp
- Timestamp:
- Aug 11, 2025, 5:45:54 PM (2 months ago)
- Branches:
- Candidate_v1.7.0, stable
- Children:
- 5718cc
- Parents:
- ae9ad6
- git-author:
- Frederik Heber <frederik.heber@…> (07/20/25 20:19:22)
- git-committer:
- Frederik Heber <frederik.heber@…> (08/11/25 17:45:54)
- File:
-
- 1 edited
-
src/UIElements/Qt4/QtMainWindow.cpp (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
src/UIElements/Qt4/QtMainWindow.cpp
rae9ad6 r9cdab3 134 134 toolbar->addFavoriteActionItems(20); 135 135 addToolBar(toolbar); 136 137 // add context menu on right click 138 glWorldView->setContextMenuPolicy(Qt::CustomContextMenu); 139 connect(glWorldView, SIGNAL(customContextMenuRequested(const QPoint&)), this, SLOT(slotContextMenuRequested(const QPoint&))); 136 140 137 141 setCentralWidget(splitter1); … … 193 197 } 194 198 199 void QtMainWindow::slotContextMenuRequested(const QPoint &pos) 200 { 201 // pick the atoms menu 202 QtMenu<QMenu_tooltip> * atoms_submenu = MainMenu->findSubmenu("atom"); 203 // and show it 204 if (atoms_submenu != NULL) { 205 atoms_submenu->popup(glWorldView->mapToGlobal(pos)); 206 } else { 207 ELOG(1, "Could not find atom submenu."); 208 } 209 } 195 210 QtMainWindow::~QtMainWindow() 196 211 {
Note:
See TracChangeset
for help on using the changeset viewer.
