mirror of
https://github.com/gyurix1968/guacamole-client.git
synced 2025-09-06 05:07:41 +00:00
GUACAMOLE-346: Update seeking state when paused or canceled.
This commit is contained in:
@@ -161,6 +161,7 @@
|
|||||||
// If paused, the play/pause button should read "Play"
|
// If paused, the play/pause button should read "Play"
|
||||||
recording.onpause = function() {
|
recording.onpause = function() {
|
||||||
playPause.textContent = 'Play';
|
playPause.textContent = 'Play';
|
||||||
|
display.classList.remove('seeking');
|
||||||
};
|
};
|
||||||
|
|
||||||
// Toggle play/pause when display or button are clicked
|
// Toggle play/pause when display or button are clicked
|
||||||
@@ -173,6 +174,7 @@
|
|||||||
|
|
||||||
// Cancel seek operation when cancel button is clicked
|
// Cancel seek operation when cancel button is clicked
|
||||||
cancelSeek.onclick = function cancelSeekOperation(e) {
|
cancelSeek.onclick = function cancelSeekOperation(e) {
|
||||||
|
display.classList.remove('seeking');
|
||||||
recording.pause();
|
recording.pause();
|
||||||
e.stopPropagation();
|
e.stopPropagation();
|
||||||
};
|
};
|
||||||
@@ -204,9 +206,6 @@
|
|||||||
// Seek within recording if slider is moved
|
// Seek within recording if slider is moved
|
||||||
positionSlider.onchange = function sliderPositionChanged() {
|
positionSlider.onchange = function sliderPositionChanged() {
|
||||||
|
|
||||||
// Seek is in progress
|
|
||||||
display.classList.add('seeking');
|
|
||||||
|
|
||||||
// Request seek
|
// Request seek
|
||||||
recording.seek(positionSlider.value, function seekComplete() {
|
recording.seek(positionSlider.value, function seekComplete() {
|
||||||
|
|
||||||
@@ -214,6 +213,10 @@
|
|||||||
display.classList.remove('seeking');
|
display.classList.remove('seeking');
|
||||||
|
|
||||||
});
|
});
|
||||||
|
|
||||||
|
// Seek is in progress
|
||||||
|
display.classList.add('seeking');
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
})();
|
})();
|
||||||
|
Reference in New Issue
Block a user