feat(hotkeys): Migrate hotkeys to customization service and fix issues with overrides (#4777)
This commit is contained in:
1 parent
4559d39a91
commit
3e6913b097
39 files changed
+814
-1552
No files matched your search
@@ -84,7 +84,8 @@ function modeFactory({ modeConfiguration }) {
|
||||
* Lifecycle hooks
|
||||
*/
|
||||
onModeEnter: function ({ servicesManager, extensionManager, commandsManager }: withAppTypes) {
|
||||
const { measurementService, toolbarService, toolGroupService } = servicesManager.services;
|
||||
const { measurementService, toolbarService, toolGroupService, customizationService } =
|
||||
servicesManager.services;
|
||||
|
||||
measurementService.clearMeasurements();
|
||||
|
||||
@@ -238,7 +239,6 @@ function modeFactory({ modeConfiguration }) {
|
||||
dicomsr.sopClassHandler,
|
||||
dicomRT.sopClassHandler,
|
||||
],
|
||||
hotkeys: [...hotkeys.defaults.hotkeyBindings],
|
||||
...modeConfiguration,
|
||||
};
|
||||
}
|
||||
|
||||
@@ -205,6 +205,32 @@ const toolbarButtons: Button[] = [
|
||||
},
|
||||
},
|
||||
},
|
||||
// {
|
||||
// id: 'Undo',
|
||||
// uiType: 'ohif.toolButton',
|
||||
// props: {
|
||||
// type: 'tool',
|
||||
// icon: 'prev-arrow',
|
||||
// label: 'Undo',
|
||||
// commands: {
|
||||
// commandName: 'undo',
|
||||
// },
|
||||
// evaluate: 'evaluate.action',
|
||||
// },
|
||||
// },
|
||||
// {
|
||||
// id: 'Redo',
|
||||
// uiType: 'ohif.toolButton',
|
||||
// props: {
|
||||
// type: 'tool',
|
||||
// icon: 'next-arrow',
|
||||
// label: 'Redo',
|
||||
// commands: {
|
||||
// commandName: 'redo',
|
||||
// },
|
||||
// evaluate: 'evaluate.action',
|
||||
// },
|
||||
// },
|
||||
];
|
||||
|
||||
export default toolbarButtons;
|
||||
Reference in new issue
Block a user