mirror of
https://github.com/RetroDECK/ES-DE.git
synced 2024-11-25 15:45:38 +00:00
Fixed listSelectorColor's alpha not working properly.
This commit is contained in:
parent
8b1e061929
commit
8b242a0532
|
@ -7,6 +7,8 @@ ES will check two places for a theme: first, the system's search directory for t
|
||||||
|
|
||||||
Almost all positions, dimensions, origins, etc. work in percentages - that is, they are a decimal between 0 and 1, representing the percentage of the screen on that axis to use. This ensures that themes look similar at every resolution.
|
Almost all positions, dimensions, origins, etc. work in percentages - that is, they are a decimal between 0 and 1, representing the percentage of the screen on that axis to use. This ensures that themes look similar at every resolution.
|
||||||
|
|
||||||
|
Colors are hex values, either 6 or 8 characters, defined as RRGGBB or RRGGBBAA. If alpha is not included, a default value of FF will be assumed (not transparent).
|
||||||
|
|
||||||
|
|
||||||
Example
|
Example
|
||||||
=======
|
=======
|
||||||
|
@ -60,9 +62,9 @@ Display tags define some "meta" display attributes about your theme. Display tag
|
||||||
|
|
||||||
`<descColor>` - the hex font color to use for the description on the GuiGameList.
|
`<descColor>` - the hex font color to use for the description on the GuiGameList.
|
||||||
|
|
||||||
`<listSelectorColor>` - the hex color to use for the "selector bar" on the GuiGameList. Default is `000000`.
|
`<listSelectorColor>` - the hex color to use for the "selector bar" on the GuiGameList. Default is `000000FF`.
|
||||||
|
|
||||||
`<listSelectedColor>` - the hex color to use for selected text on the GuiGameList. Default is -1, which will not change the color.
|
`<listSelectedColor>` - the hex color to use for selected text on the GuiGameList. Default is the value of `<listPrimaryColor>`.
|
||||||
|
|
||||||
`<listLeftAlign />` - if present, the games list names will be left aligned to the value of `<listOffsetX>` (default 0.5).
|
`<listLeftAlign />` - if present, the games list names will be left aligned to the value of `<listOffsetX>` (default 0.5).
|
||||||
|
|
||||||
|
|
|
@ -1,6 +1,7 @@
|
||||||
October 17
|
October 17
|
||||||
-Added GuiAnimation class which animates its children.
|
-Added GuiAnimation class which animates its children.
|
||||||
-The game image on the game list now slides/fades in and out.
|
-The game image on the game list now slides/fades in and out.
|
||||||
|
-You can now define alpha in hex colors (add two characters) - e.g. FFFFFF2F
|
||||||
|
|
||||||
October 14
|
October 14
|
||||||
-Fixed game list continuing to scroll when a menu is opened or a game is started.
|
-Fixed game list continuing to scroll when a menu is opened or a game is started.
|
||||||
|
|
|
@ -40,15 +40,19 @@ namespace Renderer {
|
||||||
GLubyte colors[6*4];
|
GLubyte colors[6*4];
|
||||||
buildGLColorArray(colors, color, 6);
|
buildGLColorArray(colors, color, 6);
|
||||||
|
|
||||||
|
glEnable(GL_BLEND);
|
||||||
|
glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA);
|
||||||
glEnableClientState(GL_VERTEX_ARRAY);
|
glEnableClientState(GL_VERTEX_ARRAY);
|
||||||
glEnableClientState(GL_COLOR_ARRAY);
|
glEnableClientState(GL_COLOR_ARRAY);
|
||||||
|
|
||||||
glVertexPointer(2, GL_FLOAT, 0, points);
|
glVertexPointer(2, GL_FLOAT, 0, points);
|
||||||
glColorPointer(4, GL_UNSIGNED_BYTE, 0, colors);
|
glColorPointer(4, GL_UNSIGNED_BYTE, 0, colors);
|
||||||
|
|
||||||
glDrawArrays(GL_TRIANGLES, 0, 6);
|
glDrawArrays(GL_TRIANGLES, 0, 6);
|
||||||
|
|
||||||
|
glDisableClientState(GL_BLEND);
|
||||||
glDisableClientState(GL_VERTEX_ARRAY);
|
glDisableClientState(GL_VERTEX_ARRAY);
|
||||||
glDisableClientState(GL_COLOR_ARRAY);
|
glDisable(GL_COLOR_ARRAY);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -223,8 +223,6 @@ void GuiGameList::updateTheme()
|
||||||
mTheme->readXML(""); //clears any current theme
|
mTheme->readXML(""); //clears any current theme
|
||||||
|
|
||||||
mList->setSelectorColor(mTheme->getSelectorColor());
|
mList->setSelectorColor(mTheme->getSelectorColor());
|
||||||
std::cout << "selector alpha: " << (mTheme->getSelectorColor() & 0x000000ff) << "\n";
|
|
||||||
|
|
||||||
mList->setSelectedTextColor(mTheme->getSelectedTextColor());
|
mList->setSelectedTextColor(mTheme->getSelectedTextColor());
|
||||||
mList->setScrollSound(mTheme->getMenuScrollSound());
|
mList->setScrollSound(mTheme->getMenuScrollSound());
|
||||||
|
|
||||||
|
|
|
@ -223,7 +223,6 @@ template <typename listType>
|
||||||
void GuiList<listType>::setSelectorColor(unsigned int selectorColor)
|
void GuiList<listType>::setSelectorColor(unsigned int selectorColor)
|
||||||
{
|
{
|
||||||
mSelectorColor = selectorColor;
|
mSelectorColor = selectorColor;
|
||||||
std::cout << "mSelectorColor alpha: " << (mSelectorColor & 0x000000ff) << "\n";
|
|
||||||
}
|
}
|
||||||
|
|
||||||
template <typename listType>
|
template <typename listType>
|
||||||
|
|
Loading…
Reference in a new issue