Custom Widget and images

Post your questions and help other users.

Moderator: Martin

Post Reply
lchiocca
Posts: 69
Joined: 15 Aug 2013 10:11

Custom Widget and images

Post by lchiocca » 18 Mar 2015 07:31

Hi Martin,

I'm not sure how this is supposed to work - I can't seem to make it work. So let me quickly explain the setup and what I'm doing (wrong):
I've got a OnePlus One running CM11S (xposed installed, but that shouldn't be an issue). I've created a custom widget and want to add an image. So I create a new image layer by pressing the "rectangle with a plus" and choose "Image" from the "Add Element" dialog. After that I get a "Complete action using" dialog that shows be all the "custom app icon pack" applications that I have installed. If I choose one of them, I get to choose an icon from the multitude of icons in the pack. So I choose one and I fall back into automagic. The problem is that in the image section, there is no image path, nor does the selected icon show up in the preview at the top. What am I doing wrong?

Thanks
Loris

User avatar
Martin
Posts: 4468
Joined: 09 Nov 2012 14:23

Re: Custom Widget and images

Post by Martin » 20 Mar 2015 10:57

Hi,

It's probably a limitation of Automagic. What kind of icon pack are you using? Automagic mostly only supports to pick images available on the external storage but not images that are bundled within another app.

Regards,
Martin

lchiocca
Posts: 69
Joined: 15 Aug 2013 10:11

Re: Custom Widget and images

Post by lchiocca » 20 Mar 2015 14:40

I'm using "Sticko" (https://play.google.com/store/apps/deta ... icko&hl=en)... interesting enough, I don't get the gallery or any other application that should provide me images. What kind of intent are you sending?

User avatar
Martin
Posts: 4468
Joined: 09 Nov 2012 14:23

Re: Custom Widget and images

Post by Martin » 21 Mar 2015 11:11

I'm currently using an ACTION_PICK-intent to pick images from the external storage that was supported quite well on older devices but seems to be somewhat limited since Google introduced the new documents provider stuff.
It seems that Sticko even returns a resource and not a path on the external storage. I'll change the image picker of the widget so that it accepts also such URIs.
In the meantime you could use an action Start Activity with action android.intent.action.PICK and mime type image/*, check Wait for result and use an action Copy Text to Clipboard: {data_string} and then paste the URI into the path field of the widget image element.

lchiocca
Posts: 69
Joined: 15 Aug 2013 10:11

Re: Custom Widget and images

Post by lchiocca » 23 Mar 2015 09:25

Thanks Martin... that worked!

Hope you didn't have to buy sticko to be able to verify this

Post Reply