Exemplo n.º 1
0
void GtkInputMethodFilter::notifyMouseButtonPress()
{
    // Confirming the composition may trigger a selection change, which
    // might trigger further unwanted actions on the context, so we prevent
    // that by setting m_composingTextCurrently to false.
    if (m_composingTextCurrently)
        confirmCurrentComposition();
    m_composingTextCurrently = false;
    cancelContextComposition();
}
Exemplo n.º 2
0
void GtkInputMethodFilter::notifyFocusedOut()
{
    if (!m_enabled)
        return;

    if (m_composingTextCurrently)
        confirmCurrentComposition();
    cancelContextComposition();
    gtk_im_context_focus_out(m_context.get());
    m_enabled = false;
}
Exemplo n.º 3
0
void WebViewInputMethodFilter::confirmCompositionText(String text)
{
    Frame* frame = focusedOrMainFrame();
    if (!frame || !frame->editor().canEdit())
        return;

    if (text.isNull()) {
        confirmCurrentComposition();
        return;
    }
    frame->editor().confirmComposition(m_confirmedComposition);
}
Exemplo n.º 4
0
void InputMethodFilter::notifyMouseButtonPress()
{
#if ENABLE(API_TESTS)
    ASSERT(m_page || m_testingMode);
#else
    ASSERT(m_page);
#endif

    // Confirming the composition may trigger a selection change, which
    // might trigger further unwanted actions on the context, so we prevent
    // that by setting m_composingTextCurrently to false.
    confirmCurrentComposition();
    cancelContextComposition();
}
Exemplo n.º 5
0
void InputMethodFilter::notifyFocusedOut()
{
#if ENABLE(API_TESTS)
    ASSERT(m_page || m_testingMode);
#else
    ASSERT(m_page);
#endif
    if (!m_enabled)
        return;

    confirmCurrentComposition();
    cancelContextComposition();
    gtk_im_context_focus_out(m_context.get());
}