コード例 #1
0
 /// <summary>
 /// Initializes a new instance of the <see cref="UserInterfaceElement"/> class.
 /// </summary>
 /// <param name="mouse">The mouse service.</param>
 /// <param name="parent">The parent.</param>
 protected UserInterfaceElement(IMouse mouse, UserInterfaceElement parent = null)
 {
     Parent            = parent;
     isVisible         = true;
     mouse.Move       += OnMouseMove;
     mouse.ButtonLift += OnMouseButtonLift;
 }
コード例 #2
0
ファイル: MonoGameImage.cs プロジェクト: brianjlacy/Hero6
 public MonoGameImage(
     string source,
     IMouse mouse,
     ILogger logger,
     ContentManager content,
     SpriteBatch spriteBatch,
     UserInterfaceElement parent = null)
     : base(source, mouse, parent)
 {
     this.logger      = logger;
     this.content     = content;
     this.spriteBatch = spriteBatch;
 }
コード例 #3
0
 public static IXnaGameLoop AsXnaGameLoop(this UserInterfaceElement userInterfaceElement)
 {
     return(userInterfaceElement as IXnaGameLoop);
 }
コード例 #4
0
ファイル: MonoGameLabel.cs プロジェクト: brianjlacy/Hero6
 public MonoGameLabel(ContentManager content, SpriteBatch spriteBatch, IMouse mouse, UserInterfaceElement parent = null)
     : base(mouse, parent)
 {
     this.content     = content;
     this.spriteBatch = spriteBatch;
 }
コード例 #5
0
 public MonoGameButton(IMouse mouse, UserInterfaceElement parent = null)
     : base(mouse, parent)
 {
 }
コード例 #6
0
 public MonoGameStackPanel(IMouse mouse, UserInterfaceElement parent = null)
     : base(mouse, parent)
 {
 }
コード例 #7
0
 /// <summary>
 /// Initializes a new instance of the <see cref="Button"/> class.
 /// </summary>
 /// <param name="assets">The asset manager of this user interface.</param>
 /// <param name="child">The user interface inside this button.</param>
 public Button(AssetManager assets, UserInterfaceElement child)
     : base(assets)
 {
     this.Child = child;
 }
コード例 #8
0
ファイル: Label.cs プロジェクト: brianjlacy/Hero6
 /// <summary>
 /// Initializes a new instance of the <see cref="Label"/> class.
 /// </summary>
 /// <param name="mouse">The mouse servicve.</param>
 /// <param name="parent">The parent.</param>
 protected Label(IMouse mouse, UserInterfaceElement parent = null)
     : base(mouse, parent)
 {
 }
コード例 #9
0
ファイル: Image.cs プロジェクト: brianjlacy/Hero6
 /// <summary>
 /// Initializes a new instance of the <see cref="Image"/> class.
 /// </summary>
 /// <param name="source">The source for the image.</param>
 /// <param name="mouse">The mouse service.</param>
 /// <param name="parent">The parent.</param>
 protected Image(string source, IMouse mouse, UserInterfaceElement parent)
     : base(mouse, parent)
 {
     Source = source;
 }
コード例 #10
0
ファイル: Button.cs プロジェクト: brianjlacy/Hero6
 /// <summary>
 /// Initializes a new instance of the <see cref="Button"/> class.
 /// </summary>
 /// <param name="mouse">The mouse service.</param>
 /// <param name="parent">The parent.</param>
 protected Button(IMouse mouse, UserInterfaceElement parent)
     : base(mouse, parent)
 {
 }