- Timestamp:
- 02/01/10 16:43:00 (13 years ago)
- Branches:
- master, qt5
- Children:
- ba48d2f
- Parents:
- d7986a6
- Location:
- src/alarm
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
src/alarm/alarm.cpp
rd7986a6 ra7d8638 5 5 #include <QApplication> 6 6 #include <QDir> 7 #include <Q Debug>7 #include <QFileInfo> 8 8 9 9 #include <dbus-1.0/dbus/dbus-protocol.h> … … 30 30 alarm_action_set_label(act, "FOSDEM'10"); 31 31 32 // setup this action to be a "DBus command" 32 QFileInfo fi(*qApp->argv()); 33 QString name(fi.fileName()); 34 35 QString command = QDir::currentPath() + "/" + name + QString(" %1").arg(QString::number(aEventId)); 36 //QString command = *qApp->argv() + QString(" %1").arg(QString::number(aEventId)); 37 alarm_action_set_exec_command(act, command.toLocal8Bit().data()); 38 act->flags |= ALARM_ACTION_TYPE_EXEC; 33 39 act->flags |= ALARM_ACTION_WHEN_RESPONDED; 34 act->flags |= ALARM_ACTION_ TYPE_DBUS;40 act->flags |= ALARM_ACTION_EXEC_ADD_COOKIE; // adds assigned cookie at the end of command string 35 41 36 // DBus params for this action 37 alarm_action_set_dbus_interface(act, "org.fosdem.schedule.AlarmInterface"); 38 alarm_action_set_dbus_service(act, "org.fosdem.schedule"); 39 alarm_action_set_dbus_path(act, "/Fosdem"); 40 alarm_action_set_dbus_name(act, "Alarm"); 41 42 // DBus arguments for the action 43 alarm_action_set_dbus_args(act, DBUS_TYPE_INT32, &aEventId, DBUS_TYPE_INVALID); 42 // // setup this action to be a "DBus command" 43 // act->flags |= ALARM_ACTION_WHEN_RESPONDED; 44 // act->flags |= ALARM_ACTION_TYPE_DBUS; 45 // 46 // // DBus params for this action 47 // alarm_action_set_dbus_interface(act, "org.fosdem.schedule.AlarmInterface"); 48 // alarm_action_set_dbus_service(act, "org.fosdem.schedule"); 49 // alarm_action_set_dbus_path(act, "/Fosdem"); 50 // alarm_action_set_dbus_name(act, "Alarm"); 51 // 52 // // DBus arguments for the action 53 // alarm_action_set_dbus_args(act, DBUS_TYPE_INT32, &aEventId, DBUS_TYPE_INVALID); 44 54 45 55 // act->flags |= ALARM_ACTION_TYPE_EXEC; -
src/alarm/alarm.pro
rd7986a6 ra7d8638 10 10 11 11 HEADERS += alarm.h \ 12 alarmdbus.h \13 alarmdbusadaptorp.h14 12 15 13 SOURCES += alarm.cpp \ 16 alarmdbus.cpp \17 alarmdbusadaptor.cpp18 14 19 15 INCLUDEPATH += ../gui \
Note: See TracChangeset
for help on using the changeset viewer.