diff options
author | Andrzej Rybczak <electricityispower@gmail.com> | 2009-07-04 06:41:35 +0200 |
---|---|---|
committer | Andrzej Rybczak <electricityispower@gmail.com> | 2009-07-04 06:41:35 +0200 |
commit | 9dab25e02c909196fd043f77f278ea0c032d23aa (patch) | |
tree | 08fd11e9e426c607f67e7090cbe6f4dbcc6af1ae /src/clock.cpp | |
parent | 2eb913fe22b3ef26004f085f60a8d9ab8aa75d6e (diff) |
use prefix ++ instead of postfix where available
Diffstat (limited to 'src/clock.cpp')
-rw-r--r-- | src/clock.cpp | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/clock.cpp b/src/clock.cpp index ed68685a..a48bac1d 100644 --- a/src/clock.cpp +++ b/src/clock.cpp @@ -127,20 +127,20 @@ void Clock::Update() attroff(COLOR_PAIR(Config.main_color)); refresh(); - for (int k = 0; k < 6; k++) + for (int k = 0; k < 6; ++k) { newer[k] = (newer[k] & ~mask) | (next[k] & mask); next[k] = 0; - for (int s = 1; s >= 0; s--) + for (int s = 1; s >= 0; --s) { w->Reverse(s); - for (int i = 0; i < 6; i++) + for (int i = 0; i < 6; ++i) { long a = (newer[i] ^ older[i]) & (s ? newer : older)[i]; if (a != 0) { long t = 1 << 26; - for (int j = 0; t; t >>= 1, j++) + for (int j = 0; t; t >>= 1, ++j) { if (a & t) { @@ -164,14 +164,14 @@ void Clock::Update() void Clock::Prepare() { - for (int i = 0; i < 5; i++) + for (int i = 0; i < 5; ++i) older[i] = newer[i] = next[i] = 0; } void Clock::Set(int t, int n) { int m = 7 << n; - for (int i = 0; i < 5; i++) + for (int i = 0; i < 5; ++i) { next[i] |= ((disp[t] >> ((4 - i) * 3)) & 07) << n; mask |= (next[i] ^ older[i]) & m; |