MCPcopy Create free account
hub / github.com/zxlie/FeHelper / _buildSystemMenus

Function _buildSystemMenus

apps/background/menu.js:337–346  ·  view source on GitHub ↗
(values, hasToolItems)

Source from the content-addressed store, hash-verified

335 };
336
337 let _buildSystemMenus = function (values, hasToolItems) {
338 let sysMenuItems = [];
339 String(values[0]) === '1' && sysMenuItems.push(defaultMenuOptions['download-crx']);
340 String(values[1]) !== '0' && sysMenuItems.push(defaultMenuOptions['fehelper-setting']);
341
342 if (sysMenuItems.length) {
343 hasToolItems && _createSeparator();
344 sysMenuItems.forEach(menu => _createItem(menu.text, [menu]));
345 }
346 };
347
348 /**
349 * 移除扩展专属的右键菜单

Callers 1

_buildChildMenusFunction · 0.85

Calls 2

_createSeparatorFunction · 0.85
_createItemFunction · 0.85

Tested by

no test coverage detected