mobilePickPhoto no select button on the preview picture

The place to discuss anything and everything about running your LiveCode on Android

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller

Post Reply
Saman Sjr.
Posts: 49
Joined: Sat Nov 30, 2013 6:40 am

mobilePickPhoto no select button on the preview picture

Post by Saman Sjr. » Wed Oct 24, 2018 5:45 am

Hi,

testing mobilePickPhoto "camera" on galaxy note 9 (android 8.1.0),
the build in camera work as expected but after taking a picture there's no select/confirmation button to save the new picture,
so i have to press the back key to get back to my app. In this case LC get the result as cancel, not the new picture from camera.

any hint of this ?

regards,
Sam

Klaus
Posts: 13823
Joined: Sat Apr 08, 2006 8:41 am
Location: Germany
Contact:

Re: mobilePickPhoto no select button on the preview picture

Post by Klaus » Wed Oct 24, 2018 12:26 pm

Namaste Saman,
Saman Sjr. wrote:
Wed Oct 24, 2018 5:45 am
... but after taking a picture there's no select/confirmation button to save the new picture...
Shame on the developer! Oh, wait, the developer is you, right? So shame on YOU! 8)
Taking a look into the dictionary will help most of the time and would in this case, HINT, HINT!

"mobilepickphoto..." will import a photo into your stack as a new image object, which is quite big and will cover your complete stack in general. So you either need to export/save to disk this image immediatly or make it smaller to keep it on your card for furhter actions.
1. Immediate export:

Code: Select all

...
mobilepickphoto...
if the result = "cancel" then
  exit to top
end if
## Export immediately
## New image has highest layer so it is the LAST IMAGE on the card
export last img to file (specialfolderpath("documents") & "/an_image.jpg") as JPEG
## Get rid of the image
delete last img
...
2. Resize to not cover the complete card:

Code: Select all

...
## maxwidth and maxheight parameter to mobilepickphoto will only work on iOS
## But this works everywhere, and it IS in fact listed in the dictionary entry for MOBILEPICKPHOTO!
set the width of the templateimage to 100
set the height of the templateimage to 100
mobilepickphoto...
reset the templateimage
if the result = "cancel" then
  exit to top
end if
...
Please consult the dictionary if and also if not in doubt!


Best

Klaus

Saman Sjr.
Posts: 49
Joined: Sat Nov 30, 2013 6:40 am

Re: mobilePickPhoto no select button on the preview picture

Post by Saman Sjr. » Wed Oct 24, 2018 3:25 pm

Hi Klaus :twisted:

the problem is before the import process, it's in the camera it self.
after press the shooter on the camera app and there is no "ok" menu to confirm the photo so it can import it to LC stack.
All my stack with mobilepickphoto run well on other phone from android 4 - 6, but not on galaxy note 9 (android 8.1.0).
I attach 2 pictures to show the different, the one that i put blue circle on the bottom left is the "ok" menu after the shooter button is pressed on the camera app that launch by mobilepickphoto "camera". The other picture (2.jpg) is the one from galaxy note 9 (android 8.1.0), as you can see there no "ok" menu after the photo is taken.

Yes, the dictionary is the first place i go when to find hints, but this time no luck :roll:

regards,
Sam
1.jpg
2.jpg

Klaus
Posts: 13823
Joined: Sat Apr 08, 2006 8:41 am
Location: Germany
Contact:

Re: mobilePickPhoto no select button on the preview picture

Post by Klaus » Wed Oct 24, 2018 3:32 pm

Oh, sorry for my false assumption!

I do not own a cellphone or tablet, so I cannot test/confirm this, maybe someone with Android experience will chime in...
Sounds like a bug however!

jacque
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 7227
Joined: Sat Apr 08, 2006 8:31 pm
Location: Minneapolis MN
Contact:

Re: mobilePickPhoto no select button on the preview picture

Post by jacque » Thu Oct 25, 2018 6:01 pm

This is one reason I stopped getting Samsung phones, they change too much of the Android OS. But since they are so popular, it's probably a good idea to report this as a bug. You can't fix it in script.
Jacqueline Landman Gay | jacque at hyperactivesw dot com
HyperActive Software | http://www.hyperactivesw.com

Saman Sjr.
Posts: 49
Joined: Sat Nov 30, 2013 6:40 am

Re: mobilePickPhoto no select button on the preview picture

Post by Saman Sjr. » Fri Oct 26, 2018 3:40 pm

Yup, many of my clients use samsung for their phone.
I'll try with cameraControl

thanks guys

simon.schvartzman
Posts: 641
Joined: Tue Jul 29, 2014 12:52 am
Location: Brazil

Re: mobilePickPhoto no select button on the preview picture

Post by simon.schvartzman » Thu Jun 27, 2019 8:57 pm

Hi Saman, were you able to fix this? How?

I'm facing exactly the same problem with an App generated with LC 9.0.4 on a Samsung 6j running Android 9.0.

Help needed!

Thanks
Simon
________________________________________
To ";" or not to ";" that is the question

strongbow
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 135
Joined: Mon Jul 31, 2006 1:39 am
Location: New Zealand, Australia, Germany, Japan
Contact:

Re: mobilePickPhoto no select button on the preview picture

Post by strongbow » Fri Jun 28, 2019 6:07 am

This (or similar) has been reported in the QCC as Bug 22054 :

https://quality.livecode.com/show_bug.cgi?id=22054

Hoping this is resolved sometime soon!

Saman Sjr.
Posts: 49
Joined: Sat Nov 30, 2013 6:40 am

Re: mobilePickPhoto no select button on the preview picture

Post by Saman Sjr. » Sat Jun 29, 2019 3:37 am

Hi Simon,

currently I've solved the problem bydown grade my app to LC 8.x
It's seem like the problem is caused by the SDK API 26 of LC 9.x
As far as i know, LC 9.0 still using SDK API 15 same as LC 8.0, so i think temporary we can solved this by using LC 8.x or 9.0 until they fix the bug.

hope this help,
simon.schvartzman wrote:
Thu Jun 27, 2019 8:57 pm
Hi Saman, were you able to fix this? How?

I'm facing exactly the same problem with an App generated with LC 9.0.4 on a Samsung 6j running Android 9.0.

Help needed!

Thanks

simon.schvartzman
Posts: 641
Joined: Tue Jul 29, 2014 12:52 am
Location: Brazil

Re: mobilePickPhoto no select button on the preview picture

Post by simon.schvartzman » Sat Jun 29, 2019 10:36 pm

Thanks Sam.

Downgrading to LC 8.0 or 9.0 may make the App loose some important functionalities for all phones/brands and could be worst than the original problem...

Hi LC are you listening? Can you fix it? The problem was reported for the first time in October last year.

Best!
Simon
________________________________________
To ";" or not to ";" that is the question

Post Reply

Return to “Android Deployment”