• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

C# Framework.UIElement类代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了C#中FSO.Client.UI.Framework.UIElement的典型用法代码示例。如果您正苦于以下问题:C# UIElement类的具体用法?C# UIElement怎么用?C# UIElement使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。



UIElement类属于FSO.Client.UI.Framework命名空间,在下文中一共展示了UIElement类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C#代码示例。

示例1: button_OnButtonClick

 void button_OnButtonClick(UIElement button)
 {
     if (data != null)
     {
         owner.SelectedItem = data;
     }
 }
开发者ID:RHY3756547,项目名称:FreeSO,代码行数:7,代码来源:UIGridViewerRender.cs


示例2: Draw

 public void Draw(UIElement ui, SpriteBatch batch)
 {
     if (((ITextControl)ui).DrawCursor)
     {
         batch.Draw(Texture, Position, null, Color, 0, Vector2.Zero, Scale, SpriteEffects.None, 0);
     }
 }
开发者ID:RHY3756547,项目名称:FreeSO,代码行数:7,代码来源:UITextBox.cs


示例3: UIDragHandler

        public UIDragHandler(UIElement mouseTarget, UIElement dragControl)
        {
            UpdateHook = new UpdateHookDelegate(Update);

            MouseTarget = mouseTarget;
            DragControl = dragControl;
            MouseEvent = mouseTarget.ListenForMouse(mouseTarget.GetBounds(), new UIMouseEvent(DragMouseEvents));
        }
开发者ID:Daribon,项目名称:FreeSO,代码行数:8,代码来源:UIUtils.cs


示例4: AddAt

        /// <summary>
        /// Adds a UIElement at a specific depth in the container
        /// </summary>
        /// <param name="index"></param>
        /// <param name="child"></param>
        public void AddAt(int index, UIElement child)
        {
            lock (Children)
            {
                if (Children.Contains(child))
                {
                    Children.Remove(child);
                }

                Children.Insert(index, child);
                child.Parent = this;
            }
        }
开发者ID:RHY3756547,项目名称:FreeSO,代码行数:18,代码来源:UIContainer.cs


示例5: ShowDialog

        /// <summary>
        /// Adds a popup dialog
        /// </summary>
        /// <param name="dialog"></param>
        public static void ShowDialog(UIElement dialog, bool modal)
        {
            GameFacade.Screens.AddDialog(new DialogReference
            {
                Dialog = dialog,
                Modal = modal
            });

            if (dialog is UIDialog)
            {
                ((UIDialog)dialog).CenterAround(UIScreen.Current);
            }
        }
开发者ID:Daribon,项目名称:FreeSO,代码行数:17,代码来源:UIScreen.cs


示例6: Add

        /// <summary>
        /// Adds a UIElement at the top most position in the container
        /// </summary>
        /// <param name="child"></param>
        public void Add(UIElement child)
        {
            if (child == null) { return; }

            lock (Children)
            {
                if (Children.Contains(child))
                {
                    Children.Remove(child);
                }
                Children.Add(child);
                child.Parent = this;
            }
        }
开发者ID:RHY3756547,项目名称:FreeSO,代码行数:18,代码来源:UIContainer.cs


示例7: SetSelected

        private void SetSelected(UIElement element)
        {
            if (element == null)
            {
                propertyBox.Enabled = false;
                return;
            }

            propertyBox.Enabled = true;
            Selected = element;

            valueX.Value = (decimal)element.X;
            valueY.Value = (decimal)element.Y;
            valueScaleX.Value = (decimal)element.ScaleX;
            valueScaleY.Value = (decimal)element.ScaleY;
            valueAlpha.Value = (decimal)element.Opacity;
        }
开发者ID:RHY3756547,项目名称:FreeSO,代码行数:17,代码来源:TSOClientUIInspector.cs


示例8: BuyPropertyAlert_OnButtonClick

 /// <summary>
 /// Player selected "yes" to buy a new lot.
 /// </summary>
 private void BuyPropertyAlert_OnButtonClick(UIElement Button)
 {
     Network.UIPacketSenders.SendLotPurchaseRequest(Network.NetworkFacade.Client, (short)m_SelTileTmp[0], (short)m_SelTileTmp[1]);
     UIScreen.RemoveDialog(m_BuyPropertyAlert);
 }
开发者ID:RHY3756547,项目名称:FreeSO,代码行数:8,代码来源:Terrain.cs


示例9: PieButtonClick

        private void PieButtonClick(UIElement button)
        {
            int index = m_PieButtons.IndexOf((UIButton)button);
            if (index == -1) return; //bail! this isn't meant to happen!
            var action = m_CurrentItem.Children.ElementAt(index).Value;
            HITVM.Get().PlaySoundEvent(UISounds.PieMenuSelect);

            if (action.Category) {
                m_CurrentItem = action;
                RenderMenu();
            } else {

                if (m_Obj == m_Parent.GotoObject)
                {
                    m_Parent.vm.SendCommand(new VMNetGotoCmd
                    {
                        Interaction = action.ID,
                        ActorUID = m_Caller.PersistID,
                        x = m_Obj.Position.x,
                        y = m_Obj.Position.y,
                        level = m_Obj.Position.Level
                    });
                }
                else
                {
                    if (Debug.IDEHook.IDE != null && ShiftDown) {
                        if (m_Obj.TreeTable.InteractionByIndex.ContainsKey((uint)action.ID)) {
                            var act = m_Obj.TreeTable.InteractionByIndex[(uint)action.ID];
                            ushort ActionID = act.ActionFunction;

                            var function = m_Obj.GetBHAVWithOwner(ActionID, m_Parent.vm.Context);

                            Debug.IDEHook.IDE.IDEOpenBHAV(
                                function.bhav,
                                m_Obj.Object
                            );
                        }
                    }
                    else
                    {
                        m_Parent.vm.SendCommand(new VMNetInteractionCmd
                        {
                            Interaction = action.ID,
                            ActorUID = m_Caller.PersistID,
                            CalleeID = m_Obj.ObjectID,
                            Param0 = action.Param0
                        });
                    }
                }
                HITVM.Get().PlaySoundEvent(UISounds.QueueAdd);
                m_Parent.ClosePie();

            }
        }
开发者ID:RHY3756547,项目名称:FreeSO,代码行数:54,代码来源:UIPieMenu.cs


示例10: Show

 public void Show(UIElement button)
 {
     Shown = true;
     icon.Visible = false;
     window.Visible = true;
     Alert = false;
     parent.ReorderIcons();
 }
开发者ID:RHY3756547,项目名称:FreeSO,代码行数:8,代码来源:UIMessage.cs


示例11: SendMessageEnter

 private void SendMessageEnter(UIElement element)
 {
     //remove newline first
     if (MessageType != UIMessageType.IM) return; //cannot send on enter for letters (or during read mode :|)
     MessageTextEdit.CurrentText = MessageTextEdit.CurrentText.Substring(0, MessageTextEdit.CurrentText.Length - 2);
     SendMessage(this);
 }
开发者ID:RHY3756547,项目名称:FreeSO,代码行数:7,代码来源:UIMessage.cs


示例12: SendLetter

        private void SendLetter(UIElement button)
        {
            if (MessageType != UIMessageType.Compose) return;
            UIMessageController controller = (UIMessageController)GameFacade.MessageController;

            controller.SendLetter(LetterTextEdit.CurrentText, LetterSubjectTextEdit.CurrentText, Author.GUID);
        }
开发者ID:RHY3756547,项目名称:FreeSO,代码行数:7,代码来源:UIMessage.cs


示例13: MessageTextEdit_OnChange

 private void MessageTextEdit_OnChange(UIElement TextEdit)
 {
     UITextEdit edit = (UITextEdit)TextEdit;
     SendMessageButton.Disabled = (edit.CurrentText.Length == 0);
 }
开发者ID:RHY3756547,项目名称:FreeSO,代码行数:5,代码来源:UIMessage.cs


示例14: CloseButton_OnButtonClick

 private void CloseButton_OnButtonClick(UIElement button)
 {
     //hide self.
     Visible = false;
 }
开发者ID:RHY3756547,项目名称:FreeSO,代码行数:5,代码来源:UIChatDialog.cs


示例15: ChatEntryTextEdit_OnChange

 private void ChatEntryTextEdit_OnChange(UIElement TextEdit)
 {
     UITextEdit edit = (UITextEdit)TextEdit;
     OKButton.Disabled = (edit.CurrentText.Length == 0);
 }
开发者ID:RHY3756547,项目名称:FreeSO,代码行数:5,代码来源:UIChatDialog.cs


示例16: ErrorReturnAlert

 private void ErrorReturnAlert(UIElement button)
 {
     GameFacade.Controller.ShowPersonSelection();
 }
开发者ID:RHY3756547,项目名称:FreeSO,代码行数:4,代码来源:CityTransitionScreen.cs


示例17: CloseButton_OnButtonClick

 /// <summary>
 /// User closed the UIMessage window.
 /// </summary>
 private void CloseButton_OnButtonClick(UIElement button)
 {
     Parent.Remove(this);
 }
开发者ID:RHY3756547,项目名称:FreeSO,代码行数:7,代码来源:UIMessage.cs


示例18: SendMessage

        private void SendMessage(UIElement button)
        {
            OKButton.Disabled = true;
            if (ChatEntryTextEdit.CurrentText.Length == 0) return;

            if (OnSendMessage != null) OnSendMessage(ChatEntryTextEdit.CurrentText);
            ChatEntryTextEdit.CurrentText = "";
        }
开发者ID:RHY3756547,项目名称:FreeSO,代码行数:8,代码来源:UIChatDialog.cs


示例19: RespondLetterButton_OnButtonClick

 private void RespondLetterButton_OnButtonClick(UIElement button)
 {
     if (MessageType != UIMessageType.Read) return;
     SetType(UIMessageType.Compose);
 }
开发者ID:RHY3756547,项目名称:FreeSO,代码行数:5,代码来源:UIMessage.cs


示例20: SendMessageEnter

 private void SendMessageEnter(UIElement element)
 {
     //remove newline first
     ChatEntryTextEdit.CurrentText = ChatEntryTextEdit.CurrentText.Substring(0, ChatEntryTextEdit.CurrentText.Length - 2);
     SendMessage(this);
 }
开发者ID:RHY3756547,项目名称:FreeSO,代码行数:6,代码来源:UIChatDialog.cs



注:本文中的FSO.Client.UI.Framework.UIElement类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
C# FSpot.Tag类代码示例发布时间:2022-05-24
下一篇:
C# FPCEstimate.FormulaEvaluator类代码示例发布时间:2022-05-24
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap