Skip to content

Commit

Permalink
Brand new implementation of HostController.start.
Browse files Browse the repository at this point in the history
The new implementation differs from the old on the following ways:

- Has a promise-based API.
- Based on promises thoughout.
- Reads from top to bottom.
- Lots of comments.
- Data flow is (once again) completely explicit.
- Runs async operations in parallel when possible.  Order of operations
  was overspecified in the previous version.
- Miraculously still passes unit tests.

BUG=471928

Review URL: https://codereview.chromium.org/1081603002

Cr-Commit-Position: refs/heads/master@{#324972}
  • Loading branch information
jrw authored and Commit bot committed Apr 14, 2015
1 parent 942079d commit c777502
Show file tree
Hide file tree
Showing 5 changed files with 321 additions and 436 deletions.
3 changes: 2 additions & 1 deletion remoting/webapp/crd/js/crd_main.js
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,8 @@ remoting.updateLocalHostState = function() {
};

remoting.hostController.hasFeature(
remoting.HostController.Feature.PAIRING_REGISTRY, onHasFeatureResponse);
remoting.HostController.Feature.PAIRING_REGISTRY).
then(onHasFeatureResponse);
remoting.hostController.getLocalHostState(onHostState);
};

Expand Down
Loading

0 comments on commit c777502

Please sign in to comment.