开发者

Color Picker Button

开发者 https://www.devze.com 2023-02-21 23:21 出处:网络
I am wondering how i would go about creating a button which changes colors based on the current selection of a color picker wheel. I开发者_开发知识库 already have the color wheel working but i am stuc

I am wondering how i would go about creating a button which changes colors based on the current selection of a color picker wheel. I开发者_开发知识库 already have the color wheel working but i am stuck on the button. An example of this is in the QuickOffice app. (An image can be seen by going to http://www.quickoffice.com/ and clicking the android tab in the photo gallery)


I'll assume you're using the color picker dialog from API demos.

You could implement the OnColorChangedListener inside the activity so that it changes the color of a ShapeDrawable, that you'll use as drawable in an ImageButton.

0

精彩评论

暂无评论...
验证码 换一张
取 消