[Bf-blender-cvs] [fe6114aaf5e] blender-v3.4-release: GHOST/Wayland: remove display listener (was warning on startup)

Campbell Barton noreply at git.blender.org
Mon Nov 14 00:37:36 CET 2022


Commit: fe6114aaf5ef8e33a2d33c96795d9444f35f4c62
Author: Campbell Barton
Date:   Mon Nov 14 10:12:34 2022 +1100
Branches: blender-v3.4-release
https://developer.blender.org/rBfe6114aaf5ef8e33a2d33c96795d9444f35f4c62

GHOST/Wayland: remove display listener (was warning on startup)

This already has a default listener which uses waylands logging.

===================================================================

M	intern/ghost/intern/GHOST_SystemWayland.cpp

===================================================================

diff --git a/intern/ghost/intern/GHOST_SystemWayland.cpp b/intern/ghost/intern/GHOST_SystemWayland.cpp
index ed0dc9b5949..123534502fb 100644
--- a/intern/ghost/intern/GHOST_SystemWayland.cpp
+++ b/intern/ghost/intern/GHOST_SystemWayland.cpp
@@ -5083,42 +5083,6 @@ static const struct wl_registry_listener registry_listener = {
 
 /** \} */
 
-/* -------------------------------------------------------------------- */
-/** \name Listener (Display), #wl_display_listener
- * \{ */
-
-static CLG_LogRef LOG_WL_DISPLAY = {"ghost.wl.handle.display"};
-#define LOG (&LOG_WL_DISPLAY)
-
-static void display_handle_error(
-    void *data, struct wl_display *wl_display, void *object_id, uint32_t code, const char *message)
-{
-  GWL_Display *display = static_cast<GWL_Display *>(data);
-  GHOST_ASSERT(display->wl_display == wl_display, "Invalid internal state");
-  (void)display;
-
-  /* NOTE: code is #wl_display_error, there isn't a convenient way to convert to an ID. */
-  CLOG_INFO(LOG, 2, "error (code=%u, object_id=%p, message=%s)", code, object_id, message);
-}
-
-static void display_handle_delete_id(void *data, struct wl_display *wl_display, uint32_t id)
-{
-  GWL_Display *display = static_cast<GWL_Display *>(data);
-  GHOST_ASSERT(display->wl_display == wl_display, "Invalid internal state");
-  (void)display;
-
-  CLOG_INFO(LOG, 2, "delete_id (id=%u)", id);
-}
-
-static const struct wl_display_listener display_listener = {
-    display_handle_error,
-    display_handle_delete_id,
-};
-
-#undef LOG
-
-/** \} */
-
 /* -------------------------------------------------------------------- */
 /** \name GHOST Implementation
  *
@@ -5141,8 +5105,6 @@ GHOST_SystemWayland::GHOST_SystemWayland(bool background)
   /* This may be removed later if decorations are required, needed as part of registration. */
   display_->xdg_decor = new GWL_XDG_Decor_System;
 
-  wl_display_add_listener(display_->wl_display, &display_listener, display_);
-
   /* Register interfaces. */
   {
     display_->registry_skip_update_all = true;



More information about the Bf-blender-cvs mailing list