Free cookie consent management tool by TermsFeed Policy Generator

source: branches/HeuristicLab.Problems.GrammaticalOptimization/SharpVectorDom/Element.cs @ 13374

Last change on this file since 13374 was 12762, checked in by aballeit, 9 years ago

#2283 GUI updates, Tree-chart, MCTS Version 2 (prune leaves)

File size: 2.1 KB
Line 
1using System;
2using System.Xml;
3
4using SharpVectors.Dom.Events;
5
6namespace SharpVectors.Dom
7{
8  /// <summary>
9  /// Summary description for Element.
10  /// </summary>
11  public class Element : XmlElement, INode, IEventTargetSupport
12  {
13    #region Private Fields
14   
15    private EventTarget eventTarget;
16   
17    #endregion
18   
19    #region Constructors
20   
21    public Element(string prefix, string localName, string namespaceUri,
22      Document document) : base(prefix, localName, namespaceUri, document)
23    {
24      eventTarget = new EventTarget(this);
25    }
26   
27    #endregion
28   
29    #region IEventTarget interface
30   
31    #region Methods
32   
33    #region DOM Level 2
34   
35    void IEventTarget.AddEventListener(string type, EventListener listener,
36      bool useCapture)
37    {
38      eventTarget.AddEventListener(type, listener, useCapture);
39    }
40   
41    void IEventTarget.RemoveEventListener(string type, EventListener listener,
42      bool useCapture)
43    {
44      eventTarget.RemoveEventListener(type, listener, useCapture);
45    }
46
47        bool IEventTarget.DispatchEvent(IEvent evt)
48    {
49            return eventTarget.DispatchEvent(evt);
50    }
51   
52    #endregion
53   
54    #region DOM Level 3 Experimental
55   
56    void IEventTarget.AddEventListenerNs(
57      string namespaceUri,
58      string type,
59      EventListener listener,
60      bool useCapture,
61      object eventGroup)
62    {
63      eventTarget.AddEventListenerNs(namespaceUri, type, listener, useCapture, eventGroup);
64    }
65   
66    void IEventTarget.RemoveEventListenerNs(
67      string namespaceUri,
68      string type,
69      EventListener listener,
70      bool useCapture)
71    {
72      eventTarget.RemoveEventListenerNs(namespaceUri, type, listener, useCapture);
73    }
74   
75    bool IEventTarget.WillTriggerNs(
76      string namespaceUri,
77      string type)
78    {
79      return eventTarget.WillTriggerNs(namespaceUri, type);
80    }
81   
82    bool IEventTarget.HasEventListenerNs(
83      string namespaceUri,
84      string type)
85    {
86      return eventTarget.HasEventListenerNs(namespaceUri, type);
87    }
88   
89    #endregion
90   
91    #endregion
92   
93    #endregion
94   
95    #region NON-DOM
96   
97    void IEventTargetSupport.FireEvent(IEvent evt)
98    {
99            eventTarget.FireEvent(evt);
100    }
101   
102    #endregion
103  }
104}
Note: See TracBrowser for help on using the repository browser.