partial void InitInstance(SimpleMainWindow instace)
        {
            AssetHelper.RunDownLoadBundle(BundleConst.PaymentIconBundleName, (AssetBundle bundle) =>
            {
                Texture[] allTexture = bundle.LoadAllAssets <Texture>();
                int count            = instace.m_TopValues.GetChildren().Length;
                for (int i = 0; i < count; i++)
                {
                    IconTitleLoader titleLoader = instace.m_TopValues.GetChildAt(i) as IconTitleLoader;
                    if (titleLoader != null)
                    {
                        titleLoader.m_Amount.text  = PaymentData.GetAmountValue(SingleInstance <PaymentData> .GetInstance, i).ToString();
                        titleLoader.m_Icon.texture = new FairyGUI.NTexture(allTexture[i]);
                    }
                }
            }
                                          );

            AssetHelper.RunDownLoadBundle(BundleConst.RoleBundleName, (AssetBundle bundle) =>
            {
                Texture[] allTexture = bundle.LoadAllAssets <Texture>();
                instace.m_RoleIcon.m_Icon.texture = new FairyGUI.NTexture(allTexture[SingleInstance <CurrentPlayIndex> .GetInstance.index]);
                Resources.UnloadUnusedAssets();
            }
                                          );
        }
Exemplo n.º 2
0
 public GComponent Inject()
 {
     if (instace != null)
     {
         return(instace);
     }
     instace            = IconTitleLoader.CreateInstance();
     instace.Disposable = false;
     new IconTitleLoaderMedia().Init(instace);
     return(instace);
 }
Exemplo n.º 3
0
 public void Init(IconTitleLoader instace)
 {
     InitInstance(instace);
 }
Exemplo n.º 4
0
 partial void InitInstance(IconTitleLoader instace);