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

Make WindowId::primary() const #6577

Closed
JonahPlusPlus opened this issue Nov 13, 2022 · 1 comment
Closed

Make WindowId::primary() const #6577

JonahPlusPlus opened this issue Nov 13, 2022 · 1 comment
Labels
A-Windowing Platform-agnostic interface layer to run your app in C-Feature A new feature, making something new possible

Comments

@JonahPlusPlus
Copy link
Contributor

What problem does this solve or what need does it fill?

WindowId::primary() can be made const, which would allow for using it in const contexts, such as having the primary window being a default value.

What solution would you like?

Just change add const to it. Maybe there are other things that can be made const at the same time.

What alternative(s) have you considered?

It could also be changed to WindowId::PRIMARY.

Additional context

I was writing something that uses WindowId::primary() for a default value. I didn't need it to be const here, but I just noticed it.

@JonahPlusPlus JonahPlusPlus added C-Feature A new feature, making something new possible S-Needs-Triage This issue needs to be labelled labels Nov 13, 2022
@JonahPlusPlus
Copy link
Contributor Author

This could be a good first issue (since it's just one word, lol).

@james7132 james7132 added A-Windowing Platform-agnostic interface layer to run your app in and removed S-Needs-Triage This issue needs to be labelled labels Nov 13, 2022
@bors bors bot closed this as completed in 8f95560 Nov 14, 2022
taiyoungjang pushed a commit to taiyoungjang/bevy that referenced this issue Dec 15, 2022
# Objective

- fixes bevyengine#6577

## Solution

- simply add `const` to `primary()`.
alradish pushed a commit to alradish/bevy that referenced this issue Jan 22, 2023
# Objective

- fixes bevyengine#6577

## Solution

- simply add `const` to `primary()`.
ItsDoot pushed a commit to ItsDoot/bevy that referenced this issue Feb 1, 2023
# Objective

- fixes bevyengine#6577

## Solution

- simply add `const` to `primary()`.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-Windowing Platform-agnostic interface layer to run your app in C-Feature A new feature, making something new possible
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants