mirror of
https://github.com/cookiengineer/audacity
synced 2025-08-16 08:34:10 +02:00
Move mAdjustSelectionEdges from TrackPanel to ViewInfo
This commit is contained in:
parent
c300c33901
commit
65c7beff99
@ -748,8 +748,6 @@ void TrackPanel::UpdatePrefs()
|
||||
{
|
||||
gPrefs->Read(wxT("/GUI/AutoScroll"), &mViewInfo->bUpdateTrackIndicator,
|
||||
true);
|
||||
gPrefs->Read(wxT("/GUI/AdjustSelectionEdges"), &mAdjustSelectionEdges,
|
||||
true);
|
||||
gPrefs->Read(wxT("/GUI/CircularTrackNavigation"), &mCircularTrackNavigation,
|
||||
false);
|
||||
gPrefs->Read(wxT("/GUI/Solo"), &mSoloPref, wxT("Simple"));
|
||||
@ -1587,7 +1585,7 @@ void TrackPanel::SetCursorAndTipWhenSelectTool( Track * t,
|
||||
//Make sure we are within the selected track
|
||||
// Adjusting the selection edges can be turned off in
|
||||
// the preferences...
|
||||
if ( !t->GetSelected() || !mAdjustSelectionEdges)
|
||||
if ( !t->GetSelected() || !mViewInfo->bAdjustSelectionEdges)
|
||||
{
|
||||
MaySetOnDemandTip( t, tip );
|
||||
return;
|
||||
@ -2191,7 +2189,7 @@ void TrackPanel::SelectionHandleClick(wxMouseEvent & event,
|
||||
if (pTrack && pTrack->GetSelected()) {
|
||||
// Adjusting selection edges can be turned off in the
|
||||
// preferences now
|
||||
if (mAdjustSelectionEdges) {
|
||||
if (mViewInfo->bAdjustSelectionEdges) {
|
||||
#ifdef EXPERIMENTAL_SPECTRAL_EDITING
|
||||
if (mFreqSelMode == FREQ_SEL_SNAPPING_CENTER &&
|
||||
isSpectralSelectionTrack(pTrack)) {
|
||||
@ -2256,7 +2254,7 @@ void TrackPanel::SelectionHandleClick(wxMouseEvent & event,
|
||||
wxASSERT(false);
|
||||
}
|
||||
}
|
||||
} // mAdjustSelectionEdges
|
||||
} // mViewInfo->bAdjustSelectionEdges
|
||||
}
|
||||
|
||||
#ifdef USE_MIDI
|
||||
|
@ -808,7 +808,6 @@ protected:
|
||||
enum MouseCaptureEnum mMouseCapture;
|
||||
virtual void SetCapturedTrack( Track * t, enum MouseCaptureEnum MouseCapture=IsUncaptured );
|
||||
|
||||
bool mAdjustSelectionEdges;
|
||||
bool mSlideUpDownOnly;
|
||||
bool mCircularTrackNavigation;
|
||||
|
||||
|
@ -151,7 +151,8 @@ void ViewInfo::UpdatePrefs()
|
||||
gPrefs->Read(TracksBehaviorsPrefs::ScrollingPreferenceKey(), &bScrollBeyondZero,
|
||||
TracksBehaviorsPrefs::ScrollingPreferenceDefault());
|
||||
#endif
|
||||
|
||||
gPrefs->Read(wxT("/GUI/AdjustSelectionEdges"), &bAdjustSelectionEdges,
|
||||
true);
|
||||
}
|
||||
|
||||
void ViewInfo::SetBeforeScreenWidth(wxInt64 beforeWidth, wxInt64 screenWidth, double lowerBoundTime)
|
||||
|
@ -180,6 +180,7 @@ public:
|
||||
bool bUpdateTrackIndicator;
|
||||
|
||||
bool bScrollBeyondZero;
|
||||
bool bAdjustSelectionEdges;
|
||||
|
||||
// During timer update, grab the volatile stream time just once, so that
|
||||
// various other drawing code can use the exact same value.
|
||||
|
Loading…
x
Reference in New Issue
Block a user