0

The navigation bar can take a UIImageView via the titleView property,

for example

self.navigationItem.titleView, and the The UIImageView can be animated.

Unfortunately, as per the documentation "Custom title views are centered on the navigation bar and may be resized to fit". This resizing makes it unsuitable for me.

My goal is to animate a UIImageView in something like a navigation bar, tab bar or toolbar. In other words I want to animate UIImageView in a bar that is always visible in a view.

How would I do this (using swift)?

Badal Shah
  • 7,541
  • 2
  • 30
  • 65
dasPing
  • 337
  • 1
  • 2
  • 19
  • I am not sure and i havn't seen animation as you described in question but may be you can try with creating custom view and give animation as accessing it in navigation. http://stackoverflow.com/a/35332485/4910767 – Badal Shah Feb 12 '16 at 10:00

1 Answers1

0

A possible solution is to create a UIBarButtonItem with a UIImageView in the constructor and set the left or right button in the navigator bar to the animate button item.

dasPing
  • 337
  • 1
  • 2
  • 19