Fixed rendering of integral transaction attributes and updated version
numbers
This commit is contained in:
@ -2,7 +2,7 @@ Manifest-Version: 1.0
|
||||
Bundle-ManifestVersion: 2
|
||||
Bundle-Name: %Bundle-Name
|
||||
Bundle-SymbolicName: com.minres.scviewer.e4.application;singleton:=true
|
||||
Bundle-Version: 1.1.0.qualifier
|
||||
Bundle-Version: 1.1.1.qualifier
|
||||
Bundle-Vendor: %Bundle-Vendor
|
||||
Require-Bundle: javax.inject;bundle-version="1.0.0",
|
||||
org.eclipse.core.runtime;bundle-version="3.11.1",
|
||||
|
@ -8,5 +8,5 @@
|
||||
<relativePath>../com.minres.scviewer.parent</relativePath>
|
||||
</parent>
|
||||
<packaging>eclipse-plugin</packaging>
|
||||
<version>1.1.0-SNAPSHOT</version>
|
||||
<version>1.1.1-SNAPSHOT</version>
|
||||
</project>
|
@ -55,6 +55,7 @@ import org.eclipse.swt.widgets.Tree;
|
||||
import com.minres.scviewer.database.ITx;
|
||||
import com.minres.scviewer.database.ITxAttribute;
|
||||
import com.minres.scviewer.database.ITxRelation;
|
||||
import com.minres.scviewer.database.DataType;
|
||||
import com.minres.scviewer.e4.application.Messages;
|
||||
import com.minres.scviewer.e4.application.provider.TxPropertiesLabelProvider;
|
||||
|
||||
@ -579,7 +580,13 @@ PROPS, /** The attrs. */
|
||||
default:
|
||||
if (element instanceof ITxAttribute) {
|
||||
ITxAttribute attribute = (ITxAttribute) element;
|
||||
return new StyledString(attribute.getValue().toString());
|
||||
String value = attribute.getValue().toString();
|
||||
if((DataType.UNSIGNED == attribute.getDataType() || DataType.INTEGER==attribute.getDataType()) && !"0".equals(value)) {
|
||||
try {
|
||||
value = attribute.getValue().toString() + " [0x"+Long.toHexString(Long.parseLong(attribute.getValue().toString()))+"]";
|
||||
} catch(NumberFormatException e) { }
|
||||
}
|
||||
return new StyledString(value);
|
||||
}else if(element instanceof Object[]){
|
||||
Object[] elements = (Object[]) element;
|
||||
return new StyledString(elements[field].toString());
|
||||
|
Reference in New Issue
Block a user