Waylandsink : fix bug : can not get wl_shell_surface 58/54058/2 accepted/tizen/mobile/20151212.071007 accepted/tizen/tv/20151212.072517 accepted/tizen/wearable/20151212.073113 submit/tizen/20151211.062609
authorHyunil <hyunil46.park@samsung.com>
Fri, 11 Dec 2015 06:18:51 +0000 (15:18 +0900)
committerHyunil <hyunil46.park@samsung.com>
Fri, 11 Dec 2015 06:21:17 +0000 (15:21 +0900)
Change-Id: I291e0380c1fce6669432e2432ab951e6da82cf47
Signed-off-by: Hyunil <hyunil46.park@samsung.com>
waylandsink/src/wlwindow.c

index 6f62fbf..06af24d 100644 (file)
@@ -133,7 +133,7 @@ gst_wl_window_new_internal (GstWlDisplay * display, struct wl_surface *surface)
     window->shell_surface = wl_shell_get_shell_surface (display->shell,
         window->surface);
 #endif
+
   window->viewport = wl_scaler_get_viewport (display->scaler, window->surface);
 
   /* do not accept input */
@@ -142,7 +142,8 @@ gst_wl_window_new_internal (GstWlDisplay * display, struct wl_surface *surface)
   wl_region_destroy (region);
 
 #ifdef GST_WLSINK_ENHANCEMENT
-  window->video_object = tizen_video_get_object(display->tizen_video, window->surface);
+  window->video_object =
+      tizen_video_get_object (display->tizen_video, window->surface);
 #endif
 
   return window;
@@ -155,6 +156,9 @@ gst_wl_window_new_toplevel (GstWlDisplay * display, GstVideoInfo * video_info)
 
   GstWlWindow *window;
 
+  /* not create shell_surface here for enlightenment */
+  display->need_shell_surface = TRUE;
+
   window = gst_wl_window_new_internal (display,
       wl_compositor_create_surface (display->compositor));
 
@@ -162,12 +166,10 @@ gst_wl_window_new_toplevel (GstWlDisplay * display, GstVideoInfo * video_info)
   gst_wl_window_set_render_rectangle (window, 0, 0, window->video_width,
       window->video_height);
 
-#ifdef GST_WLSINK_ENHANCEMENT
-  /* not create shell_surface here for enlightenment */
-  display->need_shell_surface = TRUE;
-#else
+#ifndef GST_WLSINK_ENHANCEMENT
+  /* go toplevel */
   window->shell_surface = wl_shell_get_shell_surface (display->shell,
-      window->surface);
+      window->area_surface);
 #endif
 
   if (window->shell_surface) {