Military cover regulations require removing the hat indoors unless under arms.
Civilian hat etiquette has no such general rule. You remove your hat (for example) in elevators or in private offices or homes not your own, or when directly addressing a lady.
Indoor public areas like lobbies, casino floors, gallerias and such are treated as "outdoors" and you can keep your hat on.