Commented out incorrect theme color change logic in ThemeInit
due to issues with the new Fyne version.
This commit is contained in:
@@ -1,10 +1,11 @@
|
|||||||
package setting
|
package setting
|
||||||
|
|
||||||
import (
|
import (
|
||||||
|
"image/color"
|
||||||
|
|
||||||
"fyne.io/fyne/v2"
|
"fyne.io/fyne/v2"
|
||||||
"fyne.io/fyne/v2/lang"
|
"fyne.io/fyne/v2/lang"
|
||||||
"fyne.io/fyne/v2/theme"
|
"fyne.io/fyne/v2/theme"
|
||||||
"image/color"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
func (s *setting) GetTheme() ThemeInfoContract {
|
func (s *setting) GetTheme() ThemeInfoContract {
|
||||||
@@ -31,7 +32,8 @@ func (s *setting) SetTheme(themeInfo ThemeInfoContract) {
|
|||||||
func (s *setting) ThemeInit() {
|
func (s *setting) ThemeInit() {
|
||||||
themeInfo := s.GetTheme()
|
themeInfo := s.GetTheme()
|
||||||
if themeInfo.GetName() == "default" {
|
if themeInfo.GetName() == "default" {
|
||||||
s.fyneApp.Settings().SetTheme(theme.DefaultTheme())
|
// In the new version of Fyne the theme color changes incorrectly if it is set to default.
|
||||||
|
// s.fyneApp.Settings().SetTheme(theme.DefaultTheme())
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
s.fyneApp.Settings().SetTheme(&forcedVariant{theme: theme.DefaultTheme(), variant: themeInfo.GetVariant()})
|
s.fyneApp.Settings().SetTheme(&forcedVariant{theme: theme.DefaultTheme(), variant: themeInfo.GetVariant()})
|
||||||
|
Reference in New Issue
Block a user