@@ -120,6 +120,9 @@ void SymbolView::setupContextMenu()
120
120
mDownloadAllSymbolsAction = new QAction (" Download Symbols for &All Modules" , this );
121
121
connect (mDownloadAllSymbolsAction , SIGNAL (triggered ()), this , SLOT (moduleDownloadAllSymbols ()));
122
122
123
+ mCopyPathAction = new QAction (" Copy File &Path" , this );
124
+ connect (mCopyPathAction , SIGNAL (triggered ()), this , SLOT (moduleCopyPath ()));
125
+
123
126
// Shortcuts
124
127
refreshShortcutsSlot ();
125
128
connect (Config (), SIGNAL (shortcutsUpdated ()), this , SLOT (refreshShortcutsSlot ()));
@@ -237,6 +240,10 @@ void SymbolView::moduleContextMenu(const QPoint & pos)
237
240
wMenu->addAction (mFollowModuleEntryAction );
238
241
wMenu->addAction (mDownloadSymbolsAction );
239
242
wMenu->addAction (mDownloadAllSymbolsAction );
243
+ int_t modbase = DbgValFromString (mModuleList ->getCellContent (mModuleList ->getInitialSelection (), 0 ).toUtf8 ().constData ());
244
+ char szModPath[MAX_PATH] = " " ;
245
+ if (DbgFunctions ()->ModPathFromAddr (modbase, szModPath, _countof (szModPath)))
246
+ wMenu->addAction (mCopyPathAction );
240
247
QMenu wCopyMenu (" &Copy" , this );
241
248
mModuleList ->setupCopyMenu (&wCopyMenu);
242
249
if (wCopyMenu.actions ().length ())
@@ -259,6 +266,14 @@ void SymbolView::moduleEntryFollow()
259
266
emit showCpu ();
260
267
}
261
268
269
+ void SymbolView::moduleCopyPath ()
270
+ {
271
+ int_t modbase = DbgValFromString (mModuleList ->getCellContent (mModuleList ->getInitialSelection (), 0 ).toUtf8 ().constData ());
272
+ char szModPath[MAX_PATH] = " " ;
273
+ if (DbgFunctions ()->ModPathFromAddr (modbase, szModPath, _countof (szModPath)))
274
+ Bridge::CopyToClipboard (szModPath);
275
+ }
276
+
262
277
void SymbolView::moduleDownloadSymbols ()
263
278
{
264
279
DbgCmdExec (QString (" symdownload " + mModuleList ->getCellContent (mModuleList ->getInitialSelection (), 1 )).toUtf8 ().constData ());
0 commit comments