RemoteAgents: Mono GTK Linux implementation. WIP.
authorgu.martinm@gmail.com <gu.martinm@gmail.com>
Sat, 22 Feb 2014 13:03:23 +0000 (14:03 +0100)
committergu.martinm@gmail.com <gu.martinm@gmail.com>
Sat, 22 Feb 2014 13:03:23 +0000 (14:03 +0100)
12 files changed:
Mono/RemoteAgents/GTKLinux/GTKLinux.sln [new file with mode: 0644]
Mono/RemoteAgents/GTKLinux/GTKLinux.userprefs [new file with mode: 0644]
Mono/RemoteAgents/GTKLinux/GTKLinux/GTKLinux.csproj [new file with mode: 0644]
Mono/RemoteAgents/GTKLinux/GTKLinux/MainWindow.cs [new file with mode: 0644]
Mono/RemoteAgents/GTKLinux/GTKLinux/Model/CallRemoteProcedure.cs [new file with mode: 0644]
Mono/RemoteAgents/GTKLinux/GTKLinux/Program.cs [new file with mode: 0644]
Mono/RemoteAgents/GTKLinux/GTKLinux/Properties/AssemblyInfo.cs [new file with mode: 0644]
Mono/RemoteAgents/GTKLinux/GTKLinux/View/View.cs [new file with mode: 0644]
Mono/RemoteAgents/GTKLinux/GTKLinux/ViewModel/ViewModel.cs [new file with mode: 0644]
Mono/RemoteAgents/GTKLinux/GTKLinux/gtk-gui/Example.RemoteAgents.GTKLinux.MainWindow.cs [new file with mode: 0644]
Mono/RemoteAgents/GTKLinux/GTKLinux/gtk-gui/generated.cs [new file with mode: 0644]
Mono/RemoteAgents/GTKLinux/GTKLinux/gtk-gui/gui.stetic [new file with mode: 0644]

diff --git a/Mono/RemoteAgents/GTKLinux/GTKLinux.sln b/Mono/RemoteAgents/GTKLinux/GTKLinux.sln
new file mode 100644 (file)
index 0000000..4a9f35d
--- /dev/null
@@ -0,0 +1,179 @@
+
+Microsoft Visual Studio Solution File, Format Version 12.00
+# Visual Studio 2012
+Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "GTKLinux", "GTKLinux\GTKLinux.csproj", "{F58086C1-1E2F-459C-B8BE-269A245C09A2}"
+EndProject
+Global
+       GlobalSection(SolutionConfigurationPlatforms) = preSolution
+               Debug|x86 = Debug|x86
+               Release|x86 = Release|x86
+       EndGlobalSection
+       GlobalSection(ProjectConfigurationPlatforms) = postSolution
+               {F58086C1-1E2F-459C-B8BE-269A245C09A2}.Debug|x86.ActiveCfg = Debug|x86
+               {F58086C1-1E2F-459C-B8BE-269A245C09A2}.Debug|x86.Build.0 = Debug|x86
+               {F58086C1-1E2F-459C-B8BE-269A245C09A2}.Release|x86.ActiveCfg = Release|x86
+               {F58086C1-1E2F-459C-B8BE-269A245C09A2}.Release|x86.Build.0 = Release|x86
+       EndGlobalSection
+       GlobalSection(MonoDevelopProperties) = preSolution
+               StartupItem = GTKLinux\GTKLinux.csproj
+               Policies = $0
+               $0.DotNetNamingPolicy = $1
+               $1.DirectoryNamespaceAssociation = None
+               $1.ResourceNamePolicy = FileFormatDefault
+               $0.StandardHeader = $2
+               $2.Text = 
+               $2.IncludeInNewFiles = True
+               $0.NameConventionPolicy = $3
+               $3.Rules = $4
+               $4.NamingRule = $5
+               $5.Name = Namespaces
+               $5.AffectedEntity = Namespace
+               $5.VisibilityMask = VisibilityMask
+               $5.NamingStyle = PascalCase
+               $5.IncludeInstanceMembers = True
+               $5.IncludeStaticEntities = True
+               $4.NamingRule = $6
+               $6.Name = Types
+               $6.AffectedEntity = Class, Struct, Enum, Delegate
+               $6.VisibilityMask = Public
+               $6.NamingStyle = PascalCase
+               $6.IncludeInstanceMembers = True
+               $6.IncludeStaticEntities = True
+               $4.NamingRule = $7
+               $7.Name = Interfaces
+               $7.RequiredPrefixes = $8
+               $8.String = I
+               $7.AffectedEntity = Interface
+               $7.VisibilityMask = Public
+               $7.NamingStyle = PascalCase
+               $7.IncludeInstanceMembers = True
+               $7.IncludeStaticEntities = True
+               $4.NamingRule = $9
+               $9.Name = Attributes
+               $9.RequiredSuffixes = $10
+               $10.String = Attribute
+               $9.AffectedEntity = CustomAttributes
+               $9.VisibilityMask = Public
+               $9.NamingStyle = PascalCase
+               $9.IncludeInstanceMembers = True
+               $9.IncludeStaticEntities = True
+               $4.NamingRule = $11
+               $11.Name = Event Arguments
+               $11.RequiredSuffixes = $12
+               $12.String = EventArgs
+               $11.AffectedEntity = CustomEventArgs
+               $11.VisibilityMask = Public
+               $11.NamingStyle = PascalCase
+               $11.IncludeInstanceMembers = True
+               $11.IncludeStaticEntities = True
+               $4.NamingRule = $13
+               $13.Name = Exceptions
+               $13.RequiredSuffixes = $14
+               $14.String = Exception
+               $13.AffectedEntity = CustomExceptions
+               $13.VisibilityMask = VisibilityMask
+               $13.NamingStyle = PascalCase
+               $13.IncludeInstanceMembers = True
+               $13.IncludeStaticEntities = True
+               $4.NamingRule = $15
+               $15.Name = Methods
+               $15.AffectedEntity = Methods
+               $15.VisibilityMask = Protected, Public
+               $15.NamingStyle = PascalCase
+               $15.IncludeInstanceMembers = True
+               $15.IncludeStaticEntities = True
+               $4.NamingRule = $16
+               $16.Name = Static Readonly Fields
+               $16.AffectedEntity = ReadonlyField
+               $16.VisibilityMask = Protected, Public
+               $16.NamingStyle = PascalCase
+               $16.IncludeInstanceMembers = False
+               $16.IncludeStaticEntities = True
+               $4.NamingRule = $17
+               $17.Name = Fields
+               $17.AffectedEntity = Field
+               $17.VisibilityMask = Protected, Public
+               $17.NamingStyle = PascalCase
+               $17.IncludeInstanceMembers = True
+               $17.IncludeStaticEntities = True
+               $4.NamingRule = $18
+               $18.Name = ReadOnly Fields
+               $18.AffectedEntity = ReadonlyField
+               $18.VisibilityMask = Protected, Public
+               $18.NamingStyle = PascalCase
+               $18.IncludeInstanceMembers = True
+               $18.IncludeStaticEntities = False
+               $4.NamingRule = $19
+               $19.Name = Constant Fields
+               $19.AffectedEntity = ConstantField
+               $19.VisibilityMask = Protected, Public
+               $19.NamingStyle = PascalCase
+               $19.IncludeInstanceMembers = True
+               $19.IncludeStaticEntities = True
+               $4.NamingRule = $20
+               $20.Name = Properties
+               $20.AffectedEntity = Property
+               $20.VisibilityMask = Protected, Public
+               $20.NamingStyle = PascalCase
+               $20.IncludeInstanceMembers = True
+               $20.IncludeStaticEntities = True
+               $4.NamingRule = $21
+               $21.Name = Events
+               $21.AffectedEntity = Event
+               $21.VisibilityMask = Protected, Public
+               $21.NamingStyle = PascalCase
+               $21.IncludeInstanceMembers = True
+               $21.IncludeStaticEntities = True
+               $4.NamingRule = $22
+               $22.Name = Enum Members
+               $22.AffectedEntity = EnumMember
+               $22.VisibilityMask = VisibilityMask
+               $22.NamingStyle = PascalCase
+               $22.IncludeInstanceMembers = True
+               $22.IncludeStaticEntities = True
+               $4.NamingRule = $23
+               $23.Name = Parameters
+               $23.AffectedEntity = Parameter
+               $23.VisibilityMask = VisibilityMask
+               $23.NamingStyle = CamelCase
+               $23.IncludeInstanceMembers = True
+               $23.IncludeStaticEntities = True
+               $4.NamingRule = $24
+               $24.Name = Type Parameters
+               $24.RequiredPrefixes = $25
+               $25.String = T
+               $24.AffectedEntity = TypeParameter
+               $24.VisibilityMask = VisibilityMask
+               $24.NamingStyle = PascalCase
+               $24.IncludeInstanceMembers = True
+               $24.IncludeStaticEntities = True
+               $0.TextStylePolicy = $26
+               $26.FileWidth = 120
+               $26.TabsToSpaces = False
+               $26.EolMarker = Unix
+               $26.inheritsSet = VisualStudio
+               $26.inheritsScope = text/plain
+               $26.scope = text/plain
+               $0.TextStylePolicy = $27
+               $27.FileWidth = 120
+               $27.IndentWidth = 2
+               $27.EolMarker = Unix
+               $27.inheritsSet = VisualStudio
+               $27.inheritsScope = text/plain
+               $27.scope = text/x-csharp
+               $0.CSharpFormattingPolicy = $28
+               $28.IndentSwitchBody = True
+               $28.StatementBraceStyle = NextLineShifted2
+               $28.BeforeMethodDeclarationParentheses = False
+               $28.BeforeMethodCallParentheses = False
+               $28.BeforeConstructorDeclarationParentheses = False
+               $28.BeforeIndexerDeclarationBracket = False
+               $28.BeforeDelegateDeclarationParentheses = False
+               $28.NewParentheses = False
+               $28.SpacesBeforeBrackets = False
+               $28.inheritsSet = Mono
+               $28.inheritsScope = text/x-csharp
+               $28.scope = text/x-csharp
+               description = @Little program to connect with remote applications\nthrough JSON API.
+       EndGlobalSection
+EndGlobal
diff --git a/Mono/RemoteAgents/GTKLinux/GTKLinux.userprefs b/Mono/RemoteAgents/GTKLinux/GTKLinux.userprefs
new file mode 100644 (file)
index 0000000..2891302
--- /dev/null
@@ -0,0 +1,18 @@
+<Properties>
+  <AuthorInfo Name="Gustavo" Email="" Copyright="Gustavo Martin Morcuende" Company="gumartinm.name" Trademark="Gustavo Martin Morcuende" />
+  <MonoDevelop.Ide.Workspace ActiveConfiguration="Debug|x86" />
+  <MonoDevelop.Ide.Workbench ActiveDocument="GTKLinux/Model/CallRemoteProcedure.cs">
+    <Files>
+      <File FileName="GTKLinux/Program.cs" Line="11" Column="30" />
+      <File FileName="GTKLinux/ViewModel/ViewModel.cs" Line="1" Column="1" />
+      <File FileName="GTKLinux/Model/CallRemoteProcedure.cs" Line="30" Column="6" />
+      <File FileName="GTKLinux/Properties/AssemblyInfo.cs" Line="1" Column="1" />
+      <File FileName="GTKLinux/MainWindow.cs" Line="1" Column="1" />
+      <File FileName="GTKLinux/View/View.cs" Line="1" Column="1" />
+    </Files>
+  </MonoDevelop.Ide.Workbench>
+  <MonoDevelop.Ide.DebuggingService.Breakpoints>
+    <BreakpointStore />
+  </MonoDevelop.Ide.DebuggingService.Breakpoints>
+  <MonoDevelop.Ide.DebuggingService.PinnedWatches />
+</Properties>
\ No newline at end of file
diff --git a/Mono/RemoteAgents/GTKLinux/GTKLinux/GTKLinux.csproj b/Mono/RemoteAgents/GTKLinux/GTKLinux/GTKLinux.csproj
new file mode 100644 (file)
index 0000000..21f6fec
--- /dev/null
@@ -0,0 +1,85 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+  <PropertyGroup>
+    <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
+    <Platform Condition=" '$(Platform)' == '' ">x86</Platform>
+    <ProductVersion>12.0.0</ProductVersion>
+    <SchemaVersion>2.0</SchemaVersion>
+    <ProjectGuid>{F58086C1-1E2F-459C-B8BE-269A245C09A2}</ProjectGuid>
+    <OutputType>WinExe</OutputType>
+    <RootNamespace>GTKLinux</RootNamespace>
+    <AssemblyName>GTKLinux</AssemblyName>
+    <TargetFrameworkVersion>v4.5</TargetFrameworkVersion>
+  </PropertyGroup>
+  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|x86' ">
+    <DebugSymbols>true</DebugSymbols>
+    <DebugType>full</DebugType>
+    <Optimize>false</Optimize>
+    <OutputPath>bin\Debug</OutputPath>
+    <DefineConstants>DEBUG;</DefineConstants>
+    <ErrorReport>prompt</ErrorReport>
+    <WarningLevel>4</WarningLevel>
+    <ConsolePause>false</ConsolePause>
+    <PlatformTarget>x86</PlatformTarget>
+  </PropertyGroup>
+  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|x86' ">
+    <DebugType>full</DebugType>
+    <Optimize>true</Optimize>
+    <OutputPath>bin\Release</OutputPath>
+    <ErrorReport>prompt</ErrorReport>
+    <WarningLevel>4</WarningLevel>
+    <ConsolePause>false</ConsolePause>
+    <PlatformTarget>x86</PlatformTarget>
+  </PropertyGroup>
+  <ItemGroup>
+    <Reference Include="System" />
+    <Reference Include="gtk-sharp, Version=2.4.0.0, Culture=neutral, PublicKeyToken=35e10195dab3c99f">
+      <SpecificVersion>False</SpecificVersion>
+    </Reference>
+    <Reference Include="gdk-sharp, Version=2.4.0.0, Culture=neutral, PublicKeyToken=35e10195dab3c99f">
+      <SpecificVersion>False</SpecificVersion>
+    </Reference>
+    <Reference Include="glib-sharp, Version=2.4.0.0, Culture=neutral, PublicKeyToken=35e10195dab3c99f">
+      <SpecificVersion>False</SpecificVersion>
+    </Reference>
+    <Reference Include="glade-sharp, Version=2.4.0.0, Culture=neutral, PublicKeyToken=35e10195dab3c99f">
+      <SpecificVersion>False</SpecificVersion>
+    </Reference>
+    <Reference Include="pango-sharp, Version=2.4.0.0, Culture=neutral, PublicKeyToken=35e10195dab3c99f">
+      <SpecificVersion>False</SpecificVersion>
+    </Reference>
+    <Reference Include="atk-sharp, Version=2.4.0.0, Culture=neutral, PublicKeyToken=35e10195dab3c99f">
+      <SpecificVersion>False</SpecificVersion>
+    </Reference>
+    <Reference Include="Mono.Posix" />
+    <Reference Include="System.Net.Http">
+      <HintPath>..\..\..\..\..\..\..\..\usr\mymono\lib\mono\4.5\System.Net.Http.dll</HintPath>
+    </Reference>
+    <Reference Include="Newtonsoft.Json, Version=4.5.0.0, Culture=neutral, PublicKeyToken=c7439020c8fedf87">
+      <Package>monodevelop</Package>
+    </Reference>
+  </ItemGroup>
+  <ItemGroup>
+    <EmbeddedResource Include="gtk-gui\gui.stetic">
+      <LogicalName>gui.stetic</LogicalName>
+    </EmbeddedResource>
+  </ItemGroup>
+  <ItemGroup>
+    <Compile Include="gtk-gui\generated.cs" />
+    <Compile Include="Program.cs" />
+    <Compile Include="Properties\AssemblyInfo.cs" />
+    <Compile Include="ViewModel\ViewModel.cs" />
+    <Compile Include="Model\CallRemoteProcedure.cs" />
+    <Compile Include="MainWindow.cs">
+      <DependentUpon>Program.cs</DependentUpon>
+    </Compile>
+    <Compile Include="gtk-gui\Example.RemoteAgents.GTKLinux.MainWindow.cs" />
+    <Compile Include="View\View.cs" />
+  </ItemGroup>
+  <Import Project="$(MSBuildBinPath)\Microsoft.CSharp.targets" />
+  <ItemGroup>
+    <Folder Include="Model\" />
+    <Folder Include="ViewModel\" />
+    <Folder Include="View\" />
+  </ItemGroup>
+</Project>
\ No newline at end of file
diff --git a/Mono/RemoteAgents/GTKLinux/GTKLinux/MainWindow.cs b/Mono/RemoteAgents/GTKLinux/GTKLinux/MainWindow.cs
new file mode 100644 (file)
index 0000000..22371ca
--- /dev/null
@@ -0,0 +1,40 @@
+using System;
+using Gtk;
+using System.Net.Http;
+using System.Threading.Tasks;
+using Example.RemoteAgents.GTKLinux.View;
+
+namespace Example.RemoteAgents.GTKLinux
+{
+    public partial class MainWindow: Gtk.Window
+    {
+        ViewImpl view;
+
+           public MainWindow () : base (Gtk.WindowType.Toplevel)
+           {
+            view = new ViewImpl();
+                   Build ();
+                   this.RetrieveRemoteDateButton.Clicked += this.ButtonClicked;
+            this.ButtonGetDate.Clicked += this.ButtonGetDateClicked;
+           }
+
+           protected void OnDeleteEvent (object sender, DeleteEventArgs a)
+           {
+                   Application.Quit ();
+                   a.RetVal = true;
+           }
+
+           async private void ButtonClicked(object sender, EventArgs a)
+           {
+                   using (HttpClient client = new HttpClient ()) {
+                Task<string> resultGET = client.GetStringAsync ("http://gumartinm.name");
+                this.RemoteDate.Buffer.Text = await resultGET;
+               }
+           }
+
+        async private void ButtonGetDateClicked(object sender, EventArgs a)
+        {
+            this.RemoteDate.Buffer.Text = await view.getCurrentDate();
+        }
+    }
+}
diff --git a/Mono/RemoteAgents/GTKLinux/GTKLinux/Model/CallRemoteProcedure.cs b/Mono/RemoteAgents/GTKLinux/GTKLinux/Model/CallRemoteProcedure.cs
new file mode 100644 (file)
index 0000000..a8d633f
--- /dev/null
@@ -0,0 +1,64 @@
+using System;
+using System.Runtime.Remoting.Messaging;
+using Newtonsoft.Json;
+using System.Net.Http;
+using System.Runtime.Remoting.Lifetime;
+using System.Threading.Tasks;
+using Gtk;
+using System.Reflection;
+using System.Net;
+using System.Security.Cryptography.X509Certificates;
+
+namespace Example.RemoteAgents.GTKLinux.Model
+{
+  public class CallRemoteProcedure
+  {
+
+    async public Task<TResult> callRemoteService<TResult>(string uri, string method)
+    {
+      POSTResult<TResult> postResult;
+      POST postData = new POST();
+      postData.id = "2114567586433855105";
+      postData.jsonrpc = "2.0";
+      postData.method = method;
+
+      string data = JsonConvert.SerializeObject(postData);
+      HttpContent content = new StringContent(data, System.Text.Encoding.UTF8, "application/json-rpc");
+
+      HttpResponseMessage response = await this.issueCall(uri, content);
+
+      //if (response.StatusCode == HttpStatusCode.OK) {
+        Task<byte[]> responseBytes = response.Content.ReadAsByteArrayAsync();
+        string responseString = System.Text.Encoding.UTF8.GetString(responseBytes.Result);
+        postResult = JsonConvert.DeserializeObject<POSTResult<TResult>>(responseString);
+      //}
+
+      return postResult.result;
+    }
+
+
+    async private Task<HttpResponseMessage> issueCall(string uri, HttpContent content)
+    {
+        using (HttpClient client = new HttpClient())
+        {
+            return await client.PostAsync(uri, content);
+        }
+    }
+
+    private class POST
+    {
+      public string id { get; set; }
+      public string jsonrpc { get; set; }
+      public string method { get; set; }
+    }
+      
+
+    private class POSTResult<TResult>
+    {
+      public string id { get; set; }
+      public string jsonrpc { get; set; }
+      public TResult result { get; set; }
+    }
+  }
+}
+
diff --git a/Mono/RemoteAgents/GTKLinux/GTKLinux/Program.cs b/Mono/RemoteAgents/GTKLinux/GTKLinux/Program.cs
new file mode 100644 (file)
index 0000000..60b38fc
--- /dev/null
@@ -0,0 +1,16 @@
+using System;
+using Gtk;
+
+namespace Example.RemoteAgents.GTKLinux
+{
+       class MainClass
+       {
+               public static void Main (string[] args)
+               {
+                       Application.Init ();
+                       MainWindow win = new MainWindow ();
+                       win.Show ();
+                       Application.Run ();
+               }
+       }
+}
diff --git a/Mono/RemoteAgents/GTKLinux/GTKLinux/Properties/AssemblyInfo.cs b/Mono/RemoteAgents/GTKLinux/GTKLinux/Properties/AssemblyInfo.cs
new file mode 100644 (file)
index 0000000..7b2678f
--- /dev/null
@@ -0,0 +1,22 @@
+using System.Reflection;
+using System.Runtime.CompilerServices;
+
+// Information about this assembly is defined by the following attributes.
+// Change them to the values specific to your project.
+[assembly: AssemblyTitle("GTKLinux")]
+[assembly: AssemblyDescription("")]
+[assembly: AssemblyConfiguration("")]
+[assembly: AssemblyCompany("")]
+[assembly: AssemblyProduct("")]
+[assembly: AssemblyCopyright("gustavo")]
+[assembly: AssemblyTrademark("")]
+[assembly: AssemblyCulture("")]
+// The assembly version has the format "{Major}.{Minor}.{Build}.{Revision}".
+// The form "{Major}.{Minor}.*" will automatically update the build and revision,
+// and "{Major}.{Minor}.{Build}.*" will update just the revision.
+[assembly: AssemblyVersion("1.0.*")]
+// The following attributes are used to specify the signing key for the assembly,
+// if desired. See the Mono documentation for more information about signing.
+//[assembly: AssemblyDelaySign(false)]
+//[assembly: AssemblyKeyFile("")]
+
diff --git a/Mono/RemoteAgents/GTKLinux/GTKLinux/View/View.cs b/Mono/RemoteAgents/GTKLinux/GTKLinux/View/View.cs
new file mode 100644 (file)
index 0000000..f35dc80
--- /dev/null
@@ -0,0 +1,18 @@
+using System;
+using System.Threading.Tasks;
+using Example.RemoteAgents.GTKLinux.ViewModel;
+
+
+namespace Example.RemoteAgents.GTKLinux.View
+{
+  public class ViewImpl
+  {
+    private static readonly ViewModelImpl vm = new ViewModelImpl();
+
+    async public Task<string> getCurrentDate()
+    {
+      return await vm.getCurrentDate();
+    }
+  }
+}
+
diff --git a/Mono/RemoteAgents/GTKLinux/GTKLinux/ViewModel/ViewModel.cs b/Mono/RemoteAgents/GTKLinux/GTKLinux/ViewModel/ViewModel.cs
new file mode 100644 (file)
index 0000000..e6b7f30
--- /dev/null
@@ -0,0 +1,18 @@
+using System;
+using System.Threading.Tasks;
+using Example.RemoteAgents.GTKLinux.Model;
+
+namespace Example.RemoteAgents.GTKLinux.ViewModel
+{
+  public class ViewModelImpl
+  {
+    private static readonly string uri = "gumartinm.name";
+    private static readonly CallRemoteProcedure remoteProcedure = new CallRemoteProcedure();
+
+    async public Task<string> getCurrentDate()
+    {
+      return await remoteProcedure.callRemoteService<string>(uri, "getCurrentDate");
+    }
+  }
+}
+
diff --git a/Mono/RemoteAgents/GTKLinux/GTKLinux/gtk-gui/Example.RemoteAgents.GTKLinux.MainWindow.cs b/Mono/RemoteAgents/GTKLinux/GTKLinux/gtk-gui/Example.RemoteAgents.GTKLinux.MainWindow.cs
new file mode 100644 (file)
index 0000000..12e792d
--- /dev/null
@@ -0,0 +1,74 @@
+
+// This file has been generated by the GUI designer. Do not modify.
+namespace Example.RemoteAgents.GTKLinux
+{
+       public partial class MainWindow
+       {
+               private global::Gtk.VBox vbox3;
+               private global::Gtk.TextView RemoteDate;
+               private global::Gtk.HBox hbox2;
+               private global::Gtk.Button ButtonGetDate;
+               private global::Gtk.Button RetrieveRemoteDateButton;
+
+               protected virtual void Build ()
+               {
+                       global::Stetic.Gui.Initialize (this);
+                       // Widget Example.RemoteAgents.GTKLinux.MainWindow
+                       this.Name = "Example.RemoteAgents.GTKLinux.MainWindow";
+                       this.Title = global::Mono.Unix.Catalog.GetString ("MainWindow");
+                       this.WindowPosition = ((global::Gtk.WindowPosition)(4));
+                       // Container child Example.RemoteAgents.GTKLinux.MainWindow.Gtk.Container+ContainerChild
+                       this.vbox3 = new global::Gtk.VBox ();
+                       this.vbox3.Name = "vbox3";
+                       this.vbox3.Spacing = 6;
+                       // Container child vbox3.Gtk.Box+BoxChild
+                       this.RemoteDate = new global::Gtk.TextView ();
+                       this.RemoteDate.CanFocus = true;
+                       this.RemoteDate.Name = "RemoteDate";
+                       this.RemoteDate.Editable = false;
+                       this.RemoteDate.CursorVisible = false;
+                       this.vbox3.Add (this.RemoteDate);
+                       global::Gtk.Box.BoxChild w1 = ((global::Gtk.Box.BoxChild)(this.vbox3 [this.RemoteDate]));
+                       w1.Position = 0;
+                       // Container child vbox3.Gtk.Box+BoxChild
+                       this.hbox2 = new global::Gtk.HBox ();
+                       this.hbox2.Name = "hbox2";
+                       this.hbox2.Spacing = 6;
+                       // Container child hbox2.Gtk.Box+BoxChild
+                       this.ButtonGetDate = new global::Gtk.Button ();
+                       this.ButtonGetDate.CanFocus = true;
+                       this.ButtonGetDate.Name = "ButtonGetDate";
+                       this.ButtonGetDate.UseUnderline = true;
+                       this.ButtonGetDate.Label = global::Mono.Unix.Catalog.GetString ("GetRemoteDate");
+                       this.hbox2.Add (this.ButtonGetDate);
+                       global::Gtk.Box.BoxChild w2 = ((global::Gtk.Box.BoxChild)(this.hbox2 [this.ButtonGetDate]));
+                       w2.Position = 0;
+                       w2.Expand = false;
+                       w2.Fill = false;
+                       // Container child hbox2.Gtk.Box+BoxChild
+                       this.RetrieveRemoteDateButton = new global::Gtk.Button ();
+                       this.RetrieveRemoteDateButton.CanFocus = true;
+                       this.RetrieveRemoteDateButton.Name = "RetrieveRemoteDateButton";
+                       this.RetrieveRemoteDateButton.UseUnderline = true;
+                       this.RetrieveRemoteDateButton.Label = global::Mono.Unix.Catalog.GetString ("RemoteDate");
+                       this.hbox2.Add (this.RetrieveRemoteDateButton);
+                       global::Gtk.Box.BoxChild w3 = ((global::Gtk.Box.BoxChild)(this.hbox2 [this.RetrieveRemoteDateButton]));
+                       w3.Position = 2;
+                       w3.Expand = false;
+                       w3.Fill = false;
+                       this.vbox3.Add (this.hbox2);
+                       global::Gtk.Box.BoxChild w4 = ((global::Gtk.Box.BoxChild)(this.vbox3 [this.hbox2]));
+                       w4.Position = 2;
+                       w4.Expand = false;
+                       w4.Fill = false;
+                       this.Add (this.vbox3);
+                       if ((this.Child != null)) {
+                               this.Child.ShowAll ();
+                       }
+                       this.DefaultWidth = 484;
+                       this.DefaultHeight = 332;
+                       this.Show ();
+                       this.DeleteEvent += new global::Gtk.DeleteEventHandler (this.OnDeleteEvent);
+               }
+       }
+}
diff --git a/Mono/RemoteAgents/GTKLinux/GTKLinux/gtk-gui/generated.cs b/Mono/RemoteAgents/GTKLinux/GTKLinux/gtk-gui/generated.cs
new file mode 100644 (file)
index 0000000..9ef3363
--- /dev/null
@@ -0,0 +1,29 @@
+
+// This file has been generated by the GUI designer. Do not modify.
+namespace Stetic
+{
+       internal class Gui
+       {
+               private static bool initialized;
+
+               internal static void Initialize (Gtk.Widget iconRenderer)
+               {
+                       if ((Stetic.Gui.initialized == false)) {
+                               Stetic.Gui.initialized = true;
+                       }
+               }
+       }
+
+       internal class ActionGroups
+       {
+               public static Gtk.ActionGroup GetActionGroup (System.Type type)
+               {
+                       return Stetic.ActionGroups.GetActionGroup (type.FullName);
+               }
+
+               public static Gtk.ActionGroup GetActionGroup (string name)
+               {
+                       return null;
+               }
+       }
+}
diff --git a/Mono/RemoteAgents/GTKLinux/GTKLinux/gtk-gui/gui.stetic b/Mono/RemoteAgents/GTKLinux/GTKLinux/gtk-gui/gui.stetic
new file mode 100644 (file)
index 0000000..6fcea56
--- /dev/null
@@ -0,0 +1,83 @@
+<?xml version="1.0" encoding="utf-8"?>
+<stetic-interface>
+  <configuration>
+    <images-root-path>..</images-root-path>
+  </configuration>
+  <import>
+    <widget-library name="glade-sharp, Version=2.12.0.0, Culture=neutral, PublicKeyToken=35e10195dab3c99f" />
+    <widget-library name="../bin/Debug/GTKLinux.exe" internal="true" />
+  </import>
+  <widget class="Gtk.Window" id="Example.RemoteAgents.GTKLinux.MainWindow" design-size="484 332">
+    <property name="MemberName" />
+    <property name="Title" translatable="yes">MainWindow</property>
+    <property name="WindowPosition">CenterOnParent</property>
+    <signal name="DeleteEvent" handler="OnDeleteEvent" />
+    <child>
+      <widget class="Gtk.VBox" id="vbox3">
+        <property name="MemberName" />
+        <property name="Spacing">6</property>
+        <child>
+          <widget class="Gtk.TextView" id="RemoteDate">
+            <property name="MemberName" />
+            <property name="CanFocus">True</property>
+            <property name="Editable">False</property>
+            <property name="CursorVisible">False</property>
+            <property name="Text" translatable="yes" />
+          </widget>
+          <packing>
+            <property name="Position">0</property>
+            <property name="AutoSize">False</property>
+          </packing>
+        </child>
+        <child>
+          <placeholder />
+        </child>
+        <child>
+          <widget class="Gtk.HBox" id="hbox2">
+            <property name="MemberName" />
+            <property name="Spacing">6</property>
+            <child>
+              <widget class="Gtk.Button" id="ButtonGetDate">
+                <property name="MemberName" />
+                <property name="CanFocus">True</property>
+                <property name="Type">TextOnly</property>
+                <property name="Label" translatable="yes">GetRemoteDate</property>
+                <property name="UseUnderline">True</property>
+              </widget>
+              <packing>
+                <property name="Position">0</property>
+                <property name="AutoSize">True</property>
+                <property name="Expand">False</property>
+                <property name="Fill">False</property>
+              </packing>
+            </child>
+            <child>
+              <placeholder />
+            </child>
+            <child>
+              <widget class="Gtk.Button" id="RetrieveRemoteDateButton">
+                <property name="MemberName" />
+                <property name="CanFocus">True</property>
+                <property name="Type">TextOnly</property>
+                <property name="Label" translatable="yes">RemoteDate</property>
+                <property name="UseUnderline">True</property>
+              </widget>
+              <packing>
+                <property name="Position">2</property>
+                <property name="AutoSize">True</property>
+                <property name="Expand">False</property>
+                <property name="Fill">False</property>
+              </packing>
+            </child>
+          </widget>
+          <packing>
+            <property name="Position">2</property>
+            <property name="AutoSize">True</property>
+            <property name="Expand">False</property>
+            <property name="Fill">False</property>
+          </packing>
+        </child>
+      </widget>
+    </child>
+  </widget>
+</stetic-interface>
\ No newline at end of file