Because the background in my shop is so busy, I modified the photo a little so you could see the table in its open position.
Step 1: My Two Requirements
Second, I wanted the table to be as complete as possible, with places for oil and solvent, patches, cleaning rods, brushes, and other tools. You will see from the photos how I accomplished that. While I was at it, I made an area on the table top to retain the bolts, roll tins, etc, I would be dealing with. I also included a magnet to help keep things from rolling away. (In this photo, the top is folded down to the storage position, showing the hardware retainer and magnet.)
In this photo, you can see a shotgun barrel supported horizontally above the cleaning supply area.
Step 2: Gun Holder Arms
You can see in this photo two of the swing down supports the barrel was sitting on. I have a couple of pairs of them, one to hold the barrel and one for the stock or magazine tube.
Step 3: Table Unfolded
This view shows the gun cleaning table folded down. At the left of the flat surface, you can see the parts holding area, which is made of 1/8" strips of oak. In the center of the middle area is the magnet. I like to have plenty of magnets around to keep things from getting lost.
The leg is hinged on the right, so that it folds up under the table top, which then swings down. When the whole works is folded up, between the joists, turn-buttons hold it there.
The hinge for the table top is on the left.
Everything is built out of 5/8 plywood and 1x6s, ripped down the middle, and a little oak that I had, and used for the gun holding arms and parts retainer. I tied a piece of paracord from the swing leg to the middle of the table top (which was braced with a second thickness of plywood) to keep it from kicking away from the table. In this photo, the leg looks somewhat plumb, but I actually have it splayed out a little for more leg room.
Step 4: Folded Up
This underside view captures most of the gun cleaning table while it is folded into the ceiling joists. Again, as in most of the photos, I have modified the surrounding area so the project itself shows up better. I have also indicated the hinge end of the table leg (orange) and the turnbuttons holding the end of the leg (center arrow) and the whole table up. The side pieces of the table assembly is screwed (using a fender washer as a sort of bearing) at the sides, just above the top of the photo.
The main part of the project, the two legs and horizontal storage shelves, somewhat resemble a ladder, with a wooden back, pivoted at the top.
It certainly wasn't a hard project to make, but it serves the purpose very nicely.
Oh, BTW, be sure to have plenty of light on the work area.