其实有这个需求很好理解,就是我有个project manager,上面的TreeWidgetItem都表示一个工程,我需要右键创建新的工程,或者删除.这个在很多普通软件中也见得多.在弹出的菜单中加入相应的QAction就行了. QMenu* pContextMenu = new QMenu(this) QTreeWidget* pTreeWidget = new QTreeWidget(); QAction* pOpenFile = new QAction(tr("Open A File&quo…
用MPLAB IDE编程时,软件总是弹出一个窗口提示:"the extended cpu mode configuration bit is enabled,but the program that was loaded was not built using extended cpu instructions.therefore,your code may not work properly."怎么办? 在main函数前加一句伪指令:#pragma config XINST=OFF即…