Kernel already gives an keyevent when you trigger the camera button in /dev/input/event[x] device, you can just edit the application that uses volumebutton to trigger camera, to read from different event device and trigger the camera like that. Atleast thats how I 1st re-enabled camera key support back in the days a year ago (afterwards I recompiled camera application with the support...)
if key == 1 and state == 2 and camera_app_on_top():