Mercurial > audlegacy
comparison src/audacious/ui_skinned_textbox.c @ 2917:e968134f11ed trunk
fix dragging textbox
author | Tomasz Mon <desowin@gmail.com> |
---|---|
date | Fri, 29 Jun 2007 10:16:01 +0200 |
parents | 3ef909ed3056 |
children | 4e71092ab29b |
comparison
equal
deleted
inserted
replaced
2916:3ef909ed3056 | 2917:e968134f11ed |
---|---|
345 if (priv->scroll_allowed && | 345 if (priv->scroll_allowed && |
346 priv->pixmap_width > priv->w) { | 346 priv->pixmap_width > priv->w) { |
347 priv->offset = priv->drag_off - (event->x - priv->drag_x); | 347 priv->offset = priv->drag_off - (event->x - priv->drag_x); |
348 | 348 |
349 while (priv->offset < 0) | 349 while (priv->offset < 0) |
350 priv->offset += priv->pixmap_width; | 350 priv->offset = 0; |
351 | 351 |
352 while (priv->offset > (priv->pixmap_width - priv->w)) | 352 while (priv->offset > (priv->pixmap_width - priv->w)) |
353 priv->offset -= priv->pixmap_width; | 353 priv->offset = (priv->pixmap_width - priv->w); |
354 | 354 |
355 ui_skinned_textbox_redraw(textbox); | 355 ui_skinned_textbox_redraw(textbox); |
356 } | 356 } |
357 } | 357 } |
358 | 358 |