Ejemplo n.º 1
0
        private void OnInsertNetworkRightMenu(object sender, PopupMenu menu)
        {
            NetworkViewer networkViewer = sender as NetworkViewer;

            foreach (TreePath treePath in networkViewer.SelectedItems) {
                UserInfo userInfo = networkViewer.Store.GetUserInfo(treePath);
                ExtMenuItem menuItem = new ExtMenuItem("Talk", "TalkBubble", userInfo);
                menu.AddItem(menuItem, new EventHandler(OnTalkRightMenu));
            }
        }
Ejemplo n.º 2
0
 // ============================================
 // PRIVATE (Methods) Event Handlers
 // ============================================
 private void OnImageClick(object o, ButtonPressEventArgs args)
 {
     if (args.Event.Button == 3) {
         PopupMenu menu = new PopupMenu();
         menu.AddImageItem(Gtk.Stock.Quit, new EventHandler(OnAppQuit));
         menu.ShowAll();
         menu.Popup();
     }
 }