コード例 #1
0
 static boolean confirmMoveOfReadOnlyElements(
     IJavaScriptElement[] javaElements, IResource[] resources, IReorgQueries queries)
     throws CoreException {
   String queryTitle = RefactoringCoreMessages.ReadOnlyResourceFinder_2;
   String question = RefactoringCoreMessages.ReadOnlyResourceFinder_3;
   return ReadOnlyResourceFinder.confirmOperationOnReadOnlyElements(
       queryTitle, question, javaElements, resources, queries);
 }
コード例 #2
0
 private static boolean confirmOperationOnReadOnlyElements(
     String queryTitle,
     String question,
     IJavaScriptElement[] javaElements,
     IResource[] resources,
     IReorgQueries queries)
     throws CoreException {
   boolean hasReadOnlyResources =
       ReadOnlyResourceFinder.hasReadOnlyResourcesAndSubResources(javaElements, resources);
   if (hasReadOnlyResources) {
     IConfirmQuery query =
         queries.createYesNoQuery(queryTitle, false, IReorgQueries.CONFIRM_READ_ONLY_ELEMENTS);
     return query.confirm(question);
   }
   return true;
 }