protected override void OnTabMenuShown(object sender, EventArgs e) { Trace.Call(sender, e); base.OnTabMenuShown(sender, e); TabMenu.Prepend(ReconnectItem); TabMenu.ShowAll(); }
public ProtocolChatView(ChatModel chat) : base(chat) { Trace.Call(chat); ProxySettings = new ProxySettings(); Add(OutputScrolledWindow); ReconnectItem = new Gtk.ImageMenuItem(_("Reconnect")); ReconnectItem.Image = new Gtk.Image(Gtk.Stock.Refresh, Gtk.IconSize.Menu); ReconnectItem.Activated += new EventHandler(OnTabMenuReconnectActivated); TabMenu.Prepend(ReconnectItem); TabMenu.ShowAll(); ShowAll(); }
protected override void OnTabMenuShown(object sender, EventArgs e) { base.OnTabMenuShown(sender, e); var stack = new Stack <Gtk.MenuItem>(); foreach (var menu_item in CreateContextMenuItems()) { stack.Push(menu_item); } TabMenu.Prepend(new Gtk.SeparatorMenuItem()); while (stack.Count != 0) { TabMenu.Prepend(stack.Pop()); } TabMenu.ShowAll(); }