frigocoder / frigotab Goto Github PK
View Code? Open in Web Editor NEWAlt-Tab replacement application.
License: GNU General Public License v3.0
Alt-Tab replacement application.
License: GNU General Public License v3.0
Something about GetWindowRect and DPI awareness causes the background image to give wrong dimensions. As a result the background image, sometimes along with icons, are stretched horizonally and pixelated.
We can unify overlay drawing to one big ass Bitmap. This removes the need for ApplicationWindow classes to extend (Frigo)Form. We only need one or two forms, depending on whether we can capture mouse inputs on a Layered form.
JetBrains Rider selects texts according to the mouse events that should have been received only by FrigoTab.
Maintain thumbnails for the entire window tree of an application, rather than only one representative window. Currently we only show the last active window, whereas the default Alt-Tab only shows the ancestor window.
Related to #21 WindowFinder overhaul.
Low level mouse hook results in a stop in mouse event processing for other purposes. Replace it with normal mouse events.
Tool windows that use blur effects are displayed without the blur. We would need direct display of said toolbars rather than relying on the DWM thumbnail API to display them. This would need a major overhaul.
Low level keyboard hooks are not triggered from a Remote Desktop Connection. The destination computer gets them rather than the alt-tab.
We first construct our form, and only then switch from the fullscreen application to our form. This triggers a resolution change, which causes our form to be redrawn. Find a way to prevent this double draw.
Windows 10 changed EnumWindows behavior. For some reason now it returns Windows Shell Experience Host and two mystery windows as well.
FrigoTab at the moment enumerates applications with EnumWindows, based on WindowExStyles.AppWindow, ToolWindow, and other flags.
Unfortunately this is inappropriate, the standard Alt-Tab and Win-Tab implementation behaves very differently. Raymond Chen wrote a blog entry about it: https://blogs.msdn.microsoft.com/oldnewthing/20071008-00/?p=24863
Several side effects arise as a result:
Find out how do Alt-Tab and Win-Tab exactly work, and change my implementation to conform to them.
If Eclipse has multiple windows open on multiple displays, then FrigoTab only shows the thumbnail of one window on one display. This makes it impossible to switch between windows if they are on different displays.
Mind you however that Windows Alt-Tab and Win-Tab behaves in similar manner, and also that in-application window switching should not be the responsibility of a task switcher, so this might not be a full-fledged bug.
Steps to reproduce:
Visual Studio uses some kind of hack to draw its borders. FrigoTab draws it as a BackgroundWindow on top of the background, and it looks especially ugly.
Windows automatically changes resolution when we switch to the alt-tab application from a fullscreen game. This is unnecessary, we could draw thumbnails without changing resolution.
We could avoid activating SessionForm to prevent the screen change, however this might mess with controls.
Fullscreen games (are said to) have complete control over the video card, as far as I know there is no easy and reliable way to draw overlays on them. Only doing some heavy hacks like injecting DLLs would work.
RDC disables DWM on the remote computer, which we require.
Terminated applications are still visible in the session as empty thumbnails. Create a callback that removes them.
Microsoft changed the behavior of EnumWindows, it only lists Desktop Apps now, but not Metro apps.
If the start menu is open when alt-tabbing, there are two tool windows that appear in the background. One is titled "Start menu", the other has the same title as the name of the logged in user.
Windows 7 can disable DWM composition to maintain compatibility with certain applications. Unfortunately it does not enable it when the application is minimized, and as a result our alt-tab form contains empty thumbnails.
I tried re-enabling composition at WM_DwmCompositionChanged and at the start of BeginSession, but Windows 7 won't budge.
Thankfully it is not a problem for Windows 8 and newer since composition is always enabled.
Still, it would be nice to find a solution that forces Windows 7 to keep composition enabled.
IBM Notes creates windows for every control. This fools FrigoTab into thinking there are multiple applications.
In order to fully fix this, we have to rework our ApplicationWindow system. We have to group windows of an application together and create overlapping thumbnails for them.
More information on how alt-tab works by Raymond Chen: https://blogs.msdn.microsoft.com/oldnewthing/20071008-00/?p=24863
Alt-tabbing from Media Player Classic has the side effect of hiding window numbers.
We switch to fullscreen applications before we end our session. This causes a resolution change, and subsequent double draw of our form. Find a way to circumvent this.
Responsible code in SessionForm:
_applications.Selected.Application.SetForeground();
EndSession();
Note however that you can not EndSession before SetForeground, because then the previous application gets focus for a moment.
We should either use Z ordering tricks, or preferably, introduce another state apart from _active=true or false, so DisplayChange ignores this state. Alternatively, set _active=false temporarily while running SetForeground.
GIMP toolbars are registered as WS_EX_TOOLWINDOW and as such they are shown as background. Find a way to reliably tell apart AppWindows and ToolWindows.
Media Player Classic stays on top and in focus if "Always On Top" is on. This is especially bad if it is fullscreen. We have to find a way to override this behavior so FrigoTab is on top and in focus.
Fullscreen games are displayed in thumbnails, except if their resolution is equal or larger than the desktop resolution. This is a fault of the DWM thumbnail implementation, I have no idea how to fix it.
Capturing DirectX and OpenGL applications via other methods are difficult as well.
FrigoTab forces resolution change by SendMessage WM_ActivateApp to the foreground application.
Unfortunately this waits for the target application, so if it hangs, it can delay execution of FrigoTab.
Try to change it to PostMessage or callback or timeout.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.