minor fixes
git-svn-id: http://svn.d4science-ii.research-infrastructures.eu/gcube/trunk/portlets/widgets/ckan-metadata-publisher-widget@133958 82a268e6-3cf1-43bd-a215-b396298e98cf
This commit is contained in:
parent
41915d6745
commit
001bf95ec2
|
@ -13,10 +13,6 @@ public class ResourceCellLeft extends AbstractCell<ResourceElementBean>{
|
|||
public void render(com.google.gwt.cell.client.Cell.Context context,
|
||||
ResourceElementBean value, SafeHtmlBuilder sb) {
|
||||
|
||||
// Do not render an object if
|
||||
// - is null;
|
||||
// - has been moved to the other side;
|
||||
// - the parent folder is not null;
|
||||
if (value == null || value.isMovedToRight()) {
|
||||
return;
|
||||
}
|
||||
|
|
|
@ -28,7 +28,6 @@ import com.google.gwt.view.client.SelectionChangeEvent;
|
|||
/**
|
||||
* The twin column panels for selection of the files to attach to the catalague product.
|
||||
* @author Costantino Perciante at ISTI-CNR (costantino.perciante@isti.cnr.it)
|
||||
*
|
||||
*/
|
||||
public class TwinColumnSelectionMainPanel extends Composite{
|
||||
|
||||
|
@ -322,15 +321,16 @@ public class TwinColumnSelectionMainPanel extends Composite{
|
|||
Iterator<ResourceElementBean> iterator = setSelected.iterator();
|
||||
while (iterator.hasNext()) {
|
||||
ResourceElementBean resourceElementBean = (ResourceElementBean) iterator.next();
|
||||
resourceElementBean.setMovedToRight(false);
|
||||
int index = dataProviderLeft.getList().indexOf(resourceElementBean);
|
||||
if(index != -1){
|
||||
resourceElementBean.setMovedToRight(false);
|
||||
dataProviderLeft.getList().set(index, resourceElementBean); // replace
|
||||
}
|
||||
}
|
||||
|
||||
// refresh providers
|
||||
dataProviderLeft.flush();
|
||||
dataProviderRight.flush();
|
||||
dataProviderLeft.refresh();
|
||||
dataProviderRight.refresh();
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue