GtkStatusIcon::position_menu

void position_menu([GtkMenu menu [, GtkStatusIcon statusicon]]);

Use to position a menu over a GtkStatusIcon object. This function makes sure the supplied menu is displayed over the icon when popup() is called.

This method must be called statically.

$menu = new GtkMenu();
$tray = new GtkStatusIcon();
GtkStatusIcon::position_menu($menu, $tray);