FELIX-3320 Ensure display status is updated on start/stop of the bundle (thanks to Alex Parvalescu providing the patch)

git-svn-id: https://svn.apache.org/repos/asf/felix/trunk@1305533 13f79535-47bb-0310-9956-ffa450edef68
diff --git a/webconsole/src/main/resources/res/ui/bundles.js b/webconsole/src/main/resources/res/ui/bundles.js
index 9406b16..f8532eb 100644
--- a/webconsole/src/main/resources/res/ui/bundles.js
+++ b/webconsole/src/main/resources/res/ui/bundles.js
@@ -73,25 +73,25 @@
     var name = bundle.name + '<span class="symName">' + bundle.symbolicName + '</span>';
 
 	tr.attr('id', 'entry'+id);
-	tr.find('td:eq(0)').text(id);
+	tr.children('td:eq(0)').text(id);
 	tr.find('.bIcon').attr('id', 'img'+id).click(function() {showDetails(id)});
 	tr.find('.bName').html( drawDetails ? name : '<a href="' + pluginRoot + '/' + id + '">' + name + '</a>' );
-	tr.find('td:eq(2)').text( bundle.version );
-	tr.find('td:eq(3)').text( bundle.category );
+	tr.children('td:eq(2)').text( bundle.version );
+	tr.children('td:eq(3)').text( bundle.category );
 	if (id == 0) { // system bundle has no actions
-		tr.find('td:eq(4)').text( stateString(bundle) );
-		tr.find('td:eq(5) ul').addClass('ui-helper-hidden');
+		tr.children('td:eq(4)').text( stateString(bundle) );
+		tr.children('td:eq(5)').find('ul').addClass('ui-helper-hidden');
 	} else {
 		entrySetupState( bundle, tr, id );
 	}
 	return tr;
 }
 function entrySetupState( /* Object */ bundle, tr, id) {
-	var start   = tr.find('td:eq(5) ul li:eq(0)').removeClass('ui-helper-hidden').unbind('click');
-	var stop    = tr.find('td:eq(5) ul li:eq(1)').removeClass('ui-helper-hidden').unbind('click');
-	var refresh = tr.find('td:eq(5) ul li:eq(2)').unbind('click').click(function() {return changeDataEntryState(id, 'refresh')});
-	var update  = tr.find('td:eq(5) ul li:eq(3)').unbind('click').click(function() {return changeDataEntryState(id, 'update')});
-	var remove  = tr.find('td:eq(5) ul li:eq(4)').removeClass('ui-helper-hidden').unbind('click');
+	var start   = tr.children('td:eq(5)').find('ul li:eq(0)').removeClass('ui-helper-hidden').unbind('click');
+	var stop    = tr.children('td:eq(5)').find('ul li:eq(1)').removeClass('ui-helper-hidden').unbind('click');
+	var refresh = tr.children('td:eq(5)').find('ul li:eq(2)').unbind('click').click(function() {return changeDataEntryState(id, 'refresh')});
+	var update  = tr.children('td:eq(5)').find('ul li:eq(3)').unbind('click').click(function() {return changeDataEntryState(id, 'update')});
+	var remove  = tr.children('td:eq(5)').find('ul li:eq(4)').removeClass('ui-helper-hidden').unbind('click');
 	start = hasStart(bundle) ?
 		start.click(function() {return changeDataEntryState(id, 'start')}) :
 		start.addClass('ui-helper-hidden');
@@ -101,7 +101,7 @@
 	remove = hasUninstall(bundle) ?
 		remove.click(function() {return changeDataEntryState(id, 'uninstall')}) :
 		remove.addClass('ui-helper-hidden');
-	tr.find('td:eq(4)').text( stateString(bundle) );
+	tr.children('td:eq(4)').text( stateString(bundle) );
 }
 
 function loadData() {