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

Unified Diff: samples/github/lib/src/commit_list_presenter.dart

Issue 2035023003: Remove service-compiler related code. (Closed) Base URL: git@github.com:dartino/sdk.git@master
Patch Set: Created 4 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « samples/github/lib/github.immi ('k') | samples/github/lib/src/commit_presenter.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: samples/github/lib/src/commit_list_presenter.dart
diff --git a/samples/github/lib/src/commit_list_presenter.dart b/samples/github/lib/src/commit_list_presenter.dart
deleted file mode 100644
index 4c7d2407e5a786bdf187a47e312d2332d5ca221e..0000000000000000000000000000000000000000
--- a/samples/github/lib/src/commit_list_presenter.dart
+++ /dev/null
@@ -1,46 +0,0 @@
-// Copyright (c) 2015, the Dartino project authors. Please see the AUTHORS file
-// for details. All rights reserved. Use of this source code is governed by a
-// BSD-style license that can be found in the LICENSE file.
-
-import 'github_services.dart';
-import 'commit_presenter.dart';
-
-import 'package:immi/dart/immi.dart';
-import 'package:immi_samples/sliding_window.dart';
-
-class CommitListPresenter {
- Repository _repository;
- SlidingWindow _presenter;
-
- CommitListPresenter(this._repository) {
- var commitPresenter = new CommitPresenter(_repository);
- _presenter = new SlidingWindow(commitPresenter);
- }
-
- // TODO(zerny): We should represent methods on nodes in a class structure and
- // support identity-preserving composition.
- Function _displayCache = null;
- Function _wrappedDisplayCache = null;
- Function _wrapDisplayForPrefetching(Function display) {
- if (display != _displayCache) {
- _displayCache = display;
- _wrappedDisplayCache = (int start, int end) {
- _repository.prefetchCommitsInRange(start, end);
- (display)(start, end);
- };
- }
- return _wrappedDisplayCache;
- }
-
- SlidingWindowNode present(Node previous) {
- SlidingWindowNode window = _presenter.present();
- return new SlidingWindowNode(
- window: window.window,
- startOffset: window.startOffset,
- windowOffset: window.windowOffset,
- minimumCount: window.minimumCount,
- maximumCount: window.maximumCount,
- toggle: window.toggle,
- display: _wrapDisplayForPrefetching(window.display));
- }
-}
« no previous file with comments | « samples/github/lib/github.immi ('k') | samples/github/lib/src/commit_presenter.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698