Default color #67
-
Can I add a button "Default" as an action button to the dialog? I would like on press of that button the color picker to jump to default color. I tried it with setting the value that is defined for "pickerColor" in setState, but with no success. Actually, the color was set, but it was not reflected in the dialog. If I selected the color it was the default, but the dialog did not show it. That would be useful, because users easily mess up colors, and it is difficult to return to default again. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
The problem is my inexperience with Flutter, and not the color picker. I found the solution to put the dialog in a StatefulBuilder. Now it works perfectly. |
Beta Was this translation helpful? Give feedback.
The problem is my inexperience with Flutter, and not the color picker. I found the solution to put the dialog in a StatefulBuilder. Now it works perfectly.