diff options
author | Mike Hayes <mhayes@openoffice.org> | 2002-11-26 09:21:35 +0000 |
---|---|---|
committer | Mike Hayes <mhayes@openoffice.org> | 2002-11-26 09:21:35 +0000 |
commit | 86b39d0cccd0dc54b2c29e948fa759841341f054 (patch) | |
tree | f8d1184971616a92a31e374c6cac756fc3101065 /vcl/unx/source | |
parent | 85504d18099dd285befbba88156c54df2b76af18 (diff) |
#96737# Check if anything is we need to delete in first place
Diffstat (limited to 'vcl/unx/source')
-rw-r--r-- | vcl/unx/source/app/i18n_cb.cxx | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/vcl/unx/source/app/i18n_cb.cxx b/vcl/unx/source/app/i18n_cb.cxx index b0c67fd7d189..60868210ad6b 100644 --- a/vcl/unx/source/app/i18n_cb.cxx +++ b/vcl/unx/source/app/i18n_cb.cxx @@ -2,9 +2,9 @@ * * $RCSfile: i18n_cb.cxx,v $ * - * $Revision: 1.16 $ + * $Revision: 1.17 $ * - * last change: $Author: sb $ $Date: 2002-11-19 10:39:48 $ + * last change: $Author: mhayes $ $Date: 2002-11-26 10:21:35 $ * * The Contents of this file are made available subject to the terms of * either of the following licenses @@ -151,6 +151,14 @@ PreeditDoneCallback ( XIC ic, XPointer client_data, XPointer call_data ) void Preedit_DeleteText(preedit_text_t *ptext, int from, int howmuch) { + // If we've been asked to delete no text then just set + // nLength correctly and return + if (ptext->nLength == 0) + { + ptext->nLength = from; + return; + } + int to = from + howmuch; if (to == ptext->nLength) |