Skip to content

Commit

Permalink
refactor(platform-browser): cleanup references to dart (#49858)
Browse files Browse the repository at this point in the history
The repo doesn't support dart anymore, we can reduce the references to it .

PR Close #49858
  • Loading branch information
JeanMeche authored and thePunderWoman committed Apr 18, 2023
1 parent ff0d23d commit 1816c89
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 10 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -12,12 +12,6 @@ if (isBrowser) {
describe('ResourceLoaderImpl', () => {
let resourceLoader: ResourceLoaderImpl;

// TODO(juliemr): This file currently won't work with dart unit tests run using
// exclusive it or describe (iit or ddescribe). This is because when
// pub run test is executed against this specific file the relative paths
// will be relative to here, so url200 should look like
// static_assets/200.html.
// We currently have no way of detecting this.
const url200 = '/base/angular/packages/platform-browser/test/browser/static_assets/200.html';
const url404 = '/bad/path/404.html';

Expand Down
6 changes: 2 additions & 4 deletions packages/platform-browser/src/browser/browser_adapter.ts
Original file line number Diff line number Diff line change
Expand Up @@ -23,11 +23,9 @@ export class BrowserDomAdapter extends GenericBrowserDomAdapter {
}

override onAndCancel(el: Node, evt: any, listener: any): Function {
el.addEventListener(evt, listener, false);
// Needed to follow Dart's subscription semantic, until fix of
// https://code.google.com/p/dart/issues/detail?id=17406
el.addEventListener(evt, listener);
return () => {
el.removeEventListener(evt, listener, false);
el.removeEventListener(evt, listener);
};
}
override dispatchEvent(el: Node, evt: any) {
Expand Down

0 comments on commit 1816c89

Please sign in to comment.