mirror of
https://github.com/Ryujinx/GtkSharp.git
synced 2025-01-18 14:37:18 +00:00
Upgrade .Net Core C# templates
This commit is contained in:
parent
de6f21ba80
commit
e621c368bd
|
@ -4,8 +4,8 @@
|
||||||
<id>GtkSharp.Template.CSharp</id>
|
<id>GtkSharp.Template.CSharp</id>
|
||||||
<version>3.0.0</version>
|
<version>3.0.0</version>
|
||||||
<title>Gtk template for CSharp</title>
|
<title>Gtk template for CSharp</title>
|
||||||
<summary>A simple C# template for your .Net Core Gtk Application.</summary>
|
<summary>A set of C# templates for your .Net Core Gtk Application.</summary>
|
||||||
<description>A simple C# template for your .Net Core Gtk Application.</description>
|
<description>A set of C# templates for your .Net Core Gtk Application.</description>
|
||||||
<authors>GtkSharp Contributors</authors>
|
<authors>GtkSharp Contributors</authors>
|
||||||
<owners>GtkSharp Contributors</owners>
|
<owners>GtkSharp Contributors</owners>
|
||||||
<projectUrl>https://github.com/GtkSharp/GtkSharp</projectUrl>
|
<projectUrl>https://github.com/GtkSharp/GtkSharp</projectUrl>
|
||||||
|
|
|
@ -2,11 +2,12 @@
|
||||||
"$schema": "http://json.schemastore.org/template",
|
"$schema": "http://json.schemastore.org/template",
|
||||||
"author": "GtkSharp Contributors",
|
"author": "GtkSharp Contributors",
|
||||||
"classifications": [
|
"classifications": [
|
||||||
"Console"
|
"Gtk",
|
||||||
|
"GUI App"
|
||||||
],
|
],
|
||||||
"name": "Gtk Application",
|
"name": "Gtk Application",
|
||||||
"identity": "GtkSharp.Template.CSharp",
|
"identity": "GtkSharp.Application.CSharp",
|
||||||
"groupIdentity": "GtkSharp.Template",
|
"groupIdentity": "GtkSharp.Application",
|
||||||
"shortName": "gtkapp",
|
"shortName": "gtkapp",
|
||||||
"tags": {
|
"tags": {
|
||||||
"language": "C#",
|
"language": "C#",
|
|
@ -4,8 +4,8 @@
|
||||||
<TargetFramework>netcoreapp2.0</TargetFramework>
|
<TargetFramework>netcoreapp2.0</TargetFramework>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<EmbeddedResource Include="MainWindow.glade">
|
<EmbeddedResource Include="**/*.glade">
|
||||||
<LogicalName>MainWindow.glade</LogicalName>
|
<LogicalName>%(Filename)%(Extension)</LogicalName>
|
||||||
</EmbeddedResource>
|
</EmbeddedResource>
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
|
@ -0,0 +1,32 @@
|
||||||
|
{
|
||||||
|
"$schema": "http://json.schemastore.org/template",
|
||||||
|
"author": "GtkSharp Contributors",
|
||||||
|
"classifications": [
|
||||||
|
"Gtk",
|
||||||
|
"UI"
|
||||||
|
],
|
||||||
|
"name": "Gtk Dialog",
|
||||||
|
"identity": "GtkSharp.Dialog.CSharp",
|
||||||
|
"groupIdentity": "GtkSharp.Dialog",
|
||||||
|
"shortName": "gtkdialog",
|
||||||
|
"tags": {
|
||||||
|
"language": "C#"
|
||||||
|
},
|
||||||
|
"sourceName": "Gtk_Dialog",
|
||||||
|
"primaryOutputs": [
|
||||||
|
{
|
||||||
|
"path": "Gtk_Dialog.cs"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"path": "Gtk_Dialog.glade"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"defaultName": "Gtk_Dialog",
|
||||||
|
"symbols": {
|
||||||
|
"namespace": {
|
||||||
|
"description": "Namespace for the generated files",
|
||||||
|
"replaces": "GtkNamespace",
|
||||||
|
"type": "parameter"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
|
@ -0,0 +1,23 @@
|
||||||
|
using System;
|
||||||
|
using Gtk;
|
||||||
|
using UI = Gtk.Builder.ObjectAttribute;
|
||||||
|
|
||||||
|
namespace GtkNamespace
|
||||||
|
{
|
||||||
|
class Gtk_Dialog : Dialog
|
||||||
|
{
|
||||||
|
public Gtk_Dialog() : this(new Builder("Gtk_Dialog.glade")) { }
|
||||||
|
|
||||||
|
private Gtk_Dialog(Builder builder) : base(builder.GetObject("Gtk_Dialog").Handle)
|
||||||
|
{
|
||||||
|
DefaultResponse = ResponseType.Cancel;
|
||||||
|
|
||||||
|
Response += OnResponse;
|
||||||
|
}
|
||||||
|
|
||||||
|
private void OnResponse(object o, ResponseArgs args)
|
||||||
|
{
|
||||||
|
Hide();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
|
@ -0,0 +1,51 @@
|
||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<interface>
|
||||||
|
<requires lib="gtk+" version="3.18"/>
|
||||||
|
<object class="GtkDialog" id="Gtk_Dialog">
|
||||||
|
<property name="can_focus">False</property>
|
||||||
|
<property name="default_width">320</property>
|
||||||
|
<property name="default_height">260</property>
|
||||||
|
<property name="type_hint">dialog</property>
|
||||||
|
<child internal-child="vbox">
|
||||||
|
<object class="GtkBox">
|
||||||
|
<property name="can_focus">False</property>
|
||||||
|
<property name="orientation">vertical</property>
|
||||||
|
<property name="spacing">2</property>
|
||||||
|
<child internal-child="action_area">
|
||||||
|
<object class="GtkButtonBox">
|
||||||
|
<property name="can_focus">False</property>
|
||||||
|
<property name="layout_style">end</property>
|
||||||
|
<child>
|
||||||
|
<placeholder/>
|
||||||
|
</child>
|
||||||
|
<child>
|
||||||
|
<object class="GtkButton" id="button1">
|
||||||
|
<property name="label">gtk-close</property>
|
||||||
|
<property name="visible">True</property>
|
||||||
|
<property name="can_focus">True</property>
|
||||||
|
<property name="receives_default">True</property>
|
||||||
|
<property name="use_stock">True</property>
|
||||||
|
</object>
|
||||||
|
<packing>
|
||||||
|
<property name="expand">True</property>
|
||||||
|
<property name="fill">True</property>
|
||||||
|
<property name="position">1</property>
|
||||||
|
</packing>
|
||||||
|
</child>
|
||||||
|
</object>
|
||||||
|
<packing>
|
||||||
|
<property name="expand">False</property>
|
||||||
|
<property name="fill">False</property>
|
||||||
|
<property name="position">0</property>
|
||||||
|
</packing>
|
||||||
|
</child>
|
||||||
|
<child>
|
||||||
|
<placeholder/>
|
||||||
|
</child>
|
||||||
|
</object>
|
||||||
|
</child>
|
||||||
|
<action-widgets>
|
||||||
|
<action-widget response="-7">button1</action-widget>
|
||||||
|
</action-widgets>
|
||||||
|
</object>
|
||||||
|
</interface>
|
|
@ -0,0 +1,32 @@
|
||||||
|
{
|
||||||
|
"$schema": "http://json.schemastore.org/template",
|
||||||
|
"author": "GtkSharp Contributors",
|
||||||
|
"classifications": [
|
||||||
|
"Gtk",
|
||||||
|
"UI"
|
||||||
|
],
|
||||||
|
"name": "Gtk Widget",
|
||||||
|
"identity": "GtkSharp.Widget.CSharp",
|
||||||
|
"groupIdentity": "GtkSharp.Widget",
|
||||||
|
"shortName": "gtkwidget",
|
||||||
|
"tags": {
|
||||||
|
"language": "C#"
|
||||||
|
},
|
||||||
|
"sourceName": "Gtk_Widget",
|
||||||
|
"primaryOutputs": [
|
||||||
|
{
|
||||||
|
"path": "Gtk_Widget.cs"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"path": "Gtk_Widget.glade"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"defaultName": "Gtk_Widget",
|
||||||
|
"symbols": {
|
||||||
|
"namespace": {
|
||||||
|
"description": "Namespace for the generated files",
|
||||||
|
"replaces": "GtkNamespace",
|
||||||
|
"type": "parameter"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
|
@ -0,0 +1,16 @@
|
||||||
|
using System;
|
||||||
|
using Gtk;
|
||||||
|
using UI = Gtk.Builder.ObjectAttribute;
|
||||||
|
|
||||||
|
namespace GtkNamespace
|
||||||
|
{
|
||||||
|
public class Gtk_Widget : Box
|
||||||
|
{
|
||||||
|
public Gtk_Widget() : this(new Builder("Gtk_Widget.glade")) { }
|
||||||
|
|
||||||
|
private Gtk_Widget(Builder builder) : base(builder.GetObject("Gtk_Widget").Handle)
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
|
@ -0,0 +1,11 @@
|
||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<interface>
|
||||||
|
<requires lib="gtk+" version="3.18"/>
|
||||||
|
<object class="GtkBox" id="${EscapedIdentifier}">
|
||||||
|
<property name="visible">True</property>
|
||||||
|
<property name="can_focus">False</property>
|
||||||
|
<child>
|
||||||
|
<placeholder/>
|
||||||
|
</child>
|
||||||
|
</object>
|
||||||
|
</interface>
|
|
@ -0,0 +1,32 @@
|
||||||
|
{
|
||||||
|
"$schema": "http://json.schemastore.org/template",
|
||||||
|
"author": "GtkSharp Contributors",
|
||||||
|
"classifications": [
|
||||||
|
"Gtk",
|
||||||
|
"UI"
|
||||||
|
],
|
||||||
|
"name": "Gtk Window",
|
||||||
|
"identity": "GtkSharp.Window.CSharp",
|
||||||
|
"groupIdentity": "GtkSharp.Window",
|
||||||
|
"shortName": "gtkwindow",
|
||||||
|
"tags": {
|
||||||
|
"language": "C#"
|
||||||
|
},
|
||||||
|
"sourceName": "Gtk_Window",
|
||||||
|
"primaryOutputs": [
|
||||||
|
{
|
||||||
|
"path": "Gtk_Window.cs"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"path": "Gtk_Window.glade"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"defaultName": "Gtk_Window",
|
||||||
|
"symbols": {
|
||||||
|
"namespace": {
|
||||||
|
"description": "Namespace for the generated files",
|
||||||
|
"replaces": "GtkNamespace",
|
||||||
|
"type": "parameter"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
|
@ -0,0 +1,23 @@
|
||||||
|
using System;
|
||||||
|
using Gtk;
|
||||||
|
using UI = Gtk.Builder.ObjectAttribute;
|
||||||
|
|
||||||
|
namespace GtkNamespace
|
||||||
|
{
|
||||||
|
class Gtk_Window : Window
|
||||||
|
{
|
||||||
|
public Gtk_Window() : this(new Builder("Gtk_Window.glade")) { }
|
||||||
|
|
||||||
|
private Gtk_Window(Builder builder) : base(builder.GetObject("Gtk_Window").Handle)
|
||||||
|
{
|
||||||
|
builder.Autoconnect(this);
|
||||||
|
|
||||||
|
DeleteEvent += OnDeleteEvent;
|
||||||
|
}
|
||||||
|
|
||||||
|
private void OnDeleteEvent(object sender, DeleteEventArgs a)
|
||||||
|
{
|
||||||
|
Application.Quit();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
|
@ -0,0 +1,11 @@
|
||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<interface>
|
||||||
|
<requires lib="gtk+" version="3.18"/>
|
||||||
|
<object class="GtkWindow" id="Gtk_Window">
|
||||||
|
<property name="can_focus">False</property>
|
||||||
|
<property name="title" translatable="yes">Gtk_Window</property>
|
||||||
|
<child>
|
||||||
|
<placeholder/>
|
||||||
|
</child>
|
||||||
|
</object>
|
||||||
|
</interface>
|
|
@ -6,7 +6,7 @@
|
||||||
// VARS
|
// VARS
|
||||||
|
|
||||||
Settings.Cake = Context;
|
Settings.Cake = Context;
|
||||||
Settings.Version = "3.22.24.11";
|
Settings.Version = "3.22.24.12";
|
||||||
Settings.BuildTarget = Argument("BuildTarget", "Default");
|
Settings.BuildTarget = Argument("BuildTarget", "Default");
|
||||||
Settings.Assembly = Argument("Assembly", "");
|
Settings.Assembly = Argument("Assembly", "");
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue