(origin FilePickerOrigin, originalPath, browseDir string, fileAllowed, dirAllowed bool)
| 143 | } |
| 144 | |
| 145 | func (m *RootModel) openDirectoryPicker(origin FilePickerOrigin, originalPath, browseDir string, fileAllowed, dirAllowed bool) tea.Cmd { |
| 146 | m.filepickerOrigin = origin |
| 147 | m.filepickerOriginalPath = originalPath |
| 148 | m.state = FilePickerState |
| 149 | m.filepicker = newFilepicker(browseDir) |
| 150 | m.applyFilePickerMode(fileAllowed, dirAllowed) |
| 151 | |
| 152 | return m.filepicker.Init() |
| 153 | } |
| 154 | |
| 155 | // checkForDuplicate checks if a compatible download already exists |
| 156 | func (m RootModel) checkForDuplicate(url string) *processing.DuplicateResult { |
no test coverage detected