SOLVED - How to capture drag and drop tab opening new window

PDF-XChange Editor SDK for Developers

Moderators: TrackerSupp-Daniel, Tracker Support, Paul - Tracker Supp, Vasyl-Tracker Dev Team, Chris - Tracker Supp, Sean - Tracker, Ivan - Tracker Software, Tracker Supp-Stefan

Forum rules
DO NOT post your license/serial key, or your activation code - these forums, and all posts within, are public and we will be forced to immediately deactivate your license.

When experiencing some errors, use the IAUX_Inst::FormatHRESULT method to see their description and include it in your post along with the error code.
sherron_docit
User
Posts: 12
Joined: Wed Apr 07, 2021 5:24 pm

SOLVED - How to capture drag and drop tab opening new window

Post by sherron_docit »

Hi there,

I have an application that uses the SDK.

I currently have an issue regarding dragging and dropping a document tab outside of the window spawning a new instance.

This feature is great, but the issue is that the new window has none of our customizations and is just the default PDF X-Change Editor.

In summary:
• Step 1 - Drag and drop a document tab outside of application
• Step 2 - Document opens up in a new instance - but it is the default application.

Is there any way to capture the event of drag and dropping a tab outside of the current window?

Ideally I would like to capture this and then open a second instance of my custom PDF editor with all of the correct branding and feature restrictions.

Thanks,

Sam
Last edited by sherron_docit on Thu Nov 04, 2021 3:56 pm, edited 1 time in total.
zarkogajic
User
Posts: 1372
Joined: Thu Sep 05, 2019 12:35 pm

Re: How to capture drag and drop tab opening new window

Post by zarkogajic »

Hi Sam,

To disable "tab out" thingie you can implement IEventHandler as in:

https://forum.pdf-xchange.com/viewtopic.php?f=66&t=33110&p=136767&hilit=IEventHandler#p136767

As for event to capture the tab out (creation of a new MainFrame) - maybe you can try (similar to above) with listening to "e.mainFrame.initialized" (I have not tested this).

-žarko
sherron_docit
User
Posts: 12
Joined: Wed Apr 07, 2021 5:24 pm

Re: How to capture drag and drop tab opening new window

Post by sherron_docit »

Hi Zarko,

Unfortunately disabling the 'tab out' feature is not an option as users like the feature.

I will try and see if that works to capture it.

Thanks for the speedy reply!

Sam
sherron_docit
User
Posts: 12
Joined: Wed Apr 07, 2021 5:24 pm

Re: How to capture drag and drop tab opening new window

Post by sherron_docit »

I was able to capture the event 'e.mainFrame.initialized' which is being fired when the new window is created.

This is a great step in the right direction.

Now that I am able to capture it...
I need to find a way to access the document that is being opened, open that document in my custom editor, then kill the PDF-XChange Editor process.

This is an entirely different issue though, so I will mark this as solved for now and open another post if I need help with this.

Thanks,

Sam
User avatar
Tracker Supp-Stefan
Site Admin
Posts: 17949
Joined: Mon Jan 12, 2009 8:07 am
Location: London

SOLVED - How to capture drag and drop tab opening new window

Post by Tracker Supp-Stefan »

:)