Refactor top bar create

I tried to clean up top bar create. There is more work to be done but this should be a good start.