<div dir="ltr"><div><div>It depends if your app is configured (via .desktop file) to be running as single instance or not;<br></div>and that is related to the launcher  (which is enforced on SFOS btw); <br>see "How can I disable single-instance launching?" under <a name="4.5.0" href="https://harbour.jolla.com/faq#4.5.0" class=""></a><a href="https://harbour.jolla.com/faq">https://harbour.jolla.com/faq</a>).<br><br><br></div><div>If the application is already open, lipstick will just raise the previously opened window.<br></div><div>It is a good question about what the app does with the arguments...<br><br></div><div>Best,<br></div><div>tortoisedoc<br></div><div><br></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Fri, Oct 23, 2015 at 12:09 AM, r0kk3rz <span dir="ltr"><<a href="mailto:r0kk3rz@gmail.com" target="_blank">r0kk3rz@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div><div><div><div><div><div><div><div>Hi Developers,<br><br></div>How does Lipstick handle xdg-open in cases when the app is already running?<br><br></div>When the app isn't running, I can currently open a file through xdg-open, which opens the app and passes in the file url as a command line parameter.<br><br></div>I expected that upon subsequent xdg-open calls, it would also call the program with command line parameter, which I could use to check for an open instance on dbus, fire off a method call, and close again. Sounds easy, but this doesn't seem to be the case.<br><br></div><div>If the app is already open, it comes into focus, and presumably needs some kind of an interface to get the open args?<br></div><div><br><br></div>Watching dbus-monitor, i can see the following happen as i am trying to open a file<br><br>method call sender=:1.394 -> dest=org.freedesktop.DBus serial=1 path=/org/freedesktop/DBus; interface=org.freedesktop.DBus; member=Hello<br>signal sender=:1.394 -> dest=(null destination) serial=2 path=/org/gtk/gio/DesktopAppInfo; interface=org.gtk.gio.DesktopAppInfo; member=Launched<br><br></div>which has a parameter with my file url that i'm trying to open. And then lipstick brings my app into focus with this straight after<br><br>method call sender=:1.390 -> dest=org.nemomobile.lipstick serial=3 path=/WindowModel; interface=local.Lipstick.WindowModel; member=launchProcess<br>   string "/usr/bin/harbour-sirensong"<br><br></div>Any information about how this is supposed to work?<br><br></div>Regards,<br><br></div>Lewis Rockliffe<br></div>
<br>_______________________________________________<br>
SailfishOS.org Devel mailing list<br>
To unsubscribe, please send a mail to <a href="mailto:devel-unsubscribe@lists.sailfishos.org">devel-unsubscribe@lists.sailfishos.org</a><br></blockquote></div><br></div>