diff --git a/src/renderer/components/ft-video-player/ft-video-player.js b/src/renderer/components/ft-video-player/ft-video-player.js
index e88bb7b2..cf3c2795 100644
--- a/src/renderer/components/ft-video-player/ft-video-player.js
+++ b/src/renderer/components/ft-video-player/ft-video-player.js
@@ -96,10 +96,6 @@ export default Vue.extend({
}
},
computed: {
- listType: function () {
- return this.$store.getters.getListType
- },
-
defaultPlayback: function () {
return this.$store.getters.getDefaultPlayback
},
@@ -112,6 +108,12 @@ export default Vue.extend({
return this.$store.getters.getAutoplayVideos
}
},
+ watch: {
+ sourceList: function () {
+ console.log('Obtained Source list')
+ this.determineFormatType()
+ }
+ },
mounted: function () {
this.id = this._uid
@@ -199,7 +201,7 @@ export default Vue.extend({
this.useHls = false
this.activeSourceList = this.dashSrc
- setTimeout(this.initializePlayer, 1000)
+ setTimeout(this.initializePlayer, 100)
},
enableLegacyFormat: function () {
diff --git a/src/renderer/components/player-settings/player-settings.js b/src/renderer/components/player-settings/player-settings.js
index c6a98422..4a3b16e4 100644
--- a/src/renderer/components/player-settings/player-settings.js
+++ b/src/renderer/components/player-settings/player-settings.js
@@ -97,6 +97,10 @@ export default Vue.extend({
defaultQuality: function () {
return this.$store.getters.getDefaultQuality
+ },
+
+ defaultTheatreMode: function () {
+ return this.$store.getters.getDefaultTheatreMode
}
},
methods: {
@@ -112,6 +116,7 @@ export default Vue.extend({
'updateEnableSubtitles',
'updateForceLocalBackendForLegacy',
'updateProxyVideos',
+ 'updateDefaultTheatreMode',
'updateDefaultVolume',
'updateDefaultPlayback',
'updateDefaultVideoFormat',
diff --git a/src/renderer/components/player-settings/player-settings.vue b/src/renderer/components/player-settings/player-settings.vue
index d43113f4..cab45f7a 100644
--- a/src/renderer/components/player-settings/player-settings.vue
+++ b/src/renderer/components/player-settings/player-settings.vue
@@ -10,25 +10,25 @@
diff --git a/src/renderer/components/side-nav/side-nav.vue b/src/renderer/components/side-nav/side-nav.vue
index 41974302..30435826 100644
--- a/src/renderer/components/side-nav/side-nav.vue
+++ b/src/renderer/components/side-nav/side-nav.vue
@@ -49,7 +49,7 @@
@click="navigate('userplaylists')"
>
diff --git a/src/renderer/store/modules/settings.js b/src/renderer/store/modules/settings.js
index b8a7ce91..494d78c5 100644
--- a/src/renderer/store/modules/settings.js
+++ b/src/renderer/store/modules/settings.js
@@ -4,18 +4,23 @@ let dbLocation
if (window && window.process && window.process.type === 'renderer') {
// Electron is being used
- let dbLocation = localStorage.getItem('dbLocation')
+ /* let dbLocation = localStorage.getItem('dbLocation')
if (dbLocation === null) {
const electron = require('electron')
dbLocation = electron.remote.app.getPath('userData')
- }
+ } */
- dbLocation += '/settings.db'
+ const electron = require('electron')
+ dbLocation = electron.remote.app.getPath('userData')
+
+ dbLocation = dbLocation + '/settings.db'
} else {
dbLocation = 'settings.db'
}
+console.log(dbLocation)
+
const settingsDb = new Datastore({
filename: dbLocation,
autoload: true
@@ -39,6 +44,7 @@ const state = {
enableSubtitles: true,
forceLocalBackendForLegacy: true,
proxyVideos: false,
+ defaultTheatreMode: false,
defaultVolume: 1,
defaultPlayback: 1,
defaultVideoFormat: 'dash',
@@ -118,6 +124,10 @@ const getters = {
return state.proxyVideos
},
+ getDefaultTheatreMode: () => {
+ return state.defaultTheatreMode
+ },
+
getDefaultVolume: () => {
return state.defaultVolume
},
@@ -191,6 +201,9 @@ const actions = {
case 'proxyVideos':
commit('setProxyVideos', result.value)
break
+ case 'defaultTheatreMode':
+ commit('setDefaultTheatreMode', result.value)
+ break
case 'defaultVolume':
commit('setDefaultVolume', result.value)
sessionStorage.setItem('volume', result.value)
@@ -330,6 +343,14 @@ const actions = {
})
},
+ updateDefaultTheatreMode ({ commit }, defaultTheatreMode) {
+ settingsDb.update({ _id: 'defaultTheatreMode' }, { _id: 'defaultTheatreMode', value: defaultTheatreMode }, { upsert: true }, (err, numReplaced) => {
+ if (!err) {
+ commit('setDefaultTheatreMode', defaultTheatreMode)
+ }
+ })
+ },
+
updateDefaultVolume ({ commit }, defaultVolume) {
settingsDb.update({ _id: 'defaultVolume' }, { _id: 'defaultVolume', value: defaultVolume }, { upsert: true }, (err, numReplaced) => {
if (!err) {
@@ -436,6 +457,9 @@ const mutations = {
setProxy (state, proxy) {
state.proxy = proxy
},
+ setDefaultTheatreMode (state, defaultTheatreMode) {
+ state.defaultTheatreMode = defaultTheatreMode
+ },
setUseTor (state, useTor) {
state.useTor = useTor
},
diff --git a/src/renderer/views/Watch/Watch.css b/src/renderer/views/Watch/Watch.css
index 983941ac..a676c712 100644
--- a/src/renderer/views/Watch/Watch.css
+++ b/src/renderer/views/Watch/Watch.css
@@ -21,7 +21,7 @@
}
.theatrePlayer {
- width: calc(85% + 30px);
+ width: 100%;
float: none;
margin: 0 auto;
margin-bottom: 10px;
diff --git a/src/renderer/views/Watch/Watch.js b/src/renderer/views/Watch/Watch.js
index b173dd52..7c64fc6d 100644
--- a/src/renderer/views/Watch/Watch.js
+++ b/src/renderer/views/Watch/Watch.js
@@ -26,7 +26,7 @@ export default Vue.extend({
return {
isLoading: false,
firstLoad: true,
- useTheatreMode: true,
+ useTheatreMode: false,
showDashPlayer: true,
showLegacyPlayer: false,
showYouTubeNoCookieEmbed: false,
@@ -72,6 +72,10 @@ export default Vue.extend({
return this.$store.getters.getProxyVideos
},
+ defaultTheatreMode: function () {
+ return this.$store.getters.getDefaultTheatreMode
+ },
+
defaultVideoFormat: function () {
return this.$store.getters.getDefaultVideoFormat
},
@@ -126,6 +130,7 @@ export default Vue.extend({
this.videoStoryboardSrc = `${this.invidiousInstance}/api/v1/storyboards/${this.videoId}?height=90`
this.activeFormat = this.defaultVideoFormat
+ this.useTheatreMode = this.defaultTheatreMode
if (!this.usingElectron) {
this.getVideoInformationInvidious()