mirror of
https://github.com/overcuriousity/autopsy-flatpak.git
synced 2025-07-13 08:26:15 +00:00
Merge pull request #5688 from gdicristofaro/6027-display-translated-file-name-column-by-default
6027 display translated file name column by default
This commit is contained in:
commit
32877c2098
@ -75,6 +75,7 @@ public final class UserPreferences {
|
||||
public static final String SHOW_ONLY_CURRENT_USER_TAGS = "ShowOnlyCurrentUserTags";
|
||||
public static final String HIDE_SCO_COLUMNS = "HideCentralRepoCommentsAndOccurrences"; //The key for this setting pre-dates the settings current functionality //NON-NLS
|
||||
public static final String DISPLAY_TRANSLATED_NAMES = "DisplayTranslatedNames";
|
||||
private static final boolean DISPLAY_TRANSLATED_NAMES_DEFAULT = true;
|
||||
public static final String EXTERNAL_HEX_EDITOR_PATH = "ExternalHexEditorPath";
|
||||
public static final String SOLR_MAX_JVM_SIZE = "SolrMaxJVMSize";
|
||||
public static final String RESULTS_TABLE_PAGE_SIZE = "ResultsTablePageSize";
|
||||
@ -265,7 +266,7 @@ public final class UserPreferences {
|
||||
}
|
||||
|
||||
public static boolean displayTranslatedFileNames() {
|
||||
return preferences.getBoolean(DISPLAY_TRANSLATED_NAMES, false);
|
||||
return preferences.getBoolean(DISPLAY_TRANSLATED_NAMES, DISPLAY_TRANSLATED_NAMES_DEFAULT);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -105,7 +105,7 @@ public abstract class AbstractAbstractFileNode<T extends AbstractFile> extends A
|
||||
this.content.getName(), this.content.getId()), ex);
|
||||
}
|
||||
|
||||
if (UserPreferences.displayTranslatedFileNames()) {
|
||||
if (TextTranslationService.getInstance().hasProvider() && UserPreferences.displayTranslatedFileNames()) {
|
||||
backgroundTasksPool.submit(new TranslationTask(
|
||||
new WeakReference<>(this), weakPcl));
|
||||
}
|
||||
@ -331,7 +331,7 @@ public abstract class AbstractAbstractFileNode<T extends AbstractFile> extends A
|
||||
* background task that promises to update these values.
|
||||
*/
|
||||
|
||||
if (UserPreferences.displayTranslatedFileNames()) {
|
||||
if (TextTranslationService.getInstance().hasProvider() && UserPreferences.displayTranslatedFileNames()) {
|
||||
properties.add(new NodeProperty<>(ORIGINAL_NAME.toString(), ORIGINAL_NAME.toString(), NO_DESCR, ""));
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user