Do Download Speed optional.

Cause I cannot properly fix that now.
This commit is contained in:
StackZ
2020-06-29 19:28:52 +02:00
parent 81f0b0d070
commit 85a18eb031
5 changed files with 38 additions and 18 deletions
+10
View File
@@ -98,4 +98,14 @@ void GFX::DrawButton(int x, int y, std::string ButtonText, u32 color) {
C2D_SetImageTint(&tint, C2D_BotRight, color, 0.5);
C2D_DrawImageAt(C2D_SpriteSheetGetImage(sprites, sprites_button_idx), x, y, 0.5f, &tint);
Gui::DrawStringCentered(- (158/2) + x, y + (61/2) - (Gui::GetStringHeight(0.6f, ButtonText) / 2), 0.6f, isScriptSelected ? TextColor : config->textColor(), ButtonText, 145, 30);
}
void GFX::TextFormatted(float x, float y, float size, const char *format, ...) {
char str[512];
va_list va;
va_start(va, format);
vsnprintf(str, 512, format, va);
va_end(va);
char * Text = strtok(str, "\n");
Gui::DrawStringCentered(x, y, size, isScriptSelected ? TextColor : config->textColor(), Text);
}