Refactor: Move UI files and gschema file to more standard locations

This commit is contained in:
June 2023-01-22 14:59:40 +01:00
commit 7ed9329f2d
No known key found for this signature in database
GPG key ID: 094C2AC34192FA11
10 changed files with 6 additions and 8 deletions

View file

@ -0,0 +1,17 @@
<?xml version="1.0" encoding="UTF-8"?>
<schemalist>
<schema id="org.gnome.shell.extensions.top-bar-organizer" path="/org/gnome/shell/extensions/top-bar-organizer/">
<key name="left-box-order" type="as">
<description>Order of items in the left box of the top bar.</description>
<default>[]</default>
</key>
<key name="center-box-order" type="as">
<description>Order of items in the center box of the top bar.</description>
<default>[]</default>
</key>
<key name="right-box-order" type="as">
<description>Order of items in the right box of the top bar.</description>
<default>[]</default>
</key>
</schema>
</schemalist>

View file

@ -0,0 +1,28 @@
<?xml version="1.0" encoding="UTF-8"?>
<interface>
<template class="PrefsBoxOrderItemRow" parent="AdwActionRow">
<child type="prefix">
<object class="GtkLabel" id="item-name-display-label">
<property name="halign">start</property>
<property name="hexpand">True</property>
</object>
</child>
<child type="prefix">
<object class="GtkImage">
<property name="icon-name">list-drag-handle-symbolic</property>
<style>
<class name="drag-handle"/>
</style>
</object>
</child>
<child type="suffix">
<object class="GtkMenuButton" id="menu-button">
<property name="valign">center</property>
<property name="icon-name">view-more-symbolic</property>
<style>
<class name="flat"/>
</style>
</object>
</child>
</template>
</interface>

View file

@ -0,0 +1,10 @@
<?xml version="1.0" encoding="UTF-8"?>
<interface>
<template class="PrefsBoxOrderListBox" parent="GtkListBox">
<property name="selection-mode">none</property>
<property name="show-separators">True</property>
<style>
<class name="boxed-list"/>
</style>
</template>
</interface>

View file

@ -0,0 +1,23 @@
<?xml version="1.0" encoding="UTF-8"?>
<interface>
<template class="PrefsBoxOrderListEmptyPlaceholder" parent="GtkBox">
<child>
<object class="GtkBox">
<property name="spacing">10</property>
<property name="margin-top">10</property>
<property name="margin-bottom">10</property>
<property name="margin-start">10</property>
<property name="margin-end">10</property>
<child>
<object class="GtkLabel">
<property name="label">Drop items onto here to add them to this box.</property>
<property name="halign">start</property>
<style>
<class name="dim-label"/>
</style>
</object>
</child>
</object>
</child>
</template>
</interface>

49
data/ui/prefs-page.ui Normal file
View file

@ -0,0 +1,49 @@
<?xml version="1.0" encoding="UTF-8"?>
<interface>
<template class="PrefsPage" parent="AdwPreferencesPage">
<child>
<object class="AdwPreferencesGroup">
<property name="title">Item Order</property>
<property name="description">Simply use drag and drop to order the items any way you want.</property>
<child>
<object class="GtkBox" id="left-box">
<property name="orientation">vertical</property>
<child>
<object class="GtkLabel">
<property name="label">Left Top Bar Box</property>
<property name="halign">start</property>
<property name="margin-bottom">12</property>
</object>
</child>
</object>
</child>
<child>
<object class="GtkBox" id="center-box">
<property name="orientation">vertical</property>
<child>
<object class="GtkLabel">
<property name="label">Center Top Bar Box</property>
<property name="halign">start</property>
<property name="margin-top">12</property>
<property name="margin-bottom">12</property>
</object>
</child>
</object>
</child>
<child>
<object class="GtkBox" id="right-box">
<property name="orientation">vertical</property>
<child>
<object class="GtkLabel">
<property name="label">Right Top Bar Box</property>
<property name="halign">start</property>
<property name="margin-top">12</property>
<property name="margin-bottom">12</property>
</object>
</child>
</object>
</child>
</object>
</child>
</template>
</interface>