Adding custom button to PE SDK UI

Michael Pravilov

I have some trouble to find information how to extend default PhotoEditor SDK. I need to add a button to default UI panel where cancel and accept buttons are located. Is there any way to do this? Thank you for your help!

Sven Nähler

Yes you can.

  1. Extend the View Class ly.img.android.ui.widgets.ImgLyTitleBar

  2. Overload this layout (this means, put this layout it in your Application res folder without rename it) and replace ly.img.android.ui.widgets.ImgLyTitleBar with your class. https://github.com/imgly/pesdk-android-demo/blob/master/default_res_files/res/layout/imgly_activity_photo_editor.xml

  3. Add your button, by overload this layout https://github.com/imgly/pesdk-android-demo/blob/master/default_res_files/res/layout/imgly_widget_actionbar.xml

  4. Add your button logic, in your ImgLyTitleBar extending class.

Best, Sven

Collected from the Internet

Please contact [email protected] to delete if infringement.

edited at
0

Comments

0 comments
Login to comment

Related