Skip to content

Language Switch Example Request #23

Answered by maeddin
taextreme asked this question in Q&A
Discussion options

You must be logged in to vote

I apologize for the late reply. I think I did it with the country_icons package. If you want an exact implementation, I can look it up too.

I didn't include the top two GIFs in my example because they require external packages.

EDIT: Here is the code for the flag which I used for the demo in the GIF. You can put this in the builder of the switch. Since I haven't touched this code for a long time, I can't guarantee that it works without problems, so feel free to give feedback if it works for you 😁.
If you want the code for the whole switch, I would have to assemble it myself first, since I have it all encapsulated.

Widget flag(Locale locale) {
  return FractionallySizedBox(
      widthFact…

Replies: 1 comment 5 replies

Comment options

You must be logged in to vote
5 replies
@taextreme
Comment options

@maeddin
Comment options

@taextreme
Comment options

@maeddin
Comment options

@maeddin
Comment options

Answer selected by taextreme
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants