Skip to content

Commit 52a4367

Browse files
committed
Merge branch 'development' into feature/subscription-cache
* development: (21 commits) Fix playback of VOD/non-live videos with Invidious (FreeTubeApp#5654) Translated using Weblate (Bulgarian) Translated using Weblate (Japanese) Translated using Weblate (Bulgarian) Specify locale for strings that may differ from the chosen display locale (FreeTubeApp#5624) Added translation using Weblate (Afrikaans) Remove "Force Local Backend for Legacy Formats" setting (FreeTubeApp#5650) Change the hls manifest type to match the parser name shaka player registers (FreeTubeApp#5648) Fix incorrect/translated placeholders in locale files (FreeTubeApp#5628) Translated using Weblate (Portuguese (Brazil)) Translated using Weblate (Portuguese (Brazil)) Translated using Weblate (Turkish) Translated using Weblate (Czech) Translated using Weblate (Japanese) Translated using Weblate (French) Translated using Weblate (Japanese) Translated using Weblate (Hungarian) Translated using Weblate (Portuguese (Brazil)) Translated using Weblate (Chinese (Traditional Han script)) Translated using Weblate (Polish) ...
2 parents 07d796a + 42781ec commit 52a4367

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

64 files changed

+1398
-425
lines changed

src/renderer/App.vue

+1
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,7 @@
2323
>
2424
<span
2525
class="changeLogText"
26+
lang="en"
2627
v-html="updateChangelog"
2728
/>
2829
<ft-flex-box>

src/renderer/components/ft-playlist-add-video-prompt/ft-playlist-add-video-prompt.js

-1
Original file line numberDiff line numberDiff line change
@@ -289,7 +289,6 @@ export default defineComponent({
289289
if (addedPlaylistIds.size === 1) {
290290
message = this.$tc('User Playlists.AddVideoPrompt.Toast.{videoCount} video(s) added to 1 playlist', this.toBeAddedToPlaylistVideoCount, {
291291
videoCount: this.toBeAddedToPlaylistVideoCount,
292-
playlistCount: addedPlaylistIds.size,
293292
})
294293
} else {
295294
message = this.$tc('User Playlists.AddVideoPrompt.Toast.{videoCount} video(s) added to {playlistCount} playlists', this.toBeAddedToPlaylistVideoCount, {

src/renderer/components/ft-select/ft-select.js

+4
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,10 @@ export default defineComponent({
4747
iconColor: {
4848
type: String,
4949
default: null
50+
},
51+
isLocaleSelector: {
52+
type: Boolean,
53+
default: false
5054
}
5155
},
5256
emits: ['change'],

src/renderer/components/ft-select/ft-select.vue

+1
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@
1515
v-for="(name, index) in selectNames"
1616
:key="index"
1717
:value="selectValues[index]"
18+
:lang="isLocaleSelector && selectValues[index] !== 'system' ? selectValues[index].replace('_', '-') : null"
1819
>
1920
{{ name }}
2021
</option>

src/renderer/components/general-settings/general-settings.js

-5
Original file line numberDiff line numberDiff line change
@@ -242,10 +242,6 @@ export default defineComponent({
242242

243243
handlePreferredApiBackend: function (backend) {
244244
this.updateBackendPreference(backend)
245-
246-
if (backend === 'local') {
247-
this.updateForceLocalBackendForLegacy(false)
248-
}
249245
},
250246

251247
handleThumbnailPreferenceChange: function (value) {
@@ -270,7 +266,6 @@ export default defineComponent({
270266
'updateRegion',
271267
'updateListType',
272268
'updateThumbnailPreference',
273-
'updateForceLocalBackendForLegacy',
274269
'updateCurrentLocale',
275270
'updateExternalLinkHandling',
276271
'updateGeneralAutoLoadMorePaginatedItemsEnabled',

src/renderer/components/general-settings/general-settings.vue

+1
Original file line numberDiff line numberDiff line change
@@ -81,6 +81,7 @@
8181
:select-names="localeNames"
8282
:select-values="localeOptions"
8383
:icon="['fas', 'language']"
84+
is-locale-selector
8485
@change="updateCurrentLocale"
8586
/>
8687
<ft-select

src/renderer/components/player-settings/player-settings.js

-5
Original file line numberDiff line numberDiff line change
@@ -83,10 +83,6 @@ export default defineComponent({
8383
return this.$store.getters.getEnableSubtitlesByDefault
8484
},
8585

86-
forceLocalBackendForLegacy: function () {
87-
return this.$store.getters.getForceLocalBackendForLegacy
88-
},
89-
9086
proxyVideos: function () {
9187
return this.$store.getters.getProxyVideos
9288
},
@@ -284,7 +280,6 @@ export default defineComponent({
284280
'updateAutoplayPlaylists',
285281
'updatePlayNextVideo',
286282
'updateEnableSubtitlesByDefault',
287-
'updateForceLocalBackendForLegacy',
288283
'updateProxyVideos',
289284
'updateDefaultTheatreMode',
290285
'updateDefaultSkipInterval',

src/renderer/components/player-settings/player-settings.vue

-8
Original file line numberDiff line numberDiff line change
@@ -4,14 +4,6 @@
44
>
55
<div class="switchColumnGrid">
66
<div class="switchColumn">
7-
<ft-toggle-switch
8-
:label="$t('Settings.Player Settings.Force Local Backend for Legacy Formats')"
9-
:compact="true"
10-
:disabled="backendPreference === 'local'"
11-
:default-value="forceLocalBackendForLegacy"
12-
:tooltip="$t('Tooltips.Player Settings.Force Local Backend for Legacy Formats')"
13-
@change="updateForceLocalBackendForLegacy"
14-
/>
157
<ft-toggle-switch
168
:label="$t('Settings.Player Settings.Proxy Videos Through Invidious')"
179
:compact="true"

src/renderer/store/modules/settings.js

-1
Original file line numberDiff line numberDiff line change
@@ -193,7 +193,6 @@ const state = {
193193
externalPlayerIgnoreDefaultArgs: false,
194194
externalPlayerCustomArgs: '',
195195
expandSideBar: false,
196-
forceLocalBackendForLegacy: false,
197196
hideActiveSubscriptions: false,
198197
hideChannelCommunity: false,
199198
hideChannelPlaylists: false,

src/renderer/views/About/About.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ export default defineComponent({
2121
{
2222
icon: ['fab', 'github'],
2323
title: this.$t('About.Source code'),
24-
content: `<a href="https://github.com/FreeTubeApp/FreeTube">GitHub: FreeTubeApp/FreeTube</a><br>${this.$t('About.Licensed under the')} <a href="https://www.gnu.org/licenses/agpl-3.0.en.html">${this.$t('About.AGPLv3')}</a>`
24+
content: `<a href="https://github.com/FreeTubeApp/FreeTube" lang="en">GitHub: FreeTubeApp/FreeTube</a><br>${this.$t('About.Licensed under the')} <a href="https://www.gnu.org/licenses/agpl-3.0.en.html">${this.$t('About.AGPLv3')}</a>`
2525
},
2626
{
2727
icon: ['fas', 'file-download'],

src/renderer/views/Watch/Watch.js

+4-31
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ import {
3838
} from '../../helpers/api/invidious'
3939

4040
const MANIFEST_TYPE_DASH = 'application/dash+xml'
41-
const MANIFEST_TYPE_HLS = 'application/x-mpegURL'
41+
const MANIFEST_TYPE_HLS = 'application/x-mpegurl'
4242

4343
export default defineComponent({
4444
name: 'Watch',
@@ -164,9 +164,6 @@ export default defineComponent({
164164
defaultVideoFormat: function () {
165165
return this.$store.getters.getDefaultVideoFormat
166166
},
167-
forceLocalBackendForLegacy: function () {
168-
return this.$store.getters.getForceLocalBackendForLegacy
169-
},
170167
thumbnailPreference: function () {
171168
return this.$store.getters.getThumbnailPreference
172169
},
@@ -836,19 +833,9 @@ export default defineComponent({
836833
// which fixed the API returning incorrect height, width and fps information
837834
const trustApiResponse = result.adaptiveFormats.some(stream => typeof stream.size === 'string')
838835

839-
if (process.env.SUPPORTS_LOCAL_API && this.forceLocalBackendForLegacy) {
840-
const legacyFormats = await this.getLocalLegacyFormats()
841-
842-
if (legacyFormats !== null) {
843-
this.legacyFormats = legacyFormats
844-
} else {
845-
this.legacyFormats = result.formatStreams.map(format => mapInvidiousLegacyFormat(format, trustApiResponse))
846-
}
847-
} else {
848-
this.legacyFormats = result.formatStreams.map(format => mapInvidiousLegacyFormat(format, trustApiResponse))
849-
}
836+
this.legacyFormats = result.formatStreams.map(format => mapInvidiousLegacyFormat(format, trustApiResponse))
850837

851-
if (!process.env.SUPPORTS_LOCAL_API || (this.proxyVideos && !this.forceLocalBackendForLegacy)) {
838+
if (!process.env.SUPPORTS_LOCAL_API || this.proxyVideos) {
852839
this.legacyFormats.forEach(format => {
853840
format.url = getProxyUrl(format.url)
854841
})
@@ -1125,20 +1112,6 @@ export default defineComponent({
11251112
this.timestamp = isNaN(timestamp) || timestamp < 0 ? null : timestamp
11261113
},
11271114

1128-
getLocalLegacyFormats: async function () {
1129-
try {
1130-
const result = await getLocalVideoInfo(this.videoId)
1131-
return result.streaming_data.formats.map(mapLocalLegacyFormat)
1132-
} catch (err) {
1133-
const errorMessage = this.$t('Local API Error (Click to copy)')
1134-
showToast(`${errorMessage}: ${err}`, 10000, () => {
1135-
copyToClipboard(err)
1136-
})
1137-
console.error(err)
1138-
return null
1139-
}
1140-
},
1141-
11421115
handleFormatChange: function (format) {
11431116
switch (format) {
11441117
case 'dash':
@@ -1410,7 +1383,7 @@ export default defineComponent({
14101383
if (localFormat.has_audio) {
14111384
audioFormats.push(localFormat)
14121385

1413-
if (localFormat.is_dubbed || localFormat.is_descriptive || localFormat.is_drc || localFormat.is_secondary) {
1386+
if (localFormat.is_dubbed || localFormat.is_descriptive || localFormat.is_secondary) {
14141387
hasMultipleAudioTracks = true
14151388
}
14161389
}

0 commit comments

Comments
 (0)