From ceea23677c61f20759ae986bd77b0d5c4d673edb Mon Sep 17 00:00:00 2001 From: tpearson Date: Wed, 17 Feb 2010 00:43:50 +0000 Subject: Added old KDE3 version of kbfx git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/applications/kbfx@1091549 283d02a7-25f6-0310-bc7c-ecb5cbfe19da --- configdialog/kbfxconfigdlgtooltip.ui.h | 86 ++++++++++++++++++++++++++++++++++ 1 file changed, 86 insertions(+) create mode 100644 configdialog/kbfxconfigdlgtooltip.ui.h (limited to 'configdialog/kbfxconfigdlgtooltip.ui.h') diff --git a/configdialog/kbfxconfigdlgtooltip.ui.h b/configdialog/kbfxconfigdlgtooltip.ui.h new file mode 100644 index 0000000..196c2d9 --- /dev/null +++ b/configdialog/kbfxconfigdlgtooltip.ui.h @@ -0,0 +1,86 @@ +/**************************************************************************** +** ui.h extension file, included from the uic-generated form implementation. +** +** If you want to add, delete, or rename functions or slots, use +** Qt Designer to update this file, preserving your code. +** +** You should not define a constructor or destructor in this file. +** Instead, write your code in functions called init() and destroy(). +** These will automatically be called by the form's constructor and +** destructor. +*****************************************************************************/ + +void KbfxConfigDlgTooltip::init() +{ + img_on = ConfigInit().KbfxOnImg; + img_off = ConfigInit().KbfxOffImg; +} + +void KbfxConfigDlgTooltip::KbfxTooltipAnimationButtonToggled ( bool ) +{ + if ( KbfxTooltipAnimationButton->state() == 2 ) + { + KbfxTooltipAnimationButton->setText ( tr2i18n ( "Turn the animation 'OFF'" ) ); + KbfxTooltipAnimationPixmapLabel->setPixmap ( img_on ); + ConfigInit().m_ToolTipAnimation = TRUE; + } + + if ( KbfxTooltipAnimationButton->state() == 0 ) + { + KbfxTooltipAnimationButton->setText ( tr2i18n ( "Turn the animation 'ON'" ) ); + KbfxTooltipAnimationPixmapLabel->setPixmap ( img_off ); + ConfigInit().m_ToolTipAnimation = FALSE; + } + + kdDebug() << "Tooltip animation state: " + << ConfigInit().m_ToolTipAnimation + << endl; +} + +void KbfxConfigDlgTooltip::KbfxTooltipTextEditTextChanged() +{ + ConfigInit().m_ToolTipText = KbfxTooltipTextEdit->text(); + + kdDebug() << "Tooltip text: " + << ConfigInit().m_ToolTipText + << endl; +} + +void KbfxConfigDlgTooltip::KbfxTooltipOnButtonToggled ( bool ) +{ + if ( KbfxTooltipOnButton->state() == 2 ) + { + KbfxTooltipOnButton->setText ( tr2i18n ( "Turn the tooltip 'OFF'" ) ); + KbfxTooltipOnPixmapLabel->setPixmap ( img_on ); + ConfigInit().m_ToolTip = TRUE; + } + + if ( KbfxTooltipOnButton->state() == 0 ) + { + KbfxTooltipOnButton->setText ( tr2i18n ( "Turn the tooltip 'ON'" ) ); + KbfxTooltipOnPixmapLabel->setPixmap ( img_off ); + ConfigInit().m_ToolTip = FALSE; + + } + + kdDebug() << "Tooltip state: " + << ConfigInit().m_ToolTip + << endl; +} + +void KbfxConfigDlgTooltip::ChangeForm() +{ + if ( ConfigInit().m_ToolTip == TRUE && KbfxTooltipOnButton->state() == 0 ) + KbfxTooltipOnButton->toggle(); + + if ( ConfigInit().m_ToolTip == FALSE && KbfxTooltipOnButton->state() == 2 ) + KbfxTooltipOnButton->toggle(); + + if ( ConfigInit().m_ToolTipAnimation == TRUE && KbfxTooltipAnimationButton->state() == 0 ) + KbfxTooltipAnimationButton->toggle(); + + if ( ConfigInit().m_ToolTipAnimation == FALSE && KbfxTooltipAnimationButton->state() == 2 ) + KbfxTooltipAnimationButton->toggle(); + + KbfxTooltipTextEdit->setText ( ConfigInit().m_ToolTipText ); +} -- cgit v1.2.1