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

Issue 291203002: Adds NetInfo v3 Web API to Blink. (Closed)

Created:
6 years, 7 months ago by jkarlin
Modified:
6 years, 2 months ago
CC:
blink-reviews, arv+blink, abarth-chromium, falken, Inactive, horo+watch_chromium.org, kinuko+watch, watchdog-blink-watchlist_google.com, mlamouri (slow - plz ping)
Base URL:
https://chromium.googlesource.com/chromium/blink.git@netinfo1
Visibility:
Public.

Description

Adds Netinfo v3 to Blink. The layout changes outside of netinfo/ are regolding. Design doc: https://docs.google.com/a/chromium.org/document/d/1LTk9uVMGi4kurzcF5ellsAJReTF31fFJMHrQwSVtBjc/ BUG=368358 Committed: https://src.chromium.org/viewvc/blink?view=rev&revision=175200

Patch Set 1 #

Patch Set 2 : Nits #

Patch Set 3 : Moved internals code to a new cl #

Patch Set 4 : Adds a simple observer registration test #

Patch Set 5 : Nits #

Patch Set 6 : Rebase #

Patch Set 7 : Rebase #

Patch Set 8 : Rebase #

Patch Set 9 : Moved WebWorker code to a new CL #

Patch Set 10 : Removing unnecessary function #

Patch Set 11 : Simplified layout tests #

Total comments: 42

Patch Set 12 : Adamk's comments before renaming to match spec #

Patch Set 13 : Refactor and remove bad assertions #

Patch Set 14 : Refactor RuntimeEnabledFeature #

Patch Set 15 : Added GC layout tests and check for internals existence #

Patch Set 16 : Regolding layout tests after moving worker parts to another CL #

Patch Set 17 : Removing spurious trace function #

Patch Set 18 : Forgot the common layout test file #

Total comments: 17

Patch Set 19 : Better assertion for hasPendingActivity #

Patch Set 20 : Addressing ch.dumez's comments #

Total comments: 3

Patch Set 21 : DEFINE_STATIC_LOCAL isn't thread safe #

Total comments: 2

Patch Set 22 : Removing constant strings #

Total comments: 4

Patch Set 23 : Tracing fixes #

Patch Set 24 : Rebase #

Patch Set 25 : Updated tracing macros #

Total comments: 5

Patch Set 26 : Comment typo #

Unified diffs Side-by-side diffs Delta from patch set Stats (+637 lines, -13 lines) Patch
M LayoutTests/fast/dom/Window/property-access-on-cached-properties-after-frame-navigated-expected.txt View 1 chunk +2 lines, -0 lines 0 comments Download
M LayoutTests/fast/dom/Window/property-access-on-cached-properties-after-frame-removed-and-gced-expected.txt View 1 chunk +2 lines, -0 lines 0 comments Download
M LayoutTests/fast/dom/Window/property-access-on-cached-properties-after-frame-removed-expected.txt View 1 chunk +2 lines, -0 lines 0 comments Download
M LayoutTests/fast/dom/Window/property-access-on-cached-window-after-frame-navigated-expected.txt View 1 chunk +2 lines, -0 lines 0 comments Download
M LayoutTests/fast/dom/Window/property-access-on-cached-window-after-frame-removed-and-gced-expected.txt View 1 chunk +2 lines, -0 lines 0 comments Download
M LayoutTests/fast/dom/Window/property-access-on-cached-window-after-frame-removed-expected.txt View 1 chunk +2 lines, -0 lines 0 comments Download
M LayoutTests/fast/dom/Window/resources/window-property-collector.js View 1 chunk +1 line, -0 lines 0 comments Download
M LayoutTests/fast/dom/navigator-detached-no-crash-expected.txt View 2 chunks +2 lines, -0 lines 0 comments Download
A LayoutTests/netinfo/basic-operation.html View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 1 chunk +27 lines, -0 lines 0 comments Download
A LayoutTests/netinfo/basic-operation-expected.txt View 1 chunk +12 lines, -0 lines 0 comments Download
A LayoutTests/netinfo/gc-frame-listeners.html View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 1 chunk +48 lines, -0 lines 0 comments Download
A LayoutTests/netinfo/gc-frame-listeners-expected.txt View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 1 chunk +15 lines, -0 lines 0 comments Download
A LayoutTests/netinfo/gc-unused-listeners.html View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 1 chunk +33 lines, -0 lines 0 comments Download
A + LayoutTests/netinfo/gc-unused-listeners-expected.txt View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 1 chunk +3 lines, -3 lines 0 comments Download
A LayoutTests/netinfo/gc-used-listeners.html View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 1 chunk +29 lines, -0 lines 0 comments Download
A + LayoutTests/netinfo/gc-used-listeners-expected.txt View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 1 chunk +2 lines, -2 lines 0 comments Download
A LayoutTests/netinfo/multiple-frames.html View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 1 chunk +58 lines, -0 lines 0 comments Download
A + LayoutTests/netinfo/multiple-frames-expected.txt View 1 chunk +1 line, -1 line 0 comments Download
A LayoutTests/netinfo/resources/netinfo_common.js View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 1 chunk +10 lines, -0 lines 0 comments Download
A LayoutTests/netinfo/unregister-during-event.html View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 1 chunk +33 lines, -0 lines 0 comments Download
A + LayoutTests/netinfo/unregister-during-event-expected.txt View 1 2 3 1 chunk +1 line, -1 line 0 comments Download
M LayoutTests/webexposed/global-constructors-listing-expected.txt View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 1 chunk +1 line, -0 lines 0 comments Download
M Source/core/events/EventTypeNames.in View 1 chunk +1 line, -0 lines 0 comments Download
M Source/core/page/NetworkStateNotifier.h View 1 2 3 4 5 6 7 8 9 10 11 12 1 chunk +4 lines, -2 lines 0 comments Download
M Source/core/page/NetworkStateNotifier.cpp View 1 2 3 4 5 6 7 8 9 10 11 12 1 chunk +0 lines, -1 line 0 comments Download
M Source/modules/EventTargetModulesFactory.in View 1 2 3 4 5 6 7 8 9 10 11 12 1 chunk +1 line, -0 lines 0 comments Download
M Source/modules/modules.gypi View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 3 chunks +6 lines, -0 lines 0 comments Download
A Source/modules/netinfo/NavigatorNetworkInformation.h View 1 2 3 4 5 6 7 8 9 10 11 12 1 chunk +41 lines, -0 lines 0 comments Download
A Source/modules/netinfo/NavigatorNetworkInformation.cpp View 1 2 3 4 5 6 7 8 9 10 11 12 1 chunk +64 lines, -0 lines 0 comments Download
A + Source/modules/netinfo/NavigatorNetworkInformation.idl View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +2 lines, -3 lines 0 comments Download
A Source/modules/netinfo/NetworkInformation.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 1 chunk +65 lines, -0 lines 0 comments Download
A Source/modules/netinfo/NetworkInformation.cpp View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 1 chunk +142 lines, -0 lines 0 comments Download
A Source/modules/netinfo/NetworkInformation.idl View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 1 chunk +22 lines, -0 lines 0 comments Download
M Source/platform/RuntimeEnabledFeatures.in View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 1 chunk +1 line, -0 lines 0 comments Download

Messages

Total messages: 42 (1 generated)
jkarlin
6 years, 7 months ago (2014-05-21 18:08:31 UTC) #1
jkarlin
jochen: Please review everything. Thanks!
6 years, 7 months ago (2014-05-22 17:53:50 UTC) #2
jochen (gone - plz use gerrit)
is it possible to split this change up? will there be another person that is ...
6 years, 7 months ago (2014-05-23 08:03:57 UTC) #3
jkarlin
On 2014/05/23 08:03:57, jochen wrote: > is it possible to split this change up? > ...
6 years, 7 months ago (2014-05-23 13:11:59 UTC) #4
jkarlin
On 2014/05/23 13:11:59, jkarlin wrote: > On 2014/05/23 08:03:57, jochen wrote: > > is it ...
6 years, 7 months ago (2014-05-27 18:00:19 UTC) #5
adamk
Sorry for the delay, long flight followed by long weekend. https://codereview.chromium.org/291203002/diff/190001/Source/modules/netinfo/NavigatorNetworkInfoConnection.cpp File Source/modules/netinfo/NavigatorNetworkInfoConnection.cpp (right): https://codereview.chromium.org/291203002/diff/190001/Source/modules/netinfo/NavigatorNetworkInfoConnection.cpp#newcode60 ...
6 years, 6 months ago (2014-05-27 21:44:27 UTC) #6
adamk
Oh, one more thing: some tests that test the GC would be great. You can ...
6 years, 6 months ago (2014-05-27 21:45:37 UTC) #7
jochen (gone - plz use gerrit)
https://codereview.chromium.org/291203002/diff/190001/LayoutTests/netinfo/basic-operation.html File LayoutTests/netinfo/basic-operation.html (right): https://codereview.chromium.org/291203002/diff/190001/LayoutTests/netinfo/basic-operation.html#newcode1 LayoutTests/netinfo/basic-operation.html:1: <html> <!DOCTYPE html> https://codereview.chromium.org/291203002/diff/190001/LayoutTests/netinfo/basic-operation.html#newcode22 LayoutTests/netinfo/basic-operation.html:22: internals.setNetworkConnectionInfo(newConnectionType); check for existence ...
6 years, 6 months ago (2014-05-28 11:57:03 UTC) #8
jkarlin
https://codereview.chromium.org/291203002/diff/190001/Source/modules/netinfo/NavigatorNetworkInfoConnection.cpp File Source/modules/netinfo/NavigatorNetworkInfoConnection.cpp (right): https://codereview.chromium.org/291203002/diff/190001/Source/modules/netinfo/NavigatorNetworkInfoConnection.cpp#newcode60 Source/modules/netinfo/NavigatorNetworkInfoConnection.cpp:60: visitor->trace(m_connection); On 2014/05/27 21:44:27, adamk wrote: > I think ...
6 years, 6 months ago (2014-05-28 13:31:29 UTC) #9
jkarlin
https://codereview.chromium.org/291203002/diff/190001/LayoutTests/netinfo/basic-operation.html File LayoutTests/netinfo/basic-operation.html (right): https://codereview.chromium.org/291203002/diff/190001/LayoutTests/netinfo/basic-operation.html#newcode1 LayoutTests/netinfo/basic-operation.html:1: <html> On 2014/05/28 11:57:03, jochen wrote: > <!DOCTYPE html> ...
6 years, 6 months ago (2014-05-28 15:34:00 UTC) #10
jkarlin
On 2014/05/27 21:45:37, adamk wrote: > Oh, one more thing: some tests that test the ...
6 years, 6 months ago (2014-05-28 15:34:14 UTC) #11
jkarlin
Okay, ready for review again. Not sure why the new layout tests are failing on ...
6 years, 6 months ago (2014-05-28 17:38:09 UTC) #12
adamk
lgtm But the failing tests clearly need to be figured out before landing. One thing ...
6 years, 6 months ago (2014-05-28 18:31:28 UTC) #13
jkarlin
PTAL jochen. Thanks so much! Failing tests should be fixed (forgot to upload netinfo_common.js).
6 years, 6 months ago (2014-05-28 19:04:32 UTC) #14
jkarlin
PTAL jochen. Thanks so much! Failing tests should be fixed (forgot to upload netinfo_common.js).
6 years, 6 months ago (2014-05-28 19:04:35 UTC) #15
Inactive
https://codereview.chromium.org/291203002/diff/330001/Source/modules/netinfo/NetworkInformation.cpp File Source/modules/netinfo/NetworkInformation.cpp (right): https://codereview.chromium.org/291203002/diff/330001/Source/modules/netinfo/NetworkInformation.cpp#newcode25 Source/modules/netinfo/NetworkInformation.cpp:25: return kCellular; So we keep constructing WTF Strings from ...
6 years, 6 months ago (2014-05-28 20:18:20 UTC) #16
adamk
https://codereview.chromium.org/291203002/diff/330001/Source/modules/netinfo/NetworkInformation.cpp File Source/modules/netinfo/NetworkInformation.cpp (right): https://codereview.chromium.org/291203002/diff/330001/Source/modules/netinfo/NetworkInformation.cpp#newcode72 Source/modules/netinfo/NetworkInformation.cpp:72: dispatchEvent(Event::create(EventTypeNames::typechange)); On 2014/05/28 20:18:20, Chris Dumez wrote: > The ...
6 years, 6 months ago (2014-05-28 22:44:07 UTC) #17
Inactive
https://codereview.chromium.org/291203002/diff/330001/Source/modules/netinfo/NetworkInformation.cpp File Source/modules/netinfo/NetworkInformation.cpp (right): https://codereview.chromium.org/291203002/diff/330001/Source/modules/netinfo/NetworkInformation.cpp#newcode72 Source/modules/netinfo/NetworkInformation.cpp:72: dispatchEvent(Event::create(EventTypeNames::typechange)); On 2014/05/28 22:44:08, adamk wrote: > On 2014/05/28 ...
6 years, 6 months ago (2014-05-28 22:47:28 UTC) #18
jkarlin
https://codereview.chromium.org/291203002/diff/330001/Source/modules/netinfo/NetworkInformation.cpp File Source/modules/netinfo/NetworkInformation.cpp (right): https://codereview.chromium.org/291203002/diff/330001/Source/modules/netinfo/NetworkInformation.cpp#newcode25 Source/modules/netinfo/NetworkInformation.cpp:25: return kCellular; On 2014/05/28 20:18:20, Chris Dumez wrote: > ...
6 years, 6 months ago (2014-05-29 11:37:55 UTC) #19
jkarlin
https://codereview.chromium.org/291203002/diff/330001/Source/modules/netinfo/NetworkInformation.cpp File Source/modules/netinfo/NetworkInformation.cpp (right): https://codereview.chromium.org/291203002/diff/330001/Source/modules/netinfo/NetworkInformation.cpp#newcode72 Source/modules/netinfo/NetworkInformation.cpp:72: dispatchEvent(Event::create(EventTypeNames::typechange)); On 2014/05/29 11:37:56, jkarlin wrote: > On 2014/05/28 ...
6 years, 6 months ago (2014-05-29 11:39:44 UTC) #20
jkarlin
PTAL jochen, thanks!
6 years, 6 months ago (2014-05-29 11:40:01 UTC) #21
adamk
https://codereview.chromium.org/291203002/diff/370001/Source/modules/netinfo/NetworkInformation.cpp File Source/modules/netinfo/NetworkInformation.cpp (right): https://codereview.chromium.org/291203002/diff/370001/Source/modules/netinfo/NetworkInformation.cpp#newcode17 Source/modules/netinfo/NetworkInformation.cpp:17: DEFINE_STATIC_LOCAL(const String, cellular, ("cellular")); These aren't going to play ...
6 years, 6 months ago (2014-05-29 16:57:55 UTC) #22
jkarlin
https://codereview.chromium.org/291203002/diff/370001/Source/modules/netinfo/NetworkInformation.cpp File Source/modules/netinfo/NetworkInformation.cpp (right): https://codereview.chromium.org/291203002/diff/370001/Source/modules/netinfo/NetworkInformation.cpp#newcode17 Source/modules/netinfo/NetworkInformation.cpp:17: DEFINE_STATIC_LOCAL(const String, cellular, ("cellular")); On 2014/05/29 16:57:56, adamk wrote: ...
6 years, 6 months ago (2014-05-29 17:12:56 UTC) #23
adamk
https://codereview.chromium.org/291203002/diff/370001/Source/modules/netinfo/NetworkInformation.cpp File Source/modules/netinfo/NetworkInformation.cpp (right): https://codereview.chromium.org/291203002/diff/370001/Source/modules/netinfo/NetworkInformation.cpp#newcode17 Source/modules/netinfo/NetworkInformation.cpp:17: DEFINE_STATIC_LOCAL(const String, cellular, ("cellular")); On 2014/05/29 17:12:56, jkarlin wrote: ...
6 years, 6 months ago (2014-05-29 18:07:57 UTC) #24
jkarlin
On 2014/05/29 18:07:57, adamk wrote: > https://codereview.chromium.org/291203002/diff/370001/Source/modules/netinfo/NetworkInformation.cpp > File Source/modules/netinfo/NetworkInformation.cpp (right): > > https://codereview.chromium.org/291203002/diff/370001/Source/modules/netinfo/NetworkInformation.cpp#newcode17 > ...
6 years, 6 months ago (2014-05-29 18:12:58 UTC) #25
adamk
https://codereview.chromium.org/291203002/diff/380001/Source/modules/netinfo/NetworkInformation.cpp File Source/modules/netinfo/NetworkInformation.cpp (right): https://codereview.chromium.org/291203002/diff/380001/Source/modules/netinfo/NetworkInformation.cpp#newcode20 Source/modules/netinfo/NetworkInformation.cpp:20: const char none[] = "none"; fwiw I don't think ...
6 years, 6 months ago (2014-05-30 00:13:50 UTC) #26
jkarlin
Done. PTAL. https://codereview.chromium.org/291203002/diff/380001/Source/modules/netinfo/NetworkInformation.cpp File Source/modules/netinfo/NetworkInformation.cpp (right): https://codereview.chromium.org/291203002/diff/380001/Source/modules/netinfo/NetworkInformation.cpp#newcode20 Source/modules/netinfo/NetworkInformation.cpp:20: const char none[] = "none"; On 2014/05/30 ...
6 years, 6 months ago (2014-05-30 01:51:23 UTC) #27
jkarlin
haraken: PTAL at Source/modules/
6 years, 6 months ago (2014-05-30 10:46:13 UTC) #28
haraken
https://codereview.chromium.org/291203002/diff/400001/Source/modules/netinfo/NetworkInformation.h File Source/modules/netinfo/NetworkInformation.h (right): https://codereview.chromium.org/291203002/diff/400001/Source/modules/netinfo/NetworkInformation.h#newcode19 Source/modules/netinfo/NetworkInformation.h:19: : public RefCountedWillBeGarbageCollected<NetworkInformation> This should be RefCountedWillBeRefCountedGarbageCollected. I'd be ...
6 years, 6 months ago (2014-05-30 15:42:18 UTC) #29
jkarlin
https://codereview.chromium.org/291203002/diff/400001/Source/modules/netinfo/NetworkInformation.h File Source/modules/netinfo/NetworkInformation.h (right): https://codereview.chromium.org/291203002/diff/400001/Source/modules/netinfo/NetworkInformation.h#newcode19 Source/modules/netinfo/NetworkInformation.h:19: : public RefCountedWillBeGarbageCollected<NetworkInformation> On 2014/05/30 15:42:19, haraken wrote: > ...
6 years, 6 months ago (2014-05-30 16:19:38 UTC) #30
haraken
> https://codereview.chromium.org/291203002/diff/400001/Source/modules/netinfo/NetworkInformation.h#newcode24 > Source/modules/netinfo/NetworkInformation.h:24: > DEFINE_EVENT_TARGET_REFCOUNTING(RefCountedWillBeGarbageCollected<NetworkInformation>); > On 2014/05/30 15:42:19, haraken wrote: > > > ...
6 years, 6 months ago (2014-05-30 16:28:00 UTC) #31
jkarlin
On 2014/05/30 16:28:00, haraken wrote: > > > https://codereview.chromium.org/291203002/diff/400001/Source/modules/netinfo/NetworkInformation.h#newcode24 > > Source/modules/netinfo/NetworkInformation.h:24: > > > ...
6 years, 6 months ago (2014-05-30 17:52:40 UTC) #32
adamk
still lgtm
6 years, 6 months ago (2014-05-30 20:05:42 UTC) #33
haraken
LGTM https://codereview.chromium.org/291203002/diff/460001/Source/modules/netinfo/NetworkInformation.h File Source/modules/netinfo/NetworkInformation.h (right): https://codereview.chromium.org/291203002/diff/460001/Source/modules/netinfo/NetworkInformation.h#newcode44 Source/modules/netinfo/NetworkInformation.h:44: virtual void stop() OVERRIDE; Just to confirm: You ...
6 years, 6 months ago (2014-05-31 08:47:15 UTC) #34
jkarlin
https://codereview.chromium.org/291203002/diff/460001/Source/modules/netinfo/NetworkInformation.h File Source/modules/netinfo/NetworkInformation.h (right): https://codereview.chromium.org/291203002/diff/460001/Source/modules/netinfo/NetworkInformation.h#newcode44 Source/modules/netinfo/NetworkInformation.h:44: virtual void stop() OVERRIDE; On 2014/05/31 08:47:16, haraken wrote: ...
6 years, 6 months ago (2014-05-31 11:12:10 UTC) #35
jkarlin
6 years, 6 months ago (2014-05-31 11:12:12 UTC) #36
haraken
still LGTM https://codereview.chromium.org/291203002/diff/460001/Source/modules/netinfo/NetworkInformation.h File Source/modules/netinfo/NetworkInformation.h (right): https://codereview.chromium.org/291203002/diff/460001/Source/modules/netinfo/NetworkInformation.h#newcode44 Source/modules/netinfo/NetworkInformation.h:44: virtual void stop() OVERRIDE; On 2014/05/31 11:12:11, ...
6 years, 6 months ago (2014-05-31 13:09:09 UTC) #37
jkarlin
The CQ bit was checked by jkarlin@chromium.org
6 years, 6 months ago (2014-05-31 13:15:10 UTC) #38
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/jkarlin@chromium.org/291203002/480001
6 years, 6 months ago (2014-05-31 13:15:20 UTC) #39
commit-bot: I haz the power
Change committed as 175200
6 years, 6 months ago (2014-05-31 20:20:56 UTC) #40
aa979586
6 years, 2 months ago (2014-09-28 22:59:49 UTC) #42
Message was sent while issue was closed.
lgtm

Powered by Google App Engine
This is Rietveld 408576698