view offline inspection results: do not try to use root profile instead of inspection based => use profile by loaded data instead

This commit is contained in:
anna
2011-06-24 19:04:52 +04:00
parent ff7344f78c
commit c061e2fe9c
@@ -149,7 +149,7 @@ public class ViewOfflineResultsAction extends AnAction implements DumbAware {
final String title) {
Profile profile;
if (profileName != null) {
profile = InspectionProjectProfileManager.getInstance(project).getProfile(profileName);
profile = InspectionProjectProfileManager.getInstance(project).getProfile(profileName, false);
if (profile == null) {
profile = InspectionProfileManager.getInstance().getProfile(profileName, false);
}
@@ -162,7 +162,7 @@ public class ViewOfflineResultsAction extends AnAction implements DumbAware {
inspectionProfile = (InspectionProfile)profile;
}
else {
inspectionProfile = new InspectionProfileImpl("Server Side") {
inspectionProfile = new InspectionProfileImpl(profileName) {
public boolean isToolEnabled(final HighlightDisplayKey key, PsiElement element) {
return resMap.containsKey(key.toString());
}