I am still trying to get it to reset to the 8way upon leaving. Thought I had it, but I need to test out another configuration. The only game I played that caused trouble when exiting to mala was qbert, but opening up another game with my trackball fixed that. Just give it some time and someone will perfect the 49way support. I know someone was working on a plugin. That is one nice feature about mala where other users can create plugins so development is open to all.
About the inputs, sounds like you are asking about mala controls. To setup the joystick you just open the options and select controls. Then you can select the joystick tab. Enable the joysticks and start setting the inputs. They even have a separate tab to see what each button is, ex. your first button is seen as joybutton3.
Set49 only switches the DRS mode of the joystick for the game, like 8way, 4way, or 49way... It sets up its own file after reading the controls.ini folder. Then when you select a game, it sends the rom name and sets the drs mode. To set the other controls in mame, you just hit tab and set the general controls which carry over to all games.
Is that what you were asking about.