private static void OnExportDragWidgetInfo(
			 DDContainer _sender ,
			ref IntPtr _item ,
			ref IntCoord _dimension )
		{
            Widget __item = null;
            
			if (_sender.mEventDragWidgetInfo != null)
				_sender.mEventDragWidgetInfo(
					 _sender ,
					ref __item ,
					ref _dimension );
					
            _item = (__item == null) ? IntPtr.Zero : __item.GetNative();
		}
Ejemplo n.º 2
0
 public void UpWidget(Widget _widget)
 {
     ExportLayerManager_UpWidget(_widget.GetNative());
 }
Ejemplo n.º 3
0
 public void AttachToLayer(string _layer, Widget _widget)
 {
     ExportLayerManager_AttachToLayer(_layer, _widget.GetNative());
 }
Ejemplo n.º 4
0
 public void UpWidget(Widget _widget)
 {
     ExportLayerManager_UpWidget(_widget.GetNative());
 }
Ejemplo n.º 5
0
 public void AttachToLayer(string _layer, Widget _widget)
 {
     ExportLayerManager_AttachToLayer(_layer, _widget.GetNative());
 }
Ejemplo n.º 6
0
Archivo: Gui.cs Proyecto: southdy/iwe
 void SetProperty(Widget _widget, string _key, string _value)
 {
     ExportGui_SetProperty(_widget.GetNative(), _key, _value);
 }
Ejemplo n.º 7
0
 public void RemoveWidgetModal(Widget _widget)
 {
     ExportInputManager_RemoveWidgetModal(_widget.GetNative());
 }
Ejemplo n.º 8
0
 public void AddWidgetModal(Widget _widget)
 {
     ExportInputManager_AddWidgetModal(_widget.GetNative());
 }
Ejemplo n.º 9
0
 public static void SetWidgetDepth(Widget _widget, float _depth)
 {
     ExportLayers_SetWidgetDepth(_widget.GetNative(), _depth);
 }
Ejemplo n.º 10
0
 public void AddWidgetModal(Widget _widget)
 {
     ExportGui_AddWidgetModal(_widget.GetNative());
 }
Ejemplo n.º 11
0
 public void UpWidget(Widget _widget)
 {
     ExportGui_UpWidget(_widget.GetNative());
 }
Ejemplo n.º 12
0
        private void ParseWidget(List <Widget> _widgets, XmlNode _node, Widget _parent, Widget _root, string _prefix)
        {
            string style = "", type = "", skin = "", name = "", layer = "", align = "", position = "";

            foreach (XmlAttribute attribute in _node.Attributes)
            {
                switch (attribute.Name)
                {
                case "style": style = attribute.Value; break;

                case "type": type = attribute.Value; break;

                case "skin": skin = attribute.Value; break;

                case "name": name = attribute.Value; break;

                case "layer": layer = attribute.Value; break;

                case "align": align = attribute.Value; break;

                case "position": position = attribute.Value; break;
                }

                if (type == "Sheet")
                {
                    type = "TabItem";
                }
            }

            if ((0 == type.Length) || (0 == skin.Length))
            {
                return;
            }

            if ((0 != name.Length) && (0 != _prefix.Length))
            {
                name = _prefix + name;
            }

            string[] coord = position.Split();

            WidgetStyle wstyle = WidgetStyle.Overlapped;

            if (_parent != null)
            {
                layer  = "";
                wstyle = (style != string.Empty) ? (WidgetStyle)Enum.Parse(typeof(WidgetStyle), style) : WidgetStyle.Child;
            }

            Align walign = Align.Default;

            if (align != string.Empty)
            {
                walign = Align.Center;
                string[] mass = align.Split();
                foreach (string item in mass)
                {
                    walign |= (Align)Enum.Parse(typeof(Align), item);
                }
            }

            Widget widget = (Widget)mMapCreator[type](
                _parent == null ? IntPtr.Zero : _parent.GetNative(),
                wstyle,
                skin,
                ((coord.Length == 4) ? new IntCoord(int.Parse(coord[0]), int.Parse(coord[1]), int.Parse(coord[2]), int.Parse(coord[3])) : new IntCoord()),
                walign,
                layer,
                name);

            if (null == _root)
            {
                _root = widget;
                _widgets.Add(_root);
            }

            foreach (XmlNode node in _node)
            {
                if ("Widget" == node.Name)
                {
                    ParseWidget(_widgets, node, widget, _root, _prefix);
                }
                else if ("Property" == node.Name)
                {
                    string key = "", value = "";
                    foreach (XmlAttribute attribute in node.Attributes)
                    {
                        if ("key" == attribute.Name)
                        {
                            key = attribute.Value;
                        }
                        else if ("value" == attribute.Name)
                        {
                            value = attribute.Value;
                        }
                    }
                    if ((0 == key.Length) || (0 == value.Length))
                    {
                        continue;
                    }

                    SetProperty(widget, key, value);
                }
                else if ("UserString" == node.Name)
                {
                    string key = "", value = "";
                    foreach (XmlAttribute attribute in node.Attributes)
                    {
                        if ("key" == attribute.Name)
                        {
                            key = attribute.Value;
                        }
                        else if ("value" == attribute.Name)
                        {
                            value = attribute.Value;
                        }
                    }
                    if ((0 == key.Length) || (0 == value.Length))
                    {
                        continue;
                    }
                    widget.SetUserString(key, value);

                    if (EventParserUserData != null)
                    {
                        EventParserUserData(widget, key, value);
                    }
                }
            }
        }
Ejemplo n.º 13
0
 public void RemoveWidgetModal(Widget _widget)
 {
     ExportGui_RemoveWidgetModal(_widget.GetNative());
 }
Ejemplo n.º 14
0
 public void AddWidgetModal(Widget _widget)
 {
     ExportInputManager_AddWidgetModal(_widget.GetNative());
 }
Ejemplo n.º 15
0
 public void RemoveWidgetModal(Widget _widget)
 {
     ExportInputManager_RemoveWidgetModal(_widget.GetNative());
 }