|
|
@ -31,6 +31,7 @@
|
|
|
|
#include <kpassivepopup.h>
|
|
|
|
#include <kpassivepopup.h>
|
|
|
|
#include <tdepopupmenu.h>
|
|
|
|
#include <tdepopupmenu.h>
|
|
|
|
#include <kglobalaccel.h>
|
|
|
|
#include <kglobalaccel.h>
|
|
|
|
|
|
|
|
#include <khelpmenu.h>
|
|
|
|
|
|
|
|
|
|
|
|
// other TQt headers:
|
|
|
|
// other TQt headers:
|
|
|
|
#include <tqcursor.h>
|
|
|
|
#include <tqcursor.h>
|
|
|
@ -225,17 +226,11 @@ void tdepowersave::initMenu() {
|
|
|
|
|
|
|
|
|
|
|
|
HELP_SEPARATOR_MENU_ID = contextMenu()->insertSeparator();
|
|
|
|
HELP_SEPARATOR_MENU_ID = contextMenu()->insertSeparator();
|
|
|
|
|
|
|
|
|
|
|
|
help_menu = new TQPopupMenu(this, i18n("&Help").utf8());
|
|
|
|
// Create help submenu
|
|
|
|
|
|
|
|
KHelpMenu *m_help = new KHelpMenu(this, TDEGlobal::instance()->aboutData(), false, actionCollection());
|
|
|
|
help_menu->insertItem( SmallIcon("help", TQIconSet::Automatic), i18n("&TDEPowersave Handbook"),
|
|
|
|
TDEPopupMenu *help = m_help->menu();
|
|
|
|
this, TQT_SLOT(slotHelp()));
|
|
|
|
help->connectItem(KHelpMenu::menuHelpContents, this, TQT_SLOT(slotHelpContents()));
|
|
|
|
help_menu->insertSeparator();
|
|
|
|
this->contextMenu()->insertItem(SmallIcon("help"), KStdGuiItem::help().text(), help);
|
|
|
|
help_menu->insertItem( i18n("&Report a bug ..."), this, TQT_SLOT(slotReportBug()));
|
|
|
|
|
|
|
|
help_menu->insertItem( SmallIcon("tdepowersave", TQIconSet::Automatic),
|
|
|
|
|
|
|
|
i18n("&About TDEPowersave"), this, TQT_SLOT(slotAbout()));
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
HELP_MENU = contextMenu()->insertItem(SmallIcon("help", TQIconSet::Automatic),
|
|
|
|
|
|
|
|
i18n("&Help"), help_menu);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
connect(this, TQT_SIGNAL(quitSelected()), this, TQT_SLOT(_quit()));
|
|
|
|
connect(this, TQT_SIGNAL(quitSelected()), this, TQT_SLOT(_quit()));
|
|
|
|
|
|
|
|
|
|
|
@ -562,34 +557,6 @@ void tdepowersave::slotAbout()
|
|
|
|
a.exec();
|
|
|
|
a.exec();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
/*!
|
|
|
|
|
|
|
|
* \b TQT_SLOT to open the website to report bugs
|
|
|
|
|
|
|
|
*/
|
|
|
|
|
|
|
|
void tdepowersave::slotReportBug()
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
#ifdef DISTRO_IS_SUSE
|
|
|
|
|
|
|
|
#ifdef DISTRO_IS_SLES_SLED
|
|
|
|
|
|
|
|
kapp->invokeBrowser("https://bugzilla.novell.com/");
|
|
|
|
|
|
|
|
#else
|
|
|
|
|
|
|
|
kapp->invokeBrowser("http://en.opensuse.org/Submitting_Bug_Reports");
|
|
|
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#else
|
|
|
|
|
|
|
|
#ifdef DISTRO_IS_ALTLINUX
|
|
|
|
|
|
|
|
kapp->invokeBrowser("http://bugzilla.altlinux.org/");
|
|
|
|
|
|
|
|
#else
|
|
|
|
|
|
|
|
#ifdef DISTRO_IS_UBUNTU
|
|
|
|
|
|
|
|
kapp->invokeBrowser("https://launchpad.net/distros/ubuntu/+bugs");
|
|
|
|
|
|
|
|
#else
|
|
|
|
|
|
|
|
#ifdef DISTRO_IS_PARDUS
|
|
|
|
|
|
|
|
kapp->invokeBrowser("http://bugs.pardus.org.tr/");
|
|
|
|
|
|
|
|
#else
|
|
|
|
|
|
|
|
kapp->invokeBrowser("http://sourceforge.net/tracker/?group_id=124576&atid=700009");
|
|
|
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/*!
|
|
|
|
/*!
|
|
|
|
* \b TQT_SLOT to set the icon background on/off if battery is in critical, low or warning-state. Within
|
|
|
|
* \b TQT_SLOT to set the icon background on/off if battery is in critical, low or warning-state. Within
|
|
|
|
* this function we set \ref icon_state_changed to true and call \ref redrawPixmap() to redraw the
|
|
|
|
* this function we set \ref icon_state_changed to true and call \ref redrawPixmap() to redraw the
|
|
|
@ -605,6 +572,7 @@ void tdepowersave::do_setIconBG(){
|
|
|
|
|
|
|
|
|
|
|
|
kdDebugFuncOut(trace);
|
|
|
|
kdDebugFuncOut(trace);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
/*!
|
|
|
|
/*!
|
|
|
|
* \b TQT_SLOT to enable/disable the autosuspend.
|
|
|
|
* \b TQT_SLOT to enable/disable the autosuspend.
|
|
|
|
*/
|
|
|
|
*/
|
|
|
|