hwc: Configure FbUpdate only when needed

When video overlay is on and there are no UI layers to compose,
there is no need to configure for framebuffer target.

If framebuffer target is  also configured in such cases, video is not
shown on display due to 0 z-order.

Change-Id: I468068fa3a273d61e3688014251043035353cec0
diff --git a/libhwcomposer/hwc_fbupdate.h b/libhwcomposer/hwc_fbupdate.h
index 5fc7708..ddd24d7 100644
--- a/libhwcomposer/hwc_fbupdate.h
+++ b/libhwcomposer/hwc_fbupdate.h
@@ -41,7 +41,10 @@
     virtual void reset();
     //Factory method that returns a low-res or high-res version
     static IFBUpdate *getObject(const int& width, const int& dpy);
-
+    //To know if configuring FbUpdate is needed.
+    static bool needFbUpdate(hwc_context_t *ctx,
+           const hwc_display_contents_1_t *list,
+                                       int dpy);
 protected:
     const int mDpy; // display to update
     bool mModeOn; // if prepare happened