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

Unified Diff: runtime/bin/directory_impl.dart

Issue 10639004: Add .fromPath constructors to File and Directory. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Address comments. Created 8 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 | « runtime/bin/directory.dart ('k') | runtime/bin/file.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/bin/directory_impl.dart
diff --git a/runtime/bin/directory_impl.dart b/runtime/bin/directory_impl.dart
index a2b804ba7df6062b69d64295624540f52b5d5b6c..a998752173e95f2afe4646da25fa709e1291ea89 100644
--- a/runtime/bin/directory_impl.dart
+++ b/runtime/bin/directory_impl.dart
@@ -16,7 +16,8 @@ class _Directory implements Directory {
static final OSERROR_RESPONSE = 2;
_Directory(String this._path);
- _Directory.current() : _path = _current();
+ _Directory.fromPath(Path path) : this(path.toNativePath());
+ _Directory.current() : this(_current());
static String _current() native "Directory_Current";
static _createTemp(String template) native "Directory_CreateTemp";
« no previous file with comments | « runtime/bin/directory.dart ('k') | runtime/bin/file.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698