MCPcopy Create free account
hub / github.com/AstroImageJ/astroimagej / installPopupMenu

Method installPopupMenu

ij/src/main/java/ij/Menus.java:1265–1285  ·  view source on GitHub ↗
(ImageJ ij)

Source from the content-addressed store, hash-verified

1263 }
1264
1265 void installPopupMenu(ImageJ ij) {
1266 String s;
1267 int count = 0;
1268 MenuItem mi;
1269 popup = new PopupMenu("");
1270 if (fontSize!=0 || scale>1.0)
1271 popup.setFont(getCachedFont());
1272 while (true) {
1273 count++;
1274 s = Prefs.getString("popup" + (count/10)%10 + count%10);
1275 if (s==null)
1276 break;
1277 if (s.equals("-"))
1278 popup.addSeparator();
1279 else if (!s.equals("")) {
1280 mi = new MenuItem(s);
1281 mi.addActionListener(ij);
1282 popup.add(mi);
1283 }
1284 }
1285 }
1286
1287 public static MenuBar getMenuBar() {
1288 return mbar;

Callers 1

ImageJMethod · 0.95

Calls 7

getCachedFontMethod · 0.95
getStringMethod · 0.95
addActionListenerMethod · 0.80
setFontMethod · 0.65
addMethod · 0.65
equalsMethod · 0.45
addSeparatorMethod · 0.45

Tested by

no test coverage detected