File: pkagentexample.cpp

package info (click to toggle)
polkit-qt-1 0.103.0-1
  • links: PTS, VCS
  • area: main
  • in suites: jessie, jessie-kfreebsd, wheezy
  • size: 712 kB
  • ctags: 521
  • sloc: cpp: 3,366; ansic: 11; xml: 9; makefile: 5
file content (17 lines) | stat: -rw-r--r-- 460 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
#define POLKIT_AGENT_I_KNOW_API_IS_SUBJECT_TO_CHANGE 1

#include <polkitagent/polkitagent.h>
#include "pkagentexample.h"
#include <glib-object.h>
#include <QtCore/QDebug>
#include "polkitqt1-subject.h"

PkAgentExample::PkAgentExample(int &argc, char **argv)
        : QCoreApplication(argc, argv)
{
    g_type_init();

    PolkitQt1::UnixSessionSubject session(getpid());

    m_listener.registerListener(session, "/org/kde/PolicyKit1/AuthenticationAgent");
}