MCPcopy Create free account
hub / github.com/audacity/audacity / GetPinnedHeadPreference

Method GetPinnedHeadPreference

src/prefs/TracksPrefs.cpp:366–375  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

364}
365
366bool TracksPrefs::GetPinnedHeadPreference()
367{
368 // JKC: Cache this setting as it is read many times during drawing, and otherwise causes screen flicker.
369 // Correct solution would be to re-write wxFileConfig to be efficient.
370 if( iPreferencePinned >= 0 )
371 return iPreferencePinned == 1;
372 bool bResult = gPrefs->ReadBool(PinnedHeadPreferenceKey(), PinnedHeadPreferenceDefault());
373 iPreferencePinned = bResult ? 1: 0;
374 return bResult;
375}
376
377void TracksPrefs::SetPinnedHeadPreference(bool value, bool flush)
378{

Callers

nothing calls this directly

Calls 3

PinnedHeadPreferenceKeyFunction · 0.85
ReadBoolMethod · 0.80

Tested by

no test coverage detected