NO

Author Topic: Allow more than 1 instance of poide  (Read 4232 times)

RJP Computing

  • Guest
Allow more than 1 instance of poide
« on: October 04, 2005, 07:08:48 pm »
It is really helpful to have 2 or more ide's open so that I can debug two applications at the same time. I really needed to do this for proper dll debugging and a client / server app I am working on.

It would be perfect if double clicking a workspace would be what opened a new instance of the IDE and just a file would go into the ide that is already open, if there is one.

Thanks

Offline Pelle

  • Administrator
  • Member
  • *****
  • Posts: 1974
    • http://www.smorgasbordet.com
Allow more than 1 instance of poide
« Reply #1 on: October 04, 2005, 10:35:23 pm »
I added a /x option to POIDE in v4.0 final - it allows you to bypass the single instance check (use with caution).

The workspace thing can probably be handled best by an add-in.

Pelle
/Pelle

Offline TimoVJL

  • Global Moderator
  • Member
  • *****
  • Posts: 1850
Allow more than 1 instance of poide
« Reply #2 on: October 04, 2005, 10:50:33 pm »
Quote

It would be perfect if double clicking a workspace would be what opened a new instance of the IDE


Try this with new POIDE 4.0
Code: [Select]

Windows Registry Editor Version 5.00

[HKEY_CLASSES_ROOT\PellesCWorkspaceFile\shell\open\command]
@="\"C:\\Program Files\\PellesC\\bin\\poide.exe\" /x \"%1\""

It may work

EDIT 2005-10-06
------------------
Code: [Select]

Windows Registry Editor Version 5.00

[HKEY_CLASSES_ROOT\PellesCProjectFile\shell\open\command]
@="\"C:\\Program Files\\PellesC\\bin\\poide.exe\" /x \"%1\""

------------------

After that, this Add-In opens project from project menu with ShellExecute()
May the source be with you

tiwag

  • Guest
Allow more than 1 instance of poide
« Reply #3 on: October 05, 2005, 07:19:38 am »
Quote from: "Pelle"
I added a /x option to POIDE in v4.0 final - it allows you to bypass the single instance check (use with caution)...

what's the dangerous thing with using multiple instances ?

RJP Computing

  • Guest
Allow more than 1 instance of poide
« Reply #4 on: October 05, 2005, 02:20:49 pm »
Quote from: "Pelle"
...
The workspace thing can probably be handled best by an add-in.
...
Can you give a quick outline of what you are thinking. I would love to try and write one. I am just not sure the steps or facilities of the add-in SDK that would help in such a case.

Thanks.

JohnF

  • Guest
Allow more than 1 instance of poide
« Reply #5 on: October 05, 2005, 04:08:45 pm »
You can use this to start extra instances

D:\PellesC\Bin\poide.exe /x

John

Offline Pelle

  • Administrator
  • Member
  • *****
  • Posts: 1974
    • http://www.smorgasbordet.com
Allow more than 1 instance of poide
« Reply #6 on: October 05, 2005, 06:23:55 pm »
Quote from: "tiwag"
what's the dangerous thing with using multiple instances ?

Synchronization - when opening the same project in more than one instance and making changes to the same project file, for example.

Pelle
/Pelle

Offline Pelle

  • Administrator
  • Member
  • *****
  • Posts: 1974
    • http://www.smorgasbordet.com
Allow more than 1 instance of poide
« Reply #7 on: October 05, 2005, 06:33:09 pm »
Quote from: "RJP Computing"
Can you give a quick outline of what you are thinking. I would love to try and write one. I am just not sure the steps or facilities of the add-in SDK that would help in such a case.

For example: start from the HexView add-in sample, replace AddIn_OpenDocument() with a call to CreateProcess for POIDE using the /x option, probably the /n option, and any filename. You start through the context menu, not a double-click, but maybe enough.

Note that pcvData will be NULL for the project target (xyz.EXE, xyz.DLL) in source file view - this works best from the target file view in the project tree (use button over the project tree...).

Pelle
/Pelle