|
java-gnome version 4.0.19 | ||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public static interface TextView.PopulatePopup
Signal emitted by GTK allowing you to populate MenuItems into the popup context menu displayed by a TextView (typically in response to the user right-clicking).
The signal has a parameter of type Menu and populating the popup menu
is done by adding items to it with Menu's append()
, etc.
After constructing your menu one must call
showAll()
on the Menu or your newly added MenuItems will
not appear in the popup menu.
An example:
TextView t; t.connect(new TextView.PopulatePopup() { public void onPopulatePopup(TextView source, Menu menu) { menu.append(new ImageMenuItem(Stock.SAVE, new MenuItem.Activate() { public void onActivate(MenuItem source) { doStuff(); } })); menu.showAll(); } });
Method Summary | |
---|---|
void |
onPopulatePopup(TextView source,
Menu menu)
Add MenuItems you wish to see in the TreeView's context menu to menu . |
Method Detail |
---|
void onPopulatePopup(TextView source, Menu menu)
menu
.
|
![]() java-gnome |
||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |