[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-devel
Subject:    Small Patch for kaction.cpp
From:       Josef Weidendorfer <Josef.Weidendorfer () gmx ! de>
Date:       2002-02-26 10:19:56
[Download RAW message or body]

Hi,

a small patch for KSelectAction: if plugged into a toolbar,
use the actions tooltip for the combobox, and make it not taking
the focus if not editable. The actual focus behaviour is confusing
for the user.

Can somebody test and commit?

-- 
--
Josef Weidendorfer



@@ -1529,11 +1533,12 @@ int KSelectAction::plug( QWidget *widget
     bar->insertCombo( items(), id_, isEditable(),
                       SIGNAL( activated( const QString & ) ), this,
                       SLOT( slotActivated( const QString & ) ), isEnabled(),
-                      QString::null, -1, index );
+                      toolTip(), -1, index );

     QComboBox *cb = bar->getCombo( id_ );
     if ( cb )
     {
+      if (!isEditable()) cb->setFocusPolicy(QWidget::NoFocus);
       cb->setMinimumWidth( cb->sizeHint().width() );
       if ( d->m_comboWidth > 0 )
         cb->setMaximumWidth( d->m_comboWidth );

 
>> Visit http://mail.kde.org/mailman/listinfo/kde-devel#unsub to unsubscribe <<
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic