예제 #1
0
        private void OnQueryRemoveButtonLogic(GameObject POIButton)
        {
            int buttonID  = POIButton.GetComponent <ButtonAttribute>().getID();
            var eventArgs = new RemoveQueryDataArgs(buttonID);

            OnPOIRemove(this, eventArgs);
            Debug.Log("Destroying POIButton " + buttonID);

            scrollingObjectCollection.RemoveItem(POIButton);
            Destroy(POIButton);
            scrollingObjectCollection.UpdateCollection();



            // foreach (Transform VARIABLE in transform.GetChild(4).GetChild(1).GetChild(0))
            // {
            //     if (id == VARIABLE.gameObject.GetComponent<ButtonAttribute>().getID())
            //     {
            //         if (VARIABLE.gameObject != null)
            //         {
            //             Destroy(VARIABLE.gameObject);
            //             Invoke("updatePOIButtonCollection",0.5f);
            //         }
            //         return;
            //     }
            // }
        }
예제 #2
0
    private void OnQueryRemoveButtonLogic(GameObject POIButton, POICoordinatesObject poiCoordinatesObject)
    {
        int ID = POIButton.GetComponent <ButtonAttribute>().getID();

        queryList.Remove(ID);
        int buttonID = POIButton.GetComponent <ButtonAttribute>().getID();

        Debug.Log("Destroying POIButton " + buttonID);

        scrollingObjectCollection.RemoveItem(POIButton);
        Destroy(POIButton);
        scrollingObjectCollection.UpdateCollection();

        var eventArgs = new QueryRemoveEventArgs();

        eventArgs.RemoveObject = poiCoordinatesObject.getMapPin();
        eventArgs.poi          = poiCoordinatesObject;
        OnRemove(this, eventArgs);



        // foreach (Transform VARIABLE in transform.GetChild(4).GetChild(1).GetChild(0))
        // {
        //     if (id == VARIABLE.gameObject.GetComponent<ButtonAttribute>().getID())
        //     {
        //         if (VARIABLE.gameObject != null)
        //         {
        //             Destroy(VARIABLE.gameObject);
        //             Invoke("updatePOIButtonCollection",0.5f);
        //         }
        //         return;
        //     }
        // }
    }
예제 #3
0
    public void  reset()
    {
        if (picturePointerDatasList != null)
        {
            foreach (var VARIABLE in picturePointerDatasList)
            {
                scrollingObjectCollection.RemoveItem(VARIABLE.getGameObject());
            }
        }

        this.picturePointerDatasList.Clear();
        this.textureDatas.Clear();
        this.PoiCoordinatesObjects.Clear();
        this.key = 0;
        ResetObject eventArgs = new ResetObject();

        OnResetObject(this, eventArgs);


        //Debug.Log("Deleted all Results "+transform.parent.parent.GetChild(8));
    }