diff options
author | Caolán McNamara <caolanm@redhat.com> | 2016-12-22 13:19:11 +0000 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2016-12-22 13:20:11 +0000 |
commit | 08e6fe3d120ad3e64c42022686579982a8af11c1 (patch) | |
tree | 83f06ffd9d954be93eee3464c3c858233ff36ffa /vcl | |
parent | 3ea598f65bed096dbf4bda5fe4105b57c58b5310 (diff) |
Resolves: tdf#104687 gtk2 paste cell text under a11y is fatal
Change-Id: Ia26ecf381e491b5591e05e0051b7162eb1d4bb56
(cherry picked from commit 88dad8fe1a94055dcbb05a6e6f0df2d007914a45)
Diffstat (limited to 'vcl')
-rw-r--r-- | vcl/unx/gtk/a11y/atkutil.cxx | 16 |
1 files changed, 10 insertions, 6 deletions
diff --git a/vcl/unx/gtk/a11y/atkutil.cxx b/vcl/unx/gtk/a11y/atkutil.cxx index 34192595a8de..bf809734f561 100644 --- a/vcl/unx/gtk/a11y/atkutil.cxx +++ b/vcl/unx/gtk/a11y/atkutil.cxx @@ -94,12 +94,16 @@ atk_wrapper_focus_idle_handler (gpointer data) if (xText.is()) { - gint caretPos = xText->getCaretPosition(); - - if ( caretPos != -1 ) - { - atk_object_notify_state_change( atk_obj, ATK_STATE_FOCUSED, TRUE ); - g_signal_emit_by_name( atk_obj, "text_caret_moved", caretPos ); + try { + gint caretPos = xText->getCaretPosition(); + + if ( caretPos != -1 ) + { + atk_object_notify_state_change( atk_obj, ATK_STATE_FOCUSED, TRUE ); + g_signal_emit_by_name( atk_obj, "text_caret_moved", caretPos ); + } + } catch (const uno::Exception& e) { + SAL_INFO("vcl.a11y", "exception: " << e.Message); } } } |