-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(ts) migrate JitsiTrackErrors to typescript enum
- Loading branch information
1 parent
3bc1b88
commit 3c392be
Showing
3 changed files
with
87 additions
and
75 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,4 @@ | ||
lib-jitsi-meet.min.js -text -diff | ||
lib-jitsi-meet.js -text -diff | ||
lib-jitsi-meet.js.map -text -diff | ||
text eol=lf |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,86 @@ | ||
/** | ||
* The errors for the JitsiTrack objects. | ||
*/ | ||
|
||
export enum JitsiTrackErrors { | ||
/** | ||
* An error which indicates that some of requested constraints in | ||
* getUserMedia call were not satisfied. | ||
*/ | ||
CONSTRAINT_FAILED = 'gum.constraint_failed', | ||
|
||
/** | ||
* A generic error which indicates an error occurred while selecting | ||
* a DesktopCapturerSource from the electron app. | ||
*/ | ||
ELECTRON_DESKTOP_PICKER_ERROR = 'gum.electron_desktop_picker_error', | ||
|
||
/** | ||
* An error which indicates a custom desktop picker could not be detected | ||
* for the electron app. | ||
*/ | ||
ELECTRON_DESKTOP_PICKER_NOT_FOUND = 'gum.electron_desktop_picker_not_found', | ||
|
||
/** | ||
* Generic getUserMedia error. | ||
*/ | ||
GENERAL = 'gum.general', | ||
|
||
/** | ||
* An error which indicates that requested device was not found. | ||
*/ | ||
NOT_FOUND = 'gum.not_found', | ||
|
||
/** | ||
* An error which indicates that user denied permission to share requested | ||
* device. | ||
*/ | ||
PERMISSION_DENIED = 'gum.permission_denied', | ||
|
||
/** | ||
* Generic error for screensharing failure. | ||
*/ | ||
SCREENSHARING_GENERIC_ERROR = 'gum.screensharing_generic_error', | ||
|
||
/** | ||
* An error which indicates that user canceled screen sharing window | ||
* selection dialog. | ||
*/ | ||
SCREENSHARING_USER_CANCELED = 'gum.screensharing_user_canceled', | ||
|
||
/** | ||
* Indicates that the timeout passed to the obtainAudioAndVideoPermissions has expired without GUM resolving. | ||
*/ | ||
TIMEOUT = 'gum.timeout', | ||
|
||
/** | ||
* An error which indicates that track has been already disposed and cannot | ||
* be longer used. | ||
*/ | ||
TRACK_IS_DISPOSED = 'track.track_is_disposed', | ||
|
||
/** | ||
* An error which indicates that track has no MediaStream associated. | ||
*/ | ||
TRACK_NO_STREAM_FOUND = 'track.no_stream_found', | ||
|
||
/** | ||
* An error which indicates that requested video resolution is not supported | ||
* by a webcam. | ||
*/ | ||
UNSUPPORTED_RESOLUTION = 'gum.unsupported_resolution' | ||
} | ||
|
||
// exported for backward compatibility | ||
export const CONSTRAINT_FAILED = JitsiTrackErrors.CONSTRAINT_FAILED; | ||
export const ELECTRON_DESKTOP_PICKER_ERROR = JitsiTrackErrors.ELECTRON_DESKTOP_PICKER_ERROR; | ||
export const ELECTRON_DESKTOP_PICKER_NOT_FOUND = JitsiTrackErrors.ELECTRON_DESKTOP_PICKER_NOT_FOUND; | ||
export const GENERAL = JitsiTrackErrors.GENERAL; | ||
export const NOT_FOUND = JitsiTrackErrors.NOT_FOUND; | ||
export const PERMISSION_DENIED = JitsiTrackErrors.PERMISSION_DENIED; | ||
export const SCREENSHARING_GENERIC_ERROR = JitsiTrackErrors.SCREENSHARING_GENERIC_ERROR; | ||
export const SCREENSHARING_USER_CANCELED = JitsiTrackErrors.SCREENSHARING_USER_CANCELED; | ||
export const TIMEOUT = JitsiTrackErrors.TIMEOUT; | ||
export const TRACK_IS_DISPOSED = JitsiTrackErrors.TRACK_IS_DISPOSED; | ||
export const TRACK_NO_STREAM_FOUND = JitsiTrackErrors.TRACK_NO_STREAM_FOUND; | ||
export const UNSUPPORTED_RESOLUTION = JitsiTrackErrors.UNSUPPORTED_RESOLUTION; |