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

Unified Diff: runtime/observatory/lib/utils.dart

Issue 928833003: Add Function based profile tree (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 5 years, 10 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/observatory/lib/src/service/object.dart ('k') | runtime/observatory/observatory.gypi » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/observatory/lib/utils.dart
diff --git a/runtime/observatory/lib/src/app/utils.dart b/runtime/observatory/lib/utils.dart
similarity index 95%
rename from runtime/observatory/lib/src/app/utils.dart
rename to runtime/observatory/lib/utils.dart
index eff1a17ca447388ce71eb0a79cf1e036bba20e49..58d18aaf1563870b7f7396d7f1b88df18f6e9aaa 100644
--- a/runtime/observatory/lib/src/app/utils.dart
+++ b/runtime/observatory/lib/utils.dart
@@ -2,12 +2,14 @@
// 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.
-part of app;
+library utils;
+
+import 'dart:math';
class Utils {
static String formatPercent(num a, num total) {
- var percent = 100.0 * (a / total);
- return '${percent.toStringAsFixed(2)}%';
+ var percent = 100.0 * (a / total);
+ return '${percent.toStringAsFixed(2)}%';
}
static String zeroPad(int value, int pad) {
@@ -110,7 +112,6 @@ class Utils {
var seconds = millis ~/ millisPerSecond;
- StringBuffer out = new StringBuffer();
if (hours != 0) {
return '${hours}h ${minutes}m ${seconds}s';
}
« no previous file with comments | « runtime/observatory/lib/src/service/object.dart ('k') | runtime/observatory/observatory.gypi » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698