Ejemplo n.º 1
0
    public void AssignActiveBubble(BubbleButton bubble)
    {
        /* if (this.bubble != null)
         *      this.bubble.FadeOut(); */

        this.bubble = bubble;
    }
 void Bubble_Dismissed(object sender, EventArgs e)
 {
     if (Dismissed != null)
     {
         Dismissed(this, new BubbleButtonEventArgs(SelectedButton));
         SelectedButton = BubbleButton.None;
     }
 }
Ejemplo n.º 3
0
            void MyGridBubbleBarEditControlButtonClick(
                object sender, ClickEventArgs e)
            {
                BubbleButton bb = (BubbleButton)sender;

                // Set the cell image to match the selected bubble image

                EditorCell.CellStyles.Default.Image = ImagesLarge.Images[bb.ImageIndex];
            }
Ejemplo n.º 4
0
    void Start()
    {
        spriteRenderer = GetComponent <SpriteRenderer>();
        boxCollider    = GetComponent <BoxCollider>();
        viewManager    = FindObjectOfType <ViewManager>();
        worldMap       = FindObjectOfType <WorldMap>();
        camera         = FindObjectOfType <Camera>();

        buttonData = FindObjectOfType <BubbleButton>();

        houseCounter = FindObjectOfType <HouseCounter>();

        //button.onClick.AddListener(ButtonClicked);

        Reposition();

        CheckOutline();
    }
Ejemplo n.º 5
0
            /// <summary>
            /// Creates the default BubbleTab for the control
            /// </summary>
            /// <param name="imageListSmall"></param>
            /// <param name="imageListLarge"></param>
            private void SetupBubbleTab(
                ImageList imageListSmall, ImageList imageListLarge)
            {
                Images      = imageListSmall;
                ImagesLarge = imageListLarge;

                ImageSizeNormal = new Size(32, 32);
                ImageSizeLarge  = new Size(64, 64);

                BubbleBarTab tab = new BubbleBarTab();

                Tabs.Add(tab);

                for (int i = 0; i < imageListSmall.Images.Count; i++)
                {
                    BubbleButton bb = new BubbleButton();
                    tab.Buttons.Add(bb);

                    bb.ImageIndex      = i;
                    bb.ImageIndexLarge = i;
                }
            }
Ejemplo n.º 6
0
 public void AssignActiveBubble(BubbleButton bubble)
 {
     fishController.AssignActiveBubble(bubble);
 }
Ejemplo n.º 7
0
		private void OnComponentRemoving(object sender,ComponentEventArgs e)
		{
			if(e.Component==this.Component)
				ThisComponentRemoving(sender,e);
			else if(e.Component is BubbleBarTab)
			{
				BubbleBarTab tab=e.Component as BubbleBarTab;
				if(tab.Parent==this.Control)
				{
					IDesignerHost dh=(IDesignerHost)GetService(typeof(IDesignerHost));
                    BubbleButton[] buttons = new BubbleButton[tab.Buttons.Count];
                    tab.Buttons.CopyTo(buttons, 0);
					foreach(BubbleButton button in buttons)
						dh.DestroyComponent(button);
					BubbleBar bar=this.Component as BubbleBar;
					bar.Tabs.Remove(tab);
					bar.RecalcLayout();
					bar.Refresh();
				}
			}
			else if(e.Component is BubbleButton)
			{
				BubbleButton button=e.Component as BubbleButton;
				if(button.GetBubbleBar()==this.Control)
				{
					button.Parent.Buttons.Remove(button);
					BubbleBar bar=this.Component as BubbleBar;
					bar.RecalcLayout();
					bar.Refresh();
				}
			}
		}
 private void Dismiss(BubbleButton button)
 {
     SelectedButton = button;
     Bubble.Dismiss();
 }
 public BubbleButtonEventArgs(BubbleButton button)
 {
     Button = button;
 }