예제 #1
0
 public void showPageFor(RefEntity refEntity, CommonProblemDescriptor descriptor) {
   try {
     String html = generateHTML(refEntity, descriptor);
     myHTMLViewer.read(new StringReader(html), null);
     setupStyle();
     myHTMLViewer.setCaretPosition(0);
   } catch (Exception e) {
     showEmpty();
   } finally {
     myCurrentEntity = refEntity;
     myCurrentDescriptor = descriptor;
   }
 }
예제 #2
0
 private void showPageFromHistory(RefEntity newEntity) {
   InspectionTool tool = getTool(newEntity);
   try {
     if (tool instanceof DescriptorProviderInspection
         && !(tool instanceof CommonInspectionToolWrapper)) {
       showEmpty();
     } else {
       try {
         String html = generateHTML(newEntity, tool);
         myHTMLViewer.read(new StringReader(html), null);
         setupStyle();
         myHTMLViewer.setCaretPosition(0);
       } catch (Exception e) {
         showEmpty();
       }
     }
   } finally {
     myCurrentEntity = newEntity;
     myCurrentDescriptor = null;
   }
 }