[gnome-panel/wip/muktupavels/api: 1/7] libgnome-panel: add GpLockdownFlags



commit 191c6dfbf88e5816e9128d31eb48274f08b757cb
Author: Alberts Muktupāvels <alberts muktupavels gmail com>
Date:   Tue Apr 14 15:25:39 2020 +0300

    libgnome-panel: add GpLockdownFlags

 libgnome-panel/Makefile.am   |  3 +++
 libgnome-panel/gp-lockdown.h | 54 ++++++++++++++++++++++++++++++++++++++++++++
 2 files changed, 57 insertions(+)
---
diff --git a/libgnome-panel/Makefile.am b/libgnome-panel/Makefile.am
index 386b5a108..73d72a5fc 100644
--- a/libgnome-panel/Makefile.am
+++ b/libgnome-panel/Makefile.am
@@ -17,6 +17,7 @@ libgnome_panel_la_SOURCES = \
        gp-initial-setup-dialog-private.h \
        gp-initial-setup-dialog.c \
        gp-initial-setup-dialog.h \
+       gp-lockdown.h \
        gp-module-private.h \
        gp-module.c \
        gp-module.h \
@@ -56,12 +57,14 @@ libgnome_panel_include_HEADERS = \
        gp-enum-types.h \
        gp-image-menu-item.h \
        gp-initial-setup-dialog.h \
+       gp-lockdown.h \
        gp-module.h \
        gp-utils.h \
        $(NULL)
 
 ENUM_TYPES = \
        $(srcdir)/gp-applet.h \
+       gp-lockdown.h \
        $(NULL)
 
 gp-enum-types.c: gp-enum-types.c.in gp-enum-types.h $(ENUM_TYPES)
diff --git a/libgnome-panel/gp-lockdown.h b/libgnome-panel/gp-lockdown.h
new file mode 100644
index 000000000..e9e852057
--- /dev/null
+++ b/libgnome-panel/gp-lockdown.h
@@ -0,0 +1,54 @@
+/*
+ * Copyright (C) 2020 Alberts Muktupāvels
+ *
+ * This library is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as published by
+ * the Free Software Foundation; either version 2.1 of the License, or
+ * (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
+ * or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
+ * License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * along with this library; if not, see <https://www.gnu.org/licenses/>.
+ */
+
+#ifndef GP_LOCKDOWN_H
+#define GP_LOCKDOWN_H
+
+#include <glib.h>
+
+G_BEGIN_DECLS
+
+/**
+ * GpLockdownFlags:
+ * @GP_LOCKDOWN_FLAGS_NONE: No flags set.
+ * @GP_LOCKDOWN_FLAGS_APPLET: Applet is disabled.
+ * @GP_LOCKDOWN_FLAGS_FORCE_QUIT: Force quit is disabled.
+ * @GP_LOCKDOWN_FLAGS_LOCKED_DOWN: Panel is lockded down.
+ * @GP_LOCKDOWN_FLAGS_COMMAND_LINE: Command line is disabled.
+ * @GP_LOCKDOWN_FLAGS_LOCK_SCREEN: Lock screen is disabled.
+ * @GP_LOCKDOWN_FLAGS_LOG_OUT: Log out is disabled.
+ * @GP_LOCKDOWN_FLAGS_USER_SWITCHING: User switching is disabled.
+ *
+ * Flags indicating active lockdowns.
+ */
+typedef enum
+{
+  GP_LOCKDOWN_FLAGS_NONE = 0,
+
+  GP_LOCKDOWN_FLAGS_APPLET = 1 << 0,
+  GP_LOCKDOWN_FLAGS_FORCE_QUIT = 1 << 1,
+  GP_LOCKDOWN_FLAGS_LOCKED_DOWN = 1 << 2,
+
+  GP_LOCKDOWN_FLAGS_COMMAND_LINE = 1 << 3,
+  GP_LOCKDOWN_FLAGS_LOCK_SCREEN = 1 << 4,
+  GP_LOCKDOWN_FLAGS_LOG_OUT = 1 << 5,
+  GP_LOCKDOWN_FLAGS_USER_SWITCHING = 1 << 6
+} GpLockdownFlags;
+
+G_END_DECLS
+
+#endif


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]