Select the full time range, if no time range is selected and selecting is allowed. Returns "false" selecting not allowed.
| 98 | // Select the full time range, if no time range is selected and |
| 99 | // selecting is allowed. Returns "false" selecting not allowed. |
| 100 | bool SelectAllIfNoneAndAllowed( AudacityProject &project ) |
| 101 | { |
| 102 | auto allowed = gPrefs->ReadBool(wxT("/GUI/SelectAllOnNone"), false); |
| 103 | auto &viewInfo = ViewInfo::Get( project ); |
| 104 | auto flags = CommandManager::Get( project ).GetUpdateFlags(); |
| 105 | |
| 106 | if((flags & EditableTracksSelectedFlag()).none() || |
| 107 | viewInfo.selectedRegion.isPoint()) { |
| 108 | if (!allowed) { |
| 109 | return false; |
| 110 | } |
| 111 | DoSelectAllAudio( project ); |
| 112 | } |
| 113 | return true; |
| 114 | } |
| 115 | |
| 116 | void DoListSelection( |
| 117 | AudacityProject &project, Track &t, bool shift, bool ctrl, bool modifyState) |
no test coverage detected