Diffstat (limited to 'core/applets/rotateapplet/rotate.cpp') (more/less context) (show whitespace changes)
-rw-r--r-- | core/applets/rotateapplet/rotate.cpp | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/core/applets/rotateapplet/rotate.cpp b/core/applets/rotateapplet/rotate.cpp index 0ead016..b490626 100644 --- a/core/applets/rotateapplet/rotate.cpp +++ b/core/applets/rotateapplet/rotate.cpp @@ -99,3 +99,3 @@ void RotateApplet::activated ( ) // 0 -> 90° clockwise, 1 -> 90° counterclockwise - bool rotDirection = cfg.readBoolEntry( "rotatedir", 0 ); + int rotDirection = cfg.readNumEntry( "rotatedir", 0 ); @@ -109,6 +109,8 @@ void RotateApplet::activated ( ) } else { - if ( rotDirection ) { + if ( rotDirection == 1 ) { newRotation = ( defaultRotation + 90 ) % 360; - } else { + } else if ( rotDirection == 0 ) { newRotation = ( defaultRotation + 270 ) % 360; + } else { + newRotation = ( defaultRotation + 180 ) % 360; } |