diff options
author | Noel Grandin <noel@peralex.com> | 2016-05-09 17:07:54 +0200 |
---|---|---|
committer | Noel Grandin <noelgrandin@gmail.com> | 2016-05-11 07:14:34 +0000 |
commit | 63ba54a168dbc777cdcec2393be476bdd5f79bc1 (patch) | |
tree | 48de29007d02ba4a982a50a1bd0138460e215c23 /vcl/unx/gtk3 | |
parent | 7b9ea3348ac08d775ae452132239853724c65a41 (diff) |
convert EXTTEXTINPUT_ATTR to scoped enum
Change-Id: I94706bdea91d367fc8c2bbd482f6b4d8f55449d7
Reviewed-on: https://gerrit.libreoffice.org/24821
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
Diffstat (limited to 'vcl/unx/gtk3')
-rw-r--r-- | vcl/unx/gtk3/gtk3gtkframe.cxx | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/vcl/unx/gtk3/gtk3gtkframe.cxx b/vcl/unx/gtk3/gtk3gtkframe.cxx index 2630aa19f2a2..b6352c694ca5 100644 --- a/vcl/unx/gtk3/gtk3gtkframe.cxx +++ b/vcl/unx/gtk3/gtk3gtkframe.cxx @@ -3794,7 +3794,7 @@ void GtkSalFrame::IMHandler::signalIMPreeditChanged( GtkIMContext*, gpointer im_ pThis->m_aInputEvent.mnCursorFlags = 0; pThis->m_aInputEvent.mbOnlyCursor = False; - pThis->m_aInputFlags = std::vector<sal_uInt16>( std::max( 1, (int)pThis->m_aInputEvent.maText.getLength() ), 0 ); + pThis->m_aInputFlags = std::vector<ExtTextInputAttr>( std::max( 1, (int)pThis->m_aInputEvent.maText.getLength() ), ExtTextInputAttr::NONE ); PangoAttrIterator *iter = pango_attr_list_get_iterator(pAttrs); do @@ -3802,7 +3802,7 @@ void GtkSalFrame::IMHandler::signalIMPreeditChanged( GtkIMContext*, gpointer im_ GSList *attr_list = nullptr; GSList *tmp_list = nullptr; gint start, end; - guint sal_attr = 0; + ExtTextInputAttr sal_attr = ExtTextInputAttr::NONE; pango_attr_iterator_range (iter, &start, &end); if (end == G_MAXINT) @@ -3821,14 +3821,14 @@ void GtkSalFrame::IMHandler::signalIMPreeditChanged( GtkIMContext*, gpointer im_ switch (pango_attr->klass->type) { case PANGO_ATTR_BACKGROUND: - sal_attr |= EXTTEXTINPUT_ATTR_HIGHLIGHT; + sal_attr |= ExtTextInputAttr::Highlight; pThis->m_aInputEvent.mnCursorFlags |= EXTTEXTINPUT_CURSOR_INVISIBLE; break; case PANGO_ATTR_UNDERLINE: - sal_attr |= EXTTEXTINPUT_ATTR_UNDERLINE; + sal_attr |= ExtTextInputAttr::Underline; break; case PANGO_ATTR_STRIKETHROUGH: - sal_attr |= EXTTEXTINPUT_ATTR_REDTEXT; + sal_attr |= ExtTextInputAttr::RedText; break; default: break; @@ -3836,8 +3836,8 @@ void GtkSalFrame::IMHandler::signalIMPreeditChanged( GtkIMContext*, gpointer im_ pango_attribute_destroy (pango_attr); tmp_list = tmp_list->next; } - if (sal_attr == 0) - sal_attr |= EXTTEXTINPUT_ATTR_UNDERLINE; + if (sal_attr == ExtTextInputAttr::NONE) + sal_attr |= ExtTextInputAttr::Underline; g_slist_free (attr_list); // Set the sal attributes on our text |