Skip to content

Commit

Permalink
Remove GlobalScope interface and global $scope variable
Browse files Browse the repository at this point in the history
  • Loading branch information
YouKnowBlom committed Aug 1, 2021
1 parent 0f62137 commit 89cfdae
Show file tree
Hide file tree
Showing 3 changed files with 1 addition and 11 deletions.
2 changes: 1 addition & 1 deletion src/components/maincontroller.ts
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ import { getMaxBitrateSupport } from './codecSupportHelper';
import { DocumentManager } from './documentManager';
import { BaseItemDto } from '~/api/generated/models/base-item-dto';
import { MediaSourceInfo } from '~/api/generated/models/media-source-info';
import { GlobalScope, PlayRequest } from '~/types/global';
import { PlayRequest } from '~/types/global';

window.castReceiverContext = cast.framework.CastReceiverContext.getInstance();
window.playerManager = window.castReceiverContext.getPlayerManager();
Expand Down
5 changes: 0 additions & 5 deletions src/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,6 @@
@import url('https://fonts.googleapis.com/css?family=Quicksand');
</style>
<script src="//www.gstatic.com/cast/sdk/libs/caf_receiver/v3/cast_receiver_framework.js"></script>
<script>
// $scope has to be available before app.js for webpack imported modules to function
// TODO: Rework this
$scope = {};
</script>
</head>
<body>
<div id="waiting-container-backdrop"></div>
Expand Down
5 changes: 0 additions & 5 deletions src/types/global.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,6 @@ import { SystemVolumeData } from 'chromecast-caf-receiver/cast.framework.system'
import { RepeatMode } from '../api/generated/models/repeat-mode';
import { BaseItemDto } from '../api/generated/models/base-item-dto';

export interface GlobalScope {
[key: string]: any;
}

export interface Dictionary<T> {
[Key: string]: T;
}
Expand Down Expand Up @@ -94,7 +90,6 @@ interface SupportedCommands {
declare global {
export const PRODUCTION: boolean;
export const RECEIVERVERSION: string;
export const $scope: GlobalScope;
export interface Window {
mediaElement: HTMLElement | null;
playerManager: PlayerManager;
Expand Down

0 comments on commit 89cfdae

Please sign in to comment.