removed mark as read method according to HL

git-svn-id: http://svn.d4science-ii.research-infrastructures.eu/gcube/trunk/portlets/user/workspace@112334 82a268e6-3cf1-43bd-a215-b396298e98cf
This commit is contained in:
Francesco Mangiacrapa 2015-03-03 16:15:32 +00:00
parent badff07973
commit 8b99dc02e5
3 changed files with 17 additions and 33 deletions

1
.tern-project Normal file
View File

@ -0,0 +1 @@
{"ide":{"scriptPaths":[]},"plugins":{"aui":{},"liferay":{},"yui":{}},"libs":["ecma5","browser"]}

View File

@ -422,15 +422,6 @@ public class AppController implements SubscriberInterface {
public void onFileDownloadEvent(FileDownloadEvent fileDownloadEvent) {
if(fileDownloadEvent!=null && fileDownloadEvent.getItemIdentifier()!=null){
// FileGridModel fileItem = getGridSelectedItem();
//
// String id = fileDownloadEvent.getItemIdentifier()!=null? fileDownloadEvent.getItemIdentifier():"";
//
// if(fileItem!=null && id.compareTo(fileItem.getIdentifier())==0){
// fileItem.setMarkAsRead(true);
// accountingSetItemAsRead(true);
// }
AppControllerExplorer.getEventBus().fireEvent(new FileDownloadEvent(fileDownloadEvent.getItemIdentifier(), fileDownloadEvent.getItemName(), fileDownloadEvent.getDownloadType()));
}
@ -463,11 +454,6 @@ public class AppController implements SubscriberInterface {
if(!event.isMultiSelection()){ //IS NOT MULTISELECTION
doElementGridSelected(true, event.getSourceFile());
//REMOVED IS MARK AS READ FROM HL - 2015/02/24
// FileGridModel fileItem = getGridSelectedItem();
// if(fileItem!=null){
// accountingSetItemAsRead(fileItem.isMarkAsRead());
// }
}else{ //IS MULTISELECTION
wsPortlet.getGxtCardLayoutResultPanel().getToolBarItemFunctionalities().activeButtonForMultiSelection(true);
@ -970,10 +956,10 @@ public class AppController implements SubscriberInterface {
});
}
/*
private void accountingSetItemAsRead(boolean read) {
wsPortlet.getToolBarItemDetails().setRead(read);
}
}*/
private void doElementGridSelected(boolean isSelected, FileModel target) {
@ -1640,14 +1626,11 @@ public class AppController implements SubscriberInterface {
FileGridModel fileItem = wsPortlet.getGridGroupContainer().getFileGridModelByIdentifier(itemIdentifier);
if(fileItem!=null && itemIdentifier!= null && fileItem.getIdentifier().compareTo(itemIdentifier)==0){
//REMOVED FROM HL
// fileItem.setMarkAsRead(true);
//SET ICON AS READ IF ITEM IS SELECETED IN THE GRID
FileGridModel fileSelected = getGridSelectedItem();
if(fileSelected!=null && fileSelected.getIdentifier().compareTo(itemIdentifier)==0)
accountingSetItemAsRead(true);
// FileGridModel fileSelected = getGridSelectedItem();
// if(fileSelected!=null && fileSelected.getIdentifier().compareTo(itemIdentifier)==0)
// accountingSetItemAsRead(true);
}
}

View File

@ -209,17 +209,17 @@ public class GxtBottomToolBarItem extends ToolBar{
}
/**
* @param markAsRead
*/
public void setRead(boolean markAsRead) {
if(markAsRead)
bRead.setIcon(Resources.getIconRead());
else
bRead.setIcon(Resources.getIconNotRead());
bRead.setEnabled(markAsRead);
}
// /**
// * @param markAsRead
// */
// public void setRead(boolean markAsRead) {
// if(markAsRead)
// bRead.setIcon(Resources.getIconRead());
// else
// bRead.setIcon(Resources.getIconNotRead());
//
// bRead.setEnabled(markAsRead);
// }
public void updateACLInfo(WorkspaceACL acl){