feat: merge demo mockup UI
Co-authored-by: LolzDEV <LolzDEV@users.noreply.github.com>pull/4/head
parent
d78870b6e9
commit
a5c5038981
|
@ -12,3 +12,4 @@ vendor
|
||||||
flatpak_app/
|
flatpak_app/
|
||||||
.flatpak-builder/
|
.flatpak-builder/
|
||||||
recompile/
|
recompile/
|
||||||
|
.vscode
|
||||||
|
|
|
@ -17,32 +17,112 @@
|
||||||
</section>
|
</section>
|
||||||
</menu>
|
</menu>
|
||||||
<template class="MutinyAppWindow" parent="AdwApplicationWindow">
|
<template class="MutinyAppWindow" parent="AdwApplicationWindow">
|
||||||
<property name="content">
|
<property name="default-width">980</property>
|
||||||
<object class="GtkBox">
|
<property name="default-height">640</property>
|
||||||
<property name="orientation">vertical</property>
|
|
||||||
<child>
|
<child>
|
||||||
<object class="AdwHeaderBar" id="headerbar">
|
<object class="AdwLeaflet" id="main_leaflet">
|
||||||
|
<property name="hexpand">True</property>
|
||||||
|
|
||||||
|
<child>
|
||||||
|
<object class="GtkBox" id="sidebar_box">
|
||||||
|
<property name="hexpand">False</property>
|
||||||
|
<property name="orientation">vertical</property>
|
||||||
|
|
||||||
|
<child>
|
||||||
|
<object class="AdwHeaderBar" id="header">
|
||||||
|
<property name="show-start-title-buttons">True</property>
|
||||||
|
<property name="show-end-title-buttons" bind-source="main_leaflet" bind-property="folded" bind-flags="sync-create"/>
|
||||||
<property name="title-widget">
|
<property name="title-widget">
|
||||||
<object class="AdwWindowTitle">
|
<object class="GtkBox" id="title_box">
|
||||||
|
<property name="orientation">horizontal</property>
|
||||||
|
<property name="spacing">6</property>
|
||||||
|
<child>
|
||||||
|
<object class="AdwWindowTitle" id="sidebar_title_widget">
|
||||||
<property name="title" translatable="yes">Mutiny</property>
|
<property name="title" translatable="yes">Mutiny</property>
|
||||||
</object>
|
</object>
|
||||||
</property>
|
</child>
|
||||||
<child type="end">
|
<child>
|
||||||
<object class="GtkMenuButton" id="appmenu_button">
|
<object class="GtkButton" id="sidebar_title_button">
|
||||||
<property name="icon-name">open-menu-symbolic</property>
|
<!-- Placeholder -->
|
||||||
<property name="menu-model">primary_menu</property>
|
<property name="icon-name">emoji-food-symbolic</property>
|
||||||
</object>
|
</object>
|
||||||
</child>
|
</child>
|
||||||
</object>
|
</object>
|
||||||
|
</property>
|
||||||
|
</object>
|
||||||
|
</child>
|
||||||
|
|
||||||
|
<child>
|
||||||
|
<object class="GtkListBox">
|
||||||
|
<child>
|
||||||
|
<object class="GtkListBoxRow">
|
||||||
|
<child>
|
||||||
|
<object class="GtkBox">
|
||||||
|
<property name="margin-start">24</property>
|
||||||
|
<property name="margin-end">24</property>
|
||||||
|
<property name="margin-top">12</property>
|
||||||
|
<property name="margin-bottom">12</property>
|
||||||
|
<property name="spacing">12</property>
|
||||||
|
<child>
|
||||||
|
<object class="AdwAvatar">
|
||||||
|
<property name="text">among us</property>
|
||||||
|
<property name="size">24</property>
|
||||||
|
<property name="show-initials">true</property>
|
||||||
|
</object>
|
||||||
</child>
|
</child>
|
||||||
<child>
|
<child>
|
||||||
<object class="GtkLabel" id="label">
|
<object class="GtkLabel">
|
||||||
<property name="label" translatable="yes">Hello world!</property>
|
|
||||||
<property name="hexpand">True</property>
|
<property name="hexpand">True</property>
|
||||||
<property name="vexpand">True</property>
|
<property name="label" translatable="yes">Among Us</property>
|
||||||
|
<property name="xalign">0</property>
|
||||||
|
</object>
|
||||||
|
</child>
|
||||||
|
<child>
|
||||||
|
<object class="GtkImage">
|
||||||
|
<property name="icon_name">go-next-symbolic</property>
|
||||||
</object>
|
</object>
|
||||||
</child>
|
</child>
|
||||||
</object>
|
</object>
|
||||||
|
</child>
|
||||||
|
</object>
|
||||||
|
</child>
|
||||||
|
</object>
|
||||||
|
</child>
|
||||||
|
</object>
|
||||||
|
</child>
|
||||||
|
|
||||||
|
<child>
|
||||||
|
<object class="AdwLeafletPage">
|
||||||
|
<property name="navigatable">False</property>
|
||||||
|
<property name="child">
|
||||||
|
<object class="GtkSeparator" id="panel_separator">
|
||||||
|
<property name="orientation">vertical</property>
|
||||||
|
<style>
|
||||||
|
<class name="sidebar"/>
|
||||||
|
</style>
|
||||||
|
</object>
|
||||||
</property>
|
</property>
|
||||||
|
|
||||||
|
</object>
|
||||||
|
</child>
|
||||||
|
|
||||||
|
<child>
|
||||||
|
<object class="GtkBox">
|
||||||
|
<property name="hexpand">True</property>
|
||||||
|
<property name="orientation">vertical</property>
|
||||||
|
<child>
|
||||||
|
<object class="AdwHeaderBar">
|
||||||
|
<property name="title-widget">
|
||||||
|
<object class="AdwWindowTitle">
|
||||||
|
<property name="title" translatable="yes">Test server</property>
|
||||||
|
</object>
|
||||||
|
</property>
|
||||||
|
</object>
|
||||||
|
</child>
|
||||||
|
</object>
|
||||||
|
</child>
|
||||||
|
</object>
|
||||||
|
</child>
|
||||||
</template>
|
</template>
|
||||||
</interface>
|
</interface>
|
||||||
|
|
|
@ -14,15 +14,15 @@ mod imp {
|
||||||
#[derive(Debug, CompositeTemplate)]
|
#[derive(Debug, CompositeTemplate)]
|
||||||
#[template(resource = "/chat/revolt/Mutiny/ui/window.ui")]
|
#[template(resource = "/chat/revolt/Mutiny/ui/window.ui")]
|
||||||
pub struct MutinyAppWindow {
|
pub struct MutinyAppWindow {
|
||||||
#[template_child]
|
// #[template_child]
|
||||||
pub headerbar: TemplateChild<adw::HeaderBar>,
|
// pub headerbar: TemplateChild<adw::HeaderBar>,
|
||||||
pub settings: gio::Settings,
|
pub settings: gio::Settings,
|
||||||
}
|
}
|
||||||
|
|
||||||
impl Default for MutinyAppWindow {
|
impl Default for MutinyAppWindow {
|
||||||
fn default() -> Self {
|
fn default() -> Self {
|
||||||
Self {
|
Self {
|
||||||
headerbar: TemplateChild::default(),
|
// headerbar: TemplateChild::default(),
|
||||||
settings: gio::Settings::new(APP_ID),
|
settings: gio::Settings::new(APP_ID),
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue