//****************************************************************************************************
    //
    //****************************************************************************************************

    public void Update()
    {
        if (m_map == null)
        {
            return;
        }

        if (m_request == null)
        {
            while ((m_request = DeQueue()) != null)
            {
                if (m_request.canceled)
                {
                    m_request = null;

                    UpdateIndicator(false);

                    continue;
                }

                UpdateIndicator(true);

                m_request.processing = true;

                StartCoroutine(RequestMap());

                break;
            }
        }
    }
    //****************************************************************************************************
    //
    //****************************************************************************************************

    private WebMapRequest DeQueue()
    {
        if (m_queue.Count > 0)
        {
            WebMapRequest req = m_queue.First.Value;

            m_queue.RemoveFirst();

            return(req);
        }

        return(null);
    }
    //****************************************************************************************************
    //
    //****************************************************************************************************

    private void DropCurRequest(WebMapRequest.DROP_REASON reason)
    {
        if (m_request != null)
        {
            switch (reason)
            {
            case WebMapRequest.DROP_REASON.NEW:                             break;

            case WebMapRequest.DROP_REASON.CANCELED: m_request.canceled = true; break;

            case WebMapRequest.DROP_REASON.COMPLETED: m_request.completed = true; break;

            case WebMapRequest.DROP_REASON.CONTEXT_CHANGED:                             break;
            }
        }

        m_request = null;

        UpdateIndicator(false);
    }
    //****************************************************************************************************
    //
    //****************************************************************************************************

    public bool Queue(WebMapRequest req)
    {
        if (req == null)
        {
            return(false);
        }

        if (req.@new == false)
        {
            return(false);
        }

        if (req.node.List != null)
        {
            return(false);
        }

        m_queue.AddLast(req.node);

        m_workLoad = m_queue.Count;

        return(true);
    }