Fix up compilation.
This commit is contained in:
parent
7cab70f839
commit
19091a0e80
13 changed files with 46 additions and 48 deletions
|
@ -44,10 +44,7 @@ namespace Theme
|
|||
Label_Small,
|
||||
Body_Large,
|
||||
Body_Medium,
|
||||
Body_Small,
|
||||
Label_Large,
|
||||
Label_Medium,
|
||||
Label_Small
|
||||
Body_Small
|
||||
};
|
||||
};
|
||||
};
|
||||
|
|
|
@ -25,15 +25,15 @@ public:
|
|||
switch (token)
|
||||
{
|
||||
case Theme::Sys::StateLayerOpacity::State::Hover:
|
||||
return 0.08;
|
||||
return 0.08f;
|
||||
case Theme::Sys::StateLayerOpacity::State::Focus:
|
||||
return 0.12;
|
||||
return 0.12f;
|
||||
case Theme::Sys::StateLayerOpacity::State::Pressed:
|
||||
return 0.12;
|
||||
return 0.12f;
|
||||
case Theme::Sys::StateLayerOpacity::State::Dragged:
|
||||
return 0.16;
|
||||
return 0.16f;
|
||||
default:
|
||||
return 0.0;
|
||||
return 0.0f;
|
||||
}
|
||||
}
|
||||
};
|
||||
|
|
|
@ -7,7 +7,7 @@
|
|||
class ThemeManager
|
||||
{
|
||||
public:
|
||||
Color getColor(ThemeToken::SystemToken token) const;
|
||||
Color getColor(Theme::Sys::Color token) const;
|
||||
|
||||
private:
|
||||
std::unique_ptr<ITheme> mActiveTheme;
|
||||
|
|
|
@ -7,7 +7,7 @@ ThemeManager::ThemeManager()
|
|||
mTheme = std::make_unique<LightTheme>();
|
||||
}
|
||||
|
||||
Color ThemeManager::getColor(ThemeToken::SystemToken token) const
|
||||
Color ThemeManager::getColor(Theme::Sys::Color token) const
|
||||
{
|
||||
return mTheme->getColor(token);
|
||||
}
|
||||
|
|
|
@ -6,7 +6,7 @@ class ThemeManager
|
|||
{
|
||||
public:
|
||||
ThemeManager();
|
||||
Color getColor(ThemeToken::SystemToken token) const;
|
||||
Color getColor(Theme::Sys::Color token) const;
|
||||
private:
|
||||
std::unique_ptr<ITheme> mTheme;
|
||||
};
|
||||
|
|
|
@ -23,8 +23,8 @@ Widget::Widget()
|
|||
mRootNode(std::make_unique<TransformNode>()),
|
||||
mChildren(),
|
||||
mBorderThickness(0),
|
||||
mBackground(ThemeToken::SystemToken::Primary),
|
||||
mBorder(ThemeToken::SystemToken::Outline),
|
||||
mBackground(Theme::Sys::Color::Primary),
|
||||
mBorder(Theme::Sys::Color::Outline),
|
||||
mVisible(true)
|
||||
{
|
||||
mName = "Widget";
|
||||
|
@ -66,7 +66,7 @@ TransformNode* Widget::getRootNode() const
|
|||
|
||||
|
||||
|
||||
void Widget::setBackground(ThemeToken::SystemToken token)
|
||||
void Widget::setBackground(Theme::Sys::Color token)
|
||||
{
|
||||
if (mBackground != token)
|
||||
{
|
||||
|
|
|
@ -47,7 +47,7 @@ public:
|
|||
|
||||
virtual bool onKeyboardEvent(const KeyboardEvent* event);
|
||||
|
||||
void setBackground(ThemeToken::SystemToken token);
|
||||
void setBackground(Theme::Sys::Color token);
|
||||
|
||||
void setVisible(bool visible);
|
||||
|
||||
|
@ -78,8 +78,8 @@ protected:
|
|||
std::vector<std::unique_ptr<Widget> > mChildren;
|
||||
|
||||
unsigned mBorderThickness{0};
|
||||
ThemeToken::SystemToken mBackground;
|
||||
ThemeToken::SystemToken mBorder;
|
||||
Theme::Sys::Color mBackground;
|
||||
Theme::Sys::Color mBorder;
|
||||
|
||||
bool mVisible{true};
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue