If I was driving with a gun out the window for laughs, just kidding, can I be pulled over? If the cop doesn't put his hand on his weapon after seeing mine that means I can't be charged right?

What if he smells the gun in the car but doesn't see it? Can he smell it on my hand and still arrest me?