Commit dc392001 authored by Jasem Mutlaq's avatar Jasem Mutlaq

Add notification configuration dialog in settings menu

parent a4484655
......@@ -74,6 +74,7 @@ else(BUILD_KSTARS_LITE)
XmlGui
Plotting
Notifications
NotifyConfig
#IconThemes
)
endif(BUILD_KSTARS_LITE)
......
......@@ -932,7 +932,7 @@ if(INDI_FOUND)
# target_link_libraries(KStarsLib ${CMAKE_THREAD_LIBS_INIT} ${NOVA_LIBRARIES})
target_link_libraries(KStarsLib ${CMAKE_THREAD_LIBS_INIT} )
else(BUILD_KSTARS_LITE)
target_link_libraries(KStarsLib ${CMAKE_THREAD_LIBS_INIT} KF5::Notifications)
target_link_libraries(KStarsLib ${CMAKE_THREAD_LIBS_INIT} KF5::Notifications KF5::NotifyConfig)
endif(BUILD_KSTARS_LITE)
if(WIN32 OR ANDROID)
......
......@@ -124,6 +124,7 @@
<Separator />
<Action name="options_configure_keybinding"/>
<Action name="options_configure_toolbars"/>
<Action name="options_configure_notifications"/>
<Action name="configure" />
<Action name="startwizard" />
</Menu>
......
......@@ -634,6 +634,9 @@ private slots:
/** Update satellites orbital elements*/
void slotUpdateSatellites();
/** Configure Notifications */
void slotConfigureNotifications();
private:
/** Load FOV information and repopulate menu. */
void repopulateFOV();
......
......@@ -48,6 +48,7 @@
#include <KMessageBox>
#include <KTipDialog>
#include <KConfigDialog>
#include <KNotifyConfigWidget>
#include <kns3/downloaddialog.h>
......@@ -1581,3 +1582,8 @@ void KStars::slotAddDeepSkyObject() {
}
m_addDSODialog->show();
}
void KStars::slotConfigureNotifications()
{
KNotifyConfigWidget::configure(this);
}
......@@ -369,6 +369,10 @@ void KStars::initActions() {
<< i18nc("Location on Earth", "&Geographic..." )
<< QIcon::fromTheme("kstars_xplanet" , QIcon(":/icons/breeze/default/kstars_xplanet.svg"))
<< QKeySequence( Qt::CTRL+Qt::Key_G );
// Configure Notifications
KStandardAction::configureNotifications(this, SLOT(slotConfigureNotifications()), actionCollection());
ka = actionCollection()->addAction( KStandardAction::Preferences, "configure", this, SLOT( slotViewOps() ) );
//I am not sure what icon preferences is supposed to be.
//ka->setIcon( QIcon::fromTheme("", QIcon(":/icons/breeze/default/.svg")));
......@@ -443,9 +447,12 @@ void KStars::initActions() {
actionCollection()->addAction("solarsystem", this, SLOT( slotSolarSystem() ) )
<< i18n("Solar System")
<< QKeySequence(Qt::CTRL+Qt::Key_Y );
actionCollection()->addAction("jmoontool", this, SLOT( slotJMoonTool() ) )
// Disabled until fixed later
/*actionCollection()->addAction("jmoontool", this, SLOT( slotJMoonTool() ) )
<< i18n("Jupiter's Moons")
<< QKeySequence(Qt::CTRL+Qt::Key_J );
<< QKeySequence(Qt::CTRL+Qt::Key_J );*/
actionCollection()->addAction("flagmanager", this, SLOT( slotFlagManager() ) )
<< i18n("Flags");
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment