diff options
author | Roland Bär <roland@verifysoft.de> | 2008-04-02 15:30:32 +0200 |
---|---|---|
committer | Danny Baumann <dannybaumann@web.de> | 2008-04-02 15:49:44 +0200 |
commit | ff891dfa4156ffa8ee0e8606bd8528c3e136db85 (patch) | |
tree | 0f184ecb60b5e4896c3c2104dfcd093dc79366ce | |
parent | 45a0e306e741db3e2b20be7025c33311b573b745 (diff) | |
download | screensaver-ff891dfa4156ffa8ee0e8606bd8528c3e136db85.tar.gz screensaver-ff891dfa4156ffa8ee0e8606bd8528c3e136db85.tar.bz2 |
Fixed forgotten initialisation of member variables in constructors
-rw-r--r-- | effect.h | 2 | ||||
-rw-r--r-- | flyingwindows.cpp | 2 | ||||
-rw-r--r-- | matrix.h | 8 | ||||
-rw-r--r-- | vector.h | 7 |
4 files changed, 15 insertions, 4 deletions
@@ -16,7 +16,7 @@ public: class ScreenEffect : public ScreenWrapper { public: - ScreenEffect( CompScreen* s ) : ScreenWrapper(s) {} + ScreenEffect( CompScreen* s ) : ScreenWrapper(s), progress(0) {} virtual ~ScreenEffect() {} float getProgress() { return progress; } diff --git a/flyingwindows.cpp b/flyingwindows.cpp index 4189014..42c53b8 100644 --- a/flyingwindows.cpp +++ b/flyingwindows.cpp @@ -273,6 +273,8 @@ WindowFlyingWindows::WindowFlyingWindows( CompWindow* w ) : WindowEffect(w), active( FALSE ), opacity( w->paint.opacity ), + opacityFadeOut( 0 ), + opacityOld( 0 ), steps(0) { @@ -10,8 +10,12 @@ class Matrix public: static const Matrix identity; - Matrix() {} - + Matrix() { + for (int i=0; i<16;i++) { + m[i] = 0; + } + } + Matrix( const CompTransform* mat ) { memcpy( m, mat->m, sizeof(m) ); } Matrix( const Matrix& mat ) { memcpy( m, mat.m, sizeof(m) ); } Matrix( const float* mat ) { memcpy( m, mat, sizeof(m) ); } @@ -16,7 +16,12 @@ class Vector public: static const Vector null; - Vector() {} + Vector() + { + for(int i = 0; i<3; i++) { + v[i] = 0; + } + } Vector( float x, float y, float z ) { v[0] = x; v[1] = y; v[2] = z; } Vector( const float* vect ) { v[0] = vect[0]; v[1] = vect[1]; v[2] = vect[2]; } Vector( const Vector& vect ) { v[0] = vect[0]; v[1] = vect[1]; v[2] = vect[2]; } |