diff options
-rw-r--r-- | libreofficekit/source/gtk/lokdocview.cxx | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/libreofficekit/source/gtk/lokdocview.cxx b/libreofficekit/source/gtk/lokdocview.cxx index cff78895ab84..550a9221744e 100644 --- a/libreofficekit/source/gtk/lokdocview.cxx +++ b/libreofficekit/source/gtk/lokdocview.cxx @@ -282,6 +282,8 @@ callbackTypeToString (int nType) return "LOK_CALLBACK_CELL_CURSOR"; case LOK_CALLBACK_HYPERLINK_CLICKED: return "LOK_CALLBACK_HYPERLINK_CLICKED"; + case LOK_CALLBACK_MOUSE_POINTER: + return "LOK_CALLBACK_MOUSE_POINTER"; case LOK_CALLBACK_STATE_CHANGED: return "LOK_CALLBACK_STATE_CHANGED"; case LOK_CALLBACK_STATUS_INDICATOR_START: @@ -736,6 +738,15 @@ callback (gpointer pData) priv->m_bCursorVisible = pCallback->m_aPayload == "true"; } break; + case LOK_CALLBACK_MOUSE_POINTER: + { + // The gtk docs claim that most css cursors should be supported, however + // on my system at least this is not true and many cursors are unsupported. + // In this case pCursor = null, which results in the default cursor being set. + GdkCursor* pCursor = gdk_cursor_new_from_name(gtk_widget_get_display(GTK_WIDGET(pDocView)), pCallback->m_aPayload.c_str()); + gdk_window_set_cursor(gtk_widget_get_window(GTK_WIDGET(pDocView)), pCursor); + } + break; case LOK_CALLBACK_GRAPHIC_SELECTION: { if (pCallback->m_aPayload != "EMPTY") |