KMyMoneyBriefSchedule::KMyMoneyBriefSchedule(QWidget *parent, const char *name ) : kScheduleBriefWidget(parent,name, WStyle_Customize | WStyle_NoBorder) { KIconLoader *ic = KGlobal::iconLoader(); m_nextButton->setPixmap(BarIcon(QString::fromLatin1("1rightarrow"))); m_prevButton->setPixmap(BarIcon(QString::fromLatin1("1leftarrow"))); connect(m_prevButton, SIGNAL(clicked()), this, SLOT(slotPrevClicked())); connect(m_nextButton, SIGNAL(clicked()), this, SLOT(slotNextClicked())); connect(m_closeButton, SIGNAL(clicked()), this, SLOT(hide())); connect(m_skipButton, SIGNAL(clicked()), this, SLOT(slotSkipClicked())); connect(m_buttonEnter, SIGNAL(clicked()), this, SLOT(slotEnterClicked())); KGuiItem skipGuiItem( i18n("&Skip"), QIconSet(ic->loadIcon("player_fwd", KIcon::Small, KIcon::SizeSmall)), i18n("Skip this transaction"), i18n("Use this button to skip this transaction")); m_skipButton->setGuiItem(skipGuiItem); KGuiItem enterGuiItem( i18n("&Enter"), QIconSet(ic->loadIcon("key_enter", KIcon::Small, KIcon::SizeSmall)), i18n("Record this transaction into the register"), i18n("Use this button to record this transaction")); m_buttonEnter->setGuiItem(enterGuiItem); }
KMyMoneyBriefSchedule::KMyMoneyBriefSchedule(QWidget *parent) : kScheduleBriefWidget(parent/*,name, Qt::WStyle_Customize | Qt::WStyle_NoBorder*/) { m_nextButton->setIcon(KIcon(QString::fromLatin1("arrow-right"))); m_prevButton->setIcon(KIcon(QString::fromLatin1("arrow-left"))); connect(m_prevButton, SIGNAL(clicked()), this, SLOT(slotPrevClicked())); connect(m_nextButton, SIGNAL(clicked()), this, SLOT(slotNextClicked())); connect(m_closeButton, SIGNAL(clicked()), this, SLOT(hide())); connect(m_skipButton, SIGNAL(clicked()), this, SLOT(slotSkipClicked())); connect(m_buttonEnter, SIGNAL(clicked()), this, SLOT(slotEnterClicked())); KGuiItem skipGuiItem(i18n("&Skip"), KIcon("media-seek-forward"), i18n("Skip this transaction"), i18n("Use this button to skip this transaction")); m_skipButton->setGuiItem(skipGuiItem); // as of KDE 4.8 the icon we use here move to a different location QString iconName("go-jump-locationbar");; if (KDE::version() >= 0x040800) { iconName = QLatin1String("key-enter"); } KGuiItem enterGuiItem(i18n("&Enter"), KIcon(iconName), i18n("Record this transaction into the register"), i18n("Use this button to record this transaction")); m_buttonEnter->setGuiItem(enterGuiItem); }