ivi-shell: rework surface_add_notification API

The surface_add_notification API accepts a simple
wl_listener instead of a ivi-shell specific notification
function. Therefore, the API is renamed to surface_add_listener.

This change has several advantages:
1. Code cleanup
2. No dynamic memory allocation. Listeners are allocated
   by controller plugins
3. Remove API is not needed. Controller plugins can easily
   remove the listener link.

This patch also remove two APIs which are not needed:
- ivi_layout_surface_remove_notification
- ivi_layout_surface_remove_notification_by_callback

Signed-off-by: Emre Ucan <eucan@de.adit-jv.com>
Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
diff --git a/ivi-shell/ivi-layout-export.h b/ivi-shell/ivi-layout-export.h
index b6ece2c..05f3668 100644
--- a/ivi-shell/ivi-layout-export.h
+++ b/ivi-shell/ivi-layout-export.h
@@ -144,12 +144,6 @@
 			enum ivi_layout_notification_mask mask,
 			void *userdata);
 
-typedef void (*surface_property_notification_func)(
-			struct ivi_layout_surface *ivisurf,
-			const struct ivi_layout_surface_properties *,
-			enum ivi_layout_notification_mask mask,
-			void *userdata);
-
 typedef void (*layer_create_notification_func)(
 			struct ivi_layout_layer *ivilayer,
 			void *userdata);
@@ -318,19 +312,18 @@
 					   enum wl_output_transform orientation);
 
 	/**
-	 * \brief register for notification on property changes of ivi_surface
+	 * \brief add a listener to listen property changes of ivi_surface
+	 *
+	 * When a property of the ivi_surface is changed, the property_changed
+	 * signal is emitted to the listening controller plugins.
+	 * The pointer of the ivi_surface is sent as the void *data argument
+	 * to the wl_listener::notify callback function of the listener.
 	 *
 	 * \return IVI_SUCCEEDED if the method call was successful
 	 * \return IVI_FAILED if the method call was failed
 	 */
-	int32_t (*surface_add_notification)(struct ivi_layout_surface *ivisurf,
-					    surface_property_notification_func callback,
-					    void *userdata);
-
-	/**
-	 * \brief remove notification on property changes of ivi_surface
-	 */
-	void (*surface_remove_notification)(struct ivi_layout_surface *ivisurf);
+	int32_t (*surface_add_listener)(struct ivi_layout_surface *ivisurf,
+					    struct wl_listener *listener);
 
 	/**
 	 * \brief get weston_surface of ivi_surface
@@ -605,13 +598,6 @@
 				int32_t width, int32_t height);
 
 	/**
-	 * remove notification by callback on property changes of ivi_surface
-	 */
-	void (*surface_remove_notification_by_callback)(struct ivi_layout_surface *ivisurf,
-							surface_property_notification_func callback,
-							void *userdata);
-
-	/**
 	 * \brief remove notification by callback on property changes of ivi_layer
 	 */
 	void (*layer_remove_notification_by_callback)(struct ivi_layout_layer *ivilayer,