diff --git a/src/kits/tracker/Pose.cpp b/src/kits/tracker/Pose.cpp index b754756230..149b685bb5 100644 --- a/src/kits/tracker/Pose.cpp +++ b/src/kits/tracker/Pose.cpp @@ -427,11 +427,18 @@ BPose::EditPreviousNextWidgetCommon(BPoseView* poseView, bool next) for (int32 index = next ? 0 : poseView->CountColumns() - 1; ; index += delta) { BColumn* column = poseView->ColumnAt(index); - if (column == NULL) + if (column == NULL) { + // out of columns break; + } BTextWidget* widget = WidgetFor(column->AttrHash()); - if (widget != NULL && widget->IsActive()) { + if (widget == NULL) { + // no widget for this column, next + continue; + } + + if (widget->IsActive()) { poseView->CommitActivePose(); found = true; continue;