[Kst] extragear/graphics/kst/kst
Rick Chern
rchern at interchange.ubc.ca
Sat Aug 6 20:53:21 CEST 2005
SVN commit 443612 by rchern:
Fix line hotpoint dragging
M +5 -5 ksttoplevelview.cpp
--- trunk/extragear/graphics/kst/kst/ksttoplevelview.cpp #443611:443612
@@ -700,16 +700,16 @@
// for now we only know how to deal with lines
if (KstViewLinePtr line = kst_cast<KstViewLine>(_pressTarget)) {
QPoint fromPoint, toPoint;
- if (_prevBand.topLeft() == QPoint(-1,-1)) {
+ if (_prevBand.topLeft()== QPoint(-1,-1)) {
// use _prevBand to save original line position
_prevBand.setTopLeft(line->from());
_prevBand.setBottomRight(line->to());
}
- if (_pressDirection & UP == UP) {
+ if ((_pressDirection & UP) == UP) {
// UP means we are on the start endpoint
toPoint = _prevBand.bottomRight();
fromPoint = pos;
- } else if (_pressDirection & DOWN == DOWN) {
+ } else if ((_pressDirection & DOWN) == DOWN) {
// DOWN means we are on the end endpoint
fromPoint = _prevBand.topLeft();
toPoint = pos;
@@ -813,10 +813,10 @@
if (_pressDirection == 0) {
// we are moving object(s)
releasePressLayoutModeMove(pos, shift);
- } else if (_pressDirection & ENDPOINT == ENDPOINT) {
+ } else if ((_pressDirection & ENDPOINT) == ENDPOINT) {
// moving an endpoint of an object
releasePressLayoutModeEndPoint(pos, shift);
- } else if (_pressDirection & CENTREDRESIZE == CENTREDRESIZE) {
+ } else if ((_pressDirection & CENTREDRESIZE) == CENTREDRESIZE) {
// resizing an object whose centre is fixed
releasePressLayoutModeCentredResize(pos, shift);
} else {
More information about the Kst
mailing list