{
int dx = x - x_org;
int dy = y - y_org;
+ int tmp;
+
+ switch (cover->angle) {
+ case 90:
+ tmp = dx;
+ dx = -dy;
+ dy = tmp;
+ break;
+ case 270:
+ tmp = dx;
+ dx = dy;
+ dy = -tmp;
+ break;
+ }
if ((dy < 0) && (abs(dx) < -dy))
return FLICK_DIRECTION_UP;
return;
}
}
- int dxx = ev->root.x - cov->flick_gesture.x_org[i];
- int dyy = ev->root.y - cov->flick_gesture.y_org[i];
+ int dx = ev->root.x - cov->flick_gesture.x_org[i];
+ int dy = ev->root.y - cov->flick_gesture.y_org[i];
+ int tmp;
+ switch (cov->angle) {
+ case 90:
+ tmp = dx;
+ dx = -dy;
+ dy = tmp;
+ break;
+ case 270:
+ tmp = dx;
+ dx = dy;
+ dy = -tmp;
+ break;
+ }
if (i == 1 && cov->n_taps == 2) {
- if ((cov->flick_gesture.flick_to_scroll || _flick_to_scroll_gesture_conditions_met(ev, cov->flick_gesture.timestamp[i], dxx, dyy)) && scrolling) {
+ if ((cov->flick_gesture.flick_to_scroll || _flick_to_scroll_gesture_conditions_met(ev, cov->flick_gesture.timestamp[i], dx, dy)) && scrolling) {
if (!cov->flick_gesture.flick_to_scroll) {
start_scroll(ev->x, ev->y, cov);
cov->flick_gesture.flick_to_scroll = EINA_TRUE;
return;
}
}
- if(!cov->flick_gesture.finger_out[i])
- {
- int dx = ev->root.x - cov->flick_gesture.x_org[i];
- int dy = ev->root.y - cov->flick_gesture.y_org[i];
-
- if (dx < 0) dx *= -1;
+ if (!cov->flick_gesture.finger_out[i])
+ {
+ if (dx < 0) dx *= -1;
if (dy < 0) dy *= -1;
if (dx > _e_mod_config->one_finger_flick_min_length)