diff options
author | tobigun <tobigun@b956fd51-792f-4845-bead-9b4dfca2ff2c> | 2008-08-13 11:55:08 +0000 |
---|---|---|
committer | tobigun <tobigun@b956fd51-792f-4845-bead-9b4dfca2ff2c> | 2008-08-13 11:55:08 +0000 |
commit | 4630fb65aef5f3f1789e94e60e52756f4d7a2a3f (patch) | |
tree | 63234fa31e93003dc7281ccfb93d1d18998fbd1d | |
parent | bc7268806e0cb477725cad39df2412bc1a2837f1 (diff) | |
download | usdx-4630fb65aef5f3f1789e94e60e52756f4d7a2a3f.tar.gz usdx-4630fb65aef5f3f1789e94e60e52756f4d7a2a3f.tar.xz usdx-4630fb65aef5f3f1789e94e60e52756f4d7a2a3f.zip |
do not use the cached option of GetTexture() for theme textures, as the cached option is obsolete now.
git-svn-id: svn://svn.code.sf.net/p/ultrastardx/svn/trunk@1255 b956fd51-792f-4845-bead-9b4dfca2ff2c
-rw-r--r-- | Game/Code/Menu/UMenu.pas | 19 |
1 files changed, 10 insertions, 9 deletions
diff --git a/Game/Code/Menu/UMenu.pas b/Game/Code/Menu/UMenu.pas index dd2ccb24..2606802a 100644 --- a/Game/Code/Menu/UMenu.pas +++ b/Game/Code/Menu/UMenu.pas @@ -374,7 +374,8 @@ begin end else begin - ButtonCollection[Num] := TButtonCollection.Create(Texture.GetTexture(Skin.GetTextureFileName(ThemeCollection.Style.Tex), ThemeCollection.Style.Typ, true)); // use cache texture + ButtonCollection[Num] := TButtonCollection.Create(Texture.GetTexture( + Skin.GetTextureFileName(ThemeCollection.Style.Tex), ThemeCollection.Style.Typ)); end; //Set Parent menu @@ -419,10 +420,13 @@ begin ButtonCollection[Num].Fade := ThemeCollection.Style.Fade; ButtonCollection[Num].FadeText := ThemeCollection.Style.FadeText; if (ThemeCollection.Style.Typ = TEXTURE_TYPE_COLORIZED) then + begin ButtonCollection[Num].FadeTex := Texture.GetTexture( Skin.GetTextureFileName(ThemeCollection.Style.FadeTex), TEXTURE_TYPE_COLORIZED, TempCol) - else - ButtonCollection[Num].FadeTex := Texture.GetTexture(Skin.GetTextureFileName(ThemeCollection.Style.FadeTex), ThemeCollection.Style.Typ, true); + end else begin + ButtonCollection[Num].FadeTex := Texture.GetTexture( + Skin.GetTextureFileName(ThemeCollection.Style.FadeTex), ThemeCollection.Style.Typ); + end; ButtonCollection[Num].FadeTexPos := ThemeCollection.Style.FadeTexPos; @@ -610,7 +614,8 @@ begin end else begin - Button[Result].FadeTex := Texture.GetTexture(Skin.GetTextureFileName(ThemeButton.FadeTex), ThemeButton.Typ, true); + Button[Result].FadeTex := Texture.GetTexture( + Skin.GetTextureFileName(ThemeButton.FadeTex), ThemeButton.Typ); end; Button[Result].FadeTexPos := ThemeButton.FadeTexPos; @@ -671,11 +676,7 @@ begin Result := Length(Button); SetLength(Button, Result + 1); end; - // Button[Result] := TButton.Create(Texture.GetTexture(Name, Typ)); - // check here for cache - // Texture.GetTexture(Name, Typ, false); // preloads textures and creates cahce mipmap when needed - // if Covers.CoverExists(Name) then // colorize hack if (Typ = TEXTURE_TYPE_COLORIZED) then begin @@ -685,7 +686,7 @@ begin end else begin - Button[Result] := TButton.Create(Texture.GetTexture(Name, Typ, true)); // use cache texture + Button[Result] := TButton.Create(Texture.GetTexture(Name, Typ)); end; // configures button |