|
Post by leet on Feb 12, 2020 4:33:32 GMT -8
Win9x-XP has 2px gap!, not 1px. 7+ TT recommends setting 2px to those who want classic behavior. That's odd. I took a screenshot from a Win98SE VM and it had a 1px gap between icons.
|
|
|
Post by leet on Feb 12, 2020 4:46:10 GMT -8
leet could you update the github repo? i'm curious about the systray implementation It's actually quite weird:
First I get a handle to the systray (just some repetitive getting of child windows) The object the handle refers to is a Win32 toolbar, so I can use the TB_BUTTONCOUNT message to get the number of buttons When I know the button count I can loop through button indexes and send the TB_GETBUTTON message to get information about the button. (Way harder then it sounds: TB_GETBUTTON only works if you specify a memory address in the processes memory space, so I first need to allocate memory inside of explorer.exe and then use some more API calls to copy the object into my own processes memory) When I have the TBBUTTON object, I can use the memory object at the adress specified by dwData[0] to get even more info about the button. When I have all info required I send it back to CLI which in turns converts them to C# managed objects.
And all of this is implemented in C++ because doing it in C# makes the already complicated code even more complicated. The code will be uploaded later today.
|
|
|
Post by leet on Feb 12, 2020 5:50:04 GMT -8
Updated Github repo to include system tray code.
|
|
veselcraft
Freshman Member
Posts: 46
OS: Windows 10 LTSB
Theme: Win 2k
|
Post by veselcraft on Feb 12, 2020 8:34:56 GMT -8
|
|
|
Post by Spitfire_x86 on Feb 12, 2020 8:41:39 GMT -8
Updated Github repo to include system tray code. Cool, thanks. I'm working on a Progman.exe replacement (hopefully I'll be able to replicate the entire Win3.1 shell experience). and I'll probably put the systray icons in the status bar to make it a bit more usable as a shell. veselcraft there's an absolute path in one of the project references, if you change it to a path relative to the solution directory it will compile without errors.
|
|
veselcraft
Freshman Member
Posts: 46
OS: Windows 10 LTSB
Theme: Win 2k
|
Post by veselcraft on Feb 12, 2020 9:07:31 GMT -8
I'm working on a Progman.exe replacement (hopefully I'll be able to replicate the entire Win3.1 shell experience). and I'll probably put the systray icons in the status bar to make it a bit more usable as a shell. actually i already made progman clone on C#
|
|
|
Post by The Jackal on Feb 12, 2020 14:15:18 GMT -8
Nightly build is crashing for me; on W10 LTSB 16 and in a XP VM. Previous version was working fine, this one auto crashes.
|
|
|
Post by Spitfire_x86 on Feb 12, 2020 16:43:14 GMT -8
Hmm, the systray doesn't work for me. GetTrayButtonCount always returns 4, no matter how many tray icons I have, and seems like everything in TBUTTONINFO is null after calling GetTrayButton.
|
|
|
Post by anixx on Feb 12, 2020 23:44:27 GMT -8
Updated Github repo to include system tray code. Cool, thanks. I'm working on a Progman.exe replacement (hopefully I'll be able to replicate the entire Win3.1 shell experience). and I'll probably put the systray icons in the status bar to make it a Why? One can use progman from WinNT 3.51 or NT 4
|
|
veselcraft
Freshman Member
Posts: 46
OS: Windows 10 LTSB
Theme: Win 2k
|
Post by veselcraft on Feb 12, 2020 23:46:32 GMT -8
Cool, thanks. I'm working on a Progman.exe replacement (hopefully I'll be able to replicate the entire Win3.1 shell experience). and I'll probably put the systray icons in the status bar to make it a Why? One can use progman from WinNT 3.51 or NT 4 we need flexable program
|
|
|
Post by leet on Feb 13, 2020 1:54:58 GMT -8
Hmm, the systray doesn't work for me. GetTrayButtonCount always returns 4, no matter how many tray icons I have, and seems like everything in TBUTTONINFO is null after calling GetTrayButton. The caveats of TB_GETBUTTON: - If the OS (and specifically explorer.exe) is x64, you NEED to compile for x64, same thing for x86.
- Tray icons that are inside of the "arrow" menu, are technically hidden, so they won't show up. You have to enable the option "Settings" -> "Personalization" -> "Taskbar" tab -> "Notification area" setting area -> "Select which icons appear on the taskbar" -> "Always show all icons in the notification area"
- All icons that are made from within explorer.exe require Shell_TrayWnd to be the foreground window because they're technically part of the taskbar (wifi, sound, eject menu etc. (battery works though?))
|
|
|
Post by leet on Feb 13, 2020 1:57:27 GMT -8
Nightly build is crashing for me; on W10 LTSB 16 and in a XP VM. Previous version was working fine, this one auto crashes. "This means that you have the chance of downloading a random thing I'm testing that will break stuff on your PC."
Well, the link still goes to my x86 folder which currently contains a broken version. I'll update the link to the x64 folder.
|
|
|
Post by leet on Feb 13, 2020 9:04:04 GMT -8
Uhm, not the right thread
|
|
|
Post by The Jackal on Feb 13, 2020 16:38:20 GMT -8
Nightly build is crashing for me; on W10 LTSB 16 and in a XP VM. Previous version was working fine, this one auto crashes. "This means that you have the chance of downloading a random thing I'm testing that will break stuff on your PC."
Well, the link still goes to my x86 folder which currently contains a broken version. I'll update the link to the x64 folder.
Thanks, but even that one isn't working for me. I don't think it's broken anything on my system, prob just not liking my setup or something. IDK.
|
|
|
Post by leet on Feb 14, 2020 1:55:46 GMT -8
Are you getting any .NET errors? If so, can you send them?
|
|
|
Post by Spitfire_x86 on Feb 14, 2020 2:19:58 GMT -8
I decided to try implementing systray from scratch - no Explorer hooks. I created a window with Shell_TrayWnd class and sent a TaskbarCreated message with C++, then redirected all WM_COPYDATA messages to my form in C#. So far I got the icons to display, they don't do anything yet though (and some of them repeat, because I forgot to filter out messages other than NIM_ADD ). There's still a long way to go though, I'll have to handle all the Shell_NotifyIcon messages and input events first before it becomes even remotely usable...
|
|
|
Post by leet on Feb 14, 2020 2:22:32 GMT -8
That's probably way faster lol. Anyways look awesome!
|
|
|
Post by The Jackal on Feb 14, 2020 5:08:33 GMT -8
Are you getting any .NET errors? If so, can you send them? Sadly just a generic "this program has stopped working" error:
|
|
|
Post by leet on Feb 14, 2020 5:27:13 GMT -8
Great! Do you have the Cpp.CLI.dll file? If so, it's a C++ error (which is not caught by .NET). Probably an ion that it doesn't like. Could you give me a list of your systray icons?
|
|
|
Post by The Jackal on Feb 14, 2020 7:30:22 GMT -8
I installed a fresh W8.1 VM and tried it in that too, and I'm getting the same error I'm afraid. Got more information this time:
Problem signature: Problem Event Name: CLR20r3 Problem Signature 01: SimpleClassicThemeTaskbar.exe Problem Signature 02: 1.0.0.0 Problem Signature 03: 5e454e3b Problem Signature 04: SimpleClassicThemeTaskbar Problem Signature 05: 1.0.0.0 Problem Signature 06: 5e454e3b Problem Signature 07: 57 Problem Signature 08: 13 Problem Signature 09: System.TypeInitialization OS Version: 6.3.9600.2.0.0.256.89 Locale ID: 1033 Additional Information 1: 57da Additional Information 2: 57dab08f08c7ee896adcb8f73cb2c69d Additional Information 3: 853c Additional Information 4: 853c4c562aeb60061bd6dbab7dadea7c
As for what icons I use (W10, I never used these on the W8 vm): Volume2, unclicky, Simpletwall, Lightshot, Malwarebytes, 3RVX, WinEject, Classic Task Manager.
|
|