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

Side by Side Diff: third_party/WebKit/Source/wtf/CurrentTime.cpp

Issue 1436153002: Apply clang-format with Chromium-style without column limit. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 1 month 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 unified diff | Download patch
« no previous file with comments | « third_party/WebKit/Source/wtf/CurrentTime.h ('k') | third_party/WebKit/Source/wtf/DataLog.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2009 Google Inc. All rights reserved. 2 * Copyright (C) 2009 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 19 matching lines...) Expand all
30 30
31 #include "config.h" 31 #include "config.h"
32 #include "wtf/CurrentTime.h" 32 #include "wtf/CurrentTime.h"
33 33
34 namespace WTF { 34 namespace WTF {
35 35
36 static TimeFunction currentTimeFunction; 36 static TimeFunction currentTimeFunction;
37 static TimeFunction monotonicallyIncreasingTimeFunction; 37 static TimeFunction monotonicallyIncreasingTimeFunction;
38 static TimeFunction systemTraceTimeFunction; 38 static TimeFunction systemTraceTimeFunction;
39 39
40 void setCurrentTimeFunction(TimeFunction func) 40 void setCurrentTimeFunction(TimeFunction func) {
41 { 41 currentTimeFunction = func;
42 currentTimeFunction = func;
43 } 42 }
44 43
45 void setMonotonicallyIncreasingTimeFunction(TimeFunction func) 44 void setMonotonicallyIncreasingTimeFunction(TimeFunction func) {
46 { 45 monotonicallyIncreasingTimeFunction = func;
47 monotonicallyIncreasingTimeFunction = func;
48 } 46 }
49 47
50 void setSystemTraceTimeFunction(TimeFunction func) 48 void setSystemTraceTimeFunction(TimeFunction func) {
51 { 49 systemTraceTimeFunction = func;
52 systemTraceTimeFunction = func;
53 } 50 }
54 51
55 double currentTime() 52 double currentTime() {
56 { 53 return (*currentTimeFunction)();
57 return (*currentTimeFunction)();
58 } 54 }
59 55
60 double monotonicallyIncreasingTime() 56 double monotonicallyIncreasingTime() {
61 { 57 return (*monotonicallyIncreasingTimeFunction)();
62 return (*monotonicallyIncreasingTimeFunction)();
63 } 58 }
64 59
65 double systemTraceTime() 60 double systemTraceTime() {
66 { 61 return (*systemTraceTimeFunction)();
67 return (*systemTraceTimeFunction)();
68 } 62 }
69 63
70 } // namespace WTF 64 } // namespace WTF
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/wtf/CurrentTime.h ('k') | third_party/WebKit/Source/wtf/DataLog.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698