summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authoraxis <qt-info@nokia.com>2010-02-05 12:49:46 (GMT)
committeraxis <qt-info@nokia.com>2010-02-05 12:50:44 (GMT)
commite3237deee07ec6961b905800d29b1a80f0f63595 (patch)
tree1ae62be2e271df3c5f42e002248bdeb9c0258703 /src
parent3fdc70e9272f1a0ddd087f0d908a64ce2d4e4302 (diff)
downloadQt-e3237deee07ec6961b905800d29b1a80f0f63595.zip
Qt-e3237deee07ec6961b905800d29b1a80f0f63595.tar.gz
Qt-e3237deee07ec6961b905800d29b1a80f0f63595.tar.bz2
Removed useless member variable and replaced with var on the stack.
RevBy: Trust me
Diffstat (limited to 'src')
-rw-r--r--src/gui/inputmethod/qcoefepinputcontext_p.h1
-rw-r--r--src/gui/inputmethod/qcoefepinputcontext_s60.cpp9
2 files changed, 5 insertions, 5 deletions
diff --git a/src/gui/inputmethod/qcoefepinputcontext_p.h b/src/gui/inputmethod/qcoefepinputcontext_p.h
index 73c13d9..f325fb9 100644
--- a/src/gui/inputmethod/qcoefepinputcontext_p.h
+++ b/src/gui/inputmethod/qcoefepinputcontext_p.h
@@ -151,7 +151,6 @@ private:
int m_inlinePosition;
MFepInlineTextFormatRetriever *m_formatRetriever;
MFepPointerEventHandlerDuringInlineEdit *m_pointerHandler;
- int m_longPress;
int m_cursorPos;
QBasicTimer m_tempPreeditStringTimeout;
bool m_hasTempPreeditString;
diff --git a/src/gui/inputmethod/qcoefepinputcontext_s60.cpp b/src/gui/inputmethod/qcoefepinputcontext_s60.cpp
index e5ab300..56b79f4 100644
--- a/src/gui/inputmethod/qcoefepinputcontext_s60.cpp
+++ b/src/gui/inputmethod/qcoefepinputcontext_s60.cpp
@@ -71,7 +71,6 @@ QCoeFepInputContext::QCoeFepInputContext(QObject *parent)
m_inlinePosition(0),
m_formatRetriever(0),
m_pointerHandler(0),
- m_longPress(0),
m_cursorPos(0),
m_hasTempPreeditString(false)
{
@@ -744,24 +743,26 @@ void QCoeFepInputContext::DoCommitFepInlineEditL()
void QCoeFepInputContext::commitCurrentString(bool triggeredBySymbian)
{
+ int longPress = 0;
+
if (m_preeditString.size() == 0) {
QWidget *w = focusWidget();
if (triggeredBySymbian && w) {
// We must replace the last character only if the input box has already accepted one
if (w->inputMethodQuery(Qt::ImCursorPosition).toInt() != m_cursorPos)
- m_longPress = 1;
+ longPress = 1;
}
return;
}
QList<QInputMethodEvent::Attribute> attributes;
QInputMethodEvent event(QLatin1String(""), attributes);
- event.setCommitString(m_preeditString, 0-m_longPress, m_longPress);
+ event.setCommitString(m_preeditString, 0-longPress, longPress);
m_preeditString.clear();
sendEvent(event);
m_hasTempPreeditString = false;
- m_longPress = 0;
+ longPress = 0;
if (!triggeredBySymbian) {
CCoeFep* fep = CCoeEnv::Static()->Fep();