Giter VIP home page Giter VIP logo

flutter_flatpak's People

Contributors

merrit avatar proninyaroslav avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

Forkers

proninyaroslav

flutter_flatpak's Issues

Incorrect system theme determining in GNOME 42

System: Fedora 36
Desktop Environment: GNOME 42
Flatpak version: 1.12.7

I found this in the current release of Feeling Finder Merrit/feeling_finder@c45b99f. When I select the system theme it always shows the dark theme no matter if the system theme is light or dark.

ThemeMode themeMode;
if (themeNumber == '2') {
themeMode = ThemeMode.light;
} else {
themeMode = ThemeMode.dark;
}

I decided to check what this command produces in different modes, I just typed this in the terminal:

dbus-send --print-reply --dest=org.freedesktop.portal.Desktop /org/freedesktop/portal/desktop org.freedesktop.portal.Settings.Read string:'org.freedesktop.appearance' string:'color-scheme'

In the light mode: variant variant uint32 0
In the dark mode: variant variant uint32 1

Your plugin code checks that if it's command returns 2 it's a light theme, but on my system it returns 1 which tells the plugin it's a dark theme when it isn't.

Listen to the theme change event in real time

When I change the theme on the system, for example in GNOME 42 (Fedora 36), the theme changes in real time and there is no way in the plugin to listen for these changes so that the app can react to the theme change. It's probably necessary to setup a D-Bus listener. We can use dbus package for this purpose.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.