This is suspend/resume behavior. A different app gained control that means 
stop() was invoked. If your app is actually killed during that time destroy 
MIGHT be called too. 

If the app is cold launched you will get init(Object) then start() with the 
app args.
If the app is warm started only the start() method is invoked with the app 
args set into place.

If the incoming URI is a file it should be accessible at least as 
read-only. You should be able to use standard file system APIs to read it.

On Tuesday, September 22, 2020 at 5:06:41 PM UTC+3 P5music wrote:

> Thanks for the response.
> I need two questions to be addressed:
> 1-Said that the start() method is called, this means that it is like the 
> app starts again and what is going on (or was going on when it went to 
> background) is lost? (except for that some methods are called before it 
> happens to let the app save its state)
> 2-How the incoming url has to managed? I mean, permissions, access to 
> filesystem and so on.
> Thanks in advance
> Regards
>
> Il giorno martedì 22 settembre 2020 alle 14:00:59 UTC+2 Steve Hannah ha 
> scritto:
>
>> Yes.  If the app is already started and it receives a call to open it 
>> with an argument, the app's start() method will be run again, and this time 
>> the AppArg will contain the new value.
>>
>> On Tue, Sep 22, 2020 at 2:39 AM 'P5music' via CodenameOne Discussions <
>> [email protected]> wrote:
>>
>>> I read in the documentation that it is possible to let the user open the 
>>> CodenameOne app by means of selecting an associated file type.
>>> The instruction (let aside all settings necessary) is something like
>>> String arg=Display.getInstance().getProperty("AppArg",null);
>>> From the documentation I see that this is at startup, that is, the app 
>>> gets launched with that if the user wants the file. Value is null when the 
>>> app is started by tapping on its icon, if I am not wrong.
>>>
>>> But what if the app is already running, in both case it's in foreground 
>>> or in background?
>>>
>>> Thanks in advance
>>>
>>> -- 
>>> You received this message because you are subscribed to the Google 
>>> Groups "CodenameOne Discussions" group.
>>> To unsubscribe from this group and stop receiving emails from it, send 
>>> an email to [email protected].
>>> To view this discussion on the web visit 
>>> https://groups.google.com/d/msgid/codenameone-discussions/bc969123-5366-4785-9eca-44ed804d8e19n%40googlegroups.com
>>>  
>>> <https://groups.google.com/d/msgid/codenameone-discussions/bc969123-5366-4785-9eca-44ed804d8e19n%40googlegroups.com?utm_medium=email&utm_source=footer>
>>> .
>>>
>>
>>
>> -- 
>> Steve Hannah
>> Software Developer
>> Codename One
>> http://www.codenameone.com
>>
>

-- 
You received this message because you are subscribed to the Google Groups 
"CodenameOne Discussions" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/codenameone-discussions/7f05941e-01b6-4467-adac-674b55fc16d3n%40googlegroups.com.

Reply via email to