Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Feature Request] Disable refresh of image on resume function #30

Closed
Moerup opened this issue Jan 13, 2021 · 2 comments
Closed

[Feature Request] Disable refresh of image on resume function #30

Moerup opened this issue Jan 13, 2021 · 2 comments

Comments

@Moerup
Copy link

Moerup commented Jan 13, 2021

Experimenting with MMM-pages and WallberryTheme which so far functions really well, except for one thing.
Every time you change a page, the background gets updated.
Would be really cool if you could somehow disable that. Or maybe I have missed a working setting for it.
I think it happens because of the resume function:

resume: function() {
		Log.info("Waking WallberryTheme...");
		clearTimeout(this.fetchTimer);
		this.fetchPhoto();
	},`

The dev log at least shows that message every time I change the page.

I'm pretty new to MM modules, so I'm not sure what specific circumstances trigger that function.
And most likely implemented this way for a reason :)

I have no idea how to implement it the best way, maybe somehow not updating the image when a specific notification is sent?
A standard config flag would be nice, but not sure if that's possible without removing other functionality.

My current config I'm using while messing with it if you want to have a look at it:

modules: [{
            module: 'MMM-pages',
            config: {
                modules:
                [["WallberryTheme/WB-weather", "calendar"],
                    ["MMM-MonthlyCalendar"]],
                fixed: ["WallberryTheme", "WallberryTheme/WB-clock", "MMM-page-indicator", "MMM-Touch"],
            }
        }, {
            module: "WallberryTheme",
            position: "fullscreen_below",
            config: {
                unsplashAccessKey: "XXX",
                collections: "45585351",
                clearCacheOnStart: false,
            }
        }, {
            module: "WallberryTheme/WB-clock",
            position: "top_bar",
            config: {}
        }, {
            module: "WallberryTheme/WB-weather",
            position: "bottom_bar",
            config: {
                apiKey: "XXX",
                providerName: "openweathermap",
                latitude: XXX,
                longitude: XXX
            }
        }, {
            module: "calendar",
            position: "top_right",
            config: {
                maximumEntries: 10000,
                colored: true,
                coloredSymbolOnly: false,
                calendars: [{
                        url: 'XXX',
                        color: '#263261',
                    },
                ],
            }
        }, {
            module: "MMM-MonthlyCalendar",
            position: "bottom_bar",
            config: {
                mode: "nextFourWeeks",
            }
        }, {
            module: "MMM-Touch",
            position: "top_right",
            config: {
                useDisplay: true,
				debug: false,
                gestureCommands: {
                    "default": {
                        "SWIPE_LEFT_1": (commander, gesture) => {
                            commander.sendNotification("PAGE_INCREMENT")
                        },
                        "SWIPE_RIGHT_1": (commander, gesture) => {
                            commander.sendNotification("PAGE_DECREMENT")
                        },
                    },
                },
            }
        }, {
            module: 'MMM-page-indicator',
            position: 'bottom_bar',
            config: {
                pages: 2,
            }
        },
    ]
};
@Moerup Moerup changed the title Disable refresh of image on resume function [Feature Request] Disable refresh of image on resume function Jan 13, 2021
@Moerup
Copy link
Author

Moerup commented Jan 13, 2021

Weird, now it stopped doing it and I don't get the log message in console every time I change page..
Don't think I changed anything, but I can't replicate it.

@Moerup
Copy link
Author

Moerup commented Jan 14, 2021

Closing this as I can't replicate the functionality anymore.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant