Improvements for imageSlider and cineDialog components. Rolling back default protocol (HP) configurations
This commit is contained in:
parent
4afe74172e
commit
5d5df29e09
@ -5,7 +5,7 @@ function getDefaultProtocol() {
|
||||
|
||||
var oneByOne = new HP.ViewportStructure('grid', {
|
||||
rows: 1,
|
||||
columns: 2
|
||||
columns: 1
|
||||
});
|
||||
|
||||
var viewport = new HP.Viewport();
|
||||
|
||||
@ -268,7 +268,7 @@ Template.cineDialog.events({
|
||||
}
|
||||
},
|
||||
|
||||
'input [data-key=framesPerSecond] input'(event, instance) {
|
||||
'input [data-key=framesPerSecond] input, change [data-key=framesPerSecond] input'(event, instance) {
|
||||
// Update the FPS text onscreen
|
||||
const rate = parseFloat($(event.currentTarget).val());
|
||||
instance.updateFramerate(rate);
|
||||
|
||||
@ -19,13 +19,10 @@ Template.imageControls.onRendered(() => {
|
||||
})
|
||||
|
||||
Template.imageControls.events({
|
||||
'keydown #imageSlider'(event) {
|
||||
'keydown input[type=range]'(event) {
|
||||
// We don't allow direct keyboard up/down input on the
|
||||
// image sliders since the natural direction is reversed (0 is at the top)
|
||||
|
||||
// Prevent the browser's default behaviour (scrolling)
|
||||
event.preventDefault();
|
||||
|
||||
// Store the KeyCodes in an object for readability
|
||||
const keys = {
|
||||
DOWN: 40,
|
||||
@ -34,8 +31,10 @@ Template.imageControls.events({
|
||||
|
||||
if (event.which === keys.DOWN) {
|
||||
OHIF.viewer.hotkeyFunctions.scrollDown();
|
||||
event.preventDefault();
|
||||
} else if (event.which === keys.UP) {
|
||||
OHIF.viewer.hotkeyFunctions.scrollUp();
|
||||
event.preventDefault();
|
||||
}
|
||||
},
|
||||
'input input[type=range], change input[type=range]'(event) {
|
||||
|
||||
Loading…
Reference in New Issue
Block a user