aboutsummaryrefslogtreecommitdiffstats
path: root/Source/SPStringAdditions.m
diff options
context:
space:
mode:
authorrowanbeentje <rowan@beent.je>2009-04-09 21:11:17 +0000
committerrowanbeentje <rowan@beent.je>2009-04-09 21:11:17 +0000
commit1ed9e77dff7bd74b04d6dc35849b6b644f11e2d5 (patch)
treecfe1edddd94e3943c2512e7fead813cae61827b5 /Source/SPStringAdditions.m
parentddc5add77f3984cae1601e96d564cf4ba7347202 (diff)
downloadsequelpro-1ed9e77dff7bd74b04d6dc35849b6b644f11e2d5.tar.gz
sequelpro-1ed9e77dff7bd74b04d6dc35849b6b644f11e2d5.tar.bz2
sequelpro-1ed9e77dff7bd74b04d6dc35849b6b644f11e2d5.zip
- Improve time interval granularity for times below 10 seconds (show two decimal places instead of one)
Diffstat (limited to 'Source/SPStringAdditions.m')
-rw-r--r--Source/SPStringAdditions.m6
1 files changed, 6 insertions, 0 deletions
diff --git a/Source/SPStringAdditions.m b/Source/SPStringAdditions.m
index 2c719f6c..e0bf65cf 100644
--- a/Source/SPStringAdditions.m
+++ b/Source/SPStringAdditions.m
@@ -83,6 +83,12 @@
return [numberFormatter stringFromNumber:[NSNumber numberWithFloat:timeInterval]];
}
+ if (timeInterval < 10) {
+ [numberFormatter setFormat:@"#,##0.00 s"];
+
+ return [numberFormatter stringFromNumber:[NSNumber numberWithFloat:timeInterval]];
+ }
+
if (timeInterval < 100) {
[numberFormatter setFormat:@"#,##0.0 s"];