Active panel - left or right?

A place where plug-in developers can share their knowledge and experience.
Locked
pepak
Posts: 44
Joined: Wed May 03, 2006 5:10 pm

Active panel - left or right?

Post by pepak »

Is there a way to determine which panel (left or right) is active and which is passive?
User avatar
DrKnS
Posts: 32
Joined: Thu Feb 23, 2006 6:48 pm
Contact:

Post by DrKnS »

Use FCTL_GETPANELINFO command and look at PanelInfo::PanelRect.
pepak
Posts: 44
Joined: Wed May 03, 2006 5:10 pm

Post by pepak »

Hmm, that doesn't sound too reliable. I'll rather try to find a way to avoid needing this information.
User avatar
t-rex
Admin
Posts: 417
Joined: Sun Mar 20, 2005 6:10 pm
Location: Ashdod
Contact:

Post by t-rex »

You shouldn't need to know which panel is which in a plugin.
pepak
Posts: 44
Joined: Wed May 03, 2006 5:10 pm

Post by pepak »

Not for the plugin itself, but it is important for its user.
User avatar
t-rex
Admin
Posts: 417
Joined: Sun Mar 20, 2005 6:10 pm
Location: Ashdod
Contact:

Post by t-rex »

Can you give more information?
pepak
Posts: 44
Joined: Wed May 03, 2006 5:10 pm

Post by pepak »

Sure. I am thinking about writing a Synchronize Folders plugin and it would be rather useful to display that "this file goes from the left panel to the right".
User avatar
t-rex
Admin
Posts: 417
Joined: Sun Mar 20, 2005 6:10 pm
Location: Ashdod
Contact:

Post by t-rex »

Hm, quite logical. I think we can manage to add a PFLAGS_PANELLEFT and PFLAGS_PANELRIGHT to PanelInfo.Flags. Please open a ticket for this in Mantis.
User avatar
t-rex
Admin
Posts: 417
Joined: Sun Mar 20, 2005 6:10 pm
Location: Ashdod
Contact:

Post by t-rex »

Here:
http://farmanager.com/farbugs/Far171.b2348.x86.rar

Flags PFLAGS_PANELRIGHT and PFLAGS_PANELLEFT for PanelInfo.Flags.
nightroman
Posts: 15
Joined: Wed Mar 14, 2007 3:23 am

Post by nightroman »

Is not it enough to introduce only one flag, say, PFLAGS_PANELLEFT? If it is set then the panel is left, otherwise it is right...

Of course, if both flags PFLAGS_PANELRIGHT and PFLAGS_PANELLEFT exist and both are not set it gives us kind of 3rd state possible ("unknown" or something). But do we really need this?
pepak
Posts: 44
Joined: Wed May 03, 2006 5:10 pm

Post by pepak »

Cool, thanks.
Locked