WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
110131
Add event dispatch class for the new calendar picker
https://bugs.webkit.org/show_bug.cgi?id=110131
Summary
Add event dispatch class for the new calendar picker
Keishi Hattori
Reported
2013-02-18 09:16:13 PST
We need to add an event dispatch class that will be used in the new calendar picker
Attachments
Patch
(3.04 KB, patch)
2013-02-18 09:26 PST
,
Keishi Hattori
no flags
Details
Formatted Diff
Diff
Patch
(3.13 KB, patch)
2013-02-21 01:54 PST
,
Keishi Hattori
no flags
Details
Formatted Diff
Diff
Show Obsolete
(1)
View All
Add attachment
proposed patch, testcase, etc.
Keishi Hattori
Comment 1
2013-02-18 09:26:44 PST
Created
attachment 188904
[details]
Patch
Build Bot
Comment 2
2013-02-19 15:42:22 PST
Comment on
attachment 188904
[details]
Patch
Attachment 188904
[details]
did not pass win-ews (win): Output:
http://queues.webkit.org/results/16637067
Kent Tamura
Comment 3
2013-02-19 23:25:06 PST
Comment on
attachment 188904
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=188904&action=review
> Source/WebCore/Resources/pagepopups/calendarPicker.js:690 > + if (!this._callbacks) > + return; > + var callbacksForType = this._callbacks[type]; > + if (!callbacksForType) > + return;
The function does nothing in a case that 'callback' is not registered. Should we warn in such case, or should we accept such call sites?
> Source/WebCore/Resources/pagepopups/calendarPicker.js:691 > + callbacksForType.splice(callbacksForType.indexOf(callback), 1);
What should happen if 'callback' is not a member of 'callbacksForType'?
Keishi Hattori
Comment 4
2013-02-20 00:16:19 PST
(In reply to
comment #3
)
> (From update of
attachment 188904
[details]
) > View in context:
https://bugs.webkit.org/attachment.cgi?id=188904&action=review
> > > Source/WebCore/Resources/pagepopups/calendarPicker.js:690 > > + if (!this._callbacks) > > + return; > > + var callbacksForType = this._callbacks[type]; > > + if (!callbacksForType) > > + return; > > The function does nothing in a case that 'callback' is not registered. Should we warn in such case, or should we accept such call sites? > > > Source/WebCore/Resources/pagepopups/calendarPicker.js:691 > > + callbacksForType.splice(callbacksForType.indexOf(callback), 1); > > What should happen if 'callback' is not a member of 'callbacksForType'?
Like Element.removeEventListener, if the callback is not registered there will be no effect. I kind of feel that this is better because of its simplicity. We usually don't care if the callback exists or not and we just want it gone. For example when calling CalendarPicker.cleanup() you don't know which callbacks have been set (it might be in the middle of an animation) but you know you want to remove them.
Kent Tamura
Comment 5
2013-02-20 03:51:38 PST
Comment on
attachment 188904
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=188904&action=review
> Source/WebCore/ChangeLog:8 > + > + No new tests. Code is not yet used.
Please mention that this patch is a part of
Bug 109439
.
Keishi Hattori
Comment 6
2013-02-21 01:54:57 PST
Created
attachment 189477
[details]
Patch
WebKit Review Bot
Comment 7
2013-02-21 02:18:16 PST
Comment on
attachment 189477
[details]
Patch Clearing flags on attachment: 189477 Committed
r143576
: <
http://trac.webkit.org/changeset/143576
>
WebKit Review Bot
Comment 8
2013-02-21 02:18:20 PST
All reviewed patches have been landed. Closing bug.
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug