The main issues I have with my code to send keys to Mame is (a) stability, because I use a dll to attach to the Mame process and subclass it's WndProc calls it might inadvertantly cause Mame to crash. If you exit CPWizard before closing Mame for example, Mame will crash. This is because the only way to inject keys into Mame's new Raw Input System is to "hack" your way into it. And (b) The fact the host application needs to run on any CPU and launch either the 32 or 64 bit versions of the dll (which I have working) but because CPWizard is still only 32-bit because of some of the 32-bit dependancies I will probably have to launch a separate program to inject the keys. It's just a little "ugly" for my liking so I am hessitant to implement it.
As for modifying the Mame source to pause, I don't think it would be that difficult. All you have to do is add a new message for the "Mame Output" window (check out output.c) there is a function called output_window_proc(). Basically you would add an extra event using RegisterWindowMessage() (lets call it IM_MAME_PAUSE).
Inside winoutput_init()
im_mame_pause = RegisterWindowMessage(IM_MAME_PAUSE);
Then inside output_window_proc()
if (message == im_mame_pause)
mame_pause(Machine);
From CPWizard I simply say PostMessage(hwnd, im_mame_pause, 0, state); to pause Mame.
Anyway something like that should work. I would prefer to use this method and create a diff for it as it doesn't have all the problems my other method brings.
I have a vertically oriented monitor and the panel gets squished (aspect ratio not maintained). What do I need to do to correct this?
Have you tried replacing the background image to be a vertical orientation? You will have to move all the buttons around to make it look right, but it should work okay.
I could have sworn that 1.70 showed numbers for the PLAYER START labels, but they appear blank now - did this get broken?
No I don't think it ever did this. Just add a "Custom Text" label if you want to put numbers on your start buttons.
I'm working on separate layouts for 3 and 4 player games (I have external boxes that plug into my panel with DB9 cables) but I can't get the alternating filter to work. The only filters I set for my layout map are numplayers=3 and alternating=no. Then when I try to preview Rampage, it falls back to the default layout. If I change alternating to a *, then it works (but of course that's not how I want it configured). Rampage does list as 3 players and not alternating, so it seems that there's a bug in determining which layout to use.
Yep you found a bug. I'll upload a fix soon.
I noticed that when I pause mame, there is a flicker where the desktop becomes visible for a moment and then mame plus cpwizard appear. Is there any way to eliminate that? It's not a huge issue, but of course ideally you want cpwizard to essentially appear to be part of mame, not something that is clearly distinct.
You could try one of the "Hide Desktop Options" under General options. Like "Hide Desktop Using Forms". To be honest I didn't do a hell of alot of testing with all that though. I should probably look into using that same method just for when CPWizard is being shown.
I don't know if this is common or not, but I have been editing my layouts and settings on my desktop machine and then copying certain files over to my cabinet. This would include my layout maps (including default "mame layout" map) and panel files (including graphics, because not all of them came with the install). A "deploy to cabinet" feature would be cool, where you would specify the UNC path to the remote cpwizard installation and it would copy over all relevant files and/or settings. Certainly not critical by any means, but if this is something many people do manually, then it might be worth adding.
There is no cure for lazyness! lol Probably not something I would do. You know what though you could setup a shortcut that will copy over the files to your cab when you double click it. That is how I update things to my cab.
Oh, and I still think making the preview window modeless just like the object properties window would be very handy while making several iterations of tweaks to a layout.
Yes it's a good idea, I'll consider it