Commit 3e3c7734 authored by Nico Alt's avatar Nico Alt

Create ui specific meson.build

parent 56553840
......@@ -14,7 +14,7 @@ from briar_gtk.define import APP
class AddContactContainer(Container):
ADD_CONTACT_UI = "/app/briar/gtk/ui/add_contact.ui"
ADD_CONTACT_UI = "/app/briar/gtk/add_contact.ui"
STACK_NAME = "add_contact_flow_stack"
HEADERS_NAME = "add_contact_flow_headers"
......
......@@ -10,7 +10,7 @@ from briar_gtk.define import APP
class LoginContainer(Container):
LOGIN_UI = "/app/briar/gtk/ui/login.ui"
LOGIN_UI = "/app/briar/gtk/login.ui"
STACK_NAME = "login_flow_stack"
HEADERS_NAME = "login_flow_headers"
......
......@@ -19,7 +19,7 @@ from briar_gtk.widgets.private_message import PrivateMessageWidget
# pylint: disable=too-few-public-methods
class PrivateChatContainer(Container):
CONTAINER_UI = "/app/briar/gtk/ui/private_chat.ui"
CONTAINER_UI = "/app/briar/gtk/private_chat.ui"
def __init__(self, contact_name, contact_id):
super().__init__()
......
......@@ -12,7 +12,7 @@ from briar_gtk.define import APP
class RegistrationContainer(Container):
REGISTRATION_UI = "/app/briar/gtk/ui/registration.ui"
REGISTRATION_UI = "/app/briar/gtk/registration.ui"
STACK_NAME = "registration_flow_stack"
HEADERS_NAME = "registration_flow_headers"
......
......@@ -10,7 +10,7 @@ from gi.repository import Gio
APPLICATION_ID = "app.briar.gtk"
APPLICATION_NAME = "Briar"
APPLICATION_STYLING_PATH = "resource:///app/briar/gtk/ui/application.css"
APPLICATION_STYLING_PATH = "resource:///app/briar/gtk/application.css"
BRIAR_HEADLESS_JAR = "/app/briar/briar-headless.jar"
APP = Gio.Application.get_default
......@@ -44,20 +44,5 @@ if compile_schemas.found()
)
endif
pkgdatadir = join_paths(get_option('prefix'), get_option('datadir'), meson.project_name())
gnome = import('gnome')
gnome.compile_resources('briar-gtk',
'ui/app.briar.gtk.gresource.xml',
gresource_bundle: true,
install: true,
install_dir: pkgdatadir,
dependencies: configure_file(
input: 'ui/about_dialog.ui.in',
output: 'about_dialog.ui',
configuration: conf
)
)
subdir('ui')
subdir('icons')
<?xml version="1.0" encoding="UTF-8"?>
<gresources>
<gresource prefix="/app/briar/gtk">
<file compressed="true">ui/application.css</file>
<file compressed="true" preprocess="xml-stripblanks">ui/add_contact.ui</file>
<file compressed="true" preprocess="xml-stripblanks">ui/login.ui</file>
<file compressed="true" preprocess="xml-stripblanks">ui/main_window.ui</file>
<file compressed="true" preprocess="xml-stripblanks">ui/private_chat.ui</file>
<file compressed="true" preprocess="xml-stripblanks">ui/registration.ui</file>
<file compressed="true">application.css</file>
<file compressed="true" preprocess="xml-stripblanks">add_contact.ui</file>
<file compressed="true" preprocess="xml-stripblanks">login.ui</file>
<file compressed="true" preprocess="xml-stripblanks">main_menu.ui</file>
<file compressed="true" preprocess="xml-stripblanks">main_window.ui</file>
<file compressed="true" preprocess="xml-stripblanks">private_chat.ui</file>
<file compressed="true" preprocess="xml-stripblanks">registration.ui</file>
<file compressed="true" preprocess="xml-stripblanks">about_dialog.ui</file>
</gresource>
</gresources>
# Copyright (c) 2020 Nico Alt
# SPDX-License-Identifier: AGPL-3.0-only
# License-Filename: LICENSE.md
pkgdatadir = join_paths(get_option('prefix'), get_option('datadir'), meson.project_name())
gnome = import('gnome')
gnome.compile_resources('briar-gtk',
'app.briar.gtk.gresource.xml',
gresource_bundle: true,
install: true,
install_dir: pkgdatadir,
dependencies: configure_file(
input: 'about_dialog.ui.in',
output: 'about_dialog.ui',
configuration: conf
)
)
......@@ -14,14 +14,12 @@ function generate_resource()
for file in briar-gtk/data/ui/*.css
do
echo -n ' <file compressed="true">'
echo -n 'ui/'
echo -n $(basename $file)
echo '</file>'
done
for file in briar-gtk/data/ui/*.ui
for file in briar-gtk/data/ui/*.ui about_dialog.ui
do
echo -n ' <file compressed="true" preprocess="xml-stripblanks">'
echo -n 'ui/'
echo -n $(basename $file)
echo '</file>'
done
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment