Skip to content
Permalink
Browse files
[JENKINS-31162] Some reviews to @gusreiber's PR
  • Loading branch information
recena committed Mar 16, 2016
1 parent 81e3bc0 commit 21f6f4e779a9cbf707003be455cb3266a6259cc2
Showing 2 changed files with 5 additions and 4 deletions.
@@ -134,8 +134,8 @@ public static String getEffectiveClazz(@Nonnull TopLevelItemDescriptor descripto

/**
* Provides the icon path pattern for the requested item or null if this configurator doesn't have one.
* For example: /plugin/shortnme-of-myplugin/icons/item/:size:/myitem.pngm where :size should be replaced by the consumer using
* the standard sizes in Jenkins: 16x16, 24x24, etc...
* For example: /plugin/shortname-of-myplugin/icons/item/:size:/myitem.pngm where :size should be replaced by the
* consumer using the standard sizes in Jenkins: 16x16, 24x24, etc...
*
* @param descriptor the item it is asking about.
*
@@ -24,7 +24,7 @@ $.when(getItems(jRoot)).done(function(data){
var $form = $root.find('form[name="createItem"]').addClass('jenkins-config new-view');
var $newView = $('<div class="new-view" />')
.attr('name','createItem')
.attr('action','craetItem')
.attr('action','createItem')
.prependTo($form);
var $tabs = $('<div class="jenkins-config-widgets" />').appendTo($newView);
var $categories = $('<div class="categories" />').appendTo($newView);
@@ -247,12 +247,13 @@ $.when(getItems(jRoot)).done(function(data){
}

function drawItem(elem){
var $iconFilePath = jRoot + '/' + elem.iconFilePathPattern.replace(":size", "48x48");
var $item = $([
'<li class="',cleanClassName(elem.class),'"><label><input name="mode" value="',elem.class,'" type="radio" /> <span class="label">', elem.displayName, '</span></label></li>'
].join('')).append([
'<div class="desc">', elem.description, '</div>'
].join('')).append([
'<div class="icn"><span class="img" style="background:url(',jRoot,'/images/items/',cleanClassName(elem.class),'.png)"></span></div>'
'<div class="icn"><span class="img" style="background:url(', $iconFilePath, ')"></span></div>'
].join(''));

function setSelectState(){

0 comments on commit 21f6f4e

Please sign in to comment.