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

Unified Diff: samples/slider/slider_sample.dart

Issue 11142015: update hello, world sample and remove slider (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: after merge with master Created 8 years, 2 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/slider/slider_sample.css ('k') | samples/slider/slider_sample.html » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: samples/slider/slider_sample.dart
diff --git a/samples/slider/slider_sample.dart b/samples/slider/slider_sample.dart
deleted file mode 100644
index 355528764bb6f5e64d6c1bf4cb84af1fa4193993..0000000000000000000000000000000000000000
--- a/samples/slider/slider_sample.dart
+++ /dev/null
@@ -1,42 +0,0 @@
-// Copyright (c) 2012, the Dart 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.
-
-library slider_sample;
-
-import 'dart:html';
-import '../ui_lib/view/view.dart';
-
-const menuItems = const["Apple", "Banana", "Cherry", "Durian"];
-
-main() {
- var sliderMenu = new SliderMenu(menuItems, (selectedText) {
- displaySelection(selectedText);
- });
- query("#menu").nodes.add(sliderMenu.node);
-
- query('#next').on.click.add((e) {
- sliderMenu.selectNext(true);
- });
-
- query('#prev').on.click.add((e) {
- sliderMenu.selectPrevious(true);
- });
-
- document.on.keyDown.add((KeyboardEvent event) {
- switch (event.keyIdentifier) {
- case KeyName.LEFT:
- sliderMenu.selectPrevious(true);
- break;
- case KeyName.RIGHT:
- sliderMenu.selectNext(true);
- break;
- }
- });
-
- sliderMenu.enterDocument();
-}
-
-void displaySelection(String selectedText) {
- query("#notes").text = "Selection: ${selectedText}";
-}
« no previous file with comments | « samples/slider/slider_sample.css ('k') | samples/slider/slider_sample.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698