function patchIcon(name, className, items, callback) {
      var id = 'snd_ui16dp_' + name + '_menu',
          post_istanbul = minVersion('J'),
          icon;
      createContextMenu(id, items);
      icon = $('.' + className + ' ' + (post_istanbul ? 'a.btn-icon' : 'span.label-icon'));
      if (icon.length) {
        icon.snd_ui16dp_menu({
          menu_id: "#" + id,
          callback: callback
        }).css('cursor', 'pointer');
        jslog('snd_ui16_developer_patch icon picker patch applied to ' + name + ' picker.');
      } else {
        jslog('snd_ui16_developer_patch icon picker patch unable to find ' + name + ' picker.');
      }
    }
/**
     * Patch a picker icon so it becomes interactive and has a context menu.
     *
     * @param  {String}   name      The name of the context menu - forms the ID.
     * @param  {String}   className The class name of the icon to patch.
     * @param  {Array}    items     An array of item objects to generate the menu.
     * @param  {Function} callback  The function to call when something is clicked.
     * @return {undefined}
     */
Patch a picker icon so it becomes interactive and has a context menu.
@param  {String}   name      The name of the context menu - forms the ID.
@param  {String}   className The class name of the icon to patch.
@param  {Array}    items     An array of item objects to generate the menu.
@param  {Function} callback  The function to call when something is clicked.
@return {undefined}
Patch a picker icon so it becomes interactive and has a context menu . @param { String } name The name of the context menu - forms the ID . @param { String } className The class name of the icon to patch . @param { Array } items An array of item objects to generate the menu . @param { Function } callback The function to call when something is clicked . @return { undefined }
function patchIcon(name, className, items, callback) {
      var id = 'snd_ui16dp_' + name + '_menu',
          post_istanbul = minVersion('J'),
          icon;
      createContextMenu(id, items);
      icon = $('.' + className + ' ' + (post_istanbul ? 'a.btn-icon' : 'span.label-icon'));
      if (icon.length) {
        icon.snd_ui16dp_menu({
          menu_id: "#" + id,
          callback: callback
        }).css('cursor', 'pointer');
        jslog('snd_ui16_developer_patch icon picker patch applied to ' + name + ' picker.');
      } else {
        jslog('snd_ui16_developer_patch icon picker patch unable to find ' + name + ' picker.');
      }
    }
function patchIcon ( name , className , items , callback ) { var id = 'snd_ui16dp_' + name + '_menu' , post_istanbul = minVersion ( 'J' ) , icon ; createContextMenu ( id , items ) ; icon = $ ( '.' + className + ' ' + ( post_istanbul ? 'a.btn-icon' : 'span.label-icon' ) ) ; if ( icon . length ) { icon . snd_ui16dp_menu ( { menu_id : "#" + id , callback : callback } ) . css ( 'cursor' , 'pointer' ) ; jslog ( 'snd_ui16_developer_patch icon picker patch applied to ' + name + ' picker.' ) ; } else { jslog ( 'snd_ui16_developer_patch icon picker patch unable to find ' + name + ' picker.' ) ; } }
Patch a picker icon so it becomes interactive and has a context menu.
Patch a picker icon so it becomes interactive and has a context menu .