From 1bc2feec92abd7ce573ff8c2a6373e1e790cd011 Mon Sep 17 00:00:00 2001 From: Ubuntu Date: Mon, 18 Mar 2024 07:40:51 +0000 Subject: [PATCH] add ui elements for bitrate --- src/components/App/App.tsx | 46 ++++++++++++++++++++++++++++ src/components/VBrowser/VBrowser.tsx | 19 +++++++++--- src/components/VBrowser/index.ts | 3 +- src/components/VBrowser/types.d.ts | 1 + 4 files changed, 64 insertions(+), 5 deletions(-) diff --git a/src/components/App/App.tsx b/src/components/App/App.tsx index 6f241d4e66..20348b586b 100644 --- a/src/components/App/App.tsx +++ b/src/components/App/App.tsx @@ -125,6 +125,7 @@ interface AppState { isErrorAuth: boolean; settings: Settings; vBrowserResolution: string; + vBrowserQuality: string; isVBrowserLarge: boolean; nonPlayableMedia: boolean; currentTab: string; @@ -189,6 +190,7 @@ export default class App extends React.Component { isErrorAuth: false, settings: {}, vBrowserResolution: '1280x720@30', + vBrowserQuality: '1', isVBrowserLarge: false, nonPlayableMedia: false, currentTab: @@ -431,6 +433,7 @@ export default class App extends React.Component { nonPlayableMedia: false, isVBrowserLarge: data.isVBrowserLarge, vBrowserResolution: '1280x720@30', + vBrowserQuality: '1', controller: data.controller, isLiveHls: false, }, @@ -2276,6 +2279,45 @@ export default class App extends React.Component { ]} > )} + {this.playingVBrowser() && ( + { + this.setState({ + vBrowserQuality: data.value as string, + }); + }} + selection + options={[ + { + text: 'Eco', + value: '0.25', + }, + { + text: 'Low', + value: '0.5', + }, + { + text: 'Standard', + value: '1', + }, + { + text: 'High', + value: '1.5', + }, + { + text: 'Ultra', + value: '2', + }, + ]} + > + )} {this.playingVBrowser() && (