From f9d480cfe50ca1d7a0f0b5a2b8bb9932962bfbe7 Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Sat, 27 Apr 2024 17:07:22 +0200 Subject: Adding upstream version 3.38.6. Signed-off-by: Daniel Baumann --- src/shell-polkit-authentication-agent.h | 33 +++++++++++++++++++++++++++++++++ 1 file changed, 33 insertions(+) create mode 100644 src/shell-polkit-authentication-agent.h (limited to 'src/shell-polkit-authentication-agent.h') diff --git a/src/shell-polkit-authentication-agent.h b/src/shell-polkit-authentication-agent.h new file mode 100644 index 0000000..55b46af --- /dev/null +++ b/src/shell-polkit-authentication-agent.h @@ -0,0 +1,33 @@ +/* -*- mode: C; c-file-style: "gnu"; indent-tabs-mode: nil; -*- */ + +/* + * Copyright (C) 20011 Red Hat, Inc. + * + * Author: David Zeuthen + */ + +#pragma once + +#define POLKIT_AGENT_I_KNOW_API_IS_SUBJECT_TO_CHANGE +#include +#include + +G_BEGIN_DECLS + +/* Polkit doesn't have g_autoptr support, thus we have to manually set the autoptr function here */ +G_DEFINE_AUTOPTR_CLEANUP_FUNC (PolkitAgentListener, g_object_unref) + +#define SHELL_TYPE_POLKIT_AUTHENTICATION_AGENT (shell_polkit_authentication_agent_get_type()) + +G_DECLARE_FINAL_TYPE (ShellPolkitAuthenticationAgent, shell_polkit_authentication_agent, SHELL, POLKIT_AUTHENTICATION_AGENT, PolkitAgentListener) + +ShellPolkitAuthenticationAgent *shell_polkit_authentication_agent_new (void); + +void shell_polkit_authentication_agent_complete (ShellPolkitAuthenticationAgent *agent, + gboolean dismissed); +void shell_polkit_authentication_agent_register (ShellPolkitAuthenticationAgent *agent, + GError **error_out); +void shell_polkit_authentication_agent_unregister (ShellPolkitAuthenticationAgent *agent); + +G_END_DECLS + -- cgit v1.2.3