Progress thread: less aggressive redraw

In commit I643e30505f962ebbf67aae57baa06a296006e542 , 'enhance the
progress thread update', I incorrectly amended philz-cwm6's commit to
work around a theoretical issue of keeping the installer's spinning
cube rotating when no progress bar is shown. While my amendment works,
it keeps the progress_thread updating text and overlays even when
sitting at the menu. This is overly aggressive. Change the update
mechanism to only apply when the background installer image is visible.

Also, make ui_increment_frame() static since is is local-only now.

Change-Id: I2fa2f8a0704f562fb027ba4bee9b1b7d278da404
Merge branch 'cm-11.0' into kk_mkt

Change-Id: I70d1a050236619f89adaa93c8c438d342a93d85c
stop showing the background icon progress outside it's scope

Also, extend print_and_error() to act as a pass-through, returning the
original error code.

Conflicts:
	extendedcommands.c
	nandroid.c
	nandroid.h

Change-Id: I3d7ee71f627f871f64defe7902b91b762ca97d59

Conflicts:
	nandroid.c
Merge branch 'cm-11.0' into kk_mkt

Conflicts:
	nandroid.c

Change-Id: I9676c2cbebfaa1f38e65d173bd06959a689e93c1