Ejemplo n.º 1
0
    private IEnumerator LoadImage(NetImageRequestObj netImageRequestObj)
    {
        yield return(this.HttpGet(netImageRequestObj, OnLoadNetImageSucceed));

        isProcess = false;
        NetImageMgr.getInstance().ProcessNextOne();
    }
 public static NetImageMgr getInstance()
 {
     if (_instance == null)
     {
         _instance = new NetImageMgr();
     }
     return(_instance);
 }
Ejemplo n.º 3
0
    private void OnLoadNetImageSucceed(WWW www, NetImageRequestObj netImageRequestObj)
    {
        Texture2D tex = www.texture;

        netImageRequestObj.netImageData.texture2D = tex;
        NetImageMgr.getInstance().AddNetImageData(netImageRequestObj.netImageData);

        if (netImageRequestObj.netImageProcessType != ProcessType.Abort)
        {
            netImageRequestObj.netImageProcessType = ProcessType.Processed;
            NetImageMgr.getInstance().ProcessSetImage(netImageRequestObj);
        }
    }
Ejemplo n.º 4
0
    public override void RefreshCellView()
    {
        if (active == false)
        {
            return;
        }

        if (requestObj != null)
        {
            requestObj.Abort();
        }

        requestObj = null;
        string path = mData.toOtherType <ImgCellData>().imgPath;

        titleImage.texture = defaultTexture;

        requestObj = NetImageMgr.getInstance().StartGetOne(path, titleImage, 1);
    }