Example #1
0
void KoColorPanel::finalizeInsertion( const Position& pos )
{
    paint( pos );

    if ( !isFocusEnabled() )
        setFocusPolicy( QWidget::StrongFocus );
    // Did we start a new row?
    if ( m_nextPosition.x == 1 )
        updateGeometry();
}
Example #2
0
bool TextField::onTouchBegan(Touch *touch, Event *unusedEvent)
{
    bool pass = Widget::onTouchBegan(touch, unusedEvent);
    if (_hitted)
    {
        if (isFocusEnabled())
        {
            requestFocus();
        }

        _textFieldRenderer->attachWithIME();
    }
    else
    {
        this->didNotSelectSelf();
    }
    return pass;
}