Revision: 6320
          
http://languagetool.svn.sourceforge.net/languagetool/?rev=6320&view=rev
Author:   dnaber
Date:     2012-01-22 23:26:33 +0000 (Sun, 22 Jan 2012)
Log Message:
-----------
make WikiCheck work again

Modified Paths:
--------------
    
trunk/ltcommunity/grails-app/controllers/org/languagetool/HomepageController.groovy
    trunk/ltcommunity/grails-app/views/_ruleMatches.gsp

Modified: 
trunk/ltcommunity/grails-app/controllers/org/languagetool/HomepageController.groovy
===================================================================
--- 
trunk/ltcommunity/grails-app/controllers/org/languagetool/HomepageController.groovy
 2012-01-22 23:23:38 UTC (rev 6319)
+++ 
trunk/ltcommunity/grails-app/controllers/org/languagetool/HomepageController.groovy
 2012-01-22 23:26:33 UTC (rev 6320)
@@ -101,7 +101,8 @@
             }
             if (detectedLang == null || params.text.trim().length() == 0) {
                 render(view:"checkText", model:[matches: [], lang: "auto", 
disabledRules: null, languages: languages,
-                        autoLangDetectionWarning: false, 
autoLangDetectionFailure: true, detectedLang: null])
+                        autoLangDetectionWarning: false, 
autoLangDetectionFailure: true, detectedLang: null,
+                        textToCheck: params.text])
                 return
             }
             lang = detectedLang.getShortName()
@@ -136,7 +137,7 @@
         List ruleMatches = lt.check(text)
         // TODO: count only disabledRules for the current language
         [matches: ruleMatches, lang: lang, languages: languages, 
-           disabledRules: langConfig?.disabledRules, 
+           disabledRules: langConfig?.disabledRules, textToCheck: params.text,
            autoLangDetectionWarning: autoLangDetectionWarning, detectedLang: 
detectedLang]
     }
     

Modified: trunk/ltcommunity/grails-app/views/_ruleMatches.gsp
===================================================================
--- trunk/ltcommunity/grails-app/views/_ruleMatches.gsp 2012-01-22 23:23:38 UTC 
(rev 6319)
+++ trunk/ltcommunity/grails-app/views/_ruleMatches.gsp 2012-01-22 23:26:33 UTC 
(rev 6320)
@@ -10,7 +10,7 @@
            <br/>
            <span class="exampleSentence">${
            org.languagetool.gui.Tools.getContext(matchInfo.getFromPos(),
-           matchInfo.getToPos(), params.text,
+           matchInfo.getToPos(), textToCheck,
            100, "<span class='error'>", "</span>", true)}</span>
             <br />
         </li>

This was sent by the SourceForge.net collaborative development platform, the 
world's largest Open Source development site.


------------------------------------------------------------------------------
Try before you buy = See our experts in action!
The most comprehensive online learning library for Microsoft developers
is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3,
Metro Style Apps, more. Free future releases when you subscribe now!
http://p.sf.net/sfu/learndevnow-dev2
_______________________________________________
Languagetool-cvs mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/languagetool-cvs

Reply via email to