Quick Drop Enthusiasts

cancel
Showing results for 
Search instead for 
Did you mean: 

Show Open VIs QD.zip

Over on this thread it was mentioned how LabVIEW development can get unorganized when you have many windows open at the same time.  The project explorer helps with this by organizing the project how you see fit, but still there are times when I have 30 VIs open, each with a block diagram and front panel.  The Windows taskbar does what it can to make organizing these windows easier but for me I usually end up finding my top level VI then drilling down to the function I know is already open.  This is because our minds are very visual and what I most recognize is the VI icon of the function I am looking for.

Some have asked for an Alt+Tab function like the one Windows gives showing the VI icon for each.  I have made this quick drop function trying to replicate some of that functionality.  Add this quick drop function to your <vi.lib>\resource\dialog\QuickDrop\plugins folder.  Then by default you press <CTRL>+E to show a dialog with the VIs whos front panels are currently open.  From here you can click the VI to open it, or right click to get options like Open Front Panel, Open Block Diagram, Open Explorer, and Abort VI where applicable.  By adding the Shift modifier it will simply open an explorer window the the VI that quick drop was opened on.  This functionality was seen over here.

If you leave the dialog open that shows the list of VIs open, you can perform another quick drop <CTRL>+E to refresh the list of open VIs, and bring that dialog back to the front.

This quick drop plugin will only work in Windows for a couple reasons.  The icon resizing is done by using .Net GDI functions because the LabVIEW Zoom property makes images look like junk.  This is also Windows only because of the explorer window option.

Also note that the VIs show will be for all application instances.  I thought about breaking it up with a drop down but this is a start and that can be added later if needed.

This relies on several OpenG packages, Error, File, Array, String, Application Control, and maybe a few others.

Message 1 of 13
(11,471 Views)

Well this is embarassing.  I found a minor bug.  You'll find that some times the mouse maybe over a VI but the blue box is over a different VI.  Because of the centering code I put in there it thinks the mouse is over a different subVI.  This can be fixed with an offset based on the centering code, but for now just know that the VI with the box around it is the one that will be selected if you click.

0 Kudos
Message 2 of 13
(8,006 Views)

Now I know where "Hoovahh" came from.

Jim
You're entirely bonkers. But I'll tell you a secret. All the best people are. ~ Alice
For he does not know what will happen; So who can tell him when it will occur? Eccl. 8:7

Message 3 of 13
(8,006 Views)

Oh no my secret identity is revealed. And I suposed I can determine that your name must be Joseph Carnegie Mody.

0 Kudos
Message 4 of 13
(8,007 Views)

This is going to save me so much time.  I'm constantly drilling navigating my classes and projects to find some VI that's already open.  Thaaaaaaanks Hoooooooooovahhhh!

Message 5 of 13
(8,008 Views)

Thank you for this plugin!

I modified it on my PC to open Block Diagram when I click to VI icon. (I don't like Front Panels = I don't need them)

0 Kudos
Message 6 of 13
(8,008 Views)

This is looking like a very nice tool.  Yeah, that centering bug you mentioned could be a pain.  I'm sure you'll knock that out soon enough when you have time to play again.

A note from quickly looking over the code:  You used the OpenG Conditional Indexing Terminals VI with a cluster so you then had to use the Variant to Data to get back to the cluster.  Since this was developed in 2012, you should just use the built-in conditional tunnel on the FOR loop.  It will save memory allocations and be a lot easier to read.


GCentral
There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5
0 Kudos
Message 7 of 13
(8,008 Views)

Yes I've fixed the issue internally.  Turns out it wasn't because the centering, it was because the title bar is about 42 pixels, and that causes the shift vertically.  I can read the size of the titlebar using a property and then adjust properly, or I can read the property of the picture control, to get the X and Y coordinates in pixels instead of mouse position in the panel.

Thanks for the advice on OpenG, but this code actually is developed in 2011 where the conditional terminal doesn't exist.

I do plan on updating it with the bug fix, and another change where the resize is optionally done by the native "Zoom" of the picture control.  I tried it on larger images and it doesn't look very good, but with the small icon it doesn't look bad, just the GDI resize looks cleaner with the aliasing it does.  Generally I've seen up to about 300ms to get the VI references and images, then another 500ms or so to perform the resize using the GDI.  This is relativly quick but some may want it to be almost instant.

0 Kudos
Message 8 of 13
(8,008 Views)

I don't understand why you are resizing VI icons? I would say that my brain know VI icon of specific size and when it is resize then it is different image = different VI.

This is my opinion.

0 Kudos
Message 9 of 13
(8,008 Views)

The resize of course can be removed.  I wanted to resize for a couple reasons none of which are too compelling.  I didn't want the window to waste any space.  When I Alt+Tab the winodows take up the full space.  This could be changed to instead resize the window I guess, but I also wanted the window to be resizable because that's how all windows should be.  I also wasn't sure if I would have a difficult time selecting the right 32 by 32 pixel image in a grid of many of them so allowing the window to be bigger and make the icons bigger seemed like it would work.

When/If I ever get around to making an update this could also be an option.

0 Kudos
Message 10 of 13
(8,008 Views)