This example shows how to add a keyboard shortcut for showing/hiding active layer.
1. Edit menu, select "Keyboard Shortcuts", or press Alt+Shift+Ctrl+k.
2. Find the layers menu, and far down you’ll see the line for "Hide Layers".
3. Select it, and press the shortcut you would like for this feature, for instance Alt+Shift+Ctrl+h.
4. Click "Accept", then "OK".
That’s it, now your shortcut should work.
You can even take an overview of all shortcuts… in order to do this just click on the summarize button in the keyboard shortcuts and menus wizard.