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

Issue 11421173: Remove double notification on Date pickers caused by trying to notify in onClick and in onStop. (Closed)

Created:
8 years ago by Miguel Garcia
Modified:
8 years ago
CC:
chromium-reviews, joi+watch-content_chromium.org, darin-cc_chromium.org, jam
Base URL:
http://git.chromium.org/chromium/src.git@master
Visibility:
Public.

Description

Remove double notification on Date pickers caused by trying to notify in onClick and in onStop. BUG=159381

Patch Set 1 #

Unified diffs Side-by-side diffs Delta from patch set Stats (+0 lines, -6 lines) Patch
M content/public/android/java/src/org/chromium/content/browser/DateTimePickerDialog.java View 1 chunk +0 lines, -3 lines 0 comments Download
M content/public/android/java/src/org/chromium/content/browser/MonthPickerDialog.java View 1 chunk +0 lines, -3 lines 0 comments Download

Messages

Total messages: 5 (0 generated)
Miguel Garcia
It seems you two were involved on upstreaming this. For some reason that I can't ...
8 years ago (2012-11-30 12:43:39 UTC) #1
Leandro Graciá Gil
You probably want to ask Oli about this. I'm adding him to the review. On ...
8 years ago (2012-11-30 13:35:01 UTC) #2
Leandro Graciá Gil
+Oli On 2012/11/30 13:35:01, Leandro Graciá Gil wrote: > You probably want to ask Oli ...
8 years ago (2012-11-30 13:35:29 UTC) #3
olilan
Yes, this code to apply the chosen date in onStop is added for JB because ...
8 years ago (2012-12-03 10:26:00 UTC) #4
Miguel Garcia
8 years ago (2012-12-03 19:12:05 UTC) #5
Got it, so I am keeping this behavior then however I think you mention only
distinguishes a cancel (by pressing the cancel button) from a cancel (by
dismissing the dialog some other way). It does not seem to prevent double
notifications which is leading me to believe that we were happily notifying
twice with the same value. That was not a problem until now but due to some
WebKit changes it is.

I am sending https://codereview.chromium.org/11434087/ to fix this.


On 2012/12/03 10:26:00, olilan wrote:
> Yes, this code to apply the chosen date in onStop is added for JB because in
JB
> the behaviour is different from ICS. In JB dismissing the dialog (e.g. by
> pressing Back) applies the chosen date.
> 
> The date should not be applied twice. When this was implemented, code was
added
> to ImeAdapter to prevent this, using the mDialogCanceled variable. If this has
> been lost, that would explain the issue.
> 
> You can see the changes originally made for this at
> https://gerrit-int.chromium.org/#/c/17478
> 
> On 2012/11/30 13:35:29, Leandro Graciá Gil wrote:
> > +Oli
> > 
> > On 2012/11/30 13:35:01, Leandro Graciá Gil wrote:
> > > You probably want to ask Oli about this. I'm adding him to the review.
> > > 
> > > On 2012/11/30 12:43:39, Miguel Garcia wrote:
> > > > It seems you two were involved on upstreaming this. 
> > > > 
> > > > For some reason that I can't understand there we try to notify the
> renderer
> > > both
> > > > onClick and onStop if the APK is 16 or bigger. In those cases (all
cases?)
> > we
> > > > send two notifications instead of one which breaks some assumptions on
> > webkit
> > > > (since some objects are freed once the selection is made).
> > > > 
> > > > Can you throw some light into this? there is very little git history
> > upstream
> > > so
> > > > it's hard to know what motivated that in the first place.

Powered by Google App Engine
This is Rietveld 408576698