private void OnContextMenu(QListViewItem item,QPoint point,int col) { popupMenuItem = item; if (item is ClassItem) { ClassItem klass = (ClassItem)item; QPopupMenu menu = new QPopupMenu(this); menu.InsertItem("Exclude from coverage",this,SLOT("OnExclude()")); if (klass.Model.sourceFile != null) { menu.InsertItem("View Source",this,SLOT("OnViewSource()")); } menu.Exec(point); } else if (item is NamespaceItem) { QPopupMenu menu = new QPopupMenu(this); menu.InsertItem("Exclude from coverage",this,SLOT("OnExclude()")); menu.Exec(point); } }
public MonoCov() : base(null) { coverageView = null; SetCaption (CAPTION); QPopupMenu fileMenu = new QPopupMenu (this); fileMenu.InsertItem ("&Open", this, SLOT ("SlotOpen()")); fileMenu.InsertItem ("E&xit", qApp, SLOT ("quit()")); //QPopupMenu editMenu = new QPopupMenu (this); //editMenu.InsertItem ("&Filters", this, SLOT ("SlotFilters()")); QPopupMenu aboutMenu = new QPopupMenu (this); aboutMenu.InsertItem ("&About", this, SLOT ("SlotAbout()")); QMenuBar menu = new QMenuBar (this); menu.InsertItem ("&File", fileMenu); //menu.InsertItem ("&Edit", editMenu); menu.InsertItem ("&About", aboutMenu); }
public MonoCov() : base(null) { coverageView = null; SetCaption(CAPTION); QPopupMenu fileMenu = new QPopupMenu(this); fileMenu.InsertItem("&Open", this, SLOT("SlotOpen()")); fileMenu.InsertItem("E&xit",qApp,SLOT("quit()")); //QPopupMenu editMenu = new QPopupMenu (this); //editMenu.InsertItem ("&Filters", this, SLOT ("SlotFilters()")); QPopupMenu aboutMenu = new QPopupMenu(this); aboutMenu.InsertItem("&About",this,SLOT("SlotAbout()")); QMenuBar menu = new QMenuBar(this); menu.InsertItem("&File",fileMenu); //menu.InsertItem ("&Edit", editMenu); menu.InsertItem("&About",aboutMenu); }
private void OnContextMenu(QListViewItem item, QPoint point, int col) { popupMenuItem = item; if (item is ClassItem) { ClassItem klass = (ClassItem)item; QPopupMenu menu = new QPopupMenu (this); menu.InsertItem ("Exclude from coverage", this, SLOT ("OnExclude()")); if (klass.Model.sourceFile != null) menu.InsertItem ("View Source", this, SLOT ("OnViewSource()")); menu.Exec (point); } else if (item is NamespaceItem) { QPopupMenu menu = new QPopupMenu (this); menu.InsertItem ("Exclude from coverage", this, SLOT ("OnExclude()")); menu.Exec (point); } }