in karaf/feature/src/main/java/org/apache/karaf/webconsole/karaf/feature/feature/FeaturesActionsPanel.java [47:71]
protected List<Link> getLinks(Feature object, String linkId, String labelId) {
Link link = new Link(linkId) {
@Override
public void onClick() {
try {
Feature object = (Feature) FeaturesActionsPanel.this.getDefaultModelObject();
if (isInstalled(object)) {
featuresService.uninstallFeature(object.getName());
} else {
featuresService.installFeature(object.getName());
}
} catch (Exception e) {
e.printStackTrace();
}
}
};
link.add(new AttributeModifier("class", isInstalled(object) ? "icon-eject" : "icon-play"));
link.add(new Label(labelId));
// add image to the link
return Arrays.asList(link);
}