[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-commits
Subject: playground/base/nepomuk-kde/systray
From: Sebastian Trueg <sebastian () trueg ! de>
Date: 2011-01-06 11:20:23
Message-ID: 20110106112023.38F88AC8B0 () svn ! kde ! org
[Download RAW message or body]
SVN commit 1212265 by trueg:
Renamed to nepomukcontroller; Added desktop file; some cleanup
M +10 -10 CMakeLists.txt
M +1 -1 Messages.sh
M +3 -3 main.cpp
A nepomukcontroller.desktop
M +6 -14 systray.cpp
--- trunk/playground/base/nepomuk-kde/systray/CMakeLists.txt #1212264:1212265
@@ -1,4 +1,4 @@
-project(nepomuksystray)
+project(nepomukcontroller)
include_directories(
${SOPRANO_INCLUDE_DIR}
@@ -7,17 +7,17 @@
${CMAKE_CURRENT_BUILD_DIR}
)
-set(systray_SRCS
+set(controller_SRCS
main.cpp
systray.cpp
)
-qt4_add_dbus_interface(systray_SRCS \
${KDE4_DBUS_INTERFACES_DIR}/org.kde.nepomuk.Strigi.xml \
strigiserviceinterface)
-qt4_add_dbus_interface(systray_SRCS \
${KDE4_DBUS_INTERFACES_DIR}/org.kde.nepomuk.ServiceControl.xml servicecontrol) \
+qt4_add_dbus_interface(controller_SRCS \
${KDE4_DBUS_INTERFACES_DIR}/org.kde.nepomuk.Strigi.xml strigiserviceinterface) \
+qt4_add_dbus_interface(controller_SRCS \
${KDE4_DBUS_INTERFACES_DIR}/org.kde.nepomuk.ServiceControl.xml servicecontrol)
-kde4_add_executable(nepomuksystray ${systray_SRCS})
+kde4_add_executable(nepomukcontroller ${controller_SRCS})
-target_link_libraries(nepomuksystray
+target_link_libraries(nepomukcontroller
${KDE4_KDEUI_LIBS}
${KDE4_KIO_LIBS}
${KDE4_SOLID_LIBS}
@@ -25,11 +25,11 @@
${SOPRANO_LIBRARIES}
)
-#install(
-# FILES nepomuksystray.desktop
-# DESTINATION ${XDG_APPS_INSTALL_DIR})
+install(
+ FILES nepomukcontroller.desktop
+ DESTINATION ${XDG_APPS_INSTALL_DIR})
install(
- TARGETS nepomuksystray
+ TARGETS nepomukcontroller
${INSTALL_TARGETS_DEFAULT_ARGS})
# -----------------------------
--- trunk/playground/base/nepomuk-kde/systray/Messages.sh #1212264:1212265
@@ -1,4 +1,4 @@
#! /usr/bin/env bash
$EXTRACTRC `find . -name "*.ui" -o -name "*.kcfg"` >> rc.cpp
-$XGETTEXT `find . -name "*.cpp"` -o $podir/nepomuksystray.pot
+$XGETTEXT `find . -name "*.cpp"` -o $podir/nepomukcontroller.pot
rm -rf rc.cpp
--- trunk/playground/base/nepomuk-kde/systray/main.cpp #1212264:1212265
@@ -27,8 +27,8 @@
int main( int argc, char *argv[] )
{
- KAboutData aboutData( "nepomuksystray",
- "nepomuksystray",
+ KAboutData aboutData( "nepomukcontroller",
+ "nepomukcontroller",
ki18n("Nepomuk Controller"),
"0.1",
ki18n("A small tool to monitor and control Nepomuk file \
indexing"), @@ -44,6 +44,6 @@
KCmdLineArgs::addCmdLineOptions( options );
KApplication app;
- Nepomuk::SystemTray* tray = new Nepomuk::SystemTray( &app );
+ (void)new Nepomuk::SystemTray( &app );
return app.exec();
}
--- trunk/playground/base/nepomuk-kde/systray/systray.cpp #1212264:1212265
@@ -38,31 +38,23 @@
{
setCategory( SystemServices );
setIconByName( "nepomuk" );
- setTitle( i18n( "Search Service" ) );
+ setTitle( i18n( "Nepomuk File Indexing" ) );
- KMenu* menu = new KMenu;
- menu->addTitle( i18n( "Search Service" ) );
-
- m_suspendResumeAction = new KToggleAction( i18n( "Suspend File Indexing" ), menu \
); + m_suspendResumeAction = new KToggleAction( i18n( "Suspend File Indexing" ), \
contextMenu() );
m_suspendResumeAction->setCheckedState( KGuiItem( i18n( "Suspend File Indexing" \
) ) );
m_suspendResumeAction->setToolTip( i18n( "Suspend or resume the file indexer \
manually" ) ); connect( m_suspendResumeAction, SIGNAL( toggled( bool ) ),
this, SLOT( slotSuspend( bool ) ) );
- KAction* configAction = new KAction( menu );
- configAction->setText( i18n( "Configure File Indexer" ) );
+ KAction* configAction = new KAction( contextMenu() );
+ configAction->setText( i18n( "Configure File Indexing" ) );
configAction->setIcon( KIcon( "configure" ) );
connect( configAction, SIGNAL( triggered() ),
this, SLOT( slotConfigure() ) );
- menu->addAction( m_suspendResumeAction );
- menu->addAction( configAction );
+ contextMenu()->addAction( m_suspendResumeAction );
+ contextMenu()->addAction( configAction );
- // we do not want autogenerated quit and restore actions
- setStandardActionsEnabled( false );
-
- setContextMenu( menu );
-
// connect to the strigi service
m_service = new org::kde::nepomuk::Strigi( \
QLatin1String("org.kde.nepomuk.services.nepomukstrigiservice"),
\
QLatin1String("/nepomukstrigiservice"),
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic