Skip to content

TagSpaces is an offline, open source, document manager with tagging support

making exif conten extraction configurable

Ilian Sapundshievb8eb941ef409
diff --git a/app/components/menus/DirectoryMenu.js b/app/components/menus/DirectoryMenu.js
index 35bd49fcc..d98593f10 100644
--- a/app/components/menus/DirectoryMenu.js
+++ b/app/components/menus/DirectoryMenu.js
@@ -50,23 +50,23 @@ import IOActions from '../../reducers/io-actions';
type Props = {
classes: Object,
- open?: boolean,
+ open: boolean,
onClose: () => void,
- anchorEl?: Object | null,
- directoryPath?: string,
+ anchorEl: Object | null,
+ directoryPath: string,
loadDirectoryContent: (path: string) => void,
openDirectory: (path: string) => void,
showInFileManager: (path: string) => void,
openFile: (path: string, isFile: boolean) => void,
deleteDirectory: (path: string) => void,
- reflectCreateEntry?: (path: string, isFile: boolean) => void,
- toggleCreateFileDialog?: () => void,
- loadParentDirectoryContent?: () => void,
- openFileNatively?: (path: string) => void,
- extractContent?: () => void,
- switchPerspective?: (perspectiveId: string) => void,
+ reflectCreateEntry: (path: string, isFile: boolean) => void,
+ toggleCreateFileDialog: () => void,
+ loadParentDirectoryContent: () => void,
+ openFileNatively: (path: string) => void,
+ extractContent: (config: Object) => void,
+ switchPerspective: (perspectiveId: string) => void,
perspectiveMode: boolean,
- showNotification?: (
+ showNotification: (
text: string,
notificationType: string,
autohide: boolean
@@ -103,7 +103,7 @@ const DirectoryMenu = (props: Props) => {
function initContentExtraction() {
props.onClose();
- props.extractContent();
+ props.extractContent({ EXIFGeo: true });
}
function switchPerspective(perspectiveId) {
diff --git a/app/reducers/io-actions.js b/app/reducers/io-actions.js
index ac3225a8a..e4251aa01 100644
--- a/app/reducers/io-actions.js
+++ b/app/reducers/io-actions.js
@@ -34,7 +34,7 @@ import { Pro } from '../pro';
import TaggingActions from './tagging-actions';
const actions = {
- extractContent: () => (
+ extractContent: (options: Object = { EXIFGeo: true, EXIFDateTime: true, IPTCDescription: true, IPTCTags: true }) => (
dispatch: (actions: Object) => void,
getState: () => Object
) => {
@@ -43,7 +43,7 @@ const actions = {
dispatch(AppActions.showNotification(i18n.t('core:needProVersion')));
return false;
}
- Pro.ContentExtractor.extractContent(currentDirectoryEntries, dispatch, AppActions, TaggingActions);
+ Pro.ContentExtractor.extractContent(currentDirectoryEntries, dispatch, AppActions, TaggingActions, options);
},
moveFiles: (paths: Array<string>, targetPath: string) => (
dispatch: (actions: Object) => void,