diff options
author | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-04-13 00:46:47 +0000 |
---|---|---|
committer | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-04-13 00:46:47 +0000 |
commit | 67e29a054cfcb1b0d2fe6b0a316cf6b3eec087b7 (patch) | |
tree | 5f52a9eada2e9f3654fc327d7c14dfef570a6ecb /kaddressbook/jumpbuttonbar.cpp | |
parent | 2ee4bf4fd5eff93b2fbef0ff8e8063edffc5da5c (diff) | |
download | tdepim-67e29a054cfcb1b0d2fe6b0a316cf6b3eec087b7.tar.gz tdepim-67e29a054cfcb1b0d2fe6b0a316cf6b3eec087b7.zip |
Initial conversion of kdepim to TQt
This will probably require some tweaking before it will build under Qt4,
however Qt3 builds are OK. Any alterations this commit makes to kdepim
behaviour under Qt3 are unintentional and should be fixed.
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdepim@1227832 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kaddressbook/jumpbuttonbar.cpp')
-rw-r--r-- | kaddressbook/jumpbuttonbar.cpp | 26 |
1 files changed, 13 insertions, 13 deletions
diff --git a/kaddressbook/jumpbuttonbar.cpp b/kaddressbook/jumpbuttonbar.cpp index aa7cb891c..4ef22bc57 100644 --- a/kaddressbook/jumpbuttonbar.cpp +++ b/kaddressbook/jumpbuttonbar.cpp @@ -17,8 +17,8 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. As a special exception, permission is given to link this program - with any edition of Qt, and distribute the resulting executable, - without including the source code for Qt in the source distribution. + with any edition of TQt, and distribute the resulting executable, + without including the source code for TQt in the source distribution. */ #include <tqapplication.h> @@ -39,11 +39,11 @@ #include "jumpbuttonbar.h" -class JumpButton : public QPushButton +class JumpButton : public TQPushButton { public: JumpButton( const TQString &firstChar, const TQString &lastChar, - TQWidget *parent ); + TQWidget *tqparent ); TQString firstChar() const { return mChar; } @@ -52,8 +52,8 @@ class JumpButton : public QPushButton }; JumpButton::JumpButton( const TQString &firstChar, const TQString &lastChar, - TQWidget *parent ) - : TQPushButton( "", parent ), mChar( firstChar ) + TQWidget *tqparent ) + : TQPushButton( "", tqparent ), mChar( firstChar ) { setToggleButton( true ); if ( !lastChar.isEmpty() ) @@ -62,17 +62,17 @@ JumpButton::JumpButton( const TQString &firstChar, const TQString &lastChar, setText( firstChar.upper() ); } -JumpButtonBar::JumpButtonBar( KAB::Core *core, TQWidget *parent, const char *name ) - : TQWidget( parent, name ), mCore( core ) +JumpButtonBar::JumpButtonBar( KAB::Core *core, TQWidget *tqparent, const char *name ) + : TQWidget( tqparent, name ), mCore( core ) { setMinimumSize( 1, 1 ); TQVBoxLayout *tqlayout = new TQVBoxLayout( this, 0, 0 ); - tqlayout->tqsetAlignment( Qt::AlignTop ); + tqlayout->tqsetAlignment( TQt::AlignTop ); tqlayout->setAutoAdd( true ); tqlayout->setResizeMode( TQLayout::FreeResize ); - mGroupBox = new TQButtonGroup( 1, Qt::Horizontal, this ); + mGroupBox = new TQButtonGroup( 1, TQt::Horizontal, this ); mGroupBox->setExclusive( true ); mGroupBox->tqlayout()->setSpacing( 0 ); mGroupBox->tqlayout()->setMargin( 0 ); @@ -130,7 +130,7 @@ void JumpButtonBar::updateButtons() if ( characters.count() <= possibleButtons ) { // at first the easy case: all buttons fits in window for ( uint i = 0; i < characters.count(); ++i ) { - JumpButton *button = new JumpButton( characters[ i ], TQString::null, + JumpButton *button = new JumpButton( characters[ i ], TQString(), mGroupBox ); connect( button, TQT_SIGNAL( clicked() ), this, TQT_SLOT( letterClicked() ) ); mButtons.append( button ); @@ -150,7 +150,7 @@ void JumpButtonBar::updateButtons() continue; if ( characters.count() - current <= possibleButtons - i ) { JumpButton *button = new JumpButton( characters[ current ], - TQString::null, mGroupBox ); + TQString(), mGroupBox ); connect( button, TQT_SIGNAL( clicked() ), this, TQT_SLOT( letterClicked() ) ); mButtons.append( button ); button->show(); @@ -179,7 +179,7 @@ void JumpButtonBar::updateButtons() int maxWidth = 0; TQPushButton *button; for ( button = mButtons.first(); button; button = mButtons.next() ) - maxWidth = QMAX( maxWidth, button->tqsizeHint().width() ); + maxWidth = TQMAX( maxWidth, button->tqsizeHint().width() ); setFixedWidth( maxWidth ); } |