Skip to content

Commit

Permalink
Merge remote-tracking branch #469 (VENOM-466) into release-0.5.3
Browse files Browse the repository at this point in the history
  • Loading branch information
naxuroqa committed Dec 21, 2018
2 parents d5a48e2 + 3610039 commit b6949c0
Showing 1 changed file with 7 additions and 5 deletions.
12 changes: 7 additions & 5 deletions src/view/ContactListWidget.vala
Original file line number Diff line number Diff line change
Expand Up @@ -112,11 +112,13 @@ namespace Venom {
if (ev.type == Gdk.EventType.BUTTON_PRESS && ev.button == 3) {
logger.d("right mouse clicked");
var row = contact_list.get_row_at_y((int) ev.y);
var contact = contact_list_model.get_object(row.get_index()) as IContact;
var menu = view_model.popup_menu(contact);
var popover = new Gtk.Popover.from_model(row, menu);
popover.popup();
return true;
if (row != null) {
var contact = contact_list_model.get_object(row.get_index()) as IContact;
var menu = view_model.popup_menu(contact);
var popover = new Gtk.Popover.from_model(row, menu);
popover.popup();
return true;
}
}
return false;
}
Expand Down

0 comments on commit b6949c0

Please sign in to comment.