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

Unified Diff: pkg/intl/example/basic/messages_de.dart

Issue 12733003: Adds facilities for extracting Intl.message calls and generating code from translations (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Fixes from review comments, also made tests more robust, removed scheduled_test dependency Created 7 years, 9 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
Index: pkg/intl/example/basic/messages_de.dart
diff --git a/pkg/intl/example/basic/messages_de.dart b/pkg/intl/example/basic/messages_de.dart
index 07e83319ceede0d082d5b8c8034f0bff8b56c23e..d18c98113972cc84dd97e6ed10c3441b512905fa 100644
--- a/pkg/intl/example/basic/messages_de.dart
+++ b/pkg/intl/example/basic/messages_de.dart
@@ -5,12 +5,20 @@
/**
* This is a library that provides messages for a German locale. All the
* messages from the main program should be duplicated here with the same
- * function name. Note that the library name is significant, as it's looked
- * up based on a naming convention.
+ * function name.
*/
-
library messages_de;
-import '../../lib/intl.dart';
+import 'package:intl/intl.dart';
+import 'package:intl/message_lookup_by_library.dart';
+
+final messages = new MessageLookup();
+
+class MessageLookup extends MessageLookupByLibrary {
+
+ get localeName => 'de';
+
+ final messages = {
+ "runAt" : (time, day) => Intl.message("Ausgedruckt am $time am $day.")
+ };
+}
-runAt(time, day) => Intl.message('Ausgedruckt am $time am $day.', name: 'runAt',
- args: [time, day]);

Powered by Google App Engine
This is Rietveld 408576698