src/gui/widgets/qlineedit.cpp
changeset 37 758a864f9613
parent 33 3e2da88830cd
equal deleted inserted replaced
36:ef0373b55136 37:758a864f9613
  1947     if (!QApplication::keypadNavigationEnabled() || hasEditFocus())
  1947     if (!QApplication::keypadNavigationEnabled() || hasEditFocus())
  1948 #endif
  1948 #endif
  1949     if (d->control->hasSelectedText() || (d->cursorVisible && !d->control->inputMask().isEmpty() && !d->control->isReadOnly())){
  1949     if (d->control->hasSelectedText() || (d->cursorVisible && !d->control->inputMask().isEmpty() && !d->control->isReadOnly())){
  1950         flags |= QLineControl::DrawSelections;
  1950         flags |= QLineControl::DrawSelections;
  1951         // Palette only used for selections/mask and may not be in sync
  1951         // Palette only used for selections/mask and may not be in sync
  1952         if(d->control->palette() != pal)
  1952         if (d->control->palette() != pal
       
  1953            || d->control->palette().currentColorGroup() != pal.currentColorGroup())
  1953             d->control->setPalette(pal);
  1954             d->control->setPalette(pal);
  1954     }
  1955     }
  1955 
  1956 
  1956     // Asian users see an IM selection text as cursor on candidate
  1957     // Asian users see an IM selection text as cursor on candidate
  1957     // selection phase of input method, so the ordinary cursor should be
  1958     // selection phase of input method, so the ordinary cursor should be