Masm32 SDK description, downloads and other helpful links
Started by hutch--, June 26, 2019, 05:29:09 AM
Quote from: hutch-- on June 27, 2019, 02:13:42 PMI have done a mod on the original to make it more flexible, by detecting if the app has the focus or not, the priority and poll duration is changed so it faster when it has the focus and goes into low priority mode with a slower polling rate when it does not have the focus. The duration difference is 100 ms when it has the focus (10 samples per second) and 500 ms when it has not (2 sample per second).If you have a need for pesky little critters like this without choking your computer with too much overhead, techniques like this are useful in keeping the overhead down.This is the additional code to do this. .case WM_ACTIVATE ; ------------------------------------------------------- ; change delay and priority depending on activation state ; ------------------------------------------------------- .switch wParam .case 0 ; 0 = WA_INACTIVE LowPriority mov delay, 500 rcall SendMessage,hStat,SB_SETTEXT,0," Low Priority Mode" .case 1 ; 1 = WA_ACTIVE NormalPriority mov delay, 100 rcall SendMessage,hStat,SB_SETTEXT,0," Startup Normal Priority" .case 2 ; 2 = WA_CLICKACTIVE NormalPriority mov delay, 100 rcall SendMessage,hStat,SB_SETTEXT,0," Normal Priority Mode" .endsw
Quote from: hutch-- on June 29, 2019, 09:12:54 AMI think you can set that in Win10. I used to know how to do it in XP but that is some years ago.
Quote from: jj2007 on June 30, 2019, 07:04:56 AMIt builds "out of the box", but the behaviour is a bit ambiguous. Left-click does nothing, right-click shows a menu. When exiting, the icon is still in the tray and disappears only when you hover over it. I see that with other (non-Masm) applications, too.
Quote from: hutch-- on June 30, 2019, 12:09:48 PMI guess no-one read the reason why I stuck with the task bar, its BIG enough to display the current memory status from the task bar without having to click on it where a half sized tray icon cannot display that much data. The lag on exit is Windows taking its time to clean up a running thread and it effects many applications. The left click is reserved for the three buttons and there is nothing to right click for, the memory status is already displayed on the interface.Code is written on the KISS process, Keep It Simple Stupid.> there is an error in the code, so the logic breaksI did not understand this one.
Quote from: AW on June 29, 2019, 11:22:00 PMQuote from: hutch-- on June 29, 2019, 09:12:54 AMI think you can set that in Win10. I used to know how to do it in XP but that is some years ago.I am sure they have invented some UWP wrapper for the old way people used to do it.https://www.codeproject.com/Articles/74/Adding-Icons-to-the-System-TrayBut I think there are posts in this forum about that.
Quote from: hutch-- on June 30, 2019, 08:47:06 PMNow there are certainly ways of making it prettier and flashier but it also makes it fatter, slower and takes up a lot more screen space which is the antithesis of what I wanted it to do, have a small interface when it was running and a lot smaller when minimised. In the future there will be more and more very large memory applications, video processing is one that comes to mind but of course there are many others, the database folks, CAD, some games etc ... and being able to track active memory usage is important for the developer.