migrant a SDL3
This commit is contained in:
@@ -242,7 +242,7 @@ void Notifier::show(std::vector<std::string> texts, int icon, const std::string
|
||||
|
||||
// Dibuja el fondo de la notificación
|
||||
SDL_SetRenderDrawColor(renderer_, bg_color_.r, bg_color_.g, bg_color_.b, 255);
|
||||
SDL_Rect rect;
|
||||
SDL_FRect rect;
|
||||
if (shape == NotificationShape::ROUNDED)
|
||||
{
|
||||
rect = {4, 0, width - (4 * 2), height};
|
||||
@@ -266,7 +266,7 @@ void Notifier::show(std::vector<std::string> texts, int icon, const std::string
|
||||
// Dibuja el icono de la notificación
|
||||
if (has_icons_ && icon >= 0 && texts.size() >= 2)
|
||||
{
|
||||
auto sp = std::make_unique<Sprite>(icon_texture_, (SDL_Rect){0, 0, icon_size, icon_size});
|
||||
auto sp = std::make_unique<Sprite>(icon_texture_, (SDL_FRect){0, 0, icon_size, icon_size});
|
||||
sp->setPosition({padding_in_h, padding_in_v, icon_size, icon_size});
|
||||
sp->setSpriteClip({icon_size * (icon % 10), icon_size * (icon / 10), icon_size, icon_size});
|
||||
sp->render();
|
||||
|
||||
Reference in New Issue
Block a user