Spellcheck should not only work if the element is contentEditable, it should also work if the document is in designMode.  WebKit has an helper function to check if something is editable in any way (and properly excludes things like read only text areas), so use that here instead of our home grown check.  Note that this code defaults text inputs to not be spell checkable, which is preserving the current behavior.
Spellcheck should not only work if the element is contentEditable, it should also work if the document is in designMode.  WebKit has an helper function to check if something is editable in any way (and properly excludes things like read only text areas), so use that here instead of our home grown check.  Note that this code defaults text inputs to not be spell checkable, which is preserving the current behavior.

BUG=14870
TEST=Will commit a WebKit LayoutTest for this after I check this in.
Review URL: http://codereview.chromium.org/155611

git-svn-id: de016e52bd170d2d4f2344f9bf92d50478b649e0@21034 0039d316-1c4b-4281-b951-d872f2087c98

robclark/chromium,ltilve/chromium,chuan9/chromium-crosswalk,mohamed--abdel-maksoud/chromium.src,ChromiumWebApps/chromium,timopulkkinen/BubbleFish,crosswalk-project/chromium-crosswalk-efl,mogoweb/chromium-crosswalk,ondra-novak/chromium.src,bright-sparks/chromium-spacewalk,krieger-od/nwjs_chromium.src,bright-sparks/chromium-spacewalk,M4sse/chromium.src,dednal/chromium.src,Jonekee/chromium.src,robclark/chromium,mohamed--abdel-maksoud/chromium.src,jaruba/chromium.src,mogoweb/chromium-crosswalk,krieger-od/nwjs_chromium.src,markYoungH/chromium.src,hgl888/chromium-crosswalk-efl,keishi/chromium,Fireblend/chromium-crosswalk,Pluto-tv/chromium-crosswalk,ltilve/chromium,patrickm/chromium.src,ondra-novak/chromium.src,ltilve/chromium,hgl888/chromium-crosswalk,krieger-od/nwjs_chromium.src,Jonekee/chromium.src,Pluto-tv/chromium-crosswalk,Just-D/chromium-1,M4sse/chromium.src,robclark/chromium,dednal/chromium.src,mohamed--abdel-maksoud/chromium.src,nacl-webkit/chrome_deps,ltilve/chromium,dushu1203/chromium.src,keishi/chromium,littlstar/chromium.src,ChromiumWebApps/chromium,Fireblend/chromium-crosswalk,krieger-od/nwjs_chromium.src,TheTypoMaster/chromium-crosswalk,rogerwang/chromium,nacl-webkit/chrome_deps,markYoungH/chromium.src,keishi/chromium,mohamed--abdel-maksoud/chromium.src,rogerwang/chromium,mohamed--abdel-maksoud/chromium.src,jaruba/chromium.src,Pluto-tv/chromium-crosswalk,pozdnyakov/chromium-crosswalk,Just-D/chromium-1,jaruba/chromium.src,mogoweb/chromium-crosswalk,markYoungH/chromium.src,axinging/chromium-crosswalk,Jonekee/chromium.src,hgl888/chromium-crosswalk,pozdnyakov/chromium-crosswalk,M4sse/chromium.src,crosswalk-project/chromium-crosswalk-efl,ondra-novak/chromium.src,bright-sparks/chromium-spacewalk,anirudhSK/chromium,Chilledheart/chromium,mogoweb/chromium-crosswalk,keishi/chromium,Jonekee/chromium.src,axinging/chromium-crosswalk,crosswalk-project/chromium-crosswalk-efl,ondra-novak/chromium.src,littlstar/chromium.src,M4sse/chromium.src,zcbenz/cefode-chromium,mohamed--abdel-maksoud/chromium.src,M4sse/chromium.src,hgl888/chromium-crosswalk-efl,robclark/chromium,mohamed--abdel-maksoud/chromium.src,keishi/chromium,dushu1203/chromium.src,ltilve/chromium,hujiajie/pa-chromium,chuan9/chromium-crosswalk,TheTypoMaster/chromium-crosswalk,dednal/chromium.src,littlstar/chromium.src,rogerwang/chromium,markYoungH/chromium.src,jaruba/chromium.src,PeterWangIntel/chromium-crosswalk,chuan9/chromium-crosswalk,krieger-od/nwjs_chromium.src,mogoweb/chromium-crosswalk,robclark/chromium,anirudhSK/chromium,dushu1203/chromium.src,hgl888/chromium-crosswalk-efl,timopulkkinen/BubbleFish,krieger-od/nwjs_chromium.src,nacl-webkit/chrome_deps,hgl888/chromium-crosswalk-efl,chuan9/chromium-crosswalk,rogerwang/chromium,PeterWangIntel/chromium-crosswalk,ltilve/chromium,pozdnyakov/chromium-crosswalk,patrickm/chromium.src,Fireblend/chromium-crosswalk,anirudhSK/chromium,junmin-zhu/chromium-rivertrail,dednal/chromium.src,dednal/chromium.src,jaruba/chromium.src,bright-sparks/chromium-spacewalk,hgl888/chromium-crosswalk-efl,patrickm/chromium.src,nacl-webkit/chrome_deps,jaruba/chromium.src,zcbenz/cefode-chromium,Chilledheart/chromium,anirudhSK/chromium,timopulkkinen/BubbleFish,hujiajie/pa-chromium,nacl-webkit/chrome_deps,Chilledheart/chromium,keishi/chromium,Fireblend/chromium-crosswalk,anirudhSK/chromium,bright-sparks/chromium-spacewalk,dushu1203/chromium.src,timopulkkinen/BubbleFish,PeterWangIntel/chromium-crosswalk,axinging/chromium-crosswalk,dushu1203/chromium.src,pozdnyakov/chromium-crosswalk,pozdnyakov/chromium-crosswalk,mogoweb/chromium-crosswalk,Just-D/chromium-1,markYoungH/chromium.src,littlstar/chromium.src,mohamed--abdel-maksoud/chromium.src,crosswalk-project/chromium-crosswalk-efl,hujiajie/pa-chromium,hgl888/chromium-crosswalk,TheTypoMaster/chromium-crosswalk,crosswalk-project/chromium-crosswalk-efl,Jonekee/chromium.src,TheTypoMaster/chromium-crosswalk,keishi/chromium,Pluto-tv/chromium-crosswalk,pozdnyakov/chromium-crosswalk,anirudhSK/chromium,axinging/chromium-crosswalk,hgl888/chromium-crosswalk,littlstar/chromium.src,Chilledheart/chromium,Pluto-tv/chromium-crosswalk,TheTypoMaster/chromium-crosswalk,zcbenz/cefode-chromium,rogerwang/chromium,chuan9/chromium-crosswalk,junmin-zhu/chromium-rivertrail,Jonekee/chromium.src,robclark/chromium,timopulkkinen/BubbleFish,robclark/chromium,crosswalk-project/chromium-crosswalk-efl,junmin-zhu/chromium-rivertrail,TheTypoMaster/chromium-crosswalk,dednal/chromium.src,M4sse/chromium.src,jaruba/chromium.src,timopulkkinen/BubbleFish,Jonekee/chromium.src,patrickm/chromium.src,Chilledheart/chromium,crosswalk-project/chromium-crosswalk-efl,mogoweb/chromium-crosswalk,Pluto-tv/chromium-crosswalk,jaruba/chromium.src,hgl888/chromium-crosswalk,zcbenz/cefode-chromium,junmin-zhu/chromium-rivertrail,markYoungH/chromium.src,mogoweb/chromium-crosswalk,robclark/chromium,hgl888/chromium-crosswalk-efl,TheTypoMaster/chromium-crosswalk,Just-D/chromium-1,hujiajie/pa-chromium,axinging/chromium-crosswalk,ondra-novak/chromium.src,axinging/chromium-crosswalk,zcbenz/cefode-chromium,crosswalk-project/chromium-crosswalk-efl,dednal/chromium.src,junmin-zhu/chromium-rivertrail,zcbenz/cefode-chromium,krieger-od/nwjs_chromium.src,fujunwei/chromium-crosswalk,hgl888/chromium-crosswalk-efl,ondra-novak/chromium.src,hgl888/chromium-crosswalk,mogoweb/chromium-crosswalk,nacl-webkit/chrome_deps,Just-D/chromium-1,ondra-novak/chromium.src,pozdnyakov/chromium-crosswalk,bright-sparks/chromium-spacewalk,Jonekee/chromium.src,axinging/chromium-crosswalk,anirudhSK/chromium,krieger-od/nwjs_chromium.src,jaruba/chromium.src,M4sse/chromium.src,PeterWangIntel/chromium-crosswalk,dushu1203/chromium.src,rogerwang/chromium,Fireblend/chromium-crosswalk,TheTypoMaster/chromium-crosswalk,hgl888/chromium-crosswalk-efl,hgl888/chromium-crosswalk-efl,nacl-webkit/chrome_deps,ChromiumWebApps/chromium,fujunwei/chromium-crosswalk,littlstar/chromium.src,chuan9/chromium-crosswalk,hujiajie/pa-chromium,mohamed--abdel-maksoud/chromium.src,bright-sparks/chromium-spacewalk,Just-D/chromium-1,Chilledheart/chromium,pozdnyakov/chromium-crosswalk,junmin-zhu/chromium-rivertrail,pozdnyakov/chromium-crosswalk,keishi/chromium,ChromiumWebApps/chromium,ltilve/chromium,keishi/chromium,ChromiumWebApps/chromium,timopulkkinen/BubbleFish,littlstar/chromium.src,dednal/chromium.src,hgl888/chromium-crosswalk,Fireblend/chromium-crosswalk,mogoweb/chromium-crosswalk,TheTypoMaster/chromium-crosswalk,ChromiumWebApps/chromium,dednal/chromium.src,rogerwang/chromium,mohamed--abdel-maksoud/chromium.src,fujunwei/chromium-crosswalk,mohamed--abdel-maksoud/chromium.src,Pluto-tv/chromium-crosswalk,Chilledheart/chromium,timopulkkinen/BubbleFish,junmin-zhu/chromium-rivertrail,jaruba/chromium.src,zcbenz/cefode-chromium,zcbenz/cefode-chromium,chuan9/chromium-crosswalk,robclark/chromium,nacl-webkit/chrome_deps,patrickm/chromium.src,Pluto-tv/chromium-crosswalk,axinging/chromium-crosswalk,axinging/chromium-crosswalk,dushu1203/chromium.src,Just-D/chromium-1,Just-D/chromium-1,Fireblend/chromium-crosswalk,ChromiumWebApps/chromium,keishi/chromium,dednal/chromium.src,PeterWangIntel/chromium-crosswalk,ondra-novak/chromium.src,patrickm/chromium.src,zcbenz/cefode-chromium,hgl888/chromium-crosswalk,junmin-zhu/chromium-rivertrail,ltilve/chromium,timopulkkinen/BubbleFish,timopulkkinen/BubbleFish,dushu1203/chromium.src,ChromiumWebApps/chromium,pozdnyakov/chromium-crosswalk,chuan9/chromium-crosswalk,PeterWangIntel/chromium-crosswalk,patrickm/chromium.src,ltilve/chromium,anirudhSK/chromium,nacl-webkit/chrome_deps,Chilledheart/chromium,zcbenz/cefode-chromium,hujiajie/pa-chromium,ChromiumWebApps/chromium,anirudhSK/chromium,hgl888/chromium-crosswalk,junmin-zhu/chromium-rivertrail,markYoungH/chromium.src,Chilledheart/chromium,dushu1203/chromium.src,dushu1203/chromium.src,Jonekee/chromium.src,markYoungH/chromium.src,patrickm/chromium.src,fujunwei/chromium-crosswalk,ChromiumWebApps/chromium,hujiajie/pa-chromium,Jonekee/chromium.src,Just-D/chromium-1,bright-sparks/chromium-spacewalk,hujiajie/pa-chromium,nacl-webkit/chrome_deps,jaruba/chromium.src,keishi/chromium,anirudhSK/chromium,anirudhSK/chromium,axinging/chromium-crosswalk,PeterWangIntel/chromium-crosswalk,fujunwei/chromium-crosswalk,Fireblend/chromium-crosswalk,hujiajie/pa-chromium,M4sse/chromium.src,rogerwang/chromium,markYoungH/chromium.src,fujunwei/chromium-crosswalk,markYoungH/chromium.src,PeterWangIntel/chromium-crosswalk,bright-sparks/chromium-spacewalk,nacl-webkit/chrome_deps,pozdnyakov/chromium-crosswalk,junmin-zhu/chromium-rivertrail,littlstar/chromium.src,M4sse/chromium.src,fujunwei/chromium-crosswalk,timopulkkinen/BubbleFish,PeterWangIntel/chromium-crosswalk,krieger-od/nwjs_chromium.src,krieger-od/nwjs_chromium.src,rogerwang/chromium,markYoungH/chromium.src,ChromiumWebApps/chromium,hujiajie/pa-chromium,dushu1203/chromium.src,dednal/chromium.src,hujiajie/pa-chromium,chuan9/chromium-crosswalk,axinging/chromium-crosswalk,ondra-novak/chromium.src,robclark/chromium,crosswalk-project/chromium-crosswalk-efl,patrickm/chromium.src,fujunwei/chromium-crosswalk,Fireblend/chromium-crosswalk,hgl888/chromium-crosswalk-efl,Pluto-tv/chromium-crosswalk,M4sse/chromium.src,ChromiumWebApps/chromium,krieger-od/nwjs_chromium.src,Jonekee/chromium.src,M4sse/chromium.src,zcbenz/cefode-chromium,anirudhSK/chromium,junmin-zhu/chromium-rivertrail,fujunwei/chromium-crosswalk,rogerwang/chromium