| 333 | } |
| 334 | |
| 335 | LabelSuggestionHelper::Preferences LabelSuggestionHelper::GetSuggestionPreferences() |
| 336 | { |
| 337 | auto prefService = mitk::CoreServices::GetPreferencesService(); |
| 338 | |
| 339 | Preferences prefs; |
| 340 | |
| 341 | if (nullptr != prefService) |
| 342 | { |
| 343 | auto systemPref = prefService->GetSystemPreferences(); |
| 344 | if (nullptr != systemPref) |
| 345 | { |
| 346 | auto* nodePrefs = systemPref->Node("/org.mitk.views.segmentation"); |
| 347 | |
| 348 | prefs.externalLabelSuggestionFile = nodePrefs->Get("external label suggestions", prefs.externalLabelSuggestionFile); |
| 349 | prefs.standardLabelSuggestionResource = nodePrefs->Get("standard label suggestions", prefs.standardLabelSuggestionResource); |
| 350 | prefs.replaceStandardSuggestions = nodePrefs->GetBool("replace standard suggestions", prefs.replaceStandardSuggestions); |
| 351 | prefs.enforceSuggestions = nodePrefs->GetBool("enforce suggestions", prefs.enforceSuggestions); |
| 352 | prefs.suggestionOnce = nodePrefs->GetBool("suggest once", prefs.suggestionOnce); |
| 353 | } |
| 354 | } |
| 355 | |
| 356 | return prefs; |
| 357 | } |
| 358 | |
| 359 | |
| 360 | } // namespace mitk |
nothing calls this directly
no test coverage detected