ce-8021x-security-page: Port to AdwBin
We add a scrolled window.
This commit is contained in:
parent
9f86405bdd
commit
15694399dd
3 changed files with 51 additions and 40 deletions
|
@ -1,44 +1,54 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<interface>
|
||||
<!-- interface-requires gtk+ 3.0 -->
|
||||
<template class="CEPage8021xSecurity" parent="GtkGrid">
|
||||
<property name="margin_start">50</property>
|
||||
<property name="margin_end">50</property>
|
||||
<property name="margin_top">12</property>
|
||||
<property name="margin_bottom">12</property>
|
||||
<property name="hexpand">True</property>
|
||||
<property name="vexpand">True</property>
|
||||
<property name="row_spacing">10</property>
|
||||
<property name="column_spacing">6</property>
|
||||
<template class="CEPage8021xSecurity" parent="AdwBin">
|
||||
<child>
|
||||
<object class="GtkLabel" id="security_label">
|
||||
<property name="xalign">1</property>
|
||||
<property name="label" translatable="yes">802.1x _Security</property>
|
||||
<property name="use_underline">True</property>
|
||||
<property name="mnemonic_widget">enable_8021x_switch</property>
|
||||
<layout>
|
||||
<property name="column">0</property>
|
||||
<property name="row">0</property>
|
||||
</layout>
|
||||
</object>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkSwitch" id="enable_8021x_switch">
|
||||
<property name="halign">start</property>
|
||||
<property name="hexpand">True</property>
|
||||
<layout>
|
||||
<property name="column">1</property>
|
||||
<property name="row">0</property>
|
||||
</layout>
|
||||
</object>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkBox" id="box">
|
||||
<property name="orientation">vertical</property>
|
||||
<layout>
|
||||
<property name="column">0</property>
|
||||
<property name="row">1</property>
|
||||
</layout>
|
||||
<object class="GtkScrolledWindow">
|
||||
<property name="propagate-natural-height">True</property>
|
||||
<property name="propagate-natural-width">True</property>
|
||||
<child>
|
||||
<object class="GtkGrid" id="grid">
|
||||
<property name="margin_start">50</property>
|
||||
<property name="margin_end">50</property>
|
||||
<property name="margin_top">12</property>
|
||||
<property name="margin_bottom">12</property>
|
||||
<property name="hexpand">True</property>
|
||||
<property name="vexpand">True</property>
|
||||
<property name="row_spacing">10</property>
|
||||
<property name="column_spacing">6</property>
|
||||
<child>
|
||||
<object class="GtkLabel" id="security_label">
|
||||
<property name="xalign">1</property>
|
||||
<property name="label" translatable="yes">802.1x _Security</property>
|
||||
<property name="use_underline">True</property>
|
||||
<property name="mnemonic_widget">enable_8021x_switch</property>
|
||||
<layout>
|
||||
<property name="column">0</property>
|
||||
<property name="row">0</property>
|
||||
</layout>
|
||||
</object>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkSwitch" id="enable_8021x_switch">
|
||||
<property name="halign">start</property>
|
||||
<property name="hexpand">True</property>
|
||||
<layout>
|
||||
<property name="column">1</property>
|
||||
<property name="row">0</property>
|
||||
</layout>
|
||||
</object>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkBox" id="box">
|
||||
<property name="orientation">vertical</property>
|
||||
<layout>
|
||||
<property name="column">0</property>
|
||||
<property name="row">1</property>
|
||||
</layout>
|
||||
</object>
|
||||
</child>
|
||||
</object>
|
||||
</child>
|
||||
</object>
|
||||
</child>
|
||||
</template>
|
||||
|
|
|
@ -32,7 +32,7 @@
|
|||
#include "nma-ws.h"
|
||||
|
||||
struct _CEPage8021xSecurity {
|
||||
GtkGrid parent;
|
||||
AdwBin parent;
|
||||
|
||||
GtkBox *box;
|
||||
GtkSwitch *enable_8021x_switch;
|
||||
|
@ -46,7 +46,7 @@ struct _CEPage8021xSecurity {
|
|||
|
||||
static void ce_page_iface_init (CEPageInterface *);
|
||||
|
||||
G_DEFINE_TYPE_WITH_CODE (CEPage8021xSecurity, ce_page_8021x_security, GTK_TYPE_GRID,
|
||||
G_DEFINE_TYPE_WITH_CODE (CEPage8021xSecurity, ce_page_8021x_security, ADW_TYPE_BIN,
|
||||
G_IMPLEMENT_INTERFACE (ce_page_get_type (), ce_page_iface_init))
|
||||
|
||||
static void
|
||||
|
|
|
@ -22,12 +22,13 @@
|
|||
|
||||
#pragma once
|
||||
|
||||
#include <adwaita.h>
|
||||
#include <gtk/gtk.h>
|
||||
#include <NetworkManager.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
G_DECLARE_FINAL_TYPE (CEPage8021xSecurity, ce_page_8021x_security, CE, PAGE_8021X_SECURITY, GtkGrid)
|
||||
G_DECLARE_FINAL_TYPE (CEPage8021xSecurity, ce_page_8021x_security, CE, PAGE_8021X_SECURITY, AdwBin)
|
||||
|
||||
CEPage8021xSecurity *ce_page_8021x_security_new (NMConnection *connection);
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue