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

Save power by adding delay between network requests in background. #573

Conversation

mbarashkov
Copy link
Contributor

This is a remake of #572

Also improve app initial load by delaying sticker set loading by 0.9 seconds
@@ -88,7 +88,8 @@ Page {
}
Timer {
id: updateSecondaryContentTimer
interval: 600
interval: 1500
repeat: false
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There's no need for this, repeat defaults to false

Copy link
Contributor Author

@mbarashkov mbarashkov Jul 2, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There's no need for this, repeat defaults to false

Above this another method states "repeat: false" expicitly. I assumed that's a code style. After all it's better readable this way..

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

And is this necessary at all, to increase the interval? This is a one-time action, it won't have any impact on power usage or anything like that.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Well, yes, it's logically unrelated, I've just noticed it improves app startup performance.. Ok, I will redo the PR again.

@mbarashkov
Copy link
Contributor Author

@monich change removed in #574

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

Successfully merging this pull request may close these issues.

2 participants