Commit 3fcb08fe authored by Christian Hergert's avatar Christian Hergert
Browse files

meson: add template priority

parent b79fd37b
......@@ -65,13 +65,14 @@ class MesonTemplateLocator(Template.TemplateLocator):
class MesonTemplate(Ide.TemplateBase, Ide.ProjectTemplate):
def __init__(self, id, name, icon_name, description, languages):
def __init__(self, id, name, icon_name, description, languages, priority):
super().__init__() = id = name
self.icon_name = icon_name
self.description = description
self.languages = languages
self.priority = priority
self.locator = MesonTemplateLocator()
self.props.locator = self.locator
......@@ -91,6 +92,9 @@ class MesonTemplate(Ide.TemplateBase, Ide.ProjectTemplate):
def do_get_languages(self):
return self.languages
def do_get_priority(self):
return self.priority
def do_expand_async(self, params, cancellable, callback, data):
......@@ -230,7 +234,8 @@ class GnomeProjectTemplate(MesonTemplate):
_('GNOME Application'),
_('Create a new GNOME application'),
['C', 'C++', 'C♯', 'Python', 'JavaScript', 'Vala']
['C', 'C++', 'C♯', 'Python', 'JavaScript', 'Vala'],
def prepare_files(self, files):
......@@ -298,7 +303,8 @@ class LibraryProjectTemplate(MesonTemplate):
_("Shared Library"),
_("Create a new project with a shared library"),
def prepare_files(self, files):
......@@ -316,6 +322,7 @@ class EmptyProjectTemplate(MesonTemplate):
_('Create a new empty project'),
['C', 'C++', 'JavaScript', 'Python', 'Vala'],
def prepare_files(self, files):
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