revert more usages of new API to fix compilation

This commit is contained in:
Dmitry Jemerov
2013-02-28 14:59:44 +01:00
parent 53abb4e61a
commit 95c61f72da
2 changed files with 2 additions and 2 deletions
@@ -70,7 +70,7 @@ public class PyUnresolvedReferencesInspection extends PyInspection {
public static PyUnresolvedReferencesInspection getInstance(PsiElement element) {
final InspectionProfile inspectionProfile = InspectionProjectProfileManager.getInstance(element.getProject()).getInspectionProfile();
return inspectionProfile.getUnwrappedTool(SHORT_NAME_KEY, element);
return (PyUnresolvedReferencesInspection)inspectionProfile.getUnwrappedTool(SHORT_NAME_KEY.toString(), element);
}
@Nls
@@ -100,7 +100,7 @@ public class Pep8ExternalAnnotator extends ExternalAnnotator<Pep8ExternalAnnotat
if (!profile.isToolEnabled(key)) {
return null;
}
final PyPep8Inspection inspection = profile.getUnwrappedTool(PyPep8Inspection.KEY, file);
final PyPep8Inspection inspection = (PyPep8Inspection)profile.getUnwrappedTool(PyPep8Inspection.KEY.toString(), file);
final List<String> ignoredErrors = inspection.ignoredErrors;
final int margin = CodeStyleSettingsManager.getInstance(file.getProject()).getCurrentSettings().RIGHT_MARGIN;
return new State(homePath, file.getText(), profile.getErrorLevel(key, file), ignoredErrors, margin);