Пример #1
0
  private void highlightMatch(SearchMatch sm) {
    if (sm == null) {
      return;
    }

    switch (sm.getLocation()) {
      case REQUEST_HEAD:
        requestPanel.highlightHeader(sm);
        requestPanel.setTabFocus();
        requestPanel.requestFocus();
        break;
      case REQUEST_BODY:
        requestPanel.highlightBody(sm);
        requestPanel.setTabFocus();
        requestPanel.requestFocus();
        break;
      case RESPONSE_HEAD:
        responsePanel.highlightHeader(sm);
        responsePanel.setTabFocus();
        responsePanel.requestFocus();
        break;
      case RESPONSE_BODY:
        responsePanel.highlightBody(sm);
        responsePanel.setTabFocus();
        responsePanel.requestFocus();
        break;
    }
  }
Пример #2
0
 /* (non-Javadoc)
  * @see org.eclipse.jdt.core.search.SearchRequestor#acceptSearchMatch(org.eclipse.jdt.core.search.SearchMatch)
  */
 public void acceptSearchMatch(SearchMatch match) throws CoreException {
   if (!match.isInsideDocComment())
     fMatch =
         new Match(
             match.getElement(), Match.UNIT_CHARACTER, match.getOffset(), match.getLength());
 }
Пример #3
0
 /* (non-Javadoc)
  * @see org.eclipse.jdt.core.search.SearchRequestor#acceptSearchMatch(org.eclipse.jdt.core.search.SearchMatch)
  */
 public void acceptSearchMatch(SearchMatch match) throws CoreException {
   if (match.getAccuracy() == SearchMatch.A_ACCURATE && !match.isInsideDocComment()) {
     fUsed = true;
   }
 }