ResReferenceValue.toResXmlFormat(): adding plus sign for references to ResIdValue.

This commit is contained in:
Ryszard Wiśniewski 2010-03-23 23:58:06 +01:00
parent 77957ae1ae
commit 921eae6b8d

View File

@ -44,9 +44,15 @@ public class ResReferenceValue extends ResIntValue {
return "@null";
}
ResResSpec spec = getReferent();
boolean newId =
spec.hasDefaultResource() &&
spec.getDefaultResource().getValue() instanceof ResIdValue;
return
(mTheme ? '?' : '@') +
getReferent().getFullName(mPackage, mTheme);
(newId ? "+" : "") +
spec.getFullName(mPackage, mTheme);
}
public ResResSpec getReferent() throws AndrolibException {