1
0
mirror of https://github.com/cookiengineer/audacity synced 2025-11-14 17:14:07 +01:00

AdornedRulerPanel updates its play region in idle time...

... Eliminating TP_DisplaySelection and making ProjectWindow independent of
AdornedRulerPanel
This commit is contained in:
Paul Licameli
2019-07-03 23:35:20 -04:00
parent 1c1aca521d
commit eb4eba6325
17 changed files with 28 additions and 85 deletions

View File

@@ -195,7 +195,7 @@ UIHandle::Result LabelTextHandle::Click
if (!unsafe)
ProjectHistory::Get( *pProject ).ModifyState(false);
return result | RefreshCode::RefreshCell | RefreshCode::UpdateSelection;
return result | RefreshCode::RefreshCell;
}
void LabelTextHandle::HandleTextDragRelease(

View File

@@ -178,7 +178,7 @@ UIHandle::Result StretchHandle::Click
// newly selected tracks. (I'm really not sure if the label area
// needs to be refreshed or how to just refresh non-label areas.-RBD)
return RefreshAll | UpdateSelection;
return RefreshAll;
}
UIHandle::Result StretchHandle::Drag

View File

@@ -162,7 +162,6 @@ UIHandle::Result CutlineHandle::Click
}
viewInfo.selectedRegion.setTimes(cutlineStart, cutlineEnd);
result |= UpdateSelection;
}
else if (mLocation.typ == WaveTrackLocation::locationMergePoint) {
const double pos = mLocation.pos;
@@ -230,7 +229,6 @@ UIHandle::Result CutlineHandle::Release
case Expand:
ProjectHistory::Get( *pProject )
.PushState(_("Expanded Cut Line"), _("Expand"));
result |= RefreshCode::UpdateSelection;
break;
case Remove:
ProjectHistory::Get( *pProject )
@@ -251,7 +249,6 @@ UIHandle::Result CutlineHandle::Cancel(AudacityProject *pProject)
AudacityProject &project = *pProject;
auto &selectedRegion = ViewInfo::Get( project ).selectedRegion;
selectedRegion.setTimes( mStartTime, mEndTime );
result |= UpdateSelection;
}
return result;
}

View File

@@ -181,9 +181,6 @@ void PlayIndicatorOverlay::OnTimer(wxCommandEvent &event)
playPos,
viewInfo.GetScreenEndTime() + tolerance);
// This displays the audio time, too...
window.TP_DisplaySelection();
auto gAudioIO = AudioIO::Get();
// BG: Scroll screen if option is set

View File

@@ -500,7 +500,6 @@ void SelectHandle::SetUseSnap(bool use)
ViewInfo::Get( *::GetActiveProject() ),
mUseSnap ? mSnapEnd.outTime : mSnapEnd.timeSnappedTime,
nullptr);
mChangeHighlight |= RefreshCode::UpdateSelection;
}
}
@@ -585,7 +584,7 @@ UIHandle::Result SelectHandle::Click
ProjectHistory::Get( *pProject ).ModifyState(false);
// Do not start a drag
return RefreshAll | UpdateSelection | Cancelled;
return RefreshAll | Cancelled;
}
else if (!event.LeftDown())
return Cancelled;
@@ -674,7 +673,7 @@ UIHandle::Result SelectHandle::Click
// Full refresh since the label area may need to indicate
// newly selected tracks.
return RefreshAll | UpdateSelection;
return RefreshAll;
}
// II. Unmodified click starts a NEW selection
@@ -707,7 +706,7 @@ UIHandle::Result SelectHandle::Click
// For persistence of the selection change:
ProjectHistory::Get( *pProject ).ModifyState(false);
mSelectionBoundary = SBWidth;
return UpdateSelection;
return RefreshNone;
}
else
#endif
@@ -779,7 +778,7 @@ UIHandle::Result SelectHandle::Click
});
Connect(pProject);
return RefreshAll | UpdateSelection;
return RefreshAll;
}
else {
Connect(pProject);