Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(36)

Issue 6764001: Update the code to have the SpellCheckProvider implement WebSpellCheckClient, in preparation for ... (Closed)

Created:
9 years, 9 months ago by jam
Modified:
9 years, 7 months ago
Reviewers:
Lei Zhang, gmorrita
CC:
chromium-reviews, darin-cc_chromium.org, brettw-cc_chromium.org, Hironori Bono
Visibility:
Public.

Description

Update the code to have the SpellCheckProvider implement WebSpellCheckClient, in preparation for moving that code out of RenderView. Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=79735

Patch Set 1 #

Patch Set 2 : sync #

Total comments: 2

Patch Set 3 : '' #

Total comments: 7
Unified diffs Side-by-side diffs Delta from patch set Stats (+161 lines, -159 lines) Patch
M chrome/renderer/spellchecker/spellcheck_provider.h View 1 2 3 chunks +36 lines, -2 lines 2 comments Download
M chrome/renderer/spellchecker/spellcheck_provider.cc View 1 2 4 chunks +117 lines, -11 lines 5 comments Download
M content/renderer/render_view.h View 1 2 8 chunks +1 line, -35 lines 0 comments Download
M content/renderer/render_view.cc View 1 2 12 chunks +7 lines, -111 lines 0 comments Download

Messages

Total messages: 7 (0 generated)
jam
9 years, 9 months ago (2011-03-29 17:21:40 UTC) #1
Lei Zhang
moritta is probably more qualified to review this, but I will take a look.
9 years, 9 months ago (2011-03-29 17:40:16 UTC) #2
gmorrita
Hi John, thank you for doing this! I CCed hbono@ who is an expert on ...
9 years, 9 months ago (2011-03-29 18:28:37 UTC) #3
jam
http://codereview.chromium.org/6764001/diff/4001/content/renderer/render_view.cc File content/renderer/render_view.cc (right): http://codereview.chromium.org/6764001/diff/4001/content/renderer/render_view.cc#newcode635 content/renderer/render_view.cc:635: webview()->setSpellCheckClient(spellcheck_provider_); On 2011/03/29 18:28:37, morrita wrote: > How about ...
9 years, 9 months ago (2011-03-29 18:37:54 UTC) #4
gmorrita
That makes sense. Let's have some cleanup after this change landed. On 2011/03/29 18:37:54, John ...
9 years, 9 months ago (2011-03-29 18:45:58 UTC) #5
jam
so i'm clear, is this a lgtm? On 2011/03/29 18:45:58, morrita wrote: > That makes ...
9 years, 9 months ago (2011-03-29 19:03:35 UTC) #6
gmorrita
9 years, 8 months ago (2011-03-29 20:29:38 UTC) #7
lgtm.

On 2011/03/29 19:03:35, John Abd-El-Malek wrote:
> so i'm clear, is this a lgtm?
> 
> On 2011/03/29 18:45:58, morrita wrote:
> > That makes sense. Let's have some cleanup after this change landed.
> > 
> > 
> > On 2011/03/29 18:37:54, John Abd-El-Malek wrote:
> > >
> >
>
http://codereview.chromium.org/6764001/diff/4001/content/renderer/render_view.cc
> > > File content/renderer/render_view.cc (right):
> > > 
> > >
> >
>
http://codereview.chromium.org/6764001/diff/4001/content/renderer/render_view...
> > > content/renderer/render_view.cc:635:
> > > webview()->setSpellCheckClient(spellcheck_provider_);
> > > On 2011/03/29 18:28:37, morrita wrote:
> > > > How about to allow SpellCheckProvider to set itself to the webview()
> > > > instead of set it by RenderView?
> > > 
> > > yep I was planning on doing this when I move the spellcheck dependencies
> > > completely from RV, soon
> > > 
> > > > 
> > > > I also think that it might be better to setSpellCheckClient(NULL) when
> > > > the client interface is gone before webview() get deleted.
> > > > Such kind of symmetry would make its lifetime clear.
> > > 
> > > right now I was keeping the old behavior/lifetime, then update the webkit
> > code,
> > > and then update RV to completely remove spelling references.  then i would
> > null
> > > it out in spellcheckprovider's destructor
> > > 
> > >
> >
>
http://codereview.chromium.org/6764001/diff/4005/chrome/renderer/spellchecker...
> > > File chrome/renderer/spellchecker/spellcheck_provider.cc (right):
> > > 
> > >
> >
>
http://codereview.chromium.org/6764001/diff/4005/chrome/renderer/spellchecker...
> > > chrome/renderer/spellchecker/spellcheck_provider.cc:86: // Will be NULL
> during
> > > unit tests.
> > > On 2011/03/29 18:28:37, morrita wrote:
> > > > Could you move this null check to where the instance is created
> > > > and skip the instance creation if it is null?
> > > > Then we can assume that RenderThread is always available
> > > > in methods in this class.
> > > 
> > > i would prefer to just copy the logic from before, and then any cleanup
for
> > the
> > > old code can be done in followup changes.  this reduces the likelyhood of
me
> > > breaking any spellchecking tests, which I'm not familiar with.
> > > 
> > >
> >
>
http://codereview.chromium.org/6764001/diff/4005/chrome/renderer/spellchecker...
> > > File chrome/renderer/spellchecker/spellcheck_provider.h (right):
> > > 
> > >
> >
>
http://codereview.chromium.org/6764001/diff/4005/chrome/renderer/spellchecker...
> > > chrome/renderer/spellchecker/spellcheck_provider.h:84: #if
> defined(OS_MACOSX)
> > > On 2011/03/29 18:28:37, morrita wrote:
> > > > I don't think this ifdef is necessary.
> > > > How about to just left it as false?
> > > 
> > > I was just copying over the existing logic from RenderView.  Was it done
> like
> > > that for any reason?  It does seem less confusing to have it only there
for
> > mac,
> > > so that people looking at this who don't know anything about document tags
> > > realize that it's only for mac.

Powered by Google App Engine
This is Rietveld 408576698