Spelling preference activated (no dictionary available though)
authorjsurfer <jsurfer>
Thu, 23 Sep 2004 19:42:19 +0000 (19:42 +0000)
committerjsurfer <jsurfer>
Thu, 23 Sep 2004 19:42:19 +0000 (19:42 +0000)
net.sourceforge.phpeclipse/src/net/sourceforge/phpdt/internal/ui/text/spelling/SpellReconcileStrategy.java

index b77b767..a977166 100644 (file)
@@ -17,11 +17,13 @@ import java.util.Locale;
 import net.sourceforge.phpdt.core.IProblemRequestor;
 import net.sourceforge.phpdt.core.compiler.IProblem;
 import net.sourceforge.phpdt.internal.ui.PHPUIMessages;
+import net.sourceforge.phpdt.internal.ui.text.IPHPPartitions;
 import net.sourceforge.phpdt.internal.ui.text.spelling.engine.ISpellCheckEngine;
 import net.sourceforge.phpdt.internal.ui.text.spelling.engine.ISpellCheckPreferenceKeys;
 import net.sourceforge.phpdt.internal.ui.text.spelling.engine.ISpellChecker;
 import net.sourceforge.phpdt.internal.ui.text.spelling.engine.ISpellEvent;
 import net.sourceforge.phpdt.internal.ui.text.spelling.engine.ISpellEventListener;
+import net.sourceforge.phpeclipse.phpeditor.php.PHPDocumentPartitioner;
 
 import org.eclipse.core.runtime.IProgressMonitor;
 import org.eclipse.jface.preference.IPreferenceStore;
@@ -257,7 +259,7 @@ public class SpellReconcileStrategy implements IReconcilingStrategy, IReconcilin
                fPartitioning= partitioning;
                fPreferences= store;
 
-               updateProblemRequestor();
+               updateProblemRequestor(); 
        }
 
        /**
@@ -338,7 +340,8 @@ public class SpellReconcileStrategy implements IReconcilingStrategy, IReconcilin
                                                
                                                for (int index= 0; index < partitions.length; index++) {
                                                        partition= partitions[index];
-                                                       if (!partition.getType().equals(IDocument.DEFAULT_CONTENT_TYPE))
+                                                       if (!partition.getType().equals(IDocument.DEFAULT_CONTENT_TYPE) &&
+                                                           !partition.getType().equals(PHPDocumentPartitioner.PHP_SCRIPT_CODE))
                                                                checker.execute(new SpellCheckIterator(fDocument, partition, locale));
                                                }