[fpc-pascal] File Association and opening with already running app
parmaja at gmail.com
Fri Apr 5 11:43:53 CEST 2013
Please tell us you success story when you done
For me i am using SimpleIPC
look at AnotherInstance and MainUnit.pas
Works good in Windows but not tested in Linux.
On Thu, Apr 4, 2013 at 12:08 PM, Graeme Geldenhuys
<graeme at geldenhuys.co.uk>wrote:
> I'm posting it here, but it is not a Lazarus question, but a general GUI
> app (created with FPC) question.
> Example of what I want to achieve. Say I have gEdit (Gnome editor) open
> and have a file loaded. Now if I am in a console and type 'gedit
> someotherfile.txt' [or double click a text file in Nautilus], it doesn't
> start a new instance of gedit, the existing instance opens the new file
> - gedit supports multiple opened files in a tabbed view.
> How do they accomplish this? I would like to implement something like
> that for fpGUI, and it must work under all fpGUI supported "desktop"
> I know under Windows you can check if an instance of an application is
> already running, and stop your current instance. Still not sure how to
> transfer the "open a new file" action to that existing instance.
> As for Linux, FreeBSD etc, I have no clue how to do it. For those not in
> the know, fpGUI is based directly on GDI or XLib (not Qt, GTK etc).
> - Graeme -
> fpGUI Toolkit - a cross-platform GUI toolkit using Free Pascal
> fpc-pascal maillist - fpc-pascal at lists.freepascal.org
I am using last revision of Lazarus, FPC 2.6 on Windows XP SP3
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the fpc-pascal