Problem with a function

For some reason this keeps moving my thumbnail_mc even when thumbnail_mc is well away from brake_right and hit_right. When I move the mouse back and forth onto and off one of the thumbnails it sorta hops to the left ten pixels every time I hover over it again. Please help me figure this out! If you need the .fla just let me know and I’ll upload it somewhere.

function thumbNailScroller(total) {
// thumbnail code!
this.createEmptyMovieClip(“tscroller”, 1000);
scroll_speed = 10;
brakeSpeed = 10;
tscroller.onEnterFrame = function() {
if (hit_right.hitTest(this._xmouse, this._ymouse) && thumbnail_mc.hitTest(brake_right)) {
thumbnail_mc._x -= scroll_speed;
} else {
thumbnail_mc._x -= brakeSpeed;
brakeSpeed = brakeSpeed-1;
if (brakeSpeed=0) {
delete tscroller.onEnterFrame;
}
}
if (hit_left.hitTest(this._xmouse, this._ymouse) && thumbnail_mc.hitTest(brake_left)) {
thumbnail_mc._x += scroll_speed;
} else {
thumbnail_mc._x += brakeSpeed;
brakeSpeed = brakeSpeed-2;
if (brakeSpeed=0) {
delete tscroller.onEnterFrame;
}
}
};
}