Actually show the About Platform dialog

This commit is contained in:
Michael Becker 2014-08-09 21:42:54 -04:00
parent c541d57244
commit aaf24d7164
7 changed files with 30 additions and 8 deletions

View File

@ -20,7 +20,7 @@
// along with this program. If not, see <http://www.gnu.org/licenses/>.
using System;
using UniversalEditor.UserInterface;
namespace UniversalEditor.Engines.GTK
namespace UniversalEditor.Engines.GTK.Dialogs
{
public partial class AboutDialog : Gtk.Dialog
{

View File

@ -27,6 +27,13 @@ namespace UniversalEditor.Engines.GTK
mw.Show ();
return mw;
}
public override void ShowAboutDialog()
{
Dialogs.AboutDialog dlg = new Dialogs.AboutDialog();
dlg.Run();
dlg.Destroy();
}
}
}

View File

@ -429,6 +429,13 @@ namespace UniversalEditor.Engines.GTK
{
throw new System.NotImplementedException ();
}
public void ShowAboutDialog()
{
Dialogs.AboutDialog dlg = new Dialogs.AboutDialog();
dlg.Run();
dlg.Destroy();
}
#endregion
}
}

View File

@ -69,7 +69,7 @@
<Compile Include="Controls\ObjectModelBrowser.cs" />
<Compile Include="gtk-gui\UniversalEditor.Engines.GTK.ObjectModelBrowser.cs" />
<Compile Include="Dialogs\AboutDialog.cs" />
<Compile Include="gtk-gui\UniversalEditor.Engines.GTK.AboutDialog.cs" />
<Compile Include="gtk-gui\UniversalEditor.Engines.GTK.Dialogs.AboutDialog.cs" />
</ItemGroup>
<Import Project="$(MSBuildBinPath)\Microsoft.CSharp.targets" />
<ItemGroup>

View File

@ -1,6 +1,6 @@
// This file has been generated by the GUI designer. Do not modify.
namespace UniversalEditor.Engines.GTK
namespace UniversalEditor.Engines.GTK.Dialogs
{
public partial class AboutDialog
{
@ -37,12 +37,12 @@ namespace UniversalEditor.Engines.GTK
protected virtual void Build ()
{
global::Stetic.Gui.Initialize (this);
// Widget UniversalEditor.Engines.GTK.AboutDialog
this.Name = "UniversalEditor.Engines.GTK.AboutDialog";
// Widget UniversalEditor.Engines.GTK.Dialogs.AboutDialog
this.Name = "UniversalEditor.Engines.GTK.Dialogs.AboutDialog";
this.Title = global::Mono.Unix.Catalog.GetString ("About [ApplicationTitle]");
this.WindowPosition = ((global::Gtk.WindowPosition)(4));
this.Resizable = false;
// Internal child UniversalEditor.Engines.GTK.AboutDialog.VBox
// Internal child UniversalEditor.Engines.GTK.Dialogs.AboutDialog.VBox
global::Gtk.VBox w1 = this.VBox;
w1.Name = "dialog1_VBox";
w1.BorderWidth = ((uint)(2));
@ -234,7 +234,7 @@ namespace UniversalEditor.Engines.GTK
w1.Add (this.vbox3);
global::Gtk.Box.BoxChild w23 = ((global::Gtk.Box.BoxChild)(w1 [this.vbox3]));
w23.Position = 0;
// Internal child UniversalEditor.Engines.GTK.AboutDialog.ActionArea
// Internal child UniversalEditor.Engines.GTK.Dialogs.AboutDialog.ActionArea
global::Gtk.HButtonBox w24 = this.ActionArea;
w24.Name = "dialog1_ActionArea";
w24.Spacing = 10;

View File

@ -264,7 +264,7 @@
</widget>
</child>
</widget>
<widget class="Gtk.Dialog" id="UniversalEditor.Engines.GTK.AboutDialog" design-size="572 444">
<widget class="Gtk.Dialog" id="UniversalEditor.Engines.GTK.Dialogs.AboutDialog" design-size="572 444">
<property name="MemberName" />
<property name="Title" translatable="yes">About [ApplicationTitle]</property>
<property name="WindowPosition">CenterOnParent</property>

View File

@ -240,6 +240,12 @@ namespace UniversalEditor.UserInterface
});
#endregion
#region Help
AttachCommandEventHandler("HelpAboutPlatform", delegate(object sender, EventArgs e)
{
ShowAboutDialog();
});
#endregion
#region Help
Command helpAboutPlatform = mvarCommands["HelpAboutPlatform"];
if (helpAboutPlatform != null)
{
@ -380,6 +386,8 @@ namespace UniversalEditor.UserInterface
/// <param name="FileNames">The file name(s) of the document(s) to load.</param>
/// <returns>An <see cref="IHostApplicationWindow"/> representing the window that was created.</returns>
protected abstract IHostApplicationWindow OpenWindowInternal(params string[] FileNames);
public abstract void ShowAboutDialog();
/// <summary>
/// Opens a new window, optionally loading the specified documents.