mirror of
https://github.com/DarkStore-3DS/DarkStore.git
synced 2026-07-02 16:49:05 +00:00
Changed Some More Stuff To DarkStore & Removed All Translations For Now
This commit is contained in:
+11
-11
@@ -1,11 +1,11 @@
|
||||
*.bin
|
||||
*.d
|
||||
*.o
|
||||
*.smdh
|
||||
*.elf
|
||||
*.cia
|
||||
*.3dsx
|
||||
*/build
|
||||
build/sprites.h
|
||||
*.map
|
||||
*.lst
|
||||
*.bin
|
||||
*.d
|
||||
*.o
|
||||
*.smdh
|
||||
*.elf
|
||||
*.cia
|
||||
*.3dsx
|
||||
*/build
|
||||
build/sprites.h
|
||||
*.map
|
||||
*.lst
|
||||
|
||||
Vendored
+91
-91
@@ -1,92 +1,92 @@
|
||||
{
|
||||
"files.associations": {
|
||||
"*.tcc": "cpp",
|
||||
"cctype": "cpp",
|
||||
"clocale": "cpp",
|
||||
"cmath": "cpp",
|
||||
"cstdarg": "cpp",
|
||||
"cstddef": "cpp",
|
||||
"cstdio": "cpp",
|
||||
"cstdlib": "cpp",
|
||||
"cstring": "cpp",
|
||||
"ctime": "cpp",
|
||||
"cwchar": "cpp",
|
||||
"cwctype": "cpp",
|
||||
"exception": "cpp",
|
||||
"fstream": "cpp",
|
||||
"iosfwd": "cpp",
|
||||
"iostream": "cpp",
|
||||
"istream": "cpp",
|
||||
"limits": "cpp",
|
||||
"memory": "cpp",
|
||||
"new": "cpp",
|
||||
"ostream": "cpp",
|
||||
"sstream": "cpp",
|
||||
"stdexcept": "cpp",
|
||||
"streambuf": "cpp",
|
||||
"typeinfo": "cpp",
|
||||
"valarray": "cpp",
|
||||
"array": "cpp",
|
||||
"atomic": "cpp",
|
||||
"bit": "cpp",
|
||||
"cstdint": "cpp",
|
||||
"deque": "cpp",
|
||||
"forward_list": "cpp",
|
||||
"map": "cpp",
|
||||
"unordered_map": "cpp",
|
||||
"vector": "cpp",
|
||||
"algorithm": "cpp",
|
||||
"functional": "cpp",
|
||||
"iterator": "cpp",
|
||||
"memory_resource": "cpp",
|
||||
"numeric": "cpp",
|
||||
"optional": "cpp",
|
||||
"random": "cpp",
|
||||
"string": "cpp",
|
||||
"string_view": "cpp",
|
||||
"system_error": "cpp",
|
||||
"tuple": "cpp",
|
||||
"type_traits": "cpp",
|
||||
"utility": "cpp",
|
||||
"initializer_list": "cpp",
|
||||
"bitset": "cpp",
|
||||
"chrono": "cpp",
|
||||
"condition_variable": "cpp",
|
||||
"ratio": "cpp",
|
||||
"regex": "cpp",
|
||||
"shared_mutex": "cpp"
|
||||
},
|
||||
"terminal.integrated.shell.windows": "C:\\msys64\\usr\\bin\\bash.exe",
|
||||
"terminal.integrated.env.windows":
|
||||
{
|
||||
"MSYSTEM": "MINGW64",
|
||||
//"MSYS2_PATH_TYPE": "inherit",
|
||||
"MSVSCODE": "1"
|
||||
},
|
||||
|
||||
"terminal.integrated.profiles.windows": {
|
||||
|
||||
"PowerShell": {
|
||||
"source": "PowerShell",
|
||||
"icon": "terminal-powershell"
|
||||
},
|
||||
"Test": {
|
||||
"path": [
|
||||
"C:\\sys64\\sys2_shell.exe"
|
||||
],
|
||||
"args": [],
|
||||
"icon": "terminal-cmd"
|
||||
},
|
||||
"Command Prompt": {
|
||||
"path": [
|
||||
"${env:windir}\\Sysnative\\cmd.exe",
|
||||
"${env:windir}\\System32\\cmd.exe"
|
||||
],
|
||||
"args": [],
|
||||
"icon": "terminal-cmd"
|
||||
},
|
||||
"Git Bash": {
|
||||
"source": "Git Bash"
|
||||
}
|
||||
}
|
||||
{
|
||||
"files.associations": {
|
||||
"*.tcc": "cpp",
|
||||
"cctype": "cpp",
|
||||
"clocale": "cpp",
|
||||
"cmath": "cpp",
|
||||
"cstdarg": "cpp",
|
||||
"cstddef": "cpp",
|
||||
"cstdio": "cpp",
|
||||
"cstdlib": "cpp",
|
||||
"cstring": "cpp",
|
||||
"ctime": "cpp",
|
||||
"cwchar": "cpp",
|
||||
"cwctype": "cpp",
|
||||
"exception": "cpp",
|
||||
"fstream": "cpp",
|
||||
"iosfwd": "cpp",
|
||||
"iostream": "cpp",
|
||||
"istream": "cpp",
|
||||
"limits": "cpp",
|
||||
"memory": "cpp",
|
||||
"new": "cpp",
|
||||
"ostream": "cpp",
|
||||
"sstream": "cpp",
|
||||
"stdexcept": "cpp",
|
||||
"streambuf": "cpp",
|
||||
"typeinfo": "cpp",
|
||||
"valarray": "cpp",
|
||||
"array": "cpp",
|
||||
"atomic": "cpp",
|
||||
"bit": "cpp",
|
||||
"cstdint": "cpp",
|
||||
"deque": "cpp",
|
||||
"forward_list": "cpp",
|
||||
"map": "cpp",
|
||||
"unordered_map": "cpp",
|
||||
"vector": "cpp",
|
||||
"algorithm": "cpp",
|
||||
"functional": "cpp",
|
||||
"iterator": "cpp",
|
||||
"memory_resource": "cpp",
|
||||
"numeric": "cpp",
|
||||
"optional": "cpp",
|
||||
"random": "cpp",
|
||||
"string": "cpp",
|
||||
"string_view": "cpp",
|
||||
"system_error": "cpp",
|
||||
"tuple": "cpp",
|
||||
"type_traits": "cpp",
|
||||
"utility": "cpp",
|
||||
"initializer_list": "cpp",
|
||||
"bitset": "cpp",
|
||||
"chrono": "cpp",
|
||||
"condition_variable": "cpp",
|
||||
"ratio": "cpp",
|
||||
"regex": "cpp",
|
||||
"shared_mutex": "cpp"
|
||||
},
|
||||
"terminal.integrated.shell.windows": "C:\\msys64\\usr\\bin\\bash.exe",
|
||||
"terminal.integrated.env.windows":
|
||||
{
|
||||
"MSYSTEM": "MINGW64",
|
||||
//"MSYS2_PATH_TYPE": "inherit",
|
||||
"MSVSCODE": "1"
|
||||
},
|
||||
|
||||
"terminal.integrated.profiles.windows": {
|
||||
|
||||
"PowerShell": {
|
||||
"source": "PowerShell",
|
||||
"icon": "terminal-powershell"
|
||||
},
|
||||
"Test": {
|
||||
"path": [
|
||||
"C:\\sys64\\sys2_shell.exe"
|
||||
],
|
||||
"args": [],
|
||||
"icon": "terminal-cmd"
|
||||
},
|
||||
"Command Prompt": {
|
||||
"path": [
|
||||
"${env:windir}\\Sysnative\\cmd.exe",
|
||||
"${env:windir}\\System32\\cmd.exe"
|
||||
],
|
||||
"args": [],
|
||||
"icon": "terminal-cmd"
|
||||
},
|
||||
"Git Bash": {
|
||||
"source": "Git Bash"
|
||||
}
|
||||
}
|
||||
}
|
||||
Vendored
+18
-18
@@ -1,19 +1,19 @@
|
||||
{
|
||||
// See https://go.microsoft.com/fwlink/?LinkId=733558
|
||||
// for the documentation about the tasks.json format
|
||||
"version": "2.0.0",
|
||||
"tasks": [
|
||||
{
|
||||
"label": "Make",
|
||||
"command": "make",
|
||||
"args": ["-s"],
|
||||
"group": {
|
||||
"kind": "build",
|
||||
"isDefault": true
|
||||
},
|
||||
"presentation": {
|
||||
"reveal": "silent"
|
||||
}
|
||||
}
|
||||
]
|
||||
{
|
||||
// See https://go.microsoft.com/fwlink/?LinkId=733558
|
||||
// for the documentation about the tasks.json format
|
||||
"version": "2.0.0",
|
||||
"tasks": [
|
||||
{
|
||||
"label": "Make",
|
||||
"command": "make",
|
||||
"args": ["-s"],
|
||||
"group": {
|
||||
"kind": "build",
|
||||
"isDefault": true
|
||||
},
|
||||
"presentation": {
|
||||
"reveal": "silent"
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -1,316 +1,316 @@
|
||||
#---------------------------------------------------------------------------------
|
||||
.SUFFIXES:
|
||||
#---------------------------------------------------------------------------------
|
||||
|
||||
ifeq ($(strip $(DEVKITARM)),)
|
||||
$(error "Veuillez régler DEVKITARM dans votre environnement. export DEVKITARM = <chemin vers> devkitARM")
|
||||
endif
|
||||
|
||||
TOPDIR ?= $(CURDIR)
|
||||
include $(DEVKITARM)/3ds_rules
|
||||
|
||||
# ------------------------------------------------- --------------------------------
|
||||
# TARGET est le nom de la sortie
|
||||
# BUILD est le répertoire dans lequel les fichiers objets et les fichiers intermédiaires seront placés
|
||||
# SOURCES est une liste de répertoires contenant le code source
|
||||
# DATA est une liste de répertoires contenant des fichiers de données
|
||||
# INCLUDES est une liste de répertoires contenant des fichiers d'en-tête
|
||||
# GRAPHICS est une liste de répertoires contenant des fichiers graphiques
|
||||
# GFXBUILD est le répertoire dans lequel les fichiers graphiques convertis seront placés
|
||||
# S'il est défini sur $ (BUILD), il sera lié statiquement dans le fichier converti
|
||||
# fichiers comme s'il s'agissait de fichiers de données.
|
||||
#
|
||||
# NO_SMDH: s'il est défini sur quelque chose, aucun fichier SMDH n'est généré.
|
||||
# ROMFS est le répertoire qui contient le RomFS, relatif au Makefile (facultatif)
|
||||
# APP_TITLE est le nom de l'application stockée dans le fichier SMDH (facultatif)
|
||||
# APP_DESCRIPTION est la description de l'application stockée dans le fichier SMDH (facultatif)
|
||||
# APP_AUTHOR est l'auteur de l'application stockée dans le fichier SMDH (facultatif)
|
||||
# ICON est le nom de fichier de l'icône (.png), relatif au dossier du projet.
|
||||
# S'il n'est pas défini, il tente d'utiliser l'un des éléments suivants (dans cet ordre):
|
||||
# - <Nom du projet> .png
|
||||
# - icon.png
|
||||
# - <dossier libctru> /default_icon.png
|
||||
|
||||
#---------------------------------------------------------------------------------
|
||||
# Outils externes
|
||||
#---------------------------------------------------------------------------------
|
||||
ifeq ($(OS),Windows_NT)
|
||||
MAKEROM ?= ../makerom.exe
|
||||
BANNERTOOL ?= ../bannertool.exe
|
||||
|
||||
else
|
||||
MAKEROM ?= makerom
|
||||
BANNERTOOL ?= bannertool
|
||||
|
||||
endif
|
||||
|
||||
CURRENT_VERSION := $(shell git describe --abbrev=0 --tags)
|
||||
|
||||
# Si sur un commit taggé, utilisez le tag au lieu du commit
|
||||
ifneq ($(shell echo $(shell git tag -l --points-at HEAD) | head -c 1),)
|
||||
GIT_VER := $(shell git tag -l --points-at HEAD)
|
||||
else
|
||||
GIT_VER := $(shell git describe --abbrev=0 --tags)-$(shell git rev-parse --short HEAD)
|
||||
endif
|
||||
|
||||
#---------------------------------------------------------------------------------
|
||||
# Version number
|
||||
#---------------------------------------------------------------------------------
|
||||
ifneq ($(shell echo $(shell git describe --tags) | head -c 2 | tail -c 1),)
|
||||
VERSION_MAJOR := $(shell echo $(shell git describe --tags) | head -c 2 | tail -c 1)
|
||||
else
|
||||
VERSION_MAJOR := 0
|
||||
endif
|
||||
|
||||
ifneq ($(shell echo $(shell git describe --tags) | head -c 4 | tail -c 1),)
|
||||
VERSION_MINOR := $(shell echo $(shell git describe --tags) | head -c 4 | tail -c 1)
|
||||
else
|
||||
VERSION_MINOR := 0
|
||||
endif
|
||||
|
||||
ifneq ($(shell echo $(shell git describe --tags) | head -c 6 | tail -c 1),)
|
||||
VERSION_MICRO := $(shell echo $(shell git describe --tags) | head -c 6 | tail -c 1)
|
||||
else
|
||||
VERSION_MICRO := 0
|
||||
endif
|
||||
|
||||
#---------------------------------------------------------------------------------
|
||||
TARGET := DarkStore
|
||||
BUILD := build
|
||||
UNIVCORE := Universal-Core
|
||||
SOURCES := $(UNIVCORE) source source/download source/gui source/lang source/menu source/overlays \
|
||||
source/qr source/screens source/store source/utils
|
||||
DATA := data
|
||||
INCLUDES := $(UNIVCORE) include include/download include/gui include/lang include/overlays include/qr include/screens \
|
||||
include/store include/utils
|
||||
GRAPHICS := assets/gfx
|
||||
ROMFS := romfs
|
||||
GFXBUILD := $(ROMFS)/gfx
|
||||
APP_AUTHOR := Dark98, Universal Team
|
||||
APP_DESCRIPTION := An Alternative eShop for Nintendo 3DS
|
||||
ICON := app/icon.png
|
||||
BNR_IMAGE := app/banner.png
|
||||
BNR_AUDIO := app/BannerAudio.wav
|
||||
RSF_FILE := app/build-cia.rsf
|
||||
|
||||
#---------------------------------------------------------------------------------
|
||||
# options de génération de code
|
||||
#---------------------------------------------------------------------------------
|
||||
ARCH := -march=armv6k -mtune=mpcore -mfloat-abi=hard -mtp=soft
|
||||
|
||||
CFLAGS := -g -Wall -Wno-psabi -O2 -mword-relocations \
|
||||
-DV_STRING=\"$(GIT_VER)\" \
|
||||
-DC_V=\"$(CURRENT_VERSION)\" \
|
||||
-fomit-frame-pointer -ffunction-sections \
|
||||
$(ARCH)
|
||||
|
||||
CFLAGS += $(INCLUDE) -DARM11 -D_3DS -D_GNU_SOURCE=1
|
||||
|
||||
CXXFLAGS := $(CFLAGS) -fno-rtti -fno-exceptions -std=gnu++17
|
||||
|
||||
ASFLAGS := -g $(ARCH)
|
||||
LDFLAGS = -specs=3dsx.specs -g $(ARCH) -Wl,-Map,$(notdir $*.map)
|
||||
|
||||
LIBS := -lcurl -lmbedtls -lmbedx509 -lmbedcrypto -larchive -lbz2 -llzma -lm -lz -lcitro2d -lcitro3d -lctru -lstdc++
|
||||
|
||||
#---------------------------------------------------------------------------------
|
||||
# liste de répertoires contenant des bibliothèques, ce doit être le niveau supérieur contenant
|
||||
# include et lib
|
||||
#---------------------------------------------------------------------------------
|
||||
LIBDIRS := $(PORTLIBS) $(CTRULIB)
|
||||
|
||||
|
||||
#---------------------------------------------------------------------------------
|
||||
# pas vraiment besoin de modifier quoi que ce soit au-delà de ce point, sauf si vous devez ajouter des
|
||||
# règles pour différentes extensions de fichiers
|
||||
#---------------------------------------------------------------------------------
|
||||
ifneq ($(BUILD),$(notdir $(CURDIR)))
|
||||
#---------------------------------------------------------------------------------
|
||||
|
||||
export OUTPUT := $(CURDIR)/$(TARGET)
|
||||
export TOPDIR := $(CURDIR)
|
||||
|
||||
export VPATH := $(foreach dir,$(SOURCES),$(CURDIR)/$(dir)) \
|
||||
$(foreach dir,$(GRAPHICS),$(CURDIR)/$(dir)) \
|
||||
$(foreach dir,$(DATA),$(CURDIR)/$(dir))
|
||||
|
||||
export DEPSDIR := $(CURDIR)/$(BUILD)
|
||||
|
||||
CFILES := $(foreach dir,$(SOURCES),$(notdir $(wildcard $(dir)/*.c)))
|
||||
CPPFILES := $(foreach dir,$(SOURCES),$(notdir $(wildcard $(dir)/*.cpp)))
|
||||
SFILES := $(foreach dir,$(SOURCES),$(notdir $(wildcard $(dir)/*.s)))
|
||||
PICAFILES := $(foreach dir,$(SOURCES),$(notdir $(wildcard $(dir)/*.v.pica)))
|
||||
SHLISTFILES := $(foreach dir,$(SOURCES),$(notdir $(wildcard $(dir)/*.shlist)))
|
||||
GFXFILES := $(foreach dir,$(GRAPHICS),$(notdir $(wildcard $(dir)/*.t3s)))
|
||||
BINFILES := $(foreach dir,$(DATA),$(notdir $(wildcard $(dir)/*.*)))
|
||||
|
||||
#---------------------------------------------------------------------------------
|
||||
# utiliser CXX pour lier des projets C ++, CC pour le C standard
|
||||
#---------------------------------------------------------------------------------
|
||||
ifeq ($(strip $(CPPFILES)),)
|
||||
#---------------------------------------------------------------------------------
|
||||
export LD := $(CC)
|
||||
#---------------------------------------------------------------------------------
|
||||
else
|
||||
#---------------------------------------------------------------------------------
|
||||
export LD := $(CXX)
|
||||
#---------------------------------------------------------------------------------
|
||||
endif
|
||||
#---------------------------------------------------------------------------------
|
||||
|
||||
#---------------------------------------------------------------------------------
|
||||
ifeq ($(GFXBUILD),$(BUILD))
|
||||
#---------------------------------------------------------------------------------
|
||||
export T3XFILES := $(GFXFILES:.t3s=.t3x)
|
||||
#---------------------------------------------------------------------------------
|
||||
else
|
||||
#---------------------------------------------------------------------------------
|
||||
export ROMFS_T3XFILES := $(patsubst %.t3s, $(GFXBUILD)/%.t3x, $(GFXFILES))
|
||||
export T3XHFILES := $(patsubst %.t3s, $(BUILD)/%.h, $(GFXFILES))
|
||||
#---------------------------------------------------------------------------------
|
||||
endif
|
||||
#---------------------------------------------------------------------------------
|
||||
|
||||
export OFILES_SOURCES := $(CPPFILES:.cpp=.o) $(CFILES:.c=.o) $(SFILES:.s=.o)
|
||||
|
||||
export OFILES_BIN := $(addsuffix .o,$(BINFILES)) \
|
||||
$(PICAFILES:.v.pica=.shbin.o) $(SHLISTFILES:.shlist=.shbin.o)
|
||||
|
||||
export OFILES := $(OFILES_BIN) $(OFILES_SOURCES)
|
||||
|
||||
export HFILES := $(PICAFILES:.v.pica=_shbin.h) $(SHLISTFILES:.shlist=_shbin.h) \
|
||||
$(addsuffix .h,$(subst .,_,$(BINFILES)))
|
||||
|
||||
export INCLUDE := $(foreach dir,$(INCLUDES),-I$(CURDIR)/$(dir)) \
|
||||
$(foreach dir,$(LIBDIRS),-I$(dir)/include) \
|
||||
-I$(CURDIR)/$(BUILD)
|
||||
|
||||
export LIBPATHS := $(foreach dir,$(LIBDIRS),-L$(dir)/lib)
|
||||
|
||||
export _3DSXDEPS := $(if $(NO_SMDH),,$(OUTPUT).smdh)
|
||||
|
||||
ifeq ($(strip $(ICON)),)
|
||||
icons := $(wildcard *.png)
|
||||
ifneq (,$(findstring $(TARGET).png,$(icons)))
|
||||
export APP_ICON := $(TOPDIR)/$(TARGET).png
|
||||
else
|
||||
ifneq (,$(findstring icon.png,$(icons)))
|
||||
export APP_ICON := $(TOPDIR)/icon.png
|
||||
endif
|
||||
endif
|
||||
else
|
||||
export APP_ICON := $(TOPDIR)/$(ICON)
|
||||
endif
|
||||
|
||||
ifeq ($(strip $(NO_SMDH)),)
|
||||
export _3DSXFLAGS += --smdh=$(CURDIR)/$(TARGET).smdh
|
||||
endif
|
||||
|
||||
ifneq ($(ROMFS),)
|
||||
export _3DSXFLAGS += --romfs=$(CURDIR)/$(ROMFS)
|
||||
endif
|
||||
|
||||
.PHONY: all clean
|
||||
|
||||
#---------------------------------------------------------------------------------
|
||||
all: $(BUILD) $(GFXBUILD) $(DEPSDIR) $(ROMFS_T3XFILES) $(T3XHFILES)
|
||||
@$(MAKE) --no-print-directory -C $(BUILD) -f $(CURDIR)/Makefile
|
||||
|
||||
#------------------------------------------------------------------------------
|
||||
clean:
|
||||
@echo clean ...
|
||||
@rm -fr DarkStore.elf
|
||||
@rm -fr DarkStore.cia
|
||||
@rm -fr DarkStore.3dsx
|
||||
@rm -fr DarkStore.smdh
|
||||
@rm -fr $(OUTDIR)
|
||||
@rm -fr $(BUILD)
|
||||
|
||||
#---------------------------------------------------------------------------------
|
||||
cia: $(BUILD)
|
||||
@$(MAKE) --no-print-directory -C $(BUILD) -f $(CURDIR)/Makefile cia
|
||||
|
||||
#---------------------------------------------------------------------------------
|
||||
3dsx: $(BUILD)
|
||||
@$(MAKE) --no-print-directory -C $(BUILD) -f $(CURDIR)/Makefile 3dsx
|
||||
|
||||
#---------------------------------------------------------------------------------
|
||||
$(GFXBUILD)/%.t3x $(BUILD)/%.h : %.t3s
|
||||
#---------------------------------------------------------------------------------
|
||||
@echo $(notdir $<)
|
||||
$(DEVKITPRO)/tools/bin/tex3ds -i $< -H $(BUILD)/$*.h -d $(DEPSDIR)/$*.d -o $(GFXBUILD)/$*.t3x
|
||||
|
||||
#---------------------------------------------------------------------------------
|
||||
$(BUILD):
|
||||
@[ -d $@ ] || mkdir -p $@
|
||||
|
||||
#---------------------------------------------------------------------------------
|
||||
else
|
||||
|
||||
#---------------------------------------------------------------------------------
|
||||
# cibles principales
|
||||
#---------------------------------------------------------------------------------
|
||||
all: $(OUTPUT).cia $(OUTPUT).elf $(OUTPUT).3dsx
|
||||
|
||||
$(OUTPUT).elf : $(OFILES)
|
||||
|
||||
$(OUTPUT).cia : $(OUTPUT).elf $(OUTPUT).smdh
|
||||
$(BANNERTOOL) makebanner -i "../app/banner.png" -a "../app/BannerAudio.wav" -o "../app/banner.bin"
|
||||
|
||||
$(BANNERTOOL) makesmdh -i "../app/icon.png" -s "$(TARGET)" -l "$(APP_DESCRIPTION)" -p "$(APP_AUTHOR)" -o "../app/icon.bin" \
|
||||
--flags visible,ratingrequired,recordusage --cero 153 --esrb 153 --usk 153 --pegigen 153 --pegiptr 153 --pegibbfc 153 --cob 153 --grb 153 --cgsrr 153
|
||||
|
||||
$(MAKEROM) -f cia -target t -exefslogo -o "../$(TARGET).cia" -elf "../$(TARGET).elf" -rsf "../app/build-cia.rsf" -banner "../app/banner.bin" -icon "../app/icon.bin" -logo "../app/logo.bcma.lz" -DAPP_ROMFS="$(TOPDIR)/$(ROMFS)" -major $(VERSION_MAJOR) -minor $(VERSION_MINOR) -DAPP_VERSION_MAJOR="$(VERSION_MAJOR)"
|
||||
#---------------------------------------------------------------------------------
|
||||
# vous avez besoin d'une règle comme celle-ci pour chaque extension que vous utilisez comme données binaires
|
||||
#---------------------------------------------------------------------------------
|
||||
%.bin.o %_bin.h : %.bin
|
||||
#---------------------------------------------------------------------------------
|
||||
@echo $(notdir $<)
|
||||
@$(bin2o)
|
||||
|
||||
#---------------------------------------------------------------------------------
|
||||
.PRECIOUS : %.t3x
|
||||
#---------------------------------------------------------------------------------
|
||||
%.t3x.o %_t3x.h : %.t3x
|
||||
#---------------------------------------------------------------------------------
|
||||
@echo $(notdir $<)
|
||||
@$(bin2o)
|
||||
|
||||
#---------------------------------------------------------------------------------
|
||||
# règles d'assemblage de shaders GPU
|
||||
#---------------------------------------------------------------------------------
|
||||
define shader-as
|
||||
$(eval CURBIN := $*.shbin)
|
||||
$(eval DEPSFILE := $(DEPSDIR)/$*.shbin.d)
|
||||
echo "$(CURBIN).o: $< $1" > $(DEPSFILE)
|
||||
echo "extern const u8" `(echo $(CURBIN) | sed -e 's/^\([0-9]\)/_\1/' | tr . _)`"_end[];" > `(echo $(CURBIN) | tr . _)`.h
|
||||
echo "extern const u8" `(echo $(CURBIN) | sed -e 's/^\([0-9]\)/_\1/' | tr . _)`"[];" >> `(echo $(CURBIN) | tr . _)`.h
|
||||
echo "extern const u32" `(echo $(CURBIN) | sed -e 's/^\([0-9]\)/_\1/' | tr . _)`_size";" >> `(echo $(CURBIN) | tr . _)`.h
|
||||
picasso -o $(CURBIN) $1
|
||||
bin2s $(CURBIN) | $(AS) -o $*.shbin.o
|
||||
endef
|
||||
|
||||
%.shbin.o %_shbin.h : %.v.pica %.g.pica
|
||||
@echo $(notdir $^)
|
||||
@$(call shader-as,$^)
|
||||
|
||||
%.shbin.o %_shbin.h : %.v.pica
|
||||
@echo $(notdir $<)
|
||||
@$(call shader-as,$<)
|
||||
|
||||
%.shbin.o %_shbin.h : %.shlist
|
||||
@echo $(notdir $<)
|
||||
@$(call shader-as,$(foreach file,$(shell cat $<),$(dir $<)$(file)))
|
||||
|
||||
#---------------------------------------------------------------------------------
|
||||
%.t3x %.h : %.t3s
|
||||
#---------------------------------------------------------------------------------
|
||||
@echo $(notdir $<)
|
||||
@tex3ds -i $< -H $*.h -d $*.d -o $*.t3x
|
||||
|
||||
-include $(DEPSDIR)/*.d
|
||||
|
||||
#---------------------------------------------------------------------------------------
|
||||
endif
|
||||
#---------------------------------------------------------------------------------------
|
||||
#---------------------------------------------------------------------------------
|
||||
.SUFFIXES:
|
||||
#---------------------------------------------------------------------------------
|
||||
|
||||
ifeq ($(strip $(DEVKITARM)),)
|
||||
$(error "Veuillez régler DEVKITARM dans votre environnement. export DEVKITARM = <chemin vers> devkitARM")
|
||||
endif
|
||||
|
||||
TOPDIR ?= $(CURDIR)
|
||||
include $(DEVKITARM)/3ds_rules
|
||||
|
||||
# ------------------------------------------------- --------------------------------
|
||||
# TARGET est le nom de la sortie
|
||||
# BUILD est le répertoire dans lequel les fichiers objets et les fichiers intermédiaires seront placés
|
||||
# SOURCES est une liste de répertoires contenant le code source
|
||||
# DATA est une liste de répertoires contenant des fichiers de données
|
||||
# INCLUDES est une liste de répertoires contenant des fichiers d'en-tête
|
||||
# GRAPHICS est une liste de répertoires contenant des fichiers graphiques
|
||||
# GFXBUILD est le répertoire dans lequel les fichiers graphiques convertis seront placés
|
||||
# S'il est défini sur $ (BUILD), il sera lié statiquement dans le fichier converti
|
||||
# fichiers comme s'il s'agissait de fichiers de données.
|
||||
#
|
||||
# NO_SMDH: s'il est défini sur quelque chose, aucun fichier SMDH n'est généré.
|
||||
# ROMFS est le répertoire qui contient le RomFS, relatif au Makefile (facultatif)
|
||||
# APP_TITLE est le nom de l'application stockée dans le fichier SMDH (facultatif)
|
||||
# APP_DESCRIPTION est la description de l'application stockée dans le fichier SMDH (facultatif)
|
||||
# APP_AUTHOR est l'auteur de l'application stockée dans le fichier SMDH (facultatif)
|
||||
# ICON est le nom de fichier de l'icône (.png), relatif au dossier du projet.
|
||||
# S'il n'est pas défini, il tente d'utiliser l'un des éléments suivants (dans cet ordre):
|
||||
# - <Nom du projet> .png
|
||||
# - icon.png
|
||||
# - <dossier libctru> /default_icon.png
|
||||
|
||||
#---------------------------------------------------------------------------------
|
||||
# Outils externes
|
||||
#---------------------------------------------------------------------------------
|
||||
ifeq ($(OS),Windows_NT)
|
||||
MAKEROM ?= ../makerom.exe
|
||||
BANNERTOOL ?= ../bannertool.exe
|
||||
|
||||
else
|
||||
MAKEROM ?= makerom
|
||||
BANNERTOOL ?= bannertool
|
||||
|
||||
endif
|
||||
|
||||
CURRENT_VERSION := $(shell git describe --abbrev=0 --tags)
|
||||
|
||||
# Si sur un commit taggé, utilisez le tag au lieu du commit
|
||||
ifneq ($(shell echo $(shell git tag -l --points-at HEAD) | head -c 1),)
|
||||
GIT_VER := $(shell git tag -l --points-at HEAD)
|
||||
else
|
||||
GIT_VER := $(shell git describe --abbrev=0 --tags)-$(shell git rev-parse --short HEAD)
|
||||
endif
|
||||
|
||||
#---------------------------------------------------------------------------------
|
||||
# Version number
|
||||
#---------------------------------------------------------------------------------
|
||||
ifneq ($(shell echo $(shell git describe --tags) | head -c 2 | tail -c 1),)
|
||||
VERSION_MAJOR := $(shell echo $(shell git describe --tags) | head -c 2 | tail -c 1)
|
||||
else
|
||||
VERSION_MAJOR := 0
|
||||
endif
|
||||
|
||||
ifneq ($(shell echo $(shell git describe --tags) | head -c 4 | tail -c 1),)
|
||||
VERSION_MINOR := $(shell echo $(shell git describe --tags) | head -c 4 | tail -c 1)
|
||||
else
|
||||
VERSION_MINOR := 0
|
||||
endif
|
||||
|
||||
ifneq ($(shell echo $(shell git describe --tags) | head -c 6 | tail -c 1),)
|
||||
VERSION_MICRO := $(shell echo $(shell git describe --tags) | head -c 6 | tail -c 1)
|
||||
else
|
||||
VERSION_MICRO := 0
|
||||
endif
|
||||
|
||||
#---------------------------------------------------------------------------------
|
||||
TARGET := DarkStore
|
||||
BUILD := build
|
||||
UNIVCORE := Universal-Core
|
||||
SOURCES := $(UNIVCORE) source source/download source/gui source/lang source/menu source/overlays \
|
||||
source/qr source/screens source/store source/utils
|
||||
DATA := data
|
||||
INCLUDES := $(UNIVCORE) include include/download include/gui include/lang include/overlays include/qr include/screens \
|
||||
include/store include/utils
|
||||
GRAPHICS := assets/gfx
|
||||
ROMFS := romfs
|
||||
GFXBUILD := $(ROMFS)/gfx
|
||||
APP_AUTHOR := Dark98, Universal Team
|
||||
APP_DESCRIPTION := An Alternative eShop for Nintendo 3DS
|
||||
ICON := app/icon.png
|
||||
BNR_IMAGE := app/banner.png
|
||||
BNR_AUDIO := app/BannerAudio.wav
|
||||
RSF_FILE := app/build-cia.rsf
|
||||
|
||||
#---------------------------------------------------------------------------------
|
||||
# options de génération de code
|
||||
#---------------------------------------------------------------------------------
|
||||
ARCH := -march=armv6k -mtune=mpcore -mfloat-abi=hard -mtp=soft
|
||||
|
||||
CFLAGS := -g -Wall -Wno-psabi -O2 -mword-relocations \
|
||||
-DV_STRING=\"$(GIT_VER)\" \
|
||||
-DC_V=\"$(CURRENT_VERSION)\" \
|
||||
-fomit-frame-pointer -ffunction-sections \
|
||||
$(ARCH)
|
||||
|
||||
CFLAGS += $(INCLUDE) -DARM11 -D_3DS -D_GNU_SOURCE=1
|
||||
|
||||
CXXFLAGS := $(CFLAGS) -fno-rtti -fno-exceptions -std=gnu++17
|
||||
|
||||
ASFLAGS := -g $(ARCH)
|
||||
LDFLAGS = -specs=3dsx.specs -g $(ARCH) -Wl,-Map,$(notdir $*.map)
|
||||
|
||||
LIBS := -lcurl -lmbedtls -lmbedx509 -lmbedcrypto -larchive -lbz2 -llzma -lm -lz -lcitro2d -lcitro3d -lctru -lstdc++
|
||||
|
||||
#---------------------------------------------------------------------------------
|
||||
# liste de répertoires contenant des bibliothèques, ce doit être le niveau supérieur contenant
|
||||
# include et lib
|
||||
#---------------------------------------------------------------------------------
|
||||
LIBDIRS := $(PORTLIBS) $(CTRULIB)
|
||||
|
||||
|
||||
#---------------------------------------------------------------------------------
|
||||
# pas vraiment besoin de modifier quoi que ce soit au-delà de ce point, sauf si vous devez ajouter des
|
||||
# règles pour différentes extensions de fichiers
|
||||
#---------------------------------------------------------------------------------
|
||||
ifneq ($(BUILD),$(notdir $(CURDIR)))
|
||||
#---------------------------------------------------------------------------------
|
||||
|
||||
export OUTPUT := $(CURDIR)/$(TARGET)
|
||||
export TOPDIR := $(CURDIR)
|
||||
|
||||
export VPATH := $(foreach dir,$(SOURCES),$(CURDIR)/$(dir)) \
|
||||
$(foreach dir,$(GRAPHICS),$(CURDIR)/$(dir)) \
|
||||
$(foreach dir,$(DATA),$(CURDIR)/$(dir))
|
||||
|
||||
export DEPSDIR := $(CURDIR)/$(BUILD)
|
||||
|
||||
CFILES := $(foreach dir,$(SOURCES),$(notdir $(wildcard $(dir)/*.c)))
|
||||
CPPFILES := $(foreach dir,$(SOURCES),$(notdir $(wildcard $(dir)/*.cpp)))
|
||||
SFILES := $(foreach dir,$(SOURCES),$(notdir $(wildcard $(dir)/*.s)))
|
||||
PICAFILES := $(foreach dir,$(SOURCES),$(notdir $(wildcard $(dir)/*.v.pica)))
|
||||
SHLISTFILES := $(foreach dir,$(SOURCES),$(notdir $(wildcard $(dir)/*.shlist)))
|
||||
GFXFILES := $(foreach dir,$(GRAPHICS),$(notdir $(wildcard $(dir)/*.t3s)))
|
||||
BINFILES := $(foreach dir,$(DATA),$(notdir $(wildcard $(dir)/*.*)))
|
||||
|
||||
#---------------------------------------------------------------------------------
|
||||
# utiliser CXX pour lier des projets C ++, CC pour le C standard
|
||||
#---------------------------------------------------------------------------------
|
||||
ifeq ($(strip $(CPPFILES)),)
|
||||
#---------------------------------------------------------------------------------
|
||||
export LD := $(CC)
|
||||
#---------------------------------------------------------------------------------
|
||||
else
|
||||
#---------------------------------------------------------------------------------
|
||||
export LD := $(CXX)
|
||||
#---------------------------------------------------------------------------------
|
||||
endif
|
||||
#---------------------------------------------------------------------------------
|
||||
|
||||
#---------------------------------------------------------------------------------
|
||||
ifeq ($(GFXBUILD),$(BUILD))
|
||||
#---------------------------------------------------------------------------------
|
||||
export T3XFILES := $(GFXFILES:.t3s=.t3x)
|
||||
#---------------------------------------------------------------------------------
|
||||
else
|
||||
#---------------------------------------------------------------------------------
|
||||
export ROMFS_T3XFILES := $(patsubst %.t3s, $(GFXBUILD)/%.t3x, $(GFXFILES))
|
||||
export T3XHFILES := $(patsubst %.t3s, $(BUILD)/%.h, $(GFXFILES))
|
||||
#---------------------------------------------------------------------------------
|
||||
endif
|
||||
#---------------------------------------------------------------------------------
|
||||
|
||||
export OFILES_SOURCES := $(CPPFILES:.cpp=.o) $(CFILES:.c=.o) $(SFILES:.s=.o)
|
||||
|
||||
export OFILES_BIN := $(addsuffix .o,$(BINFILES)) \
|
||||
$(PICAFILES:.v.pica=.shbin.o) $(SHLISTFILES:.shlist=.shbin.o)
|
||||
|
||||
export OFILES := $(OFILES_BIN) $(OFILES_SOURCES)
|
||||
|
||||
export HFILES := $(PICAFILES:.v.pica=_shbin.h) $(SHLISTFILES:.shlist=_shbin.h) \
|
||||
$(addsuffix .h,$(subst .,_,$(BINFILES)))
|
||||
|
||||
export INCLUDE := $(foreach dir,$(INCLUDES),-I$(CURDIR)/$(dir)) \
|
||||
$(foreach dir,$(LIBDIRS),-I$(dir)/include) \
|
||||
-I$(CURDIR)/$(BUILD)
|
||||
|
||||
export LIBPATHS := $(foreach dir,$(LIBDIRS),-L$(dir)/lib)
|
||||
|
||||
export _3DSXDEPS := $(if $(NO_SMDH),,$(OUTPUT).smdh)
|
||||
|
||||
ifeq ($(strip $(ICON)),)
|
||||
icons := $(wildcard *.png)
|
||||
ifneq (,$(findstring $(TARGET).png,$(icons)))
|
||||
export APP_ICON := $(TOPDIR)/$(TARGET).png
|
||||
else
|
||||
ifneq (,$(findstring icon.png,$(icons)))
|
||||
export APP_ICON := $(TOPDIR)/icon.png
|
||||
endif
|
||||
endif
|
||||
else
|
||||
export APP_ICON := $(TOPDIR)/$(ICON)
|
||||
endif
|
||||
|
||||
ifeq ($(strip $(NO_SMDH)),)
|
||||
export _3DSXFLAGS += --smdh=$(CURDIR)/$(TARGET).smdh
|
||||
endif
|
||||
|
||||
ifneq ($(ROMFS),)
|
||||
export _3DSXFLAGS += --romfs=$(CURDIR)/$(ROMFS)
|
||||
endif
|
||||
|
||||
.PHONY: all clean
|
||||
|
||||
#---------------------------------------------------------------------------------
|
||||
all: $(BUILD) $(GFXBUILD) $(DEPSDIR) $(ROMFS_T3XFILES) $(T3XHFILES)
|
||||
@$(MAKE) --no-print-directory -C $(BUILD) -f $(CURDIR)/Makefile
|
||||
|
||||
#------------------------------------------------------------------------------
|
||||
clean:
|
||||
@echo clean ...
|
||||
@rm -fr DarkStore.elf
|
||||
@rm -fr DarkStore.cia
|
||||
@rm -fr DarkStore.3dsx
|
||||
@rm -fr DarkStore.smdh
|
||||
@rm -fr $(OUTDIR)
|
||||
@rm -fr $(BUILD)
|
||||
|
||||
#---------------------------------------------------------------------------------
|
||||
cia: $(BUILD)
|
||||
@$(MAKE) --no-print-directory -C $(BUILD) -f $(CURDIR)/Makefile cia
|
||||
|
||||
#---------------------------------------------------------------------------------
|
||||
3dsx: $(BUILD)
|
||||
@$(MAKE) --no-print-directory -C $(BUILD) -f $(CURDIR)/Makefile 3dsx
|
||||
|
||||
#---------------------------------------------------------------------------------
|
||||
$(GFXBUILD)/%.t3x $(BUILD)/%.h : %.t3s
|
||||
#---------------------------------------------------------------------------------
|
||||
@echo $(notdir $<)
|
||||
$(DEVKITPRO)/tools/bin/tex3ds -i $< -H $(BUILD)/$*.h -d $(DEPSDIR)/$*.d -o $(GFXBUILD)/$*.t3x
|
||||
|
||||
#---------------------------------------------------------------------------------
|
||||
$(BUILD):
|
||||
@[ -d $@ ] || mkdir -p $@
|
||||
|
||||
#---------------------------------------------------------------------------------
|
||||
else
|
||||
|
||||
#---------------------------------------------------------------------------------
|
||||
# cibles principales
|
||||
#---------------------------------------------------------------------------------
|
||||
all: $(OUTPUT).cia $(OUTPUT).elf $(OUTPUT).3dsx
|
||||
|
||||
$(OUTPUT).elf : $(OFILES)
|
||||
|
||||
$(OUTPUT).cia : $(OUTPUT).elf $(OUTPUT).smdh
|
||||
$(BANNERTOOL) makebanner -i "../app/banner.png" -a "../app/BannerAudio.wav" -o "../app/banner.bin"
|
||||
|
||||
$(BANNERTOOL) makesmdh -i "../app/icon.png" -s "$(TARGET)" -l "$(APP_DESCRIPTION)" -p "$(APP_AUTHOR)" -o "../app/icon.bin" \
|
||||
--flags visible,ratingrequired,recordusage --cero 153 --esrb 153 --usk 153 --pegigen 153 --pegiptr 153 --pegibbfc 153 --cob 153 --grb 153 --cgsrr 153
|
||||
|
||||
$(MAKEROM) -f cia -target t -exefslogo -o "../$(TARGET).cia" -elf "../$(TARGET).elf" -rsf "../app/build-cia.rsf" -banner "../app/banner.bin" -icon "../app/icon.bin" -logo "../app/logo.bcma.lz" -DAPP_ROMFS="$(TOPDIR)/$(ROMFS)" -major $(VERSION_MAJOR) -minor $(VERSION_MINOR) -DAPP_VERSION_MAJOR="$(VERSION_MAJOR)"
|
||||
#---------------------------------------------------------------------------------
|
||||
# vous avez besoin d'une règle comme celle-ci pour chaque extension que vous utilisez comme données binaires
|
||||
#---------------------------------------------------------------------------------
|
||||
%.bin.o %_bin.h : %.bin
|
||||
#---------------------------------------------------------------------------------
|
||||
@echo $(notdir $<)
|
||||
@$(bin2o)
|
||||
|
||||
#---------------------------------------------------------------------------------
|
||||
.PRECIOUS : %.t3x
|
||||
#---------------------------------------------------------------------------------
|
||||
%.t3x.o %_t3x.h : %.t3x
|
||||
#---------------------------------------------------------------------------------
|
||||
@echo $(notdir $<)
|
||||
@$(bin2o)
|
||||
|
||||
#---------------------------------------------------------------------------------
|
||||
# règles d'assemblage de shaders GPU
|
||||
#---------------------------------------------------------------------------------
|
||||
define shader-as
|
||||
$(eval CURBIN := $*.shbin)
|
||||
$(eval DEPSFILE := $(DEPSDIR)/$*.shbin.d)
|
||||
echo "$(CURBIN).o: $< $1" > $(DEPSFILE)
|
||||
echo "extern const u8" `(echo $(CURBIN) | sed -e 's/^\([0-9]\)/_\1/' | tr . _)`"_end[];" > `(echo $(CURBIN) | tr . _)`.h
|
||||
echo "extern const u8" `(echo $(CURBIN) | sed -e 's/^\([0-9]\)/_\1/' | tr . _)`"[];" >> `(echo $(CURBIN) | tr . _)`.h
|
||||
echo "extern const u32" `(echo $(CURBIN) | sed -e 's/^\([0-9]\)/_\1/' | tr . _)`_size";" >> `(echo $(CURBIN) | tr . _)`.h
|
||||
picasso -o $(CURBIN) $1
|
||||
bin2s $(CURBIN) | $(AS) -o $*.shbin.o
|
||||
endef
|
||||
|
||||
%.shbin.o %_shbin.h : %.v.pica %.g.pica
|
||||
@echo $(notdir $^)
|
||||
@$(call shader-as,$^)
|
||||
|
||||
%.shbin.o %_shbin.h : %.v.pica
|
||||
@echo $(notdir $<)
|
||||
@$(call shader-as,$<)
|
||||
|
||||
%.shbin.o %_shbin.h : %.shlist
|
||||
@echo $(notdir $<)
|
||||
@$(call shader-as,$(foreach file,$(shell cat $<),$(dir $<)$(file)))
|
||||
|
||||
#---------------------------------------------------------------------------------
|
||||
%.t3x %.h : %.t3s
|
||||
#---------------------------------------------------------------------------------
|
||||
@echo $(notdir $<)
|
||||
@tex3ds -i $< -H $*.h -d $*.d -o $*.t3x
|
||||
|
||||
-include $(DEPSDIR)/*.d
|
||||
|
||||
#---------------------------------------------------------------------------------------
|
||||
endif
|
||||
#---------------------------------------------------------------------------------------
|
||||
|
||||
Vendored
+4
-4
@@ -1,5 +1,5 @@
|
||||
{
|
||||
"files.associations": {
|
||||
"string": "cpp"
|
||||
}
|
||||
{
|
||||
"files.associations": {
|
||||
"string": "cpp"
|
||||
}
|
||||
}
|
||||
+674
-674
File diff suppressed because it is too large
Load Diff
@@ -1,9 +1,9 @@
|
||||
# Universal-Core by Universal-Team
|
||||
This contains the GUI & Core part for our 3DS Applications.
|
||||
|
||||
Logo created by: [TotallyNotGuy](https://github.com/TotallyNotGuy).
|
||||
|
||||

|
||||
|
||||
Licensing:
|
||||
# Universal-Core by Universal-Team
|
||||
This contains the GUI & Core part for our 3DS Applications.
|
||||
|
||||
Logo created by: [TotallyNotGuy](https://github.com/TotallyNotGuy).
|
||||
|
||||

|
||||
|
||||
Licensing:
|
||||
This software is licensed under the terms of the GPLv3. You can find a copy of the license in the LICENSE file.
|
||||
+500
-500
File diff suppressed because it is too large
Load Diff
+245
-245
@@ -1,246 +1,246 @@
|
||||
/*
|
||||
* This file is part of Universal-Core
|
||||
* Copyright (C) 2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#ifndef _UNIVERSAL_CORE_GUI_HPP
|
||||
#define _UNIVERSAL_CORE_GUI_HPP
|
||||
|
||||
#include "screen.hpp"
|
||||
|
||||
#include <3ds.h>
|
||||
#include <citro2d.h>
|
||||
#include <citro3d.h>
|
||||
|
||||
namespace Gui {
|
||||
/*
|
||||
Clear the Text Buffer.
|
||||
*/
|
||||
void clearTextBufs(void);
|
||||
|
||||
/*
|
||||
Draw a sprite from a SpriteSheet.
|
||||
sheet: The SpriteSheet which should be used.
|
||||
imgIndex: The index of the sprite from the sheet which should be drawn.
|
||||
x: The X Position where the sprite should be drawn.
|
||||
y: The Y Position where the sprite should be drawn.
|
||||
ScaleX: The X-Scale for the sprite. (Optional!)
|
||||
ScaleY: The Y-Scale for the sprite. (Optional!)
|
||||
*/
|
||||
void DrawSprite(C2D_SpriteSheet sheet, size_t imgindex, int x, int y, float ScaleX = 1, float ScaleY = 1);
|
||||
|
||||
/*
|
||||
Initialize the GUI with Citro2D & Citro3D and initialize the Textbuffer.
|
||||
call this when initializing.
|
||||
*/
|
||||
Result init(void);
|
||||
|
||||
/*
|
||||
Load a Font. (BCFNT)
|
||||
|
||||
fnt: The C2D_Font variable which should be initialized.
|
||||
Path: Path to the BCFNT file.
|
||||
if you're unsure, just call 'Gui::init();' and it will load the system font.
|
||||
*/
|
||||
Result loadFont(C2D_Font &fnt, const char *Path = "");
|
||||
|
||||
/*
|
||||
Unload a Font. (BCFNT)
|
||||
|
||||
fnt: The C2D_Font variable which should be unloaded.
|
||||
*/
|
||||
Result unloadFont(C2D_Font &fnt);
|
||||
|
||||
/*
|
||||
Load a spritesheet.
|
||||
|
||||
Path: Path to the SpriteSheet file. (T3X)
|
||||
sheet: Reference to the C2D_SpriteSheet declaration.
|
||||
*/
|
||||
Result loadSheet(const char *Path, C2D_SpriteSheet &sheet);
|
||||
|
||||
/*
|
||||
Unload a spritesheet.
|
||||
|
||||
sheet: Reference to the C2D_SpriteSheet which should be free'd.
|
||||
*/
|
||||
Result unloadSheet(C2D_SpriteSheet &sheet);
|
||||
|
||||
/*
|
||||
Exit the GUI.
|
||||
Call this at exit.
|
||||
*/
|
||||
void exit(void);
|
||||
|
||||
/*
|
||||
Reinit the GUI.
|
||||
*/
|
||||
Result reinit(void);
|
||||
|
||||
/*
|
||||
Draws a centered String.
|
||||
x: The X Offset from center. (Center: 200 px on top, 160 px on Bottom.)
|
||||
y: The Y Position of the Text.
|
||||
size: The size of the Text.
|
||||
color: The Color of the Text.
|
||||
Text: The Text which should be displayed.
|
||||
maxWidth: The maxWidth for the Text. (Optional!)
|
||||
maxHeight: The maxHeight of the Text. (Optional!)
|
||||
fnt: The Font which should be used. Uses SystemFont by default. (Optional!)
|
||||
int flags: C2D text flags to use. (Optional!)
|
||||
*/
|
||||
void DrawStringCentered(float x, float y, float size, u32 color, std::string Text, int maxWidth = 0, int maxHeight = 0, C2D_Font fnt = nullptr, int flags = 0);
|
||||
|
||||
/*
|
||||
Draws a String.
|
||||
|
||||
x: The X Position where the Text should be drawn.
|
||||
y: The Y Position where the Text should be drawn.
|
||||
size: The size of the Text.
|
||||
color: The Color of the Text.
|
||||
Text: The Text which should be displayed.
|
||||
maxWidth: The maxWidth for the Text. (Optional!)
|
||||
maxHeight: The maxHeight of the Text. (Optional!)
|
||||
fnt: The Font which should be used. Uses SystemFont by default. (Optional!)
|
||||
flags: C2D text flags to use.
|
||||
*/
|
||||
void DrawString(float x, float y, float size, u32 color, std::string Text, int maxWidth = 0, int maxHeight = 0, C2D_Font fnt = nullptr, int flags = 0);
|
||||
|
||||
/*
|
||||
Get the width of a String.
|
||||
|
||||
size: The size of the Text.
|
||||
Text: The Text where the width should be getted from.
|
||||
fnt: The Font which should be used. Uses SystemFont by default. (Optional!)
|
||||
*/
|
||||
float GetStringWidth(float size, std::string Text, C2D_Font fnt = nullptr);
|
||||
|
||||
/*
|
||||
Get the size of a String.
|
||||
|
||||
size: The size of the Text.
|
||||
width: The width of the Text.
|
||||
height: The height of the Text.
|
||||
Text: The Text where the size should be getted from.
|
||||
fnt: The Font which should be used. Uses SystemFont by default. (Optional!)
|
||||
*/
|
||||
void GetStringSize(float size, float *width, float *height, std::string Text, C2D_Font fnt = nullptr);
|
||||
|
||||
/*
|
||||
Get the height of a String.
|
||||
|
||||
size: The size of the Text.
|
||||
Text: The Text where the height should be getted from.
|
||||
fnt: The Font which should be used. Uses SystemFont by default. (Optional!)
|
||||
*/
|
||||
float GetStringHeight(float size, std::string Text, C2D_Font fnt = nullptr);
|
||||
|
||||
/*
|
||||
Draw a Rectangle.
|
||||
|
||||
x: X Position of the Rectangle.
|
||||
y: Y Position of the Rectangle.
|
||||
w: The width of the rectangle.
|
||||
h: The height of the rectangle.
|
||||
color: The color of the rectangle.
|
||||
*/
|
||||
bool Draw_Rect(float x, float y, float w, float h, u32 color);
|
||||
|
||||
/*
|
||||
Used for the current Screen's Draw. (Optional!)
|
||||
stack: Is it the stack variant?
|
||||
*/
|
||||
void DrawScreen(bool stack = false);
|
||||
|
||||
/*
|
||||
Used for the current Screen's Logic. (Optional!)
|
||||
|
||||
hDown: the hidKeysDown() variable.
|
||||
hHeld: the HidKeysHeld() variable.
|
||||
touch: The TouchPosition variable.
|
||||
waitFade: Wheter to wait until the fade ends.
|
||||
stack: Is it the stack variant?
|
||||
*/
|
||||
void ScreenLogic(u32 hDown, u32 hHeld, touchPosition touch, bool waitFade = true, bool stack = false);
|
||||
|
||||
/*
|
||||
Transfer the Temp Screen to the used one. (Optional!)
|
||||
|
||||
stack: Is it the stack variant?
|
||||
It will check, if the tempScreen variable is not nullptr, so don't worry.
|
||||
*/
|
||||
void transferScreen(bool stack = false);
|
||||
|
||||
/*
|
||||
Set a specific Screen with switch function. (Optional!)
|
||||
|
||||
screen: unique_ptr of the screen. (Optional by using the screen class.)
|
||||
screenSwitch: Wheter to switch to the current screen.
|
||||
stack: Is it the stack variant?
|
||||
*/
|
||||
void setScreen(std::unique_ptr<Screen> screen, bool fade = false, bool stack = false);
|
||||
|
||||
/*
|
||||
Fades into screens and calls the constructor after it. (Optional!)
|
||||
fadeoutFrames: Amount of frames for fadeout.
|
||||
fadeinFrames: Amount of frames for fadein.
|
||||
stack: Is it the stack variant?
|
||||
*/
|
||||
void fadeEffects(int fadeoutFrames = 6, int fadeinFrames = 6, bool stack = false);
|
||||
|
||||
void screenBack(bool fade = false); // Goes a screen back. (Set!) (Stack only!)
|
||||
void screenBack2(); // Goes a screen back.(Action!) (Stack only!)
|
||||
|
||||
/*
|
||||
Set on which screen to draw.
|
||||
|
||||
screen: The render target. (Targets are inside the screenCommon.hpp file.)
|
||||
*/
|
||||
void ScreenDraw(C3D_RenderTarget * screen);
|
||||
|
||||
/*
|
||||
Draws a grid.
|
||||
xPos: X Position of the grid.
|
||||
yPos: Y Position of the grid.
|
||||
Width: Width of the grid.
|
||||
Height: Height of the grid.
|
||||
color: Color of the grid.
|
||||
bgColor: The BG Color from the grid. (Optional! It's transparent by default.)
|
||||
*/
|
||||
void drawGrid(float xPos, float yPos, float Width, float Height, u32 color, u32 bgColor = C2D_Color32(0, 0, 0, 0));
|
||||
|
||||
/*
|
||||
Draws an animated selector.
|
||||
xPos: X Position of the selector.
|
||||
yPos: Y Position of the Selector.
|
||||
Width: Width of the Selector.
|
||||
Height: Height of the Selector.
|
||||
speed: The speed of the animation. (Use .030f or something by default.)
|
||||
SelectorColor: The Color of the Selector outline.
|
||||
bgColor: The BG Color from the selector. (Optional! It's transparent by default.)
|
||||
*/
|
||||
void drawAnimatedSelector(float xPos, float yPos, float Width, float Height, float speed, u32 SelectorColor, u32 bgColor = C2D_Color32(0, 0, 0, 0));
|
||||
};
|
||||
|
||||
/*
|
||||
* This file is part of Universal-Core
|
||||
* Copyright (C) 2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#ifndef _UNIVERSAL_CORE_GUI_HPP
|
||||
#define _UNIVERSAL_CORE_GUI_HPP
|
||||
|
||||
#include "screen.hpp"
|
||||
|
||||
#include <3ds.h>
|
||||
#include <citro2d.h>
|
||||
#include <citro3d.h>
|
||||
|
||||
namespace Gui {
|
||||
/*
|
||||
Clear the Text Buffer.
|
||||
*/
|
||||
void clearTextBufs(void);
|
||||
|
||||
/*
|
||||
Draw a sprite from a SpriteSheet.
|
||||
sheet: The SpriteSheet which should be used.
|
||||
imgIndex: The index of the sprite from the sheet which should be drawn.
|
||||
x: The X Position where the sprite should be drawn.
|
||||
y: The Y Position where the sprite should be drawn.
|
||||
ScaleX: The X-Scale for the sprite. (Optional!)
|
||||
ScaleY: The Y-Scale for the sprite. (Optional!)
|
||||
*/
|
||||
void DrawSprite(C2D_SpriteSheet sheet, size_t imgindex, int x, int y, float ScaleX = 1, float ScaleY = 1);
|
||||
|
||||
/*
|
||||
Initialize the GUI with Citro2D & Citro3D and initialize the Textbuffer.
|
||||
call this when initializing.
|
||||
*/
|
||||
Result init(void);
|
||||
|
||||
/*
|
||||
Load a Font. (BCFNT)
|
||||
|
||||
fnt: The C2D_Font variable which should be initialized.
|
||||
Path: Path to the BCFNT file.
|
||||
if you're unsure, just call 'Gui::init();' and it will load the system font.
|
||||
*/
|
||||
Result loadFont(C2D_Font &fnt, const char *Path = "");
|
||||
|
||||
/*
|
||||
Unload a Font. (BCFNT)
|
||||
|
||||
fnt: The C2D_Font variable which should be unloaded.
|
||||
*/
|
||||
Result unloadFont(C2D_Font &fnt);
|
||||
|
||||
/*
|
||||
Load a spritesheet.
|
||||
|
||||
Path: Path to the SpriteSheet file. (T3X)
|
||||
sheet: Reference to the C2D_SpriteSheet declaration.
|
||||
*/
|
||||
Result loadSheet(const char *Path, C2D_SpriteSheet &sheet);
|
||||
|
||||
/*
|
||||
Unload a spritesheet.
|
||||
|
||||
sheet: Reference to the C2D_SpriteSheet which should be free'd.
|
||||
*/
|
||||
Result unloadSheet(C2D_SpriteSheet &sheet);
|
||||
|
||||
/*
|
||||
Exit the GUI.
|
||||
Call this at exit.
|
||||
*/
|
||||
void exit(void);
|
||||
|
||||
/*
|
||||
Reinit the GUI.
|
||||
*/
|
||||
Result reinit(void);
|
||||
|
||||
/*
|
||||
Draws a centered String.
|
||||
x: The X Offset from center. (Center: 200 px on top, 160 px on Bottom.)
|
||||
y: The Y Position of the Text.
|
||||
size: The size of the Text.
|
||||
color: The Color of the Text.
|
||||
Text: The Text which should be displayed.
|
||||
maxWidth: The maxWidth for the Text. (Optional!)
|
||||
maxHeight: The maxHeight of the Text. (Optional!)
|
||||
fnt: The Font which should be used. Uses SystemFont by default. (Optional!)
|
||||
int flags: C2D text flags to use. (Optional!)
|
||||
*/
|
||||
void DrawStringCentered(float x, float y, float size, u32 color, std::string Text, int maxWidth = 0, int maxHeight = 0, C2D_Font fnt = nullptr, int flags = 0);
|
||||
|
||||
/*
|
||||
Draws a String.
|
||||
|
||||
x: The X Position where the Text should be drawn.
|
||||
y: The Y Position where the Text should be drawn.
|
||||
size: The size of the Text.
|
||||
color: The Color of the Text.
|
||||
Text: The Text which should be displayed.
|
||||
maxWidth: The maxWidth for the Text. (Optional!)
|
||||
maxHeight: The maxHeight of the Text. (Optional!)
|
||||
fnt: The Font which should be used. Uses SystemFont by default. (Optional!)
|
||||
flags: C2D text flags to use.
|
||||
*/
|
||||
void DrawString(float x, float y, float size, u32 color, std::string Text, int maxWidth = 0, int maxHeight = 0, C2D_Font fnt = nullptr, int flags = 0);
|
||||
|
||||
/*
|
||||
Get the width of a String.
|
||||
|
||||
size: The size of the Text.
|
||||
Text: The Text where the width should be getted from.
|
||||
fnt: The Font which should be used. Uses SystemFont by default. (Optional!)
|
||||
*/
|
||||
float GetStringWidth(float size, std::string Text, C2D_Font fnt = nullptr);
|
||||
|
||||
/*
|
||||
Get the size of a String.
|
||||
|
||||
size: The size of the Text.
|
||||
width: The width of the Text.
|
||||
height: The height of the Text.
|
||||
Text: The Text where the size should be getted from.
|
||||
fnt: The Font which should be used. Uses SystemFont by default. (Optional!)
|
||||
*/
|
||||
void GetStringSize(float size, float *width, float *height, std::string Text, C2D_Font fnt = nullptr);
|
||||
|
||||
/*
|
||||
Get the height of a String.
|
||||
|
||||
size: The size of the Text.
|
||||
Text: The Text where the height should be getted from.
|
||||
fnt: The Font which should be used. Uses SystemFont by default. (Optional!)
|
||||
*/
|
||||
float GetStringHeight(float size, std::string Text, C2D_Font fnt = nullptr);
|
||||
|
||||
/*
|
||||
Draw a Rectangle.
|
||||
|
||||
x: X Position of the Rectangle.
|
||||
y: Y Position of the Rectangle.
|
||||
w: The width of the rectangle.
|
||||
h: The height of the rectangle.
|
||||
color: The color of the rectangle.
|
||||
*/
|
||||
bool Draw_Rect(float x, float y, float w, float h, u32 color);
|
||||
|
||||
/*
|
||||
Used for the current Screen's Draw. (Optional!)
|
||||
stack: Is it the stack variant?
|
||||
*/
|
||||
void DrawScreen(bool stack = false);
|
||||
|
||||
/*
|
||||
Used for the current Screen's Logic. (Optional!)
|
||||
|
||||
hDown: the hidKeysDown() variable.
|
||||
hHeld: the HidKeysHeld() variable.
|
||||
touch: The TouchPosition variable.
|
||||
waitFade: Wheter to wait until the fade ends.
|
||||
stack: Is it the stack variant?
|
||||
*/
|
||||
void ScreenLogic(u32 hDown, u32 hHeld, touchPosition touch, bool waitFade = true, bool stack = false);
|
||||
|
||||
/*
|
||||
Transfer the Temp Screen to the used one. (Optional!)
|
||||
|
||||
stack: Is it the stack variant?
|
||||
It will check, if the tempScreen variable is not nullptr, so don't worry.
|
||||
*/
|
||||
void transferScreen(bool stack = false);
|
||||
|
||||
/*
|
||||
Set a specific Screen with switch function. (Optional!)
|
||||
|
||||
screen: unique_ptr of the screen. (Optional by using the screen class.)
|
||||
screenSwitch: Wheter to switch to the current screen.
|
||||
stack: Is it the stack variant?
|
||||
*/
|
||||
void setScreen(std::unique_ptr<Screen> screen, bool fade = false, bool stack = false);
|
||||
|
||||
/*
|
||||
Fades into screens and calls the constructor after it. (Optional!)
|
||||
fadeoutFrames: Amount of frames for fadeout.
|
||||
fadeinFrames: Amount of frames for fadein.
|
||||
stack: Is it the stack variant?
|
||||
*/
|
||||
void fadeEffects(int fadeoutFrames = 6, int fadeinFrames = 6, bool stack = false);
|
||||
|
||||
void screenBack(bool fade = false); // Goes a screen back. (Set!) (Stack only!)
|
||||
void screenBack2(); // Goes a screen back.(Action!) (Stack only!)
|
||||
|
||||
/*
|
||||
Set on which screen to draw.
|
||||
|
||||
screen: The render target. (Targets are inside the screenCommon.hpp file.)
|
||||
*/
|
||||
void ScreenDraw(C3D_RenderTarget * screen);
|
||||
|
||||
/*
|
||||
Draws a grid.
|
||||
xPos: X Position of the grid.
|
||||
yPos: Y Position of the grid.
|
||||
Width: Width of the grid.
|
||||
Height: Height of the grid.
|
||||
color: Color of the grid.
|
||||
bgColor: The BG Color from the grid. (Optional! It's transparent by default.)
|
||||
*/
|
||||
void drawGrid(float xPos, float yPos, float Width, float Height, u32 color, u32 bgColor = C2D_Color32(0, 0, 0, 0));
|
||||
|
||||
/*
|
||||
Draws an animated selector.
|
||||
xPos: X Position of the selector.
|
||||
yPos: Y Position of the Selector.
|
||||
Width: Width of the Selector.
|
||||
Height: Height of the Selector.
|
||||
speed: The speed of the animation. (Use .030f or something by default.)
|
||||
SelectorColor: The Color of the Selector outline.
|
||||
bgColor: The BG Color from the selector. (Optional! It's transparent by default.)
|
||||
*/
|
||||
void drawAnimatedSelector(float xPos, float yPos, float Width, float Height, float speed, u32 SelectorColor, u32 bgColor = C2D_Color32(0, 0, 0, 0));
|
||||
};
|
||||
|
||||
#endif
|
||||
+39
-39
@@ -1,40 +1,40 @@
|
||||
/*
|
||||
* This file is part of Universal-Core
|
||||
* Copyright (C) 2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#ifndef _UNIVERSAL_CORE_SCREEN_HPP
|
||||
#define _UNIVERSAL_CORE_SCREEN_HPP
|
||||
|
||||
#include <3ds.h>
|
||||
#include <memory>
|
||||
|
||||
class Screen {
|
||||
public:
|
||||
virtual ~Screen() {}
|
||||
virtual void Logic(u32 hDown, u32 hHeld, touchPosition touch) = 0;
|
||||
virtual void Draw() const = 0;
|
||||
};
|
||||
|
||||
/*
|
||||
* This file is part of Universal-Core
|
||||
* Copyright (C) 2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#ifndef _UNIVERSAL_CORE_SCREEN_HPP
|
||||
#define _UNIVERSAL_CORE_SCREEN_HPP
|
||||
|
||||
#include <3ds.h>
|
||||
#include <memory>
|
||||
|
||||
class Screen {
|
||||
public:
|
||||
virtual ~Screen() {}
|
||||
virtual void Logic(u32 hDown, u32 hHeld, touchPosition touch) = 0;
|
||||
virtual void Draw() const = 0;
|
||||
};
|
||||
|
||||
#endif
|
||||
@@ -1,37 +1,37 @@
|
||||
/*
|
||||
* This file is part of Universal-Core
|
||||
* Copyright (C) 2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#ifndef _UNIVERSAL_CORE_SCREENCOMMON_HPP
|
||||
#define _UNIVERSAL_CORE_SCREENCOMMON_HPP
|
||||
|
||||
#include "gui.hpp"
|
||||
#include "structs.hpp"
|
||||
|
||||
extern C3D_RenderTarget *Top, *TopRight, *Bottom;
|
||||
extern bool fadeout, fadein, fadeout2, fadein2;
|
||||
extern int fadealpha, fadecolor;
|
||||
|
||||
/*
|
||||
* This file is part of Universal-Core
|
||||
* Copyright (C) 2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#ifndef _UNIVERSAL_CORE_SCREENCOMMON_HPP
|
||||
#define _UNIVERSAL_CORE_SCREENCOMMON_HPP
|
||||
|
||||
#include "gui.hpp"
|
||||
#include "structs.hpp"
|
||||
|
||||
extern C3D_RenderTarget *Top, *TopRight, *Bottom;
|
||||
extern bool fadeout, fadein, fadeout2, fadein2;
|
||||
extern int fadealpha, fadecolor;
|
||||
|
||||
#endif
|
||||
+48
-48
@@ -1,49 +1,49 @@
|
||||
/*
|
||||
* This file is part of Universal-Core
|
||||
* Copyright (C) 2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#ifndef _UNIVERSAL_CORE_STRUCTS_HPP
|
||||
#define _UNIVERSAL_CORE_STRUCTS_HPP
|
||||
|
||||
#include <string>
|
||||
|
||||
class Structs {
|
||||
public:
|
||||
struct ButtonPos {
|
||||
int x;
|
||||
int y;
|
||||
int w;
|
||||
int h;
|
||||
};
|
||||
|
||||
struct Key {
|
||||
std::string character;
|
||||
int x;
|
||||
int y;
|
||||
int w;
|
||||
};
|
||||
};
|
||||
|
||||
/*
|
||||
* This file is part of Universal-Core
|
||||
* Copyright (C) 2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#ifndef _UNIVERSAL_CORE_STRUCTS_HPP
|
||||
#define _UNIVERSAL_CORE_STRUCTS_HPP
|
||||
|
||||
#include <string>
|
||||
|
||||
class Structs {
|
||||
public:
|
||||
struct ButtonPos {
|
||||
int x;
|
||||
int y;
|
||||
int w;
|
||||
int h;
|
||||
};
|
||||
|
||||
struct Key {
|
||||
std::string character;
|
||||
int x;
|
||||
int y;
|
||||
int w;
|
||||
};
|
||||
};
|
||||
|
||||
#endif
|
||||
+285
-285
@@ -1,285 +1,285 @@
|
||||
BasicInfo:
|
||||
Title : "DarkStore"
|
||||
ProductCode : "CTR-H-DARK"
|
||||
Logo : Homebrew # Nintendo / Licensed / Distributed / iQue / iQueForSystem
|
||||
|
||||
RomFs:
|
||||
RootPath: "../romfs"
|
||||
|
||||
TitleInfo:
|
||||
Category : Application
|
||||
UniqueId : 0x42042
|
||||
|
||||
Option:
|
||||
UseOnSD : true # true si l'application doit être installée sur SD
|
||||
FreeProductCode : true # Supprime les limitations sur ProductCode
|
||||
MediaFootPadding : false # Si de vrais fichiers CCI sont créés avec un remplissage
|
||||
EnableCrypt : false # Active le cryptage pour NCCH et CIA
|
||||
EnableCompress : true # Compresse le cas échéant (actuellement uniquement exefs: /. Code)
|
||||
|
||||
AccessControlInfo:
|
||||
CoreVersion : 2
|
||||
|
||||
# Version du format Exheader
|
||||
DescVersion : 2
|
||||
|
||||
# Version minimale requise du noyau (ci-dessous est pour 4.5.0)
|
||||
ReleaseKernelMajor : "02"
|
||||
ReleaseKernelMinor : "33"
|
||||
|
||||
# ExtData
|
||||
UseExtSaveData : false # active ExtData
|
||||
#ExtSaveDataId : 0x300 # définissez ceci uniquement lorsque l'ID est différent de UniqueId
|
||||
|
||||
# FS: autorisations d'accès aux archives USER
|
||||
# Décommenter si nécessaire
|
||||
FileSystemAccess:
|
||||
- CategorySystemApplication
|
||||
- CategoryHardwareCheck
|
||||
- CategoryFileSystemTool
|
||||
- Debug
|
||||
- TwlCardBackup
|
||||
- TwlNandData
|
||||
#- Boss
|
||||
- DirectSdmc
|
||||
- Core
|
||||
#- CtrNandRo
|
||||
#- CtrNandRw
|
||||
#- CtrNandRoWrite
|
||||
- CategorySystemSettings
|
||||
#- CardBoard
|
||||
#- ExportImportIvs
|
||||
- DirectSdmcWrite
|
||||
#- SwitchCleanup
|
||||
#- SaveDataMove
|
||||
#- Shop
|
||||
#- Shell
|
||||
#- CategoryHomeMenu
|
||||
#- SeedDB
|
||||
IoAccessControl:
|
||||
#- FsMountNand
|
||||
#- FsMountNandRoWrite
|
||||
- FsMountTwln
|
||||
#- FsMountWnand
|
||||
- FsMountCardSpi
|
||||
- UseSdif3
|
||||
#- CreateSeed
|
||||
- UseCardSpi
|
||||
|
||||
# Paramètres de processus
|
||||
MemoryType : Application # Application/System/Base
|
||||
SystemMode : 64MB # 64MB(Defaut)/96MB/80MB/72MB/32MB
|
||||
IdealProcessor : 0
|
||||
AffinityMask : 1
|
||||
Priority : 16
|
||||
MaxCpu : 0x9E # Defaut
|
||||
HandleTableSize : 0x200
|
||||
DisableDebug : false
|
||||
EnableForceDebug : false
|
||||
CanWriteSharedPage : true
|
||||
CanUsePrivilegedPriority : false
|
||||
CanUseNonAlphabetAndNumber : true
|
||||
PermitMainFunctionArgument : true
|
||||
CanShareDeviceMemory : true
|
||||
RunnableOnSleep : false
|
||||
SpecialMemoryArrange : true
|
||||
|
||||
# Paramètres de processus exclusifs New3DS
|
||||
SystemModeExt : Legacy # Legacy (par défaut) / 124 Mo / 178 Mo Legacy: utilisez le mode système Old3DS
|
||||
CpuSpeed : 804MHz # 268MHz(Defaut)/804MHz
|
||||
EnableL2Cache : true # false (par défaut) / true
|
||||
CanAccessCore2 : true
|
||||
|
||||
# Correspondances d’adresses virtuelles
|
||||
IORegisterMapping:
|
||||
- 1ff00000-1ff7ffff # DSP memory
|
||||
MemoryMapping:
|
||||
- 1f000000-1f5fffff:r # VRAM
|
||||
|
||||
# SVC accessibles, <Name>:<ID>
|
||||
SystemCallAccess:
|
||||
ControlMemory: 1
|
||||
QueryMemory: 2
|
||||
ExitProcess: 3
|
||||
GetProcessAffinityMask: 4
|
||||
SetProcessAffinityMask: 5
|
||||
GetProcessIdealProcessor: 6
|
||||
SetProcessIdealProcessor: 7
|
||||
CreateThread: 8
|
||||
ExitThread: 9
|
||||
SleepThread: 10
|
||||
GetThreadPriority: 11
|
||||
SetThreadPriority: 12
|
||||
GetThreadAffinityMask: 13
|
||||
SetThreadAffinityMask: 14
|
||||
GetThreadIdealProcessor: 15
|
||||
SetThreadIdealProcessor: 16
|
||||
GetCurrentProcessorNumber: 17
|
||||
Run: 18
|
||||
CreateMutex: 19
|
||||
ReleaseMutex: 20
|
||||
CreateSemaphore: 21
|
||||
ReleaseSemaphore: 22
|
||||
CreateEvent: 23
|
||||
SignalEvent: 24
|
||||
ClearEvent: 25
|
||||
CreateTimer: 26
|
||||
SetTimer: 27
|
||||
CancelTimer: 28
|
||||
ClearTimer: 29
|
||||
CreateMemoryBlock: 30
|
||||
MapMemoryBlock: 31
|
||||
UnmapMemoryBlock: 32
|
||||
CreateAddressArbiter: 33
|
||||
ArbitrateAddress: 34
|
||||
CloseHandle: 35
|
||||
WaitSynchronization1: 36
|
||||
WaitSynchronizationN: 37
|
||||
SignalAndWait: 38
|
||||
DuplicateHandle: 39
|
||||
GetSystemTick: 40
|
||||
GetHandleInfo: 41
|
||||
GetSystemInfo: 42
|
||||
GetProcessInfo: 43
|
||||
GetThreadInfo: 44
|
||||
ConnectToPort: 45
|
||||
SendSyncRequest1: 46
|
||||
SendSyncRequest2: 47
|
||||
SendSyncRequest3: 48
|
||||
SendSyncRequest4: 49
|
||||
SendSyncRequest: 50
|
||||
OpenProcess: 51
|
||||
OpenThread: 52
|
||||
GetProcessId: 53
|
||||
GetProcessIdOfThread: 54
|
||||
GetThreadId: 55
|
||||
GetResourceLimit: 56
|
||||
GetResourceLimitLimitValues: 57
|
||||
GetResourceLimitCurrentValues: 58
|
||||
GetThreadContext: 59
|
||||
Break: 60
|
||||
OutputDebugString: 61
|
||||
ControlPerformanceCounter: 62
|
||||
CreatePort: 71
|
||||
CreateSessionToPort: 72
|
||||
CreateSession: 73
|
||||
AcceptSession: 74
|
||||
ReplyAndReceive1: 75
|
||||
ReplyAndReceive2: 76
|
||||
ReplyAndReceive3: 77
|
||||
ReplyAndReceive4: 78
|
||||
ReplyAndReceive: 79
|
||||
BindInterrupt: 80
|
||||
UnbindInterrupt: 81
|
||||
InvalidateProcessDataCache: 82
|
||||
StoreProcessDataCache: 83
|
||||
FlushProcessDataCache: 84
|
||||
StartInterProcessDma: 85
|
||||
StopDma: 86
|
||||
GetDmaState: 87
|
||||
RestartDma: 88
|
||||
DebugActiveProcess: 96
|
||||
BreakDebugProcess: 97
|
||||
TerminateDebugProcess: 98
|
||||
GetProcessDebugEvent: 99
|
||||
ContinueDebugEvent: 100
|
||||
GetProcessList: 101
|
||||
GetThreadList: 102
|
||||
GetDebugThreadContext: 103
|
||||
SetDebugThreadContext: 104
|
||||
QueryDebugProcessMemory: 105
|
||||
ReadProcessMemory: 106
|
||||
WriteProcessMemory: 107
|
||||
SetHardwareBreakPoint: 108
|
||||
GetDebugThreadParam: 109
|
||||
ControlProcessMemory: 112
|
||||
MapProcessMemory: 113
|
||||
UnmapProcessMemory: 114
|
||||
CreateCodeSet: 115
|
||||
CreateProcess: 117
|
||||
TerminateProcess: 118
|
||||
SetProcessResourceLimits: 119
|
||||
CreateResourceLimit: 120
|
||||
SetResourceLimitValues: 121
|
||||
AddCodeSegment: 122
|
||||
Backdoor: 123
|
||||
KernelSetState: 124
|
||||
QueryProcessMemory: 125
|
||||
|
||||
# Liste des services
|
||||
# 34 services maximum (32 si le micrologiciel est antérieur à la version 9.6.0)
|
||||
ServiceAccessControl:
|
||||
- APT:U
|
||||
- ac:u
|
||||
- am:net
|
||||
#- boss:U
|
||||
#- cam:u
|
||||
#- cecd:u
|
||||
#- cfg:nor
|
||||
- cfg:u
|
||||
#- csnd:SND
|
||||
- dsp::DSP
|
||||
#- frd:u
|
||||
- fs:USER
|
||||
- gsp::Gpu
|
||||
- gsp::Lcd
|
||||
- hid:USER
|
||||
- http:C
|
||||
#- ir:rst
|
||||
#- ir:u
|
||||
#- ir:USER
|
||||
#- mic:u
|
||||
#- ndm:u
|
||||
#- news:s
|
||||
- nwm::EXT
|
||||
- nwm::UDS
|
||||
- ptm:sysm
|
||||
- ptm:u
|
||||
- pxi:dev
|
||||
- soc:U
|
||||
- ssl:C
|
||||
#- y2r:u
|
||||
|
||||
|
||||
SystemControlInfo:
|
||||
SaveDataSize: 0KB # Change if the app uses savedata
|
||||
RemasterVersion: $(APP_VERSION_MAJOR)
|
||||
StackSize: 0x40000
|
||||
|
||||
# Les modules qui exécutent les services énumérés ci-dessus doivent être inclus sous
|
||||
# 48 dépendances maximum
|
||||
# <module name>:<module titleid>
|
||||
Dependency:
|
||||
ac: 0x0004013000002402
|
||||
#act: 0x0004013000003802
|
||||
am: 0x0004013000001502
|
||||
boss: 0x0004013000003402
|
||||
camera: 0x0004013000001602
|
||||
cecd: 0x0004013000002602
|
||||
cfg: 0x0004013000001702
|
||||
codec: 0x0004013000001802
|
||||
csnd: 0x0004013000002702
|
||||
dlp: 0x0004013000002802
|
||||
dsp: 0x0004013000001a02
|
||||
friends: 0x0004013000003202
|
||||
gpio: 0x0004013000001b02
|
||||
gsp: 0x0004013000001c02
|
||||
hid: 0x0004013000001d02
|
||||
http: 0x0004013000002902
|
||||
i2c: 0x0004013000001e02
|
||||
ir: 0x0004013000003302
|
||||
mcu: 0x0004013000001f02
|
||||
mic: 0x0004013000002002
|
||||
ndm: 0x0004013000002b02
|
||||
news: 0x0004013000003502
|
||||
#nfc: 0x0004013000004002
|
||||
nim: 0x0004013000002c02
|
||||
nwm: 0x0004013000002d02
|
||||
pdn: 0x0004013000002102
|
||||
ps: 0x0004013000003102
|
||||
ptm: 0x0004013000002202
|
||||
#qtm: 0x0004013020004202
|
||||
ro: 0x0004013000003702
|
||||
socket: 0x0004013000002e02
|
||||
spi: 0x0004013000002302
|
||||
ssl: 0x0004013000002f02
|
||||
BasicInfo:
|
||||
Title : "DarkStore"
|
||||
ProductCode : "CTR-H-DARK"
|
||||
Logo : Homebrew # Nintendo / Licensed / Distributed / iQue / iQueForSystem
|
||||
|
||||
RomFs:
|
||||
RootPath: "../romfs"
|
||||
|
||||
TitleInfo:
|
||||
Category : Application
|
||||
UniqueId : 0x42042
|
||||
|
||||
Option:
|
||||
UseOnSD : true # true si l'application doit être installée sur SD
|
||||
FreeProductCode : true # Supprime les limitations sur ProductCode
|
||||
MediaFootPadding : false # Si de vrais fichiers CCI sont créés avec un remplissage
|
||||
EnableCrypt : false # Active le cryptage pour NCCH et CIA
|
||||
EnableCompress : true # Compresse le cas échéant (actuellement uniquement exefs: /. Code)
|
||||
|
||||
AccessControlInfo:
|
||||
CoreVersion : 2
|
||||
|
||||
# Version du format Exheader
|
||||
DescVersion : 2
|
||||
|
||||
# Version minimale requise du noyau (ci-dessous est pour 4.5.0)
|
||||
ReleaseKernelMajor : "02"
|
||||
ReleaseKernelMinor : "33"
|
||||
|
||||
# ExtData
|
||||
UseExtSaveData : false # active ExtData
|
||||
#ExtSaveDataId : 0x300 # définissez ceci uniquement lorsque l'ID est différent de UniqueId
|
||||
|
||||
# FS: autorisations d'accès aux archives USER
|
||||
# Décommenter si nécessaire
|
||||
FileSystemAccess:
|
||||
- CategorySystemApplication
|
||||
- CategoryHardwareCheck
|
||||
- CategoryFileSystemTool
|
||||
- Debug
|
||||
- TwlCardBackup
|
||||
- TwlNandData
|
||||
#- Boss
|
||||
- DirectSdmc
|
||||
- Core
|
||||
#- CtrNandRo
|
||||
#- CtrNandRw
|
||||
#- CtrNandRoWrite
|
||||
- CategorySystemSettings
|
||||
#- CardBoard
|
||||
#- ExportImportIvs
|
||||
- DirectSdmcWrite
|
||||
#- SwitchCleanup
|
||||
#- SaveDataMove
|
||||
#- Shop
|
||||
#- Shell
|
||||
#- CategoryHomeMenu
|
||||
#- SeedDB
|
||||
IoAccessControl:
|
||||
#- FsMountNand
|
||||
#- FsMountNandRoWrite
|
||||
- FsMountTwln
|
||||
#- FsMountWnand
|
||||
- FsMountCardSpi
|
||||
- UseSdif3
|
||||
#- CreateSeed
|
||||
- UseCardSpi
|
||||
|
||||
# Paramètres de processus
|
||||
MemoryType : Application # Application/System/Base
|
||||
SystemMode : 64MB # 64MB(Defaut)/96MB/80MB/72MB/32MB
|
||||
IdealProcessor : 0
|
||||
AffinityMask : 1
|
||||
Priority : 16
|
||||
MaxCpu : 0x9E # Defaut
|
||||
HandleTableSize : 0x200
|
||||
DisableDebug : false
|
||||
EnableForceDebug : false
|
||||
CanWriteSharedPage : true
|
||||
CanUsePrivilegedPriority : false
|
||||
CanUseNonAlphabetAndNumber : true
|
||||
PermitMainFunctionArgument : true
|
||||
CanShareDeviceMemory : true
|
||||
RunnableOnSleep : false
|
||||
SpecialMemoryArrange : true
|
||||
|
||||
# Paramètres de processus exclusifs New3DS
|
||||
SystemModeExt : Legacy # Legacy (par défaut) / 124 Mo / 178 Mo Legacy: utilisez le mode système Old3DS
|
||||
CpuSpeed : 804MHz # 268MHz(Defaut)/804MHz
|
||||
EnableL2Cache : true # false (par défaut) / true
|
||||
CanAccessCore2 : true
|
||||
|
||||
# Correspondances d’adresses virtuelles
|
||||
IORegisterMapping:
|
||||
- 1ff00000-1ff7ffff # DSP memory
|
||||
MemoryMapping:
|
||||
- 1f000000-1f5fffff:r # VRAM
|
||||
|
||||
# SVC accessibles, <Name>:<ID>
|
||||
SystemCallAccess:
|
||||
ControlMemory: 1
|
||||
QueryMemory: 2
|
||||
ExitProcess: 3
|
||||
GetProcessAffinityMask: 4
|
||||
SetProcessAffinityMask: 5
|
||||
GetProcessIdealProcessor: 6
|
||||
SetProcessIdealProcessor: 7
|
||||
CreateThread: 8
|
||||
ExitThread: 9
|
||||
SleepThread: 10
|
||||
GetThreadPriority: 11
|
||||
SetThreadPriority: 12
|
||||
GetThreadAffinityMask: 13
|
||||
SetThreadAffinityMask: 14
|
||||
GetThreadIdealProcessor: 15
|
||||
SetThreadIdealProcessor: 16
|
||||
GetCurrentProcessorNumber: 17
|
||||
Run: 18
|
||||
CreateMutex: 19
|
||||
ReleaseMutex: 20
|
||||
CreateSemaphore: 21
|
||||
ReleaseSemaphore: 22
|
||||
CreateEvent: 23
|
||||
SignalEvent: 24
|
||||
ClearEvent: 25
|
||||
CreateTimer: 26
|
||||
SetTimer: 27
|
||||
CancelTimer: 28
|
||||
ClearTimer: 29
|
||||
CreateMemoryBlock: 30
|
||||
MapMemoryBlock: 31
|
||||
UnmapMemoryBlock: 32
|
||||
CreateAddressArbiter: 33
|
||||
ArbitrateAddress: 34
|
||||
CloseHandle: 35
|
||||
WaitSynchronization1: 36
|
||||
WaitSynchronizationN: 37
|
||||
SignalAndWait: 38
|
||||
DuplicateHandle: 39
|
||||
GetSystemTick: 40
|
||||
GetHandleInfo: 41
|
||||
GetSystemInfo: 42
|
||||
GetProcessInfo: 43
|
||||
GetThreadInfo: 44
|
||||
ConnectToPort: 45
|
||||
SendSyncRequest1: 46
|
||||
SendSyncRequest2: 47
|
||||
SendSyncRequest3: 48
|
||||
SendSyncRequest4: 49
|
||||
SendSyncRequest: 50
|
||||
OpenProcess: 51
|
||||
OpenThread: 52
|
||||
GetProcessId: 53
|
||||
GetProcessIdOfThread: 54
|
||||
GetThreadId: 55
|
||||
GetResourceLimit: 56
|
||||
GetResourceLimitLimitValues: 57
|
||||
GetResourceLimitCurrentValues: 58
|
||||
GetThreadContext: 59
|
||||
Break: 60
|
||||
OutputDebugString: 61
|
||||
ControlPerformanceCounter: 62
|
||||
CreatePort: 71
|
||||
CreateSessionToPort: 72
|
||||
CreateSession: 73
|
||||
AcceptSession: 74
|
||||
ReplyAndReceive1: 75
|
||||
ReplyAndReceive2: 76
|
||||
ReplyAndReceive3: 77
|
||||
ReplyAndReceive4: 78
|
||||
ReplyAndReceive: 79
|
||||
BindInterrupt: 80
|
||||
UnbindInterrupt: 81
|
||||
InvalidateProcessDataCache: 82
|
||||
StoreProcessDataCache: 83
|
||||
FlushProcessDataCache: 84
|
||||
StartInterProcessDma: 85
|
||||
StopDma: 86
|
||||
GetDmaState: 87
|
||||
RestartDma: 88
|
||||
DebugActiveProcess: 96
|
||||
BreakDebugProcess: 97
|
||||
TerminateDebugProcess: 98
|
||||
GetProcessDebugEvent: 99
|
||||
ContinueDebugEvent: 100
|
||||
GetProcessList: 101
|
||||
GetThreadList: 102
|
||||
GetDebugThreadContext: 103
|
||||
SetDebugThreadContext: 104
|
||||
QueryDebugProcessMemory: 105
|
||||
ReadProcessMemory: 106
|
||||
WriteProcessMemory: 107
|
||||
SetHardwareBreakPoint: 108
|
||||
GetDebugThreadParam: 109
|
||||
ControlProcessMemory: 112
|
||||
MapProcessMemory: 113
|
||||
UnmapProcessMemory: 114
|
||||
CreateCodeSet: 115
|
||||
CreateProcess: 117
|
||||
TerminateProcess: 118
|
||||
SetProcessResourceLimits: 119
|
||||
CreateResourceLimit: 120
|
||||
SetResourceLimitValues: 121
|
||||
AddCodeSegment: 122
|
||||
Backdoor: 123
|
||||
KernelSetState: 124
|
||||
QueryProcessMemory: 125
|
||||
|
||||
# Liste des services
|
||||
# 34 services maximum (32 si le micrologiciel est antérieur à la version 9.6.0)
|
||||
ServiceAccessControl:
|
||||
- APT:U
|
||||
- ac:u
|
||||
- am:net
|
||||
#- boss:U
|
||||
#- cam:u
|
||||
#- cecd:u
|
||||
#- cfg:nor
|
||||
- cfg:u
|
||||
#- csnd:SND
|
||||
- dsp::DSP
|
||||
#- frd:u
|
||||
- fs:USER
|
||||
- gsp::Gpu
|
||||
- gsp::Lcd
|
||||
- hid:USER
|
||||
- http:C
|
||||
#- ir:rst
|
||||
#- ir:u
|
||||
#- ir:USER
|
||||
#- mic:u
|
||||
#- ndm:u
|
||||
#- news:s
|
||||
- nwm::EXT
|
||||
- nwm::UDS
|
||||
- ptm:sysm
|
||||
- ptm:u
|
||||
- pxi:dev
|
||||
- soc:U
|
||||
- ssl:C
|
||||
#- y2r:u
|
||||
|
||||
|
||||
SystemControlInfo:
|
||||
SaveDataSize: 0KB # Change if the app uses savedata
|
||||
RemasterVersion: $(APP_VERSION_MAJOR)
|
||||
StackSize: 0x40000
|
||||
|
||||
# Les modules qui exécutent les services énumérés ci-dessus doivent être inclus sous
|
||||
# 48 dépendances maximum
|
||||
# <module name>:<module titleid>
|
||||
Dependency:
|
||||
ac: 0x0004013000002402
|
||||
#act: 0x0004013000003802
|
||||
am: 0x0004013000001502
|
||||
boss: 0x0004013000003402
|
||||
camera: 0x0004013000001602
|
||||
cecd: 0x0004013000002602
|
||||
cfg: 0x0004013000001702
|
||||
codec: 0x0004013000001802
|
||||
csnd: 0x0004013000002702
|
||||
dlp: 0x0004013000002802
|
||||
dsp: 0x0004013000001a02
|
||||
friends: 0x0004013000003202
|
||||
gpio: 0x0004013000001b02
|
||||
gsp: 0x0004013000001c02
|
||||
hid: 0x0004013000001d02
|
||||
http: 0x0004013000002902
|
||||
i2c: 0x0004013000001e02
|
||||
ir: 0x0004013000003302
|
||||
mcu: 0x0004013000001f02
|
||||
mic: 0x0004013000002002
|
||||
ndm: 0x0004013000002b02
|
||||
news: 0x0004013000003502
|
||||
#nfc: 0x0004013000004002
|
||||
nim: 0x0004013000002c02
|
||||
nwm: 0x0004013000002d02
|
||||
pdn: 0x0004013000002102
|
||||
ps: 0x0004013000003102
|
||||
ptm: 0x0004013000002202
|
||||
#qtm: 0x0004013020004202
|
||||
ro: 0x0004013000003702
|
||||
socket: 0x0004013000002e02
|
||||
spi: 0x0004013000002302
|
||||
ssl: 0x0004013000002f02
|
||||
|
||||
+36
-36
@@ -1,37 +1,37 @@
|
||||
--atlas -f rgba -z auto
|
||||
|
||||
sprites/add.png
|
||||
sprites/add_font.png
|
||||
sprites/arrow.png
|
||||
sprites/checked.png
|
||||
sprites/delete.png
|
||||
sprites/download.png
|
||||
sprites/info.png
|
||||
sprites/keyboard.png
|
||||
sprites/list.png
|
||||
sprites/noIcon.png
|
||||
sprites/notes.png
|
||||
sprites/qr_code.png
|
||||
sprites/queue0.png
|
||||
sprites/queue1.png
|
||||
sprites/queue2.png
|
||||
sprites/queue3.png
|
||||
sprites/queue4.png
|
||||
sprites/queue5.png
|
||||
sprites/queue6.png
|
||||
sprites/queue7.png
|
||||
sprites/screenshot.png
|
||||
sprites/search.png
|
||||
sprites/settings.png
|
||||
sprites/shortcut.png
|
||||
sprites/sort.png
|
||||
sprites/sort_checked.png
|
||||
sprites/sort_unchecked.png
|
||||
sprites/toggle_off.png
|
||||
sprites/toggle_on.png
|
||||
sprites/unchecked.png
|
||||
sprites/DarkStore.png
|
||||
sprites/DarkStore-core.png
|
||||
sprites/update.png
|
||||
sprites/update_app.png
|
||||
--atlas -f rgba -z auto
|
||||
|
||||
sprites/add.png
|
||||
sprites/add_font.png
|
||||
sprites/arrow.png
|
||||
sprites/checked.png
|
||||
sprites/delete.png
|
||||
sprites/download.png
|
||||
sprites/info.png
|
||||
sprites/keyboard.png
|
||||
sprites/list.png
|
||||
sprites/noIcon.png
|
||||
sprites/notes.png
|
||||
sprites/qr_code.png
|
||||
sprites/queue0.png
|
||||
sprites/queue1.png
|
||||
sprites/queue2.png
|
||||
sprites/queue3.png
|
||||
sprites/queue4.png
|
||||
sprites/queue5.png
|
||||
sprites/queue6.png
|
||||
sprites/queue7.png
|
||||
sprites/screenshot.png
|
||||
sprites/search.png
|
||||
sprites/settings.png
|
||||
sprites/shortcut.png
|
||||
sprites/sort.png
|
||||
sprites/sort_checked.png
|
||||
sprites/sort_unchecked.png
|
||||
sprites/toggle_off.png
|
||||
sprites/toggle_on.png
|
||||
sprites/unchecked.png
|
||||
sprites/DarkStore.png
|
||||
sprites/DarkStore-core.png
|
||||
sprites/update.png
|
||||
sprites/update_app.png
|
||||
sprites/update_filter.png
|
||||
+3
-3
@@ -1,3 +1,3 @@
|
||||
@echo off
|
||||
make
|
||||
pause
|
||||
@echo off
|
||||
make
|
||||
pause
|
||||
|
||||
+3
-3
@@ -1,3 +1,3 @@
|
||||
files:
|
||||
- source: /romfs/lang/en/app.json
|
||||
translation: /romfs/lang/%two_letters_code%/app.json
|
||||
files:
|
||||
- source: /romfs/lang/en/app.json
|
||||
translation: /romfs/lang/%two_letters_code%/app.json
|
||||
|
||||
+45
-45
@@ -1,46 +1,46 @@
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#ifndef _GHOST_ESHOP_COMMON_HPP
|
||||
#define _GHOST_ESHOP_COMMON_HPP
|
||||
|
||||
#include <3ds.h>
|
||||
#include "config.hpp"
|
||||
#include "gfx.hpp"
|
||||
#include "lang.hpp"
|
||||
#include "msg.hpp"
|
||||
#include "screenCommon.hpp"
|
||||
|
||||
#define _STORE_PATH "sdmc:/3ds/DarkStore/stores/"
|
||||
#define _META_PATH "sdmc:/3ds/DarkStore/MetaData.json"
|
||||
#define _ESHOP_VERSION 4
|
||||
|
||||
inline std::unique_ptr<Config> config;
|
||||
inline uint32_t hRepeat, hDown, hHeld;
|
||||
inline touchPosition touch;
|
||||
inline C2D_Font font;
|
||||
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#ifndef _DARKSTORE_COMMON_HPP
|
||||
#define _DARKSTORE_COMMON_HPP
|
||||
|
||||
#include <3ds.h>
|
||||
#include "config.hpp"
|
||||
#include "gfx.hpp"
|
||||
#include "lang.hpp"
|
||||
#include "msg.hpp"
|
||||
#include "screenCommon.hpp"
|
||||
|
||||
#define _STORE_PATH "sdmc:/3ds/DarkStore/stores/"
|
||||
#define _META_PATH "sdmc:/3ds/DarkStore/MetaData.json"
|
||||
#define _ESHOP_VERSION 4
|
||||
|
||||
inline std::unique_ptr<Config> config;
|
||||
inline uint32_t hRepeat, hDown, hHeld;
|
||||
inline touchPosition touch;
|
||||
inline C2D_Font font;
|
||||
|
||||
#endif
|
||||
+80
-80
@@ -1,81 +1,81 @@
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#ifndef _GHOST_ESHOP_GFX_HPP
|
||||
#define _GHOST_ESHOP_GFX_HPP
|
||||
|
||||
#include "common.hpp"
|
||||
#include "sprites.h"
|
||||
#include <citro2d.h>
|
||||
#include <string>
|
||||
|
||||
/*
|
||||
Définissez toutes les couleurs utilisées, pour des changements plus faciles.
|
||||
*/
|
||||
|
||||
/* Couleurs Standard. */
|
||||
#define WHITE C2D_Color32(255, 255, 255, 255)
|
||||
#define BLACK C2D_Color32(0, 0, 0, 255)
|
||||
#define TRANSPARENT C2D_Color32(0, 0, 0, 0)
|
||||
#define DIM_COLOR C2D_Color32(0, 0, 0, 190)
|
||||
|
||||
/* Barres, Textes, BG Couleurs. */
|
||||
#define TEXT_COLOR WHITE
|
||||
#define BAR_COLOR C2D_Color32(50, 73, 98, 255)
|
||||
#define BAR_OUTL_COLOR C2D_Color32(25, 30, 53, 255)
|
||||
#define BG_COLOR C2D_Color32(255, 125, 0, 255)
|
||||
|
||||
/* Entrée Des Couleurs. */
|
||||
#define ENTRY_BAR_COLOR BAR_COLOR
|
||||
#define ENTRY_BAR_OUTL_COLOR BAR_OUTL_COLOR
|
||||
|
||||
/* Entrée Des Couleurs De La Boîte. */
|
||||
#define BOX_INSIDE_COLOR C2D_Color32(28, 33, 58, 255)
|
||||
#define BOX_SELECTED_COLOR C2D_Color32(108, 130, 155, 255)
|
||||
#define BOX_UNSELECTED_COLOR BLACK
|
||||
|
||||
/* Couleurs De La Barre De Progression. */
|
||||
#define PROGRESSBAR_OUT_COLOR BOX_INSIDE_COLOR
|
||||
#define PROGRESSBAR_IN_COLOR SIDEBAR_UNSELECTED_COLOR
|
||||
|
||||
/* Couleurs du menu de recherche. */
|
||||
#define SEARCH_BAR_COLOR C2D_Color32(51, 75, 102, 255)
|
||||
#define SEARCH_BAR_OUTL_COLOR BAR_OUTL_COLOR
|
||||
|
||||
/* Sidebar Couleurs. */
|
||||
#define SIDEBAR_SELECTED_COLOR C2D_Color32(108, 130, 155, 255)
|
||||
#define SIDEBAR_UNSELECTED_COLOR C2D_Color32(77, 101, 128, 255)
|
||||
|
||||
namespace GFX {
|
||||
void DrawTop(void);
|
||||
void DrawBottom();
|
||||
void DrawSprite(int img, int x, int y, float ScaleX = 1, float ScaleY = 1);
|
||||
void DrawBox(float xPos, float yPos, float width = 50, float height = 50, bool selected = false, uint32_t clr = BOX_INSIDE_COLOR);
|
||||
void DrawCheckbox(float xPos, float yPos, bool selected);
|
||||
void DrawToggle(float xPos, float yPos, bool toggled);
|
||||
};
|
||||
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#ifndef _DARKSTORE_GFX_HPP
|
||||
#define _DARKSTORE_GFX_HPP
|
||||
|
||||
#include "common.hpp"
|
||||
#include "sprites.h"
|
||||
#include <citro2d.h>
|
||||
#include <string>
|
||||
|
||||
/*
|
||||
Définissez toutes les couleurs utilisées, pour des changements plus faciles.
|
||||
*/
|
||||
|
||||
/* Couleurs Standard. */
|
||||
#define WHITE C2D_Color32(255, 255, 255, 255)
|
||||
#define BLACK C2D_Color32(0, 0, 0, 255)
|
||||
#define TRANSPARENT C2D_Color32(0, 0, 0, 0)
|
||||
#define DIM_COLOR C2D_Color32(0, 0, 0, 190)
|
||||
|
||||
/* Barres, Textes, BG Couleurs. */
|
||||
#define TEXT_COLOR WHITE
|
||||
#define BAR_COLOR C2D_Color32(50, 73, 98, 255)
|
||||
#define BAR_OUTL_COLOR C2D_Color32(25, 30, 53, 255)
|
||||
#define BG_COLOR C2D_Color32(255, 125, 0, 255)
|
||||
|
||||
/* Entrée Des Couleurs. */
|
||||
#define ENTRY_BAR_COLOR BAR_COLOR
|
||||
#define ENTRY_BAR_OUTL_COLOR BAR_OUTL_COLOR
|
||||
|
||||
/* Entrée Des Couleurs De La Boîte. */
|
||||
#define BOX_INSIDE_COLOR C2D_Color32(28, 33, 58, 255)
|
||||
#define BOX_SELECTED_COLOR C2D_Color32(108, 130, 155, 255)
|
||||
#define BOX_UNSELECTED_COLOR BLACK
|
||||
|
||||
/* Couleurs De La Barre De Progression. */
|
||||
#define PROGRESSBAR_OUT_COLOR BOX_INSIDE_COLOR
|
||||
#define PROGRESSBAR_IN_COLOR SIDEBAR_UNSELECTED_COLOR
|
||||
|
||||
/* Couleurs du menu de recherche. */
|
||||
#define SEARCH_BAR_COLOR C2D_Color32(51, 75, 102, 255)
|
||||
#define SEARCH_BAR_OUTL_COLOR BAR_OUTL_COLOR
|
||||
|
||||
/* Sidebar Couleurs. */
|
||||
#define SIDEBAR_SELECTED_COLOR C2D_Color32(108, 130, 155, 255)
|
||||
#define SIDEBAR_UNSELECTED_COLOR C2D_Color32(77, 101, 128, 255)
|
||||
|
||||
namespace GFX {
|
||||
void DrawTop(void);
|
||||
void DrawBottom();
|
||||
void DrawSprite(int img, int x, int y, float ScaleX = 1, float ScaleY = 1);
|
||||
void DrawBox(float xPos, float yPos, float width = 50, float height = 50, bool selected = false, uint32_t clr = BOX_INSIDE_COLOR);
|
||||
void DrawCheckbox(float xPos, float yPos, bool selected);
|
||||
void DrawToggle(float xPos, float yPos, bool toggled);
|
||||
};
|
||||
|
||||
#endif
|
||||
+38
-38
@@ -1,39 +1,39 @@
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#ifndef _GHOST_ESHOP_MSG_HPP
|
||||
#define _GHOST_ESHOP_MSG_HPP
|
||||
|
||||
#include <string>
|
||||
|
||||
namespace Msg {
|
||||
void DisplayMsg(const std::string &Text);
|
||||
void DisplayWarnMsg(const std::string &Text);
|
||||
bool promptMsg(const std::string &promptMsg);
|
||||
void waitMsg(const std::string &msg);
|
||||
};
|
||||
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#ifndef _DARKSTORE_MSG_HPP
|
||||
#define _DARKSTORE_MSG_HPP
|
||||
|
||||
#include <string>
|
||||
|
||||
namespace Msg {
|
||||
void DisplayMsg(const std::string &Text);
|
||||
void DisplayWarnMsg(const std::string &Text);
|
||||
bool promptMsg(const std::string &promptMsg);
|
||||
void waitMsg(const std::string &msg);
|
||||
};
|
||||
|
||||
#endif
|
||||
+40
-40
@@ -1,41 +1,41 @@
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#ifndef _GHOST_ESHOP_INIT_HPP
|
||||
#define _GHOST_ESHOP_INIT_HPP
|
||||
|
||||
#include <3ds.h>
|
||||
|
||||
namespace Init {
|
||||
Result Initialize();
|
||||
Result MainLoop();
|
||||
Result Exit();
|
||||
|
||||
void LoadFont();
|
||||
void UnloadFont();
|
||||
};
|
||||
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#ifndef _DARKSTORE_INIT_HPP
|
||||
#define _DARKSTORE_INIT_HPP
|
||||
|
||||
#include <3ds.h>
|
||||
|
||||
namespace Init {
|
||||
Result Initialize();
|
||||
Result MainLoop();
|
||||
Result Exit();
|
||||
|
||||
void LoadFont();
|
||||
void UnloadFont();
|
||||
};
|
||||
|
||||
#endif
|
||||
+36
-36
@@ -1,37 +1,37 @@
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#ifndef _GHOST_ESHOP_KEYBOARD_HPP
|
||||
#define _GHOST_ESHOP_KEYBOARD_HPP
|
||||
|
||||
#include "storeEntry.hpp"
|
||||
#include <string>
|
||||
|
||||
namespace Input {
|
||||
std::string setkbdString(uint maxLength, const std::string &Text, const std::vector<std::unique_ptr<StoreEntry>> &entries);
|
||||
};
|
||||
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#ifndef _DARKSTORE_KEYBOARD_HPP
|
||||
#define _DARKSTORE_KEYBOARD_HPP
|
||||
|
||||
#include "storeEntry.hpp"
|
||||
#include <string>
|
||||
|
||||
namespace Input {
|
||||
std::string setkbdString(uint maxLength, const std::string &Text, const std::vector<std::unique_ptr<StoreEntry>> &entries);
|
||||
};
|
||||
|
||||
#endif
|
||||
@@ -1,42 +1,42 @@
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#ifndef _GHOST_ESHOP_OVERLAY_HPP
|
||||
#define _GHOST_ESHOP_OVERLAY_HPP
|
||||
|
||||
#include "common.hpp"
|
||||
#include "store.hpp"
|
||||
#include "storeEntry.hpp"
|
||||
#include <3ds.h>
|
||||
|
||||
namespace Overlays {
|
||||
void SelectStore(std::unique_ptr<Store> &store, std::vector<std::unique_ptr<StoreEntry>> &entries, std::unique_ptr<Meta> &meta);
|
||||
void SelectLanguage(const std::unique_ptr<Store> &store);
|
||||
void ShowCredits();
|
||||
std::string SelectDir(const std::string &oldDir, const std::string &msg, const std::unique_ptr<Store> &store);
|
||||
};
|
||||
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#ifndef _DARKSTORE_OVERLAY_HPP
|
||||
#define _DARKSTORE_OVERLAY_HPP
|
||||
|
||||
#include "common.hpp"
|
||||
#include "store.hpp"
|
||||
#include "storeEntry.hpp"
|
||||
#include <3ds.h>
|
||||
|
||||
namespace Overlays {
|
||||
void SelectStore(std::unique_ptr<Store> &store, std::vector<std::unique_ptr<StoreEntry>> &entries, std::unique_ptr<Meta> &meta);
|
||||
void SelectLanguage(const std::unique_ptr<Store> &store);
|
||||
void ShowCredits();
|
||||
std::string SelectDir(const std::string &oldDir, const std::string &msg, const std::unique_ptr<Store> &store);
|
||||
};
|
||||
|
||||
#endif
|
||||
+125
-125
@@ -1,126 +1,126 @@
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
/*
|
||||
* This file is part of PKSM
|
||||
* Copyright (C) 2016-2020 Bernardo Giordano, Admiral Fish, piepie62
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#ifndef _GHOST_ESHOP_QR_CODE_HPP
|
||||
#define _GHOST_ESHOP_QR_CODE_HPP
|
||||
|
||||
#include "common.hpp"
|
||||
#include "quirc.hpp"
|
||||
#include <atomic>
|
||||
#include <3ds.h>
|
||||
#include <array>
|
||||
#include <vector>
|
||||
|
||||
class QRCode {
|
||||
public:
|
||||
QRCode();
|
||||
~QRCode();
|
||||
|
||||
void drawThread();
|
||||
void captureThread();
|
||||
void handler(std::string &result);
|
||||
bool done() const { return this->finished; };
|
||||
bool cancelled() const { return this->cancel; };
|
||||
void List(bool v) { this->displayList = v; };
|
||||
private:
|
||||
void buffToImage();
|
||||
void finish();
|
||||
std::array<u16, 400 * 240> cameraBuffer;
|
||||
LightLock bufferLock;
|
||||
C2D_Image image;
|
||||
LightLock imageLock;
|
||||
quirc *qrData;
|
||||
Handle exitEvent;
|
||||
static constexpr Tex3DS_SubTexture subtex = { 512, 256, 0.0f, 1.0f, 1.0f, 0.0f };
|
||||
std::atomic<bool> finished = false;
|
||||
bool capturing = false;
|
||||
bool cancel = false;
|
||||
bool displayList = false;
|
||||
int selectedStore = 0, sPos = 0;
|
||||
std::vector<StoreList> stores = { };
|
||||
std::vector<u8> out;
|
||||
};
|
||||
|
||||
/*
|
||||
This is, what should get called.
|
||||
*/
|
||||
namespace QR_Scanner {
|
||||
std::string StoreHandle();
|
||||
};
|
||||
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
/*
|
||||
* This file is part of PKSM
|
||||
* Copyright (C) 2016-2020 Bernardo Giordano, Admiral Fish, piepie62
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#ifndef _DARKSTORE_QR_CODE_HPP
|
||||
#define _DARKSTORE_QR_CODE_HPP
|
||||
|
||||
#include "common.hpp"
|
||||
#include "quirc.hpp"
|
||||
#include <atomic>
|
||||
#include <3ds.h>
|
||||
#include <array>
|
||||
#include <vector>
|
||||
|
||||
class QRCode {
|
||||
public:
|
||||
QRCode();
|
||||
~QRCode();
|
||||
|
||||
void drawThread();
|
||||
void captureThread();
|
||||
void handler(std::string &result);
|
||||
bool done() const { return this->finished; };
|
||||
bool cancelled() const { return this->cancel; };
|
||||
void List(bool v) { this->displayList = v; };
|
||||
private:
|
||||
void buffToImage();
|
||||
void finish();
|
||||
std::array<u16, 400 * 240> cameraBuffer;
|
||||
LightLock bufferLock;
|
||||
C2D_Image image;
|
||||
LightLock imageLock;
|
||||
quirc *qrData;
|
||||
Handle exitEvent;
|
||||
static constexpr Tex3DS_SubTexture subtex = { 512, 256, 0.0f, 1.0f, 1.0f, 0.0f };
|
||||
std::atomic<bool> finished = false;
|
||||
bool capturing = false;
|
||||
bool cancel = false;
|
||||
bool displayList = false;
|
||||
int selectedStore = 0, sPos = 0;
|
||||
std::vector<StoreList> stores = { };
|
||||
std::vector<u8> out;
|
||||
};
|
||||
|
||||
/*
|
||||
This is, what should get called.
|
||||
*/
|
||||
namespace QR_Scanner {
|
||||
std::string StoreHandle();
|
||||
};
|
||||
|
||||
#endif
|
||||
+190
-190
@@ -1,191 +1,191 @@
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
/* quirc -- QR-code recognition library
|
||||
* Copyright (C) 2010-2012 Daniel Beer <dlbeer@gmail.com>
|
||||
*
|
||||
* Permission to use, copy, modify, and/or distribute this software for any
|
||||
* purpose with or without fee is hereby granted, provided that the above
|
||||
* copyright notice and this permission notice appear in all copies.
|
||||
*
|
||||
* THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
* WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
* MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
* ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
* WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
* ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
* OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
|
||||
#ifndef QUIRC_HPP
|
||||
#define QUIRC_HPP
|
||||
|
||||
#include <stdint.h>
|
||||
|
||||
struct quirc;
|
||||
|
||||
/* Obtain the library version string. */
|
||||
const char *quirc_version(void);
|
||||
|
||||
/* Construct a new QR-code recognizer. This function will return NULL
|
||||
* if sufficient memory could not be allocated.
|
||||
*/
|
||||
struct quirc *quirc_new(void);
|
||||
|
||||
/* Destroy a QR-code recognizer. */
|
||||
void quirc_destroy(struct quirc *q);
|
||||
|
||||
/* Resize the QR-code recognizer. The size of an image must be
|
||||
* specified before codes can be analyzed.
|
||||
*
|
||||
* This function returns 0 on success, or -1 if sufficient memory could
|
||||
* not be allocated.
|
||||
*/
|
||||
int quirc_resize(struct quirc *q, int w, int h);
|
||||
|
||||
/* These functions are used to process images for QR-code recognition.
|
||||
* quirc_begin() must first be called to obtain access to a buffer into
|
||||
* which the input image should be placed. Optionally, the current
|
||||
* width and height may be returned.
|
||||
*
|
||||
* After filling the buffer, quirc_end() should be called to process
|
||||
* the image for QR-code recognition. The locations and content of each
|
||||
* code may be obtained using accessor functions described below.
|
||||
*/
|
||||
uint8_t *quirc_begin(struct quirc *q, int *w, int *h);
|
||||
void quirc_end(struct quirc *q);
|
||||
|
||||
/* This structure describes a location in the input image buffer. */
|
||||
struct quirc_point {
|
||||
int x;
|
||||
int y;
|
||||
};
|
||||
|
||||
/* This enum describes the various decoder errors which may occur. */
|
||||
typedef enum {
|
||||
QUIRC_SUCCESS = 0,
|
||||
QUIRC_ERROR_INVALID_GRID_SIZE,
|
||||
QUIRC_ERROR_INVALID_VERSION,
|
||||
QUIRC_ERROR_FORMAT_ECC,
|
||||
QUIRC_ERROR_DATA_ECC,
|
||||
QUIRC_ERROR_UNKNOWN_DATA_TYPE,
|
||||
QUIRC_ERROR_DATA_OVERFLOW,
|
||||
QUIRC_ERROR_DATA_UNDERFLOW
|
||||
} quirc_decode_error_t;
|
||||
|
||||
/* Return a string error message for an error code. */
|
||||
const char *quirc_strerror(quirc_decode_error_t err);
|
||||
|
||||
/* Limits on the maximum size of QR-codes and their content. */
|
||||
#define QUIRC_MAX_BITMAP 3917
|
||||
#define QUIRC_MAX_PAYLOAD 8896
|
||||
|
||||
/* QR-code ECC types. */
|
||||
#define QUIRC_ECC_LEVEL_M 0
|
||||
#define QUIRC_ECC_LEVEL_L 1
|
||||
#define QUIRC_ECC_LEVEL_H 2
|
||||
#define QUIRC_ECC_LEVEL_Q 3
|
||||
|
||||
/* QR-code data types. */
|
||||
#define QUIRC_DATA_TYPE_NUMERIC 1
|
||||
#define QUIRC_DATA_TYPE_ALPHA 2
|
||||
#define QUIRC_DATA_TYPE_BYTE 4
|
||||
#define QUIRC_DATA_TYPE_KANJI 8
|
||||
|
||||
/* Common character encodings */
|
||||
#define QUIRC_ECI_ISO_8859_1 1
|
||||
#define QUIRC_ECI_IBM437 2
|
||||
#define QUIRC_ECI_ISO_8859_2 4
|
||||
#define QUIRC_ECI_ISO_8859_3 5
|
||||
#define QUIRC_ECI_ISO_8859_4 6
|
||||
#define QUIRC_ECI_ISO_8859_5 7
|
||||
#define QUIRC_ECI_ISO_8859_6 8
|
||||
#define QUIRC_ECI_ISO_8859_7 9
|
||||
#define QUIRC_ECI_ISO_8859_8 10
|
||||
#define QUIRC_ECI_ISO_8859_9 11
|
||||
#define QUIRC_ECI_WINDOWS_874 13
|
||||
#define QUIRC_ECI_ISO_8859_13 15
|
||||
#define QUIRC_ECI_ISO_8859_15 17
|
||||
#define QUIRC_ECI_SHIFT_JIS 20
|
||||
#define QUIRC_ECI_UTF_8 26
|
||||
|
||||
/* This structure is used to return information about detected QR codes
|
||||
* in the input image.
|
||||
*/
|
||||
struct quirc_code {
|
||||
/* The four corners of the QR-code, from top left, clockwise */
|
||||
struct quirc_point corners[4];
|
||||
|
||||
/* The number of cells across in the QR-code. The cell bitmap
|
||||
* is a bitmask giving the actual values of cells. If the cell
|
||||
* at (x, y) is black, then the following bit is set:
|
||||
*
|
||||
* cell_bitmap[i << 3] & (1 << (i & 7))
|
||||
*
|
||||
* where i = (y * size) + x.
|
||||
*/
|
||||
int size;
|
||||
uint8_t cell_bitmap[QUIRC_MAX_BITMAP];
|
||||
};
|
||||
|
||||
/* This structure holds the decoded QR-code data */
|
||||
struct quirc_data {
|
||||
/* Various parameters of the QR-code. These can mostly be
|
||||
* ignored if you only care about the data.
|
||||
*/
|
||||
int version;
|
||||
int ecc_level;
|
||||
int mask;
|
||||
|
||||
/* This field is the highest-valued data type found in the QR
|
||||
* code.
|
||||
*/
|
||||
int data_type;
|
||||
|
||||
/* Data payload. For the Kanji datatype, payload is encoded as
|
||||
* Shift-JIS. For all other datatypes, payload is ASCII text.
|
||||
*/
|
||||
uint8_t payload[QUIRC_MAX_PAYLOAD];
|
||||
int payload_len;
|
||||
|
||||
/* ECI assignment number */
|
||||
uint32_t eci;
|
||||
};
|
||||
|
||||
/* Return the number of QR-codes identified in the last processed
|
||||
* image.
|
||||
*/
|
||||
int quirc_count(const struct quirc *q);
|
||||
|
||||
/* Extract the QR-code specified by the given index. */
|
||||
void quirc_extract(const struct quirc *q, int index,
|
||||
struct quirc_code *code);
|
||||
|
||||
/* Decode a QR-code, returning the payload data. */
|
||||
quirc_decode_error_t quirc_decode(const struct quirc_code *code,
|
||||
struct quirc_data *data);
|
||||
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
/* quirc -- QR-code recognition library
|
||||
* Copyright (C) 2010-2012 Daniel Beer <dlbeer@gmail.com>
|
||||
*
|
||||
* Permission to use, copy, modify, and/or distribute this software for any
|
||||
* purpose with or without fee is hereby granted, provided that the above
|
||||
* copyright notice and this permission notice appear in all copies.
|
||||
*
|
||||
* THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
* WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
* MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
* ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
* WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
* ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
* OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
|
||||
#ifndef QUIRC_HPP
|
||||
#define QUIRC_HPP
|
||||
|
||||
#include <stdint.h>
|
||||
|
||||
struct quirc;
|
||||
|
||||
/* Obtain the library version string. */
|
||||
const char *quirc_version(void);
|
||||
|
||||
/* Construct a new QR-code recognizer. This function will return NULL
|
||||
* if sufficient memory could not be allocated.
|
||||
*/
|
||||
struct quirc *quirc_new(void);
|
||||
|
||||
/* Destroy a QR-code recognizer. */
|
||||
void quirc_destroy(struct quirc *q);
|
||||
|
||||
/* Resize the QR-code recognizer. The size of an image must be
|
||||
* specified before codes can be analyzed.
|
||||
*
|
||||
* This function returns 0 on success, or -1 if sufficient memory could
|
||||
* not be allocated.
|
||||
*/
|
||||
int quirc_resize(struct quirc *q, int w, int h);
|
||||
|
||||
/* These functions are used to process images for QR-code recognition.
|
||||
* quirc_begin() must first be called to obtain access to a buffer into
|
||||
* which the input image should be placed. Optionally, the current
|
||||
* width and height may be returned.
|
||||
*
|
||||
* After filling the buffer, quirc_end() should be called to process
|
||||
* the image for QR-code recognition. The locations and content of each
|
||||
* code may be obtained using accessor functions described below.
|
||||
*/
|
||||
uint8_t *quirc_begin(struct quirc *q, int *w, int *h);
|
||||
void quirc_end(struct quirc *q);
|
||||
|
||||
/* This structure describes a location in the input image buffer. */
|
||||
struct quirc_point {
|
||||
int x;
|
||||
int y;
|
||||
};
|
||||
|
||||
/* This enum describes the various decoder errors which may occur. */
|
||||
typedef enum {
|
||||
QUIRC_SUCCESS = 0,
|
||||
QUIRC_ERROR_INVALID_GRID_SIZE,
|
||||
QUIRC_ERROR_INVALID_VERSION,
|
||||
QUIRC_ERROR_FORMAT_ECC,
|
||||
QUIRC_ERROR_DATA_ECC,
|
||||
QUIRC_ERROR_UNKNOWN_DATA_TYPE,
|
||||
QUIRC_ERROR_DATA_OVERFLOW,
|
||||
QUIRC_ERROR_DATA_UNDERFLOW
|
||||
} quirc_decode_error_t;
|
||||
|
||||
/* Return a string error message for an error code. */
|
||||
const char *quirc_strerror(quirc_decode_error_t err);
|
||||
|
||||
/* Limits on the maximum size of QR-codes and their content. */
|
||||
#define QUIRC_MAX_BITMAP 3917
|
||||
#define QUIRC_MAX_PAYLOAD 8896
|
||||
|
||||
/* QR-code ECC types. */
|
||||
#define QUIRC_ECC_LEVEL_M 0
|
||||
#define QUIRC_ECC_LEVEL_L 1
|
||||
#define QUIRC_ECC_LEVEL_H 2
|
||||
#define QUIRC_ECC_LEVEL_Q 3
|
||||
|
||||
/* QR-code data types. */
|
||||
#define QUIRC_DATA_TYPE_NUMERIC 1
|
||||
#define QUIRC_DATA_TYPE_ALPHA 2
|
||||
#define QUIRC_DATA_TYPE_BYTE 4
|
||||
#define QUIRC_DATA_TYPE_KANJI 8
|
||||
|
||||
/* Common character encodings */
|
||||
#define QUIRC_ECI_ISO_8859_1 1
|
||||
#define QUIRC_ECI_IBM437 2
|
||||
#define QUIRC_ECI_ISO_8859_2 4
|
||||
#define QUIRC_ECI_ISO_8859_3 5
|
||||
#define QUIRC_ECI_ISO_8859_4 6
|
||||
#define QUIRC_ECI_ISO_8859_5 7
|
||||
#define QUIRC_ECI_ISO_8859_6 8
|
||||
#define QUIRC_ECI_ISO_8859_7 9
|
||||
#define QUIRC_ECI_ISO_8859_8 10
|
||||
#define QUIRC_ECI_ISO_8859_9 11
|
||||
#define QUIRC_ECI_WINDOWS_874 13
|
||||
#define QUIRC_ECI_ISO_8859_13 15
|
||||
#define QUIRC_ECI_ISO_8859_15 17
|
||||
#define QUIRC_ECI_SHIFT_JIS 20
|
||||
#define QUIRC_ECI_UTF_8 26
|
||||
|
||||
/* This structure is used to return information about detected QR codes
|
||||
* in the input image.
|
||||
*/
|
||||
struct quirc_code {
|
||||
/* The four corners of the QR-code, from top left, clockwise */
|
||||
struct quirc_point corners[4];
|
||||
|
||||
/* The number of cells across in the QR-code. The cell bitmap
|
||||
* is a bitmask giving the actual values of cells. If the cell
|
||||
* at (x, y) is black, then the following bit is set:
|
||||
*
|
||||
* cell_bitmap[i << 3] & (1 << (i & 7))
|
||||
*
|
||||
* where i = (y * size) + x.
|
||||
*/
|
||||
int size;
|
||||
uint8_t cell_bitmap[QUIRC_MAX_BITMAP];
|
||||
};
|
||||
|
||||
/* This structure holds the decoded QR-code data */
|
||||
struct quirc_data {
|
||||
/* Various parameters of the QR-code. These can mostly be
|
||||
* ignored if you only care about the data.
|
||||
*/
|
||||
int version;
|
||||
int ecc_level;
|
||||
int mask;
|
||||
|
||||
/* This field is the highest-valued data type found in the QR
|
||||
* code.
|
||||
*/
|
||||
int data_type;
|
||||
|
||||
/* Data payload. For the Kanji datatype, payload is encoded as
|
||||
* Shift-JIS. For all other datatypes, payload is ASCII text.
|
||||
*/
|
||||
uint8_t payload[QUIRC_MAX_PAYLOAD];
|
||||
int payload_len;
|
||||
|
||||
/* ECI assignment number */
|
||||
uint32_t eci;
|
||||
};
|
||||
|
||||
/* Return the number of QR-codes identified in the last processed
|
||||
* image.
|
||||
*/
|
||||
int quirc_count(const struct quirc *q);
|
||||
|
||||
/* Extract the QR-code specified by the given index. */
|
||||
void quirc_extract(const struct quirc *q, int index,
|
||||
struct quirc_code *code);
|
||||
|
||||
/* Decode a QR-code, returning the payload data. */
|
||||
quirc_decode_error_t quirc_decode(const struct quirc_code *code,
|
||||
struct quirc_data *data);
|
||||
|
||||
#endif
|
||||
+139
-139
@@ -1,140 +1,140 @@
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
/* quirc -- QR-code recognition library
|
||||
* Copyright (C) 2010-2012 Daniel Beer <dlbeer@gmail.com>
|
||||
*
|
||||
* Permission to use, copy, modify, and/or distribute this software for any
|
||||
* purpose with or without fee is hereby granted, provided that the above
|
||||
* copyright notice and this permission notice appear in all copies.
|
||||
*
|
||||
* THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
* WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
* MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
* ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
* WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
* ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
* OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
|
||||
#ifndef QUIRC_INTERNAL_HPP
|
||||
#define QUIRC_INTERNAL_HPP
|
||||
|
||||
#include "quirc.hpp"
|
||||
|
||||
#define QUIRC_PIXEL_WHITE 0
|
||||
#define QUIRC_PIXEL_BLACK 1
|
||||
#define QUIRC_PIXEL_REGION 2
|
||||
|
||||
#ifndef QUIRC_MAX_REGIONS
|
||||
#define QUIRC_MAX_REGIONS 254
|
||||
#endif
|
||||
#define QUIRC_MAX_CAPSTONES 32
|
||||
#define QUIRC_MAX_GRIDS 8
|
||||
|
||||
#define QUIRC_PERSPECTIVE_PARAMS 8
|
||||
|
||||
#if QUIRC_MAX_REGIONS < UINT8_MAX
|
||||
typedef uint8_t quirc_pixel_t;
|
||||
#elif QUIRC_MAX_REGIONS < UINT16_MAX
|
||||
typedef uint16_t quirc_pixel_t;
|
||||
#else
|
||||
#error "QUIRC_MAX_REGIONS > 65534 is not supported"
|
||||
#endif
|
||||
|
||||
struct quirc_region {
|
||||
struct quirc_point seed;
|
||||
int count;
|
||||
int capstone;
|
||||
};
|
||||
|
||||
struct quirc_capstone {
|
||||
int ring;
|
||||
int stone;
|
||||
|
||||
struct quirc_point corners[4];
|
||||
struct quirc_point center;
|
||||
double c[QUIRC_PERSPECTIVE_PARAMS];
|
||||
|
||||
int qr_grid;
|
||||
};
|
||||
|
||||
struct quirc_grid {
|
||||
/* Capstone indices */
|
||||
int caps[3];
|
||||
|
||||
/* Alignment pattern region and corner */
|
||||
int align_region;
|
||||
struct quirc_point align;
|
||||
|
||||
/* Timing pattern endpoints */
|
||||
struct quirc_point tpep[3];
|
||||
int hscan;
|
||||
int vscan;
|
||||
|
||||
/* Grid size and perspective transform */
|
||||
int grid_size;
|
||||
double c[QUIRC_PERSPECTIVE_PARAMS];
|
||||
};
|
||||
|
||||
struct quirc {
|
||||
uint8_t *image;
|
||||
quirc_pixel_t *pixels;
|
||||
int w;
|
||||
int h;
|
||||
|
||||
int num_regions;
|
||||
struct quirc_region regions[QUIRC_MAX_REGIONS];
|
||||
|
||||
int num_capstones;
|
||||
struct quirc_capstone capstones[QUIRC_MAX_CAPSTONES];
|
||||
|
||||
int num_grids;
|
||||
struct quirc_grid grids[QUIRC_MAX_GRIDS];
|
||||
};
|
||||
|
||||
/************************************************************************
|
||||
* QR-code version information database
|
||||
*/
|
||||
|
||||
#define QUIRC_MAX_VERSION 40
|
||||
#define QUIRC_MAX_ALIGNMENT 7
|
||||
|
||||
struct quirc_rs_params {
|
||||
int bs; /* Block size */
|
||||
int dw; /* Data words */
|
||||
int ce; /* Correctable errors */
|
||||
};
|
||||
|
||||
struct quirc_version_info {
|
||||
int data_bytes;
|
||||
int apat[QUIRC_MAX_ALIGNMENT];
|
||||
struct quirc_rs_params ecc[4];
|
||||
};
|
||||
|
||||
extern const struct quirc_version_info quirc_version_db[QUIRC_MAX_VERSION + 1];
|
||||
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
/* quirc -- QR-code recognition library
|
||||
* Copyright (C) 2010-2012 Daniel Beer <dlbeer@gmail.com>
|
||||
*
|
||||
* Permission to use, copy, modify, and/or distribute this software for any
|
||||
* purpose with or without fee is hereby granted, provided that the above
|
||||
* copyright notice and this permission notice appear in all copies.
|
||||
*
|
||||
* THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
* WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
* MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
* ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
* WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
* ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
* OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
|
||||
#ifndef QUIRC_INTERNAL_HPP
|
||||
#define QUIRC_INTERNAL_HPP
|
||||
|
||||
#include "quirc.hpp"
|
||||
|
||||
#define QUIRC_PIXEL_WHITE 0
|
||||
#define QUIRC_PIXEL_BLACK 1
|
||||
#define QUIRC_PIXEL_REGION 2
|
||||
|
||||
#ifndef QUIRC_MAX_REGIONS
|
||||
#define QUIRC_MAX_REGIONS 254
|
||||
#endif
|
||||
#define QUIRC_MAX_CAPSTONES 32
|
||||
#define QUIRC_MAX_GRIDS 8
|
||||
|
||||
#define QUIRC_PERSPECTIVE_PARAMS 8
|
||||
|
||||
#if QUIRC_MAX_REGIONS < UINT8_MAX
|
||||
typedef uint8_t quirc_pixel_t;
|
||||
#elif QUIRC_MAX_REGIONS < UINT16_MAX
|
||||
typedef uint16_t quirc_pixel_t;
|
||||
#else
|
||||
#error "QUIRC_MAX_REGIONS > 65534 is not supported"
|
||||
#endif
|
||||
|
||||
struct quirc_region {
|
||||
struct quirc_point seed;
|
||||
int count;
|
||||
int capstone;
|
||||
};
|
||||
|
||||
struct quirc_capstone {
|
||||
int ring;
|
||||
int stone;
|
||||
|
||||
struct quirc_point corners[4];
|
||||
struct quirc_point center;
|
||||
double c[QUIRC_PERSPECTIVE_PARAMS];
|
||||
|
||||
int qr_grid;
|
||||
};
|
||||
|
||||
struct quirc_grid {
|
||||
/* Capstone indices */
|
||||
int caps[3];
|
||||
|
||||
/* Alignment pattern region and corner */
|
||||
int align_region;
|
||||
struct quirc_point align;
|
||||
|
||||
/* Timing pattern endpoints */
|
||||
struct quirc_point tpep[3];
|
||||
int hscan;
|
||||
int vscan;
|
||||
|
||||
/* Grid size and perspective transform */
|
||||
int grid_size;
|
||||
double c[QUIRC_PERSPECTIVE_PARAMS];
|
||||
};
|
||||
|
||||
struct quirc {
|
||||
uint8_t *image;
|
||||
quirc_pixel_t *pixels;
|
||||
int w;
|
||||
int h;
|
||||
|
||||
int num_regions;
|
||||
struct quirc_region regions[QUIRC_MAX_REGIONS];
|
||||
|
||||
int num_capstones;
|
||||
struct quirc_capstone capstones[QUIRC_MAX_CAPSTONES];
|
||||
|
||||
int num_grids;
|
||||
struct quirc_grid grids[QUIRC_MAX_GRIDS];
|
||||
};
|
||||
|
||||
/************************************************************************
|
||||
* QR-code version information database
|
||||
*/
|
||||
|
||||
#define QUIRC_MAX_VERSION 40
|
||||
#define QUIRC_MAX_ALIGNMENT 7
|
||||
|
||||
struct quirc_rs_params {
|
||||
int bs; /* Block size */
|
||||
int dw; /* Data words */
|
||||
int ce; /* Correctable errors */
|
||||
};
|
||||
|
||||
struct quirc_version_info {
|
||||
int data_bytes;
|
||||
int apat[QUIRC_MAX_ALIGNMENT];
|
||||
struct quirc_rs_params ecc[4];
|
||||
};
|
||||
|
||||
extern const struct quirc_version_info quirc_version_db[QUIRC_MAX_VERSION + 1];
|
||||
|
||||
#endif
|
||||
@@ -1,74 +1,74 @@
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#ifndef _GHOST_ESHOP_MAIN_SCREEN_HPP
|
||||
#define _GHOST_ESHOP_MAIN_SCREEN_HPP
|
||||
|
||||
#include "common.hpp"
|
||||
#include "store.hpp"
|
||||
#include "storeEntry.hpp"
|
||||
#include "storeUtils.hpp"
|
||||
|
||||
/*
|
||||
Modes:
|
||||
|
||||
0: Entry Info.
|
||||
1: Download List.
|
||||
2: Queue.
|
||||
3: Search + Favorites.
|
||||
4: Sorting.
|
||||
5: Settings / Credits(?).
|
||||
6: Screenshot Menu.
|
||||
7: Release Notes.
|
||||
*/
|
||||
|
||||
class MainScreen : public Screen {
|
||||
public:
|
||||
MainScreen();
|
||||
void Draw(void) const override;
|
||||
void Logic(u32 hDown, u32 hHeld, touchPosition touch) override;
|
||||
private:
|
||||
std::unique_ptr<Store> store = nullptr;
|
||||
std::unique_ptr<Meta> meta = nullptr;
|
||||
std::vector<std::unique_ptr<StoreEntry>> entries;
|
||||
std::vector<std::string> dwnldList, dwnldSizes;
|
||||
|
||||
bool initialized = false, fetchDown = false, showMarks = false, showSettings = false,
|
||||
ascending = false, updateFilter = false, screenshotFetch = false, canDisplay = false;
|
||||
|
||||
int storeMode = 0, marks = 0, markIndex = 0, sPage = 0, lMode = 0, sSelection = 0,
|
||||
lastMode = 0, smallDelay = 0, sPos = 0, screenshotIndex = 0, sSize = 0, zoom = 0, scrollIndex = 0, queueIndex = 0;
|
||||
|
||||
SortType sorttype = SortType::LAST_UPDATED;
|
||||
|
||||
/* Titre, Auteur, Catégorie, Console. */
|
||||
std::vector<bool> searchIncludes = { false, false, false, false };
|
||||
std::string searchResult = "", screenshotName = "";
|
||||
|
||||
C2D_Image Screenshot = { nullptr, nullptr };
|
||||
};
|
||||
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#ifndef _DARKSTORE_MAIN_SCREEN_HPP
|
||||
#define _DARKSTORE_MAIN_SCREEN_HPP
|
||||
|
||||
#include "common.hpp"
|
||||
#include "store.hpp"
|
||||
#include "storeEntry.hpp"
|
||||
#include "storeUtils.hpp"
|
||||
|
||||
/*
|
||||
Modes:
|
||||
|
||||
0: Entry Info.
|
||||
1: Download List.
|
||||
2: Queue.
|
||||
3: Search + Favorites.
|
||||
4: Sorting.
|
||||
5: Settings / Credits(?).
|
||||
6: Screenshot Menu.
|
||||
7: Release Notes.
|
||||
*/
|
||||
|
||||
class MainScreen : public Screen {
|
||||
public:
|
||||
MainScreen();
|
||||
void Draw(void) const override;
|
||||
void Logic(u32 hDown, u32 hHeld, touchPosition touch) override;
|
||||
private:
|
||||
std::unique_ptr<Store> store = nullptr;
|
||||
std::unique_ptr<Meta> meta = nullptr;
|
||||
std::vector<std::unique_ptr<StoreEntry>> entries;
|
||||
std::vector<std::string> dwnldList, dwnldSizes;
|
||||
|
||||
bool initialized = false, fetchDown = false, showMarks = false, showSettings = false,
|
||||
ascending = false, updateFilter = false, screenshotFetch = false, canDisplay = false;
|
||||
|
||||
int storeMode = 0, marks = 0, markIndex = 0, sPage = 0, lMode = 0, sSelection = 0,
|
||||
lastMode = 0, smallDelay = 0, sPos = 0, screenshotIndex = 0, sSize = 0, zoom = 0, scrollIndex = 0, queueIndex = 0;
|
||||
|
||||
SortType sorttype = SortType::LAST_UPDATED;
|
||||
|
||||
/* Titre, Auteur, Catégorie, Console. */
|
||||
std::vector<bool> searchIncludes = { false, false, false, false };
|
||||
std::string searchResult = "", screenshotName = "";
|
||||
|
||||
C2D_Image Screenshot = { nullptr, nullptr };
|
||||
};
|
||||
|
||||
#endif
|
||||
+63
-63
@@ -1,64 +1,64 @@
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#ifndef _GHOST_ESHOP_META_HPP
|
||||
#define _GHOST_ESHOP_META_HPP
|
||||
|
||||
#include "json.hpp"
|
||||
#include <string>
|
||||
|
||||
enum favoriteMarks {
|
||||
STAR = 1 << 0,
|
||||
HEART = 1 << 1,
|
||||
DIAMOND = 1 << 2,
|
||||
CLUBS = 1 << 3,
|
||||
SPADE = 1 << 4
|
||||
};
|
||||
|
||||
class Meta {
|
||||
public:
|
||||
Meta();
|
||||
~Meta() { this->SaveCall(); };
|
||||
|
||||
std::string GetUpdated(const std::string &EshopName, const std::string &entry) const;
|
||||
int GetMarks(const std::string &EshopName, const std::string &entry) const;
|
||||
bool UpdateAvailable(const std::string &EshopName, const std::string &entry, const std::string &updated) const;
|
||||
|
||||
void SetUpdated(const std::string &EshopName, const std::string &entry, const std::string &updated) {
|
||||
this->metadataJson[EshopName][entry]["updated"] = updated;
|
||||
};
|
||||
|
||||
void SetMarks(const std::string &EshopName, const std::string &entry, int marks) {
|
||||
this->metadataJson[EshopName][entry]["marks"] = marks;
|
||||
};
|
||||
|
||||
void ImportMetadata();
|
||||
void SaveCall();
|
||||
private:
|
||||
nlohmann::json metadataJson = nullptr;
|
||||
};
|
||||
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#ifndef _DARKSTORE_META_HPP
|
||||
#define _DARKSTORE_META_HPP
|
||||
|
||||
#include "json.hpp"
|
||||
#include <string>
|
||||
|
||||
enum favoriteMarks {
|
||||
STAR = 1 << 0,
|
||||
HEART = 1 << 1,
|
||||
DIAMOND = 1 << 2,
|
||||
CLUBS = 1 << 3,
|
||||
SPADE = 1 << 4
|
||||
};
|
||||
|
||||
class Meta {
|
||||
public:
|
||||
Meta();
|
||||
~Meta() { this->SaveCall(); };
|
||||
|
||||
std::string GetUpdated(const std::string &EshopName, const std::string &entry) const;
|
||||
int GetMarks(const std::string &EshopName, const std::string &entry) const;
|
||||
bool UpdateAvailable(const std::string &EshopName, const std::string &entry, const std::string &updated) const;
|
||||
|
||||
void SetUpdated(const std::string &EshopName, const std::string &entry, const std::string &updated) {
|
||||
this->metadataJson[EshopName][entry]["updated"] = updated;
|
||||
};
|
||||
|
||||
void SetMarks(const std::string &EshopName, const std::string &entry, int marks) {
|
||||
this->metadataJson[EshopName][entry]["marks"] = marks;
|
||||
};
|
||||
|
||||
void ImportMetadata();
|
||||
void SaveCall();
|
||||
private:
|
||||
nlohmann::json metadataJson = nullptr;
|
||||
};
|
||||
|
||||
#endif
|
||||
+100
-100
@@ -1,101 +1,101 @@
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#ifndef _GHOST_ESHOP_STORE_HPP
|
||||
#define _GHOST_ESHOP_STORE_HPP
|
||||
|
||||
#include "json.hpp"
|
||||
#include <citro2d.h>
|
||||
#include <string>
|
||||
|
||||
class Store {
|
||||
public:
|
||||
Store(const std::string &file, const std::string &file2, bool ARGMode = false);
|
||||
~Store();
|
||||
void LoadFromFile(const std::string &file);
|
||||
void loadSheets();
|
||||
void unloadSheets();
|
||||
void update(const std::string &file);
|
||||
|
||||
/* Obtenir des informations sur l’eShop lui-même. */
|
||||
std::string GetEshopTitle() const;
|
||||
std::string GetEshopAuthor() const;
|
||||
|
||||
/* Obtenir des informations sur les entrées eShop. */
|
||||
std::string GetTitleEntry(int index) const;
|
||||
std::string GetAuthorEntry(int index) const;
|
||||
std::string GetDescriptionEntry(int index) const;
|
||||
std::vector<std::string> GetCategoryIndex(int index) const;
|
||||
std::string GetVersionEntry(int index) const;
|
||||
std::vector<std::string> GetConsoleEntry(int index) const;
|
||||
std::string GetLastUpdatedEntry(int index) const;
|
||||
std::string GetSizeEntry(int index) const;
|
||||
std::string GetAdditionalcontentEntry(int index) const;
|
||||
C2D_Image GetIconEntry(int index) const;
|
||||
std::string GetFileSizes(int index, const std::string &entry) const;
|
||||
std::vector<std::string> GetScreenshotList(int index) const;
|
||||
std::vector<std::string> GetScreenshotNames(int index) const;
|
||||
std::string GetReleaseNotes(int index) const;
|
||||
|
||||
std::vector<std::string> GetDownloadList(int index) const;
|
||||
|
||||
int GetStoreSize() const { return (int)this->storeJson["storeContent"].size(); };
|
||||
|
||||
int GetScreenIndx() const { return this->screenIndex; };
|
||||
void SetScreenIndx(int v) { this->screenIndex = v; };
|
||||
|
||||
int GetEntry() const { return this->entry; };
|
||||
void SetEntry(int v) { this->entry = v; };
|
||||
|
||||
int GetBox() const { return this->box; };
|
||||
void SetBox(int v) { this->box = v; };
|
||||
|
||||
int GetDownloadSIndex() const { return this->downIndex; };
|
||||
void SetDownloadSIndex(int v) { this->downIndex = v; };
|
||||
|
||||
int GetDownloadIndex() const { return this->downEntry; };
|
||||
void SetDownloadIndex(int v) { this->downEntry = v; };
|
||||
|
||||
nlohmann::json &GetJson() { return this->storeJson; };
|
||||
bool GetValid() const { return this->valid; };
|
||||
|
||||
/* Ces deux choses sont utilisées pour le support BG personnalisé. */
|
||||
C2D_Image GetStoreImg() const { return this->storeBG; };
|
||||
bool customBG() const { return this->hasCustomBG; };
|
||||
|
||||
/* Renvoie le nom du fichier eShop. */
|
||||
std::string GetFileName() const { return this->fileName; };
|
||||
private:
|
||||
void SetC2DBGImage();
|
||||
nlohmann::json storeJson = nullptr;
|
||||
std::vector<C2D_SpriteSheet> sheets;
|
||||
C2D_Image storeBG = { nullptr };
|
||||
bool valid = false, hasSheet = false, hasCustomBG = false;
|
||||
int screenIndex = 0, entry = 0, box = 0, downEntry = 0, downIndex = 0;
|
||||
std::string fileName = "";
|
||||
};
|
||||
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#ifndef _DARKSTORE_STORE_HPP
|
||||
#define _DARKSTORE_STORE_HPP
|
||||
|
||||
#include "json.hpp"
|
||||
#include <citro2d.h>
|
||||
#include <string>
|
||||
|
||||
class Store {
|
||||
public:
|
||||
Store(const std::string &file, const std::string &file2, bool ARGMode = false);
|
||||
~Store();
|
||||
void LoadFromFile(const std::string &file);
|
||||
void loadSheets();
|
||||
void unloadSheets();
|
||||
void update(const std::string &file);
|
||||
|
||||
/* Obtenir des informations sur l’eShop lui-même. */
|
||||
std::string GetEshopTitle() const;
|
||||
std::string GetEshopAuthor() const;
|
||||
|
||||
/* Obtenir des informations sur les entrées eShop. */
|
||||
std::string GetTitleEntry(int index) const;
|
||||
std::string GetAuthorEntry(int index) const;
|
||||
std::string GetDescriptionEntry(int index) const;
|
||||
std::vector<std::string> GetCategoryIndex(int index) const;
|
||||
std::string GetVersionEntry(int index) const;
|
||||
std::vector<std::string> GetConsoleEntry(int index) const;
|
||||
std::string GetLastUpdatedEntry(int index) const;
|
||||
std::string GetSizeEntry(int index) const;
|
||||
std::string GetAdditionalcontentEntry(int index) const;
|
||||
C2D_Image GetIconEntry(int index) const;
|
||||
std::string GetFileSizes(int index, const std::string &entry) const;
|
||||
std::vector<std::string> GetScreenshotList(int index) const;
|
||||
std::vector<std::string> GetScreenshotNames(int index) const;
|
||||
std::string GetReleaseNotes(int index) const;
|
||||
|
||||
std::vector<std::string> GetDownloadList(int index) const;
|
||||
|
||||
int GetStoreSize() const { return (int)this->storeJson["storeContent"].size(); };
|
||||
|
||||
int GetScreenIndx() const { return this->screenIndex; };
|
||||
void SetScreenIndx(int v) { this->screenIndex = v; };
|
||||
|
||||
int GetEntry() const { return this->entry; };
|
||||
void SetEntry(int v) { this->entry = v; };
|
||||
|
||||
int GetBox() const { return this->box; };
|
||||
void SetBox(int v) { this->box = v; };
|
||||
|
||||
int GetDownloadSIndex() const { return this->downIndex; };
|
||||
void SetDownloadSIndex(int v) { this->downIndex = v; };
|
||||
|
||||
int GetDownloadIndex() const { return this->downEntry; };
|
||||
void SetDownloadIndex(int v) { this->downEntry = v; };
|
||||
|
||||
nlohmann::json &GetJson() { return this->storeJson; };
|
||||
bool GetValid() const { return this->valid; };
|
||||
|
||||
/* Ces deux choses sont utilisées pour le support BG personnalisé. */
|
||||
C2D_Image GetStoreImg() const { return this->storeBG; };
|
||||
bool customBG() const { return this->hasCustomBG; };
|
||||
|
||||
/* Renvoie le nom du fichier eShop. */
|
||||
std::string GetFileName() const { return this->fileName; };
|
||||
private:
|
||||
void SetC2DBGImage();
|
||||
nlohmann::json storeJson = nullptr;
|
||||
std::vector<C2D_SpriteSheet> sheets;
|
||||
C2D_Image storeBG = { nullptr };
|
||||
bool valid = false, hasSheet = false, hasCustomBG = false;
|
||||
int screenIndex = 0, entry = 0, box = 0, downEntry = 0, downIndex = 0;
|
||||
std::string fileName = "";
|
||||
};
|
||||
|
||||
#endif
|
||||
@@ -1,77 +1,77 @@
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#ifndef _GHOST_ESHOP_STORE_ENTRY_HPP
|
||||
#define _GHOST_ESHOP_STORE_ENTRY_HPP
|
||||
|
||||
#include "meta.hpp"
|
||||
#include "store.hpp"
|
||||
#include "stringutils.hpp"
|
||||
|
||||
class StoreEntry {
|
||||
public:
|
||||
StoreEntry(const std::unique_ptr<Store> &store, const std::unique_ptr<Meta> &meta, int index);
|
||||
|
||||
std::string GetTitle() const { return this->Title; };
|
||||
std::string GetAuthor() const { return this->Author; };
|
||||
std::string GetDescription() const { return this->Description; };
|
||||
std::string GetCategory() const { return this->Category; };
|
||||
std::string GetVersion() const { return this->Version; };
|
||||
std::string GetConsole() const { return this->Console; };
|
||||
std::string GetLastUpdated() const { return this->LastUpdated; };
|
||||
std::string GetSize() const { return this->Size; };
|
||||
std::string GetAdditionalcontent() const { return this->Additional; };
|
||||
int GetMarks() const { return this->Marks; };
|
||||
|
||||
C2D_Image GetIcon() const { return this->Icon; };
|
||||
|
||||
int GetSheetIndex() const { return this->SheetIndex; };
|
||||
int GetEntryIndex() const { return this->EntryIndex; };
|
||||
|
||||
std::vector<std::string> GetCategoryFull() const { return this->FullCategory; };
|
||||
std::vector<std::string> GetConsoleFull() const { return this->FullConsole; };
|
||||
std::vector<std::string> GetSizes() const { return this->Sizes; };
|
||||
std::vector<std::string> GetScreenshots() const { return this->Screenshots; };
|
||||
std::vector<std::string> GetScreenshotNames() const { return this->ScreenshotNames; };
|
||||
std::string GetReleaseNotes() const { return this->ReleaseNotes; };
|
||||
|
||||
bool GetUpdateAvl() const { return this->UpdateAvailable; };
|
||||
void SetUpdateAvl(bool v) { this->UpdateAvailable = v; };
|
||||
|
||||
void SetMark(int marks) {
|
||||
this->Marks = marks;
|
||||
this->MarkString = StringUtils::GetMarkString(this->Marks);
|
||||
};
|
||||
|
||||
private:
|
||||
std::string Title, Author, Description, Category, Version, Console, LastUpdated, Size, MarkString, Additional, ReleaseNotes;
|
||||
C2D_Image Icon;
|
||||
int SheetIndex, EntryIndex, Marks;
|
||||
std::vector<std::string> FullCategory, FullConsole, Sizes, Screenshots, ScreenshotNames;
|
||||
bool UpdateAvailable;
|
||||
};
|
||||
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#ifndef _DARKSTORE_STORE_ENTRY_HPP
|
||||
#define _DARKSTORE_STORE_ENTRY_HPP
|
||||
|
||||
#include "meta.hpp"
|
||||
#include "store.hpp"
|
||||
#include "stringutils.hpp"
|
||||
|
||||
class StoreEntry {
|
||||
public:
|
||||
StoreEntry(const std::unique_ptr<Store> &store, const std::unique_ptr<Meta> &meta, int index);
|
||||
|
||||
std::string GetTitle() const { return this->Title; };
|
||||
std::string GetAuthor() const { return this->Author; };
|
||||
std::string GetDescription() const { return this->Description; };
|
||||
std::string GetCategory() const { return this->Category; };
|
||||
std::string GetVersion() const { return this->Version; };
|
||||
std::string GetConsole() const { return this->Console; };
|
||||
std::string GetLastUpdated() const { return this->LastUpdated; };
|
||||
std::string GetSize() const { return this->Size; };
|
||||
std::string GetAdditionalcontent() const { return this->Additional; };
|
||||
int GetMarks() const { return this->Marks; };
|
||||
|
||||
C2D_Image GetIcon() const { return this->Icon; };
|
||||
|
||||
int GetSheetIndex() const { return this->SheetIndex; };
|
||||
int GetEntryIndex() const { return this->EntryIndex; };
|
||||
|
||||
std::vector<std::string> GetCategoryFull() const { return this->FullCategory; };
|
||||
std::vector<std::string> GetConsoleFull() const { return this->FullConsole; };
|
||||
std::vector<std::string> GetSizes() const { return this->Sizes; };
|
||||
std::vector<std::string> GetScreenshots() const { return this->Screenshots; };
|
||||
std::vector<std::string> GetScreenshotNames() const { return this->ScreenshotNames; };
|
||||
std::string GetReleaseNotes() const { return this->ReleaseNotes; };
|
||||
|
||||
bool GetUpdateAvl() const { return this->UpdateAvailable; };
|
||||
void SetUpdateAvl(bool v) { this->UpdateAvailable = v; };
|
||||
|
||||
void SetMark(int marks) {
|
||||
this->Marks = marks;
|
||||
this->MarkString = StringUtils::GetMarkString(this->Marks);
|
||||
};
|
||||
|
||||
private:
|
||||
std::string Title, Author, Description, Category, Version, Console, LastUpdated, Size, MarkString, Additional, ReleaseNotes;
|
||||
C2D_Image Icon;
|
||||
int SheetIndex, EntryIndex, Marks;
|
||||
std::vector<std::string> FullCategory, FullConsole, Sizes, Screenshots, ScreenshotNames;
|
||||
bool UpdateAvailable;
|
||||
};
|
||||
|
||||
#endif
|
||||
+110
-110
@@ -1,111 +1,111 @@
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#ifndef _GHOST_ESHOP_STORE_UTILS_HPP
|
||||
#define _GHOST_ESHOP_STORE_UTILS_HPP
|
||||
|
||||
#include "common.hpp"
|
||||
#include "store.hpp"
|
||||
#include "storeEntry.hpp"
|
||||
#include <vector>
|
||||
|
||||
enum class SortType : uint8_t {
|
||||
TITLE,
|
||||
AUTHOR,
|
||||
LAST_UPDATED
|
||||
};
|
||||
|
||||
namespace StoreUtils {
|
||||
/* Grille. */
|
||||
void DrawGrid(const std::unique_ptr<Store> &store, const std::vector<std::unique_ptr<StoreEntry>> &entries);
|
||||
void GridLogic(std::unique_ptr<Store> &store, std::vector<std::unique_ptr<StoreEntry>> &entries, int ¤tMode, int &lastMode, bool &fetch, int &smallDelay);
|
||||
|
||||
/* Top Liste. */
|
||||
void DrawList(const std::unique_ptr<Store> &store, const std::vector<std::unique_ptr<StoreEntry>> &entries);
|
||||
void ListLogic(std::unique_ptr<Store> &store, std::vector<std::unique_ptr<StoreEntry>> &entries, int ¤tMode, int &lastMode, bool &fetch, int &smallDelay);
|
||||
|
||||
/* Infos Sur L'Entrée. */
|
||||
void DrawEntryInfo(const std::unique_ptr<Store> &store, const std::unique_ptr<StoreEntry> &entry);
|
||||
void EntryHandle(bool &showMark, bool &fetch, bool &sFetch, int &mode, const std::unique_ptr<StoreEntry> &entry);
|
||||
|
||||
/* Menu Latéral. */
|
||||
void DrawSideMenu(int currentMenu);
|
||||
void SideMenuHandle(int ¤tMenu, bool &fetch, int &lastMenu);
|
||||
|
||||
/* Entrées Des Téléchargements. */
|
||||
void DrawDownList(const std::unique_ptr<Store> &store, const std::vector<std::string> &entries, bool fetch, const std::unique_ptr<StoreEntry> &entry, const std::vector<std::string> &sizes);
|
||||
void DownloadHandle(const std::unique_ptr<Store> &store, const std::unique_ptr<StoreEntry> &entry, const std::vector<std::string> &entries, int ¤tMenu, std::unique_ptr<Meta> &meta, const int &lastMode, int &smallDelay);
|
||||
|
||||
/* Queue System. */
|
||||
void DrawQueueMenu(const int queueIndex);
|
||||
void QueueMenuHandle(int &queueIndex);
|
||||
|
||||
/* Recherche + Menu Favoris. */
|
||||
void DrawSearchMenu(const std::vector<bool> &searchIncludes, const std::string &searchResult, int marks, bool updateFilter);
|
||||
void SearchHandle(std::unique_ptr<Store> &store, std::vector<std::unique_ptr<StoreEntry>> &entries, std::vector<bool> &searchIncludes, std::unique_ptr<Meta> &meta, std::string &searchResult, int &marks, bool &updateFilter, bool ascending, SortType sorttype);
|
||||
|
||||
/* Menu Marquer. */
|
||||
void DisplayMarkBox(int marks);
|
||||
void MarkHandle(std::unique_ptr<StoreEntry> &entry, const std::unique_ptr<Store> &store, bool &showMark, std::unique_ptr<Meta> &meta);
|
||||
|
||||
/* Crédits. */
|
||||
void DrawCredits();
|
||||
|
||||
/* Screenshot menu. */
|
||||
void DrawScreenshotMenu(const C2D_Image &img, const int sIndex, const bool sFetch, const int screenshotSize, const std::string &name, const int zoom, const bool canDisplay);
|
||||
void ScreenshotMenu(C2D_Image &img, int &sIndex, bool &sFetch, int &storeMode, const int screenshotSize, int &zoom, bool &canDisplay);
|
||||
|
||||
/* Paramètres. */
|
||||
void DrawSettings(int page, int selection, int sPos);
|
||||
void SettingsHandle(int &page, bool &dspSettings, int &storeMode, int &selection, std::unique_ptr<Store> &store, std::vector<std::unique_ptr<StoreEntry>> &entries, std::unique_ptr<Meta> &meta, int &sPos);
|
||||
|
||||
/* Trie. */
|
||||
void DrawSorting(bool asc, SortType st);
|
||||
void SortHandle(std::unique_ptr<Store> &store, std::vector<std::unique_ptr<StoreEntry>> &entries, bool &asc, SortType &st);
|
||||
|
||||
/* Release Notes. */
|
||||
void DrawReleaseNotes(const int &scrollIndex, const std::unique_ptr<StoreEntry> &entry, const std::unique_ptr<Store> &store);
|
||||
void ReleaseNotesLogic(int &scrollIndex, int &storeMode);
|
||||
|
||||
bool compareTitleDescending(const std::unique_ptr<StoreEntry> &a, const std::unique_ptr<StoreEntry> &b);
|
||||
bool compareTitleAscending(const std::unique_ptr<StoreEntry> &a, const std::unique_ptr<StoreEntry> &b);
|
||||
|
||||
bool compareAuthorDescending(const std::unique_ptr<StoreEntry> &a, const std::unique_ptr<StoreEntry> &b);
|
||||
bool compareAuthorAscending(const std::unique_ptr<StoreEntry> &a, const std::unique_ptr<StoreEntry> &b);
|
||||
|
||||
bool compareUpdateDescending(const std::unique_ptr<StoreEntry> &a, const std::unique_ptr<StoreEntry> &b);
|
||||
bool compareUpdateAscending(const std::unique_ptr<StoreEntry> &a, const std::unique_ptr<StoreEntry> &b);
|
||||
|
||||
void SortEntries(bool Ascending, SortType sorttype, std::vector<std::unique_ptr<StoreEntry>> &entries);
|
||||
|
||||
void search(std::vector<std::unique_ptr<StoreEntry>> &entries, const std::string &query, bool title, bool author, bool category, bool console, int selectedMarks, bool updateAvl);
|
||||
|
||||
void FilterUpdateAvailable(std::vector<std::unique_ptr<StoreEntry>> &entries);
|
||||
|
||||
void ResetAll(const std::unique_ptr<Store> &store, const std::unique_ptr<Meta> &meta, std::vector<std::unique_ptr<StoreEntry>> &entries);
|
||||
};
|
||||
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#ifndef _DARKSTORE_STORE_UTILS_HPP
|
||||
#define _DARKSTORE_STORE_UTILS_HPP
|
||||
|
||||
#include "common.hpp"
|
||||
#include "store.hpp"
|
||||
#include "storeEntry.hpp"
|
||||
#include <vector>
|
||||
|
||||
enum class SortType : uint8_t {
|
||||
TITLE,
|
||||
AUTHOR,
|
||||
LAST_UPDATED
|
||||
};
|
||||
|
||||
namespace StoreUtils {
|
||||
/* Grille. */
|
||||
void DrawGrid(const std::unique_ptr<Store> &store, const std::vector<std::unique_ptr<StoreEntry>> &entries);
|
||||
void GridLogic(std::unique_ptr<Store> &store, std::vector<std::unique_ptr<StoreEntry>> &entries, int ¤tMode, int &lastMode, bool &fetch, int &smallDelay);
|
||||
|
||||
/* Top Liste. */
|
||||
void DrawList(const std::unique_ptr<Store> &store, const std::vector<std::unique_ptr<StoreEntry>> &entries);
|
||||
void ListLogic(std::unique_ptr<Store> &store, std::vector<std::unique_ptr<StoreEntry>> &entries, int ¤tMode, int &lastMode, bool &fetch, int &smallDelay);
|
||||
|
||||
/* Infos Sur L'Entrée. */
|
||||
void DrawEntryInfo(const std::unique_ptr<Store> &store, const std::unique_ptr<StoreEntry> &entry);
|
||||
void EntryHandle(bool &showMark, bool &fetch, bool &sFetch, int &mode, const std::unique_ptr<StoreEntry> &entry);
|
||||
|
||||
/* Menu Latéral. */
|
||||
void DrawSideMenu(int currentMenu);
|
||||
void SideMenuHandle(int ¤tMenu, bool &fetch, int &lastMenu);
|
||||
|
||||
/* Entrées Des Téléchargements. */
|
||||
void DrawDownList(const std::unique_ptr<Store> &store, const std::vector<std::string> &entries, bool fetch, const std::unique_ptr<StoreEntry> &entry, const std::vector<std::string> &sizes);
|
||||
void DownloadHandle(const std::unique_ptr<Store> &store, const std::unique_ptr<StoreEntry> &entry, const std::vector<std::string> &entries, int ¤tMenu, std::unique_ptr<Meta> &meta, const int &lastMode, int &smallDelay);
|
||||
|
||||
/* Queue System. */
|
||||
void DrawQueueMenu(const int queueIndex);
|
||||
void QueueMenuHandle(int &queueIndex);
|
||||
|
||||
/* Recherche + Menu Favoris. */
|
||||
void DrawSearchMenu(const std::vector<bool> &searchIncludes, const std::string &searchResult, int marks, bool updateFilter);
|
||||
void SearchHandle(std::unique_ptr<Store> &store, std::vector<std::unique_ptr<StoreEntry>> &entries, std::vector<bool> &searchIncludes, std::unique_ptr<Meta> &meta, std::string &searchResult, int &marks, bool &updateFilter, bool ascending, SortType sorttype);
|
||||
|
||||
/* Menu Marquer. */
|
||||
void DisplayMarkBox(int marks);
|
||||
void MarkHandle(std::unique_ptr<StoreEntry> &entry, const std::unique_ptr<Store> &store, bool &showMark, std::unique_ptr<Meta> &meta);
|
||||
|
||||
/* Crédits. */
|
||||
void DrawCredits();
|
||||
|
||||
/* Screenshot menu. */
|
||||
void DrawScreenshotMenu(const C2D_Image &img, const int sIndex, const bool sFetch, const int screenshotSize, const std::string &name, const int zoom, const bool canDisplay);
|
||||
void ScreenshotMenu(C2D_Image &img, int &sIndex, bool &sFetch, int &storeMode, const int screenshotSize, int &zoom, bool &canDisplay);
|
||||
|
||||
/* Paramètres. */
|
||||
void DrawSettings(int page, int selection, int sPos);
|
||||
void SettingsHandle(int &page, bool &dspSettings, int &storeMode, int &selection, std::unique_ptr<Store> &store, std::vector<std::unique_ptr<StoreEntry>> &entries, std::unique_ptr<Meta> &meta, int &sPos);
|
||||
|
||||
/* Trie. */
|
||||
void DrawSorting(bool asc, SortType st);
|
||||
void SortHandle(std::unique_ptr<Store> &store, std::vector<std::unique_ptr<StoreEntry>> &entries, bool &asc, SortType &st);
|
||||
|
||||
/* Release Notes. */
|
||||
void DrawReleaseNotes(const int &scrollIndex, const std::unique_ptr<StoreEntry> &entry, const std::unique_ptr<Store> &store);
|
||||
void ReleaseNotesLogic(int &scrollIndex, int &storeMode);
|
||||
|
||||
bool compareTitleDescending(const std::unique_ptr<StoreEntry> &a, const std::unique_ptr<StoreEntry> &b);
|
||||
bool compareTitleAscending(const std::unique_ptr<StoreEntry> &a, const std::unique_ptr<StoreEntry> &b);
|
||||
|
||||
bool compareAuthorDescending(const std::unique_ptr<StoreEntry> &a, const std::unique_ptr<StoreEntry> &b);
|
||||
bool compareAuthorAscending(const std::unique_ptr<StoreEntry> &a, const std::unique_ptr<StoreEntry> &b);
|
||||
|
||||
bool compareUpdateDescending(const std::unique_ptr<StoreEntry> &a, const std::unique_ptr<StoreEntry> &b);
|
||||
bool compareUpdateAscending(const std::unique_ptr<StoreEntry> &a, const std::unique_ptr<StoreEntry> &b);
|
||||
|
||||
void SortEntries(bool Ascending, SortType sorttype, std::vector<std::unique_ptr<StoreEntry>> &entries);
|
||||
|
||||
void search(std::vector<std::unique_ptr<StoreEntry>> &entries, const std::string &query, bool title, bool author, bool category, bool console, int selectedMarks, bool updateAvl);
|
||||
|
||||
void FilterUpdateAvailable(std::vector<std::unique_ptr<StoreEntry>> &entries);
|
||||
|
||||
void ResetAll(const std::unique_ptr<Store> &store, const std::unique_ptr<Meta> &meta, std::vector<std::unique_ptr<StoreEntry>> &entries);
|
||||
};
|
||||
|
||||
#endif
|
||||
+47
-47
@@ -1,48 +1,48 @@
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#ifndef _GHOST_ESHOP_ANIMATION_HPP
|
||||
#define _GHOST_ESHOP_ANIMATION_HPP
|
||||
|
||||
#include <3ds.h>
|
||||
#include <string>
|
||||
|
||||
enum class ProgressBar {
|
||||
Downloading,
|
||||
Extracting,
|
||||
Installing,
|
||||
Copying
|
||||
};
|
||||
|
||||
namespace Animation {
|
||||
void DrawProgressBar(u64 currentProgress, u64 totalProgress);
|
||||
void displayProgressBar();
|
||||
|
||||
void DrawQueue(int x, int y);
|
||||
void QueueAnimHandle();
|
||||
};
|
||||
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#ifndef _DARKSTORE_ANIMATION_HPP
|
||||
#define _DARKSTORE_ANIMATION_HPP
|
||||
|
||||
#include <3ds.h>
|
||||
#include <string>
|
||||
|
||||
enum class ProgressBar {
|
||||
Downloading,
|
||||
Extracting,
|
||||
Installing,
|
||||
Copying
|
||||
};
|
||||
|
||||
namespace Animation {
|
||||
void DrawProgressBar(u64 currentProgress, u64 totalProgress);
|
||||
void displayProgressBar();
|
||||
|
||||
void DrawQueue(int x, int y);
|
||||
void QueueAnimHandle();
|
||||
};
|
||||
|
||||
#endif
|
||||
@@ -1,47 +1,47 @@
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#ifndef _GHOST_ESHOP_ARGUMENT_PARSER_HPP
|
||||
#define _GHOST_ESHOP_ARGUMENT_PARSER_HPP
|
||||
|
||||
#include "json.hpp"
|
||||
#include "store.hpp"
|
||||
#include <string>
|
||||
|
||||
class ArgumentParser {
|
||||
public:
|
||||
ArgumentParser(const std::string &file, const std::string &entry, int dlIndex);
|
||||
void Load();
|
||||
void Execute();
|
||||
bool GetValid() const { return this->isValid; };
|
||||
private:
|
||||
std::unique_ptr<Store> store = nullptr;
|
||||
bool isValid = false;
|
||||
std::string file = "", executeEntry = "", entry = "";
|
||||
int dlIndex = -1, entryIndex = -1;
|
||||
};
|
||||
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#ifndef _DARKSTORE_ARGUMENT_PARSER_HPP
|
||||
#define _DARKSTORE_ARGUMENT_PARSER_HPP
|
||||
|
||||
#include "json.hpp"
|
||||
#include "store.hpp"
|
||||
#include <string>
|
||||
|
||||
class ArgumentParser {
|
||||
public:
|
||||
ArgumentParser(const std::string &file, const std::string &entry, int dlIndex);
|
||||
void Load();
|
||||
void Execute();
|
||||
bool GetValid() const { return this->isValid; };
|
||||
private:
|
||||
std::unique_ptr<Store> store = nullptr;
|
||||
bool isValid = false;
|
||||
std::string file = "", executeEntry = "", entry = "";
|
||||
int dlIndex = -1, entryIndex = -1;
|
||||
};
|
||||
|
||||
#endif
|
||||
+39
-39
@@ -1,40 +1,40 @@
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#ifndef _GHOST_ESHOP_CIA_HPP
|
||||
#define _GHOST_ESHOP_CIA_HPP
|
||||
|
||||
#include "common.hpp"
|
||||
|
||||
#include <3ds.h>
|
||||
|
||||
namespace Title {
|
||||
Result Launch(u64 titleId, FS_MediaType mediaType);
|
||||
Result DeletePrevious(u64 titleid, FS_MediaType media);
|
||||
Result Install(const char *ciaPath, bool updateSelf);
|
||||
};
|
||||
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#ifndef _DARKSTORE_CIA_HPP
|
||||
#define _DARKSTORE_CIA_HPP
|
||||
|
||||
#include "common.hpp"
|
||||
|
||||
#include <3ds.h>
|
||||
|
||||
namespace Title {
|
||||
Result Launch(u64 titleId, FS_MediaType mediaType);
|
||||
Result DeletePrevious(u64 titleid, FS_MediaType media);
|
||||
Result Install(const char *ciaPath, bool updateSelf);
|
||||
};
|
||||
|
||||
#endif
|
||||
+110
-110
@@ -1,110 +1,110 @@
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#ifndef _GHOST_ESHOP_CONFIG_HPP
|
||||
#define _GHOST_ESHOP_CONFIG_HPP
|
||||
|
||||
#include "json.hpp"
|
||||
|
||||
#include <3ds.h>
|
||||
#include <string>
|
||||
|
||||
class Config {
|
||||
public:
|
||||
Config();
|
||||
void save();
|
||||
void initialize();
|
||||
void sysLang();
|
||||
|
||||
/* Language. */
|
||||
std::string language() const { return this->v_language; };
|
||||
void language(const std::string &v) { this->v_language = v; if (!this->changesMade) this->changesMade = true; };
|
||||
|
||||
/* Dernier Magasin. */
|
||||
std::string lastStore() const { return this->v_lastStore; };
|
||||
void lastStore(const std::string &v) { this->v_lastStore = v; if (!this->changesMade) this->changesMade = true; };
|
||||
|
||||
/* Utilisation De La Liste Supérieure. */
|
||||
bool list() const { return this->v_list; };
|
||||
void list(bool v) { this->v_list = v; if (!this->changesMade) this->changesMade = true; };
|
||||
|
||||
/* Mise à Jour Automatique Au Démarrage. */
|
||||
bool autoupdate() const { return this->v_autoUpdate; };
|
||||
void autoupdate(bool v) { this->v_autoUpdate = v; if (!this->changesMade) this->changesMade = true; };
|
||||
|
||||
std::string _3dsxPath() const { return this->v_3dsxPath; };
|
||||
void _3dsxPath(const std::string &v) { this->v_3dsxPath = v; if (!this->changesMade) this->changesMade = true; };
|
||||
|
||||
std::string ndsPath() const { return this->v_ndsPath; };
|
||||
void ndsPath(const std::string &v) { this->v_ndsPath = v; if (!this->changesMade) this->changesMade = true; };
|
||||
|
||||
std::string archPath() const { return this->v_archivePath; };
|
||||
void archPath(const std::string &v) { this->v_archivePath = v; if (!this->changesMade) this->changesMade = true; };
|
||||
|
||||
/* Récupération d'anciennes métadonnées. */
|
||||
bool metadata() const { return this->v_metadata; };
|
||||
void metadata(bool v) { this->v_metadata = v; if (!this->changesMade) this->changesMade = true; };
|
||||
|
||||
/* Vérification des Mises à Jour de DarkStore au Démarrage. */
|
||||
bool updatecheck() const { return this->v_updateCheck; };
|
||||
void updatecheck(bool v) { this->v_updateCheck = v; if (!this->changesMade) this->changesMade = true; };
|
||||
|
||||
/* Vérification des Mises à Jour de DarkStore au Démarrage. */
|
||||
bool usebg() const { return this->v_showBg; };
|
||||
void usebg(bool v) { this->v_showBg = v; if (!this->changesMade) this->changesMade = true; };
|
||||
|
||||
/* Si vous utilisez une police personnalisée. */
|
||||
bool customfont() const { return this->v_customFont; };
|
||||
void customfont(bool v) { this->v_customFont = v; if (!this->changesMade) this->changesMade = true; };
|
||||
|
||||
/* Le chemin du raccourci. */
|
||||
std::string shortcut() const { return this->v_shortcutPath; };
|
||||
void shortcut(const std::string &v) { this->v_shortcutPath = v; if (!this->changesMade) this->changesMade = true; };
|
||||
|
||||
/* If displaying changelog. */
|
||||
bool changelog() const { return this->v_changelog; };
|
||||
void changelog(bool v) { this->v_changelog = v; if (!this->changesMade) this->changesMade = true; };
|
||||
private:
|
||||
/* Principalement aide. */
|
||||
bool getBool(const std::string &key);
|
||||
void setBool(const std::string &key, bool v);
|
||||
int getInt(const std::string &key);
|
||||
void setInt(const std::string &key, int v);
|
||||
std::string getString(const std::string &key);
|
||||
void setString(const std::string &key, const std::string &v);
|
||||
|
||||
nlohmann::json json;
|
||||
bool changesMade = false;
|
||||
|
||||
std::string v_language = "en", v_lastStore = "darkstore-homebrew.eshop",
|
||||
v_3dsxPath = "sdmc:/3ds", v_ndsPath = "sdmc:", v_archivePath = "sdmc:",
|
||||
v_shortcutPath = "sdmc:/3ds/DarkStore/shortcuts";
|
||||
|
||||
bool v_list = false, v_autoUpdate = true, v_metadata = true, v_updateCheck = true,
|
||||
v_showBg = false, v_customFont = false, v_changelog = true;
|
||||
};
|
||||
|
||||
#endif
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#ifndef _DARKSTORE_CONFIG_HPP
|
||||
#define _DARKSTORE_CONFIG_HPP
|
||||
|
||||
#include "json.hpp"
|
||||
|
||||
#include <3ds.h>
|
||||
#include <string>
|
||||
|
||||
class Config {
|
||||
public:
|
||||
Config();
|
||||
void save();
|
||||
void initialize();
|
||||
void sysLang();
|
||||
|
||||
/* Language. */
|
||||
std::string language() const { return this->v_language; };
|
||||
void language(const std::string &v) { this->v_language = v; if (!this->changesMade) this->changesMade = true; };
|
||||
|
||||
/* Dernier Magasin. */
|
||||
std::string lastStore() const { return this->v_lastStore; };
|
||||
void lastStore(const std::string &v) { this->v_lastStore = v; if (!this->changesMade) this->changesMade = true; };
|
||||
|
||||
/* Utilisation De La Liste Supérieure. */
|
||||
bool list() const { return this->v_list; };
|
||||
void list(bool v) { this->v_list = v; if (!this->changesMade) this->changesMade = true; };
|
||||
|
||||
/* Mise à Jour Automatique Au Démarrage. */
|
||||
bool autoupdate() const { return this->v_autoUpdate; };
|
||||
void autoupdate(bool v) { this->v_autoUpdate = v; if (!this->changesMade) this->changesMade = true; };
|
||||
|
||||
std::string _3dsxPath() const { return this->v_3dsxPath; };
|
||||
void _3dsxPath(const std::string &v) { this->v_3dsxPath = v; if (!this->changesMade) this->changesMade = true; };
|
||||
|
||||
std::string ndsPath() const { return this->v_ndsPath; };
|
||||
void ndsPath(const std::string &v) { this->v_ndsPath = v; if (!this->changesMade) this->changesMade = true; };
|
||||
|
||||
std::string archPath() const { return this->v_archivePath; };
|
||||
void archPath(const std::string &v) { this->v_archivePath = v; if (!this->changesMade) this->changesMade = true; };
|
||||
|
||||
/* Récupération d'anciennes métadonnées. */
|
||||
bool metadata() const { return this->v_metadata; };
|
||||
void metadata(bool v) { this->v_metadata = v; if (!this->changesMade) this->changesMade = true; };
|
||||
|
||||
/* Vérification des Mises à Jour de DarkStore au Démarrage. */
|
||||
bool updatecheck() const { return this->v_updateCheck; };
|
||||
void updatecheck(bool v) { this->v_updateCheck = v; if (!this->changesMade) this->changesMade = true; };
|
||||
|
||||
/* Vérification des Mises à Jour de DarkStore au Démarrage. */
|
||||
bool usebg() const { return this->v_showBg; };
|
||||
void usebg(bool v) { this->v_showBg = v; if (!this->changesMade) this->changesMade = true; };
|
||||
|
||||
/* Si vous utilisez une police personnalisée. */
|
||||
bool customfont() const { return this->v_customFont; };
|
||||
void customfont(bool v) { this->v_customFont = v; if (!this->changesMade) this->changesMade = true; };
|
||||
|
||||
/* Le chemin du raccourci. */
|
||||
std::string shortcut() const { return this->v_shortcutPath; };
|
||||
void shortcut(const std::string &v) { this->v_shortcutPath = v; if (!this->changesMade) this->changesMade = true; };
|
||||
|
||||
/* If displaying changelog. */
|
||||
bool changelog() const { return this->v_changelog; };
|
||||
void changelog(bool v) { this->v_changelog = v; if (!this->changesMade) this->changesMade = true; };
|
||||
private:
|
||||
/* Principalement aide. */
|
||||
bool getBool(const std::string &key);
|
||||
void setBool(const std::string &key, bool v);
|
||||
int getInt(const std::string &key);
|
||||
void setInt(const std::string &key, int v);
|
||||
std::string getString(const std::string &key);
|
||||
void setString(const std::string &key, const std::string &v);
|
||||
|
||||
nlohmann::json json;
|
||||
bool changesMade = false;
|
||||
|
||||
std::string v_language = "en", v_lastStore = "darkstore-homebrew.eshop",
|
||||
v_3dsxPath = "sdmc:/3ds", v_ndsPath = "sdmc:", v_archivePath = "sdmc:",
|
||||
v_shortcutPath = "sdmc:/3ds/DarkStore/shortcuts";
|
||||
|
||||
bool v_list = false, v_autoUpdate = true, v_metadata = true, v_updateCheck = true,
|
||||
v_showBg = false, v_customFont = false, v_changelog = true;
|
||||
};
|
||||
|
||||
#endif
|
||||
|
||||
+90
-90
@@ -1,90 +1,90 @@
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#ifndef _GHOST_ESHOP_DOWNLOAD_HPP
|
||||
#define _GHOST_ESHOP_DOWNLOAD_HPP
|
||||
|
||||
#include "common.hpp"
|
||||
|
||||
#define APP_TITLE "DarkStore"
|
||||
#define VERSION_STRING "12.0"
|
||||
|
||||
enum DownloadError {
|
||||
DL_ERROR_NONE = 0,
|
||||
DL_ERROR_WRITEFILE,
|
||||
DL_ERROR_ALLOC,
|
||||
DL_ERROR_STATUSCODE,
|
||||
DL_ERROR_GIT,
|
||||
DL_CANCEL, // Aucune idée si c’est nécessaire.
|
||||
};
|
||||
|
||||
struct StoreList {
|
||||
std::string Title;
|
||||
std::string Author;
|
||||
std::string URL;
|
||||
std::string Description;
|
||||
};
|
||||
|
||||
struct DSUpdate {
|
||||
bool Available = false;
|
||||
std::string Notes = "";
|
||||
std::string Version = "";
|
||||
};
|
||||
|
||||
Result downloadToFile(const std::string &url, const std::string &path);
|
||||
Result downloadFromRelease(const std::string &url, const std::string &asset, const std::string &path, bool includePrereleases);
|
||||
|
||||
/*
|
||||
Vérifiez l’état du Wi-Fi.
|
||||
@return True si le Wi-Fi est connecté ; false si non.
|
||||
*/
|
||||
bool checkWifiStatus(void);
|
||||
|
||||
/*
|
||||
Afficher "Veuillez vous connecter au Wi-Fi" pour 2s.
|
||||
*/
|
||||
void notConnectedMsg(void);
|
||||
|
||||
/*
|
||||
Affiche "Not Implemented Yet" pour 2s.
|
||||
*/
|
||||
void notImplemented(void);
|
||||
|
||||
/*
|
||||
Afficher le msg done.
|
||||
*/
|
||||
void doneMsg(void);
|
||||
|
||||
bool IsUpdateAvailable(const std::string &URL, int revCurrent);
|
||||
bool DownloadEshop(const std::string &URL, int currentRev, std::string &fl, bool isDownload = false, bool isUDB = false);
|
||||
bool DownloadSpriteSheet(const std::string &URL, const std::string &file);
|
||||
DSUpdate IsDSUpdateAvailable();
|
||||
void UpdateAction();
|
||||
std::vector<StoreList> FetchStores();
|
||||
C2D_Image FetchScreenshot(const std::string &URL);
|
||||
std::string GetChangelog();
|
||||
|
||||
#endif
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#ifndef _DARKSTORE_DOWNLOAD_HPP
|
||||
#define _DARKSTORE_DOWNLOAD_HPP
|
||||
|
||||
#include "common.hpp"
|
||||
|
||||
#define APP_TITLE "DarkStore"
|
||||
#define VERSION_STRING "12.0"
|
||||
|
||||
enum DownloadError {
|
||||
DL_ERROR_NONE = 0,
|
||||
DL_ERROR_WRITEFILE,
|
||||
DL_ERROR_ALLOC,
|
||||
DL_ERROR_STATUSCODE,
|
||||
DL_ERROR_GIT,
|
||||
DL_CANCEL, // Aucune idée si c’est nécessaire.
|
||||
};
|
||||
|
||||
struct StoreList {
|
||||
std::string Title;
|
||||
std::string Author;
|
||||
std::string URL;
|
||||
std::string Description;
|
||||
};
|
||||
|
||||
struct DSUpdate {
|
||||
bool Available = false;
|
||||
std::string Notes = "";
|
||||
std::string Version = "";
|
||||
};
|
||||
|
||||
Result downloadToFile(const std::string &url, const std::string &path);
|
||||
Result downloadFromRelease(const std::string &url, const std::string &asset, const std::string &path, bool includePrereleases);
|
||||
|
||||
/*
|
||||
Vérifiez l’état du Wi-Fi.
|
||||
@return True si le Wi-Fi est connecté ; false si non.
|
||||
*/
|
||||
bool checkWifiStatus(void);
|
||||
|
||||
/*
|
||||
Afficher "Veuillez vous connecter au Wi-Fi" pour 2s.
|
||||
*/
|
||||
void notConnectedMsg(void);
|
||||
|
||||
/*
|
||||
Affiche "Not Implemented Yet" pour 2s.
|
||||
*/
|
||||
void notImplemented(void);
|
||||
|
||||
/*
|
||||
Afficher le msg done.
|
||||
*/
|
||||
void doneMsg(void);
|
||||
|
||||
bool IsUpdateAvailable(const std::string &URL, int revCurrent);
|
||||
bool DownloadEshop(const std::string &URL, int currentRev, std::string &fl, bool isDownload = false, bool isUDB = false);
|
||||
bool DownloadSpriteSheet(const std::string &URL, const std::string &file);
|
||||
DSUpdate IsDSUpdateAvailable();
|
||||
void UpdateAction();
|
||||
std::vector<StoreList> FetchStores();
|
||||
C2D_Image FetchScreenshot(const std::string &URL);
|
||||
std::string GetChangelog();
|
||||
|
||||
#endif
|
||||
|
||||
+45
-45
@@ -1,46 +1,46 @@
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#ifndef _GHOST_ESHOP_EXTRACT_HPP
|
||||
#define _GHOST_ESHOP_EXTRACT_HPP
|
||||
|
||||
#include "common.hpp"
|
||||
|
||||
enum ExtractError {
|
||||
EXTRACT_ERROR_NONE = 0,
|
||||
EXTRACT_ERROR_ARCHIVE,
|
||||
EXTRACT_ERROR_ALLOC,
|
||||
EXTRACT_ERROR_FIND,
|
||||
EXTRACT_ERROR_READFILE,
|
||||
EXTRACT_ERROR_OPENFILE,
|
||||
EXTRACT_ERROR_WRITEFILE,
|
||||
};
|
||||
|
||||
Result getExtractedSize(const std::string &archivePath, const std::string &wantedFile);
|
||||
|
||||
Result extractArchive(const std::string &archivePath, const std::string &wantedFile, const std::string &outputPath);
|
||||
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#ifndef _DARKSTORE_EXTRACT_HPP
|
||||
#define _DARKSTORE_EXTRACT_HPP
|
||||
|
||||
#include "common.hpp"
|
||||
|
||||
enum ExtractError {
|
||||
EXTRACT_ERROR_NONE = 0,
|
||||
EXTRACT_ERROR_ARCHIVE,
|
||||
EXTRACT_ERROR_ALLOC,
|
||||
EXTRACT_ERROR_FIND,
|
||||
EXTRACT_ERROR_READFILE,
|
||||
EXTRACT_ERROR_OPENFILE,
|
||||
EXTRACT_ERROR_WRITEFILE,
|
||||
};
|
||||
|
||||
Result getExtractedSize(const std::string &archivePath, const std::string &wantedFile);
|
||||
|
||||
Result extractArchive(const std::string &archivePath, const std::string &wantedFile, const std::string &outputPath);
|
||||
|
||||
#endif
|
||||
@@ -1,66 +1,66 @@
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#ifndef _GHOST_ESHOP_FILE_BROWSE_HPP
|
||||
#define _GHOST_ESHOP_FILE_BROWSE_HPP
|
||||
|
||||
#include <dirent.h>
|
||||
#include <string>
|
||||
#include <sys/stat.h>
|
||||
#include <vector>
|
||||
|
||||
struct DirEntry {
|
||||
std::string name;
|
||||
std::string path;
|
||||
bool isDirectory;
|
||||
};
|
||||
|
||||
/*
|
||||
Information de la structure de l'eShop
|
||||
*/
|
||||
struct EshopInfo {
|
||||
std::string Title;
|
||||
std::string Author;
|
||||
std::string URL;
|
||||
std::string File; // Permet de vérifier si le fichier ne contient PAS de barre oblique.
|
||||
std::string FileName;
|
||||
std::string Description;
|
||||
int Version;
|
||||
int Revision;
|
||||
int StoreSize;
|
||||
};
|
||||
|
||||
bool nameEndsWith(const std::string &name, const std::vector<std::string> &extensionList);
|
||||
void getDirectoryContents(std::vector<DirEntry> &dirContents, const std::vector<std::string> &extensionList);
|
||||
void getDirectoryContents(std::vector<DirEntry> &dirContents);
|
||||
std::vector<std::string> getContents(const std::string &name, const std::vector<std::string> &extensionList);
|
||||
|
||||
std::vector<EshopInfo> GetEshopInfo(const std::string &path);
|
||||
|
||||
void dirCopy(DirEntry *entry, const char *destinationPath, const char *sourcePath);
|
||||
int fcopy(const char *sourcePath, const char *destinationPath);
|
||||
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#ifndef _DARKSTORE_FILE_BROWSE_HPP
|
||||
#define _DARKSTORE_FILE_BROWSE_HPP
|
||||
|
||||
#include <dirent.h>
|
||||
#include <string>
|
||||
#include <sys/stat.h>
|
||||
#include <vector>
|
||||
|
||||
struct DirEntry {
|
||||
std::string name;
|
||||
std::string path;
|
||||
bool isDirectory;
|
||||
};
|
||||
|
||||
/*
|
||||
Information de la structure de l'eShop
|
||||
*/
|
||||
struct EshopInfo {
|
||||
std::string Title;
|
||||
std::string Author;
|
||||
std::string URL;
|
||||
std::string File; // Permet de vérifier si le fichier ne contient PAS de barre oblique.
|
||||
std::string FileName;
|
||||
std::string Description;
|
||||
int Version;
|
||||
int Revision;
|
||||
int StoreSize;
|
||||
};
|
||||
|
||||
bool nameEndsWith(const std::string &name, const std::vector<std::string> &extensionList);
|
||||
void getDirectoryContents(std::vector<DirEntry> &dirContents, const std::vector<std::string> &extensionList);
|
||||
void getDirectoryContents(std::vector<DirEntry> &dirContents);
|
||||
std::vector<std::string> getContents(const std::string &name, const std::vector<std::string> &extensionList);
|
||||
|
||||
std::vector<EshopInfo> GetEshopInfo(const std::string &path);
|
||||
|
||||
void dirCopy(DirEntry *entry, const char *destinationPath, const char *sourcePath);
|
||||
int fcopy(const char *sourcePath, const char *destinationPath);
|
||||
|
||||
#endif
|
||||
+37
-37
@@ -1,38 +1,38 @@
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#ifndef _GHOST_ESHOP_FILES_HPP
|
||||
#define _GHOST_ESHOP_FILES_HPP
|
||||
|
||||
#include "common.hpp"
|
||||
|
||||
Result makeDirs(const char *path);
|
||||
Result openFile(Handle *fileHandle, const char *path, bool write);
|
||||
Result deleteFile(const char *path);
|
||||
Result removeDir(const char *path);
|
||||
Result removeDirRecursive(const char *path);
|
||||
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#ifndef _DARKSTORE_FILES_HPP
|
||||
#define _DARKSTORE_FILES_HPP
|
||||
|
||||
#include "common.hpp"
|
||||
|
||||
Result makeDirs(const char *path);
|
||||
Result openFile(Handle *fileHandle, const char *path, bool write);
|
||||
Result deleteFile(const char *path);
|
||||
Result removeDir(const char *path);
|
||||
Result removeDirRecursive(const char *path);
|
||||
|
||||
#endif
|
||||
+25473
-25473
File diff suppressed because it is too large
Load Diff
+37
-37
@@ -1,38 +1,38 @@
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#ifndef _GHOST_ESHOP_LANG_HPP
|
||||
#define _GHOST_ESHOP_LANG_HPP
|
||||
|
||||
#include "json.hpp"
|
||||
#include <string>
|
||||
|
||||
namespace Lang {
|
||||
std::string get(const std::string &key);
|
||||
void load(const std::string &lang);
|
||||
};
|
||||
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#ifndef _DARKSTORE_LANG_HPP
|
||||
#define _DARKSTORE_LANG_HPP
|
||||
|
||||
#include "json.hpp"
|
||||
#include <string>
|
||||
|
||||
namespace Lang {
|
||||
std::string get(const std::string &key);
|
||||
void load(const std::string &lang);
|
||||
};
|
||||
|
||||
#endif
|
||||
+2002
-2002
File diff suppressed because it is too large
Load Diff
@@ -1,68 +1,68 @@
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#ifndef _GHOST_ESHOP_QUEUE_SYSTEM_HPP
|
||||
#define _GHOST_ESHOP_QUEUE_SYSTEM_HPP
|
||||
|
||||
#include "json.hpp"
|
||||
#include <citro2d.h>
|
||||
#include <deque>
|
||||
#include <memory>
|
||||
|
||||
/*
|
||||
Extend this, if more statuses are neccessary.
|
||||
*/
|
||||
enum class QueueStatus {
|
||||
None,
|
||||
Downloading,
|
||||
Extracting,
|
||||
Installing,
|
||||
Failed,
|
||||
Done
|
||||
};
|
||||
|
||||
class Queue {
|
||||
public:
|
||||
Queue(nlohmann::json object, C2D_Image img, std::string name) : obj(object), icn(img), name(name) { };
|
||||
QueueStatus status = QueueStatus::None;
|
||||
nlohmann::json obj;
|
||||
C2D_Image icn;
|
||||
int total, current;
|
||||
std::string name = "";
|
||||
};
|
||||
|
||||
/*
|
||||
Of course also a namespace to that part, so we can do that in a Thread.
|
||||
*/
|
||||
namespace QueueSystem {
|
||||
void QueueHandle(); // Handles the Queue.
|
||||
void AddToQueue(nlohmann::json obj, C2D_Image icn, std::string name); // Adds to Queue.
|
||||
void ClearQueue(); // Clears the Queue.
|
||||
|
||||
extern LightLock lock;
|
||||
};
|
||||
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#ifndef _DARKSTORE_QUEUE_SYSTEM_HPP
|
||||
#define _DARKSTORE_QUEUE_SYSTEM_HPP
|
||||
|
||||
#include "json.hpp"
|
||||
#include <citro2d.h>
|
||||
#include <deque>
|
||||
#include <memory>
|
||||
|
||||
/*
|
||||
Extend this, if more statuses are neccessary.
|
||||
*/
|
||||
enum class QueueStatus {
|
||||
None,
|
||||
Downloading,
|
||||
Extracting,
|
||||
Installing,
|
||||
Failed,
|
||||
Done
|
||||
};
|
||||
|
||||
class Queue {
|
||||
public:
|
||||
Queue(nlohmann::json object, C2D_Image img, std::string name) : obj(object), icn(img), name(name) { };
|
||||
QueueStatus status = QueueStatus::None;
|
||||
nlohmann::json obj;
|
||||
C2D_Image icn;
|
||||
int total, current;
|
||||
std::string name = "";
|
||||
};
|
||||
|
||||
/*
|
||||
Of course also a namespace to that part, so we can do that in a Thread.
|
||||
*/
|
||||
namespace QueueSystem {
|
||||
void QueueHandle(); // Handles the Queue.
|
||||
void AddToQueue(nlohmann::json obj, C2D_Image icn, std::string name); // Adds to Queue.
|
||||
void ClearQueue(); // Clears the Queue.
|
||||
|
||||
extern LightLock lock;
|
||||
};
|
||||
|
||||
#endif
|
||||
@@ -1,39 +1,39 @@
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#ifndef _GHOST_ESHOP_SCREENSHOT_HPP
|
||||
#define _GHOST_ESHOP_SCREENSHOT_HPP
|
||||
|
||||
#include <citro2d.h>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
|
||||
namespace Screenshot {
|
||||
C2D_Image Convert(const std::string &filename);
|
||||
C2D_Image ConvertFromBuffer(const std::vector<u8> &buffer);
|
||||
};
|
||||
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#ifndef _DARKSTORE_SCREENSHOT_HPP
|
||||
#define _DARKSTORE_SCREENSHOT_HPP
|
||||
|
||||
#include <citro2d.h>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
|
||||
namespace Screenshot {
|
||||
C2D_Image Convert(const std::string &filename);
|
||||
C2D_Image ConvertFromBuffer(const std::vector<u8> &buffer);
|
||||
};
|
||||
|
||||
#endif
|
||||
@@ -1,60 +1,60 @@
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#ifndef _GHOST_ESHOP_SCRIPT_UTILS_HPP
|
||||
#define _GHOST_ESHOP_SCRIPT_UTILS_HPP
|
||||
|
||||
#include "json.hpp"
|
||||
#include <3ds.h>
|
||||
#include <string>
|
||||
|
||||
enum ScriptState {
|
||||
NONE = 0,
|
||||
FAILED_DOWNLOAD,
|
||||
SCRIPT_CANCELED,
|
||||
SYNTAX_ERROR,
|
||||
COPY_ERROR,
|
||||
MOVE_ERROR,
|
||||
DELETE_ERROR
|
||||
};
|
||||
|
||||
namespace ScriptUtils {
|
||||
bool matchPattern(const std::string &pattern, const std::string &tested);
|
||||
|
||||
Result removeFile(const std::string &file, const std::string &message);
|
||||
void bootTitle(const std::string &TitleID, bool isNAND, const std::string &message);
|
||||
Result prompt(const std::string &message);
|
||||
Result copyFile(const std::string &source, const std::string &destination, const std::string &message, bool isARG = false);
|
||||
Result renameFile(const std::string &oldName, const std::string &newName, const std::string &message);
|
||||
Result downloadRelease(const std::string &repo, const std::string &file, const std::string &output, bool includePrereleases, const std::string &message, bool isARG = false);
|
||||
Result downloadFile(const std::string &file, const std::string &output, const std::string &message, bool isARG = false);
|
||||
void installFile(const std::string &file, bool updatingSelf, const std::string &message, bool isARG = false);
|
||||
void extractFile(const std::string &file, const std::string &input, const std::string &output, const std::string &message, bool isARG = false);
|
||||
|
||||
Result runFunctions(nlohmann::json storeJson, int selection, const std::string &entry);
|
||||
};
|
||||
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#ifndef _DARKSTORE_SCRIPT_UTILS_HPP
|
||||
#define _DARKSTORE_SCRIPT_UTILS_HPP
|
||||
|
||||
#include "json.hpp"
|
||||
#include <3ds.h>
|
||||
#include <string>
|
||||
|
||||
enum ScriptState {
|
||||
NONE = 0,
|
||||
FAILED_DOWNLOAD,
|
||||
SCRIPT_CANCELED,
|
||||
SYNTAX_ERROR,
|
||||
COPY_ERROR,
|
||||
MOVE_ERROR,
|
||||
DELETE_ERROR
|
||||
};
|
||||
|
||||
namespace ScriptUtils {
|
||||
bool matchPattern(const std::string &pattern, const std::string &tested);
|
||||
|
||||
Result removeFile(const std::string &file, const std::string &message);
|
||||
void bootTitle(const std::string &TitleID, bool isNAND, const std::string &message);
|
||||
Result prompt(const std::string &message);
|
||||
Result copyFile(const std::string &source, const std::string &destination, const std::string &message, bool isARG = false);
|
||||
Result renameFile(const std::string &oldName, const std::string &newName, const std::string &message);
|
||||
Result downloadRelease(const std::string &repo, const std::string &file, const std::string &output, bool includePrereleases, const std::string &message, bool isARG = false);
|
||||
Result downloadFile(const std::string &file, const std::string &output, const std::string &message, bool isARG = false);
|
||||
void installFile(const std::string &file, bool updatingSelf, const std::string &message, bool isARG = false);
|
||||
void extractFile(const std::string &file, const std::string &input, const std::string &output, const std::string &message, bool isARG = false);
|
||||
|
||||
Result runFunctions(nlohmann::json storeJson, int selection, const std::string &entry);
|
||||
};
|
||||
|
||||
#endif
|
||||
+46
-46
@@ -1,47 +1,47 @@
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#ifndef _GHOST_ESHOP_SOUND_HPP
|
||||
#define _GHOST_ESHOP_SOUND_HPP
|
||||
|
||||
#include <3ds.h>
|
||||
#include <string>
|
||||
|
||||
class Sound {
|
||||
public:
|
||||
Sound(const std::string &path, const int channel = 1, const bool toloop = true);
|
||||
~Sound();
|
||||
void play();
|
||||
void stop();
|
||||
private:
|
||||
u32 dataSize;
|
||||
bool good = true;
|
||||
ndspWaveBuf waveBuf;
|
||||
u8 *data = nullptr;
|
||||
int chnl;
|
||||
};
|
||||
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#ifndef _DARKSTORE_SOUND_HPP
|
||||
#define _DARKSTORE_SOUND_HPP
|
||||
|
||||
#include <3ds.h>
|
||||
#include <string>
|
||||
|
||||
class Sound {
|
||||
public:
|
||||
Sound(const std::string &path, const int channel = 1, const bool toloop = true);
|
||||
~Sound();
|
||||
void play();
|
||||
void stop();
|
||||
private:
|
||||
u32 dataSize;
|
||||
bool good = true;
|
||||
ndspWaveBuf waveBuf;
|
||||
u8 *data = nullptr;
|
||||
int chnl;
|
||||
};
|
||||
|
||||
#endif
|
||||
@@ -1,42 +1,42 @@
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#ifndef _GHOST_ESHOP_STRING_UTILS_HPP
|
||||
#define _GHOST_ESHOP_STRING_UTILS_HPP
|
||||
|
||||
#include "meta.hpp"
|
||||
#include <string>
|
||||
#include <vector>
|
||||
|
||||
namespace StringUtils {
|
||||
std::string lower_case(const std::string &str);
|
||||
std::string FetchStringsFromVector(const std::vector<std::string> &fetch);
|
||||
std::string formatBytes(int bytes);
|
||||
std::string GetMarkString(int marks);
|
||||
std::vector<std::string> GetMarks(int marks);
|
||||
};
|
||||
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#ifndef _DARKSTORE_STRING_UTILS_HPP
|
||||
#define _DARKSTORE_STRING_UTILS_HPP
|
||||
|
||||
#include "meta.hpp"
|
||||
#include <string>
|
||||
#include <vector>
|
||||
|
||||
namespace StringUtils {
|
||||
std::string lower_case(const std::string &str);
|
||||
std::string FetchStringsFromVector(const std::vector<std::string> &fetch);
|
||||
std::string formatBytes(int bytes);
|
||||
std::string GetMarkString(int marks);
|
||||
std::vector<std::string> GetMarks(int marks);
|
||||
};
|
||||
|
||||
#endif
|
||||
+1204
-1204
File diff suppressed because it is too large
Load Diff
+721
-721
File diff suppressed because it is too large
Load Diff
+41
-41
@@ -1,41 +1,41 @@
|
||||
# libarchive.la - a libtool library file
|
||||
# Generated by libtool (GNU libtool) 2.4.6 Debian-2.4.6-14
|
||||
#
|
||||
# Please DO NOT delete this file!
|
||||
# It is necessary for linking the library.
|
||||
|
||||
# The name that we can dlopen(3).
|
||||
dlname=''
|
||||
|
||||
# Names of this library.
|
||||
library_names=''
|
||||
|
||||
# The name of the static archive.
|
||||
old_library='libarchive.a'
|
||||
|
||||
# Linker flags that cannot go in dependency_libs.
|
||||
inherited_linker_flags=''
|
||||
|
||||
# Libraries that this one depends upon.
|
||||
dependency_libs=' -L/opt/devkitpro/portlibs/3ds/lib -L/opt/devkitpro/libctru/lib /opt/devkitpro/portlibs/3ds/lib/liblzma.la -lbz2 -lz -lctru'
|
||||
|
||||
# Names of additional weak libraries provided by this library
|
||||
weak_library_names=''
|
||||
|
||||
# Version information for libarchive.
|
||||
current=18
|
||||
age=5
|
||||
revision=1
|
||||
|
||||
# Is this an already installed library?
|
||||
installed=yes
|
||||
|
||||
# Should we warn about portability when linking against -modules?
|
||||
shouldnotlink=no
|
||||
|
||||
# Files to dlopen/dlpreopen
|
||||
dlopen=''
|
||||
dlpreopen=''
|
||||
|
||||
# Directory that this library needs to be installed in:
|
||||
libdir='/opt/devkitpro/portlibs/3ds/lib'
|
||||
# libarchive.la - a libtool library file
|
||||
# Generated by libtool (GNU libtool) 2.4.6 Debian-2.4.6-14
|
||||
#
|
||||
# Please DO NOT delete this file!
|
||||
# It is necessary for linking the library.
|
||||
|
||||
# The name that we can dlopen(3).
|
||||
dlname=''
|
||||
|
||||
# Names of this library.
|
||||
library_names=''
|
||||
|
||||
# The name of the static archive.
|
||||
old_library='libarchive.a'
|
||||
|
||||
# Linker flags that cannot go in dependency_libs.
|
||||
inherited_linker_flags=''
|
||||
|
||||
# Libraries that this one depends upon.
|
||||
dependency_libs=' -L/opt/devkitpro/portlibs/3ds/lib -L/opt/devkitpro/libctru/lib /opt/devkitpro/portlibs/3ds/lib/liblzma.la -lbz2 -lz -lctru'
|
||||
|
||||
# Names of additional weak libraries provided by this library
|
||||
weak_library_names=''
|
||||
|
||||
# Version information for libarchive.
|
||||
current=18
|
||||
age=5
|
||||
revision=1
|
||||
|
||||
# Is this an already installed library?
|
||||
installed=yes
|
||||
|
||||
# Should we warn about portability when linking against -modules?
|
||||
shouldnotlink=no
|
||||
|
||||
# Files to dlopen/dlpreopen
|
||||
dlopen=''
|
||||
dlpreopen=''
|
||||
|
||||
# Directory that this library needs to be installed in:
|
||||
libdir='/opt/devkitpro/portlibs/3ds/lib'
|
||||
|
||||
@@ -1,12 +1,12 @@
|
||||
prefix=/opt/devkitpro/portlibs/3ds
|
||||
exec_prefix=${prefix}
|
||||
libdir=${exec_prefix}/lib
|
||||
includedir=${prefix}/include
|
||||
|
||||
Name: libarchive
|
||||
Description: library that can create and read several streaming archive formats
|
||||
Version: 3.5.1
|
||||
Cflags: -I${includedir}
|
||||
Cflags.private: -DLIBARCHIVE_STATIC
|
||||
Libs: -L${libdir} -larchive
|
||||
Libs.private: -llzma -lbz2 -lz -lctru
|
||||
prefix=/opt/devkitpro/portlibs/3ds
|
||||
exec_prefix=${prefix}
|
||||
libdir=${exec_prefix}/lib
|
||||
includedir=${prefix}/include
|
||||
|
||||
Name: libarchive
|
||||
Description: library that can create and read several streaming archive formats
|
||||
Version: 3.5.1
|
||||
Cflags: -I${includedir}
|
||||
Cflags.private: -DLIBARCHIVE_STATIC
|
||||
Libs: -L${libdir} -larchive
|
||||
Libs.private: -llzma -lbz2 -lz -lctru
|
||||
|
||||
+10
-10
@@ -1,10 +1,10 @@
|
||||
{
|
||||
"version": "v12.5",
|
||||
"name": "2021",
|
||||
"Author": "DarkStore Team",
|
||||
"files": ["DarkStore.cia", "DarkStore.3dsx", "DarkStore.smdh"],
|
||||
"Link": ["https://darkstore.ml/assets/DarkStore.cia", "https://darkstore.ml/assets/DarkStore.3dsx", "https://darkstore.ml/assets/DarkStore.smdh"],
|
||||
"changelog_en": "- Adding ScreenShot,\n- Update Translations,\n- Adding icon of games to the download menu",
|
||||
"changelog_es": "- Agregar captura de pantalla,\n- Actualizar traducciones,\n- Agregar ícono de juegos al menú de descarga",
|
||||
"changelog_fr": "- Ajout des captures d'écran,\n- Amélioration des traductions,\n- Ajout des icon des jeux dans le menu de téléchargement"
|
||||
}
|
||||
{
|
||||
"version": "v12.5",
|
||||
"name": "2021",
|
||||
"Author": "DarkStore Team",
|
||||
"files": ["DarkStore.cia", "DarkStore.3dsx", "DarkStore.smdh"],
|
||||
"Link": ["https://darkstore.ml/assets/DarkStore.cia", "https://darkstore.ml/assets/DarkStore.3dsx", "https://darkstore.ml/assets/DarkStore.smdh"],
|
||||
"changelog_en": "- Adding ScreenShot,\n- Update Translations,\n- Adding icon of games to the download menu",
|
||||
"changelog_es": "- Agregar captura de pantalla,\n- Actualizar traducciones,\n- Agregar ícono de juegos al menú de descarga",
|
||||
"changelog_fr": "- Ajout des captures d'écran,\n- Amélioration des traductions,\n- Ajout des icon des jeux dans le menu de téléchargement"
|
||||
}
|
||||
|
||||
@@ -1,124 +0,0 @@
|
||||
{
|
||||
"ARGUMENT_INVALID": "المتغير المستقل غير صحيح.\nبرجاء التحقق من ملف xml للمرافعات الصحيحة.",
|
||||
"ASCENDING": "تصاعدي",
|
||||
"AUTHOR": "المؤلف",
|
||||
"AUTO_UPDATE_ESHOP": "تحديث-آلي eShop",
|
||||
"AUTO_UPDATE_ESHOP_DESC": "وبهذا ، سيتم تحديث eShop آخر استخدام بطريقة آلية عند اطلاق صالون الشبح.",
|
||||
"AUTO_UPDATE_DS": "تحديث للشبح الآلي للتحديث الآلي",
|
||||
"AUTO_UPDATE_DS_DESC": "عند الاتاحة ، سيقوم الشبح eShop بالتحقق من التعديلات في كل مرة يتم فتحها.",
|
||||
"AUTO_UPDATE_SETTINGS": "محددات التحديث الآلي",
|
||||
"AUTO_UPDATE_SETTINGS_BTN": "محددات التحديث الآلي ...",
|
||||
"AVAILABLE_DOWNLOADS": "تحميلات متاحة",
|
||||
"BOOT_TITLE": "هل ترغب في بدء هذا العنوان ؟",
|
||||
"CATEGORY": "الفئة",
|
||||
"CHANGE_3DSX_PATH": "تغيير مسار 3DSX",
|
||||
"CHANGE_ARCHIVE_PATH": "تغيير مسار التخزين",
|
||||
"CHANGE_NDS_PATH": "تغيير مسار NDS",
|
||||
"CHANGE_SHORTCUT_PATH": "تغيير مسار المسار المختصر",
|
||||
"CHANGELOG": "التغيير",
|
||||
"CHECK_ESHOP_UPDATES": "جاري التحقق من تعديلات eShop ...",
|
||||
"CHECK_DS_UPDATES": "جاري التحقق من تحديث الشبح eShop ...",
|
||||
"CITRA_BIGN_ICON": "Citra & Nteninea للشارة",
|
||||
"CONFIRM_OR_CANCEL": "اضغط على مفتاح للتأكيد ، قم بالالغاء للالغاء.",
|
||||
"CONNECT_WIFI": "برجاء الاتصال الى WiFi.",
|
||||
"CONSOLE": "الشاشة الرئيسية",
|
||||
"CONTRIBUTOR_TRANSLATORS": "-كل المترجمون والمشاركين",
|
||||
"COPY_ERROR": "خطأ في النسخ !",
|
||||
"CREATE_SHORTCUT": "هل ترغب في تكوين مسار مختصر ؟",
|
||||
"CREDITS": "أرصدة دائنة",
|
||||
"CURRENT_VERSION": "النسخة الحالية : ",
|
||||
"CURRENTLY_EXTRACTING": "استخراج :\n",
|
||||
"CUSTOM_FONT": "استخدام طاقم طباعة مهيأ",
|
||||
"CUSTOM_FONT_DESC": "اذا تم اتاحته ، سيتم استخدام 'sdcm:/3ds/GhoteShShop/font.bcfnt' بدلا من طاقم طباعة النظام ، اذا تم ايجاده.",
|
||||
"DELETE_ERROR": "خطأ في الحذف !",
|
||||
"DELETE_PROMPT": "هل أنت متأكد من أنك تريد حذف هذا الدليل ؟",
|
||||
"DELETE_UNNEEDED_FILE": "جاري حذف ملف غير مطلوب ...",
|
||||
"DESCENDING": "تنازلي",
|
||||
"DIRECTION": "الاتجاه",
|
||||
"DIRECTORY_SETTINGS": "محددات الدليل",
|
||||
"DIRECTORY_SETTINGS_BTN": "محددات الدليل ...",
|
||||
"DISABLE_AUTOUPDATE_ESHOP": "الغاء اتاحة التحديث الآلي للتسلسل عند بدء التشغيل",
|
||||
"DISABLE_UPDATE_CHECK": "الغاء اتاحة التحديث الذاتي",
|
||||
"DONE": "! إنتهينا",
|
||||
"DOWNLOAD_ERROR": "خطأ في التحميل !",
|
||||
"DOWNLOAD_FAILED": "فشلت عملية التحميل !",
|
||||
"DOWNLOADING_ESHOP": "جاري تحميل eShop ...",
|
||||
"DOWNLOADING_ESHOP_DB": "جاري تحميل eShop ...",
|
||||
"DOWNLOADING_GHOST_ESHOP": "تحميل متجر الأشباح ...",
|
||||
"DOWNLOADING_COMPATIBLE_FONT": "جاري تحميل طاقم طباعة متوافق ...",
|
||||
"DOWNLOADING_SPRITE_SHEET": "تحميل برنامج Spritsheet ...",
|
||||
"DOWNLOADING_SPRITE_SHEET2": "تحميل Spritsheet %i من %i...",
|
||||
"ESHOP_BG": "استخدام eShop BG",
|
||||
"ESHOP_BG_DESC": "عند الاتاحة ، سيتم عرض eShop الذي يتم اتاحته BG بدلا من لون BG الصلب للشاشة العليا.",
|
||||
"ESHOP_INVALID_ERROR": "يعد هذا eShop غير صحيح ولا يمكن أن يكون من\nتم تحميله مع Ghost Eالورشة.\nربما يتم التحقق مما اذا كانت هناك أي أخطاء في الصيغة ؟",
|
||||
"ESHOP_TOO_NEW": "النسخة الخاصة بك من DarkStore هي\nقديمة جدا لاستخدام هذا eShop.\nيرجى تحديث النسخة الأخيرة.",
|
||||
"ESHOP_TOO_OLD": "هذه الورشة قديمة ولا يمكن استخدامها\nمع هذه النسخة من \"الشبح الشop\".\nرجاء أطلب من القائم بالتكوين أن يقوم بتعديله.",
|
||||
"ENABLE_AUTOUPDATE_ESHOP": "اتاحة التحديث الآلي للتسلسل عند بدء التشغيل",
|
||||
"ENABLE_UPDATE_CHECK": "اتاحة التحديث الذاتي",
|
||||
"ENTER_DESC_SHORTCUT": "أدخل وصف المسار المختصر.",
|
||||
"ENTER_SEARCH": "أدخل ما تريد البحث عنه.",
|
||||
"ENTER_SHORTCUT_FILENAME": "أدخل اسم ملف المسار المختصر (بدون لاحقة).",
|
||||
"ENTER_TITLE_SHORTCUT": "أدخل عنوان المسار المختصر.",
|
||||
"ENTER_URL": "أدخل عنوان URL الى eShop.",
|
||||
"ENTRIES": "ادخالات",
|
||||
"EXECUTE_ENTRY": "هل ترغب في تنفيذ هذا الادخال ?",
|
||||
"EXIT_APP": "الخروج من متجر الأشباح",
|
||||
"FETCHING_METADATA": "احضار بيانات تعريف قديمة ...",
|
||||
"FETCHING_RECOMMENDED_ESHOP": "إحضار متجر eShop الموصى به ...",
|
||||
"FILE_EXTRACTED": "ملف تم استخراجه.",
|
||||
"FILES_HOSTING_ANONYKU": "شركة Anonyku لاستضافة الملفات",
|
||||
"FILE_SLASH": "يبدو أنه تم تضمين '/' ، والذي لا يتم دعمه.\nبرجاء تغيير 'ملف' الى اسم الملف فقط.",
|
||||
"FILES_EXTRACTED": "الملفات التي تم استخراجها",
|
||||
"FILTER_TO": "ترشيح البيانات الى :",
|
||||
"GRID": "خطوط التحديد",
|
||||
"GUI_SETTINGS": "محددات GUI",
|
||||
"GUI_SETTINGS_BTN": "محددات GUI ...",
|
||||
"INCLUDE_IN_RESULTS": "تضمين في النتائج :",
|
||||
"INSTALL_GHOST_ESHOP": "جاري تركيب eShop الشبح ...",
|
||||
"INVALID_ESHOP": "متجر eShop غير صحيح",
|
||||
"KEY_CONTINUE": "اضغط على أي مفتاح للاستمرار.",
|
||||
"LANGUAGE": "اللغة",
|
||||
"LAST_UPDATED": "آخر تعديل",
|
||||
"LIST": "كشف",
|
||||
"LOADING_SPRITESHEET": "تحميل Spritsheet %i من %i...",
|
||||
"MEDIATYPE_NAND": "NAND ediaMepyT",
|
||||
"MEDIATYPE_SD": "MediaType DSD",
|
||||
"MOVE_ERROR": "خطأ في النقل !",
|
||||
"NO": "لا",
|
||||
"NO_ADDITIONAL_CONTENT_AVAILABLE": "لا توجد محتويات اضافية متاحة",
|
||||
"NO_DOWNLOADS_AVAILABLE": "لا توجد عمليات تحميل متاحة",
|
||||
"NO_SIZE": "لا يوجد حجم",
|
||||
"NO_SCREENSHOTS_AVAILABLE": "لا توجد لقطات شاشة متاحة",
|
||||
"NOT_IMPLEMENTED": "لم تنفذ بعد",
|
||||
"RECOMMENDED_ESHOP": "موصى به eShop",
|
||||
"REVISION": "المراجعة",
|
||||
"SCREENSHOT": "لقطة شاشة %d / %d",
|
||||
"SCREENSHOT_COULD_NOT_LOAD": "تعذر تحميل لقطة الشاشة.",
|
||||
"SCREENSHOT_INSTRUCTIONS": "اضغط على للتغيير والتغيير",
|
||||
"SEARCH_FILTERS": "البحث وترشيح البيانات",
|
||||
"SELECT_ESHOP": "اختيار eShop",
|
||||
"SELECT_ESHOP_2": "قم بتحديد eShop",
|
||||
"SELECT_DIR": "حدد دليل",
|
||||
"SELECT_LANG": "قم باختيار اللغة",
|
||||
"SETTINGS": "المحددات",
|
||||
"SHEET_SLASH": "يبدو أنه تم تضمين '/' ، والذي لا يتم دعمه.\nبرجاء تغيير 'sheet' الى اسم الملف فقط.",
|
||||
"SHORTCUT_CREATED": "تم تكوين المسار المختصر !",
|
||||
"SIZE": "الحجم",
|
||||
"SORT_BY": "فرز بواسطة",
|
||||
"SORTING": "فرز",
|
||||
"START_SELECT": "اضغط START لاختيار الحافظة الحالية",
|
||||
"STORE_INFO": "Store Info",
|
||||
"SYNTAX_ERROR": "خطأ في الصيغة !",
|
||||
"TITLE": "العنوان",
|
||||
"TOP_STYLE": "أعلى نمط",
|
||||
"UNSUPPORTED_ESHOP_VERSION": "لا يتم دعم نسخة eShop هذه.",
|
||||
"UPDATE_AVAILABLE": "تحديث متاح !",
|
||||
"UPDATE_DONE": "تم تعديله ! برجاء اعادة فتح متجر الأشباح.",
|
||||
"UPDATE_NOT_AVAILABLE": "لا توجد تعديلات متاحة !",
|
||||
"UPDATING_ESHOP": "تحديث eShop ...",
|
||||
"UPDATING_SPRITE_SHEET": "تحديث صفحة Spritsheet ...",
|
||||
"UPDATING_SPRITE_SHEET2": "تحديث صفحة Spritsheet %i من %i...",
|
||||
"VERSION": "النسخة",
|
||||
"WEBSITE": "يمكن ايجاد الاعتمادات الكاملة & Changelog في الموقع Ghosteshop.com",
|
||||
"YES": "نعم."
|
||||
}
|
||||
@@ -1,124 +0,0 @@
|
||||
{
|
||||
"ARGUMENT_INVALID": "参数无效。\n请检查xml文件以获取正确的参数。",
|
||||
"ASCENDING": "上升",
|
||||
"AUTHOR": "作者",
|
||||
"AUTO_UPDATE_ESHOP": "自动更新eShop",
|
||||
"AUTO_UPDATE_ESHOP_DESC": "这样,启动DarkStore时,上次使用的eShop将自动更新。",
|
||||
"AUTO_UPDATE_DS": "自动更新DarkStore",
|
||||
"AUTO_UPDATE_DS_DESC": "启用后,DarkStore每次打开时都会检查更新。",
|
||||
"AUTO_UPDATE_SETTINGS": "自动更新设置",
|
||||
"AUTO_UPDATE_SETTINGS_BTN": "自动更新设置...",
|
||||
"AVAILABLE_DOWNLOADS": "可用下载",
|
||||
"BOOT_TITLE": "您要启动此标题吗?",
|
||||
"CATEGORY": "类别",
|
||||
"CHANGE_3DSX_PATH": "更改3DSX路径",
|
||||
"CHANGE_ARCHIVE_PATH": "更改档案路径",
|
||||
"CHANGE_NDS_PATH": "更改NDS路径",
|
||||
"CHANGE_SHORTCUT_PATH": "更改快捷方式路径",
|
||||
"CHANGELOG": "变更日志",
|
||||
"CHECK_ESHOP_UPDATES": "检查eShop更新...",
|
||||
"CHECK_DS_UPDATES": "检查DarkStore更新...",
|
||||
"CITRA_BIGN_ICON": "Citra和任天堂的偶像",
|
||||
"CONFIRM_OR_CANCEL": "按下 \uE000 确认,\uE001 取消。",
|
||||
"CONNECT_WIFI": "请连接到WiFi。",
|
||||
"CONSOLE": "安慰",
|
||||
"CONTRIBUTOR_TRANSLATORS": "- 所有翻译和贡献者",
|
||||
"COPY_ERROR": "复制错误!",
|
||||
"CREATE_SHORTCUT": "您想创建一个快捷方式吗?",
|
||||
"CREDITS": "学分",
|
||||
"CURRENT_VERSION": "当前版本:",
|
||||
"CURRENTLY_EXTRACTING": "目前正在提取:\n",
|
||||
"CUSTOM_FONT": "使用自定义字体",
|
||||
"CUSTOM_FONT_DESC": "如果启用,将使用 'sdmc:/3ds/DarkStore/font.bcfnt' 代替系统字体 (如果找到)。",
|
||||
"DELETE_ERROR": "删除错误!",
|
||||
"DELETE_PROMPT": "您确定要删除此目录吗?",
|
||||
"DELETE_UNNEEDED_FILE": "删除不需要的文件...",
|
||||
"DESCENDING": "降序",
|
||||
"DIRECTION": "方向",
|
||||
"DIRECTORY_SETTINGS": "目录设置",
|
||||
"DIRECTORY_SETTINGS_BTN": "目录设置...",
|
||||
"DISABLE_AUTOUPDATE_ESHOP": "在启动时禁用自动更新eShop",
|
||||
"DISABLE_UPDATE_CHECK": "禁用自我更新",
|
||||
"DONE": "做完了!",
|
||||
"DOWNLOAD_ERROR": "下载错误!",
|
||||
"DOWNLOAD_FAILED": "下载失败!",
|
||||
"DOWNLOADING_ESHOP": "正在下载eShop...",
|
||||
"DOWNLOADING_ESHOP_DB": "正在下载eShop...",
|
||||
"DOWNLOADING_GHOST_ESHOP": "下载DarkStore...",
|
||||
"DOWNLOADING_COMPATIBLE_FONT": "下载兼容字体...",
|
||||
"DOWNLOADING_SPRITE_SHEET": "下载Spritesheet...",
|
||||
"DOWNLOADING_SPRITE_SHEET2": "正在下载 %i 的Spritesheet %i ...",
|
||||
"ESHOP_BG": "使用eShop BG",
|
||||
"ESHOP_BG_DESC": "启用后,将显示eShop提供的BG,而不是顶部屏幕的纯BG颜色。",
|
||||
"ESHOP_INVALID_ERROR": "该eShop无效,无法\n与DarkStore一起加载。\n也许检查是否存在语法错误?",
|
||||
"ESHOP_TOO_NEW": "您使用的DarkStore版本较旧,\ntoo不能使用此eShop。\n请更新至最新版本。",
|
||||
"ESHOP_TOO_OLD": "该eShop已过时,不能与该版本的DarkStore一起使用。\n请要求创建者对其进行更新。",
|
||||
"ENABLE_AUTOUPDATE_ESHOP": "在启动时启用自动更新eShop",
|
||||
"ENABLE_UPDATE_CHECK": "启用自我更新",
|
||||
"ENTER_DESC_SHORTCUT": "输入快捷方式描述。",
|
||||
"ENTER_SEARCH": "输入您要搜索的内容。",
|
||||
"ENTER_SHORTCUT_FILENAME": "输入快捷方式文件名(不带扩展名)。",
|
||||
"ENTER_TITLE_SHORTCUT": "输入快捷方式标题。",
|
||||
"ENTER_URL": "输入eShop的URL。",
|
||||
"ENTRIES": "参赛作品",
|
||||
"EXECUTE_ENTRY": "您要执行此输入吗?",
|
||||
"EXIT_APP": "退出DarkStore",
|
||||
"FETCHING_METADATA": "正在获取旧的元数据...",
|
||||
"FETCHING_RECOMMENDED_ESHOP": "正在获取推荐的eShop ...",
|
||||
"FILE_EXTRACTED": "文件提取。",
|
||||
"FILES_HOSTING_ANONYKU": "Anonyku用于托管文件",
|
||||
"FILE_SLASH": "似乎其中包含一个'/',不支持。\n请仅将'file'更改为filename。",
|
||||
"FILES_EXTRACTED": "文件提取。",
|
||||
"FILTER_TO": "筛选至:",
|
||||
"GRID": "格",
|
||||
"GUI_SETTINGS": "GUI设置",
|
||||
"GUI_SETTINGS_BTN": "GUI设置...",
|
||||
"INCLUDE_IN_RESULTS": "包括在结果中:",
|
||||
"INSTALL_GHOST_ESHOP": "正在安装DarkStore...",
|
||||
"INVALID_ESHOP": "无效的eShop",
|
||||
"KEY_CONTINUE": "按任意键继续。",
|
||||
"LANGUAGE": "语言",
|
||||
"LAST_UPDATED": "最近更新时间",
|
||||
"LIST": "清单",
|
||||
"LOADING_SPRITESHEET": "载入精灵表 %i 的 %i...",
|
||||
"MEDIATYPE_NAND": "MediaType NAND",
|
||||
"MEDIATYPE_SD": "MediaType SD",
|
||||
"MOVE_ERROR": "移动错误!",
|
||||
"NO": "没有",
|
||||
"NO_ADDITIONAL_CONTENT_AVAILABLE": "没有可用的其他内容",
|
||||
"NO_DOWNLOADS_AVAILABLE": "无法下载",
|
||||
"NO_SCREENSHOTS_AVAILABLE": "没有可用的屏幕截图",
|
||||
"NO_SIZE": "没有大小",
|
||||
"NOT_IMPLEMENTED": "尚未实施",
|
||||
"RECOMMENDED_ESHOP": "推荐的网上商店",
|
||||
"REVISION": "修订版",
|
||||
"SCREENSHOT": "屏幕截图 %d / %d",
|
||||
"SCREENSHOT_COULD_NOT_LOAD": "无法加载屏幕截图。",
|
||||
"SCREENSHOT_INSTRUCTIONS": "按 改变和 放大",
|
||||
"SEARCH_FILTERS": "搜索和过滤器",
|
||||
"SELECT_ESHOP": "选择网上商店",
|
||||
"SELECT_ESHOP_2": "选择一个网上商店",
|
||||
"SELECT_DIR": "选择目录",
|
||||
"SELECT_LANG": "选择语言",
|
||||
"SETTINGS": "设定值",
|
||||
"SHEET_SLASH": "似乎包含了一个'/',不支持该字符。\n请仅将'sheet'更改为filename。",
|
||||
"SHORTCUT_CREATED": "快捷方式已创建!",
|
||||
"SIZE": "尺寸",
|
||||
"SORT_BY": "排序方式",
|
||||
"SORTING": "排序",
|
||||
"START_SELECT": "按开始选择当前文件夹",
|
||||
"STORE_INFO": "店铺信息",
|
||||
"SYNTAX_ERROR": "语法错误!",
|
||||
"TITLE": "标题",
|
||||
"TOP_STYLE": "顶级风格",
|
||||
"UNSUPPORTED_ESHOP_VERSION": "不支持此eShop的版本。",
|
||||
"UPDATE_AVAILABLE": "更新可用!",
|
||||
"UPDATE_DONE": "更新完成!请重新打开DarkStore。",
|
||||
"UPDATE_NOT_AVAILABLE": "没有可用的更新!",
|
||||
"UPDATING_ESHOP": "正在更新eShop...",
|
||||
"UPDATING_SPRITE_SHEET": "正在更新Spritesheet...",
|
||||
"UPDATING_SPRITE_SHEET2": "更新Spritesheet %i 的 %i...",
|
||||
"VERSION": "版",
|
||||
"WEBSITE": "完整的积分和变更日志可在Ghosteshop.com上找到",
|
||||
"YES": "是"
|
||||
}
|
||||
@@ -1,124 +0,0 @@
|
||||
{
|
||||
"ARGUMENT_INVALID": "參數無效。\n請檢查xml文件以獲取正確的參數。",
|
||||
"ASCENDING": "上升",
|
||||
"AUTHOR": "作者",
|
||||
"AUTO_UPDATE_ESHOP": "自動更新eShop",
|
||||
"AUTO_UPDATE_ESHOP_DESC": "這樣,啟動DarkStore時,上次使用的eShop將自動更新。",
|
||||
"AUTO_UPDATE_DS": "自動更新DarkStore",
|
||||
"AUTO_UPDATE_DS_DESC": "啟用後,DarkStore每次打開時都會檢查更新。",
|
||||
"AUTO_UPDATE_SETTINGS": "自動更新設置",
|
||||
"AUTO_UPDATE_SETTINGS_BTN": "自動更新設置...",
|
||||
"AVAILABLE_DOWNLOADS": "可用下載",
|
||||
"BOOT_TITLE": "您要啟動此標題嗎?",
|
||||
"CATEGORY": "類別",
|
||||
"CHANGE_3DSX_PATH": "更改3DSX路徑",
|
||||
"CHANGE_ARCHIVE_PATH": "更改檔案路徑",
|
||||
"CHANGE_NDS_PATH": "更改NDS路徑",
|
||||
"CHANGE_SHORTCUT_PATH": "更改快捷方式路徑",
|
||||
"CHANGELOG": "變更日誌",
|
||||
"CHECK_ESHOP_UPDATES": "正在檢查eShop更新...",
|
||||
"CHECK_DS_UPDATES": "正在檢查DarkStore更新...",
|
||||
"CITRA_BIGN_ICON": "Citra和任天堂的偶像",
|
||||
"CONFIRM_OR_CANCEL": "按下 \uE000 確認, \uE001 取消。",
|
||||
"CONNECT_WIFI": "請連接到WiFi.",
|
||||
"CONSOLE": "安慰",
|
||||
"CONTRIBUTOR_TRANSLATORS": "- 所有翻譯和貢獻者",
|
||||
"COPY_ERROR": "複製錯誤!",
|
||||
"CREATE_SHORTCUT": "您想創建一個快捷方式嗎?",
|
||||
"CREDITS": "學分",
|
||||
"CURRENT_VERSION": "當前版本: ",
|
||||
"CURRENTLY_EXTRACTING": "當前正在提取:\n",
|
||||
"CUSTOM_FONT": "使用自定義字體",
|
||||
"CUSTOM_FONT_DESC": "如果啟用,將使用 'sdmc:/3ds/DarkStore/font.bcfnt' 代替系統字體(如果找到)。",
|
||||
"DELETE_ERROR": "刪除錯誤!",
|
||||
"DELETE_PROMPT": "您確定要刪除此目錄嗎?",
|
||||
"DELETE_UNNEEDED_FILE": "刪除不需要的文件...",
|
||||
"DESCENDING": "降序",
|
||||
"DIRECTION": "方向",
|
||||
"DIRECTORY_SETTINGS": "目錄設置",
|
||||
"DIRECTORY_SETTINGS_BTN": "目錄設置...",
|
||||
"DISABLE_AUTOUPDATE_ESHOP": "在啟動時禁用自動更新eShop",
|
||||
"DISABLE_UPDATE_CHECK": "禁用自我更新",
|
||||
"DONE": "做完了!",
|
||||
"DOWNLOAD_ERROR": "下載錯誤!",
|
||||
"DOWNLOAD_FAILED": "下載失敗!",
|
||||
"DOWNLOADING_ESHOP": "正在下載eShop...",
|
||||
"DOWNLOADING_ESHOP_DB": "正在下載eShop...",
|
||||
"DOWNLOADING_GHOST_ESHOP": "下載DarkStore...",
|
||||
"DOWNLOADING_COMPATIBLE_FONT": "下載兼容字體...",
|
||||
"DOWNLOADING_SPRITE_SHEET": "下載Spritesheet...",
|
||||
"DOWNLOADING_SPRITE_SHEET2": "下載Spritesheet %i 的 %i...",
|
||||
"ESHOP_BG": "使用eShop BG",
|
||||
"ESHOP_BG_DESC": "啟用後,將顯示eShop提供的BG,而不是頂部屏幕的純BG顏色。",
|
||||
"ESHOP_INVALID_ERROR": "該eShop無效,無法\n與DarkStore一起加載。\n請檢查是否存在任何語法錯誤?",
|
||||
"ESHOP_TOO_NEW": "您使用的DarkStore版本較舊,\n無法使用此eShop。\n請更新至最新版本。",
|
||||
"ESHOP_TOO_OLD": "該eShop已過時,無法使用\n此版本的DarkStore。\n請要求創建者對其進行更新。",
|
||||
"ENABLE_AUTOUPDATE_ESHOP": "在啟動時啟用自動更新eShop",
|
||||
"ENABLE_UPDATE_CHECK": "啟用自我更新",
|
||||
"ENTER_DESC_SHORTCUT": "輸入快捷方式描述。",
|
||||
"ENTER_SEARCH": "輸入您要搜索的內容。",
|
||||
"ENTER_SHORTCUT_FILENAME": "輸入快捷方式文件名(不帶擴展名)。",
|
||||
"ENTER_TITLE_SHORTCUT": "輸入快捷方式標題。",
|
||||
"ENTER_URL": "輸入網上商店的URL.",
|
||||
"ENTRIES": "參賽作品",
|
||||
"EXECUTE_ENTRY": "您要執行此輸入嗎?",
|
||||
"EXIT_APP": "退出DarkStore",
|
||||
"FETCHING_METADATA": "提取舊的元數據...",
|
||||
"FETCHING_RECOMMENDED_ESHOP": "正在獲取推薦的eShop...",
|
||||
"FILE_EXTRACTED": "提取文件.",
|
||||
"FILES_HOSTING_ANONYKU": "Anonyku用於託管文件",
|
||||
"FILE_SLASH": "似乎包含了一個 '/',但不支持。\n請更換 'file' 到文件名。",
|
||||
"FILES_EXTRACTED": "文件提取。",
|
||||
"FILTER_TO": "篩選至:",
|
||||
"GRID": "格",
|
||||
"GUI_SETTINGS": "GUI設置",
|
||||
"GUI_SETTINGS_BTN": "GUI設置...",
|
||||
"INCLUDE_IN_RESULTS": "包括在結果中:",
|
||||
"INSTALL_GHOST_ESHOP": "正在安裝DarkStore...",
|
||||
"INVALID_ESHOP": "無效的eShop",
|
||||
"KEY_CONTINUE": "按任意鍵繼續。",
|
||||
"LANGUAGE": "語言",
|
||||
"LAST_UPDATED": "最近更新時間",
|
||||
"LIST": "清單",
|
||||
"LOADING_SPRITESHEET": "載入精靈表 %i 的 %i...",
|
||||
"MEDIATYPE_NAND": "MediaType NAND",
|
||||
"MEDIATYPE_SD": "MediaType SD",
|
||||
"MOVE_ERROR": "移動錯誤!",
|
||||
"NO": "沒有",
|
||||
"NO_ADDITIONAL_CONTENT_AVAILABLE": "沒有可用的其他內容",
|
||||
"NO_DOWNLOADS_AVAILABLE": "無法下載",
|
||||
"NO_SCREENSHOTS_AVAILABLE": "沒有可用的屏幕截圖",
|
||||
"NO_SIZE": "沒有大小",
|
||||
"NOT_IMPLEMENTED": "尚未實施",
|
||||
"RECOMMENDED_ESHOP": "推薦的網上商店",
|
||||
"REVISION": "修訂版",
|
||||
"SCREENSHOT": "屏幕截圖 %d / %d",
|
||||
"SCREENSHOT_COULD_NOT_LOAD": "無法加載屏幕截圖。",
|
||||
"SCREENSHOT_INSTRUCTIONS": "按 改變和 放大",
|
||||
"SEARCH_FILTERS": "搜索和過濾器",
|
||||
"SELECT_ESHOP": "選擇網上商店",
|
||||
"SELECT_ESHOP_2": "選擇一個網上商店",
|
||||
"SELECT_DIR": "選擇目錄",
|
||||
"SELECT_LANG": "選擇語言",
|
||||
"SETTINGS": "設定值",
|
||||
"SHEET_SLASH": "似乎包含了一個 '/',但不支持。\n請將“工作表”更改為僅文件名。",
|
||||
"SHORTCUT_CREATED": "快捷方式已創建!",
|
||||
"SIZE": "尺寸",
|
||||
"SORT_BY": "排序方式",
|
||||
"SORTING": "排序",
|
||||
"START_SELECT": "按開始選擇當前文件夾",
|
||||
"STORE_INFO": "店鋪信息",
|
||||
"SYNTAX_ERROR": "語法錯誤!",
|
||||
"TITLE": "標題",
|
||||
"TOP_STYLE": "頂級風格",
|
||||
"UNSUPPORTED_ESHOP_VERSION": "不支持此eShop的版本。",
|
||||
"UPDATE_AVAILABLE": "更新可用!",
|
||||
"UPDATE_DONE": "更新完成!請重新打開DarkStore。",
|
||||
"UPDATE_NOT_AVAILABLE": "沒有可用的更新!",
|
||||
"UPDATING_ESHOP": "正在更新eShop...",
|
||||
"UPDATING_SPRITE_SHEET": "正在更新Spritesheet...",
|
||||
"UPDATING_SPRITE_SHEET2": "正在更新Spritesheet %i 的 %i...",
|
||||
"VERSION": "版",
|
||||
"WEBSITE": "完整的積分和變更日誌可在Ghosteshop.com上找到",
|
||||
"YES": "是"
|
||||
}
|
||||
@@ -1,124 +0,0 @@
|
||||
{
|
||||
"ARGUMENT_INVALID": "Argumentet er ugyldigt.\nKontroller xml-filen for korrekte argumenter.",
|
||||
"ASCENDING": "Stigende",
|
||||
"AUTHOR": "Forfatter",
|
||||
"AUTO_UPDATE_ESHOP": "Auto-opdater eShop",
|
||||
"AUTO_UPDATE_ESHOP_DESC": "Med dette opdateres den sidst anvendte eShop automatisk, når DarkStore startes.",
|
||||
"AUTO_UPDATE_DS": "Opdater DarkStore automatisk",
|
||||
"AUTO_UPDATE_DS_DESC": "Når det er aktiveret, kontrollerer DarkStore for opdateringer hver gang det åbnes.",
|
||||
"AUTO_UPDATE_SETTINGS": "Indstillinger for automatisk opdatering",
|
||||
"AUTO_UPDATE_SETTINGS_BTN": "Indstillinger for automatisk opdatering...",
|
||||
"AVAILABLE_DOWNLOADS": "Tilgængelige downloads",
|
||||
"BOOT_TITLE": "Vil du gerne starte denne titel?",
|
||||
"CATEGORY": "Kategori",
|
||||
"CHANGE_3DSX_PATH": "Skift 3DSX-sti",
|
||||
"CHANGE_ARCHIVE_PATH": "Skift arkivsti",
|
||||
"CHANGE_NDS_PATH": "Skift NDS-sti",
|
||||
"CHANGE_SHORTCUT_PATH": "Skift genvejssti",
|
||||
"CHANGELOG": "skiftelog",
|
||||
"CHECK_ESHOP_UPDATES": "Kontrollerer for eShop-opdateringer...",
|
||||
"CHECK_DS_UPDATES": "Kontrollerer for DarkStore-opdateringer...",
|
||||
"CITRA_BIGN_ICON": "Citra & Nintendo til ikonet",
|
||||
"CONFIRM_OR_CANCEL": "Tryk på for at bekræfte, for at annullere.",
|
||||
"CONNECT_WIFI": "Forbind venligst til WiFi.",
|
||||
"CONSOLE": "Konsol",
|
||||
"CONTRIBUTOR_TRANSLATORS": "- Alle oversættere og bidragydere",
|
||||
"COPY_ERROR": "Kopierings Fejl!",
|
||||
"CREATE_SHORTCUT": "Vil du oprette en genvej?",
|
||||
"CREDITS": "Medvirkende",
|
||||
"CURRENT_VERSION": "Nuværende version: ",
|
||||
"CURRENTLY_EXTRACTING": "Udpakker i øjeblikket:\n",
|
||||
"CUSTOM_FONT": "Brug brugerdefineret skrifttype",
|
||||
"CUSTOM_FONT_DESC": "Hvis aktiveret, vil 'sdmc: /3ds/DarkStore/font.bcfnt' blive brugt i stedet for systemets skrifttype, hvis den findes.",
|
||||
"DELETE_ERROR": "Sletnings Fejl!",
|
||||
"DELETE_PROMPT": "Er du sikker på at du vil slette denne Mappe?",
|
||||
"DELETE_UNNEEDED_FILE": "Sletning af unødvendig fil...",
|
||||
"DESCENDING": "Aftagende",
|
||||
"DIRECTION": "Retning",
|
||||
"DIRECTORY_SETTINGS": "Directory-indstillinger",
|
||||
"DIRECTORY_SETTINGS_BTN": "Directory-indstillinger...",
|
||||
"DISABLE_AUTOUPDATE_ESHOP": "Deaktiver automatisk opdatering af eShop ved opstart",
|
||||
"DISABLE_UPDATE_CHECK": "Deaktiver selvopdatering",
|
||||
"DONE": "Færdig!",
|
||||
"DOWNLOAD_ERROR": "Nedhentings Fejl!",
|
||||
"DOWNLOADING_COMPATIBLE_FONT": "Downloader kompatibel skrifttype...",
|
||||
"DOWNLOADING_ESHOP": "Downloader eShop...",
|
||||
"DOWNLOADING_ESHOP_DB": "Downloader eShop...",
|
||||
"DOWNLOADING_GHOST_ESHOP": "Downloader DarkStore...",
|
||||
"DOWNLOAD_FAILED": "Nedhentning mislykkedes!",
|
||||
"DOWNLOADING_SPRITE_SHEET": "Download af Spritesheet...",
|
||||
"DOWNLOADING_SPRITE_SHEET2": "Download af Spritesheet% i af% i...",
|
||||
"ENABLE_AUTOUPDATE_ESHOP": "Aktivér automatisk opdatering af eShop ved opstart",
|
||||
"ENABLE_UPDATE_CHECK": "Aktivér selvopdatering",
|
||||
"ENTER_DESC_SHORTCUT": "Indtast genvejsbeskrivelsen.",
|
||||
"ENTER_SEARCH": "Indtast det, du gerne vil søge.",
|
||||
"ENTER_SHORTCUT_FILENAME": "Indtast genvejsfilnavnet (uden udvidelse).",
|
||||
"ENTER_TITLE_SHORTCUT": "Indtast genvejstitlen.",
|
||||
"ENTER_URL": "Indtast webadressen til eShop.",
|
||||
"ENTRIES": "Indlæg",
|
||||
"ESHOP_BG": "Brug eShop BG",
|
||||
"ESHOP_BG_DESC": "Når det er aktiveret, vises e-Shops leverede BG i stedet for den solide BG-farve til den øverste skærm.",
|
||||
"ESHOP_INVALID_ERROR": "Denne eShop er ugyldig og kan ikke\nloades med DarkStore.\nKontroller muligvis, om der er syntaksfejl?",
|
||||
"ESHOP_TOO_NEW": "Din version af DarkStore er\nalt for gammel til at bruge denne eShop.\nOpdater til den nyeste version.",
|
||||
"ESHOP_TOO_OLD": "Denne eShop er forældet og kan ikke bruges\nmed denne version af DarkStore.\nBed skaberen om at opdatere den.",
|
||||
"EXECUTE_ENTRY": "Vil du udføre denne post?",
|
||||
"EXIT_APP": "Afslut DarkStore",
|
||||
"FETCHING_METADATA": "Henter gamle metadata...",
|
||||
"FETCHING_RECOMMENDED_ESHOP": "Fetching recommended eShop...",
|
||||
"FILE_EXTRACTED": "fil udpakket.",
|
||||
"FILES_HOSTING_ANONYKU": "Anonyku til hosting af filer",
|
||||
"FILE_SLASH": "Det ser ud til, at en '/' er inkluderet, hvilket ikke understøttes.\nSkift 'fil' kun til filnavn.",
|
||||
"FILES_EXTRACTED": "filer udpakket.",
|
||||
"FILTER_TO": "Filtrer til:",
|
||||
"GRID": "Gitter",
|
||||
"GUI_SETTINGS": "GUI-indstillinger",
|
||||
"GUI_SETTINGS_BTN": "GUI-indstillinger...",
|
||||
"INCLUDE_IN_RESULTS": "Medtag i resultaterne:",
|
||||
"INSTALL_GHOST_ESHOP": "Installation af DarkStore...",
|
||||
"INVALID_ESHOP": "Ugyldig eShop",
|
||||
"KEY_CONTINUE": "Tryk på en vilkårlig tast for at fortsætte.",
|
||||
"LANGUAGE": "Sprog",
|
||||
"LAST_UPDATED": "Sidst opdateret",
|
||||
"LIST": "Liste",
|
||||
"LOADING_SPRITESHEET": "Indlæser Spritesheet %i af %i...",
|
||||
"MEDIATYPE_NAND": "MedieType NAND",
|
||||
"MEDIATYPE_SD": "MedieType SD",
|
||||
"MOVE_ERROR": "Flytnings Fejl!",
|
||||
"NO": "Nej",
|
||||
"NO_ADDITIONAL_CONTENT_AVAILABLE": "Intet yderligere indhold tilgængeligt",
|
||||
"NO_DOWNLOADS_AVAILABLE": "Ingen tilgængelige downloads",
|
||||
"NO_SCREENSHOTS_AVAILABLE": "Ingen skærmbilleder tilgængelige",
|
||||
"NO_SIZE": "Ingen størrelse",
|
||||
"NOT_IMPLEMENTED": "Ikke Implementeret Endnu",
|
||||
"RECOMMENDED_ESHOP": "Anbefalet eShop",
|
||||
"REVISION": "Revision",
|
||||
"SCREENSHOT": "Skærmbillede %d / %d",
|
||||
"SCREENSHOT_COULD_NOT_LOAD": "Skærmbillede kunne ikke indlæses.",
|
||||
"SCREENSHOT_INSTRUCTIONS": "Trykke for at ændre og for at zoome",
|
||||
"SEARCH_FILTERS": "Søg og filtre",
|
||||
"SELECT_ESHOP": "Vælg eShop",
|
||||
"SELECT_ESHOP_2": "Vælg en eShop",
|
||||
"SELECT_DIR": "Vælg et bibliotek",
|
||||
"SELECT_LANG": "Vælg sprog",
|
||||
"SETTINGS": "Indstillinger",
|
||||
"SHEET_SLASH": "Det ser ud til, at der er inkluderet et '/', som ikke understøttes.\nVend venligst 'ark' til kun filnavnet.",
|
||||
"SHORTCUT_CREATED": "Genvej oprettet!",
|
||||
"SIZE": "Størrelse",
|
||||
"SORT_BY": "Sorter efter",
|
||||
"SORTING": "Sortering",
|
||||
"START_SELECT": "Tryk på START for at vælge den aktuelle mappe",
|
||||
"STORE_INFO": "Gem info",
|
||||
"SYNTAX_ERROR": "Syntaks Fejl!",
|
||||
"TITLE": "Titel",
|
||||
"TOP_STYLE": "Top Stil",
|
||||
"UNSUPPORTED_ESHOP_VERSION": "Versionen af denne eShop understøttes ikke.",
|
||||
"UPDATE_AVAILABLE": "Opdatering tilgængelig!",
|
||||
"UPDATE_DONE": "Opdatering færdig! Åbn DarkStore igen.",
|
||||
"UPDATE_NOT_AVAILABLE": "Ingen Opdateringer Tilgængelige!",
|
||||
"UPDATING_SPRITE_SHEET": "Opdaterer Spritesheet...",
|
||||
"UPDATING_SPRITE_SHEET2": "Opdatering af Spritesheet %i af %i...",
|
||||
"UPDATING_ESHOP": "Opdatering af eShop...",
|
||||
"VERSION": "Version",
|
||||
"WEBSITE": "Fuld kredit og Changelog kan findes på Ghosteshop.com",
|
||||
"YES": "Ja"
|
||||
}
|
||||
@@ -1,124 +0,0 @@
|
||||
{
|
||||
"ARGUMENT_INVALID": "Argument ungültig.\nFbitte überprüfen Sie die XML-Datei auf korrekte Argumente.",
|
||||
"ASCENDING": "Aufsteigend",
|
||||
"AUTHOR": "Autor",
|
||||
"AUTO_UPDATE_ESHOP": "eShop automatisch aktualisieren",
|
||||
"AUTO_UPDATE_ESHOP_DESC": "Damit wird der zuletzt verwendete eShop automatisch aktualisiert, wenn DarkStore gestartet wird.",
|
||||
"AUTO_UPDATE_DS": "DarkStore automatisch aktualisieren",
|
||||
"AUTO_UPDATE_DS_DESC": "Falls aktiviert, sucht DarkStore bei jedem Start nach Aktualisierungen.",
|
||||
"AUTO_UPDATE_SETTINGS": "Aktualisierungs-Einstellungen",
|
||||
"AUTO_UPDATE_SETTINGS_BTN": "Aktualisierungs-Einstellungen...",
|
||||
"AVAILABLE_DOWNLOADS": "Verfügbare Downloads",
|
||||
"BOOT_TITLE": "Möchten Sie diesen Titel starten?",
|
||||
"CATEGORY": "Kategorie",
|
||||
"CHANGE_3DSX_PATH": "3DSX Pfad ändern",
|
||||
"CHANGE_ARCHIVE_PATH": "Archiv Pfad ändern",
|
||||
"CHANGE_NDS_PATH": "NDS Pfad ändern",
|
||||
"CHANGE_SHORTCUT_PATH": "Verknüpfungspfad ändern",
|
||||
"CHANGELOG": "Änderungsprotokoll",
|
||||
"CHECK_ESHOP_UPDATES": "Überprüfe für eShop Aktualisierungen...",
|
||||
"CHECK_DS_UPDATES": "Überprüfe für DarkStore Aktualisierungen...",
|
||||
"CITRA_BIGN_ICON": "Citra & Nintendo für die Ikone",
|
||||
"CONFIRM_OR_CANCEL": "Drücke zum bestätigen, zum abbrechen.",
|
||||
"CONNECT_WIFI": "Bitte mit dem WLAN verbinden.",
|
||||
"CONSOLE": "Konsole",
|
||||
"CONTRIBUTOR_TRANSLATORS": "- Alle Übersetzer & Mitwirkenden",
|
||||
"COPY_ERROR": "Fehler beim Kopieren!",
|
||||
"CREATE_SHORTCUT": "Möchten Sie eine Verknüpfung erstellen?",
|
||||
"CREDITS": "Credits",
|
||||
"CURRENT_VERSION": "Aktuelle Version: ",
|
||||
"CURRENTLY_EXTRACTING": "Momentan extrahieren:\n",
|
||||
"CUSTOM_FONT": "Verwenden Sie die benutzerdefinierte Schriftart",
|
||||
"CUSTOM_FONT_DESC": "Wenn aktiviert, wird 'sdmc: /3ds/DarkStore/font.bcfnt' anstelle der Systemschriftart verwendet, falls gefunden.",
|
||||
"DELETE_ERROR": "Fehler beim Löschen!",
|
||||
"DELETE_PROMPT": "Möchten Sie den Ordner wirklich entfernen?",
|
||||
"DELETE_UNNEEDED_FILE": "Entferne nicht benötigte Datei...",
|
||||
"DESCENDING": "Absteigend",
|
||||
"DIRECTION": "Richtung",
|
||||
"DIRECTORY_SETTINGS": "Verzeichniseinstellungen",
|
||||
"DIRECTORY_SETTINGS_BTN": "Verzeichniseinstellungen...",
|
||||
"DISABLE_AUTOUPDATE_ESHOP": "Deaktiviere autom. aktual. eShop beim Start",
|
||||
"DISABLE_UPDATE_CHECK": "Deaktiviere Selbst-Aktualisierung",
|
||||
"DONE": "Fertig!",
|
||||
"DOWNLOAD_ERROR": "Download-Fehler!",
|
||||
"DOWNLOAD_FAILED": "Download fehlgeschlagen!",
|
||||
"DOWNLOADING_COMPATIBLE_FONT": "Kompatible Schriftart herunterladen...",
|
||||
"DOWNLOADING_ESHOP": "Lade eShop herunter...",
|
||||
"DOWNLOADING_ESHOP_DB": "Lade eShop herunter...",
|
||||
"DOWNLOADING_GHOST_ESHOP": "Lade DarkStore herunter...",
|
||||
"DOWNLOADING_SPRITE_SHEET": "Lade Spritesheet herunter...",
|
||||
"DOWNLOADING_SPRITE_SHEET2": "Lade Spritesheet %i von %i herunter...",
|
||||
"ENABLE_AUTOUPDATE_ESHOP": "Aktiviere autom. aktual. eShop beim Start",
|
||||
"ENABLE_UPDATE_CHECK": "Aktiviere Selbst-Aktualisierung",
|
||||
"ENTER_DESC_SHORTCUT": "Geben Sie die Verknüpfungsbeschreibung ein.",
|
||||
"ENTER_SEARCH": "Gebe ein, was du suchen möchtest.",
|
||||
"ENTER_SHORTCUT_FILENAME": "Geben Sie den Verknüpfungsdateinamen ein (ohne Erweiterung).",
|
||||
"ENTER_TITLE_SHORTCUT": "Geben Sie den Verknüpfungstitel ein.",
|
||||
"ENTER_URL": "Gebe die URL des eShop's ein.",
|
||||
"ENTRIES": "Einträge",
|
||||
"ESHOP_BG": "eShop Hintergrund verwenden",
|
||||
"ESHOP_BG_DESC": "Falls aktiviert, wird der Hintergrund des eShop's verwendet falls verfügbar anstatt der soliden Hintergrund Farbe für den oberen Bildschirm.",
|
||||
"ESHOP_INVALID_ERROR": "Dieser eShop ist ungültig und kann nicht\nmit DarkStore geladen werden.\nÜberprüfe ob eventuell ein Syntax-Fehler vorliegt?",
|
||||
"ESHOP_TOO_NEW": "Diese Version von DarkStore ist\nzu alt um diesen eShop zu benutzen.\nBitte aktualisiere zur neusten Version.",
|
||||
"ESHOP_TOO_OLD": "Dieser eShop ist veraltet und kann nicht\nmit dieser Version von DarkStore benutzt werden.\nBitte frage den Ersteller um dies zu aktualisieren.",
|
||||
"EXECUTE_ENTRY": "Möchtest du diesen Eintrag ausführen?",
|
||||
"EXIT_APP": "Verlasse DarkStore",
|
||||
"FETCHING_METADATA": "Rufe alte Metadaten ab...",
|
||||
"FETCHING_RECOMMENDED_ESHOP": "Empfohlener eShop abrufen...",
|
||||
"FILES_HOSTING_ANONYKU": "Anonyku zum Hosten von Dateien",
|
||||
"FILE_EXTRACTED": "Datei entpackt.",
|
||||
"FILE_SLASH": "Es scheint, als wäre ein '/' enthalten, das nicht unterstützt wird.\nBitte änder 'file' in nur den Dateinamen.",
|
||||
"FILES_EXTRACTED": "Dateien entpackt.",
|
||||
"FILTER_TO": "Fitern nach:",
|
||||
"GRID": "Gitter",
|
||||
"GUI_SETTINGS": "GUI-Einstellungen",
|
||||
"GUI_SETTINGS_BTN": "GUI-Einstellungen...",
|
||||
"INCLUDE_IN_RESULTS": "In Ergebnisse miteinbeziehen:",
|
||||
"INSTALL_GHOST_ESHOP": "Installiere DarkStore...",
|
||||
"INVALID_ESHOP": "Ungültiger eShop",
|
||||
"KEY_CONTINUE": "Drücke eine Taste zum fortfahren.",
|
||||
"LANGUAGE": "Sprache",
|
||||
"LAST_UPDATED": "Zuletzt aktualisiert",
|
||||
"LIST": "Liste",
|
||||
"LOADING_SPRITESHEET": "Lade Spritesheet %i von %i...",
|
||||
"MEDIATYPE_NAND": "Medientyp NAND",
|
||||
"MEDIATYPE_SD": "Medientyp SD",
|
||||
"MOVE_ERROR": "Verschiebe-Fehler!",
|
||||
"NO": "Nein",
|
||||
"NO_ADDITIONAL_CONTENT_AVAILABLE": "Kein zusätzlicher Inhalt verfügbar",
|
||||
"NO_DOWNLOADS_AVAILABLE": "Keine Downloads verfügbar",
|
||||
"NO_SCREENSHOTS_AVAILABLE": "Keine Bildschirmfoto verfügbar",
|
||||
"NO_SIZE": "Keine Größe",
|
||||
"NOT_IMPLEMENTED": "Noch nicht implementiert",
|
||||
"RECOMMENDED_ESHOP": "Empfohlener eShop",
|
||||
"REVISION": "Revision",
|
||||
"SCREENSHOT": "Bildschirmfoto %d / %d",
|
||||
"SCREENSHOT_COULD_NOT_LOAD": "Bildschirmfoto konnte nicht geladen werden.",
|
||||
"SCREENSHOT_INSTRUCTIONS": "Drücken Sie change zum Ändern und zum Zoomen",
|
||||
"SEARCH_FILTERS": "Suche und Filters",
|
||||
"SELECT_ESHOP": "Wechsel eShop",
|
||||
"SELECT_ESHOP_2": "Wähle einen eShop",
|
||||
"SELECT_DIR": "Wähle einen Ordner",
|
||||
"SELECT_LANG": "Wähle eine Sprache",
|
||||
"SETTINGS": "Einstellungen",
|
||||
"SHEET_SLASH": "Es scheint, als wäre ein '/' enthalten, das nicht unterstützt wird.\nBitte änder 'sheet' in nur den Dateinamen.",
|
||||
"SHORTCUT_CREATED": "Verknüpfung erstellt!",
|
||||
"SIZE": "Größe",
|
||||
"SORT_BY": "Sortieren nach",
|
||||
"SORTING": "Sortierung",
|
||||
"START_SELECT": "Drücke START um den aktuellen Ordner auszuwählen",
|
||||
"STORE_INFO": "Informationen speichern",
|
||||
"SYNTAX_ERROR": "Syntax-Fehler!",
|
||||
"TITLE": "Titel",
|
||||
"TOP_STYLE": "Top-Stil",
|
||||
"UNSUPPORTED_ESHOP_VERSION": "Die Version dieses eShop wird nicht unterstützt.",
|
||||
"UPDATE_AVAILABLE": "Aktualisierung verfügbar!",
|
||||
"UPDATE_DONE": "Aktualisierung abgeschlossen! Bitte öffne DarkStore neu.",
|
||||
"UPDATE_NOT_AVAILABLE": "Keine Aktualisierungen verfügbar!",
|
||||
"UPDATING_ESHOP": "Aktualisiere eShop...",
|
||||
"UPDATING_SPRITE_SHEET": "Aktualisiere Spritesheet...",
|
||||
"UPDATING_SPRITE_SHEET2": "Aktualisiere Spritesheet %i von %i...",
|
||||
"VERSION": "Version",
|
||||
"WEBSITE": "Volle Credits & Changelog finden Sie auf Ghosteshop.com",
|
||||
"YES": "Ja"
|
||||
}
|
||||
+123
-123
@@ -1,124 +1,124 @@
|
||||
{
|
||||
"ARGUMENT_INVALID": "Argument invalid.\nPlease check the xml file for proper arguments.",
|
||||
"ASCENDING": "Ascending",
|
||||
"AUTHOR": "Author",
|
||||
"AUTO_UPDATE_ESHOP": "Auto-update eShop",
|
||||
"AUTO_UPDATE_ESHOP_DESC": "With this, the last used eShop will be updated automatically when launching DarkStore.",
|
||||
"AUTO_UPDATE_DS": "Auto-update DarkStore",
|
||||
"AUTO_UPDATE_DS_DESC": "When enabled, DarkStore will check for updates every time it's opened.",
|
||||
"AUTO_UPDATE_SETTINGS": "Auto-Update Settings",
|
||||
"AUTO_UPDATE_SETTINGS_BTN": "Auto-update settings...",
|
||||
"AVAILABLE_DOWNLOADS": "Available Downloads",
|
||||
"BOOT_TITLE": "Would you like to boot this title?",
|
||||
"CATEGORY": "Category",
|
||||
"CHANGE_3DSX_PATH": "Change 3DSX path",
|
||||
"CHANGE_ARCHIVE_PATH": "Change archive path",
|
||||
"CHANGE_NDS_PATH": "Change NDS path",
|
||||
"CHANGE_SHORTCUT_PATH": "Change shortcut path",
|
||||
"CHANGELOG": "Changelog",
|
||||
"CHECK_ESHOP_UPDATES": "Checking for eShop updates...",
|
||||
"CHECK_DS_UPDATES": "Checking for DarkStore updates...",
|
||||
"CITRA_BIGN_ICON": "Citra & Nintendo for the Icon",
|
||||
"CONFIRM_OR_CANCEL": "Press \uE000 to confirm, \uE001 to cancel.",
|
||||
"CONNECT_WIFI": "Please Connect to WiFi.",
|
||||
"CONSOLE": "Console",
|
||||
"CONTRIBUTOR_TRANSLATORS": "- All Translators & Contributors",
|
||||
"COPY_ERROR": "Copy Error!",
|
||||
"CREATE_SHORTCUT": "Would you like to create a shortcut?",
|
||||
"CREDITS": "Credits",
|
||||
"CURRENT_VERSION": "Current version: ",
|
||||
"CURRENTLY_EXTRACTING": "Currently extracting:\n",
|
||||
"CUSTOM_FONT": "Use Custom Font",
|
||||
"CUSTOM_FONT_DESC": "If enabled, 'sdmc:/3ds/DarkStore/font.bcfnt' will be used instead of the system font, if found.",
|
||||
"DELETE_ERROR": "Delete Error!",
|
||||
"DELETE_PROMPT": "Are you sure you want to delete this Directory?",
|
||||
"DELETE_UNNEEDED_FILE": "Deleting unneeded file...",
|
||||
"DESCENDING": "Descending",
|
||||
"DIRECTION": "Direction",
|
||||
"DIRECTORY_SETTINGS": "Directory Settings",
|
||||
"DIRECTORY_SETTINGS_BTN": "Directory settings...",
|
||||
"DISABLE_AUTOUPDATE_ESHOP": "Disable auto-update eShop on boot",
|
||||
"DISABLE_UPDATE_CHECK": "Disable self-updating",
|
||||
"DONE": "Done!",
|
||||
"DOWNLOAD_ERROR": "Download Error!",
|
||||
"DOWNLOAD_FAILED": "Download Failed!",
|
||||
"DOWNLOADING_ESHOP": "Downloading eShop...",
|
||||
"DOWNLOADING_ESHOP_DB": "Downloading eShop...",
|
||||
"DOWNLOADING_GHOST_ESHOP": "Downloading DarkStore...",
|
||||
"DOWNLOADING_COMPATIBLE_FONT": "Downloading compatible font...",
|
||||
"DOWNLOADING_SPRITE_SHEET": "Downloading Spritesheet...",
|
||||
"DOWNLOADING_SPRITE_SHEET2": "Downloading Spritesheet %i of %i...",
|
||||
"ESHOP_BG": "Use eShop BG",
|
||||
"ESHOP_BG_DESC": "When enabled, the eShop's provided BG will be shown instead of the solid BG color for the top screen.",
|
||||
"ESHOP_INVALID_ERROR": "This eShop is invalid and cannot be\nloaded with DarkStore.\nMaybe check if there are any Syntax errors?",
|
||||
"ESHOP_TOO_NEW": "Your version of DarkStore is\ntoo old to use this eShop.\nPlease update to the latest version.",
|
||||
"ESHOP_TOO_OLD": "This eShop is outdated and cannot be used\nwith this version of DarkStore.\nPlease ask the creator to update it.",
|
||||
"ENABLE_AUTOUPDATE_ESHOP": "Enable auto-update eShop on boot",
|
||||
"ENABLE_UPDATE_CHECK": "Enable self-updating",
|
||||
"ENTER_DESC_SHORTCUT": "Enter the shortcut description.",
|
||||
"ENTER_SEARCH": "Enter what you like to search.",
|
||||
"ENTER_SHORTCUT_FILENAME": "Enter the shortcut filename (without extension).",
|
||||
"ENTER_TITLE_SHORTCUT": "Enter the shortcut title.",
|
||||
"ENTER_URL": "Enter the URL of the eShop.",
|
||||
"ENTRIES": "Entries",
|
||||
"EXECUTE_ENTRY": "Would you like to execute this entry?",
|
||||
"EXIT_APP": "Exit DarkStore",
|
||||
"FETCHING_METADATA": "Fetching old metadata...",
|
||||
"FETCHING_RECOMMENDED_ESHOP": "Fetching recommended eShop...",
|
||||
"FILE_EXTRACTED": "file extracted.",
|
||||
"FILES_HOSTING_ANONYKU": "Anonyku For Hosting Files",
|
||||
"FILE_SLASH": "Seems like a '/' is included, which is not supported.\nPlease change 'file' to filename only.",
|
||||
"FILES_EXTRACTED": "files extracted.",
|
||||
"FILTER_TO": "Filter to:",
|
||||
"GRID": "Grid",
|
||||
"GUI_SETTINGS": "GUI Settings",
|
||||
"GUI_SETTINGS_BTN": "GUI settings...",
|
||||
"INCLUDE_IN_RESULTS": "Include in results:",
|
||||
"INSTALL_GHOST_ESHOP": "Installing DarkStore...",
|
||||
"INVALID_ESHOP": "Invalid eShop",
|
||||
"KEY_CONTINUE": "Press any key to continue.",
|
||||
"LANGUAGE": "Language",
|
||||
"LAST_UPDATED": "Last updated",
|
||||
"LIST": "List",
|
||||
"LOADING_SPRITESHEET": "Loading Spritesheet %i of %i...",
|
||||
"MEDIATYPE_NAND": "MediaType NAND",
|
||||
"MEDIATYPE_SD": "MediaType SD",
|
||||
"MOVE_ERROR": "Move Error!",
|
||||
"NO": "No",
|
||||
"NO_ADDITIONAL_CONTENT_AVAILABLE": "No Additional Content Available",
|
||||
"NO_DOWNLOADS_AVAILABLE": "No downloads available",
|
||||
"NO_SIZE": "No Size",
|
||||
"NO_SCREENSHOTS_AVAILABLE": "No Screenshots available",
|
||||
"NOT_IMPLEMENTED": "Not Implemented Yet",
|
||||
"RECOMMENDED_ESHOP": "Recommended eShop",
|
||||
"REVISION": "Revision",
|
||||
"SCREENSHOT": "Screenshot %d / %d",
|
||||
"SCREENSHOT_COULD_NOT_LOAD": "Screenshot could not be loaded.",
|
||||
"SCREENSHOT_INSTRUCTIONS": "Press to change and to zoom",
|
||||
"SEARCH_FILTERS": "Search and Filters",
|
||||
"SELECT_ESHOP": "Select eShop",
|
||||
"SELECT_ESHOP_2": "Select a eShop",
|
||||
"SELECT_DIR": "Select a directory",
|
||||
"SELECT_LANG": "Choose the language",
|
||||
"SETTINGS": "Settings",
|
||||
"SHEET_SLASH": "Seems like a '/' is included, which is not supported.\nPlease change 'sheet' to filename only.",
|
||||
"SHORTCUT_CREATED": "Shortcut created!",
|
||||
"SIZE": "Size",
|
||||
"SORT_BY": "Sort By",
|
||||
"SORTING": "Sorting",
|
||||
"START_SELECT": "Press START to select the current folder",
|
||||
"STORE_INFO": "Store Info",
|
||||
"SYNTAX_ERROR": "Syntax Error!",
|
||||
"TITLE": "Title",
|
||||
"TOP_STYLE": "Top Style",
|
||||
"UNSUPPORTED_ESHOP_VERSION": "The version of this eShop is unsupported.",
|
||||
"UPDATE_AVAILABLE": "Update Available!",
|
||||
"UPDATE_DONE": "Update done! Please re-open DarkStore.",
|
||||
"UPDATE_NOT_AVAILABLE": "No Updates Available!",
|
||||
"UPDATING_ESHOP": "Updating eShop...",
|
||||
"UPDATING_SPRITE_SHEET": "Updating Spritesheet...",
|
||||
"UPDATING_SPRITE_SHEET2": "Updating Spritesheet %i of %i...",
|
||||
"VERSION": "Version",
|
||||
"WEBSITE": "Full Credits & Changelog Can Be Found On Ghosteshop.com",
|
||||
"YES": "Yes"
|
||||
{
|
||||
"ARGUMENT_INVALID": "Argument invalid.\nPlease check the xml file for proper arguments.",
|
||||
"ASCENDING": "Ascending",
|
||||
"AUTHOR": "Author",
|
||||
"AUTO_UPDATE_ESHOP": "Auto-update eShop",
|
||||
"AUTO_UPDATE_ESHOP_DESC": "With this, the last used eShop will be updated automatically when launching DarkStore.",
|
||||
"AUTO_UPDATE_DS": "Auto-update DarkStore",
|
||||
"AUTO_UPDATE_DS_DESC": "When enabled, DarkStore will check for updates every time it's opened.",
|
||||
"AUTO_UPDATE_SETTINGS": "Auto-Update Settings",
|
||||
"AUTO_UPDATE_SETTINGS_BTN": "Auto-update settings...",
|
||||
"AVAILABLE_DOWNLOADS": "Available Downloads",
|
||||
"BOOT_TITLE": "Would you like to boot this title?",
|
||||
"CATEGORY": "Category",
|
||||
"CHANGE_3DSX_PATH": "Change 3DSX path",
|
||||
"CHANGE_ARCHIVE_PATH": "Change archive path",
|
||||
"CHANGE_NDS_PATH": "Change NDS path",
|
||||
"CHANGE_SHORTCUT_PATH": "Change shortcut path",
|
||||
"CHANGELOG": "Changelog",
|
||||
"CHECK_ESHOP_UPDATES": "Checking for eShop updates...",
|
||||
"CHECK_DS_UPDATES": "Checking for DarkStore updates...",
|
||||
"CITRA_BIGN_ICON": "Citra & Nintendo for the Icon",
|
||||
"CONFIRM_OR_CANCEL": "Press \uE000 to confirm, \uE001 to cancel.",
|
||||
"CONNECT_WIFI": "Please Connect to WiFi.",
|
||||
"CONSOLE": "Console",
|
||||
"CONTRIBUTOR_TRANSLATORS": "- All Translators & Contributors",
|
||||
"COPY_ERROR": "Copy Error!",
|
||||
"CREATE_SHORTCUT": "Would you like to create a shortcut?",
|
||||
"CREDITS": "Credits",
|
||||
"CURRENT_VERSION": "Current version: ",
|
||||
"CURRENTLY_EXTRACTING": "Currently extracting:\n",
|
||||
"CUSTOM_FONT": "Use Custom Font",
|
||||
"CUSTOM_FONT_DESC": "If enabled, 'sdmc:/3ds/DarkStore/font.bcfnt' will be used instead of the system font, if found.",
|
||||
"DELETE_ERROR": "Delete Error!",
|
||||
"DELETE_PROMPT": "Are you sure you want to delete this Directory?",
|
||||
"DELETE_UNNEEDED_FILE": "Deleting unneeded file...",
|
||||
"DESCENDING": "Descending",
|
||||
"DIRECTION": "Direction",
|
||||
"DIRECTORY_SETTINGS": "Directory Settings",
|
||||
"DIRECTORY_SETTINGS_BTN": "Directory settings...",
|
||||
"DISABLE_AUTOUPDATE_ESHOP": "Disable auto-update eShop on boot",
|
||||
"DISABLE_UPDATE_CHECK": "Disable self-updating",
|
||||
"DONE": "Done!",
|
||||
"DOWNLOAD_ERROR": "Download Error!",
|
||||
"DOWNLOAD_FAILED": "Download Failed!",
|
||||
"DOWNLOADING_ESHOP": "Downloading eShop...",
|
||||
"DOWNLOADING_ESHOP_DB": "Downloading eShop...",
|
||||
"DOWNLOADING_DARKSTORE": "Downloading DarkStore...",
|
||||
"DOWNLOADING_COMPATIBLE_FONT": "Downloading compatible font...",
|
||||
"DOWNLOADING_SPRITE_SHEET": "Downloading Spritesheet...",
|
||||
"DOWNLOADING_SPRITE_SHEET2": "Downloading Spritesheet %i of %i...",
|
||||
"ESHOP_BG": "Use eShop BG",
|
||||
"ESHOP_BG_DESC": "When enabled, the eShop's provided BG will be shown instead of the solid BG color for the top screen.",
|
||||
"ESHOP_INVALID_ERROR": "This eShop is invalid and cannot be\nloaded with DarkStore.\nMaybe check if there are any Syntax errors?",
|
||||
"ESHOP_TOO_NEW": "Your version of DarkStore is\ntoo old to use this eShop.\nPlease update to the latest version.",
|
||||
"ESHOP_TOO_OLD": "This eShop is outdated and cannot be used\nwith this version of DarkStore.\nPlease ask the creator to update it.",
|
||||
"ENABLE_AUTOUPDATE_ESHOP": "Enable auto-update eShop on boot",
|
||||
"ENABLE_UPDATE_CHECK": "Enable self-updating",
|
||||
"ENTER_DESC_SHORTCUT": "Enter the shortcut description.",
|
||||
"ENTER_SEARCH": "Enter what you like to search.",
|
||||
"ENTER_SHORTCUT_FILENAME": "Enter the shortcut filename (without extension).",
|
||||
"ENTER_TITLE_SHORTCUT": "Enter the shortcut title.",
|
||||
"ENTER_URL": "Enter the URL of the eShop.",
|
||||
"ENTRIES": "Entries",
|
||||
"EXECUTE_ENTRY": "Would you like to execute this entry?",
|
||||
"EXIT_APP": "Exit DarkStore",
|
||||
"FETCHING_METADATA": "Fetching old metadata...",
|
||||
"FETCHING_RECOMMENDED_ESHOP": "Fetching recommended eShop...",
|
||||
"FILE_EXTRACTED": "file extracted.",
|
||||
"FILES_HOSTING_ANONYKU": "Anonyku For Hosting Files",
|
||||
"FILE_SLASH": "Seems like a '/' is included, which is not supported.\nPlease change 'file' to filename only.",
|
||||
"FILES_EXTRACTED": "files extracted.",
|
||||
"FILTER_TO": "Filter to:",
|
||||
"GRID": "Grid",
|
||||
"GUI_SETTINGS": "GUI Settings",
|
||||
"GUI_SETTINGS_BTN": "GUI settings...",
|
||||
"INCLUDE_IN_RESULTS": "Include in results:",
|
||||
"INSTALL_DARKSTORE": "Installing DarkStore...",
|
||||
"INVALID_ESHOP": "Invalid eShop",
|
||||
"KEY_CONTINUE": "Press any key to continue.",
|
||||
"LANGUAGE": "Language",
|
||||
"LAST_UPDATED": "Last updated",
|
||||
"LIST": "List",
|
||||
"LOADING_SPRITESHEET": "Loading Spritesheet %i of %i...",
|
||||
"MEDIATYPE_NAND": "MediaType NAND",
|
||||
"MEDIATYPE_SD": "MediaType SD",
|
||||
"MOVE_ERROR": "Move Error!",
|
||||
"NO": "No",
|
||||
"NO_ADDITIONAL_CONTENT_AVAILABLE": "No Additional Content Available",
|
||||
"NO_DOWNLOADS_AVAILABLE": "No downloads available",
|
||||
"NO_SIZE": "No Size",
|
||||
"NO_SCREENSHOTS_AVAILABLE": "No Screenshots available",
|
||||
"NOT_IMPLEMENTED": "Not Implemented Yet",
|
||||
"RECOMMENDED_ESHOP": "Recommended eShop",
|
||||
"REVISION": "Revision",
|
||||
"SCREENSHOT": "Screenshot %d / %d",
|
||||
"SCREENSHOT_COULD_NOT_LOAD": "Screenshot could not be loaded.",
|
||||
"SCREENSHOT_INSTRUCTIONS": "Press to change and to zoom",
|
||||
"SEARCH_FILTERS": "Search and Filters",
|
||||
"SELECT_ESHOP": "Select eShop",
|
||||
"SELECT_ESHOP_2": "Select a eShop",
|
||||
"SELECT_DIR": "Select a directory",
|
||||
"SELECT_LANG": "Choose the language",
|
||||
"SETTINGS": "Settings",
|
||||
"SHEET_SLASH": "Seems like a '/' is included, which is not supported.\nPlease change 'sheet' to filename only.",
|
||||
"SHORTCUT_CREATED": "Shortcut created!",
|
||||
"SIZE": "Size",
|
||||
"SORT_BY": "Sort By",
|
||||
"SORTING": "Sorting",
|
||||
"START_SELECT": "Press START to select the current folder",
|
||||
"STORE_INFO": "Store Info",
|
||||
"SYNTAX_ERROR": "Syntax Error!",
|
||||
"TITLE": "Title",
|
||||
"TOP_STYLE": "Top Style",
|
||||
"UNSUPPORTED_ESHOP_VERSION": "The version of this eShop is unsupported.",
|
||||
"UPDATE_AVAILABLE": "Update Available!",
|
||||
"UPDATE_DONE": "Update done! Please re-open DarkStore.",
|
||||
"UPDATE_NOT_AVAILABLE": "No Updates Available!",
|
||||
"UPDATING_ESHOP": "Updating eShop...",
|
||||
"UPDATING_SPRITE_SHEET": "Updating Spritesheet...",
|
||||
"UPDATING_SPRITE_SHEET2": "Updating Spritesheet %i of %i...",
|
||||
"VERSION": "Version",
|
||||
"WEBSITE": "Website In Progress",
|
||||
"YES": "Yes"
|
||||
}
|
||||
@@ -1,124 +0,0 @@
|
||||
{
|
||||
"ARGUMENT_INVALID": "Argumento inválido.\nVerifique el archivo xml para ver los argumentos adecuados.",
|
||||
"ASCENDING": "Ascendente",
|
||||
"AUTHOR": "Autor",
|
||||
"AUTO_UPDATE_SETTINGS": "Auto-Update Settings",
|
||||
"AUTO_UPDATE_SETTINGS_BTN": "Configuración de actualización automática",
|
||||
"AUTO_UPDATE_ESHOP": "Actualización automática de eShop",
|
||||
"AUTO_UPDATE_DS": "Actualización automática de DarkStore",
|
||||
"AUTO_UPDATE_ESHOP_DESC": "Con esto, la última eShop utilizada se actualizará automáticamente al iniciar DarkStore.",
|
||||
"AUTO_UPDATE_DS_DESC": "Cuando está habilitado, DarkStore buscará actualizaciones cada vez que se abra.",
|
||||
"AVAILABLE_DOWNLOADS": "Descargas disponibles",
|
||||
"BOOT_TITLE": "¿Te gustaría ejecutar este título?",
|
||||
"CATEGORY": "Categoría",
|
||||
"CHANGE_3DSX_PATH": "Cambiar la ruta 3DSX",
|
||||
"CHANGE_ARCHIVE_PATH": "Cambiar la ruta del archivo",
|
||||
"CHANGE_NDS_PATH": "Cambiar la ruta de NDS",
|
||||
"CHANGE_SHORTCUT_PATH": "Cambiar ruta de acceso directo",
|
||||
"CHANGELOG": "Registro de cambios",
|
||||
"CHECK_ESHOP_UPDATES": "Comprobando actualizaciones de DarkStore...",
|
||||
"CHECK_DS_UPDATES": "Buscando actualizaciones de DarkStore...",
|
||||
"CITRA_BIGN_ICON": "Citra y Nintendo para el icono",
|
||||
"CONFIRM_OR_CANCEL": "Preciona \uE000 para confirmar, \uE001 para cancelar.",
|
||||
"CONNECT_WIFI": "Por favor conéctese al WiFi.",
|
||||
"CONSOLE": "Consola",
|
||||
"CONTRIBUTOR_TRANSLATORS": "- Todos los traductores y colaboradores",
|
||||
"COPY_ERROR": "Error de copia!",
|
||||
"CREATE_SHORTCUT": "Le gustaría crear un atajo?",
|
||||
"CREDITS": "Créditos",
|
||||
"CURRENT_VERSION": "Versión actual: ",
|
||||
"CURRENTLY_EXTRACTING": "Extrayendo actualmente:\n",
|
||||
"CUSTOM_FONT": "Usar fuente personalizada",
|
||||
"CUSTOM_FONT_DESC": "Si está habilitado, 'sdmc:/3ds/DarkStore/font.bcfnt' se utilizará en lugar de la fuente del sistema, si se encuentra.",
|
||||
"DELETE_ERROR": "Eliminar error!",
|
||||
"DELETE_PROMPT": "¿Está seguro de que desea eliminar este directorio?",
|
||||
"DELETE_UNNEEDED_FILE": "Eliminar archivo innecesario...",
|
||||
"DESCENDING": "Descendiendo",
|
||||
"DIRECTION": "Dirección",
|
||||
"DIRECTORY_SETTINGS": "Configuración de directorio",
|
||||
"DIRECTORY_SETTINGS_BTN": "Configuración de directorio...",
|
||||
"DISABLE_AUTOUPDATE_ESHOP": "Deshabilitar la actualización automática de UniStore al arrancar",
|
||||
"DISABLE_UPDATE_CHECK": "Deshabilitar actualización automática",
|
||||
"DONE": "Hecho!",
|
||||
"DOWNLOAD_ERROR": "Error de descarga!",
|
||||
"DOWNLOAD_FAILED": "no se pudo descargar!",
|
||||
"DOWNLOADING_COMPATIBLE_FONT": "Descargando fuente compatible...",
|
||||
"DOWNLOADING_SPRITE_SHEET": "Descarga de Spritesheet...",
|
||||
"DOWNLOADING_SPRITE_SHEET2": "Descarga de Spritesheet %i of %i...",
|
||||
"DOWNLOADING_ESHOP_DB": "Descargando eShop...",
|
||||
"DOWNLOADING_GHOST_ESHOP": "Descargando DarkStore...",
|
||||
"DOWNLOADING_ESHOP": "Descargando eShop...",
|
||||
"ESHOP_BG": "Utilice eShop BG",
|
||||
"ESHOP_BG_DESC": "Cuando está habilitado, la eShop's prevista BG Se mostrará en lugar del sólido BG color para la pantalla superior.",
|
||||
"ESHOP_INVALID_ERROR": "Esta eShop no es válida y no se puede\nCargada con DarkStore.\nQuizás verifique si hay algún error de sintaxis?",
|
||||
"ESHOP_TOO_NEW": "Tu versión de DarkStore es \nDemasiado antiguo para usar esta eShop.\nActualice a la última versión.",
|
||||
"ESHOP_TOO_OLD": "Esta eShop está desactualizada y no se puede utilizar\ncon esta versión de DarkStore.\nPide al creador que lo actualice.",
|
||||
"ENABLE_AUTOUPDATE_ESHOP": "Habilitar eShop de actualización automática al arrancar",
|
||||
"ENABLE_UPDATE_CHECK": "Habilitar la actualización automática",
|
||||
"ENTER_DESC_SHORTCUT": "Ingrese la descripción del acceso directo.",
|
||||
"ENTER_SEARCH": "Ingrese la busqueda.",
|
||||
"ENTER_SHORTCUT_FILENAME": "Ingrese el nombre del archivo de acceso directo (sin extensión).",
|
||||
"ENTER_TITLE_SHORTCUT": "Ingrese el título del acceso directo.",
|
||||
"ENTER_URL": "Ingrese la URL de la eShop.",
|
||||
"ENTRIES": "Entradas",
|
||||
"EXECUTE_ENTRY": "¿Le gustaría ejecutar esta entrada?",
|
||||
"EXIT_APP": "Salir de DarkStore",
|
||||
"FETCHING_METADATA": "Obteniendo metadatos antiguos...",
|
||||
"FETCHING_RECOMMENDED_ESHOP": "Fetching recommended eShop...",
|
||||
"FILE_EXTRACTED": "Archivo extraído.",
|
||||
"FILES_HOSTING_ANONYKU": "Anonyku para alojar archivos",
|
||||
"FILE_SLASH": "Parece un '/' está incluido, que no es compatible.\nPor favor cambia 'archivo' solo al nombre de archivo.",
|
||||
"FILES_EXTRACTED": "archivos extraídos.",
|
||||
"FILTER_TO": "Filtrar a:",
|
||||
"GRID": "Cuadrícula",
|
||||
"GUI_SETTINGS": "Configuración de GUI",
|
||||
"GUI_SETTINGS_BTN": "Configuración de GUI...",
|
||||
"INCLUDE_IN_RESULTS": "Incluir en los resultados:",
|
||||
"INSTALL_GHOST_ESHOP": "Instalar DarkStore...",
|
||||
"INVALID_ESHOP": "EShop no válida",
|
||||
"KEY_CONTINUE": "Pulse cualquier tecla para continuar.",
|
||||
"LANGUAGE": "Idioma",
|
||||
"LAST_UPDATED": "Última actualización",
|
||||
"LIST": "Lista",
|
||||
"LOADING_SPRITESHEET": "Cargando Spritesheet %i of %i...",
|
||||
"MEDIATYPE_NAND": "Tipo de medio NAND",
|
||||
"MEDIATYPE_SD": "Tipo de medio SD",
|
||||
"MOVE_ERROR": "Error al mover!",
|
||||
"NO": "No",
|
||||
"NO_ADDITIONAL_CONTENT_AVAILABLE": "No hay contenido adicional disponible",
|
||||
"NO_DOWNLOADS_AVAILABLE": "No hay descargas disponibles",
|
||||
"NOT_IMPLEMENTED": "Aún no implementada",
|
||||
"NO_SCREENSHOTS_AVAILABLE": "No hay Captura de pantalla disponible",
|
||||
"NO_SIZE": "Sin tamaño",
|
||||
"RECOMMENDED_ESHOP": "eShop recomendado",
|
||||
"REVISION": "Revisión",
|
||||
"SCREENSHOT": "Captura de pantalla %d / %d",
|
||||
"SCREENSHOT_COULD_NOT_LOAD": "No se pudo cargar Captura de pantalla.",
|
||||
"SCREENSHOT_INSTRUCTIONS": "Presione para cambiar y para hacer zoom",
|
||||
"SEARCH_FILTERS": "Búsqueda y filtros",
|
||||
"SELECT_DIR": "Seleccionar un directorio",
|
||||
"SELECT_LANG": "Elige el idioma",
|
||||
"SELECT_ESHOP": "Seleccione eShop",
|
||||
"SELECT_ESHOP_2": "Seleccione una eShop",
|
||||
"SETTINGS": "Configuraciones",
|
||||
"SHEET_SLASH": "Parece un '/' está incluido, que no es compatible.\nPor favor cambia 'hoja' solo al nombre de archivo.",
|
||||
"SHORTCUT_CREATED": "Acceso directo creado!",
|
||||
"SIZE": "Talla",
|
||||
"SORT_BY": "Ordenar por",
|
||||
"SORTING": "Clasificación",
|
||||
"START_SELECT": "Presione START para seleccionar la carpeta actual",
|
||||
"STORE_INFO": "Información de la tienda",
|
||||
"SYNTAX_ERROR": "Error de sintaxis!",
|
||||
"TITLE": "Título",
|
||||
"TOP_STYLE": "Estilo máximo",
|
||||
"UNSUPPORTED_ESHOP_VERSION": "La versión de esta eShop no es compatible.",
|
||||
"UPDATE_AVAILABLE": "Actualización disponible!",
|
||||
"UPDATE_DONE": "Actualizacion realizada! Vuelve a abrir DarkStore.",
|
||||
"UPDATE_NOT_AVAILABLE": "No hay actualizaciones disponibles!",
|
||||
"UPDATING_SPRITE_SHEET": "Actualización de Spritesheet...",
|
||||
"UPDATING_SPRITE_SHEET2": "Actualización de Spritesheet %i of %i...",
|
||||
"UPDATING_ESHOP": "Actualización de eShop...",
|
||||
"VERSION": "Versión",
|
||||
"WEBSITE": "Los créditos completos y el registro de cambios se pueden encontrar en Ghosteshop.com",
|
||||
"YES": "Si"
|
||||
}
|
||||
@@ -1,124 +0,0 @@
|
||||
{
|
||||
"ARGUMENT_INVALID": "Argument non valide.\nVeuillez vérifier le fichier xml pour les arguments appropriés.",
|
||||
"ASCENDING": "Croissant",
|
||||
"AUTHOR": "Auteur",
|
||||
"AUTO_UPDATE_SETTINGS": "Paramètres de mise à jour automatique",
|
||||
"AUTO_UPDATE_SETTINGS_BTN": "Paramètres de mise à jour automatique",
|
||||
"AUTO_UPDATE_ESHOP": "Mise à jour auto de l'eShop",
|
||||
"AUTO_UPDATE_DS": "Mise à jour auto de DarkStore",
|
||||
"AUTO_UPDATE_ESHOP_DESC": "Avec cela, le dernier eShop utilisé sera mis à jour automatiquement lors du lancement de DarkStore.",
|
||||
"AUTO_UPDATE_DS_DESC": "Lorsque cette option est activé, DarkStore vérifiera les mises à jour à chaque fois qu'il est ouvert.",
|
||||
"AVAILABLE_DOWNLOADS": "Téléchargements Disponibles",
|
||||
"BOOT_TITLE": "Souhaitez-vous démarrer ce titre ?",
|
||||
"CATEGORY": "Catégories",
|
||||
"CHANGE_3DSX_PATH": "Changer le chemin des 3DSX",
|
||||
"CHANGE_ARCHIVE_PATH": "Changer le chemin archive",
|
||||
"CHANGE_NDS_PATH": "Changer le chemin NDS",
|
||||
"CHANGE_SHORTCUT_PATH": "Modifier le chemin du raccourci",
|
||||
"CHANGELOG": "Changelog",
|
||||
"CHECK_ESHOP_UPDATES": "Vérification des mises à jour de l'eShop...",
|
||||
"CHECK_DS_UPDATES": "Vérification des mises à jour du DarkStore...",
|
||||
"CITRA_BIGN_ICON": "Citra & Nintendo pour les Icones",
|
||||
"CONFIRM_OR_CANCEL": "Appuyer \uE000 pour confirmer, \uE001 ou annuler.",
|
||||
"CONNECT_WIFI": "Veuillez vous connecter au wifi.",
|
||||
"CONSOLE": "Console",
|
||||
"CONTRIBUTOR_TRANSLATORS": "- Tout les Traducteurs & Contributeurs",
|
||||
"COPY_ERROR": "Erreur de copie !",
|
||||
"CREATE_SHORTCUT": "Souhaitez-vous créer un raccourci ?",
|
||||
"CREDITS": "Crédits",
|
||||
"CURRENT_VERSION": "Version actuel: ",
|
||||
"CURRENTLY_EXTRACTING": "Extraction en cours:\n",
|
||||
"CUSTOM_FONT": "Utiliser une police personnalisée",
|
||||
"CUSTOM_FONT_DESC": "Si activé, 'sdmc: /3ds/DarkStore/font.bcfnt' sera utilisé à la place de la police système, si elle est trouvée.",
|
||||
"DELETE_ERROR": "Erreur de suppresion!",
|
||||
"DELETE_PROMPT": "Voulez-vous vraiment supprimer ce répertoire ?",
|
||||
"DELETE_UNNEEDED_FILE": "Suppression du fichier inutile...",
|
||||
"DESCENDING": "Decroissant",
|
||||
"DIRECTION": "Direction",
|
||||
"DIRECTORY_SETTINGS": "Paramètres du répertoire",
|
||||
"DIRECTORY_SETTINGS_BTN": "Paramètres du répertoire...",
|
||||
"DISABLE_AUTOUPDATE_ESHOP": "Désactiver la mise à jour automatique de l'eShop au démarrage",
|
||||
"DISABLE_UPDATE_CHECK": "Désactiver la mise à jour automatique",
|
||||
"DONE": "Terminé !",
|
||||
"DOWNLOAD_ERROR": "Erreur du téléchargement !",
|
||||
"DOWNLOAD_FAILED": "Échec du téléchargement !",
|
||||
"DOWNLOADING_COMPATIBLE_FONT": "Téléchargement d'une police compatible...",
|
||||
"DOWNLOADING_SPRITE_SHEET": "Téléchargement de la feuille de Sprite...",
|
||||
"DOWNLOADING_SPRITE_SHEET2": "Téléchargement de la feuille de Sprite %i de %i...",
|
||||
"DOWNLOADING_ESHOP_DB": "Téléchargement de l'eShop...",
|
||||
"DOWNLOADING_GHOST_ESHOP": "Téléchargement de DarkStore...",
|
||||
"DOWNLOADING_ESHOP": "Téléchargement de l'eShop...",
|
||||
"ENABLE_AUTOUPDATE_ESHOP": "Activer la mise à jour automatique de l'eShop au démarrage",
|
||||
"ENABLE_UPDATE_CHECK": "Activer la mise à jour automatique",
|
||||
"ENTER_DESC_SHORTCUT": "Entrez la description du raccourci.",
|
||||
"ENTER_SEARCH": "Entrez ce que vous souhaitez rechercher.",
|
||||
"ENTER_SHORTCUT_FILENAME": "Entrez le nom de fichier du raccourci (sans extension).",
|
||||
"ENTER_TITLE_SHORTCUT": "Entrez le titre du raccourci.",
|
||||
"ENTER_URL": "Entrez l'URL de l'eShop.",
|
||||
"ENTRIES": "Entrées",
|
||||
"EXECUTE_ENTRY": "Voulez-vous exécuter cette entrée ?",
|
||||
"EXIT_APP": "Quitter DarkStore",
|
||||
"FETCHING_METADATA": "Récupération d'anciennes métadonnées...",
|
||||
"FETCHING_RECOMMENDED_ESHOP": "Récupération de la liste des différents eShop...",
|
||||
"FILE_EXTRACTED": "fichier extrait.",
|
||||
"FILES_HOSTING_ANONYKU": "Anonyku pour l'hébergement des fichiers",
|
||||
"FILE_SLASH": "On dirait qu'un '/' est inclus, ce qui n'est pas pris en charge. \nVeuillez changer 'file' en nom de fichier uniquement.",
|
||||
"FILES_EXTRACTED": "fichier extrait.",
|
||||
"FILTER_TO": "Filtrer:",
|
||||
"GRID": "Grille",
|
||||
"GUI_SETTINGS": "Paramètres interface graphique",
|
||||
"GUI_SETTINGS_BTN": "Paramètres de l'interface graphique...",
|
||||
"INCLUDE_IN_RESULTS": "Inclure dans les résultats:",
|
||||
"INSTALL_GHOST_ESHOP": "Installation de DarkStore...",
|
||||
"INVALID_ESHOP": "eShop non valide",
|
||||
"KEY_CONTINUE": "Appuyez sur n'importe quelle touche pour continuer.",
|
||||
"LANGUAGE": "Language",
|
||||
"LAST_UPDATED": "Dernière mise à jour",
|
||||
"LIST": "Liste",
|
||||
"LOADING_SPRITESHEET": "Chargement du Spritesheet %i de %i...",
|
||||
"MEDIATYPE_NAND": "MediaType NAND",
|
||||
"MEDIATYPE_SD": "MediaType SD",
|
||||
"MOVE_ERROR": "Erreur de déplacement!",
|
||||
"NO": "Non",
|
||||
"NO_ADDITIONAL_CONTENT_AVAILABLE": "Aucun contenu supplémentaire disponible",
|
||||
"NO_DOWNLOADS_AVAILABLE": "Aucun téléchargement disponible",
|
||||
"NO_SCREENSHOTS_AVAILABLE": "Acune capture disponible",
|
||||
"NO_SIZE": "Aucune taille spécifiée",
|
||||
"NOT_IMPLEMENTED": "Pas encore mis implémenté",
|
||||
"RECOMMENDED_ESHOP": "List des eShop",
|
||||
"REVISION": "Révision",
|
||||
"SCREENSHOT": "Capture %d / %d",
|
||||
"SCREENSHOT_COULD_NOT_LOAD": "La capture n'a pas pu être chargée.",
|
||||
"SCREENSHOT_INSTRUCTIONS": "Appuyez sur pour changer et pour zoomer",
|
||||
"SELECT_DIR": "Sélectionnez un dossier",
|
||||
"SELECT_LANG": "Choisissez la langue",
|
||||
"SELECT_ESHOP": "Selectionner l'eShop",
|
||||
"SELECT_ESHOP_2": "Selectionner l'eShop",
|
||||
"SEARCH_FILTERS": "Recherche et filtres",
|
||||
"SHEET_SLASH": "On dirait qu'un '/' est inclus, ce qui n'est pas pris en charge.\nVeuillez remplacer 'sheet' par le nom de fichier uniquement.",
|
||||
"SETTINGS": "Paramètres",
|
||||
"SHORTCUT_CREATED": "Raccourci créé!",
|
||||
"SIZE": "Taille",
|
||||
"SORT_BY": "Trier par",
|
||||
"SORTING": "Tri",
|
||||
"START_SELECT": "Appuyez sur START pour sélectionner le dossier actuel",
|
||||
"STORE_INFO": "Informations sur l'eShop",
|
||||
"SYNTAX_ERROR": "Erreur de syntaxe!",
|
||||
"TITLE": "Titre",
|
||||
"TOP_STYLE": "Top Style",
|
||||
"ESHOP_BG": "Utilisez la BG de l'eShop",
|
||||
"ESHOP_BG_DESC": "Lorsqu'elle est activée, la BG fournie par l'eShop sera affichée à la place de la couleur de BG unie pour l'écran supérieur.",
|
||||
"ESHOP_INVALID_ERROR": "Cet eShop n'est pas valide et ne peut pas être \nchargé avec DarkStore. \nPeut-être vérifier s'il y a des erreurs de syntaxe?",
|
||||
"ESHOP_TOO_NEW": "Votre version de DarkStore est \ntrop ancienne pour utiliser cette eShop. \nVeuillez mettre à jour vers la dernière version.",
|
||||
"ESHOP_TOO_OLD": "Cet eShop est obsolète et ne peut pas être utilisé \n avec cette version de DarkStore. \nVeuillez demander au créateur de le mettre à jour.",
|
||||
"UNSUPPORTED_ESHOP_VERSION": "La version de cet eShop n'est pas prise en charge.",
|
||||
"UPDATE_AVAILABLE": "Mise à jour disponible!",
|
||||
"UPDATE_DONE": "Mise à jour terminée! Veuillez rouvrir DarkStore.",
|
||||
"UPDATE_NOT_AVAILABLE": "Aucune mise à jour disponible!",
|
||||
"UPDATING_SPRITE_SHEET": "Mise à jour de la feuille de Sprite...",
|
||||
"UPDATING_SPRITE_SHEET2": "Mise à jour de la feuille de Sprite %i de %i...",
|
||||
"UPDATING_ESHOP": "Mise à jour de l'eShop...",
|
||||
"VERSION": "Version",
|
||||
"WEBSITE": "Les crédits et le changelog complets se trouve sur ghosteshop.com",
|
||||
"YES": "Oui"
|
||||
}
|
||||
@@ -1,124 +0,0 @@
|
||||
{
|
||||
"ARGUMENT_INVALID": "Το επιχείρημα δεν είναι έγκυρο.\nΕλέγξτε το αρχείο xml για σωστά επιχειρήματα.",
|
||||
"ASCENDING": "Ανερχόμενος",
|
||||
"AUTHOR": "Συντάκτης",
|
||||
"AUTO_UPDATE_ESHOP": "Αυτόματη ενημέρωση του eShop",
|
||||
"AUTO_UPDATE_ESHOP_DESC": "Με αυτό, το eShop που χρησιμοποιήθηκε τελευταία θα ενημερωθεί αυτόματα κατά την εκκίνηση του DarkStore.",
|
||||
"AUTO_UPDATE_DS": "Αυτόματη ενημέρωση DarkStore",
|
||||
"AUTO_UPDATE_DS_DESC": "Όταν είναι ενεργοποιημένο, το DarkStore θα ελέγχει για ενημερώσεις κάθε φορά που ανοίγει.",
|
||||
"AUTO_UPDATE_SETTINGS": "Ρυθμίσεις αυτόματης ενημέρωσης",
|
||||
"AUTO_UPDATE_SETTINGS_BTN": "Ρυθμίσεις αυτόματης ενημέρωσης...",
|
||||
"AVAILABLE_DOWNLOADS": "Διαθέσιμες λήψεις",
|
||||
"BOOT_TITLE": "Θέλετε να εκκινήσετε αυτόν τον τίτλο;",
|
||||
"CATEGORY": "Κατηγορία",
|
||||
"CHANGE_3DSX_PATH": "Αλλαγή διαδρομής 3DSX",
|
||||
"CHANGE_ARCHIVE_PATH": "Αλλαγή διαδρομής αρχειοθέτησης",
|
||||
"CHANGE_NDS_PATH": "Αλλαγή διαδρομής NDS",
|
||||
"CHANGE_SHORTCUT_PATH": "Αλλαγή διαδρομής συντόμευσης",
|
||||
"CHANGELOG": "Τσανγκολόγκ",
|
||||
"CHECK_ESHOP_UPDATES": "Έλεγχος για ενημερώσεις του eShop...",
|
||||
"CHECK_DS_UPDATES": "Έλεγχος για ενημερώσεις DarkStore...",
|
||||
"CITRA_BIGN_ICON": "Citra & Nintendo για το εικονίδιο",
|
||||
"CONFIRM_OR_CANCEL": "Τύπος \uE000 για να επιβεβαιώσετε, \uE001 να ακυρώσω.",
|
||||
"CONNECT_WIFI": "Συνδεθείτε στο WiFi.",
|
||||
"CONSOLE": "Κονσόλα",
|
||||
"CONTRIBUTOR_TRANSLATORS": "- Όλοι οι μεταφραστές και οι συνεργάτες",
|
||||
"COPY_ERROR": "Σφάλμα αντιγραφής!",
|
||||
"CREATE_SHORTCUT": "Θέλετε να δημιουργήσετε μια συντόμευση;",
|
||||
"CREDITS": "Πιστώσεις",
|
||||
"CURRENT_VERSION": "Τρέχουσα έκδοση: ",
|
||||
"CURRENTLY_EXTRACTING": "Εξαγωγή επί του παρόντος:\n",
|
||||
"CUSTOM_FONT": "Χρησιμοποιήστε προσαρμοσμένη γραμματοσειρά",
|
||||
"CUSTOM_FONT_DESC": "Εάν είναι ενεργοποιημένο, θα χρησιμοποιηθεί το 'sdmc: /3ds/DarkStore/font.bcfnt' αντί της γραμματοσειράς συστήματος, εάν βρεθεί.",
|
||||
"DELETE_ERROR": "Διαγραφή σφάλματος!",
|
||||
"DELETE_PROMPT": "Είστε βέβαιοι ότι θέλετε να διαγράψετε αυτόν τον κατάλογο;",
|
||||
"DELETE_UNNEEDED_FILE": "Διαγραφή άχρηστου αρχείου...",
|
||||
"DESCENDING": "Φθίνων",
|
||||
"DIRECTION": "Κατεύθυνση",
|
||||
"DIRECTORY_SETTINGS": "Ρυθμίσεις καταλόγου",
|
||||
"DIRECTORY_SETTINGS_BTN": "Ρυθμίσεις καταλόγου...",
|
||||
"DISABLE_AUTOUPDATE_ESHOP": "Απενεργοποιήστε την αυτόματη ενημέρωση του eShop κατά την εκκίνηση",
|
||||
"DISABLE_UPDATE_CHECK": "Απενεργοποίηση αυτόματης ενημέρωσης",
|
||||
"DONE": "Εγινε!",
|
||||
"DOWNLOAD_ERROR": "Σφάλμα λήψης!",
|
||||
"DOWNLOAD_FAILED": "Η λήψη απέτυχε!",
|
||||
"DOWNLOADING_ESHOP": "Λήψη του eShop...",
|
||||
"DOWNLOADING_ESHOP_DB": "Λήψη του eShop...",
|
||||
"DOWNLOADING_GHOST_ESHOP": "Λήψη του DarkStore...",
|
||||
"DOWNLOADING_COMPATIBLE_FONT": "Λήψη συμβατής γραμματοσειράς...",
|
||||
"DOWNLOADING_SPRITE_SHEET": "Λήψη του Spritesheet...",
|
||||
"DOWNLOADING_SPRITE_SHEET2": "Λήψη του Spritesheet %i του %i...",
|
||||
"ESHOP_BG": "Χρησιμοποιήστε το eShop BG",
|
||||
"ESHOP_BG_DESC": "Όταν είναι ενεργοποιημένο, το παρεχόμενο BG του eShop θα εμφανίζεται αντί του στερεού χρώματος BG για την επάνω οθόνη.",
|
||||
"ESHOP_INVALID_ERROR": "Αυτό το eShop δεν είναι έγκυρο και δεν μπορεί να είναι \nφορτωμένο με το DarkStore. \nΊσως ελέγξτε αν υπάρχουν σφάλματα σύνταξης;",
|
||||
"ESHOP_TOO_NEW": "Η έκδοση του DarkStore είναι\nπολύ παλιά για να χρησιμοποιήσετε αυτό το eShop.\nΕνημερώστε την τελευταία έκδοση.",
|
||||
"ESHOP_TOO_OLD": "Αυτό το eShop είναι ξεπερασμένο και δεν μπορεί να χρησιμοποιηθεί\nμε αυτήν την έκδοση του DarkStore.\nΖητήστε από τον δημιουργό να το ενημερώσει.",
|
||||
"ENABLE_AUTOUPDATE_ESHOP": "Ενεργοποίηση αυτόματης ενημέρωσης eShop κατά την εκκίνηση",
|
||||
"ENABLE_UPDATE_CHECK": "Ενεργοποίηση αυτόματης ενημέρωσης",
|
||||
"ENTER_DESC_SHORTCUT": "Εισαγάγετε την περιγραφή συντόμευσης.",
|
||||
"ENTER_SEARCH": "Εισαγάγετε ό, τι θέλετε να αναζητήσετε.",
|
||||
"ENTER_SHORTCUT_FILENAME": "Εισαγάγετε το όνομα αρχείου συντόμευσης (χωρίς επέκταση).",
|
||||
"ENTER_TITLE_SHORTCUT": "Εισαγάγετε τον τίτλο συντόμευσης.",
|
||||
"ENTER_URL": "Εισαγάγετε τη διεύθυνση URL του eShop.",
|
||||
"ENTRIES": "Συμμετοχές",
|
||||
"EXECUTE_ENTRY": "Θέλετε να εκτελέσετε αυτήν την καταχώριση;",
|
||||
"EXIT_APP": "Έξοδος από το DarkStore",
|
||||
"FETCHING_METADATA": "Ανάκτηση παλαιών μεταδεδομένων...",
|
||||
"FETCHING_RECOMMENDED_ESHOP": "Λήψη προτεινόμενου eShop...",
|
||||
"FILE_EXTRACTED": "το αρχείο εξήχθη.",
|
||||
"FILES_HOSTING_ANONYKU": "Anonyku για φιλοξενία αρχείων",
|
||||
"FILE_SLASH": "Φαίνεται ότι περιλαμβάνεται ένα '/', το οποίο δεν υποστηρίζεται.\nΑλλάξτε το 'αρχείο' μόνο σε όνομα αρχείου.",
|
||||
"FILES_EXTRACTED": "αρχεία που εξήχθησαν.",
|
||||
"FILTER_TO": "Φίλτερ το:",
|
||||
"GRID": "Πλέγμα",
|
||||
"GUI_SETTINGS": "Ρυθμίσεις GUI",
|
||||
"GUI_SETTINGS_BTN": "Ρυθμίσεις GUI...",
|
||||
"INCLUDE_IN_RESULTS": "Συμπερίληψη στα αποτελέσματα:",
|
||||
"INSTALL_GHOST_ESHOP": "Εγκατάσταση του DarkStore...",
|
||||
"INVALID_ESHOP": "Μη έγκυρο eShop",
|
||||
"KEY_CONTINUE": "Πατήστε οποιοδήποτε κουμπί για να συνεχίσετε.",
|
||||
"LANGUAGE": "Γλώσσα",
|
||||
"LAST_UPDATED": "Τελευταία ενημέρωση",
|
||||
"LIST": "Λίστα",
|
||||
"LOADING_SPRITESHEET": "Φόρτωση φύλλου Sprite %i του %i...",
|
||||
"MEDIATYPE_NAND": "Τύπος πολυμέσων NAND",
|
||||
"MEDIATYPE_SD": "Τύπος πολυμέσων SD",
|
||||
"MOVE_ERROR": "Μετακίνηση σφάλματος!",
|
||||
"NO": "Οχι",
|
||||
"NO_ADDITIONAL_CONTENT_AVAILABLE": "Δεν υπάρχει διαθέσιμο πρόσθετο περιεχόμενο",
|
||||
"NO_DOWNLOADS_AVAILABLE": "Δεν υπάρχουν διαθέσιμες λήψεις",
|
||||
"NO_SCREENSHOTS_AVAILABLE": "Δεν υπάρχουν διαθέσιμα στιγμιότυπα οθόνης",
|
||||
"NO_SIZE": "Χωρίς μέγεθος",
|
||||
"NOT_IMPLEMENTED": "Δεν έχει εφαρμοστεί ακόμα",
|
||||
"RECOMMENDED_ESHOP": "Προτεινόμενο eShop",
|
||||
"REVISION": "Αναθεώρηση",
|
||||
"SCREENSHOT": "Στιγμιότυπο οθόνης %d / %d",
|
||||
"SCREENSHOT_COULD_NOT_LOAD": "Δεν ήταν δυνατή η φόρτωση του στιγμιότυπου οθόνης.",
|
||||
"SCREENSHOT_INSTRUCTIONS": "Πατήστε για αλλαγή και για μεγέθυνση",
|
||||
"SEARCH_FILTERS": "Αναζήτηση και φίλτρα",
|
||||
"SELECT_ESHOP": "Επιλέξτε eShop",
|
||||
"SELECT_ESHOP_2": "Επιλέξτε eShop",
|
||||
"SELECT_DIR": "Επιλέξτε έναν κατάλογο",
|
||||
"SELECT_LANG": "Επιλέξτε τη γλώσσα",
|
||||
"SETTINGS": "Ρυθμίσεις",
|
||||
"SHEET_SLASH": "Φαίνεται ότι περιλαμβάνεται ένα '/', το οποίο δεν υποστηρίζεται. \nΑλλαγή του 'sheet' σε όνομα αρχείου μόνο.",
|
||||
"SHORTCUT_CREATED": "Δημιουργήθηκε συντόμευση!",
|
||||
"SIZE": "Μέγεθος",
|
||||
"SORT_BY": "Ταξινόμηση κατά",
|
||||
"SORTING": "Ταξινόμηση",
|
||||
"START_SELECT": "Πατήστε START για να επιλέξετε τον τρέχοντα φάκελο",
|
||||
"STORE_INFO": "Πληροφορίες καταστήματος",
|
||||
"SYNTAX_ERROR": "Συντακτικό λάθος!",
|
||||
"TITLE": "Τίτλος",
|
||||
"TOP_STYLE": "Κορυφαίο στύλ",
|
||||
"UNSUPPORTED_ESHOP_VERSION": "Η έκδοση αυτού του eShop δεν υποστηρίζεται.",
|
||||
"UPDATE_AVAILABLE": "Διαθέσιμη ενημέρωση!",
|
||||
"UPDATE_DONE": "Η ενημέρωση ολοκληρώθηκε! Ανοίξτε ξανά το DarkStore.",
|
||||
"UPDATE_NOT_AVAILABLE": "Δεν υπάρχουν διαθέσιμες ενημερώσεις!",
|
||||
"UPDATING_ESHOP": "Ενημέρωση eShop ...",
|
||||
"UPDATING_SPRITE_SHEET": "Ενημέρωση φύλλου Sprite ...",
|
||||
"UPDATING_SPRITE_SHEET2": "Ενημέρωση φύλλου Sprite %i του %i...",
|
||||
"VERSION": "Εκδοχή",
|
||||
"WEBSITE": "Πλήρεις πιστώσεις & Changelog μπορούν να βρεθούν στο Ghosteshop.com",
|
||||
"YES": "Ναί"
|
||||
}
|
||||
@@ -1,124 +0,0 @@
|
||||
{
|
||||
"ARGUMENT_INVALID": "Érvénytelen érv.\nKérjük, ellenőrizze az xml fájlban a megfelelő argumentumokat.",
|
||||
"ASCENDING": "Növekvő",
|
||||
"AUTHOR": "Szerző",
|
||||
"AUTO_UPDATE_SETTINGS": "Auto-frissítés beállítások",
|
||||
"AUTO_UPDATE_SETTINGS_BTN": "Auto-frissítés beállítások...",
|
||||
"AUTO_UPDATE_ESHOP": "eShop-ok auto-frissítése",
|
||||
"AUTO_UPDATE_ESHOP_DESC": "Ezzel az utoljára használt eShop automatikusan frissítésre kerül az DarkStore futtatásakor.",
|
||||
"AUTO_UPDATE_DS": "DarkStore auto-frissítése",
|
||||
"AUTO_UPDATE_DS_DESC": "Ha engedélyezett, a DarkStore ellenőzi minden megnyitásakor a frissítéseket.",
|
||||
"AVAILABLE_DOWNLOADS": "Elérhető letöltések",
|
||||
"BOOT_TITLE": "Szeretné bebootolni ezt a címet?",
|
||||
"CATEGORY": "Kategória",
|
||||
"CHANGE_3DSX_PATH": "3DSX útvonal módosítása",
|
||||
"CHANGE_ARCHIVE_PATH": "Archív útvonal módosítása",
|
||||
"CHANGE_NDS_PATH": "NDS útvonal módosítása",
|
||||
"CHANGE_SHORTCUT_PATH": "Parancsikon elérési útjának módosítása",
|
||||
"CHANGELOG": "változási napló",
|
||||
"CHECK_ESHOP_UPDATES": "eShop frissítések ellenőrzése...",
|
||||
"CHECK_DS_UPDATES": "DarkStore frissítések ellenőrzése...",
|
||||
"CITRA_BIGN_ICON": "Citra és Nintendo az ikonhoz",
|
||||
"CONFIRM_OR_CANCEL": "Nyomjon -t a folytatáshoz, -t a megszakításhoz.",
|
||||
"CONNECT_WIFI": "Kérjük kapcsolódjon WiFi-re.",
|
||||
"CONSOLE": "Konzol",
|
||||
"CONTRIBUTOR_TRANSLATORS": "- Minden fordító és hozzájáruló",
|
||||
"COPY_ERROR": "Másolási hiba!",
|
||||
"CREATE_SHORTCUT": "Szeretne létrehozni egy parancsikont?",
|
||||
"CREDITS": "Készítők",
|
||||
"CURRENT_VERSION": "Aktuális verzió: ",
|
||||
"CURRENTLY_EXTRACTING": "Épp kicsomagolás alatt:\n",
|
||||
"CUSTOM_FONT": "Használja az Egyéni betűtípust",
|
||||
"CUSTOM_FONT_DESC": "Ha engedélyezve van, akkor az 'sdmc: /3ds/DarkStore/font.bcfnt' lesz a rendszer betűtípusa helyett, ha megtalálható.",
|
||||
"DELETE_ERROR": "Törlési hiba!",
|
||||
"DELETE_PROMPT": "Biztosan el szeretnéd törölni ezt a könyvtárat?",
|
||||
"DELETE_UNNEEDED_FILE": "Felesleges fájlok törlése...",
|
||||
"DESCENDING": "Csökkenő",
|
||||
"DIRECTION": "Irány",
|
||||
"DIRECTORY_SETTINGS": "Könyvtár beállítások",
|
||||
"DIRECTORY_SETTINGS_BTN": "Könyvtár beállítások...",
|
||||
"DISABLE_AUTOUPDATE_ESHOP": "A bootoláskori eShop auto-frissítés tiltása",
|
||||
"DISABLE_UPDATE_CHECK": "Önfrissítés tiltása",
|
||||
"DONE": "Kész!",
|
||||
"DOWNLOAD_ERROR": "Letöltési hiba!",
|
||||
"DOWNLOAD_FAILED": "Letöltés sikertelen!",
|
||||
"DOWNLOADING_COMPATIBLE_FONT": "Kompatibilis betűtípus letöltése...",
|
||||
"DOWNLOADING_ESHOP": "eShop letöltése...",
|
||||
"DOWNLOADING_ESHOP_DB": "eShop letöltése...",
|
||||
"DOWNLOADING_GHOST_ESHOP": "Az DarkStore letöltése...",
|
||||
"DOWNLOADING_SPRITE_SHEET": "A spritelap letöltése...",
|
||||
"DOWNLOADING_SPRITE_SHEET2": "A spritelap letöltése %i/%i...",
|
||||
"ENABLE_AUTOUPDATE_ESHOP": "A bootoláskori eShop auto-frissítés engedélyezése",
|
||||
"ENABLE_UPDATE_CHECK": "Önfrissítés engedélyezése",
|
||||
"ENTER_DESC_SHORTCUT": "Írja be a parancsikon leírását.",
|
||||
"ENTER_SEARCH": "Írja be azt, amire keresni szeretne.",
|
||||
"ENTER_SHORTCUT_FILENAME": "Írja be a parancsikon fájlnevét (kiterjesztés nélkül).",
|
||||
"ENTER_TITLE_SHORTCUT": "Írja be a parancsikon címét.",
|
||||
"ENTER_URL": "Adja meg az eShop URL-jét.",
|
||||
"ENTRIES": "Bejegyzések",
|
||||
"ESHOP_BG": "eShop HK használata",
|
||||
"ESHOP_BG_DESC": "Ha bekapcsolt, az eShop által biztosított háttérkép jelenik meg az egyszínű helyett, a felső képernyőn.",
|
||||
"ESHOP_INVALID_ERROR": "Ez az eShop érvénytelen és nem\nbetölthető az DarkStore-rel.\nEgy ellenőrzés szintaktikai hibákra?",
|
||||
"ESHOP_TOO_NEW": "Ez az DarkStore\nnagyon régi ehhez az eShop-hoz.\nKérjük frissítsen a legutóbbira.",
|
||||
"ESHOP_TOO_OLD": "Az eShop régi és nem használható DarkStore ezen verziójával.\nKérje meg a készítőját, hogy frissítse.",
|
||||
"EXECUTE_ENTRY": "Szeretné futtatni ezt a bejegyzést?",
|
||||
"EXIT_APP": "Kilépés az DarkStore-ből",
|
||||
"FETCHING_METADATA": "Régi metaadat beolvasása...",
|
||||
"FETCHING_RECOMMENDED_ESHOP": "Fetching recommended eShop...",
|
||||
"FILE_EXTRACTED": "fájl kicsomagolva.",
|
||||
"FILES_HOSTING_ANONYKU": "Anonyku fájlok tárolására",
|
||||
"FILE_SLASH": "Úgy tűnik tartalmaz egy '/' jelet, ami nem támogatott.\nKérjük változtassa meg a 'file' értéket csak fájlnévre.",
|
||||
"FILES_EXTRACTED": "fájl kicsomagolva.",
|
||||
"FILTER_TO": "Szűrő:",
|
||||
"GRID": "Rács",
|
||||
"GUI_SETTINGS": "GUI beállítások",
|
||||
"GUI_SETTINGS_BTN": "GUI beállítások...",
|
||||
"INCLUDE_IN_RESULTS": "Befoglalás az eredményekbe:",
|
||||
"INSTALL_GHOST_ESHOP": "Az DarkStore teleptése...",
|
||||
"INVALID_ESHOP": "Érvénytelen eShop",
|
||||
"KEY_CONTINUE": "Nyomjon meg egy billentyűt a folytatáshoz.",
|
||||
"LANGUAGE": "Nyelv",
|
||||
"LAST_UPDATED": "Utolsó frissítés",
|
||||
"LIST": "Lista",
|
||||
"LOADING_SPRITESHEET": "A spritelap betöltése %i/%i...",
|
||||
"MEDIATYPE_NAND": "Médiatípus NAND",
|
||||
"MEDIATYPE_SD": "Médiatípus SD",
|
||||
"MOVE_ERROR": "Mozgatási hiba!",
|
||||
"NO": "Nem",
|
||||
"NO_ADDITIONAL_CONTENT_AVAILABLE": "Nincs elérhető további tartalom",
|
||||
"NO_DOWNLOADS_AVAILABLE": "Nincsenek elérhető letöltések",
|
||||
"NO_SCREENSHOTS_AVAILABLE": "Nincs elérhető képernyőkép",
|
||||
"NO_SIZE": "Nincs méret",
|
||||
"NOT_IMPLEMENTED": "Még nem implementált",
|
||||
"RECOMMENDED_ESHOP": "Ajánlott eShop",
|
||||
"REVISION": "Revízió",
|
||||
"SCREENSHOT": "Pillanatkép %d / %d",
|
||||
"SCREENSHOT_COULD_NOT_LOAD": "A képernyőkép nem sikerült betölteni.",
|
||||
"SCREENSHOT_INSTRUCTIONS": "Nyomja meg a gombot a változtatáshoz, a gombot a nagyításhoz",
|
||||
"SEARCH_FILTERS": "Keresés és Szűrők",
|
||||
"SELECT_DIR": "Könyvtár kiválasztása",
|
||||
"SELECT_ESHOP": "UniStore választás",
|
||||
"SELECT_ESHOP_2": "Válasszon egy eShop-t",
|
||||
"SELECT_LANG": "Válassza ki a nyelvet",
|
||||
"SETTINGS": "Beállítások",
|
||||
"SHEET_SLASH": "Úgy tűnik tartalmaz egy '/' jelet, ami nem támogatott.\nKérjük változtassa meg a 'sheet' értéket csak fájlnévre.",
|
||||
"SHORTCUT_CREATED": "Parancsikon létrehozva!",
|
||||
"SIZE": "Méret",
|
||||
"SORT_BY": "Rendezés eszerint",
|
||||
"SORTING": "Rendezés",
|
||||
"START_SELECT": "Nyomjon START-t az aktuális mappa kiválasztásához",
|
||||
"STORE_INFO": "Store Info",
|
||||
"SYNTAX_ERROR": "Szintaktikai hiba!",
|
||||
"TITLE": "Cím",
|
||||
"TOP_STYLE": "Top Stílus",
|
||||
"UNSUPPORTED_ESHOP_VERSION": "Ez az eShop verzió nem támogatott.",
|
||||
"UPDATE_AVAILABLE": "Frissítés elérhető!",
|
||||
"UPDATE_DONE": "Frissítés kész! Kérjük, nyissa meg újra az DarkStore-t.",
|
||||
"UPDATE_NOT_AVAILABLE": "Nincs elérhető frissítés!",
|
||||
"UPDATING_ESHOP": "eShop frissítése...",
|
||||
"UPDATING_SPRITE_SHEET": "A spritelap frissítése...",
|
||||
"UPDATING_SPRITE_SHEET2": "A spritelap frissítése %i/%i...",
|
||||
"VERSION": "Verzió",
|
||||
"WEBSITE": "Teljes kreditek és változásnaplók megtalálhatók a Ghosteshop.com oldalon",
|
||||
"YES": "Igen"
|
||||
}
|
||||
@@ -1,124 +0,0 @@
|
||||
{
|
||||
"ARGUMENT_INVALID": "Argomento non valido.\nControlla il file xml per gli argomenti corretti.",
|
||||
"ASCENDING": "Crescente",
|
||||
"AUTHOR": "Autore",
|
||||
"AUTO_UPDATE_SETTINGS": "Impostazioni Auto-Aggiornamento",
|
||||
"AUTO_UPDATE_SETTINGS_BTN": "Impostazioni aggiornamento automatico...",
|
||||
"AUTO_UPDATE_ESHOP": "Auto-Aggiornamento eShop",
|
||||
"AUTO_UPDATE_ESHOP_DESC": "Con questo, l'ultimo eShop utilizzato verrà aggiornato automaticamente all'avvio di DarkStore.",
|
||||
"AUTO_UPDATE_DS": "Auto-aggiornamento DarkStore",
|
||||
"AUTO_UPDATE_DS_DESC": "Se abilitato, DarkStore controllerà se ci sono degli aggiornamenti ogni volta che viene aperto.",
|
||||
"AVAILABLE_DOWNLOADS": "Download Disponibili",
|
||||
"BOOT_TITLE": "Vorresti avviare questo titolo?",
|
||||
"CATEGORY": "Categoria",
|
||||
"CHANGE_3DSX_PATH": "Cambia percorso 3DSX",
|
||||
"CHANGE_ARCHIVE_PATH": "Cambia il percorso dell'archivio",
|
||||
"CHANGE_NDS_PATH": "Cambia percorso NDS",
|
||||
"CHANGE_SHORTCUT_PATH": "Cambia percorso scorciatoia",
|
||||
"CHANGELOG": "Registro delle modifiche",
|
||||
"CHECK_ESHOP_UPDATES": "Controllo aggiornamenti per l'eShop...",
|
||||
"CHECK_DS_UPDATES": "Controllo aggiornamenti DarkStore...",
|
||||
"CITRA_BIGN_ICON": "Citra e Nintendo per Icon",
|
||||
"CONFIRM_OR_CANCEL": "Premi per confermare, per annullare.",
|
||||
"CONNECT_WIFI": "Per favore connettiti al WiFi.",
|
||||
"CONSOLE": "Console",
|
||||
"CONTRIBUTOR_TRANSLATORS": "- Tutti I Traduttori E Collaboratori",
|
||||
"COPY_ERROR": "Errore di Copia!",
|
||||
"CREATE_SHORTCUT": "Vorresti creare un collegamento?",
|
||||
"CREDITS": "Riconoscimenti",
|
||||
"CURRENT_VERSION": "Versione corrente: ",
|
||||
"CURRENTLY_EXTRACTING": "Estrazione attuale:\n",
|
||||
"CUSTOM_FONT": "Usa carattere personalizzato",
|
||||
"CUSTOM_FONT_DESC": "Se abilitato, verrà utilizzato 'sdmc:/3ds/DarkStore/font.bcfnt' al posto del carattere di sistema, se trovato.",
|
||||
"DELETE_ERROR": "Errore di Eliminazione!",
|
||||
"DELETE_PROMPT": "Sei sicuro di voler eliminare questa categoria?",
|
||||
"DELETE_UNNEEDED_FILE": "Eliminazione file non necessari...",
|
||||
"DESCENDING": "Decrescente",
|
||||
"DIRECTION": "Direzione",
|
||||
"DIRECTORY_SETTINGS": "Impostazioni Directory",
|
||||
"DIRECTORY_SETTINGS_BTN": "Impostazioni directory...",
|
||||
"DISABLE_AUTOUPDATE_ESHOP": "Disabilita l'aggiornamento automatico di eShop all'avvio",
|
||||
"DISABLE_UPDATE_CHECK": "Disabilita l'auto-aggiornamento",
|
||||
"DONE": "Fatto!",
|
||||
"DOWNLOAD_ERROR": "Errore Di Download!",
|
||||
"DOWNLOAD_FAILED": "Download non riuscito!",
|
||||
"DOWNLOADING_COMPATIBLE_FONT": "Download di font compatibili...",
|
||||
"DOWNLOADING_SPRITE_SHEET": "Scaricamento dello Spritesheet...",
|
||||
"DOWNLOADING_SPRITE_SHEET2": "Scaricamento dello Spritesheet %i di %i...",
|
||||
"DOWNLOADING_ESHOP_DB": "Scaricamento dell'eShop...",
|
||||
"DOWNLOADING_GHOST_ESHOP": "Scaricamento dell'DarkStore...",
|
||||
"DOWNLOADING_ESHOP": "Scaricamento dell'eShop...",
|
||||
"ENABLE_AUTOUPDATE_ESHOP": "Abilita l'aggiornamento automatico dell'eShop all'avvio",
|
||||
"ENABLE_UPDATE_CHECK": "Abilita l'auto-aggiornamento",
|
||||
"ENTER_DESC_SHORTCUT": "Immettere la descrizione del collegamento.",
|
||||
"ENTER_SEARCH": "Inserisci quello che vorresti cercare.",
|
||||
"ENTER_SHORTCUT_FILENAME": "Immettere il nome del file di collegamento (senza estensione)",
|
||||
"ENTER_TITLE_SHORTCUT": "Immettere il titolo della scorciatoia.",
|
||||
"ENTER_URL": "Inserisci l'URL dell'eShop.",
|
||||
"ENTRIES": "Voci",
|
||||
"ESHOP_BG": "Usa Sfondo eShop",
|
||||
"ESHOP_BG_DESC": "Se abilitato, lo sfondo fornito da UniStore verrà mostrato al posto del colore solido dello sfondo per lo schermo superiore.",
|
||||
"ESHOP_INVALID_ERROR": "Questo eShop non è valido e non può essere caricato\ncon DarkStore.\nMagari controllare se ci sono errori di sintassi?",
|
||||
"ESHOP_TOO_NEW": "La tua versione di DarkStore è\ntroppo vecchia per usare questo eShop.\nSi prega di aggiornare all'ultima versione.",
|
||||
"ESHOP_TOO_OLD": "Questo eShop è obsoleto e non può essere utilizzato\ncon questa versione di DarkStore.\nChiedi al creatore di aggiornarlo.",
|
||||
"EXECUTE_ENTRY": "Vuoi eseguire questa voce?",
|
||||
"EXIT_APP": "Esci da DarkStore",
|
||||
"FETCHING_METADATA": "Recupero di metadata antica in corso...",
|
||||
"FETCHING_RECOMMENDED_ESHOP": "Recupero dell'eShop consigliato ...",
|
||||
"FILE_EXTRACTED": "File estratto.",
|
||||
"FILES_HOSTING_ANONYKU": "Anonyku per l'hosting di file",
|
||||
"FILE_SLASH": "Sembrerebbe che sia incluso un '/', che non è supportato.\nSi prega di cambiare 'file' nel nome del file.",
|
||||
"FILES_EXTRACTED": "File estratti.",
|
||||
"FILTER_TO": "Filtro:",
|
||||
"GRID": "Griglia",
|
||||
"GUI_SETTINGS": "Impostazioni GUI",
|
||||
"GUI_SETTINGS_BTN": "Impostazioni GUI...",
|
||||
"INCLUDE_IN_RESULTS": "Includi nei risultati:",
|
||||
"INSTALL_GHOST_ESHOP": "Installazione dell'DarkStore...",
|
||||
"INVALID_UNISTORE": "eShop non valido",
|
||||
"KEY_CONTINUE": "Premere un qualsiasi tasto per continuare.",
|
||||
"LANGUAGE": "Lingua",
|
||||
"LAST_UPDATED": "Ultimo aggiornamento",
|
||||
"LIST": "Lista",
|
||||
"LOADING_SPRITESHEET": "Caricamento dello Spritesheet %i di %i...",
|
||||
"MEDIATYPE_NAND": "MediaType NAND",
|
||||
"MEDIATYPE_SD": "MediaType SD",
|
||||
"MOVE_ERROR": "Errore di Spostamento!",
|
||||
"NO": "No",
|
||||
"NO_ADDITIONAL_CONTENT_AVAILABLE": "Nessun contenuto aggiuntivo disponibile",
|
||||
"NO_DOWNLOADS_AVAILABLE": "Nessun download disponibile",
|
||||
"NO_SCREENSHOTS_AVAILABLE": "Nessuno screenshot disponibile",
|
||||
"NO_SIZE": "Nessuna Dimensione",
|
||||
"NOT_IMPLEMENTED": "Non ancora implementato",
|
||||
"RECOMMENDED_ESHOP": "eShop consigliato",
|
||||
"REVISION": "Revisione",
|
||||
"SCREENSHOT": "Immagine dello schermo %d / %d",
|
||||
"SCREENSHOT_COULD_NOT_LOAD": "Impossibile caricare l'immagine dello schermo.",
|
||||
"SCREENSHOT_INSTRUCTIONS": "Premere per modificare e per ingrandire",
|
||||
"SEARCH_FILTERS": "Ricerca e filtri",
|
||||
"SELECT_DIR": "Seleziona una directory",
|
||||
"SELECT_LANG": "Seleziona la lingua",
|
||||
"SELECT_ESHOP": "Seleziona eShop",
|
||||
"SELECT_ESHOP_2": "Seleziona un eShop",
|
||||
"SETTINGS": "Impostazioni",
|
||||
"SHEET_SLASH": "Sembrerebbe che sia incluso un '/', che non è supportato.\nSi prega di cambiare 'sheet' nel nome del file.",
|
||||
"SHORTCUT_CREATED": "Collegamento creato!",
|
||||
"SIZE": "Taglia",
|
||||
"SORT_BY": "Ordina Per",
|
||||
"SORTING": "Ordinamento",
|
||||
"START_SELECT": "Premere START per selezionare la cartella corrente",
|
||||
"STORE_INFO": "Informazioni negozio",
|
||||
"SYNTAX_ERROR": "Errore Di Sintassi!",
|
||||
"TITLE": "Titolo",
|
||||
"TOP_STYLE": "Stile Superiore",
|
||||
"UNSUPPORTED_ESHOP_VERSION": "La versione di questo eShop non è supportata.",
|
||||
"UPDATE_AVAILABLE": "Aggiornamento Disponibile!",
|
||||
"UPDATE_DONE": "Aggiornamento completato! Riapri DarkStore.",
|
||||
"UPDATE_NOT_AVAILABLE": "Nessun Aggiornamento Disponibile!",
|
||||
"UPDATING_SPRITE_SHEET": "Aggiornamento dello Spritesheet...",
|
||||
"UPDATING_SPRITE_SHEET2": "Aggiornamento dello Spritesheet %i di %i...",
|
||||
"UPDATING_ESHOP": "Aggiornamento dell'eShop...",
|
||||
"VERSION": "Versione",
|
||||
"WEBSITE": "Riconoscimenti completi e log delle modifiche possono essere trovati su Ghosteshop.com",
|
||||
"YES": "Si"
|
||||
}
|
||||
@@ -1,124 +0,0 @@
|
||||
{
|
||||
"ARGUMENT_INVALID": "Argument invalid.\nPlease check the xml file for proper arguments.",
|
||||
"ASCENDING": "昇順",
|
||||
"AUTHOR": "作者",
|
||||
"AUTO_UPDATE_SETTINGS": "自動更新設定",
|
||||
"AUTO_UPDATE_SETTINGS_BTN": "自動更新設定……",
|
||||
"AUTO_UPDATE_ESHOP": "eShopの自動更新",
|
||||
"AUTO_UPDATE_ESHOP_DESC": "これにより、DarkStoreの起動時で最後に使用されたeShopを自動的に更新されます。",
|
||||
"AUTO_UPDATE_DS": "DarkStoreの自動更新",
|
||||
"AUTO_UPDATE_DS_DESC": "有効にすると、 DarkStoreは開くたびに更新を確認します。",
|
||||
"AVAILABLE_DOWNLOADS": "利用可能なダウンロード",
|
||||
"BOOT_TITLE": "このアプリを開始しますか?",
|
||||
"CATEGORY": "カテゴリ",
|
||||
"CHANGE_3DSX_PATH": "3DSXのパスを変更します",
|
||||
"CHANGE_ARCHIVE_PATH": "アーカイブのパスを変更します",
|
||||
"CHANGE_NDS_PATH": "NDSのパスを変更します",
|
||||
"CHANGE_SHORTCUT_PATH": "ショートカットパスを変更する",
|
||||
"CHECK_ESHOP_UPDATES": "eShop更新を確認しています……",
|
||||
"CHECK_DS_UPDATES": "DarkStore更新を確認しています……",
|
||||
"CHANGELOG": "変更ログ",
|
||||
"CONFIRM_OR_CANCEL": "を押して確認し、を押してキャンセルします。",
|
||||
"CONNECT_WIFI": "WiFiに接続してください。",
|
||||
"CITRA_BIGN_ICON": "アイコンのCitra&Nintendo",
|
||||
"CONSOLE": "本体",
|
||||
"CONTRIBUTOR_TRANSLATORS": "- すべての翻訳者と貢献者",
|
||||
"COPY_ERROR": "コピーエラー!",
|
||||
"CREATE_SHORTCUT": "ショートカットを作成しますか?",
|
||||
"CREDITS": "クレジット",
|
||||
"CURRENT_VERSION": "現在のバージョン: ",
|
||||
"CURRENTLY_EXTRACTING": "現在展開中:\n",
|
||||
"CUSTOM_FONT": "カスタムフォントを使用する",
|
||||
"CUSTOM_FONT_DESC": "有効にすると、システムフォントの代わりに「sdmc:/ 3ds / GhostShop /font.bcfnt」が使用されます(見つかった場合)。",
|
||||
"DELETE_ERROR": "削除エラー!",
|
||||
"DELETE_PROMPT": "このディレクトリを削除してもよろしいですか?",
|
||||
"DELETE_UNNEEDED_FILE": "不要なファイルを削除しています……",
|
||||
"DESCENDING": "降順",
|
||||
"DIRECTION": "方向",
|
||||
"DIRECTORY_SETTINGS": "ディレクトリ設定",
|
||||
"DIRECTORY_SETTINGS_BTN": "ディレクトリ設定……",
|
||||
"DISABLE_AUTOUPDATE_ESHOP": "起動時にeShopの自動更新を無効にします",
|
||||
"DISABLE_UPDATE_CHECK": "自己更新を無効にします",
|
||||
"DONE": "完了!",
|
||||
"DOWNLOAD_ERROR": "ダウンロードエラー!",
|
||||
"DOWNLOAD_FAILED": "ダウンロードに失敗しました!",
|
||||
"DOWNLOADING_COMPATIBLE_FONT": "互換性のあるフォントをダウンロードしています……",
|
||||
"DOWNLOADING_SPRITE_SHEET": "スプライトシートをダウンロードしています……",
|
||||
"DOWNLOADING_SPRITE_SHEET2": "スプライトシート%i/%iをダウンロードしています……",
|
||||
"DOWNLOADING_ESHOP_DB": "eShopをダウンロードしています……",
|
||||
"DOWNLOADING_GHOST_ESHOP": "DarkStoreをダウンロードしています……",
|
||||
"DOWNLOADING_ESHOP": "eShopをダウンロードしています……",
|
||||
"ENABLE_AUTOUPDATE_ESHOP": "起動時にeShopの自動更新を有効にします",
|
||||
"ENABLE_UPDATE_CHECK": "自己更新を有効にします",
|
||||
"ENTER_DESC_SHORTCUT": "ショートカットの説明を入力します。",
|
||||
"ENTER_SEARCH": "検索したいものを入力します。",
|
||||
"ENTER_SHORTCUT_FILENAME": "ショートカットファイル名を入力します(拡張子なし)。",
|
||||
"ENTER_TITLE_SHORTCUT": "ショートカットのタイトルを入力します。",
|
||||
"ENTER_URL": "eShopのURLを入力します。",
|
||||
"ENTRIES": "項目",
|
||||
"ESHOP_BG": "eShopの背景画像を使用",
|
||||
"ESHOP_BG_DESC": "有効にすると、上画面の無地色の代わりにeShopが提供する背景画像が表示されまる。",
|
||||
"ESHOP_INVALID_ERROR": "このeShopは無効であり、\nDarkStoreで読み込めません。\n多分、構文エラーがないか確認しますか?",
|
||||
"ESHOP_TOO_NEW": "DarkStoreのバージョンはこの\neShopを使用するには古すぎます。\n最新のバージョンに更新してください。",
|
||||
"ESHOP_TOO_OLD": "このeShopは古く、このバージョンの\nDarkStoreでは使用できません。\n作成者に更新しますを依頼してください。",
|
||||
"EXECUTE_ENTRY": "この項目を実行しますか?",
|
||||
"EXIT_APP": "DarkStoreを終了します",
|
||||
"FETCHING_METADATA": "古いメタデータを取得しています……",
|
||||
"FETCHING_RECOMMENDED_ESHOP": "推奨されるeショップを取得しています……",
|
||||
"FILE_EXTRACTED": "展開されたファイル",
|
||||
"FILE_SLASH": "「/」が含まれていますようですが、サポートされていません。\n「file」をファイル名のみに変更してください。",
|
||||
"FILES_EXTRACTED": "展開されたファイル",
|
||||
"FILES_HOSTING_ANONYKU": "ファイルをホストするための匿名",
|
||||
"FILTER_TO": "フィルター:",
|
||||
"GRID": "グリッド",
|
||||
"GUI_SETTINGS": "GUI設定",
|
||||
"GUI_SETTINGS_BTN": "GUI設定……",
|
||||
"INCLUDE_IN_RESULTS": "結果に含みます:",
|
||||
"INSTALL_GHOST_ESHOP": "DarkStoreをインストールしています……",
|
||||
"INVALID_ESHOP": "無効なeShop",
|
||||
"KEY_CONTINUE": "続行しますには何かキーを押します。",
|
||||
"LANGUAGE": "言語",
|
||||
"LAST_UPDATED": "最後更新日",
|
||||
"LIST": "リスト",
|
||||
"LOADING_SPRITESHEET": "スプライトシート%i/%iを読み込んでいます……",
|
||||
"MEDIATYPE_NAND": "メディアタイプNAND",
|
||||
"MEDIATYPE_SD": "メディアタイプSD",
|
||||
"MOVE_ERROR": "移動エラー",
|
||||
"NO": "いいえ",
|
||||
"NO_ADDITIONAL_CONTENT_AVAILABLE": "利用可能な追加コンテンツはありません",
|
||||
"NO_DOWNLOADS_AVAILABLE": "ダウンロードがありません",
|
||||
"NO_SCREENSHOTS_AVAILABLE": "利用可能なスクリーンショットはありません",
|
||||
"NO_SIZE": "サイズなし",
|
||||
"NOT_IMPLEMENTED": "まだ実装されていません",
|
||||
"RECOMMENDED_ESHOP": "推奨されるeショップ",
|
||||
"REVISION": "改定",
|
||||
"SCREENSHOT": "スクリーンショット %d / %d",
|
||||
"SCREENSHOT_COULD_NOT_LOAD": "スクリーンショットを読み込めませんでした。",
|
||||
"SCREENSHOT_INSTRUCTIONS": "を押して変更し、を押してズームします",
|
||||
"SEARCH_FILTERS": "検索とフィルター",
|
||||
"SELECT_DIR": "ディレクトリを選択します",
|
||||
"SELECT_LANG": "言語を選択します",
|
||||
"SELECT_ESHOP": "eShopを選択します",
|
||||
"SELECT_ESHOP_2": "eShopを選択します",
|
||||
"SETTINGS": "設定",
|
||||
"SHEET_SLASH": "「/」が含まれていますようですが、サポートされていません。\n「sheet」をファイル名のみに変更してください。",
|
||||
"SHORTCUT_CREATED": "ショートカットを作成しました!",
|
||||
"SIZE": "サイズ",
|
||||
"SORT_BY": "並べ替え順",
|
||||
"SORTING": "並べ替え",
|
||||
"START_SELECT": "STARTを押して、現在のフォルダを選択します",
|
||||
"STORE_INFO": "ストア情報",
|
||||
"SYNTAX_ERROR": "構文エラー!",
|
||||
"TITLE": "タイトル",
|
||||
"TOP_STYLE": "上スタイル",
|
||||
"UNSUPPORTED_ESHOP_VERSION": "このeShopのバージョンはサポートされていません。",
|
||||
"UPDATE_AVAILABLE": "更新があります!",
|
||||
"UPDATE_DONE": "更新が完了しました!DarkStoreを再度開いてください。",
|
||||
"UPDATE_NOT_AVAILABLE": "更新はありません!",
|
||||
"UPDATING_SPRITE_SHEET": "スプライトシートを更新しています……",
|
||||
"UPDATING_SPRITE_SHEET2": "スプライトシート%i/%iを更新しています……",
|
||||
"UPDATING_ESHOP": "eShopを更新しています……",
|
||||
"VERSION": "バージョン",
|
||||
"WEBSITE": "完全なクレジットと変更ログはGhosteshop.comで見つけることができます",
|
||||
"YES": "はい"
|
||||
}
|
||||
@@ -1,124 +0,0 @@
|
||||
{
|
||||
"ARGUMENT_INVALID": "인수가 잘못되었습니다. \nxml 파일에서 올바른 인수를 확인하십시오.",
|
||||
"ASCENDING": "오름차순",
|
||||
"AUTHOR": "저자",
|
||||
"AUTO_UPDATE_ESHOP": "eShop 자동 업데이트",
|
||||
"AUTO_UPDATE_ESHOP_DESC": "이렇게하면 DarkStore을 시작할 때 마지막으로 사용한 eShop이 자동으로 업데이트됩니다.",
|
||||
"AUTO_UPDATE_DS": "DarkStore 자동 업데이트",
|
||||
"AUTO_UPDATE_DS_DESC": "활성화되면 DarkStore이 열릴 때마다 업데이트를 확인합니다.",
|
||||
"AUTO_UPDATE_SETTINGS": "자동 업데이트 설정",
|
||||
"AUTO_UPDATE_SETTINGS_BTN": "자동 업데이트 설정...",
|
||||
"AVAILABLE_DOWNLOADS": "사용 가능한 다운로드",
|
||||
"BOOT_TITLE": "이 타이틀을 부팅 하시겠습니까?",
|
||||
"CATEGORY": "범주",
|
||||
"CHANGE_3DSX_PATH": "3DSX 경로 변경",
|
||||
"CHANGE_ARCHIVE_PATH": "아카이브 경로 변경",
|
||||
"CHANGE_NDS_PATH": "NDS 경로 변경",
|
||||
"CHANGE_SHORTCUT_PATH": "바로 가기 경로 변경",
|
||||
"CHANGELOG": "변경 로그",
|
||||
"CHECK_ESHOP_UPDATES": "eShop 업데이트 확인...",
|
||||
"CHECK_DS_UPDATES": "DarkStore 업데이트 확인 중...",
|
||||
"CITRA_BIGN_ICON": "아이콘을위한 Citra & Nintendo",
|
||||
"CONFIRM_OR_CANCEL": "확인하려면 \uE000 을 누르고 취소하려면 \uE001 을 누르세요.",
|
||||
"CONNECT_WIFI": "WiFi에 연결하십시오.",
|
||||
"CONSOLE": "콘솔",
|
||||
"CONTRIBUTOR_TRANSLATORS": "- 모든 번역가 및 기여자",
|
||||
"COPY_ERROR": "복사 오류!",
|
||||
"CREATE_SHORTCUT": "바로 가기를 만드시겠습니까?",
|
||||
"CREDITS": "크레딧",
|
||||
"CURRENT_VERSION": "현재 버전: ",
|
||||
"CURRENTLY_EXTRACTING": "현재 추출 중:\n",
|
||||
"CUSTOM_FONT": "사용자 정의 글꼴 사용",
|
||||
"CUSTOM_FONT_DESC": "활성화하면 시스템 글꼴 대신 'sdmc : /3ds/DarkStore/font.bcfnt' 가 사용됩니다 (있는 경우).",
|
||||
"DELETE_ERROR": "삭제 오류!",
|
||||
"DELETE_PROMPT": "이 디렉토리를 삭제 하시겠습니까?",
|
||||
"DELETE_UNNEEDED_FILE": "불필요한 파일 삭제 중...",
|
||||
"DESCENDING": "내림차순",
|
||||
"DIRECTION": "방향",
|
||||
"DIRECTORY_SETTINGS": "디렉토리 설정",
|
||||
"DIRECTORY_SETTINGS_BTN": "디렉토리 설정...",
|
||||
"DISABLE_AUTOUPDATE_ESHOP": "부팅시 자동 업데이트 eShop 비활성화",
|
||||
"DISABLE_UPDATE_CHECK": "자동 업데이트 비활성화",
|
||||
"DONE": "끝난!",
|
||||
"DOWNLOAD_ERROR": "다운로드 오류!",
|
||||
"DOWNLOAD_FAILED": "다운로드 실패!",
|
||||
"DOWNLOADING_ESHOP": "eShop 다운로드 중...",
|
||||
"DOWNLOADING_ESHOP_DB": "eShop 다운로드 중...",
|
||||
"DOWNLOADING_GHOST_ESHOP": "DarkStore 다운로드...",
|
||||
"DOWNLOADING_COMPATIBLE_FONT": "호환 가능한 글꼴 다운로드...",
|
||||
"DOWNLOADING_SPRITE_SHEET": "스프라이트 시트 다운로드...",
|
||||
"DOWNLOADING_SPRITE_SHEET2": "스프라이트 시트 다운로드 %i 의 %i...",
|
||||
"ESHOP_BG": "eShop BG 사용",
|
||||
"ESHOP_BG_DESC": "활성화되면 상단 화면에 단색 BG 색상 대신 eShop에서 제공하는 BG가 표시됩니다.",
|
||||
"ESHOP_INVALID_ERROR": "이 eShop은 유효하지 않으며\nDarkStore으로로드되었습니다.\n구문 오류가 있는지 확인할 수 있습니까?",
|
||||
"ESHOP_TOO_NEW": "귀하의 DarkStore 버전은\n이 eShop을 사용하기에는 너무 오래되었습니다.\n최신 버전으로 업데이트하십시오.",
|
||||
"ESHOP_TOO_OLD": "이 eShop은 오래되어 사용할 수 없습니다.\n이 버전의 DarkStore으로.\n제작자에게 업데이트를 요청하십시오.",
|
||||
"ENABLE_AUTOUPDATE_ESHOP": "부팅시 자동 업데이트 eShop 활성화",
|
||||
"ENABLE_UPDATE_CHECK": "자동 업데이트 활성화",
|
||||
"ENTER_DESC_SHORTCUT": "바로 가기 설명을 입력하십시오.",
|
||||
"ENTER_SEARCH": "검색 할 내용을 입력하십시오.",
|
||||
"ENTER_SHORTCUT_FILENAME": "바로 가기 파일 이름 (확장자 없음)을 입력합니다.",
|
||||
"ENTER_TITLE_SHORTCUT": "바로 가기 제목을 입력하십시오.",
|
||||
"ENTER_URL": "eShop의 URL을 입력하십시오.",
|
||||
"ENTRIES": "출품작",
|
||||
"EXECUTE_ENTRY": "이 항목을 실행 하시겠습니까?",
|
||||
"EXIT_APP": "DarkStore 종료",
|
||||
"FETCHING_METADATA": "이전 메타 데이터 가져 오기...",
|
||||
"FETCHING_RECOMMENDED_ESHOP": "추천 eShop을 가져 오는 중...",
|
||||
"FILE_EXTRACTED": "파일이 추출되었습니다.",
|
||||
"FILES_HOSTING_ANONYKU": "파일 호스팅을위한 Anonyku",
|
||||
"FILE_SLASH": "지원되지 않는 '/'가 포함 된 것 같습니다. \n'file'을 파일 이름으로 만 변경하십시오.",
|
||||
"FILES_EXTRACTED": "추출 된 파일.",
|
||||
"FILTER_TO": "필터링 대상:",
|
||||
"GRID": "그리드",
|
||||
"GUI_SETTINGS": "GUI 설정",
|
||||
"GUI_SETTINGS_BTN": "GUI 설정...",
|
||||
"INCLUDE_IN_RESULTS": "결과에 포함:",
|
||||
"INSTALL_GHOST_ESHOP": "DarkStore 설치...",
|
||||
"INVALID_ESHOP": "잘못된 eShop",
|
||||
"KEY_CONTINUE": "계속하려면 아무 키나 누르십시오.",
|
||||
"LANGUAGE": "언어",
|
||||
"LAST_UPDATED": "마지막 업데이트",
|
||||
"LIST": "명부",
|
||||
"LOADING_SPRITESHEET": "스프라이트 시트로드 %i 의 %i...",
|
||||
"MEDIATYPE_NAND": "MediaType NAND",
|
||||
"MEDIATYPE_SD": "MediaType SD",
|
||||
"MOVE_ERROR": "이동 오류!",
|
||||
"NO": "아니",
|
||||
"NO_ADDITIONAL_CONTENT_AVAILABLE": "사용 가능한 추가 콘텐츠 없음",
|
||||
"NO_DOWNLOADS_AVAILABLE": "사용 가능한 다운로드 없음",
|
||||
"NO_SCREENSHOTS_AVAILABLE": "사용 가능한 스크린 샷 없음",
|
||||
"NO_SIZE": "크기 없음",
|
||||
"NOT_IMPLEMENTED": "아직 구현되지 않음",
|
||||
"RECOMMENDED_ESHOP": "추천 eShop",
|
||||
"REVISION": "개정",
|
||||
"SCREENSHOT": "스크린 샷 %d / %d",
|
||||
"SCREENSHOT_COULD_NOT_LOAD": "스크린 샷을로드 할 수 없습니다.",
|
||||
"SCREENSHOT_INSTRUCTIONS": "를 눌러 변경하고 를 눌러 확대",
|
||||
"SEARCH_FILTERS": "검색 및 필터",
|
||||
"SELECT_ESHOP": "eShop 선택",
|
||||
"SELECT_ESHOP_2": "eShop 선택",
|
||||
"SELECT_DIR": "디렉토리 선택",
|
||||
"SELECT_LANG": "언어 선택",
|
||||
"SETTINGS": "설정",
|
||||
"SHEET_SLASH": "지원되지 않는 '/'가 포함 된 것 같습니다. \n '시트'를 파일 이름으로 만 변경하십시오.",
|
||||
"SHORTCUT_CREATED": "바로 가기가 생성되었습니다!",
|
||||
"SIZE": "크기",
|
||||
"SORT_BY": "정렬 기준",
|
||||
"SORTING": "정렬",
|
||||
"START_SELECT": "현재 폴더를 선택하려면 시작을 누르십시오.",
|
||||
"STORE_INFO": "매장 정보",
|
||||
"SYNTAX_ERROR": "구문 오류!",
|
||||
"TITLE": "표제",
|
||||
"TOP_STYLE": "탑 스타일",
|
||||
"UNSUPPORTED_ESHOP_VERSION": "이 eShop의 버전은 지원되지 않습니다.",
|
||||
"UPDATE_AVAILABLE": "업데이트 가능!",
|
||||
"UPDATE_DONE": "업데이트 완료! DarkStore을 다시여십시오.",
|
||||
"UPDATE_NOT_AVAILABLE": "사용 가능한 업데이트가 없습니다!",
|
||||
"UPDATING_ESHOP": "eShop 업데이트...",
|
||||
"UPDATING_SPRITE_SHEET": "스프라이트 시트 업데이트...",
|
||||
"UPDATING_SPRITE_SHEET2": "스프라이트 시트 업데이트 %i 의 %i...",
|
||||
"VERSION": "버전",
|
||||
"WEBSITE": "전체 크레딧 및 변경 내역은 Ghosteshop.com에서 찾을 수 있습니다.",
|
||||
"YES": "예"
|
||||
}
|
||||
@@ -1,124 +0,0 @@
|
||||
{
|
||||
"ARGUMENT_INVALID": "Argumentas neteisingas.\nPrašome patikrinti xml failą, kad būtų galima pateikti tinkamus argumentus.",
|
||||
"ASCENDING": "Didėjimo tvarka",
|
||||
"AUTHOR": "Autorius",
|
||||
"AUTO_UPDATE_ESHOP": "Auto-atnaujinimo eShop",
|
||||
"AUTO_UPDATE_ESHOP_DESC": "Su tuo, paskutinis naudojamas eShop bus atnaujintas automatiškai, kai pradeda Gost Eshop.",
|
||||
"AUTO_UPDATE_DS": "Auto-atnaujinimo Gost eShop",
|
||||
"AUTO_UPDATE_DS_DESC": "Kai įjungta, Gost eShop bus patikrinti, ar atnaujinimai kiekvieną kartą, kai jis atidarė.",
|
||||
"AUTO_UPDATE_SETTINGS": "Automatiškai atnaujinti nustatymus",
|
||||
"AUTO_UPDATE_SETTINGS_BTN": "Automatiškai atnaujinti nustatymus ...",
|
||||
"AVAILABLE_DOWNLOADS": "Prieinami atsiuntimai",
|
||||
"BOOT_TITLE": "Ar norite įkelti šį titulą?",
|
||||
"CATEGORY": "Kategorija",
|
||||
"CHANGE_3DSX_PATH": "Keisti 3DSX kelią",
|
||||
"CHANGE_ARCHIVE_PATH": "Pakeisti archyvo kelią",
|
||||
"CHANGE_NDS_PATH": "Pakeisti NDS kelią",
|
||||
"CHANGE_SHORTCUT_PATH": "Pakeisti trumpojo kelio kryptį",
|
||||
"CHANGELOG": "Changelog",
|
||||
"CHECK_ESHOP_UPDATES": "Patikrinti eShop atnaujinimus ...",
|
||||
"CHECK_DS_UPDATES": "Patikrinti, ar Gost eShop atnaujinimai ...",
|
||||
"CITRA_BIGN_ICON": "Citra & Nintendo for the Icon",
|
||||
"CONFIRM_OR_CANCEL": "Paspauskite mygtuką, kad patvirtintų, kad atšaukti.",
|
||||
"CONNECT_WIFI": "Prašome prisijungti prie WiFi.",
|
||||
"CONSOLE": "Pultas",
|
||||
"CONTRIBUTOR_TRANSLATORS": "-Visi vertėjai ir prie jų prisidedantys",
|
||||
"COPY_ERROR": "Kopijavimo klaida!",
|
||||
"CREATE_SHORTCUT": "Ar norite sukurti spartą?",
|
||||
"CREDITS": "Kreditai",
|
||||
"CURRENT_VERSION": "Dabartinė versija: ",
|
||||
"CURRENTLY_EXTRACTING": "Šiuo metu išgaunama:\n",
|
||||
"CUSTOM_FONT": "Naudoti individualų šriftą",
|
||||
"CUSTOM_FONT_DESC": "Jei įjungta, \"sdmc: /3ds/DarkStore/font.bcfnt\" bus naudojamas vietoj sistemos šrifto, jei jis bus rastas.",
|
||||
"DELETE_ERROR": "Pašalinti klaidą!",
|
||||
"DELETE_PROMPT": "Ar tikrai norite ištrinti šį aplanką?",
|
||||
"DELETE_UNNEEDED_FILE": "Pašalinti nereikalingą failą ...",
|
||||
"DESCENDING": "Mažėjanti",
|
||||
"DIRECTION": "Kryptis",
|
||||
"DIRECTORY_SETTINGS": "Aplanko nustatymai",
|
||||
"DIRECTORY_SETTINGS_BTN": "Katalogo nustatymai ...",
|
||||
"DISABLE_AUTOUPDATE_ESHOP": "Išjungti auto-atnaujinimo eShop apie boot",
|
||||
"DISABLE_UPDATE_CHECK": "Išjungti savęs atnaujinimui",
|
||||
"DONE": "Baigta!",
|
||||
"DOWNLOAD_ERROR": "Parsisiųsti Klaida!",
|
||||
"DOWNLOAD_FAILED": "Atsisiųsti nepavyko!",
|
||||
"DOWNLOADING_ESHOP": "Atsisiuntimas eShop ...",
|
||||
"DOWNLOADING_ESHOP_DB": "Atsisiuntimas eShop ...",
|
||||
"DOWNLOADING_GHOST_ESHOP": "Parsisiųsdintivaiduoklis ...",
|
||||
"DOWNLOADING_COMPATIBLE_FONT": "Atsisiuntimas suderinamas šriftas ...",
|
||||
"DOWNLOADING_SPRITE_SHEET": "Parsisiųsdinama Spriteheet ...",
|
||||
"DOWNLOADING_SPRITE_SHEET2": "Parsisiųsdinama Spriteheet %i of %i...",
|
||||
"ESHOP_BG": "Naudoti eShop BG",
|
||||
"ESHOP_BG_DESC": "Kai įjungta, eShop suteiktas BG bus rodomas vietoj kieto BG spalvos viršutiniame ekrane.",
|
||||
"ESHOP_INVALID_ERROR": "Šis \"eShop\" yra neteisingas ir negali būti\npakrautas su \"Gost Eshop\".\nGalbūt patikrinti, ar yra kokių nors sintaksės klaidų?",
|
||||
"ESHOP_TOO_NEW": "Jūsų versija DarkStore yra\nper senas naudoti šį e-parduotuvė.\nPrašome atnaujinti į naujausią versiją.",
|
||||
"ESHOP_TOO_OLD": "Šis eShop yra pasenęs ir negali būti naudojamas\nsu šia \"Gost eShop\" versija.\nPrašome paprašyti kūrėjo jį atnaujinti.",
|
||||
"ENABLE_AUTOUPDATE_ESHOP": "Įjungti auto-atnaujinimo eShop įkrovos",
|
||||
"ENABLE_UPDATE_CHECK": "Įgalinti save atnaujinti",
|
||||
"ENTER_DESC_SHORTCUT": "Įveskite trumpojo aprašymo aprašymą.",
|
||||
"ENTER_SEARCH": "Įveskite tai, ką norite ieškoti.",
|
||||
"ENTER_SHORTCUT_FILENAME": "Įveskite į galutinį failo pavadinimą (be pratęsimo).",
|
||||
"ENTER_TITLE_SHORTCUT": "Įveskite trumpos antraštės pavadinimą.",
|
||||
"ENTER_URL": "Įveskite eShop URL adresą.",
|
||||
"ENTRIES": "Įrašai",
|
||||
"EXECUTE_ENTRY": "Ar jums patinka vykdyti šį įrašą?",
|
||||
"EXIT_APP": "Išeiti vaiduoklis Shesop",
|
||||
"FETCHING_METADATA": "Apgauti senus metaduomenis ...",
|
||||
"FETCHING_RECOMMENDED_ESHOP": "Fetching recommended eShop...",
|
||||
"FILE_EXTRACTED": "išgaunamas failas.",
|
||||
"FILES_HOSTING_ANONYKU": "Anononu Hosting Failams",
|
||||
"FILE_SLASH": "Atrodo, kad \" /\" yra įtrauktas, kuris nėra palaikomas.\nPrašome pakeisti \"failą\" tik į failo pavadinimą.",
|
||||
"FILES_EXTRACTED": "išgaunami failai.",
|
||||
"FILTER_TO": "Filtruoti iki:",
|
||||
"GRID": "Tinklelis",
|
||||
"GUI_SETTINGS": "GUI nustatymai",
|
||||
"GUI_SETTINGS_BTN": "GUI nustatymai ...",
|
||||
"INCLUDE_IN_RESULTS": "Įtraukti į rezultatus:",
|
||||
"INSTALL_GHOST_ESHOP": "Įdiekite vėlių parduotuvę ...",
|
||||
"INVALID_ESHOP": "Netinkamas eShop",
|
||||
"KEY_CONTINUE": "Paspauskite bet kurį klavišą, norėdami tęsti.",
|
||||
"LANGUAGE": "Kalba",
|
||||
"LAST_UPDATED": "Paskutinį kartą atnaujinta",
|
||||
"LIST": "1 straipsnis",
|
||||
"LOADING_SPRITESHEET": "Pakrovimo Spricesheet %i of %i...",
|
||||
"MEDIATYPE_NAND": "MediaType NIR",
|
||||
"MEDIATYPE_SD": "MediaType SD",
|
||||
"MOVE_ERROR": "Perkelti Klaida!",
|
||||
"NO": "Nr.",
|
||||
"NO_ADDITIONAL_CONTENT_AVAILABLE": "Papildomo Turinio Nėra",
|
||||
"NO_DOWNLOADS_AVAILABLE": "Nėra parsisiųsti",
|
||||
"NO_SIZE": "Nėra dydžio",
|
||||
"NO_SCREENSHOTS_AVAILABLE": "No Screenshots available",
|
||||
"NOT_IMPLEMENTED": "Dar Neįgyvendinta",
|
||||
"RECOMMENDED_ESHOP": "Recommended eShop",
|
||||
"REVISION": "Peržiūra",
|
||||
"SCREENSHOT": "Screenshot %d / %d",
|
||||
"SCREENSHOT_COULD_NOT_LOAD": "Screenshot could not be loaded.",
|
||||
"SCREENSHOT_INSTRUCTIONS": "Press to change and to zoom",
|
||||
"SEARCH_FILTERS": "Paieškos ir Filtrai",
|
||||
"SELECT_ESHOP": "Pasirinkite eShop",
|
||||
"SELECT_ESHOP_2": "Pasirinkite eShop",
|
||||
"SELECT_DIR": "Pasirinkite aplanką",
|
||||
"SELECT_LANG": "Pasirinkite kalbą",
|
||||
"SETTINGS": "Nustatymai",
|
||||
"SHEET_SLASH": "Atrodo, kad \" /\" yra įtrauktas, kuris nėra palaikomas.\nPrašome pakeisti \"lapą\" tik failo pavadinimui.",
|
||||
"SHORTCUT_CREATED": "Spartusis klavišas sukurtas!",
|
||||
"SIZE": "Dydis",
|
||||
"SORT_BY": "Rikiuoti pagal",
|
||||
"SORTING": "Rūšiavimas",
|
||||
"START_SELECT": "Paspauskite START, kad būtų galima pasirinkti dabartinį aplanką",
|
||||
"STORE_INFO": "Store Info",
|
||||
"SYNTAX_ERROR": "Sintaksės klaida!",
|
||||
"TITLE": "Pavadinimas",
|
||||
"TOP_STYLE": "Viršutinis stilius",
|
||||
"UNSUPPORTED_ESHOP_VERSION": "Šio eShop versija yra nepalaikoma.",
|
||||
"UPDATE_AVAILABLE": "Atnaujinti Turimą!",
|
||||
"UPDATE_DONE": "Atnaujinimas atliktas! Prašome iš naujo atidaryti DarkStore.",
|
||||
"UPDATE_NOT_AVAILABLE": "Atnaujinimai Nėra Prieinami!",
|
||||
"UPDATING_ESHOP": "Atnaujinti eShop ...",
|
||||
"UPDATING_SPRITE_SHEET": "Sprinteheet atnaujinimas ...",
|
||||
"UPDATING_SPRITE_SHEET2": "Atnaujinimui Spriteheet %i of %i...",
|
||||
"VERSION": "Versija",
|
||||
"WEBSITE": "Full Credit & Changelog Galima Rasti Ghosteshop.com",
|
||||
"YES": "Taip."
|
||||
}
|
||||
@@ -1,124 +0,0 @@
|
||||
{
|
||||
"ARGUMENT_INVALID": "Niepoprawny argument.\nSprawdź plik xml pod kątem właściwych argumentów.",
|
||||
"ASCENDING": "Rosnąco",
|
||||
"AUTHOR": "Autor",
|
||||
"AUTO_UPDATE_ESHOP": "Automatycznie aktualizuj sklep eShop",
|
||||
"AUTO_UPDATE_ESHOP_DESC": "Dzięki temu ostatni użyty eShop zostanie zaktualizowany automatycznie podczas uruchamiania programu DarkStore.",
|
||||
"AUTO_UPDATE_DS": "Automatycznie aktualizuj program DarkStore",
|
||||
"AUTO_UPDATE_DS_DESC": "Gdy ta opcja jest włączona, DarkStore będzie sprawdzać aktualizacje za każdym razem, gdy jest otwarty.",
|
||||
"AUTO_UPDATE_SETTINGS": "Ustawienia automatycznej aktualizacji",
|
||||
"AUTO_UPDATE_SETTINGS_BTN": "Ustawienia automatycznej aktualizacji ...",
|
||||
"AVAILABLE_DOWNLOADS": "Dostępne pobrania",
|
||||
"BOOT_TITLE": "Czy chcesz uruchomić ten tytuł?",
|
||||
"CATEGORY": "Kategoria",
|
||||
"CHANGE_3DSX_PATH": "Zmień ścieżkę 3DSX",
|
||||
"CHANGE_ARCHIVE_PATH": "Zmień ścieżkę archiwum",
|
||||
"CHANGE_NDS_PATH": "Zmiana ścieżki NDS",
|
||||
"CHANGE_SHORTCUT_PATH": "Zmień ścieżkę skrótu",
|
||||
"CHANGELOG": "Changelog",
|
||||
"CHECK_ESHOP_UPDATES": "Sprawdzanie dostępności aktualizacji eShop ...",
|
||||
"CHECK_DS_UPDATES": "Sprawdzanie pod kątem aktualizacji programu DarkStore ...",
|
||||
"CITRA_BIGN_ICON": "Citra & Nintendo dla ikony",
|
||||
"CONFIRM_OR_CANCEL": "Naciśnij klawisz Enter, aby potwierdzić, kliknij przycisk Anuluj, aby anulować.",
|
||||
"CONNECT_WIFI": "Połącz się z WiFi.",
|
||||
"CONSOLE": "Konsola",
|
||||
"CONTRIBUTOR_TRANSLATORS": "-Wszystkie Tłumacze i Kontrybutorzy",
|
||||
"COPY_ERROR": "Błąd kopiowania!",
|
||||
"CREATE_SHORTCUT": "Czy chcesz utworzyć skrót?",
|
||||
"CREDITS": "Uznania",
|
||||
"CURRENT_VERSION": "Bieżąca wersja: ",
|
||||
"CURRENTLY_EXTRACTING": "Obecnie ekstrahowanie:\n",
|
||||
"CUSTOM_FONT": "Użyj czcionki niestandardowej",
|
||||
"CUSTOM_FONT_DESC": "Jeśli ta opcja jest włączona, zamiast czcionki systemowej zostanie użyta 'sdmc:/3ds/DarkStore/font.bcfnt ', jeśli zostanie znaleziony.",
|
||||
"DELETE_ERROR": "Błąd usuwania!",
|
||||
"DELETE_PROMPT": "Czy na pewno usunąć ten katalog?",
|
||||
"DELETE_UNNEEDED_FILE": "Usuwanie niepotrzebnego pliku ...",
|
||||
"DESCENDING": "Malejąco",
|
||||
"DIRECTION": "Kierunek",
|
||||
"DIRECTORY_SETTINGS": "Ustawienia katalogu",
|
||||
"DIRECTORY_SETTINGS_BTN": "Ustawienia katalogu ...",
|
||||
"DISABLE_AUTOUPDATE_ESHOP": "Wyłącz automatyczne aktualizowanie eShop podczas startu",
|
||||
"DISABLE_UPDATE_CHECK": "Wyłącz samodzielną aktualizację",
|
||||
"DONE": "Gotowe!",
|
||||
"DOWNLOAD_ERROR": "Błąd pobierania!",
|
||||
"DOWNLOAD_FAILED": "Pobieranie nie powiodło się!",
|
||||
"DOWNLOADING_ESHOP": "Pobieranie eShop ...",
|
||||
"DOWNLOADING_ESHOP_DB": "Pobieranie eShop ...",
|
||||
"DOWNLOADING_GHOST_ESHOP": "Pobieranie programu DarkStore ...",
|
||||
"DOWNLOADING_COMPATIBLE_FONT": "Pobieranie kompatybilnej czcionki ...",
|
||||
"DOWNLOADING_SPRITE_SHEET": "Pobieranie arkusza Spritesheet ...",
|
||||
"DOWNLOADING_SPRITE_SHEET2": "Pobieranie arkusza Spritesheet %i z %i...",
|
||||
"ESHOP_BG": "Użyj eShop BG",
|
||||
"ESHOP_BG_DESC": "Jeśli ta opcja jest włączona, dla górnego ekranu zostanie wyświetlony formularz BG udostępniony przez sklep elektroniczny zamiast stałego koloru BG.",
|
||||
"ESHOP_INVALID_ERROR": "Ten eShop jest nieprawidłowy i nie może być\nzaładowany z DarkStore.\nMoże sprawdzic czy są jakieś błędy składniowe?",
|
||||
"ESHOP_TOO_NEW": "Twoja wersja programu DarkStore to\nza stare, by korzystać z tego sklepu eShop.\nProszę o aktualizację do najnowszej wersji.",
|
||||
"ESHOP_TOO_OLD": "Ten eShop jest przestarzany i nie może być używany\nz tą wersją DarkStore.\nProszę poprosić twórcę o jego aktualizację.",
|
||||
"ENABLE_AUTOUPDATE_ESHOP": "Włącz automatyczne aktualizowanie eShop podczas startu",
|
||||
"ENABLE_UPDATE_CHECK": "Włącz samodzielną aktualizację",
|
||||
"ENTER_DESC_SHORTCUT": "Wprowadź opis skrótu.",
|
||||
"ENTER_SEARCH": "Wprowadź informacje, które mają być wyszukiwane.",
|
||||
"ENTER_SHORTCUT_FILENAME": "Wprowadź nazwę pliku skrótu (bez rozszerzenia).",
|
||||
"ENTER_TITLE_SHORTCUT": "Wprowadź tytuł skrótu.",
|
||||
"ENTER_URL": "Wprowadź adres URL eSklepu.",
|
||||
"ENTRIES": "Wpisy",
|
||||
"EXECUTE_ENTRY": "Czy chcesz wykonać tę pozycję?",
|
||||
"EXIT_APP": "Wyjdź z DarkStore",
|
||||
"FETCHING_METADATA": "Pobieranie starych metadanych ...",
|
||||
"FETCHING_RECOMMENDED_ESHOP": "Fetching recommended eShop...",
|
||||
"FILE_EXTRACTED": "plik wyodrębniony.",
|
||||
"FILES_HOSTING_ANONYKU": "Anonyku dla plików hostingowych",
|
||||
"FILE_SLASH": "Wygląda na to, że włączona jest opcja ' /', która nie jest obsługiwana.\nZmień 'plik' tylko na nazwę pliku.",
|
||||
"FILES_EXTRACTED": "pliki wyodrębnione.",
|
||||
"FILTER_TO": "Filtruj do:",
|
||||
"GRID": "Siatka",
|
||||
"GUI_SETTINGS": "Ustawienia interfejsu GUI",
|
||||
"GUI_SETTINGS_BTN": "Ustawienia interfejsu GUI ...",
|
||||
"INCLUDE_IN_RESULTS": "Uwzględnij w wynikach:",
|
||||
"INSTALL_GHOST_ESHOP": "Instalowanie programu DarkStore ...",
|
||||
"INVALID_ESHOP": "Niepoprawny sklep eShop",
|
||||
"KEY_CONTINUE": "Naciśnij dowolny klawisz, aby kontynuować.",
|
||||
"LANGUAGE": "Język",
|
||||
"LAST_UPDATED": "Ostatnia aktualizacja",
|
||||
"LIST": "Lista",
|
||||
"LOADING_SPRITESHEET": "Ładowanie arkusza Spritesheet %i z %i...",
|
||||
"MEDIATYPE_NAND": "NAND typu MediaType",
|
||||
"MEDIATYPE_SD": "MediaType SD",
|
||||
"MOVE_ERROR": "Błąd przeniesienia!",
|
||||
"NO": "Nie",
|
||||
"NO_ADDITIONAL_CONTENT_AVAILABLE": "Brak dostępnej dodatkowej treści",
|
||||
"NO_DOWNLOADS_AVAILABLE": "Brak dostępnych pobrań",
|
||||
"NO_SIZE": "Brak wielkości",
|
||||
"NO_SCREENSHOTS_AVAILABLE": "No Screenshots available",
|
||||
"NOT_IMPLEMENTED": "Jeszcze nie zaimplementowane",
|
||||
"RECOMMENDED_ESHOP": "Recommended eShop",
|
||||
"REVISION": "Podwersja",
|
||||
"SCREENSHOT": "Screenshot %d / %d",
|
||||
"SCREENSHOT_COULD_NOT_LOAD": "Screenshot could not be loaded.",
|
||||
"SCREENSHOT_INSTRUCTIONS": "Press to change and to zoom",
|
||||
"SEARCH_FILTERS": "Wyszukiwanie i filtry",
|
||||
"SELECT_ESHOP": "Wybierz sklep eShop",
|
||||
"SELECT_ESHOP_2": "Wybierz sklep eShop",
|
||||
"SELECT_DIR": "Wybierz katalog",
|
||||
"SELECT_LANG": "Wybierz język",
|
||||
"SETTINGS": "Ustawienia",
|
||||
"SHEET_SLASH": "Wygląda na to, że włączona jest opcja ' /', która nie jest obsługiwana.\nZmień 'arkusz' tylko na nazwę pliku.",
|
||||
"SHORTCUT_CREATED": "Utworzono skrót!",
|
||||
"SIZE": "Wielkość",
|
||||
"SORT_BY": "Sortuj wg",
|
||||
"SORTING": "Sortowanie",
|
||||
"START_SELECT": "Naciśnij START, aby wybrać bieżący folder",
|
||||
"STORE_INFO": "Store Info",
|
||||
"SYNTAX_ERROR": "Błąd składniowy!",
|
||||
"TITLE": "Tytuł",
|
||||
"TOP_STYLE": "Styl najwyższego poziomu",
|
||||
"UNSUPPORTED_ESHOP_VERSION": "Wersja tego sklepu eShop nie jest obsługiwana.",
|
||||
"UPDATE_AVAILABLE": "Aktualizacja jest dostępna!",
|
||||
"UPDATE_DONE": "Aktualizacja została wykonana! Proszę ponownie otworzyć DarkStore.",
|
||||
"UPDATE_NOT_AVAILABLE": "Brak dostępnych aktualizacji!",
|
||||
"UPDATING_ESHOP": "Aktualizowanie produktu eShop ...",
|
||||
"UPDATING_SPRITE_SHEET": "Aktualizowanie arkusza Spritesheet ...",
|
||||
"UPDATING_SPRITE_SHEET2": "Aktualizowanie arkusza Spritesheet %i z dnia %i...",
|
||||
"VERSION": "Wersja",
|
||||
"WEBSITE": "Full Credits & Changelog Można Znaleźć Na Stronie Ghosteshop.com",
|
||||
"YES": "Tak"
|
||||
}
|
||||
@@ -1,124 +0,0 @@
|
||||
{
|
||||
"ARGUMENT_INVALID": "Argument invalid.\nPlease check the xml file for proper arguments.",
|
||||
"ASCENDING": "Crescente",
|
||||
"AUTHOR": "Author",
|
||||
"AUTO_UPDATE_SETTINGS": "Ajustes de atualização automática",
|
||||
"AUTO_UPDATE_SETTINGS_BTN": "Atualização automática...",
|
||||
"AUTO_UPDATE_ESHOP": "Atualizar eShop automaticamente",
|
||||
"AUTO_UPDATE_ESHOP_DESC": "Se ativado, a ultima eShop usada na ultima sessão será atualizada automaticamente ao abrir o DarkStore.",
|
||||
"AUTO_UPDATE_DS": "Atualizar DarkStore automaticamente",
|
||||
"AUTO_UPDATE_DS_DESC": "Se ativado, DarkStore vai buscar por atualizações toda vez que for aberto.",
|
||||
"AVAILABLE_DOWNLOADS": "Downloads disponíveis",
|
||||
"BOOT_TITLE": "Would you like to boot this title?",
|
||||
"CATEGORY": "Categoria",
|
||||
"CHANGE_3DSX_PATH": "Alterar pasta \"3DSX\"",
|
||||
"CHANGE_ARCHIVE_PATH": "Alterar pasta temporária",
|
||||
"CHANGE_NDS_PATH": "Alterar pasta \"NDS\"",
|
||||
"CHANGE_SHORTCUT_PATH": "Change shortcut path",
|
||||
"CHANGELOG": "Changelog",
|
||||
"CHECK_ESHOP_UPDATES": "Verificando atualizações para eShop...",
|
||||
"CHECK_DS_UPDATES": "Verificando atualizações para DarkStore...",
|
||||
"CONFIRM_OR_CANCEL": ": Confirmar | : Cancelar",
|
||||
"CONNECT_WIFI": "Please Connect to WiFi.",
|
||||
"CONSOLE": "Console",
|
||||
"CONTRIBUTOR_TRANSLATORS": "- Todos os tradutores e colaboradores",
|
||||
"COPY_ERROR": "Copy Error!",
|
||||
"CITRA_BIGN_ICON": "Citra & Nintendo for the Icon",
|
||||
"CREATE_SHORTCUT": "Would you like to create a shortcut?",
|
||||
"CREDITS": "Créditos",
|
||||
"CURRENT_VERSION": "Versão instalada: ",
|
||||
"CURRENTLY_EXTRACTING": "Currently extracting:\n",
|
||||
"CUSTOM_FONT": "Use Custom Font",
|
||||
"CUSTOM_FONT_DESC": "If enabled, 'sdmc:/3ds/DarkStore/font.bcfnt' will be used instead of the system font, if found.",
|
||||
"DELETE_ERROR": "Delete Error!",
|
||||
"DELETE_PROMPT": "Are you sure you want to delete this Directory?",
|
||||
"DELETE_UNNEEDED_FILE": "Deleting unneeded file...",
|
||||
"DESCENDING": "Decrescente",
|
||||
"DIRECTION": "Ordem",
|
||||
"DIRECTORY_SETTINGS": "Directory Settings",
|
||||
"DIRECTORY_SETTINGS_BTN": "Directory settings...",
|
||||
"DISABLE_AUTOUPDATE_ESHOP": "Disable auto-update eShop on boot",
|
||||
"DISABLE_UPDATE_CHECK": "Disable self-updating",
|
||||
"DONE": "Tudo pronto!",
|
||||
"DOWNLOAD_ERROR": "Erro no download!",
|
||||
"DOWNLOAD_FAILED": "Falha no download!",
|
||||
"DOWNLOADING_COMPATIBLE_FONT": "Downloading compatible font...",
|
||||
"DOWNLOADING_SPRITE_SHEET": "Baixando spritesheet...",
|
||||
"DOWNLOADING_SPRITE_SHEET2": "Baixando spritesheet %i de %i...",
|
||||
"DOWNLOADING_ESHOP_DB": "Baixando eShop...",
|
||||
"DOWNLOADING_GHOST_ESHOP": "Baixando DarkStore...",
|
||||
"DOWNLOADING_ESHOP": "Baixando eShop...",
|
||||
"ENABLE_AUTOUPDATE_ESHOP": "Enable auto-update eShop on boot",
|
||||
"ENABLE_UPDATE_CHECK": "Enable self-updating",
|
||||
"ENTER_DESC_SHORTCUT": "Enter the shortcut description.",
|
||||
"ENTER_SEARCH": "Enter what you like to search.",
|
||||
"ENTER_SHORTCUT_FILENAME": "Enter the shortcut filename (without extension).",
|
||||
"ENTER_TITLE_SHORTCUT": "Enter the shortcut title.",
|
||||
"ENTER_URL": "Insira o link da eShop.",
|
||||
"ENTRIES": "Entries",
|
||||
"ESHOP_BG": "Use eShop BG",
|
||||
"ESHOP_BG_DESC": "When enabled, the eShop's provided BG will be shown instead of the solid BG color for the top screen.",
|
||||
"ESHOP_INVALID_ERROR": "This eShop is invalid and cannot be\nloaded with DarkStore.\nMaybe check if there are any Syntax errors?",
|
||||
"ESHOP_TOO_NEW": "Your version of DarkStore is\ntoo old to use this eShop.\nPlease update to the latest version.",
|
||||
"ESHOP_TOO_OLD": "This eShop is outdated and cannot be used\nwith this version of DarkStore.\nPlease ask the creator to update it.",
|
||||
"EXECUTE_ENTRY": "Tem certeza de que quer executar este item?",
|
||||
"EXIT_APP": "Exit DarkStore",
|
||||
"FETCHING_METADATA": "Fetching old metadata...",
|
||||
"FETCHING_RECOMMENDED_ESHOP": "Fetching recommended eShop...",
|
||||
"FILE_EXTRACTED": "file extracted.",
|
||||
"FILE_SLASH": "Uma '/' foi incluida no caminho do arquivo — algo que não é compatível.\nAjuste a chave 'file' para que ela contenha somente o nome do arquivo.",
|
||||
"FILES_EXTRACTED": "files extracted.",
|
||||
"FILES_HOSTING_ANONYKU": "Anonyku For Hosting Files",
|
||||
"FILTER_TO": "Filtrar somente:",
|
||||
"GRID": "Blocos",
|
||||
"GUI_SETTINGS": "Configuração da interface",
|
||||
"GUI_SETTINGS_BTN": "Interface...",
|
||||
"INCLUDE_IN_RESULTS": "Incluir na pesquisa:",
|
||||
"INSTALL_GHOST_ESHOP": "Installing DarkStore...",
|
||||
"INVALID_ESHOP": "Invalid eShop",
|
||||
"KEY_CONTINUE": "Pressione qualquer botão para continuar.",
|
||||
"LANGUAGE": "Idioma",
|
||||
"LAST_UPDATED": "Atualizado pela ultima vez",
|
||||
"LIST": "Lista",
|
||||
"LOADING_SPRITESHEET": "Carregando spritesheet %i de %i...",
|
||||
"MEDIATYPE_NAND": "MediaType NAND",
|
||||
"MEDIATYPE_SD": "MediaType SD",
|
||||
"MOVE_ERROR": "Move Error!",
|
||||
"NO": "No",
|
||||
"NO_ADDITIONAL_CONTENT_AVAILABLE": "No Additional Content Available",
|
||||
"NO_DOWNLOADS_AVAILABLE": "Não há nenhum download disponível",
|
||||
"NO_SCREENSHOTS_AVAILABLE": "No Screenshots available",
|
||||
"NO_SIZE": "No Size",
|
||||
"NOT_IMPLEMENTED": "Not Implemented Yet",
|
||||
"RECOMMENDED_ESHOP": "Recommended eShop",
|
||||
"REVISION": "Revision",
|
||||
"SCREENSHOT": "Screenshot %d / %d",
|
||||
"SCREENSHOT_COULD_NOT_LOAD": "Screenshot could not be loaded.",
|
||||
"SCREENSHOT_INSTRUCTIONS": "Press to change and to zoom",
|
||||
"SEARCH_FILTERS": "Pesquisa e Filtros",
|
||||
"SELECT_DIR": "Escolha uma pasta",
|
||||
"SELECT_LANG": "Escolha um idioma",
|
||||
"SELECT_ESHOP": "Select eShop",
|
||||
"SELECT_ESHOP_2": "Escolha uma eShop",
|
||||
"SETTINGS": "Configurações",
|
||||
"SHEET_SLASH": "Uma '/' foi incluida no caminho da spritesheet — algo que não é compatível.\nAjuste a chave 'sheet' para que ela contenha somente o nome do arquivo.",
|
||||
"SHORTCUT_CREATED": "Shortcut created!",
|
||||
"SIZE": "Size",
|
||||
"SORT_BY": "Classificar por",
|
||||
"SORTING": "Sorting",
|
||||
"START_SELECT": "Pressione START para selecionar a pasta atual",
|
||||
"STORE_INFO": "Store Info",
|
||||
"SYNTAX_ERROR": "Syntax Error!",
|
||||
"TITLE": "Title",
|
||||
"TOP_STYLE": "Exibir em",
|
||||
"UNSUPPORTED_ESHOP_VERSION": "The version of this eShop is unsupported.",
|
||||
"UPDATE_AVAILABLE": "Atualização disponível!",
|
||||
"UPDATE_DONE": "Atualização concluida! Por favor, reinicie DarkStore.",
|
||||
"UPDATE_NOT_AVAILABLE": "Nenhuma atualização disponível!",
|
||||
"UPDATING_SPRITE_SHEET": "Atualizando spritesheet...",
|
||||
"UPDATING_SPRITE_SHEET2": "Atualizando spritesheet %i de %i...",
|
||||
"UPDATING_ESHOP": "Atualizando a eShop...",
|
||||
"VERSION": "Versão",
|
||||
"WEBSITE": "Full Credits & Changelog Can Be Found On Ghosteshop.com",
|
||||
"YES": "Yes"
|
||||
}
|
||||
@@ -1,124 +0,0 @@
|
||||
{
|
||||
"ARGUMENT_INVALID": "Argumento inválido.\nPor favor, verifique o arquivo xml para argumentos adequados.",
|
||||
"ASCENDING": "Crescente",
|
||||
"AUTHOR": "Autor",
|
||||
"AUTO_UPDATE_ESHOP": "EShop de atualização automática",
|
||||
"AUTO_UPDATE_ESHOP_DESC": "Com isso, o último eShop usado será atualizado automaticamente ao lançar o DarkStore.",
|
||||
"AUTO_UPDATE_DS": "Auto-update DarkStore",
|
||||
"AUTO_UPDATE_DS_DESC": "Quando ativado, o DarkStore irá verificar as atualizações toda vez que for aberto.",
|
||||
"AUTO_UPDATE_SETTINGS": "Configurações de Auto-Atualização",
|
||||
"AUTO_UPDATE_SETTINGS_BTN": "Configurações de auto-atualização ...",
|
||||
"AVAILABLE_DOWNLOADS": "Downloads disponíveis",
|
||||
"BOOT_TITLE": "Você gostaria de bota este título?",
|
||||
"CATEGORY": "Categoria",
|
||||
"CHANGE_3DSX_PATH": "Alterar caminho 3DSX",
|
||||
"CHANGE_ARCHIVE_PATH": "Alterar caminho de arquivo",
|
||||
"CHANGE_NDS_PATH": "Alterar caminho NDS",
|
||||
"CHANGE_SHORTCUT_PATH": "Alterar caminho de atalho",
|
||||
"CHANGELOG": "Changelog",
|
||||
"CHECK_ESHOP_UPDATES": "Verificando as atualizações de eShop ...",
|
||||
"CHECK_DS_UPDATES": "Verificando as atualizações do DarkStore ...",
|
||||
"CITRA_BIGN_ICON": "Citra & Nintendo para o Icon",
|
||||
"CONFIRM_OR_CANCEL": "Pressione para confirmar, precisa cancelar.",
|
||||
"CONNECT_WIFI": "Por favor, se conecte ao WiFi.",
|
||||
"CONSOLE": "Console",
|
||||
"CONTRIBUTOR_TRANSLATORS": "-Todos os Tradutores & Contribuintes",
|
||||
"COPY_ERROR": "Erro de Cópia!",
|
||||
"CREATE_SHORTCUT": "Você gostaria de criar um atalho?",
|
||||
"CREDITS": "Créditos",
|
||||
"CURRENT_VERSION": "Versão atual: ",
|
||||
"CURRENTLY_EXTRACTING": "Atualmente extraindo:\n",
|
||||
"CUSTOM_FONT": "Usar Fonte Personalizada",
|
||||
"CUSTOM_FONT_DESC": "Se ativado, o 'sdmc: /3ds/DarkStore/font.bcfnt' será usado em vez da fonte do sistema, se encontrado.",
|
||||
"DELETE_ERROR": "Erro de Exclusão!",
|
||||
"DELETE_PROMPT": "Tem certeza de que deseja excluir este Diretório?",
|
||||
"DELETE_UNNEEDED_FILE": "Excluindo arquivo não necessário ...",
|
||||
"DESCENDING": "Decrescente",
|
||||
"DIRECTION": "Direção",
|
||||
"DIRECTORY_SETTINGS": "Configurações do Diretório",
|
||||
"DIRECTORY_SETTINGS_BTN": "Configurações do diretório ...",
|
||||
"DISABLE_AUTOUPDATE_ESHOP": "Desativar a auto-atualização eShop no boot",
|
||||
"DISABLE_UPDATE_CHECK": "Desativar a auto-atualização",
|
||||
"DONE": "Feito!",
|
||||
"DOWNLOAD_ERROR": "Erro de Download!",
|
||||
"DOWNLOAD_FAILED": "Download Falhou!",
|
||||
"DOWNLOADING_ESHOP": "Download de eShop ...",
|
||||
"DOWNLOADING_ESHOP_DB": "Download de eShop ...",
|
||||
"DOWNLOADING_GHOST_ESHOP": "Downloading DarkStore ...",
|
||||
"DOWNLOADING_COMPATIBLE_FONT": "Download de fonte compatível ...",
|
||||
"DOWNLOADING_SPRITE_SHEET": "Download de Spritesheet ...",
|
||||
"DOWNLOADING_SPRITE_SHEET2": "Baixando o Spritesheet %i de %i...",
|
||||
"ESHOP_BG": "Use eShop BG",
|
||||
"ESHOP_BG_DESC": "Quando ativado, o BG fornecido da eShop será mostrado em vez da cor BG sólida para a tela superior.",
|
||||
"ESHOP_INVALID_ERROR": "Este eShop é inválido e não pode ser\ncarregado com DarkStore.\nTalvez verificar se há algum erro Sintaxe?",
|
||||
"ESHOP_TOO_NEW": "Sua versão do DarkStore é\nminutos muito velha para usar este eShop.\nAtualize para a versão mais recente.",
|
||||
"ESHOP_TOO_OLD": "Este eShop é ultrapassado e não pode ser usado\ncom esta versão do DarkStore.\nPor favor, peça ao criador para atualizá-lo.",
|
||||
"ENABLE_AUTOUPDATE_ESHOP": "Ativar eShop de atualização automática na inicialização",
|
||||
"ENABLE_UPDATE_CHECK": "Habilitar a auto-atualização",
|
||||
"ENTER_DESC_SHORTCUT": "Insira a descrição do atalho.",
|
||||
"ENTER_SEARCH": "Digite o que você gosta de pesquisar.",
|
||||
"ENTER_SHORTCUT_FILENAME": "Digite o atalho filename (sem extensão).",
|
||||
"ENTER_TITLE_SHORTCUT": "Insira o título de atalho.",
|
||||
"ENTER_URL": "Digite a URL do eShop.",
|
||||
"ENTRIES": "Entradas",
|
||||
"EXECUTE_ENTRY": "Você gostaria de executar esta entrada?",
|
||||
"EXIT_APP": "Sair DarkStore",
|
||||
"FETCHING_METADATA": "Buscar metadados antigos ...",
|
||||
"FETCHING_RECOMMENDED_ESHOP": "Fetching recommended eShop...",
|
||||
"FILE_EXTRACTED": "arquivo extraído.",
|
||||
"FILES_HOSTING_ANONYKU": "Anonyku Para Hospedagem De Arquivos",
|
||||
"FILE_SLASH": "Parece que um ' /' está incluído, o que não é suportado.\naltere 'arquivo' apenas para filename.",
|
||||
"FILES_EXTRACTED": "arquivos extraídos.",
|
||||
"FILTER_TO": "Filtrar para:",
|
||||
"GRID": "Grade",
|
||||
"GUI_SETTINGS": "Configurações da GUI",
|
||||
"GUI_SETTINGS_BTN": "Configurações da GUI ...",
|
||||
"INCLUDE_IN_RESULTS": "Incluir em resultados:",
|
||||
"INSTALL_GHOST_ESHOP": "Instalando DarkStore ...",
|
||||
"INVALID_ESHOP": "EShop inválido",
|
||||
"KEY_CONTINUE": "Pressione qualquer tecla para continuar.",
|
||||
"LANGUAGE": "Idioma",
|
||||
"LAST_UPDATED": "Última atualização",
|
||||
"LIST": "Lista",
|
||||
"LOADING_SPRITESHEET": "Carregando Spritesheet %i de %i...",
|
||||
"MEDIATYPE_NAND": "MediaTipo NAND",
|
||||
"MEDIATYPE_SD": "MediaTipo SD",
|
||||
"MOVE_ERROR": "Mover Erro!",
|
||||
"NO": "Não",
|
||||
"NO_ADDITIONAL_CONTENT_AVAILABLE": "Nenhum Conteúdo Adicional Disponível",
|
||||
"NO_DOWNLOADS_AVAILABLE": "Nenhum downloads disponível",
|
||||
"NO_SIZE": "Sem Tamanho",
|
||||
"NO_SCREENSHOTS_AVAILABLE": "No Screenshots available",
|
||||
"NOT_IMPLEMENTED": "Não Implementado Ainda",
|
||||
"RECOMMENDED_ESHOP": "Recommended eShop",
|
||||
"REVISION": "Revisão",
|
||||
"SCREENSHOT": "Screenshot %d / %d",
|
||||
"SCREENSHOT_COULD_NOT_LOAD": "Screenshot could not be loaded.",
|
||||
"SCREENSHOT_INSTRUCTIONS": "Press to change and to zoom",
|
||||
"SEARCH_FILTERS": "Procurar e Filtros",
|
||||
"SELECT_ESHOP": "Selecionar eShop",
|
||||
"SELECT_ESHOP_2": "Selecione um eShop",
|
||||
"SELECT_DIR": "Selecione um diretório",
|
||||
"SELECT_LANG": "Escolha o idioma",
|
||||
"SETTINGS": "Configurações",
|
||||
"SHEET_SLASH": "Parece que um ' /' está incluído, o que não é suportado.\naltere 'folha' apenas para filename.",
|
||||
"SHORTCUT_CREATED": "Atalho criado!",
|
||||
"SIZE": "Tamanho",
|
||||
"SORT_BY": "Classificar Por",
|
||||
"SORTING": "Classificação",
|
||||
"START_SELECT": "Pressione START para selecionar a pasta atual",
|
||||
"STORE_INFO": "Store Info",
|
||||
"SYNTAX_ERROR": "Erro de Sintaxe!",
|
||||
"TITLE": "Título",
|
||||
"TOP_STYLE": "Estilo Superior",
|
||||
"UNSUPPORTED_ESHOP_VERSION": "A versão deste eShop está sem suporte.",
|
||||
"UPDATE_AVAILABLE": "Atualização Disponível!",
|
||||
"UPDATE_DONE": "Atualização feita! Favor reabrir o DarkStore.",
|
||||
"UPDATE_NOT_AVAILABLE": "Sem Atualizações Disponíveis!",
|
||||
"UPDATING_ESHOP": "Atualizando eShop ...",
|
||||
"UPDATING_SPRITE_SHEET": "Atualização de Spritesheet ...",
|
||||
"UPDATING_SPRITE_SHEET2": "Atualização do Spritesheet %i de %i...",
|
||||
"VERSION": "Versão",
|
||||
"WEBSITE": "Créditos Completos & Changelog Podem Ser Encontrados No Ghosteshop.com",
|
||||
"YES": "Sim"
|
||||
}
|
||||
@@ -1,124 +0,0 @@
|
||||
{
|
||||
"ARGUMENT_INVALID": "Argument invalid.\nPlease check the xml file for proper arguments.",
|
||||
"ASCENDING": "По возрастанию",
|
||||
"AUTHOR": "Автор",
|
||||
"AUTO_UPDATE_SETTINGS": "Настройки автообновления",
|
||||
"AUTO_UPDATE_SETTINGS_BTN": "Настройки автообновления...",
|
||||
"AUTO_UPDATE_ESHOP": "Автообновление eShop",
|
||||
"AUTO_UPDATE_ESHOP_DESC": "При включении настройки - последний используемый UniStore будет автоматически обновлен при запуске DarkStore.",
|
||||
"AUTO_UPDATE_DS": "Автообновление DarkStore",
|
||||
"AUTO_UPDATE_DS_DESC": "Если включено, то DarkStore будет проверять обновления при каждом запуске.",
|
||||
"AVAILABLE_DOWNLOADS": "Доступные для загрузки",
|
||||
"BOOT_TITLE": "Вы хотите войти в эту игру?",
|
||||
"CATEGORY": "Катеория",
|
||||
"CHANGE_3DSX_PATH": "Изменить путь 3DSX",
|
||||
"CHANGE_ARCHIVE_PATH": "Изменить путь к архиву",
|
||||
"CHANGE_NDS_PATH": "Изменить путь NDS",
|
||||
"CHANGE_SHORTCUT_PATH": "Change shortcut path",
|
||||
"CHANGELOG": "Журнал изменений",
|
||||
"CHECK_ESHOP_UPDATES": "Проверка обновление eShop...",
|
||||
"CHECK_DS_UPDATES": "Проверка обновлений DarkStore...",
|
||||
"CITRA_BIGN_ICON": "Citra и Nintendo для иконы",
|
||||
"CONFIRM_OR_CANCEL": "Нажмите для подтверждения, для отмены.",
|
||||
"CONNECT_WIFI": "Пожалуйста, подключитесь к WiFi.",
|
||||
"CONSOLE": "Консоль",
|
||||
"CONTRIBUTOR_TRANSLATORS": "- Все переводчики и участники",
|
||||
"COPY_ERROR": "Ошибка копирования!",
|
||||
"CREATE_SHORTCUT": "Would you like to create a shortcut?",
|
||||
"CREDITS": "Благодарность",
|
||||
"CURRENT_VERSION": "Текущая версия: ",
|
||||
"CURRENTLY_EXTRACTING": "Извлекается:\n",
|
||||
"CUSTOM_FONT": "Use Custom Font",
|
||||
"CUSTOM_FONT_DESC": "If enabled, 'sdmc:/3ds/DarkStore/font.bcfnt' will be used instead of the system font, if found.",
|
||||
"DELETE_ERROR": "Ошибка удаления!",
|
||||
"DELETE_PROMPT": "Вы уверены, что хотите удалить эту директорию?",
|
||||
"DELETE_UNNEEDED_FILE": "Удаление ненужного файла...",
|
||||
"DESCENDING": "По убыванию",
|
||||
"DIRECTION": "Направление",
|
||||
"DIRECTORY_SETTINGS": "Настройки директории",
|
||||
"DIRECTORY_SETTINGS_BTN": "Настройки директории...",
|
||||
"DISABLE_AUTOUPDATE_ESHOP": "Отключить авто-обновление eShop при загрузке",
|
||||
"DISABLE_UPDATE_CHECK": "Отключить самообновление",
|
||||
"DONE": "Готово!",
|
||||
"DOWNLOAD_ERROR": "Ошибка загрузки!",
|
||||
"DOWNLOAD_FAILED": "Ошибка с загрузкой!",
|
||||
"DOWNLOADING_COMPATIBLE_FONT": "Downloading compatible font...",
|
||||
"DOWNLOADING_SPRITE_SHEET": "Загрузка таблицы спрайтов...",
|
||||
"DOWNLOADING_SPRITE_SHEET2": "Загрузка таблицы спрайтов %i из %i...",
|
||||
"DOWNLOADING_ESHOP_DB": "Загрузка eShop...",
|
||||
"DOWNLOADING_GHOST_ESHOP": "Загрузка DarkStore...",
|
||||
"DOWNLOADING_ESHOP": "Загрузка eShop...",
|
||||
"ENABLE_AUTOUPDATE_ESHOP": "Включить автообновление UniStore при загрузке",
|
||||
"ENABLE_UPDATE_CHECK": "Включить само-обновление",
|
||||
"ENTER_DESC_SHORTCUT": "Enter the shortcut description.",
|
||||
"ENTER_SEARCH": "Введите что вы хотите найти.",
|
||||
"ENTER_SHORTCUT_FILENAME": "Enter the shortcut filename (without extension).",
|
||||
"ENTER_TITLE_SHORTCUT": "Enter the shortcut title.",
|
||||
"ENTER_URL": "Введите URL eShop.",
|
||||
"ENTRIES": "Записи",
|
||||
"ESHOP_BG": "Использовать фон eShop",
|
||||
"ESHOP_BG_DESC": "Когда включено, будет показан фон предоставленный eShop вместо сплошного цвета фона для верхнего экрана.",
|
||||
"ESHOP_INVALID_ERROR": "UniStore некорректен и не может быть загружен DarkStore.\nМожет быть стоить проверить синтаксические ошибки?",
|
||||
"ESHOP_TOO_NEW": "Ваша версия DarkStore \nслишком старая для использования этого eShop.\nПожалуйста, обновитесь до последней версии.",
|
||||
"ESHOP_TOO_OLD": "Этот eShop устарел и не может быть использован\nс этой версией DarkStore.\nПожалуйста, попросите автора обновить его.",
|
||||
"EXECUTE_ENTRY": "Выполнить эту запись?",
|
||||
"EXIT_APP": "Выйти из DarkStore",
|
||||
"FETCHING_METADATA": "Получение старых метаданных...",
|
||||
"FETCHING_RECOMMENDED_ESHOP": "Fetching recommended eShop...",
|
||||
"FILE_EXTRACTED": "файл извлечен.",
|
||||
"FILE_SLASH": "Похоже, что используется символ '/'. Он не поддерживается\nПожалуйста, измените 'file' только на имя файла.",
|
||||
"FILES_EXTRACTED": "файлы извлечены.",
|
||||
"FILES_HOSTING_ANONYKU": "Anonyku для размещения файлов",
|
||||
"FILTER_TO": "Фильтр:",
|
||||
"GRID": "Сетка",
|
||||
"GUI_SETTINGS": "Настройки GUI",
|
||||
"GUI_SETTINGS_BTN": "Настройки GUI...",
|
||||
"INCLUDE_IN_RESULTS": "Включить в результаты:",
|
||||
"INSTALL_GHOST_ESHOP": "Установка DarkStore...",
|
||||
"INVALID_ESHOP": "Неверный eShop",
|
||||
"KEY_CONTINUE": "Нажмите любую кнопку для продолжения.",
|
||||
"LANGUAGE": "Язык",
|
||||
"LAST_UPDATED": "Последнее обновление",
|
||||
"LIST": "Список",
|
||||
"LOADING_SPRITESHEET": "Загрузка таблицы спрайтов %i из %i...",
|
||||
"MEDIATYPE_NAND": "Тип медии NAND",
|
||||
"MEDIATYPE_SD": "Тип медии SD",
|
||||
"MOVE_ERROR": "Ошибка перемещения!",
|
||||
"NO": "Нет",
|
||||
"NO_ADDITIONAL_CONTENT_AVAILABLE": "Дополнительный контент недоступен",
|
||||
"NO_DOWNLOADS_AVAILABLE": "Отсутствуют файлы для загрузки",
|
||||
"NO_SCREENSHOTS_AVAILABLE": "No Screenshots available",
|
||||
"NO_SIZE": "No Size",
|
||||
"NOT_IMPLEMENTED": "Ещё не реализовано",
|
||||
"RECOMMENDED_ESHOP": "Recommended eShop",
|
||||
"REVISION": "Ревизия",
|
||||
"SCREENSHOT": "Screenshot %d / %d",
|
||||
"SCREENSHOT_COULD_NOT_LOAD": "Screenshot could not be loaded.",
|
||||
"SCREENSHOT_INSTRUCTIONS": "Press to change and to zoom",
|
||||
"SEARCH_FILTERS": "Поиск и фильтры",
|
||||
"SELECT_DIR": "Выберите каталог",
|
||||
"SELECT_LANG": "Выберите язык",
|
||||
"SELECT_ESHOP": "Выберите eShop",
|
||||
"SELECT_ESHOP_2": "Выберите eShop",
|
||||
"SETTINGS": "Настройки",
|
||||
"SHEET_SLASH": "Похоже, что используется символ '/'. Он не поддерживается.\nПожалуйста, измените 'sheet' только на имя файла.",
|
||||
"SHORTCUT_CREATED": "Shortcut created!",
|
||||
"SIZE": "Size",
|
||||
"SORT_BY": "Сортировка по",
|
||||
"SORTING": "Сортировка",
|
||||
"START_SELECT": "Нажмите Start для выбора текущей папки",
|
||||
"STORE_INFO": "Store Info",
|
||||
"SYNTAX_ERROR": "Синтаксическая ошибка!",
|
||||
"TITLE": "Название",
|
||||
"TOP_STYLE": "Верхний стиль",
|
||||
"UNSUPPORTED_ESHOP_VERSION": "Версия этого eShop не поддерживается.",
|
||||
"UPDATE_AVAILABLE": "Доступны обновление!",
|
||||
"UPDATE_DONE": "Обновление завершено! Перезапустите DarkStore.",
|
||||
"UPDATE_NOT_AVAILABLE": "Нет доступных обновлений!",
|
||||
"UPDATING_SPRITE_SHEET": "Загрузка таблицы спрайтов...",
|
||||
"UPDATING_SPRITE_SHEET2": "Загрузка таблицы спрайтов %i из %i...",
|
||||
"UPDATING_ESHOP": "Обновление eShop...",
|
||||
"VERSION": "Версия",
|
||||
"WEBSITE": "Полный список авторов и список изменений можно найти на Ghosteshop.com",
|
||||
"YES": "Да"
|
||||
}
|
||||
@@ -1,124 +0,0 @@
|
||||
{
|
||||
"ARGUMENT_INVALID": "Bağımsız değişken geçersiz.\nLütfen doğru bağımsız değişkenler için xml dosyasını kontrol edin.",
|
||||
"ASCENDING": "Yükselen",
|
||||
"AUTHOR": "Yazar",
|
||||
"AUTO_UPDATE_ESHOP": "Otomatik güncelleme (eShop)",
|
||||
"AUTO_UPDATE_ESHOP_DESC": "Bununla birlikte, son kullanılan eShop DarkStore 'ı başlatırken otomatik olarak güncellenecek.",
|
||||
"AUTO_UPDATE_DS": "DarkStore 'ı otomatik güncelle",
|
||||
"AUTO_UPDATE_DS_DESC": "DarkStore etkinleştirildiğinde, her açıldığında güncelleme olup olmadığını denetler.",
|
||||
"AUTO_UPDATE_SETTINGS": "Otomatik Güncelleme Ayarları",
|
||||
"AUTO_UPDATE_SETTINGS_BTN": "Ayarları otomatik olarak güncelle ...",
|
||||
"AVAILABLE_DOWNLOADS": "Kullanılabilir Yüklemeler",
|
||||
"BOOT_TITLE": "Bu başlığı önyüklemek istiyor musunuz?",
|
||||
"CATEGORY": "Kategori",
|
||||
"CHANGE_3DSX_PATH": "3DSX yolunu değiştir",
|
||||
"CHANGE_ARCHIVE_PATH": "Arşiv yolunu değiştir",
|
||||
"CHANGE_NDS_PATH": "NDS yolunu değiştir",
|
||||
"CHANGE_SHORTCUT_PATH": "Kısayol yolunu değiştir",
|
||||
"CHANGELOG": "Değişiklik Günlüğü",
|
||||
"CHECK_ESHOP_UPDATES": "EShop güncellemeleri denetleniyor ...",
|
||||
"CHECK_DS_UPDATES": "DarkStore güncellemeleri denetleniyor ...",
|
||||
"CITRA_BIGN_ICON": "Simge için Citra ve Nintendo",
|
||||
"CONFIRM_OR_CANCEL": "Onaylamak için düğmeye basın, iptal etmek için kullanın.",
|
||||
"CONNECT_WIFI": "Lütfen WiFi 'ye bağlanın.",
|
||||
"CONSOLE": "Konsol",
|
||||
"CONTRIBUTOR_TRANSLATORS": "-Tüm Çevirmenler ve Katkıda Bulunanlar",
|
||||
"COPY_ERROR": "Kopyalama Hatası!",
|
||||
"CREATE_SHORTCUT": "Bir kısayol oluşturmak istiyor musunuz?",
|
||||
"CREDITS": "Alacaklar",
|
||||
"CURRENT_VERSION": "Yürürlükteki sürüm: ",
|
||||
"CURRENTLY_EXTRACTING": "Şu anda ayıklanıyor:\n",
|
||||
"CUSTOM_FONT": "Özel Yazı Tipi Kullan",
|
||||
"CUSTOM_FONT_DESC": "Etkinleştirilirse, sistem yazı tipi yerine 'sdmc: /3ds/DarkStore/font.bcfnt' kullanılır.",
|
||||
"DELETE_ERROR": "Silme Hatası!",
|
||||
"DELETE_PROMPT": "Bu Dizini silmek istediğinizden emin misiniz?",
|
||||
"DELETE_UNNEEDED_FILE": "Gerekmeyen dosya siliniyor ...",
|
||||
"DESCENDING": "Alçalan",
|
||||
"DIRECTION": "Yön",
|
||||
"DIRECTORY_SETTINGS": "Dizin Ayarları",
|
||||
"DIRECTORY_SETTINGS_BTN": "Dizin ayarları ...",
|
||||
"DISABLE_AUTOUPDATE_ESHOP": "Önyükleme sırasında otomatik güncelleme e-Mağazasını devre dışı bırak",
|
||||
"DISABLE_UPDATE_CHECK": "Otomatik güncellemeyi devre dışı bırak",
|
||||
"DONE": "Bitti!",
|
||||
"DOWNLOAD_ERROR": "Karşıdan Yükleme Hatası!",
|
||||
"DOWNLOAD_FAILED": "Karşıdan Yükleme Başarısız Oldu!",
|
||||
"DOWNLOADING_ESHOP": "EShop karşıdan yükleniyor ...",
|
||||
"DOWNLOADING_ESHOP_DB": "EShop karşıdan yükleniyor ...",
|
||||
"DOWNLOADING_GHOST_ESHOP": "DarkStore indiriyor ...",
|
||||
"DOWNLOADING_COMPATIBLE_FONT": "Uyumlu yazı tipi karşıdan yükleniyor ...",
|
||||
"DOWNLOADING_SPRITE_SHEET": "Spritesheet 'i indiriyor ...",
|
||||
"DOWNLOADING_SPRITE_SHEET2": "%i/ %i Spriesheet 'in yüklenmesi ...",
|
||||
"ESHOP_BG": "eShop BG kullan",
|
||||
"ESHOP_BG_DESC": "Etkinleştirildiğinde, en üst ekran için kesiksiz BG rengi yerine, eShop tarafından sağlanan BG gösterilir.",
|
||||
"ESHOP_INVALID_ERROR": "Bu eShop geçersiz ve DarkStore ile birlikte\nyüklü olamaz.\nSözdizimi hataları olup olmadığını kontrol edin.",
|
||||
"ESHOP_TOO_NEW": "DarkStore versiyonunuz bu tamirciyi kullanmak için\nçok eski.\nLütfen en son sürüme güncelleyin.",
|
||||
"ESHOP_TOO_OLD": "Bu eshop modası geçmiş ve DarkStore 'ın bu versiyonuyla birlikte\nkullanılamaz.\nLütfen yaratıcıya bunu güncelleştirmesini isteyin.",
|
||||
"ENABLE_AUTOUPDATE_ESHOP": "Önyükde otomatik güncelleme eShop 'ı etkinleştir",
|
||||
"ENABLE_UPDATE_CHECK": "Otomatik güncellemeyi etkinleştir",
|
||||
"ENTER_DESC_SHORTCUT": "Kısayol açıklamasını girin.",
|
||||
"ENTER_SEARCH": "Arama yapmak istediğiniz bilgileri girin.",
|
||||
"ENTER_SHORTCUT_FILENAME": "Kısayol dosya adını girin (uzantı olmadan).",
|
||||
"ENTER_TITLE_SHORTCUT": "Kısayol başlığını girin.",
|
||||
"ENTER_URL": "EShop olanağının URL adresini girin.",
|
||||
"ENTRIES": "Girdiler",
|
||||
"EXECUTE_ENTRY": "Bu girdiyi yürütmek istiyor musunuz?",
|
||||
"EXIT_APP": "DarkStore 'tan çık",
|
||||
"FETCHING_METADATA": "Eski meta veriler getiriliyor ...",
|
||||
"FETCHING_RECOMMENDED_ESHOP": "Fetching recommended eShop...",
|
||||
"FILE_EXTRACTED": "dosya çıkarıldı.",
|
||||
"FILES_HOSTING_ANONYKU": "Dosyaların Barındırılması Için Anonyku",
|
||||
"FILE_SLASH": "Bir ' /' gibi görünüyor, bu desteklenmez.\nLütfen 'file' dosyasını yalnızca dosya adı olarak değiştirin.",
|
||||
"FILES_EXTRACTED": "dosya çıkarıldı.",
|
||||
"FILTER_TO": "Süzgeç uygula:",
|
||||
"GRID": "Kılavuz",
|
||||
"GUI_SETTINGS": "GUI Ayarları",
|
||||
"GUI_SETTINGS_BTN": "GUI ayarları ...",
|
||||
"INCLUDE_IN_RESULTS": "Sonuçlara ekle:",
|
||||
"INSTALL_GHOST_ESHOP": "DarkStore kuruluyor ...",
|
||||
"INVALID_ESHOP": "Geçersiz eShop",
|
||||
"KEY_CONTINUE": "Devam etmek için herhangi bir tuşa basın.",
|
||||
"LANGUAGE": "Dil",
|
||||
"LAST_UPDATED": "Son güncelleme",
|
||||
"LIST": "Liste",
|
||||
"LOADING_SPRITESHEET": "Loading Spritesheet %i of %i...",
|
||||
"MEDIATYPE_NAND": "MediaType NAND",
|
||||
"MEDIATYPE_SD": "MediaType SD",
|
||||
"MOVE_ERROR": "Taşıma Hatası!",
|
||||
"NO": "Hayır",
|
||||
"NO_ADDITIONAL_CONTENT_AVAILABLE": "Kullanılabilecek Ek İçerik Yok",
|
||||
"NO_DOWNLOADS_AVAILABLE": "Kullanılabilir karşıdan yükleme yok",
|
||||
"NO_SIZE": "Boyut Yok",
|
||||
"NO_SCREENSHOTS_AVAILABLE": "No Screenshots available",
|
||||
"NOT_IMPLEMENTED": "Henüz Gerçekleştirilmedi",
|
||||
"RECOMMENDED_ESHOP": "Recommended eShop",
|
||||
"REVISION": "Düzeltme",
|
||||
"SCREENSHOT": "Screenshot %d / %d",
|
||||
"SCREENSHOT_COULD_NOT_LOAD": "Screenshot could not be loaded.",
|
||||
"SCREENSHOT_INSTRUCTIONS": "Press to change and to zoom",
|
||||
"SEARCH_FILTERS": "Arama ve Süzgeçler",
|
||||
"SELECT_ESHOP": "EShop seçeneğini belirleyin",
|
||||
"SELECT_ESHOP_2": "Bir e-Mağaza seçin",
|
||||
"SELECT_DIR": "Bir dizin seçin",
|
||||
"SELECT_LANG": "Dili seçin",
|
||||
"SETTINGS": "Ayarlar",
|
||||
"SHEET_SLASH": "Bir ' /' gibi görünüyor, bu desteklenmez.\nLütfen 'sheet' seçeneğini yalnızca dosya adı olarak değiştirin.",
|
||||
"SHORTCUT_CREATED": "Kısayol yaratıldı!",
|
||||
"SIZE": "Boyut",
|
||||
"SORT_BY": "Sıralama Temeli",
|
||||
"SORTING": "Sıralanıyor",
|
||||
"START_SELECT": "Yürürlükteki klasörü seçmek için START tuşuna basın",
|
||||
"STORE_INFO": "Store Info",
|
||||
"SYNTAX_ERROR": "Sözdizimi Hatası!",
|
||||
"TITLE": "Unvan",
|
||||
"TOP_STYLE": "Üst Stil",
|
||||
"UNSUPPORTED_ESHOP_VERSION": "Bu eShop sürümü desteklenmiyor.",
|
||||
"UPDATE_AVAILABLE": "Güncelleştirme Kullanılabilir!",
|
||||
"UPDATE_DONE": "Güncelleme bitti! Lütfen DarkStore 'ı yeniden açın.",
|
||||
"UPDATE_NOT_AVAILABLE": "Kullanılabilir Güncelleme Yok!",
|
||||
"UPDATING_ESHOP": "eShop güncelleniyor ...",
|
||||
"UPDATING_SPRITE_SHEET": "Spritesheet güncelleniyor ...",
|
||||
"UPDATING_SPRITE_SHEET2": "%i arası Spritesheet %i güncelleştiriliyor ...",
|
||||
"VERSION": "Sürüm",
|
||||
"WEBSITE": "Tam Krediler & Changelog Ghosteshop.com üzerinde Bulunabilir",
|
||||
"YES": "Evet"
|
||||
}
|
||||
@@ -1,124 +0,0 @@
|
||||
{
|
||||
"ARGUMENT_INVALID": "Неприпустимий аргументи.\nБудь ласка, перевірте файл xml для правильних аргументів.",
|
||||
"ASCENDING": "За зростанням",
|
||||
"AUTHOR": "Автор",
|
||||
"AUTO_UPDATE_ESHOP": "Автооновлення eМагазину",
|
||||
"AUTO_UPDATE_ESHOP_DESC": "При цьому, останній використаний магазин буде оновлено автоматично при запуску Ghost магазин.",
|
||||
"AUTO_UPDATE_DS": "Автоматичне оновлення eМагазину Ghost",
|
||||
"AUTO_UPDATE_DS_DESC": "Коли увімкнено, DarkStore буде перевіряти оновлення щоразу при його відкритті.",
|
||||
"AUTO_UPDATE_SETTINGS": "Параметри автоматичного оновлення",
|
||||
"AUTO_UPDATE_SETTINGS_BTN": "Налаштування автооновлення...",
|
||||
"AVAILABLE_DOWNLOADS": "Доступні завантаження",
|
||||
"BOOT_TITLE": "Ви бажаєте запустити цю назву?",
|
||||
"CATEGORY": "Категорія",
|
||||
"CHANGE_3DSX_PATH": "Зміна траєкторії 3DSX",
|
||||
"CHANGE_ARCHIVE_PATH": "Змінити шлях до архіву",
|
||||
"CHANGE_NDS_PATH": "Змінити шлях до NDS",
|
||||
"CHANGE_SHORTCUT_PATH": "Змінити шлях до ярлика",
|
||||
"CHANGELOG": "Список змін",
|
||||
"CHECK_ESHOP_UPDATES": "Перевірка оновлень eМагазину...",
|
||||
"CHECK_DS_UPDATES": "Перевірка оновлень Ghost eМагазину...",
|
||||
"CITRA_BIGN_ICON": "Citra і Nintendo для ікони",
|
||||
"CONFIRM_OR_CANCEL": "Натисніть <unk> для підтвердження, <unk> для скасування.",
|
||||
"CONNECT_WIFI": "Будь ласка, підключіться до Wi-Fi.",
|
||||
"CONSOLE": "Консоль",
|
||||
"CONTRIBUTOR_TRANSLATORS": "- Всі перекладачі та учасники",
|
||||
"COPY_ERROR": "Помилка копіювання!",
|
||||
"CREATE_SHORTCUT": "Створити ярлик?",
|
||||
"CREDITS": "Автори",
|
||||
"CURRENT_VERSION": "Поточна версія: ",
|
||||
"CURRENTLY_EXTRACTING": "Наразі розархівування:\n",
|
||||
"CUSTOM_FONT": "Користувацький шрифт",
|
||||
"CUSTOM_FONT_DESC": "Якщо увімкнуто, буде використано «sdmc:/3ds/DarkStore/font.bcfnt», замість системного шрифту.",
|
||||
"DELETE_ERROR": "Видалити помилку!",
|
||||
"DELETE_PROMPT": "Ви дійсно бажаєте видалити цю теку?",
|
||||
"DELETE_UNNEEDED_FILE": "Видалення непотрібного файлу...",
|
||||
"DESCENDING": "За спаданням",
|
||||
"DIRECTION": "Напрямок",
|
||||
"DIRECTORY_SETTINGS": "Налаштування каталогів",
|
||||
"DIRECTORY_SETTINGS_BTN": "Налаштування каталогу...",
|
||||
"DISABLE_AUTOUPDATE_ESHOP": "Вимкнути автоматичне оновлення eМагазину при завантаженні",
|
||||
"DISABLE_UPDATE_CHECK": "Вимкнути самооновлення",
|
||||
"DONE": "Виконано!",
|
||||
"DOWNLOAD_ERROR": "Помилка завантаження!",
|
||||
"DOWNLOAD_FAILED": "Помилка завантаження!",
|
||||
"DOWNLOADING_ESHOP": "Завантаження eShop...",
|
||||
"DOWNLOADING_ESHOP_DB": "Завантаження eShop...",
|
||||
"DOWNLOADING_GHOST_ESHOP": "Завантаження DarkStore...",
|
||||
"DOWNLOADING_COMPATIBLE_FONT": "Завантаження сумісного шрифту...",
|
||||
"DOWNLOADING_SPRITE_SHEET": "Завантаження Spritesheet...",
|
||||
"DOWNLOADING_SPRITE_SHEET2": "Завантаження Spritesheet %i з %i...",
|
||||
"ESHOP_BG": "Використовувати BG для eShop",
|
||||
"ESHOP_BG_DESC": "Якщо увімкнуто, eShop's буде показано замість суцільного кольору BG вікна у верхній частині магазину.",
|
||||
"ESHOP_INVALID_ERROR": "Даний eМагазин некоректний і не може бути\nзавантажений DarkStore.\nМоже перевірити, чи є якісь синтаксичні помилки?",
|
||||
"ESHOP_TOO_NEW": "Ваша версія Ghost eМагазину\nзанадто стара для використання цього eShop.\nБудь ласка, оновіться до останньої версії.",
|
||||
"ESHOP_TOO_OLD": "Цей eМагазин застарілий і не може використовуватися\nз цією версією ehost eShop.\nБудь ласка, попросіть творця оновити його.",
|
||||
"ENABLE_AUTOUPDATE_ESHOP": "Увімкнути автоматичне оновлення eМагазину при завантаженні",
|
||||
"ENABLE_UPDATE_CHECK": "Дозволити автооновлення",
|
||||
"ENTER_DESC_SHORTCUT": "Введіть опис гарячих клавіш.",
|
||||
"ENTER_SEARCH": "Введіть те, що вам подобається шукати.",
|
||||
"ENTER_SHORTCUT_FILENAME": "Введіть ім'я файлу ярлика (без розширення).",
|
||||
"ENTER_TITLE_SHORTCUT": "Введіть назву ярлика.",
|
||||
"ENTER_URL": "Введіть URL-адресу eShop.",
|
||||
"ENTRIES": "Записів",
|
||||
"EXECUTE_ENTRY": "Ви хотіли б виконати цей запис?",
|
||||
"EXIT_APP": "Вийти з DarkStore",
|
||||
"FETCHING_METADATA": "Отримання старих метаданих...",
|
||||
"FETCHING_RECOMMENDED_ESHOP": "Fetching recommended eShop...",
|
||||
"FILE_EXTRACTED": "файл вилучено.",
|
||||
"FILES_HOSTING_ANONYKU": "Аноніку для файлів хостингу",
|
||||
"FILE_SLASH": "Схоже що '/' включено, яка не підтримується.\nБудь ласка, змініть 'файл' лише на ім'я файлу.",
|
||||
"FILES_EXTRACTED": "файлів вилучено.",
|
||||
"FILTER_TO": "Фільтрувати до:",
|
||||
"GRID": "Сітка",
|
||||
"GUI_SETTINGS": "Налаштування інтерфейсу",
|
||||
"GUI_SETTINGS_BTN": "Налаштування інтерфейсу...",
|
||||
"INCLUDE_IN_RESULTS": "Включно з результатами:",
|
||||
"INSTALL_GHOST_ESHOP": "Встановлення DarkStore...",
|
||||
"INVALID_ESHOP": "Неправильний eМагазин",
|
||||
"KEY_CONTINUE": "Натисніть на будь-яку клавішу, щоб продовжити.",
|
||||
"LANGUAGE": "Мова:",
|
||||
"LAST_UPDATED": "Востаннє оновлено",
|
||||
"LIST": "Список",
|
||||
"LOADING_SPRITESHEET": "Завантаження Spritesheet %i з %i...",
|
||||
"MEDIATYPE_NAND": "NAND Медіатипу",
|
||||
"MEDIATYPE_SD": "Медіатип SD",
|
||||
"MOVE_ERROR": "Помилка переміщення!",
|
||||
"NO": "Ні",
|
||||
"NO_ADDITIONAL_CONTENT_AVAILABLE": "Немає доступного додаткового вмісту",
|
||||
"NO_DOWNLOADS_AVAILABLE": "Немає доступних завантажень",
|
||||
"NO_SIZE": "No Size",
|
||||
"NO_SCREENSHOTS_AVAILABLE": "No Screenshots available",
|
||||
"NOT_IMPLEMENTED": "Ще не реалізовано",
|
||||
"RECOMMENDED_ESHOP": "Recommended eShop",
|
||||
"REVISION": "Редакція",
|
||||
"SCREENSHOT": "Screenshot %d / %d",
|
||||
"SCREENSHOT_COULD_NOT_LOAD": "Screenshot could not be loaded.",
|
||||
"SCREENSHOT_INSTRUCTIONS": "Press to change and to zoom",
|
||||
"SEARCH_FILTERS": "Пошук і фільтри",
|
||||
"SELECT_ESHOP": "Виберіть магазин",
|
||||
"SELECT_ESHOP_2": "Виберіть магазин",
|
||||
"SELECT_DIR": "Виберіть теку",
|
||||
"SELECT_LANG": "Виберіть мову",
|
||||
"SETTINGS": "Налаштування",
|
||||
"SHEET_SLASH": "Схоже що '/' включено, яка не підтримується.\nБудь ласка, змініть 'листа' на ім'я файлу.",
|
||||
"SHORTCUT_CREATED": "Ярлик створено!",
|
||||
"SIZE": "Розмір",
|
||||
"SORT_BY": "Сортувати за",
|
||||
"SORTING": "Сортування",
|
||||
"START_SELECT": "Натисніть СТАРТ для вибору поточної теки",
|
||||
"STORE_INFO": "Store Info",
|
||||
"SYNTAX_ERROR": "Синтаксична помилка!",
|
||||
"TITLE": "Найменування",
|
||||
"TOP_STYLE": "Верхній стиль",
|
||||
"UNSUPPORTED_ESHOP_VERSION": "Версія цього магазину не підтримується.",
|
||||
"UPDATE_AVAILABLE": "Оновлення доступне!",
|
||||
"UPDATE_DONE": "Оновлення завершено! Будь ласка, повторно відкрийте DarkStore.",
|
||||
"UPDATE_NOT_AVAILABLE": "Немає доступних оновлень!",
|
||||
"UPDATING_ESHOP": "Оновлення eShop...",
|
||||
"UPDATING_SPRITE_SHEET": "Оновлення Spritesheet...",
|
||||
"UPDATING_SPRITE_SHEET2": "Оновлення Spritesheet %i з %i...",
|
||||
"VERSION": "Версія",
|
||||
"WEBSITE": "Повні кредити та журнал змін можна знайти на Ghosteshop.com",
|
||||
"YES": "Так"
|
||||
}
|
||||
+105
-105
@@ -1,106 +1,106 @@
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#include "common.hpp"
|
||||
#include "gfx.hpp"
|
||||
|
||||
/*
|
||||
Déssinez la base de l'écran supèrieur.
|
||||
*/
|
||||
void GFX::DrawTop(void) {
|
||||
Gui::ScreenDraw(Top);
|
||||
Gui::Draw_Rect(0, 0, 400, 25, BAR_COLOR);
|
||||
Gui::Draw_Rect(0, 26, 400, 214, BG_COLOR);
|
||||
Gui::Draw_Rect(0, 25, 400, 1, BAR_OUTL_COLOR);
|
||||
}
|
||||
|
||||
/*
|
||||
Déssinez la base de l'écran infèrieur.
|
||||
*/
|
||||
void GFX::DrawBottom() {
|
||||
Gui::ScreenDraw(Bottom);
|
||||
Gui::Draw_Rect(0, 0, 320, 240, BG_COLOR);
|
||||
}
|
||||
|
||||
/*
|
||||
Dessinez la boîte.
|
||||
|
||||
float xPos: La position X où dessiner la boîte.
|
||||
float yPos: La position Y où dessiner la boîte.
|
||||
float width: La largeur du bouton.
|
||||
float height: La hauteur du bouton.
|
||||
bool selected: Si sélectionné ou non.
|
||||
uint32_t clr: (Facultatif) La couleur de l’intérieur de la boîte.
|
||||
*/
|
||||
void GFX::DrawBox(float xPos, float yPos, float width, float height, bool selected, uint32_t clr) {
|
||||
Gui::Draw_Rect(xPos, yPos, width, height, BOX_INSIDE_COLOR); // Dessinez le BG du milieu.
|
||||
|
||||
if (selected) {
|
||||
static constexpr int depth = 2;
|
||||
|
||||
Gui::Draw_Rect(xPos - depth, yPos - depth, width + depth * 2, depth, BOX_SELECTED_COLOR); // Haut.
|
||||
Gui::Draw_Rect(xPos - depth, yPos - depth, depth, height + depth * 2, BOX_SELECTED_COLOR); // Gauche.
|
||||
Gui::Draw_Rect(xPos + width, yPos - depth, depth, height + depth * 2, BOX_SELECTED_COLOR); // Droite.
|
||||
Gui::Draw_Rect(xPos - depth, yPos + height, width + depth * 2, depth, BOX_SELECTED_COLOR); // Bas.
|
||||
}
|
||||
}
|
||||
|
||||
extern C2D_SpriteSheet sprites;
|
||||
|
||||
/*
|
||||
Dessinez un Sprite des sprites SpriteSheet.
|
||||
|
||||
int img: L'index d'image.
|
||||
int x: la position X où dessiner.
|
||||
int y: la position Y où dessiner.
|
||||
float ScaleX: (Facultatif) L'échelle X du Sprite. (1 par défaut)
|
||||
float ScaleY: (Facultatif) L'échelle Y du Sprite. (1 par défaut)
|
||||
*/
|
||||
void GFX::DrawSprite(int img, int x, int y, float ScaleX, float ScaleY) {
|
||||
Gui::DrawSprite(sprites, img, x, y, ScaleX, ScaleY);
|
||||
}
|
||||
|
||||
/*
|
||||
Dessinez la case à cocher.
|
||||
|
||||
float xPos: La position X où dessiner la boîte.
|
||||
float yPos: La position Y où dessiner la boîte.
|
||||
booléen sélectionné: si coché ou non.
|
||||
*/
|
||||
void GFX::DrawCheckbox(float xPos, float yPos, bool selected) {
|
||||
GFX::DrawSprite((selected ? sprites_checked_idx : sprites_unchecked_idx), xPos, yPos);
|
||||
}
|
||||
|
||||
/*
|
||||
Dessinez la boîte à bascule.
|
||||
|
||||
float xPos: La position X où dessiner la bascule.
|
||||
float yPos: La position Y où dessiner la bascule.
|
||||
bool toggled: Si basculé ou non.
|
||||
*/
|
||||
void GFX::DrawToggle(float xPos, float yPos, bool toggled) {
|
||||
GFX::DrawSprite((toggled ? sprites_toggle_on_idx : sprites_toggle_off_idx), xPos, yPos);
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#include "common.hpp"
|
||||
#include "gfx.hpp"
|
||||
|
||||
/*
|
||||
Déssinez la base de l'écran supèrieur.
|
||||
*/
|
||||
void GFX::DrawTop(void) {
|
||||
Gui::ScreenDraw(Top);
|
||||
Gui::Draw_Rect(0, 0, 400, 25, BAR_COLOR);
|
||||
Gui::Draw_Rect(0, 26, 400, 214, BG_COLOR);
|
||||
Gui::Draw_Rect(0, 25, 400, 1, BAR_OUTL_COLOR);
|
||||
}
|
||||
|
||||
/*
|
||||
Déssinez la base de l'écran infèrieur.
|
||||
*/
|
||||
void GFX::DrawBottom() {
|
||||
Gui::ScreenDraw(Bottom);
|
||||
Gui::Draw_Rect(0, 0, 320, 240, BG_COLOR);
|
||||
}
|
||||
|
||||
/*
|
||||
Dessinez la boîte.
|
||||
|
||||
float xPos: La position X où dessiner la boîte.
|
||||
float yPos: La position Y où dessiner la boîte.
|
||||
float width: La largeur du bouton.
|
||||
float height: La hauteur du bouton.
|
||||
bool selected: Si sélectionné ou non.
|
||||
uint32_t clr: (Facultatif) La couleur de l’intérieur de la boîte.
|
||||
*/
|
||||
void GFX::DrawBox(float xPos, float yPos, float width, float height, bool selected, uint32_t clr) {
|
||||
Gui::Draw_Rect(xPos, yPos, width, height, BOX_INSIDE_COLOR); // Dessinez le BG du milieu.
|
||||
|
||||
if (selected) {
|
||||
static constexpr int depth = 2;
|
||||
|
||||
Gui::Draw_Rect(xPos - depth, yPos - depth, width + depth * 2, depth, BOX_SELECTED_COLOR); // Haut.
|
||||
Gui::Draw_Rect(xPos - depth, yPos - depth, depth, height + depth * 2, BOX_SELECTED_COLOR); // Gauche.
|
||||
Gui::Draw_Rect(xPos + width, yPos - depth, depth, height + depth * 2, BOX_SELECTED_COLOR); // Droite.
|
||||
Gui::Draw_Rect(xPos - depth, yPos + height, width + depth * 2, depth, BOX_SELECTED_COLOR); // Bas.
|
||||
}
|
||||
}
|
||||
|
||||
extern C2D_SpriteSheet sprites;
|
||||
|
||||
/*
|
||||
Dessinez un Sprite des sprites SpriteSheet.
|
||||
|
||||
int img: L'index d'image.
|
||||
int x: la position X où dessiner.
|
||||
int y: la position Y où dessiner.
|
||||
float ScaleX: (Facultatif) L'échelle X du Sprite. (1 par défaut)
|
||||
float ScaleY: (Facultatif) L'échelle Y du Sprite. (1 par défaut)
|
||||
*/
|
||||
void GFX::DrawSprite(int img, int x, int y, float ScaleX, float ScaleY) {
|
||||
Gui::DrawSprite(sprites, img, x, y, ScaleX, ScaleY);
|
||||
}
|
||||
|
||||
/*
|
||||
Dessinez la case à cocher.
|
||||
|
||||
float xPos: La position X où dessiner la boîte.
|
||||
float yPos: La position Y où dessiner la boîte.
|
||||
booléen sélectionné: si coché ou non.
|
||||
*/
|
||||
void GFX::DrawCheckbox(float xPos, float yPos, bool selected) {
|
||||
GFX::DrawSprite((selected ? sprites_checked_idx : sprites_unchecked_idx), xPos, yPos);
|
||||
}
|
||||
|
||||
/*
|
||||
Dessinez la boîte à bascule.
|
||||
|
||||
float xPos: La position X où dessiner la bascule.
|
||||
float yPos: La position Y où dessiner la bascule.
|
||||
bool toggled: Si basculé ou non.
|
||||
*/
|
||||
void GFX::DrawToggle(float xPos, float yPos, bool toggled) {
|
||||
GFX::DrawSprite((toggled ? sprites_toggle_on_idx : sprites_toggle_off_idx), xPos, yPos);
|
||||
}
|
||||
+122
-122
@@ -1,123 +1,123 @@
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#include "common.hpp"
|
||||
#include "msg.hpp"
|
||||
|
||||
/*
|
||||
Affiche juste un message jusqu’au prochain cadre de dessin.
|
||||
const std::string &Text : Le message, qui doit être affiché.
|
||||
*/
|
||||
void Msg::DisplayMsg(const std::string &Text) {
|
||||
Gui::clearTextBufs();
|
||||
C3D_FrameBegin(C3D_FRAME_SYNCDRAW);
|
||||
C2D_TargetClear(Top, TRANSPARENT);
|
||||
C2D_TargetClear(Bottom, TRANSPARENT);
|
||||
|
||||
GFX::DrawTop();
|
||||
Gui::DrawStringCentered(0, (240 - Gui::GetStringHeight(0.6f, Text)) / 2, 0.6f, TEXT_COLOR, Text, 395, 0, font);
|
||||
GFX::DrawBottom();
|
||||
C3D_FrameEnd(0);
|
||||
}
|
||||
|
||||
/*
|
||||
Affiche un message d’avertissement pendant 3 secondes.
|
||||
const std::string &Text : Le message, qui doit être affiché.
|
||||
*/
|
||||
void Msg::DisplayWarnMsg(const std::string &Text) {
|
||||
Gui::clearTextBufs();
|
||||
C3D_FrameBegin(C3D_FRAME_SYNCDRAW);
|
||||
C2D_TargetClear(Top, TRANSPARENT);
|
||||
C2D_TargetClear(Bottom, TRANSPARENT);
|
||||
|
||||
GFX::DrawTop();
|
||||
Gui::DrawStringCentered(0, 1, 0.6f, TEXT_COLOR, Text, 390, 0, font);
|
||||
|
||||
GFX::DrawBottom();
|
||||
C3D_FrameEnd(0);
|
||||
|
||||
for (int i = 0; i < 60 * 3; i++) {
|
||||
gspWaitForVBlank();
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
Afficher un message qui doit être confirmé par A/B.
|
||||
const std::string &promptMsg : Le message, qui doit être affiché.
|
||||
*/
|
||||
bool Msg::promptMsg(const std::string &promptMsg) {
|
||||
Gui::clearTextBufs();
|
||||
C3D_FrameBegin(C3D_FRAME_SYNCDRAW);
|
||||
C2D_TargetClear(Top, TRANSPARENT);
|
||||
C2D_TargetClear(Bottom, TRANSPARENT);
|
||||
|
||||
GFX::DrawTop();
|
||||
Gui::Draw_Rect(0, 215, 400, 25, BAR_COLOR);
|
||||
Gui::Draw_Rect(0, 214, 400, 1, BAR_OUTL_COLOR);
|
||||
Gui::DrawStringCentered(0, (240 - Gui::GetStringHeight(0.6f, promptMsg)) / 2, 0.6f, TEXT_COLOR, promptMsg, 395, 0, font);
|
||||
|
||||
Gui::DrawStringCentered(0, 218, 0.6f, TEXT_COLOR, Lang::get("CONFIRM_OR_CANCEL"), 390, 0, font);
|
||||
GFX::DrawBottom();
|
||||
C3D_FrameEnd(0);
|
||||
|
||||
for (int i = 0; i < 3; i++) gspWaitForVBlank();
|
||||
hidScanInput();
|
||||
|
||||
while(1) {
|
||||
hidScanInput();
|
||||
if (hidKeysDown() & KEY_A) return true;
|
||||
else if (hidKeysDown() & KEY_B) return false;
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
Afficher un message, qui peut être "confirmé" avec n’importe quelle clé.
|
||||
const std::string &msg : Le message qui doit être affiché.
|
||||
*/
|
||||
void Msg::waitMsg(const std::string &msg) {
|
||||
bool doOut = false;
|
||||
|
||||
Gui::clearTextBufs();
|
||||
C3D_FrameBegin(C3D_FRAME_SYNCDRAW);
|
||||
C2D_TargetClear(Top, TRANSPARENT);
|
||||
C2D_TargetClear(Bottom, TRANSPARENT);
|
||||
|
||||
GFX::DrawTop();
|
||||
Gui::DrawStringCentered(0, (240 - Gui::GetStringHeight(0.6f, msg)) / 2, 0.6f, TEXT_COLOR, msg, 395, 0, font);
|
||||
Gui::Draw_Rect(0, 215, 400, 25, BAR_COLOR);
|
||||
Gui::Draw_Rect(0, 214, 400, 1, BAR_OUTL_COLOR);
|
||||
Gui::DrawStringCentered(0, 218, 0.6f, TEXT_COLOR, Lang::get("KEY_CONTINUE"), 390, 0, font);
|
||||
GFX::DrawBottom();
|
||||
C3D_FrameEnd(0);
|
||||
|
||||
for (int i = 0; i < 3; i++) gspWaitForVBlank();
|
||||
hidScanInput();
|
||||
|
||||
while(!doOut) {
|
||||
hidScanInput();
|
||||
if (hidKeysDown()) doOut = !doOut;
|
||||
}
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#include "common.hpp"
|
||||
#include "msg.hpp"
|
||||
|
||||
/*
|
||||
Affiche juste un message jusqu’au prochain cadre de dessin.
|
||||
const std::string &Text : Le message, qui doit être affiché.
|
||||
*/
|
||||
void Msg::DisplayMsg(const std::string &Text) {
|
||||
Gui::clearTextBufs();
|
||||
C3D_FrameBegin(C3D_FRAME_SYNCDRAW);
|
||||
C2D_TargetClear(Top, TRANSPARENT);
|
||||
C2D_TargetClear(Bottom, TRANSPARENT);
|
||||
|
||||
GFX::DrawTop();
|
||||
Gui::DrawStringCentered(0, (240 - Gui::GetStringHeight(0.6f, Text)) / 2, 0.6f, TEXT_COLOR, Text, 395, 0, font);
|
||||
GFX::DrawBottom();
|
||||
C3D_FrameEnd(0);
|
||||
}
|
||||
|
||||
/*
|
||||
Affiche un message d’avertissement pendant 3 secondes.
|
||||
const std::string &Text : Le message, qui doit être affiché.
|
||||
*/
|
||||
void Msg::DisplayWarnMsg(const std::string &Text) {
|
||||
Gui::clearTextBufs();
|
||||
C3D_FrameBegin(C3D_FRAME_SYNCDRAW);
|
||||
C2D_TargetClear(Top, TRANSPARENT);
|
||||
C2D_TargetClear(Bottom, TRANSPARENT);
|
||||
|
||||
GFX::DrawTop();
|
||||
Gui::DrawStringCentered(0, 1, 0.6f, TEXT_COLOR, Text, 390, 0, font);
|
||||
|
||||
GFX::DrawBottom();
|
||||
C3D_FrameEnd(0);
|
||||
|
||||
for (int i = 0; i < 60 * 3; i++) {
|
||||
gspWaitForVBlank();
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
Afficher un message qui doit être confirmé par A/B.
|
||||
const std::string &promptMsg : Le message, qui doit être affiché.
|
||||
*/
|
||||
bool Msg::promptMsg(const std::string &promptMsg) {
|
||||
Gui::clearTextBufs();
|
||||
C3D_FrameBegin(C3D_FRAME_SYNCDRAW);
|
||||
C2D_TargetClear(Top, TRANSPARENT);
|
||||
C2D_TargetClear(Bottom, TRANSPARENT);
|
||||
|
||||
GFX::DrawTop();
|
||||
Gui::Draw_Rect(0, 215, 400, 25, BAR_COLOR);
|
||||
Gui::Draw_Rect(0, 214, 400, 1, BAR_OUTL_COLOR);
|
||||
Gui::DrawStringCentered(0, (240 - Gui::GetStringHeight(0.6f, promptMsg)) / 2, 0.6f, TEXT_COLOR, promptMsg, 395, 0, font);
|
||||
|
||||
Gui::DrawStringCentered(0, 218, 0.6f, TEXT_COLOR, Lang::get("CONFIRM_OR_CANCEL"), 390, 0, font);
|
||||
GFX::DrawBottom();
|
||||
C3D_FrameEnd(0);
|
||||
|
||||
for (int i = 0; i < 3; i++) gspWaitForVBlank();
|
||||
hidScanInput();
|
||||
|
||||
while(1) {
|
||||
hidScanInput();
|
||||
if (hidKeysDown() & KEY_A) return true;
|
||||
else if (hidKeysDown() & KEY_B) return false;
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
Afficher un message, qui peut être "confirmé" avec n’importe quelle clé.
|
||||
const std::string &msg : Le message qui doit être affiché.
|
||||
*/
|
||||
void Msg::waitMsg(const std::string &msg) {
|
||||
bool doOut = false;
|
||||
|
||||
Gui::clearTextBufs();
|
||||
C3D_FrameBegin(C3D_FRAME_SYNCDRAW);
|
||||
C2D_TargetClear(Top, TRANSPARENT);
|
||||
C2D_TargetClear(Bottom, TRANSPARENT);
|
||||
|
||||
GFX::DrawTop();
|
||||
Gui::DrawStringCentered(0, (240 - Gui::GetStringHeight(0.6f, msg)) / 2, 0.6f, TEXT_COLOR, msg, 395, 0, font);
|
||||
Gui::Draw_Rect(0, 215, 400, 25, BAR_COLOR);
|
||||
Gui::Draw_Rect(0, 214, 400, 1, BAR_OUTL_COLOR);
|
||||
Gui::DrawStringCentered(0, 218, 0.6f, TEXT_COLOR, Lang::get("KEY_CONTINUE"), 390, 0, font);
|
||||
GFX::DrawBottom();
|
||||
C3D_FrameEnd(0);
|
||||
|
||||
for (int i = 0; i < 3; i++) gspWaitForVBlank();
|
||||
hidScanInput();
|
||||
|
||||
while(!doOut) {
|
||||
hidScanInput();
|
||||
if (hidKeysDown()) doOut = !doOut;
|
||||
}
|
||||
}
|
||||
+220
-220
@@ -1,220 +1,220 @@
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#include "common.hpp"
|
||||
#include "download.hpp"
|
||||
#include "init.hpp"
|
||||
#include "mainScreen.hpp"
|
||||
#include "queueSystem.hpp"
|
||||
#include "sound.hpp"
|
||||
|
||||
#include <dirent.h>
|
||||
#include <unistd.h>
|
||||
|
||||
bool exiting = false, is3DSX = false, needUnloadFont = false;
|
||||
C2D_SpriteSheet sprites;
|
||||
int fadeAlpha = 0;
|
||||
u32 old_time_limit;
|
||||
std::unique_ptr<Sound> Music = nullptr;
|
||||
bool dspfirmFound = false;
|
||||
|
||||
/*
|
||||
Set, si 3DSX ou CIA.
|
||||
*/
|
||||
static void getCurrentUsage(){
|
||||
u64 id;
|
||||
APT_GetProgramID(&id);
|
||||
is3DSX = (id != 0x0004000007392600);
|
||||
}
|
||||
|
||||
/*
|
||||
Init Music.
|
||||
*/
|
||||
static void InitMusic() {
|
||||
if (access("sdmc:/3ds/dspfirm.cdc", F_OK) == 0) { // Ensure dspfirm dump exist.
|
||||
if (access("romfs:/song/music.wav", F_OK) == 0) { // Ensure music.wav exist.
|
||||
dspfirmFound = true;
|
||||
ndspInit();
|
||||
Music = std::make_unique<Sound>("romfs:/song/music.wav");
|
||||
|
||||
Music->play();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
Exit Music.
|
||||
*/
|
||||
static void ExitMusic() {
|
||||
if (dspfirmFound) {
|
||||
Music->stop();
|
||||
Music = nullptr;
|
||||
ndspExit();
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
If button Position pressed -> Do something.
|
||||
|
||||
touchPosition touch: The TouchPosition variable.
|
||||
Structs::ButtonPos button: The Button Struct.
|
||||
*/
|
||||
bool touching(touchPosition touch, Structs::ButtonPos button) {
|
||||
if (touch.px >= button.x && touch.px <= (button.x + button.w) && touch.py >= button.y && touch.py <= (button.y + button.h)) return true;
|
||||
return false;
|
||||
}
|
||||
|
||||
/*
|
||||
Chargez la police personnalisée et utilisez-la à la place de SysFont, si elle est trouvée.
|
||||
*/
|
||||
void Init::LoadFont() {
|
||||
if (config->customfont()) {
|
||||
if (!needUnloadFont) {
|
||||
if (access("sdmc:/3ds/DarkStore/font.bcfnt", F_OK) == 0) {
|
||||
Gui::loadFont(font, "sdmc:/3ds/DarkStore/font.bcfnt");
|
||||
needUnloadFont = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
Déchargez la police personnalisée et revenez à SysFont.
|
||||
*/
|
||||
void Init::UnloadFont() {
|
||||
if (needUnloadFont) {
|
||||
Gui::unloadFont(font);
|
||||
font = nullptr;
|
||||
needUnloadFont = false;
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
Initialiser DarkStore.
|
||||
*/
|
||||
Result Init::Initialize() {
|
||||
gfxInitDefault();
|
||||
romfsInit();
|
||||
Gui::init();
|
||||
|
||||
cfguInit();
|
||||
amInit();
|
||||
acInit();
|
||||
|
||||
APT_GetAppCpuTimeLimit(&old_time_limit);
|
||||
APT_SetAppCpuTimeLimit(30); // Nécessaire pour que le scanner QR fonctionne.
|
||||
getCurrentUsage();
|
||||
aptSetSleepAllowed(false);
|
||||
hidSetRepeatParameters(20, 8);
|
||||
|
||||
/* Créer des répertoires, s’il manque. */
|
||||
mkdir("sdmc:/3ds", 0777);
|
||||
mkdir("sdmc:/3ds/DarkStore", 0777);
|
||||
mkdir("sdmc:/3ds/DarkStore/stores", 0777);
|
||||
mkdir("sdmc:/3ds/DarkStore/shortcuts", 0777);
|
||||
|
||||
config = std::make_unique<Config>();
|
||||
Lang::load(config->language());
|
||||
|
||||
Gui::loadSheet("romfs:/gfx/sprites.t3x", sprites);
|
||||
LoadFont();
|
||||
|
||||
osSetSpeedupEnable(true); // Activer l’accélération pour les utilisateurs de new3DS.
|
||||
|
||||
/* Check here for updates. */
|
||||
if (config->updatecheck()) UpdateAction();
|
||||
|
||||
if (exiting) return -1; // En cas de succès de la mise à jour.
|
||||
|
||||
Gui::setScreen(std::make_unique<MainScreen>(), false, false);
|
||||
InitMusic();
|
||||
|
||||
/* Initialize Queue System LightLock. */
|
||||
LightLock_Init(&QueueSystem::lock);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
/*
|
||||
MainLoop de DarkStore.
|
||||
*/
|
||||
Result Init::MainLoop() {
|
||||
bool fullExit = false;
|
||||
|
||||
if (Initialize() == -1) fullExit = true;
|
||||
|
||||
/* Boucle tant que le statut n’est pas fullExit. */
|
||||
while (aptMainLoop() && !fullExit) {
|
||||
hidScanInput();
|
||||
hHeld = hidKeysHeld();
|
||||
hDown = hidKeysDown();
|
||||
hRepeat = hidKeysDownRepeat();
|
||||
hidTouchRead(&touch);
|
||||
|
||||
Gui::clearTextBufs();
|
||||
C3D_FrameBegin(C3D_FRAME_SYNCDRAW);
|
||||
C2D_TargetClear(Top, C2D_Color32(0, 0, 0, 0));
|
||||
C2D_TargetClear(Bottom, C2D_Color32(0, 0, 0, 0));
|
||||
|
||||
Gui::DrawScreen(false);
|
||||
if (!exiting) Gui::ScreenLogic(hDown, hHeld, touch, true, false);
|
||||
C3D_FrameEnd(0);
|
||||
|
||||
if (exiting) {
|
||||
if (hDown & KEY_START) fullExit = true; // En option, plus vite.
|
||||
|
||||
if (fadeAlpha < 255) {
|
||||
fadeAlpha += 4;
|
||||
if (fadeAlpha >= 255) fullExit = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/* Quitter tous les services et quitter l’application. */
|
||||
Exit();
|
||||
return 0;
|
||||
}
|
||||
|
||||
/*
|
||||
Fermer DarkStore.
|
||||
*/
|
||||
Result Init::Exit() {
|
||||
Gui::exit();
|
||||
Gui::unloadSheet(sprites);
|
||||
UnloadFont();
|
||||
ExitMusic();
|
||||
gfxExit();
|
||||
cfguExit();
|
||||
config->save();
|
||||
acExit();
|
||||
amExit();
|
||||
|
||||
if (old_time_limit != UINT32_MAX) APT_SetAppCpuTimeLimit(old_time_limit); // Rétablir l’ancienne limite.
|
||||
aptSetSleepAllowed(true);
|
||||
|
||||
romfsExit();
|
||||
return 0;
|
||||
}
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#include "common.hpp"
|
||||
#include "download.hpp"
|
||||
#include "init.hpp"
|
||||
#include "mainScreen.hpp"
|
||||
#include "queueSystem.hpp"
|
||||
#include "sound.hpp"
|
||||
|
||||
#include <dirent.h>
|
||||
#include <unistd.h>
|
||||
|
||||
bool exiting = false, is3DSX = false, needUnloadFont = false;
|
||||
C2D_SpriteSheet sprites;
|
||||
int fadeAlpha = 0;
|
||||
u32 old_time_limit;
|
||||
std::unique_ptr<Sound> Music = nullptr;
|
||||
bool dspfirmFound = false;
|
||||
|
||||
/*
|
||||
Set, si 3DSX ou CIA.
|
||||
*/
|
||||
static void getCurrentUsage(){
|
||||
u64 id;
|
||||
APT_GetProgramID(&id);
|
||||
is3DSX = (id != 0x0004000007392600);
|
||||
}
|
||||
|
||||
/*
|
||||
Init Music.
|
||||
*/
|
||||
static void InitMusic() {
|
||||
if (access("sdmc:/3ds/dspfirm.cdc", F_OK) == 0) { // Ensure dspfirm dump exist.
|
||||
if (access("romfs:/song/music.wav", F_OK) == 0) { // Ensure music.wav exist.
|
||||
dspfirmFound = true;
|
||||
ndspInit();
|
||||
Music = std::make_unique<Sound>("romfs:/song/music.wav");
|
||||
|
||||
Music->play();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
Exit Music.
|
||||
*/
|
||||
static void ExitMusic() {
|
||||
if (dspfirmFound) {
|
||||
Music->stop();
|
||||
Music = nullptr;
|
||||
ndspExit();
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
If button Position pressed -> Do something.
|
||||
|
||||
touchPosition touch: The TouchPosition variable.
|
||||
Structs::ButtonPos button: The Button Struct.
|
||||
*/
|
||||
bool touching(touchPosition touch, Structs::ButtonPos button) {
|
||||
if (touch.px >= button.x && touch.px <= (button.x + button.w) && touch.py >= button.y && touch.py <= (button.y + button.h)) return true;
|
||||
return false;
|
||||
}
|
||||
|
||||
/*
|
||||
Chargez la police personnalisée et utilisez-la à la place de SysFont, si elle est trouvée.
|
||||
*/
|
||||
void Init::LoadFont() {
|
||||
if (config->customfont()) {
|
||||
if (!needUnloadFont) {
|
||||
if (access("sdmc:/3ds/DarkStore/font.bcfnt", F_OK) == 0) {
|
||||
Gui::loadFont(font, "sdmc:/3ds/DarkStore/font.bcfnt");
|
||||
needUnloadFont = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
Déchargez la police personnalisée et revenez à SysFont.
|
||||
*/
|
||||
void Init::UnloadFont() {
|
||||
if (needUnloadFont) {
|
||||
Gui::unloadFont(font);
|
||||
font = nullptr;
|
||||
needUnloadFont = false;
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
Initialiser DarkStore.
|
||||
*/
|
||||
Result Init::Initialize() {
|
||||
gfxInitDefault();
|
||||
romfsInit();
|
||||
Gui::init();
|
||||
|
||||
cfguInit();
|
||||
amInit();
|
||||
acInit();
|
||||
|
||||
APT_GetAppCpuTimeLimit(&old_time_limit);
|
||||
APT_SetAppCpuTimeLimit(30); // Nécessaire pour que le scanner QR fonctionne.
|
||||
getCurrentUsage();
|
||||
aptSetSleepAllowed(false);
|
||||
hidSetRepeatParameters(20, 8);
|
||||
|
||||
/* Créer des répertoires, s’il manque. */
|
||||
mkdir("sdmc:/3ds", 0777);
|
||||
mkdir("sdmc:/3ds/DarkStore", 0777);
|
||||
mkdir("sdmc:/3ds/DarkStore/stores", 0777);
|
||||
mkdir("sdmc:/3ds/DarkStore/shortcuts", 0777);
|
||||
|
||||
config = std::make_unique<Config>();
|
||||
Lang::load(config->language());
|
||||
|
||||
Gui::loadSheet("romfs:/gfx/sprites.t3x", sprites);
|
||||
LoadFont();
|
||||
|
||||
osSetSpeedupEnable(true); // Activer l’accélération pour les utilisateurs de new3DS.
|
||||
|
||||
/* Check here for updates. */
|
||||
if (config->updatecheck()) UpdateAction();
|
||||
|
||||
if (exiting) return -1; // En cas de succès de la mise à jour.
|
||||
|
||||
Gui::setScreen(std::make_unique<MainScreen>(), false, false);
|
||||
InitMusic();
|
||||
|
||||
/* Initialize Queue System LightLock. */
|
||||
LightLock_Init(&QueueSystem::lock);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
/*
|
||||
MainLoop de DarkStore.
|
||||
*/
|
||||
Result Init::MainLoop() {
|
||||
bool fullExit = false;
|
||||
|
||||
if (Initialize() == -1) fullExit = true;
|
||||
|
||||
/* Boucle tant que le statut n’est pas fullExit. */
|
||||
while (aptMainLoop() && !fullExit) {
|
||||
hidScanInput();
|
||||
hHeld = hidKeysHeld();
|
||||
hDown = hidKeysDown();
|
||||
hRepeat = hidKeysDownRepeat();
|
||||
hidTouchRead(&touch);
|
||||
|
||||
Gui::clearTextBufs();
|
||||
C3D_FrameBegin(C3D_FRAME_SYNCDRAW);
|
||||
C2D_TargetClear(Top, C2D_Color32(0, 0, 0, 0));
|
||||
C2D_TargetClear(Bottom, C2D_Color32(0, 0, 0, 0));
|
||||
|
||||
Gui::DrawScreen(false);
|
||||
if (!exiting) Gui::ScreenLogic(hDown, hHeld, touch, true, false);
|
||||
C3D_FrameEnd(0);
|
||||
|
||||
if (exiting) {
|
||||
if (hDown & KEY_START) fullExit = true; // En option, plus vite.
|
||||
|
||||
if (fadeAlpha < 255) {
|
||||
fadeAlpha += 4;
|
||||
if (fadeAlpha >= 255) fullExit = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/* Quitter tous les services et quitter l’application. */
|
||||
Exit();
|
||||
return 0;
|
||||
}
|
||||
|
||||
/*
|
||||
Fermer DarkStore.
|
||||
*/
|
||||
Result Init::Exit() {
|
||||
Gui::exit();
|
||||
Gui::unloadSheet(sprites);
|
||||
UnloadFont();
|
||||
ExitMusic();
|
||||
gfxExit();
|
||||
cfguExit();
|
||||
config->save();
|
||||
acExit();
|
||||
amExit();
|
||||
|
||||
if (old_time_limit != UINT32_MAX) APT_SetAppCpuTimeLimit(old_time_limit); // Rétablir l’ancienne limite.
|
||||
aptSetSleepAllowed(true);
|
||||
|
||||
romfsExit();
|
||||
return 0;
|
||||
}
|
||||
|
||||
+67
-67
@@ -1,68 +1,68 @@
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#include "gfx.hpp"
|
||||
#include "keyboard.hpp"
|
||||
#include "screenCommon.hpp"
|
||||
|
||||
static std::vector<SwkbdDictWord> words;
|
||||
|
||||
/*
|
||||
Retourne une chaîne du clavier.
|
||||
uint maxLongueur : La longueur maximale.
|
||||
const std::string &Text : Const Référence au texte.
|
||||
const std::vectorstd::unique_ptrStoreEntry>> &entries : Const Référence de toutes les entrées pour les mots à suggérer.
|
||||
*/
|
||||
std::string Input::setkbdString(uint maxLength, const std::string &Text, const std::vector<std::unique_ptr<StoreEntry>> &entries) {
|
||||
C3D_FrameEnd(0); // Nécessaire pour que le système ne gèle pas.
|
||||
|
||||
SwkbdState state;
|
||||
swkbdInit(&state, SWKBD_TYPE_NORMAL, 2, maxLength);
|
||||
char temp[maxLength + 1] = { 0 };
|
||||
swkbdSetHintText(&state, Text.c_str());
|
||||
swkbdSetValidation(&state, SWKBD_NOTBLANK_NOTEMPTY, SWKBD_FILTER_PROFANITY, 0);
|
||||
|
||||
if (entries.size()) {
|
||||
words.clear();
|
||||
words.resize(entries.size());
|
||||
|
||||
for (uint i = 0; i < entries.size(); i++) {
|
||||
/* Vérification pour non nullptr. */
|
||||
if (entries[i]) swkbdSetDictWord(&words[i], StringUtils::lower_case(entries[i]->GetTitle()).c_str(), entries[i]->GetTitle().c_str());
|
||||
else swkbdSetDictWord(&words[i], "", "");
|
||||
}
|
||||
|
||||
if (words.size() > 0) {
|
||||
swkbdSetDictionary(&state, words.data(), entries.size());
|
||||
swkbdSetFeatures(&state, SWKBD_PREDICTIVE_INPUT);
|
||||
}
|
||||
}
|
||||
|
||||
SwkbdButton ret = swkbdInputText(&state, temp, sizeof(temp));
|
||||
temp[maxLength] = '\0';
|
||||
|
||||
return (ret == SWKBD_BUTTON_CONFIRM ? temp : "");
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#include "gfx.hpp"
|
||||
#include "keyboard.hpp"
|
||||
#include "screenCommon.hpp"
|
||||
|
||||
static std::vector<SwkbdDictWord> words;
|
||||
|
||||
/*
|
||||
Retourne une chaîne du clavier.
|
||||
uint maxLongueur : La longueur maximale.
|
||||
const std::string &Text : Const Référence au texte.
|
||||
const std::vectorstd::unique_ptrStoreEntry>> &entries : Const Référence de toutes les entrées pour les mots à suggérer.
|
||||
*/
|
||||
std::string Input::setkbdString(uint maxLength, const std::string &Text, const std::vector<std::unique_ptr<StoreEntry>> &entries) {
|
||||
C3D_FrameEnd(0); // Nécessaire pour que le système ne gèle pas.
|
||||
|
||||
SwkbdState state;
|
||||
swkbdInit(&state, SWKBD_TYPE_NORMAL, 2, maxLength);
|
||||
char temp[maxLength + 1] = { 0 };
|
||||
swkbdSetHintText(&state, Text.c_str());
|
||||
swkbdSetValidation(&state, SWKBD_NOTBLANK_NOTEMPTY, SWKBD_FILTER_PROFANITY, 0);
|
||||
|
||||
if (entries.size()) {
|
||||
words.clear();
|
||||
words.resize(entries.size());
|
||||
|
||||
for (uint i = 0; i < entries.size(); i++) {
|
||||
/* Vérification pour non nullptr. */
|
||||
if (entries[i]) swkbdSetDictWord(&words[i], StringUtils::lower_case(entries[i]->GetTitle()).c_str(), entries[i]->GetTitle().c_str());
|
||||
else swkbdSetDictWord(&words[i], "", "");
|
||||
}
|
||||
|
||||
if (words.size() > 0) {
|
||||
swkbdSetDictionary(&state, words.data(), entries.size());
|
||||
swkbdSetFeatures(&state, SWKBD_PREDICTIVE_INPUT);
|
||||
}
|
||||
}
|
||||
|
||||
SwkbdButton ret = swkbdInputText(&state, temp, sizeof(temp));
|
||||
temp[maxLength] = '\0';
|
||||
|
||||
return (ret == SWKBD_BUTTON_CONFIRM ? temp : "");
|
||||
}
|
||||
+93
-93
@@ -1,93 +1,93 @@
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#include "argumentParser.hpp"
|
||||
#include "common.hpp"
|
||||
#include "init.hpp"
|
||||
#include <dirent.h>
|
||||
#include <string>
|
||||
|
||||
#define ARG_AMOUNT 4 // Dans le cas où plus d’args, modifiez ceci. Il doit être le montant ARG + 1, en raison de 3DSX Path.
|
||||
std::string _3dsxPath = "";
|
||||
|
||||
/*
|
||||
ARG Init.
|
||||
*/
|
||||
static void InitForARG() {
|
||||
gfxInitDefault();
|
||||
romfsInit();
|
||||
cfguInit();
|
||||
Gui::init();
|
||||
amInit();
|
||||
acInit();
|
||||
|
||||
/* Créer des répertoires, s’il manque. */
|
||||
mkdir("sdmc:/3ds", 0777);
|
||||
mkdir("sdmc:/3ds/DarkStore", 0777);
|
||||
mkdir("sdmc:/3ds/DarkStore/stores", 0777);
|
||||
mkdir("sdmc:/3ds/DarkStore/shortcuts", 0777);
|
||||
|
||||
config = std::make_unique<Config>();
|
||||
Lang::load(config->language());
|
||||
Init::LoadFont();
|
||||
osSetSpeedupEnable(true); // Activer l’accélération pour les utilisateurs de new3DS.
|
||||
}
|
||||
|
||||
/*
|
||||
ARG Exit.
|
||||
*/
|
||||
static Result ExitForARG() {
|
||||
Gui::exit();
|
||||
Init::UnloadFont();
|
||||
gfxExit();
|
||||
cfguExit();
|
||||
acExit();
|
||||
amExit();
|
||||
romfsExit();
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
int main(int argc, char *argv[]) {
|
||||
if (argc > 0) _3dsxPath = argv[0];
|
||||
|
||||
/* 4 --> Mode argument. */
|
||||
if (argc == ARG_AMOUNT) {
|
||||
InitForARG();
|
||||
|
||||
const std::string file = argv[1];
|
||||
const std::string entry = argv[2];
|
||||
int dlIndex = atoi(argv[3]);
|
||||
|
||||
std::unique_ptr<ArgumentParser> arg = std::make_unique<ArgumentParser>(file, entry, dlIndex);
|
||||
|
||||
if (arg->GetValid()) arg->Execute(); // Exécuter, si valide.
|
||||
else Msg::waitMsg(Lang::get("ARGUMENT_INVALID"));
|
||||
return ExitForARG();
|
||||
}
|
||||
|
||||
return Init::MainLoop();
|
||||
}
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#include "argumentParser.hpp"
|
||||
#include "common.hpp"
|
||||
#include "init.hpp"
|
||||
#include <dirent.h>
|
||||
#include <string>
|
||||
|
||||
#define ARG_AMOUNT 4 // Dans le cas où plus d’args, modifiez ceci. Il doit être le montant ARG + 1, en raison de 3DSX Path.
|
||||
std::string _3dsxPath = "";
|
||||
|
||||
/*
|
||||
ARG Init.
|
||||
*/
|
||||
static void InitForARG() {
|
||||
gfxInitDefault();
|
||||
romfsInit();
|
||||
cfguInit();
|
||||
Gui::init();
|
||||
amInit();
|
||||
acInit();
|
||||
|
||||
/* Créer des répertoires, s’il manque. */
|
||||
mkdir("sdmc:/3ds", 0777);
|
||||
mkdir("sdmc:/3ds/DarkStore", 0777);
|
||||
mkdir("sdmc:/3ds/DarkStore/stores", 0777);
|
||||
mkdir("sdmc:/3ds/DarkStore/shortcuts", 0777);
|
||||
|
||||
config = std::make_unique<Config>();
|
||||
Lang::load(config->language());
|
||||
Init::LoadFont();
|
||||
osSetSpeedupEnable(true); // Activer l’accélération pour les utilisateurs de new3DS.
|
||||
}
|
||||
|
||||
/*
|
||||
ARG Exit.
|
||||
*/
|
||||
static Result ExitForARG() {
|
||||
Gui::exit();
|
||||
Init::UnloadFont();
|
||||
gfxExit();
|
||||
cfguExit();
|
||||
acExit();
|
||||
amExit();
|
||||
romfsExit();
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
int main(int argc, char *argv[]) {
|
||||
if (argc > 0) _3dsxPath = argv[0];
|
||||
|
||||
/* 4 --> Mode argument. */
|
||||
if (argc == ARG_AMOUNT) {
|
||||
InitForARG();
|
||||
|
||||
const std::string file = argv[1];
|
||||
const std::string entry = argv[2];
|
||||
int dlIndex = atoi(argv[3]);
|
||||
|
||||
std::unique_ptr<ArgumentParser> arg = std::make_unique<ArgumentParser>(file, entry, dlIndex);
|
||||
|
||||
if (arg->GetValid()) arg->Execute(); // Exécuter, si valide.
|
||||
else Msg::waitMsg(Lang::get("ARGUMENT_INVALID"));
|
||||
return ExitForARG();
|
||||
}
|
||||
|
||||
return Init::MainLoop();
|
||||
}
|
||||
|
||||
+254
-254
@@ -1,255 +1,255 @@
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#include "keyboard.hpp"
|
||||
#include "queueSystem.hpp"
|
||||
#include "scriptUtils.hpp"
|
||||
#include "storeUtils.hpp"
|
||||
#include "structs.hpp"
|
||||
#include <fstream>
|
||||
|
||||
#define DOWNLOAD_ENTRIES 7
|
||||
extern std::string _3dsxPath;
|
||||
extern bool is3DSX;
|
||||
extern bool touching(touchPosition touch, Structs::ButtonPos button);
|
||||
static const std::vector<Structs::ButtonPos> downloadBoxes = {
|
||||
{ 46, 32, 270, 22 },
|
||||
{ 46, 62, 270, 22 },
|
||||
{ 46, 92, 270, 22 },
|
||||
{ 46, 122, 270, 22 },
|
||||
{ 46, 152, 270, 22 },
|
||||
{ 46, 182, 270, 22 },
|
||||
{ 46, 212, 270, 22 },
|
||||
|
||||
{ 42, 216, 24, 24 }
|
||||
};
|
||||
|
||||
/*
|
||||
With this, we can create a shortcut. ;P
|
||||
const std::string &entryName: The name of the Entry. AKA: The Title Name.
|
||||
int index: The Download index.
|
||||
const std::string &EshopName: The name of the eShop filename.
|
||||
const std::string &author: The author of the app.
|
||||
*/
|
||||
static bool CreateShortcut(const std::string &entryName, int index, const std::string &EshopName, const std::string &author) {
|
||||
std::string sName = Input::setkbdString(30, Lang::get("ENTER_SHORTCUT_FILENAME"), {});
|
||||
if (sName == "") return false; // Just cancel.
|
||||
std::ofstream out(config->shortcut() + "/" + sName + ".xml", std::ios::binary);
|
||||
|
||||
out << "<shortcut>" << std::endl;
|
||||
|
||||
/* Executable. */
|
||||
const std::string executable = _3dsxPath.substr(5, _3dsxPath.size()); // It must be '/3ds/...'.
|
||||
out << " <executable>" << executable << "</executable>" << std::endl;
|
||||
|
||||
/* Arguments. */
|
||||
out << " <arg>\"" << EshopName << "\" \"" << entryName << "\" \"" << std::to_string(index) << "\"" << "</arg>" << std::endl;
|
||||
|
||||
/* Title. */
|
||||
const std::string title = Input::setkbdString(30, Lang::get("ENTER_TITLE_SHORTCUT"), {});
|
||||
if (title != "") out << " <name>" << title << "</name>" << std::endl;
|
||||
else out << " <name>" << entryName << "</name>" << std::endl;
|
||||
|
||||
/* Description. */
|
||||
const std::string desc = Input::setkbdString(50, Lang::get("ENTER_DESC_SHORTCUT"), {});
|
||||
if (desc != "") out << " <description>" << desc << "</description>" << std::endl;
|
||||
else out << " <description>" << entryName << "</description>" << std::endl;
|
||||
|
||||
/* Author and end. */
|
||||
out << " <author>" << author << "</author>" << std::endl;
|
||||
out << "</shortcut>" << std::endl;
|
||||
out.close();
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
Draw the Download Entries part.
|
||||
const std::unique_ptr<Store> &store: Const Reference to the Store class.
|
||||
const std::vector<std::string> &entries: Const Reference to the download list as a vector of strings.
|
||||
bool fetch: if fetching or not.
|
||||
const std::unique_ptr<StoreEntry> &entry: Const Reference to the StoreEntry.
|
||||
const std::vector<std::string> &sizes: Const Reference to the download sizes as a vector of strings.
|
||||
*/
|
||||
void StoreUtils::DrawDownList(const std::unique_ptr<Store> &store, const std::vector<std::string> &entries, bool fetch, const std::unique_ptr<StoreEntry> &entry, const std::vector<std::string> &sizes) {
|
||||
/* For the Top Screen. */
|
||||
if (store && store->GetValid() && !fetch && entry) {
|
||||
if (entries.size() > 0) {
|
||||
Gui::Draw_Rect(0, 174, 400, 66, BOX_INSIDE_COLOR);
|
||||
const C2D_Image tempImg = entry->GetIcon();
|
||||
const uint8_t offsetW = (48 - tempImg.subtex->width) / 2; // Center W.
|
||||
const uint8_t offsetH = (48 - tempImg.subtex->height) / 2; // Center H.
|
||||
|
||||
C2D_DrawImageAt(tempImg, 9 + offsetW, 174 + 9 + offsetH, 0.5);
|
||||
|
||||
Gui::DrawString(70, 174 + 15, 0.45f, TEXT_COLOR, entries[store->GetDownloadIndex()], 310, 0, font);
|
||||
|
||||
if (!sizes.empty()) {
|
||||
if (sizes[store->GetDownloadIndex()] != "") {
|
||||
Gui::DrawString(70, 174 + 30, 0.45f, TEXT_COLOR, Lang::get("SIZE") + ": " + sizes[store->GetDownloadIndex()], 310, 0, font);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
GFX::DrawBottom();
|
||||
Gui::Draw_Rect(40, 0, 280, 25, ENTRY_BAR_COLOR);
|
||||
Gui::Draw_Rect(40, 25, 280, 1, ENTRY_BAR_OUTL_COLOR);
|
||||
Gui::DrawStringCentered(17, 2, 0.6, TEXT_COLOR, Lang::get("AVAILABLE_DOWNLOADS"), 273, 0, font);
|
||||
|
||||
if (store && store->GetValid() && !fetch && entry) {
|
||||
if (entries.size() > 0) {
|
||||
for (int i = 0; i < DOWNLOAD_ENTRIES && i < (int)entries.size(); i++) {
|
||||
if (store->GetDownloadIndex() == i + store->GetDownloadSIndex()) GFX::DrawBox(downloadBoxes[i].x, downloadBoxes[i].y, downloadBoxes[i].w, downloadBoxes[i].h, false);
|
||||
Gui::DrawStringCentered(46 - 160 + (270 / 2), downloadBoxes[i].y + 4, 0.45f, TEXT_COLOR, entries[(i + store->GetDownloadSIndex())], 268, 0, font);
|
||||
}
|
||||
|
||||
if (is3DSX) GFX::DrawSprite(sprites_shortcut_idx, downloadBoxes[6].x, downloadBoxes[6].y);
|
||||
|
||||
} else { // If no downloads available..
|
||||
Gui::DrawStringCentered(46 - 160 + (270 / 2), downloadBoxes[0].y + 4, 0.5f, TEXT_COLOR, Lang::get("NO_DOWNLOADS_AVAILABLE"), 263, 0, font);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
Adding to Queue.. with checks!
|
||||
*/
|
||||
void AddToQueue(int index, const std::string &entry, const std::unique_ptr<Store> &store) {
|
||||
if (!store) return;
|
||||
/* Check first for proper JSON. */
|
||||
if (!store->GetJson().contains("storeContent")) return;
|
||||
if ((int)store->GetJson()["storeContent"].size() < index) return;
|
||||
if (!store->GetJson()["storeContent"][index].contains(entry)) return;
|
||||
|
||||
nlohmann::json Script = nullptr;
|
||||
|
||||
/* Detect if array or new object thing. Else return Syntax error. :P */
|
||||
if (store->GetJson()["storeContent"][index][entry].type() == nlohmann::json::value_t::array) {
|
||||
Script = store->GetJson()["storeContent"][index][entry];
|
||||
|
||||
} else if (store->GetJson()["storeContent"][index][entry].type() == nlohmann::json::value_t::object) {
|
||||
if (store->GetJson()["storeContent"][index][entry].contains("script") && store->GetJson()["storeContent"][index][entry]["script"].is_array()) {
|
||||
Script = store->GetJson()["storeContent"][index][entry]["script"];
|
||||
|
||||
} else {
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
QueueSystem::AddToQueue(Script, store->GetIconEntry(index), entry); // Here we add this to the Queue at the end.
|
||||
}
|
||||
|
||||
/*
|
||||
This is the Download List handle.
|
||||
Here you can..
|
||||
- Scroll through the download list, if any available.
|
||||
- Execute an Entry of the download list.
|
||||
- Return back to EntryInfo through `B`.
|
||||
const std::unique_ptr<Store> &store: Const Reference to the Store class, since we do not modify anything in it.
|
||||
const std::unique_ptr<StoreEntry> &entry: Const Reference to the current StoreEntry, since we do not modify anything in it.
|
||||
const std::vector<std::string> &entries: Const Reference to the download list, since we do not modify anything in it.
|
||||
int ¤tMenu: Reference to the StoreMode / Menu, so we can switch back to EntryInfo with `B`.
|
||||
std::unique_ptr<Meta> &meta: Reference to the Meta, to apply the updates stuff.
|
||||
const int &lastMode: Const Reference to the last mode.
|
||||
int &smallDelay: Reference to the small delay. This helps to not directly press A.
|
||||
*/
|
||||
void StoreUtils::DownloadHandle(const std::unique_ptr<Store> &store, const std::unique_ptr<StoreEntry> &entry, const std::vector<std::string> &entries, int ¤tMenu, std::unique_ptr<Meta> &meta, const int &lastMode, int &smallDelay) {
|
||||
if (store && entry) { // Ensure, store & entry is not a nullptr.
|
||||
if (smallDelay > 0) {
|
||||
smallDelay--;
|
||||
}
|
||||
|
||||
if ((hDown & KEY_Y) || (hDown & KEY_START) || (hDown & KEY_TOUCH && touching(touch, downloadBoxes[6]))) {
|
||||
if (is3DSX) { // Only allow if 3DSX.
|
||||
if (entries.size() <= 0) return; // Smaller than 0 -> No No.
|
||||
|
||||
if (Msg::promptMsg(Lang::get("CREATE_SHORTCUT"))) {
|
||||
if (CreateShortcut(entry->GetTitle(), store->GetDownloadIndex(), store->GetFileName(), entry->GetAuthor())) {
|
||||
Msg::waitMsg(Lang::get("SHORTCUT_CREATED"));
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (hRepeat & KEY_DOWN) {
|
||||
if (entries.size() <= 0) return; // Smaller *than* 0 -> Invalid.
|
||||
|
||||
if (store->GetDownloadIndex() < (int)entries.size() - 1) store->SetDownloadIndex(store->GetDownloadIndex() + 1);
|
||||
else store->SetDownloadIndex(0);
|
||||
}
|
||||
|
||||
if (hRepeat & KEY_UP) {
|
||||
if (entries.size() <= 0) return; // Smaller *than* 0 -> Invalid.
|
||||
|
||||
if (store->GetDownloadIndex() > 0) store->SetDownloadIndex(store->GetDownloadIndex() - 1);
|
||||
else store->SetDownloadIndex(entries.size() - 1);
|
||||
}
|
||||
|
||||
|
||||
if (hRepeat & KEY_RIGHT) {
|
||||
if (entries.size() <= 0) return; // Smaller *than* 0 -> Invalid.
|
||||
|
||||
if (store->GetDownloadIndex() + DOWNLOAD_ENTRIES < (int)entries.size()-1) store->SetDownloadIndex(store->GetDownloadIndex() + DOWNLOAD_ENTRIES);
|
||||
else store->SetDownloadIndex(entries.size()-1);
|
||||
}
|
||||
|
||||
if (hRepeat & KEY_LEFT) {
|
||||
if (entries.size() <= 0) return; // Smaller *than* 0 -> Invalid.
|
||||
|
||||
if (store->GetDownloadIndex() - DOWNLOAD_ENTRIES > 0) store->SetDownloadIndex(store->GetDownloadIndex() - DOWNLOAD_ENTRIES);
|
||||
else store->SetDownloadIndex(0);
|
||||
}
|
||||
|
||||
if (smallDelay == 0 && hDown & KEY_TOUCH) {
|
||||
if (entries.size() <= 0) return; // Smaller *than* 0 -> Invalid.
|
||||
|
||||
for (int i = 0; i < DOWNLOAD_ENTRIES; i++) {
|
||||
if (touching(touch, downloadBoxes[i])) {
|
||||
if (i + store->GetDownloadSIndex() < (int)entries.size()) {
|
||||
if (Msg::promptMsg(Lang::get("EXECUTE_ENTRY") + "\n\n" + entries[i + store->GetDownloadSIndex()])) {
|
||||
AddToQueue(entry->GetEntryIndex(), entries[i + store->GetDownloadSIndex()], store);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (smallDelay == 0 && hDown & KEY_A) {
|
||||
if (entries.size() <= 0) return; // Smaller *than* 0 -> Invalid.
|
||||
|
||||
if (Msg::promptMsg(Lang::get("EXECUTE_ENTRY") + "\n\n" + entries[store->GetDownloadIndex()])) {
|
||||
AddToQueue(entry->GetEntryIndex(), entries[store->GetDownloadIndex()], store);
|
||||
}
|
||||
}
|
||||
|
||||
if (hDown & KEY_B) currentMenu = lastMode; // Go back to EntryInfo.
|
||||
|
||||
/* Scroll Handle. */
|
||||
if (store->GetDownloadIndex() < store->GetDownloadSIndex()) store->SetDownloadSIndex(store->GetDownloadIndex());
|
||||
else if (store->GetDownloadIndex() > store->GetDownloadSIndex() + DOWNLOAD_ENTRIES - 1) store->SetDownloadSIndex(store->GetDownloadIndex() - DOWNLOAD_ENTRIES + 1);
|
||||
}
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#include "keyboard.hpp"
|
||||
#include "queueSystem.hpp"
|
||||
#include "scriptUtils.hpp"
|
||||
#include "storeUtils.hpp"
|
||||
#include "structs.hpp"
|
||||
#include <fstream>
|
||||
|
||||
#define DOWNLOAD_ENTRIES 7
|
||||
extern std::string _3dsxPath;
|
||||
extern bool is3DSX;
|
||||
extern bool touching(touchPosition touch, Structs::ButtonPos button);
|
||||
static const std::vector<Structs::ButtonPos> downloadBoxes = {
|
||||
{ 46, 32, 270, 22 },
|
||||
{ 46, 62, 270, 22 },
|
||||
{ 46, 92, 270, 22 },
|
||||
{ 46, 122, 270, 22 },
|
||||
{ 46, 152, 270, 22 },
|
||||
{ 46, 182, 270, 22 },
|
||||
{ 46, 212, 270, 22 },
|
||||
|
||||
{ 42, 216, 24, 24 }
|
||||
};
|
||||
|
||||
/*
|
||||
With this, we can create a shortcut. ;P
|
||||
const std::string &entryName: The name of the Entry. AKA: The Title Name.
|
||||
int index: The Download index.
|
||||
const std::string &EshopName: The name of the eShop filename.
|
||||
const std::string &author: The author of the app.
|
||||
*/
|
||||
static bool CreateShortcut(const std::string &entryName, int index, const std::string &EshopName, const std::string &author) {
|
||||
std::string sName = Input::setkbdString(30, Lang::get("ENTER_SHORTCUT_FILENAME"), {});
|
||||
if (sName == "") return false; // Just cancel.
|
||||
std::ofstream out(config->shortcut() + "/" + sName + ".xml", std::ios::binary);
|
||||
|
||||
out << "<shortcut>" << std::endl;
|
||||
|
||||
/* Executable. */
|
||||
const std::string executable = _3dsxPath.substr(5, _3dsxPath.size()); // It must be '/3ds/...'.
|
||||
out << " <executable>" << executable << "</executable>" << std::endl;
|
||||
|
||||
/* Arguments. */
|
||||
out << " <arg>\"" << EshopName << "\" \"" << entryName << "\" \"" << std::to_string(index) << "\"" << "</arg>" << std::endl;
|
||||
|
||||
/* Title. */
|
||||
const std::string title = Input::setkbdString(30, Lang::get("ENTER_TITLE_SHORTCUT"), {});
|
||||
if (title != "") out << " <name>" << title << "</name>" << std::endl;
|
||||
else out << " <name>" << entryName << "</name>" << std::endl;
|
||||
|
||||
/* Description. */
|
||||
const std::string desc = Input::setkbdString(50, Lang::get("ENTER_DESC_SHORTCUT"), {});
|
||||
if (desc != "") out << " <description>" << desc << "</description>" << std::endl;
|
||||
else out << " <description>" << entryName << "</description>" << std::endl;
|
||||
|
||||
/* Author and end. */
|
||||
out << " <author>" << author << "</author>" << std::endl;
|
||||
out << "</shortcut>" << std::endl;
|
||||
out.close();
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
Draw the Download Entries part.
|
||||
const std::unique_ptr<Store> &store: Const Reference to the Store class.
|
||||
const std::vector<std::string> &entries: Const Reference to the download list as a vector of strings.
|
||||
bool fetch: if fetching or not.
|
||||
const std::unique_ptr<StoreEntry> &entry: Const Reference to the StoreEntry.
|
||||
const std::vector<std::string> &sizes: Const Reference to the download sizes as a vector of strings.
|
||||
*/
|
||||
void StoreUtils::DrawDownList(const std::unique_ptr<Store> &store, const std::vector<std::string> &entries, bool fetch, const std::unique_ptr<StoreEntry> &entry, const std::vector<std::string> &sizes) {
|
||||
/* For the Top Screen. */
|
||||
if (store && store->GetValid() && !fetch && entry) {
|
||||
if (entries.size() > 0) {
|
||||
Gui::Draw_Rect(0, 174, 400, 66, BOX_INSIDE_COLOR);
|
||||
const C2D_Image tempImg = entry->GetIcon();
|
||||
const uint8_t offsetW = (48 - tempImg.subtex->width) / 2; // Center W.
|
||||
const uint8_t offsetH = (48 - tempImg.subtex->height) / 2; // Center H.
|
||||
|
||||
C2D_DrawImageAt(tempImg, 9 + offsetW, 174 + 9 + offsetH, 0.5);
|
||||
|
||||
Gui::DrawString(70, 174 + 15, 0.45f, TEXT_COLOR, entries[store->GetDownloadIndex()], 310, 0, font);
|
||||
|
||||
if (!sizes.empty()) {
|
||||
if (sizes[store->GetDownloadIndex()] != "") {
|
||||
Gui::DrawString(70, 174 + 30, 0.45f, TEXT_COLOR, Lang::get("SIZE") + ": " + sizes[store->GetDownloadIndex()], 310, 0, font);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
GFX::DrawBottom();
|
||||
Gui::Draw_Rect(40, 0, 280, 25, ENTRY_BAR_COLOR);
|
||||
Gui::Draw_Rect(40, 25, 280, 1, ENTRY_BAR_OUTL_COLOR);
|
||||
Gui::DrawStringCentered(17, 2, 0.6, TEXT_COLOR, Lang::get("AVAILABLE_DOWNLOADS"), 273, 0, font);
|
||||
|
||||
if (store && store->GetValid() && !fetch && entry) {
|
||||
if (entries.size() > 0) {
|
||||
for (int i = 0; i < DOWNLOAD_ENTRIES && i < (int)entries.size(); i++) {
|
||||
if (store->GetDownloadIndex() == i + store->GetDownloadSIndex()) GFX::DrawBox(downloadBoxes[i].x, downloadBoxes[i].y, downloadBoxes[i].w, downloadBoxes[i].h, false);
|
||||
Gui::DrawStringCentered(46 - 160 + (270 / 2), downloadBoxes[i].y + 4, 0.45f, TEXT_COLOR, entries[(i + store->GetDownloadSIndex())], 268, 0, font);
|
||||
}
|
||||
|
||||
if (is3DSX) GFX::DrawSprite(sprites_shortcut_idx, downloadBoxes[6].x, downloadBoxes[6].y);
|
||||
|
||||
} else { // If no downloads available..
|
||||
Gui::DrawStringCentered(46 - 160 + (270 / 2), downloadBoxes[0].y + 4, 0.5f, TEXT_COLOR, Lang::get("NO_DOWNLOADS_AVAILABLE"), 263, 0, font);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
Adding to Queue.. with checks!
|
||||
*/
|
||||
void AddToQueue(int index, const std::string &entry, const std::unique_ptr<Store> &store) {
|
||||
if (!store) return;
|
||||
/* Check first for proper JSON. */
|
||||
if (!store->GetJson().contains("storeContent")) return;
|
||||
if ((int)store->GetJson()["storeContent"].size() < index) return;
|
||||
if (!store->GetJson()["storeContent"][index].contains(entry)) return;
|
||||
|
||||
nlohmann::json Script = nullptr;
|
||||
|
||||
/* Detect if array or new object thing. Else return Syntax error. :P */
|
||||
if (store->GetJson()["storeContent"][index][entry].type() == nlohmann::json::value_t::array) {
|
||||
Script = store->GetJson()["storeContent"][index][entry];
|
||||
|
||||
} else if (store->GetJson()["storeContent"][index][entry].type() == nlohmann::json::value_t::object) {
|
||||
if (store->GetJson()["storeContent"][index][entry].contains("script") && store->GetJson()["storeContent"][index][entry]["script"].is_array()) {
|
||||
Script = store->GetJson()["storeContent"][index][entry]["script"];
|
||||
|
||||
} else {
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
QueueSystem::AddToQueue(Script, store->GetIconEntry(index), entry); // Here we add this to the Queue at the end.
|
||||
}
|
||||
|
||||
/*
|
||||
This is the Download List handle.
|
||||
Here you can..
|
||||
- Scroll through the download list, if any available.
|
||||
- Execute an Entry of the download list.
|
||||
- Return back to EntryInfo through `B`.
|
||||
const std::unique_ptr<Store> &store: Const Reference to the Store class, since we do not modify anything in it.
|
||||
const std::unique_ptr<StoreEntry> &entry: Const Reference to the current StoreEntry, since we do not modify anything in it.
|
||||
const std::vector<std::string> &entries: Const Reference to the download list, since we do not modify anything in it.
|
||||
int ¤tMenu: Reference to the StoreMode / Menu, so we can switch back to EntryInfo with `B`.
|
||||
std::unique_ptr<Meta> &meta: Reference to the Meta, to apply the updates stuff.
|
||||
const int &lastMode: Const Reference to the last mode.
|
||||
int &smallDelay: Reference to the small delay. This helps to not directly press A.
|
||||
*/
|
||||
void StoreUtils::DownloadHandle(const std::unique_ptr<Store> &store, const std::unique_ptr<StoreEntry> &entry, const std::vector<std::string> &entries, int ¤tMenu, std::unique_ptr<Meta> &meta, const int &lastMode, int &smallDelay) {
|
||||
if (store && entry) { // Ensure, store & entry is not a nullptr.
|
||||
if (smallDelay > 0) {
|
||||
smallDelay--;
|
||||
}
|
||||
|
||||
if ((hDown & KEY_Y) || (hDown & KEY_START) || (hDown & KEY_TOUCH && touching(touch, downloadBoxes[6]))) {
|
||||
if (is3DSX) { // Only allow if 3DSX.
|
||||
if (entries.size() <= 0) return; // Smaller than 0 -> No No.
|
||||
|
||||
if (Msg::promptMsg(Lang::get("CREATE_SHORTCUT"))) {
|
||||
if (CreateShortcut(entry->GetTitle(), store->GetDownloadIndex(), store->GetFileName(), entry->GetAuthor())) {
|
||||
Msg::waitMsg(Lang::get("SHORTCUT_CREATED"));
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (hRepeat & KEY_DOWN) {
|
||||
if (entries.size() <= 0) return; // Smaller *than* 0 -> Invalid.
|
||||
|
||||
if (store->GetDownloadIndex() < (int)entries.size() - 1) store->SetDownloadIndex(store->GetDownloadIndex() + 1);
|
||||
else store->SetDownloadIndex(0);
|
||||
}
|
||||
|
||||
if (hRepeat & KEY_UP) {
|
||||
if (entries.size() <= 0) return; // Smaller *than* 0 -> Invalid.
|
||||
|
||||
if (store->GetDownloadIndex() > 0) store->SetDownloadIndex(store->GetDownloadIndex() - 1);
|
||||
else store->SetDownloadIndex(entries.size() - 1);
|
||||
}
|
||||
|
||||
|
||||
if (hRepeat & KEY_RIGHT) {
|
||||
if (entries.size() <= 0) return; // Smaller *than* 0 -> Invalid.
|
||||
|
||||
if (store->GetDownloadIndex() + DOWNLOAD_ENTRIES < (int)entries.size()-1) store->SetDownloadIndex(store->GetDownloadIndex() + DOWNLOAD_ENTRIES);
|
||||
else store->SetDownloadIndex(entries.size()-1);
|
||||
}
|
||||
|
||||
if (hRepeat & KEY_LEFT) {
|
||||
if (entries.size() <= 0) return; // Smaller *than* 0 -> Invalid.
|
||||
|
||||
if (store->GetDownloadIndex() - DOWNLOAD_ENTRIES > 0) store->SetDownloadIndex(store->GetDownloadIndex() - DOWNLOAD_ENTRIES);
|
||||
else store->SetDownloadIndex(0);
|
||||
}
|
||||
|
||||
if (smallDelay == 0 && hDown & KEY_TOUCH) {
|
||||
if (entries.size() <= 0) return; // Smaller *than* 0 -> Invalid.
|
||||
|
||||
for (int i = 0; i < DOWNLOAD_ENTRIES; i++) {
|
||||
if (touching(touch, downloadBoxes[i])) {
|
||||
if (i + store->GetDownloadSIndex() < (int)entries.size()) {
|
||||
if (Msg::promptMsg(Lang::get("EXECUTE_ENTRY") + "\n\n" + entries[i + store->GetDownloadSIndex()])) {
|
||||
AddToQueue(entry->GetEntryIndex(), entries[i + store->GetDownloadSIndex()], store);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (smallDelay == 0 && hDown & KEY_A) {
|
||||
if (entries.size() <= 0) return; // Smaller *than* 0 -> Invalid.
|
||||
|
||||
if (Msg::promptMsg(Lang::get("EXECUTE_ENTRY") + "\n\n" + entries[store->GetDownloadIndex()])) {
|
||||
AddToQueue(entry->GetEntryIndex(), entries[store->GetDownloadIndex()], store);
|
||||
}
|
||||
}
|
||||
|
||||
if (hDown & KEY_B) currentMenu = lastMode; // Go back to EntryInfo.
|
||||
|
||||
/* Scroll Handle. */
|
||||
if (store->GetDownloadIndex() < store->GetDownloadSIndex()) store->SetDownloadSIndex(store->GetDownloadIndex());
|
||||
else if (store->GetDownloadIndex() > store->GetDownloadSIndex() + DOWNLOAD_ENTRIES - 1) store->SetDownloadSIndex(store->GetDownloadIndex() - DOWNLOAD_ENTRIES + 1);
|
||||
}
|
||||
}
|
||||
+88
-88
@@ -1,89 +1,89 @@
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#include "storeUtils.hpp"
|
||||
#include "structs.hpp"
|
||||
|
||||
extern bool touching(touchPosition touch, Structs::ButtonPos button);
|
||||
static const Structs::ButtonPos btn = { 45, 215, 24, 24 };
|
||||
static const Structs::ButtonPos sshot = { 75, 215, 24, 24 };
|
||||
static const Structs::ButtonPos notes = { 105, 215, 24, 24 };
|
||||
extern bool checkWifiStatus();
|
||||
|
||||
/*
|
||||
Dessinez la partie Entry Info.
|
||||
const std::unique_ptr<Store> &store : Const Référence à la classe Store.
|
||||
const std::unique_ptr<StoreEntry> &entry : Const Référence au StoreEntry actuel.
|
||||
*/
|
||||
void StoreUtils::DrawEntryInfo(const std::unique_ptr<Store> &store, const std::unique_ptr<StoreEntry> &entry) {
|
||||
if (store && entry) { // Assurez-vous que l’enregistrement et la saisie ne sont pas un nullptr.
|
||||
Gui::Draw_Rect(40, 0, 280, 36, ENTRY_BAR_COLOR);
|
||||
Gui::Draw_Rect(40, 36, 280, 1, ENTRY_BAR_OUTL_COLOR);
|
||||
|
||||
Gui::DrawStringCentered(17, 0, 0.6, TEXT_COLOR, entry->GetTitle(), 273, 0, font);
|
||||
Gui::DrawStringCentered(17, 20, 0.4, TEXT_COLOR, entry->GetAuthor(), 273, 0, font);
|
||||
Gui::DrawStringCentered(17, 50, 0.4, TEXT_COLOR, entry->GetDescription(), 248, 0, font, C2D_WordWrap);
|
||||
|
||||
Gui::DrawString(61, 130, 0.45, TEXT_COLOR, Lang::get("VERSION") + ": " + entry->GetVersion(), 248, 0, font);
|
||||
Gui::DrawString(61, 145, 0.45, TEXT_COLOR, Lang::get("CATEGORY") + ": " + entry->GetCategory(), 248, 0, font);
|
||||
Gui::DrawString(61, 160, 0.45, TEXT_COLOR, Lang::get("CONSOLE") + ": " + entry->GetConsole(), 248, 0, font);
|
||||
Gui::DrawString(61, 175, 0.45, TEXT_COLOR, Lang::get("SIZE") + ": " + entry->GetSize(), 248, 0, font);
|
||||
Gui::DrawString(61, 195, 0.45, TEXT_COLOR, entry->GetAdditionalcontent(), 248, 0, font);
|
||||
|
||||
GFX::DrawBox(btn.x, btn.y, btn.w, btn.h, false);
|
||||
if (!entry->GetScreenshots().empty()) GFX::DrawSprite(sprites_screenshot_idx, sshot.x, sshot.y);
|
||||
if (entry->GetReleaseNotes() != "") GFX::DrawSprite(sprites_notes_idx, notes.x, notes.y);
|
||||
Gui::DrawString(btn.x + 5, btn.y + 2, 0.6f, TEXT_COLOR, "★", 0, 0, font);
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
La poignée EntryInfo.
|
||||
Ici vous pouvez..
|
||||
- Accédez à la liste de téléchargement en appuyant sur « A ».
|
||||
- Montrez le MarkMenu avec START.
|
||||
bool &showMark : Référence à showMark.. pour afficher le menu mark.
|
||||
bool &fetch : Référence à fetch, pour que nous sachions, si nous avons besoin de fetch,
|
||||
quand nous accédons à la liste de téléchargement.
|
||||
*/
|
||||
void StoreUtils::EntryHandle(bool &showMark, bool &fetch, bool &sFetch, int &mode, const std::unique_ptr<StoreEntry> &entry) {
|
||||
if (entry) {
|
||||
if ((hDown & KEY_START) || (hDown & KEY_TOUCH && touching(touch, btn))) showMark = true;
|
||||
|
||||
if ((hDown & KEY_Y) || (hDown & KEY_TOUCH && touching(touch, sshot))) {
|
||||
if (!entry->GetScreenshots().empty()) {
|
||||
if (checkWifiStatus()) {
|
||||
sFetch = true;
|
||||
mode = 6;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if ((hDown & KEY_X) || (hDown & KEY_TOUCH && touching(touch, notes))) {
|
||||
if (entry->GetReleaseNotes() != "") mode = 7;
|
||||
}
|
||||
}
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#include "storeUtils.hpp"
|
||||
#include "structs.hpp"
|
||||
|
||||
extern bool touching(touchPosition touch, Structs::ButtonPos button);
|
||||
static const Structs::ButtonPos btn = { 45, 215, 24, 24 };
|
||||
static const Structs::ButtonPos sshot = { 75, 215, 24, 24 };
|
||||
static const Structs::ButtonPos notes = { 105, 215, 24, 24 };
|
||||
extern bool checkWifiStatus();
|
||||
|
||||
/*
|
||||
Dessinez la partie Entry Info.
|
||||
const std::unique_ptr<Store> &store : Const Référence à la classe Store.
|
||||
const std::unique_ptr<StoreEntry> &entry : Const Référence au StoreEntry actuel.
|
||||
*/
|
||||
void StoreUtils::DrawEntryInfo(const std::unique_ptr<Store> &store, const std::unique_ptr<StoreEntry> &entry) {
|
||||
if (store && entry) { // Assurez-vous que l’enregistrement et la saisie ne sont pas un nullptr.
|
||||
Gui::Draw_Rect(40, 0, 280, 36, ENTRY_BAR_COLOR);
|
||||
Gui::Draw_Rect(40, 36, 280, 1, ENTRY_BAR_OUTL_COLOR);
|
||||
|
||||
Gui::DrawStringCentered(17, 0, 0.6, TEXT_COLOR, entry->GetTitle(), 273, 0, font);
|
||||
Gui::DrawStringCentered(17, 20, 0.4, TEXT_COLOR, entry->GetAuthor(), 273, 0, font);
|
||||
Gui::DrawStringCentered(17, 50, 0.4, TEXT_COLOR, entry->GetDescription(), 248, 0, font, C2D_WordWrap);
|
||||
|
||||
Gui::DrawString(61, 130, 0.45, TEXT_COLOR, Lang::get("VERSION") + ": " + entry->GetVersion(), 248, 0, font);
|
||||
Gui::DrawString(61, 145, 0.45, TEXT_COLOR, Lang::get("CATEGORY") + ": " + entry->GetCategory(), 248, 0, font);
|
||||
Gui::DrawString(61, 160, 0.45, TEXT_COLOR, Lang::get("CONSOLE") + ": " + entry->GetConsole(), 248, 0, font);
|
||||
Gui::DrawString(61, 175, 0.45, TEXT_COLOR, Lang::get("SIZE") + ": " + entry->GetSize(), 248, 0, font);
|
||||
Gui::DrawString(61, 195, 0.45, TEXT_COLOR, entry->GetAdditionalcontent(), 248, 0, font);
|
||||
|
||||
GFX::DrawBox(btn.x, btn.y, btn.w, btn.h, false);
|
||||
if (!entry->GetScreenshots().empty()) GFX::DrawSprite(sprites_screenshot_idx, sshot.x, sshot.y);
|
||||
if (entry->GetReleaseNotes() != "") GFX::DrawSprite(sprites_notes_idx, notes.x, notes.y);
|
||||
Gui::DrawString(btn.x + 5, btn.y + 2, 0.6f, TEXT_COLOR, "★", 0, 0, font);
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
La poignée EntryInfo.
|
||||
Ici vous pouvez..
|
||||
- Accédez à la liste de téléchargement en appuyant sur « A ».
|
||||
- Montrez le MarkMenu avec START.
|
||||
bool &showMark : Référence à showMark.. pour afficher le menu mark.
|
||||
bool &fetch : Référence à fetch, pour que nous sachions, si nous avons besoin de fetch,
|
||||
quand nous accédons à la liste de téléchargement.
|
||||
*/
|
||||
void StoreUtils::EntryHandle(bool &showMark, bool &fetch, bool &sFetch, int &mode, const std::unique_ptr<StoreEntry> &entry) {
|
||||
if (entry) {
|
||||
if ((hDown & KEY_START) || (hDown & KEY_TOUCH && touching(touch, btn))) showMark = true;
|
||||
|
||||
if ((hDown & KEY_Y) || (hDown & KEY_TOUCH && touching(touch, sshot))) {
|
||||
if (!entry->GetScreenshots().empty()) {
|
||||
if (checkWifiStatus()) {
|
||||
sFetch = true;
|
||||
mode = 6;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if ((hDown & KEY_X) || (hDown & KEY_TOUCH && touching(touch, notes))) {
|
||||
if (entry->GetReleaseNotes() != "") mode = 7;
|
||||
}
|
||||
}
|
||||
}
|
||||
+175
-175
@@ -1,176 +1,176 @@
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#include "storeUtils.hpp"
|
||||
#include "structs.hpp"
|
||||
|
||||
static const std::vector<Structs::ButtonPos> GridBoxes = {
|
||||
{ 25, 45, 50, 50 },
|
||||
{ 100, 45, 50, 50 },
|
||||
{ 175, 45, 50, 50 },
|
||||
{ 250, 45, 50, 50 },
|
||||
{ 325, 45, 50, 50 },
|
||||
|
||||
{ 25, 105, 50, 50 },
|
||||
{ 100, 105, 50, 50 },
|
||||
{ 175, 105, 50, 50 },
|
||||
{ 250, 105, 50, 50 },
|
||||
{ 325, 105, 50, 50 },
|
||||
|
||||
{ 25, 165, 50, 50 },
|
||||
{ 100, 165, 50, 50 },
|
||||
{ 175, 165, 50, 50 },
|
||||
{ 250, 165, 50, 50 },
|
||||
{ 325, 165, 50, 50 }
|
||||
};
|
||||
|
||||
/*
|
||||
Dessinez la grille supérieure.
|
||||
const std::unique_ptr<Store> &store : Const Référence à la classe Store.
|
||||
const std::vector<std::unique_ptr<StoreEntry>> &entries : Const Référence à StoreEntries.
|
||||
*/
|
||||
void StoreUtils::DrawGrid(const std::unique_ptr<Store> &store, const std::vector<std::unique_ptr<StoreEntry>> &entries) {
|
||||
if (store) { // Assurez-vous que le magasin n’est pas un nullptr.
|
||||
|
||||
if (config->usebg() && store->customBG()) {
|
||||
C2D_DrawImageAt(store->GetStoreImg(), 0, 26, 0.5f, nullptr);
|
||||
|
||||
} else {
|
||||
Gui::Draw_Rect(0, 26, 400, 214, BG_COLOR);
|
||||
}
|
||||
|
||||
for (int i = 0, i2 = 0 + (store->GetScreenIndx() * 5); i2 < 15 + (store->GetScreenIndx() * 5) && i2 < (int)entries.size(); i2++, i++) {
|
||||
|
||||
/* Boxes. */
|
||||
if (i == store->GetBox()) GFX::DrawBox(GridBoxes[i].x, GridBoxes[i].y, 50, 50, true);
|
||||
|
||||
/* Assurez-vous que les entrées sont plus grandes que l’index. */
|
||||
if ((int)entries.size() > i2) {
|
||||
if (entries[i2]) { // Assurez-vous que l’entrée n’est pas nullptr.
|
||||
const C2D_Image tempImg = entries[i2]->GetIcon();
|
||||
const uint8_t offsetW = (48 - tempImg.subtex->width) / 2; // Centre W.
|
||||
const uint8_t offsetH = (48 - tempImg.subtex->height) / 2; // Centre H.
|
||||
|
||||
C2D_DrawImageAt(tempImg, GridBoxes[i].x + 1 + offsetW, GridBoxes[i].y + 1 + offsetH, 0.5);
|
||||
|
||||
/* Mettre à jour la marque disponible. */
|
||||
if (entries[i2]->GetUpdateAvl()) GFX::DrawSprite(sprites_update_app_idx, GridBoxes[i].x + 32, GridBoxes[i].y + 32);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
Poignée logique de grille supérieure.
|
||||
Ici vous pouvez..
|
||||
- Faire défiler la grille à l’aide du pavé en D.
|
||||
std::unique_ptrStore> &store : Référence à la classe Store.
|
||||
std::vectorstd::unique_ptrStoreEntry>> &entries : Référence à StoreEntries.
|
||||
const int ¤tMode : Référence au mode actuel.
|
||||
int &lastMode : Référence au dernier mode.
|
||||
bool &fetch : Référence à fetch.
|
||||
int &smallDelay : Référence au petit délai.
|
||||
*/
|
||||
void StoreUtils::GridLogic(std::unique_ptr<Store> &store, std::vector<std::unique_ptr<StoreEntry>> &entries, int ¤tMode, int &lastMode, bool &fetch, int &smallDelay) {
|
||||
if (store) { // Assurez-vous que le magasin n’est pas un nullptr.
|
||||
if (hRepeat & KEY_DOWN) {
|
||||
if (store->GetBox() > 9) {
|
||||
if (store->GetEntry() + 5 < (int)entries.size() - 1) {
|
||||
store->SetEntry(store->GetEntry() + 5);
|
||||
|
||||
if (entries.size() > 15) store->SetScreenIndx((store->GetEntry() / 5) - 2);
|
||||
|
||||
} else {
|
||||
if (store->GetEntry() < (int)entries.size() - 1) {
|
||||
store->SetEntry(entries.size() - 1);
|
||||
store->SetBox(10 + (store->GetEntry() % 5));
|
||||
|
||||
if (entries.size() > 15) store->SetScreenIndx((store->GetEntry() / 5) - 2);
|
||||
}
|
||||
}
|
||||
|
||||
} else {
|
||||
if (store->GetEntry() + 5 < (int)entries.size()) {
|
||||
store->SetBox(store->GetBox() + 5);
|
||||
store->SetEntry(store->GetEntry() + 5);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (hRepeat & KEY_RIGHT) {
|
||||
if (store->GetEntry() < (int)entries.size() - 1) {
|
||||
if (store->GetBox() < 14) {
|
||||
store->SetBox(store->GetBox() + 1);
|
||||
store->SetEntry(store->GetEntry() + 1);
|
||||
|
||||
} else {
|
||||
store->SetBox(10);
|
||||
store->SetEntry(store->GetEntry() + 1);
|
||||
|
||||
store->SetScreenIndx((store->GetEntry() / 5) - 2);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (hRepeat & KEY_LEFT) {
|
||||
if (store->GetEntry() > 0) {
|
||||
if (store->GetBox() > 0) {
|
||||
store->SetBox(store->GetBox() - 1);
|
||||
store->SetEntry(store->GetEntry() - 1);
|
||||
|
||||
} else {
|
||||
store->SetBox(4);
|
||||
store->SetEntry(store->GetEntry() - 1);
|
||||
|
||||
store->SetScreenIndx((store->GetEntry() / 5));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (hRepeat & KEY_UP) {
|
||||
if (store->GetBox() < 5) {
|
||||
if (store->GetEntry() > 4) {
|
||||
store->SetEntry(store->GetEntry() - 5);
|
||||
|
||||
store->SetScreenIndx((store->GetEntry() / 5));
|
||||
}
|
||||
|
||||
} else {
|
||||
store->SetBox(store->GetBox() - 5);
|
||||
store->SetEntry(store->GetEntry() - 5);
|
||||
}
|
||||
}
|
||||
|
||||
if (hDown & KEY_A) {
|
||||
fetch = true;
|
||||
smallDelay = 5;
|
||||
lastMode = currentMode;
|
||||
currentMode = 1;
|
||||
}
|
||||
}
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#include "storeUtils.hpp"
|
||||
#include "structs.hpp"
|
||||
|
||||
static const std::vector<Structs::ButtonPos> GridBoxes = {
|
||||
{ 25, 45, 50, 50 },
|
||||
{ 100, 45, 50, 50 },
|
||||
{ 175, 45, 50, 50 },
|
||||
{ 250, 45, 50, 50 },
|
||||
{ 325, 45, 50, 50 },
|
||||
|
||||
{ 25, 105, 50, 50 },
|
||||
{ 100, 105, 50, 50 },
|
||||
{ 175, 105, 50, 50 },
|
||||
{ 250, 105, 50, 50 },
|
||||
{ 325, 105, 50, 50 },
|
||||
|
||||
{ 25, 165, 50, 50 },
|
||||
{ 100, 165, 50, 50 },
|
||||
{ 175, 165, 50, 50 },
|
||||
{ 250, 165, 50, 50 },
|
||||
{ 325, 165, 50, 50 }
|
||||
};
|
||||
|
||||
/*
|
||||
Dessinez la grille supérieure.
|
||||
const std::unique_ptr<Store> &store : Const Référence à la classe Store.
|
||||
const std::vector<std::unique_ptr<StoreEntry>> &entries : Const Référence à StoreEntries.
|
||||
*/
|
||||
void StoreUtils::DrawGrid(const std::unique_ptr<Store> &store, const std::vector<std::unique_ptr<StoreEntry>> &entries) {
|
||||
if (store) { // Assurez-vous que le magasin n’est pas un nullptr.
|
||||
|
||||
if (config->usebg() && store->customBG()) {
|
||||
C2D_DrawImageAt(store->GetStoreImg(), 0, 26, 0.5f, nullptr);
|
||||
|
||||
} else {
|
||||
Gui::Draw_Rect(0, 26, 400, 214, BG_COLOR);
|
||||
}
|
||||
|
||||
for (int i = 0, i2 = 0 + (store->GetScreenIndx() * 5); i2 < 15 + (store->GetScreenIndx() * 5) && i2 < (int)entries.size(); i2++, i++) {
|
||||
|
||||
/* Boxes. */
|
||||
if (i == store->GetBox()) GFX::DrawBox(GridBoxes[i].x, GridBoxes[i].y, 50, 50, true);
|
||||
|
||||
/* Assurez-vous que les entrées sont plus grandes que l’index. */
|
||||
if ((int)entries.size() > i2) {
|
||||
if (entries[i2]) { // Assurez-vous que l’entrée n’est pas nullptr.
|
||||
const C2D_Image tempImg = entries[i2]->GetIcon();
|
||||
const uint8_t offsetW = (48 - tempImg.subtex->width) / 2; // Centre W.
|
||||
const uint8_t offsetH = (48 - tempImg.subtex->height) / 2; // Centre H.
|
||||
|
||||
C2D_DrawImageAt(tempImg, GridBoxes[i].x + 1 + offsetW, GridBoxes[i].y + 1 + offsetH, 0.5);
|
||||
|
||||
/* Mettre à jour la marque disponible. */
|
||||
if (entries[i2]->GetUpdateAvl()) GFX::DrawSprite(sprites_update_app_idx, GridBoxes[i].x + 32, GridBoxes[i].y + 32);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
Poignée logique de grille supérieure.
|
||||
Ici vous pouvez..
|
||||
- Faire défiler la grille à l’aide du pavé en D.
|
||||
std::unique_ptrStore> &store : Référence à la classe Store.
|
||||
std::vectorstd::unique_ptrStoreEntry>> &entries : Référence à StoreEntries.
|
||||
const int ¤tMode : Référence au mode actuel.
|
||||
int &lastMode : Référence au dernier mode.
|
||||
bool &fetch : Référence à fetch.
|
||||
int &smallDelay : Référence au petit délai.
|
||||
*/
|
||||
void StoreUtils::GridLogic(std::unique_ptr<Store> &store, std::vector<std::unique_ptr<StoreEntry>> &entries, int ¤tMode, int &lastMode, bool &fetch, int &smallDelay) {
|
||||
if (store) { // Assurez-vous que le magasin n’est pas un nullptr.
|
||||
if (hRepeat & KEY_DOWN) {
|
||||
if (store->GetBox() > 9) {
|
||||
if (store->GetEntry() + 5 < (int)entries.size() - 1) {
|
||||
store->SetEntry(store->GetEntry() + 5);
|
||||
|
||||
if (entries.size() > 15) store->SetScreenIndx((store->GetEntry() / 5) - 2);
|
||||
|
||||
} else {
|
||||
if (store->GetEntry() < (int)entries.size() - 1) {
|
||||
store->SetEntry(entries.size() - 1);
|
||||
store->SetBox(10 + (store->GetEntry() % 5));
|
||||
|
||||
if (entries.size() > 15) store->SetScreenIndx((store->GetEntry() / 5) - 2);
|
||||
}
|
||||
}
|
||||
|
||||
} else {
|
||||
if (store->GetEntry() + 5 < (int)entries.size()) {
|
||||
store->SetBox(store->GetBox() + 5);
|
||||
store->SetEntry(store->GetEntry() + 5);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (hRepeat & KEY_RIGHT) {
|
||||
if (store->GetEntry() < (int)entries.size() - 1) {
|
||||
if (store->GetBox() < 14) {
|
||||
store->SetBox(store->GetBox() + 1);
|
||||
store->SetEntry(store->GetEntry() + 1);
|
||||
|
||||
} else {
|
||||
store->SetBox(10);
|
||||
store->SetEntry(store->GetEntry() + 1);
|
||||
|
||||
store->SetScreenIndx((store->GetEntry() / 5) - 2);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (hRepeat & KEY_LEFT) {
|
||||
if (store->GetEntry() > 0) {
|
||||
if (store->GetBox() > 0) {
|
||||
store->SetBox(store->GetBox() - 1);
|
||||
store->SetEntry(store->GetEntry() - 1);
|
||||
|
||||
} else {
|
||||
store->SetBox(4);
|
||||
store->SetEntry(store->GetEntry() - 1);
|
||||
|
||||
store->SetScreenIndx((store->GetEntry() / 5));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (hRepeat & KEY_UP) {
|
||||
if (store->GetBox() < 5) {
|
||||
if (store->GetEntry() > 4) {
|
||||
store->SetEntry(store->GetEntry() - 5);
|
||||
|
||||
store->SetScreenIndx((store->GetEntry() / 5));
|
||||
}
|
||||
|
||||
} else {
|
||||
store->SetBox(store->GetBox() - 5);
|
||||
store->SetEntry(store->GetEntry() - 5);
|
||||
}
|
||||
}
|
||||
|
||||
if (hDown & KEY_A) {
|
||||
fetch = true;
|
||||
smallDelay = 5;
|
||||
lastMode = currentMode;
|
||||
currentMode = 1;
|
||||
}
|
||||
}
|
||||
}
|
||||
+121
-121
@@ -1,122 +1,122 @@
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#include "storeUtils.hpp"
|
||||
#include "structs.hpp"
|
||||
|
||||
static const std::vector<Structs::ButtonPos> StoreBoxesList = {
|
||||
{ 20, 45, 360, 50 },
|
||||
{ 20, 105, 360, 50 },
|
||||
{ 20, 165, 360, 50 }
|
||||
};
|
||||
|
||||
/*
|
||||
Dessinez la liste du haut.
|
||||
const std::unique_ptr<Store> &store : Const Référence à la classe Store.
|
||||
const std::vector<std::unique_ptr<StoreEntry>> &entries : Const Référence à StoreEntries.
|
||||
*/
|
||||
void StoreUtils::DrawList(const std::unique_ptr<Store> &store, const std::vector<std::unique_ptr<StoreEntry>> &entries) {
|
||||
if (store) { // Assurez-vous que le magasin n’est pas un nullptr.
|
||||
|
||||
if (config->usebg() && store->customBG()) {
|
||||
C2D_DrawImageAt(store->GetStoreImg(), 0, 26, 0.5f, nullptr);
|
||||
|
||||
} else {
|
||||
Gui::Draw_Rect(0, 26, 400, 214, BG_COLOR);
|
||||
}
|
||||
|
||||
if (entries.size() > 0) {
|
||||
for (int i = 0; i < 3 && i < (int)entries.size(); i++) {
|
||||
|
||||
if (i + store->GetScreenIndx() == store->GetEntry()) {
|
||||
GFX::DrawBox(StoreBoxesList[i].x, StoreBoxesList[i].y, StoreBoxesList[i].w, StoreBoxesList[i].h, false);
|
||||
}
|
||||
|
||||
/* Assurez-vous que les entrées sont plus grandes que l’index. */
|
||||
if ((int)entries.size() > i + store->GetScreenIndx()) {
|
||||
if (entries[i + store->GetScreenIndx()]) { // Assurez-vous que l’entrée n’est pas nulle.
|
||||
const C2D_Image tempImg = entries[i + store->GetScreenIndx()]->GetIcon();
|
||||
const uint8_t offsetW = (48 - tempImg.subtex->width) / 2; // Centre W.
|
||||
const uint8_t offsetH = (48 - tempImg.subtex->height) / 2; // Centre H.
|
||||
|
||||
C2D_DrawImageAt(tempImg, StoreBoxesList[i].x + 1 + offsetW, StoreBoxesList[i].y + 1 + offsetH, 0.5);
|
||||
}
|
||||
|
||||
if (entries[i + store->GetScreenIndx()]->GetUpdateAvl()) GFX::DrawSprite(sprites_update_app_idx, StoreBoxesList[i].x + 32, StoreBoxesList[i].y + 32);
|
||||
Gui::DrawStringCentered(29, StoreBoxesList[i].y + 5, 0.6f, TEXT_COLOR, entries[i + store->GetScreenIndx()]->GetTitle(), 300, 0, font);
|
||||
Gui::DrawStringCentered(29, StoreBoxesList[i].y + 24, 0.6f, TEXT_COLOR, entries[i + store->GetScreenIndx()]->GetAuthor(), 300, 0, font);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
Poignée logique de liste supérieure.
|
||||
Ici vous pouvez..
|
||||
- Faites défiler la grille avec le pavé en D vers le haut/vers le bas et sautez 3 entrées avec la gauche/droite.
|
||||
std::unique_ptrStore> &store : Référence à la classe Store.
|
||||
std::vectorstd::unique_ptrStoreEntry>> &entries : Référence à StoreEntries.
|
||||
int ¤tMode : Const Référence au mode actuel.
|
||||
int &lastMode : Référence au dernier mode.
|
||||
bool &fetch : Référence à fetch.
|
||||
int &smallDelay : Référence au petit délai.
|
||||
*/
|
||||
void StoreUtils::ListLogic(std::unique_ptr<Store> &store, std::vector<std::unique_ptr<StoreEntry>> &entries, int ¤tMode, int &lastMode, bool &fetch, int &smallDelay) {
|
||||
if (store) { // Assurez-vous que le magasin n’est pas un nullptr.
|
||||
if (hRepeat & KEY_DOWN) {
|
||||
if (store->GetEntry() < (int)entries.size() - 1) store->SetEntry(store->GetEntry() + 1);
|
||||
else store->SetEntry(0);
|
||||
}
|
||||
|
||||
if (hRepeat & KEY_RIGHT) {
|
||||
if (store->GetEntry() < (int)entries.size() - 3) store->SetEntry(store->GetEntry() + 3);
|
||||
else store->SetEntry(entries.size() - 1);
|
||||
}
|
||||
|
||||
if (hRepeat & KEY_LEFT) {
|
||||
if (store->GetEntry() - 2 > 0) store->SetEntry(store->GetEntry() - 3);
|
||||
else store->SetEntry(0);
|
||||
}
|
||||
|
||||
if (hRepeat & KEY_UP) {
|
||||
if (store->GetEntry() > 0) store->SetEntry(store->GetEntry() - 1);
|
||||
else store->SetEntry(entries.size() - 1);
|
||||
}
|
||||
|
||||
if (hDown & KEY_A) {
|
||||
fetch = true;
|
||||
smallDelay = 5;
|
||||
lastMode = currentMode;
|
||||
currentMode = 1;
|
||||
}
|
||||
|
||||
/* Scroll Logic. */
|
||||
if (store->GetEntry() < store->GetScreenIndx()) store->SetScreenIndx(store->GetEntry());
|
||||
else if (store->GetEntry() > store->GetScreenIndx() + 3 - 1) store->SetScreenIndx(store->GetEntry() - 3 + 1);
|
||||
}
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#include "storeUtils.hpp"
|
||||
#include "structs.hpp"
|
||||
|
||||
static const std::vector<Structs::ButtonPos> StoreBoxesList = {
|
||||
{ 20, 45, 360, 50 },
|
||||
{ 20, 105, 360, 50 },
|
||||
{ 20, 165, 360, 50 }
|
||||
};
|
||||
|
||||
/*
|
||||
Dessinez la liste du haut.
|
||||
const std::unique_ptr<Store> &store : Const Référence à la classe Store.
|
||||
const std::vector<std::unique_ptr<StoreEntry>> &entries : Const Référence à StoreEntries.
|
||||
*/
|
||||
void StoreUtils::DrawList(const std::unique_ptr<Store> &store, const std::vector<std::unique_ptr<StoreEntry>> &entries) {
|
||||
if (store) { // Assurez-vous que le magasin n’est pas un nullptr.
|
||||
|
||||
if (config->usebg() && store->customBG()) {
|
||||
C2D_DrawImageAt(store->GetStoreImg(), 0, 26, 0.5f, nullptr);
|
||||
|
||||
} else {
|
||||
Gui::Draw_Rect(0, 26, 400, 214, BG_COLOR);
|
||||
}
|
||||
|
||||
if (entries.size() > 0) {
|
||||
for (int i = 0; i < 3 && i < (int)entries.size(); i++) {
|
||||
|
||||
if (i + store->GetScreenIndx() == store->GetEntry()) {
|
||||
GFX::DrawBox(StoreBoxesList[i].x, StoreBoxesList[i].y, StoreBoxesList[i].w, StoreBoxesList[i].h, false);
|
||||
}
|
||||
|
||||
/* Assurez-vous que les entrées sont plus grandes que l’index. */
|
||||
if ((int)entries.size() > i + store->GetScreenIndx()) {
|
||||
if (entries[i + store->GetScreenIndx()]) { // Assurez-vous que l’entrée n’est pas nulle.
|
||||
const C2D_Image tempImg = entries[i + store->GetScreenIndx()]->GetIcon();
|
||||
const uint8_t offsetW = (48 - tempImg.subtex->width) / 2; // Centre W.
|
||||
const uint8_t offsetH = (48 - tempImg.subtex->height) / 2; // Centre H.
|
||||
|
||||
C2D_DrawImageAt(tempImg, StoreBoxesList[i].x + 1 + offsetW, StoreBoxesList[i].y + 1 + offsetH, 0.5);
|
||||
}
|
||||
|
||||
if (entries[i + store->GetScreenIndx()]->GetUpdateAvl()) GFX::DrawSprite(sprites_update_app_idx, StoreBoxesList[i].x + 32, StoreBoxesList[i].y + 32);
|
||||
Gui::DrawStringCentered(29, StoreBoxesList[i].y + 5, 0.6f, TEXT_COLOR, entries[i + store->GetScreenIndx()]->GetTitle(), 300, 0, font);
|
||||
Gui::DrawStringCentered(29, StoreBoxesList[i].y + 24, 0.6f, TEXT_COLOR, entries[i + store->GetScreenIndx()]->GetAuthor(), 300, 0, font);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
Poignée logique de liste supérieure.
|
||||
Ici vous pouvez..
|
||||
- Faites défiler la grille avec le pavé en D vers le haut/vers le bas et sautez 3 entrées avec la gauche/droite.
|
||||
std::unique_ptrStore> &store : Référence à la classe Store.
|
||||
std::vectorstd::unique_ptrStoreEntry>> &entries : Référence à StoreEntries.
|
||||
int ¤tMode : Const Référence au mode actuel.
|
||||
int &lastMode : Référence au dernier mode.
|
||||
bool &fetch : Référence à fetch.
|
||||
int &smallDelay : Référence au petit délai.
|
||||
*/
|
||||
void StoreUtils::ListLogic(std::unique_ptr<Store> &store, std::vector<std::unique_ptr<StoreEntry>> &entries, int ¤tMode, int &lastMode, bool &fetch, int &smallDelay) {
|
||||
if (store) { // Assurez-vous que le magasin n’est pas un nullptr.
|
||||
if (hRepeat & KEY_DOWN) {
|
||||
if (store->GetEntry() < (int)entries.size() - 1) store->SetEntry(store->GetEntry() + 1);
|
||||
else store->SetEntry(0);
|
||||
}
|
||||
|
||||
if (hRepeat & KEY_RIGHT) {
|
||||
if (store->GetEntry() < (int)entries.size() - 3) store->SetEntry(store->GetEntry() + 3);
|
||||
else store->SetEntry(entries.size() - 1);
|
||||
}
|
||||
|
||||
if (hRepeat & KEY_LEFT) {
|
||||
if (store->GetEntry() - 2 > 0) store->SetEntry(store->GetEntry() - 3);
|
||||
else store->SetEntry(0);
|
||||
}
|
||||
|
||||
if (hRepeat & KEY_UP) {
|
||||
if (store->GetEntry() > 0) store->SetEntry(store->GetEntry() - 1);
|
||||
else store->SetEntry(entries.size() - 1);
|
||||
}
|
||||
|
||||
if (hDown & KEY_A) {
|
||||
fetch = true;
|
||||
smallDelay = 5;
|
||||
lastMode = currentMode;
|
||||
currentMode = 1;
|
||||
}
|
||||
|
||||
/* Scroll Logic. */
|
||||
if (store->GetEntry() < store->GetScreenIndx()) store->SetScreenIndx(store->GetEntry());
|
||||
else if (store->GetEntry() > store->GetScreenIndx() + 3 - 1) store->SetScreenIndx(store->GetEntry() - 3 + 1);
|
||||
}
|
||||
}
|
||||
+125
-125
@@ -1,126 +1,126 @@
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#include "storeUtils.hpp"
|
||||
#include "structs.hpp"
|
||||
|
||||
extern bool touching(touchPosition touch, Structs::ButtonPos button);
|
||||
static const std::vector<Structs::ButtonPos> markBox = {
|
||||
{ 10, 94, 52, 52 },
|
||||
{ 72, 94, 52, 52 },
|
||||
{ 134, 94, 52, 52 },
|
||||
{ 196, 94, 52, 52 },
|
||||
{ 258, 94, 52, 52 },
|
||||
|
||||
{ 45, 215, 24, 24 }
|
||||
};
|
||||
|
||||
/*
|
||||
Dessinez la partie Marquage.
|
||||
int marks : Les drapeaux de marque actifs.
|
||||
*/
|
||||
void StoreUtils::DisplayMarkBox(int marks) {
|
||||
Gui::Draw_Rect(0, 0, 320, 240, DIM_COLOR); // Assombrir.
|
||||
|
||||
Gui::Draw_Rect(markBox[0].x, markBox[0].y, markBox[0].w, markBox[0].h, (marks & favoriteMarks::STAR ?
|
||||
SIDEBAR_UNSELECTED_COLOR : BOX_INSIDE_COLOR));
|
||||
|
||||
Gui::Draw_Rect(markBox[1].x, markBox[1].y, markBox[1].w, markBox[1].h, (marks & favoriteMarks::HEART ?
|
||||
SIDEBAR_UNSELECTED_COLOR : BOX_INSIDE_COLOR));
|
||||
|
||||
Gui::Draw_Rect(markBox[2].x, markBox[2].y, markBox[2].w, markBox[2].h, (marks & favoriteMarks::DIAMOND ?
|
||||
SIDEBAR_UNSELECTED_COLOR : BOX_INSIDE_COLOR));
|
||||
|
||||
Gui::Draw_Rect(markBox[3].x, markBox[3].y, markBox[3].w, markBox[3].h, (marks & favoriteMarks::CLUBS ?
|
||||
SIDEBAR_UNSELECTED_COLOR : BOX_INSIDE_COLOR));
|
||||
|
||||
Gui::Draw_Rect(markBox[4].x, markBox[4].y, markBox[4].w, markBox[4].h, (marks & favoriteMarks::SPADE ?
|
||||
SIDEBAR_UNSELECTED_COLOR : BOX_INSIDE_COLOR));
|
||||
|
||||
Gui::DrawString(markBox[0].x + 15, markBox[0].y + 11, 0.9, TEXT_COLOR, "★", 0, 0, font);
|
||||
Gui::DrawString(markBox[1].x + 15, markBox[1].y + 11, 0.9, TEXT_COLOR, "♥", 0, 0, font);
|
||||
Gui::DrawString(markBox[2].x + 15, markBox[2].y + 11, 0.9, TEXT_COLOR, "♦", 0, 0, font);
|
||||
Gui::DrawString(markBox[3].x + 15, markBox[3].y + 11, 0.9, TEXT_COLOR, "♣", 0, 0, font);
|
||||
Gui::DrawString(markBox[4].x + 15, markBox[4].y + 11, 0.9, TEXT_COLOR, "♠", 0, 0, font);
|
||||
|
||||
GFX::DrawBox(markBox[5].x, markBox[5].y, markBox[5].w, markBox[5].h, false);
|
||||
Gui::DrawString(markBox[5].x + 5, markBox[5].y + 2, 0.6f, TEXT_COLOR, "★", 0, 0, font);
|
||||
}
|
||||
|
||||
/*
|
||||
Sélectionner la poignée de menu.
|
||||
Ici vous pouvez..
|
||||
- Cochez l’application sélectionnée.
|
||||
- Retournez à EntryInfo avec `B`.
|
||||
std::unique_ptrStoreEntry> &entry : Référence au StoreEntry actuel.
|
||||
const std::unique_ptrStore> &store : Const Référence au Store, puisque nous n’y modifions rien.
|
||||
bool &showMark : Référence à showMark, pour que nous sachions si nous devrions rester ici ou non.
|
||||
std::unique_ptrMeta> &meta : Référence à la classe Meta.
|
||||
*/
|
||||
void StoreUtils::MarkHandle(std::unique_ptr<StoreEntry> &entry, const std::unique_ptr<Store> &store, bool &showMark, std::unique_ptr<Meta> &meta) {
|
||||
hidScanInput();
|
||||
touchPosition t;
|
||||
hidTouchRead(&t);
|
||||
|
||||
if (meta && entry && store) {
|
||||
if (hidKeysDown() & KEY_TOUCH) {
|
||||
/* Etoiles. */
|
||||
if (touching(t, markBox[0])) {
|
||||
meta->SetMarks(store->GetEshopTitle(), entry->GetTitle(),
|
||||
meta->GetMarks(store->GetEshopTitle(), entry->GetTitle()) ^ favoriteMarks::STAR);
|
||||
entry->SetMark(meta->GetMarks(store->GetEshopTitle(), entry->GetTitle()));
|
||||
|
||||
/* Coeur. */
|
||||
} else if (touching(t, markBox[1])) {
|
||||
meta->SetMarks(store->GetEshopTitle(), entry->GetTitle(),
|
||||
meta->GetMarks(store->GetEshopTitle(), entry->GetTitle()) ^ favoriteMarks::HEART);
|
||||
entry->SetMark(meta->GetMarks(store->GetEshopTitle(), entry->GetTitle()));
|
||||
|
||||
/* Diamand. */
|
||||
} else if (touching(t, markBox[2])) {
|
||||
meta->SetMarks(store->GetEshopTitle(), entry->GetTitle(),
|
||||
meta->GetMarks(store->GetEshopTitle(), entry->GetTitle()) ^ favoriteMarks::DIAMOND);
|
||||
entry->SetMark(meta->GetMarks(store->GetEshopTitle(), entry->GetTitle()));
|
||||
|
||||
/* Clubs. */
|
||||
} else if (touching(t, markBox[3])) {
|
||||
meta->SetMarks(store->GetEshopTitle(), entry->GetTitle(),
|
||||
meta->GetMarks(store->GetEshopTitle(), entry->GetTitle()) ^ favoriteMarks::CLUBS);
|
||||
entry->SetMark(meta->GetMarks(store->GetEshopTitle(), entry->GetTitle()));
|
||||
|
||||
/* Spade. */
|
||||
} else if (touching(t, markBox[4])) {
|
||||
meta->SetMarks(store->GetEshopTitle(), entry->GetTitle(),
|
||||
meta->GetMarks(store->GetEshopTitle(), entry->GetTitle()) ^ favoriteMarks::SPADE);
|
||||
|
||||
entry->SetMark(meta->GetMarks(store->GetEshopTitle(), entry->GetTitle()));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
if ((hidKeysDown() & KEY_B || hidKeysDown() & KEY_START) || (hidKeysDown() & KEY_TOUCH && touching(t, markBox[5]))) showMark = false; // Return back to screen.
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#include "storeUtils.hpp"
|
||||
#include "structs.hpp"
|
||||
|
||||
extern bool touching(touchPosition touch, Structs::ButtonPos button);
|
||||
static const std::vector<Structs::ButtonPos> markBox = {
|
||||
{ 10, 94, 52, 52 },
|
||||
{ 72, 94, 52, 52 },
|
||||
{ 134, 94, 52, 52 },
|
||||
{ 196, 94, 52, 52 },
|
||||
{ 258, 94, 52, 52 },
|
||||
|
||||
{ 45, 215, 24, 24 }
|
||||
};
|
||||
|
||||
/*
|
||||
Dessinez la partie Marquage.
|
||||
int marks : Les drapeaux de marque actifs.
|
||||
*/
|
||||
void StoreUtils::DisplayMarkBox(int marks) {
|
||||
Gui::Draw_Rect(0, 0, 320, 240, DIM_COLOR); // Assombrir.
|
||||
|
||||
Gui::Draw_Rect(markBox[0].x, markBox[0].y, markBox[0].w, markBox[0].h, (marks & favoriteMarks::STAR ?
|
||||
SIDEBAR_UNSELECTED_COLOR : BOX_INSIDE_COLOR));
|
||||
|
||||
Gui::Draw_Rect(markBox[1].x, markBox[1].y, markBox[1].w, markBox[1].h, (marks & favoriteMarks::HEART ?
|
||||
SIDEBAR_UNSELECTED_COLOR : BOX_INSIDE_COLOR));
|
||||
|
||||
Gui::Draw_Rect(markBox[2].x, markBox[2].y, markBox[2].w, markBox[2].h, (marks & favoriteMarks::DIAMOND ?
|
||||
SIDEBAR_UNSELECTED_COLOR : BOX_INSIDE_COLOR));
|
||||
|
||||
Gui::Draw_Rect(markBox[3].x, markBox[3].y, markBox[3].w, markBox[3].h, (marks & favoriteMarks::CLUBS ?
|
||||
SIDEBAR_UNSELECTED_COLOR : BOX_INSIDE_COLOR));
|
||||
|
||||
Gui::Draw_Rect(markBox[4].x, markBox[4].y, markBox[4].w, markBox[4].h, (marks & favoriteMarks::SPADE ?
|
||||
SIDEBAR_UNSELECTED_COLOR : BOX_INSIDE_COLOR));
|
||||
|
||||
Gui::DrawString(markBox[0].x + 15, markBox[0].y + 11, 0.9, TEXT_COLOR, "★", 0, 0, font);
|
||||
Gui::DrawString(markBox[1].x + 15, markBox[1].y + 11, 0.9, TEXT_COLOR, "♥", 0, 0, font);
|
||||
Gui::DrawString(markBox[2].x + 15, markBox[2].y + 11, 0.9, TEXT_COLOR, "♦", 0, 0, font);
|
||||
Gui::DrawString(markBox[3].x + 15, markBox[3].y + 11, 0.9, TEXT_COLOR, "♣", 0, 0, font);
|
||||
Gui::DrawString(markBox[4].x + 15, markBox[4].y + 11, 0.9, TEXT_COLOR, "♠", 0, 0, font);
|
||||
|
||||
GFX::DrawBox(markBox[5].x, markBox[5].y, markBox[5].w, markBox[5].h, false);
|
||||
Gui::DrawString(markBox[5].x + 5, markBox[5].y + 2, 0.6f, TEXT_COLOR, "★", 0, 0, font);
|
||||
}
|
||||
|
||||
/*
|
||||
Sélectionner la poignée de menu.
|
||||
Ici vous pouvez..
|
||||
- Cochez l’application sélectionnée.
|
||||
- Retournez à EntryInfo avec `B`.
|
||||
std::unique_ptrStoreEntry> &entry : Référence au StoreEntry actuel.
|
||||
const std::unique_ptrStore> &store : Const Référence au Store, puisque nous n’y modifions rien.
|
||||
bool &showMark : Référence à showMark, pour que nous sachions si nous devrions rester ici ou non.
|
||||
std::unique_ptrMeta> &meta : Référence à la classe Meta.
|
||||
*/
|
||||
void StoreUtils::MarkHandle(std::unique_ptr<StoreEntry> &entry, const std::unique_ptr<Store> &store, bool &showMark, std::unique_ptr<Meta> &meta) {
|
||||
hidScanInput();
|
||||
touchPosition t;
|
||||
hidTouchRead(&t);
|
||||
|
||||
if (meta && entry && store) {
|
||||
if (hidKeysDown() & KEY_TOUCH) {
|
||||
/* Etoiles. */
|
||||
if (touching(t, markBox[0])) {
|
||||
meta->SetMarks(store->GetEshopTitle(), entry->GetTitle(),
|
||||
meta->GetMarks(store->GetEshopTitle(), entry->GetTitle()) ^ favoriteMarks::STAR);
|
||||
entry->SetMark(meta->GetMarks(store->GetEshopTitle(), entry->GetTitle()));
|
||||
|
||||
/* Coeur. */
|
||||
} else if (touching(t, markBox[1])) {
|
||||
meta->SetMarks(store->GetEshopTitle(), entry->GetTitle(),
|
||||
meta->GetMarks(store->GetEshopTitle(), entry->GetTitle()) ^ favoriteMarks::HEART);
|
||||
entry->SetMark(meta->GetMarks(store->GetEshopTitle(), entry->GetTitle()));
|
||||
|
||||
/* Diamand. */
|
||||
} else if (touching(t, markBox[2])) {
|
||||
meta->SetMarks(store->GetEshopTitle(), entry->GetTitle(),
|
||||
meta->GetMarks(store->GetEshopTitle(), entry->GetTitle()) ^ favoriteMarks::DIAMOND);
|
||||
entry->SetMark(meta->GetMarks(store->GetEshopTitle(), entry->GetTitle()));
|
||||
|
||||
/* Clubs. */
|
||||
} else if (touching(t, markBox[3])) {
|
||||
meta->SetMarks(store->GetEshopTitle(), entry->GetTitle(),
|
||||
meta->GetMarks(store->GetEshopTitle(), entry->GetTitle()) ^ favoriteMarks::CLUBS);
|
||||
entry->SetMark(meta->GetMarks(store->GetEshopTitle(), entry->GetTitle()));
|
||||
|
||||
/* Spade. */
|
||||
} else if (touching(t, markBox[4])) {
|
||||
meta->SetMarks(store->GetEshopTitle(), entry->GetTitle(),
|
||||
meta->GetMarks(store->GetEshopTitle(), entry->GetTitle()) ^ favoriteMarks::SPADE);
|
||||
|
||||
entry->SetMark(meta->GetMarks(store->GetEshopTitle(), entry->GetTitle()));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
if ((hidKeysDown() & KEY_B || hidKeysDown() & KEY_START) || (hidKeysDown() & KEY_TOUCH && touching(t, markBox[5]))) showMark = false; // Return back to screen.
|
||||
}
|
||||
+134
-134
@@ -1,135 +1,135 @@
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#include "common.hpp"
|
||||
#include "fileBrowse.hpp"
|
||||
#include "meta.hpp"
|
||||
#include <unistd.h>
|
||||
|
||||
/*
|
||||
Le Constructeur de la Meta.
|
||||
Inclut la création de fichier MetaData, si elle n’existe pas.
|
||||
*/
|
||||
Meta::Meta() {
|
||||
if (access(_META_PATH, F_OK) != 0) {
|
||||
FILE *temp = fopen(_META_PATH, "w");
|
||||
char tmp[2] = { '{', '}' };
|
||||
fwrite(tmp, sizeof(tmp), 1, temp);
|
||||
fclose(temp);
|
||||
}
|
||||
|
||||
FILE *temp = fopen(_META_PATH, "rt");
|
||||
this->metadataJson = nlohmann::json::parse(temp, nullptr, false);
|
||||
fclose(temp);
|
||||
|
||||
if (config->metadata()) this->ImportMetadata();
|
||||
}
|
||||
|
||||
/*
|
||||
Importez les anciennes métadonnées du fichier 'updates.json'.
|
||||
*/
|
||||
void Meta::ImportMetadata() {
|
||||
if (access("sdmc:/3ds/DarkStore/updates.json", F_OK) != 0) {
|
||||
config->metadata(false);
|
||||
return; // Introuvables.
|
||||
}
|
||||
|
||||
Msg::DisplayMsg(Lang::get("FETCHING_METADATA"));
|
||||
FILE *old = fopen("sdmc:/3ds/DarkStore/updates.json", "r");
|
||||
nlohmann::json oldJson = nlohmann::json::parse(old, nullptr, false);
|
||||
fclose(old);
|
||||
|
||||
std::vector<EshopInfo> info = GetEshopInfo(_STORE_PATH); // Va chercher eShop.
|
||||
|
||||
for (int i = 0; i < (int)info.size(); i++) {
|
||||
if (info[i].Title != "" && oldJson.contains(info[i].FileName)) {
|
||||
for(auto it = oldJson[info[i].FileName].begin(); it != oldJson[info[i].FileName].end(); ++it) {
|
||||
this->SetUpdated(info[i].Title, it.key().c_str(), it.value().get<std::string>());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
config->metadata(false);
|
||||
}
|
||||
|
||||
/*
|
||||
Obtenir la dernière mise à jour.
|
||||
const std::string &EshopName : Le nom eShop.
|
||||
const std::string &entry : Le nom de l’entrée.
|
||||
*/
|
||||
std::string Meta::GetUpdated(const std::string &EshopName, const std::string &entry) const {
|
||||
if (!this->metadataJson.contains(EshopName)) return ""; // Le nom de l'eShop n’existe pas.
|
||||
|
||||
if (!this->metadataJson[EshopName].contains(entry)) return ""; // L'entrée n'existe pas.
|
||||
|
||||
if (!this->metadataJson[EshopName][entry].contains("updated")) return ""; // Les mises à jour n'existe pas.
|
||||
|
||||
if (this->metadataJson[EshopName][entry]["updated"].is_string()) return this->metadataJson[EshopName][entry]["updated"];
|
||||
return "";
|
||||
}
|
||||
|
||||
/*
|
||||
Prends les marques.
|
||||
const std::string &EshopName : Le nom eShop.
|
||||
const std::string &entry : Le nom de l’entrée.
|
||||
*/
|
||||
int Meta::GetMarks(const std::string &EshopName, const std::string &entry) const {
|
||||
int temp = 0;
|
||||
|
||||
if (!this->metadataJson.contains(EshopName)) return temp; // Le nom de l'eShop n’existe pas.
|
||||
|
||||
if (!this->metadataJson[EshopName].contains(entry)) return temp; // L'entrée n'existe pas.
|
||||
|
||||
if (!this->metadataJson[EshopName][entry].contains("marks")) return temp; // Les marques n'existe pas.
|
||||
|
||||
if (this->metadataJson[EshopName][entry]["marks"].is_number()) return this->metadataJson[EshopName][entry]["marks"];
|
||||
return temp;
|
||||
}
|
||||
|
||||
/*
|
||||
Retourner, si la mise à jour est disponible.
|
||||
const std::string &EshopName : Le nom eShop.
|
||||
const std::string &entry : Le nom de l’entrée.
|
||||
const std::string &updated : Compare pour la mise à jour.
|
||||
*/
|
||||
bool Meta::UpdateAvailable(const std::string &EshopName, const std::string &entry, const std::string &updated) const {
|
||||
if (this->GetUpdated(EshopName, entry) != "" && updated != "") {
|
||||
return strcasecmp(updated.c_str(), this->GetUpdated(EshopName, entry).c_str()) > 0;
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
/*
|
||||
L’appel de sauvegarde.
|
||||
Ecrire au fichier.. appelé sur destructor.
|
||||
*/
|
||||
void Meta::SaveCall() {
|
||||
FILE *file = fopen(_META_PATH, "wb");
|
||||
const std::string dump = this->metadataJson.dump(1, '\t');
|
||||
fwrite(dump.c_str(), 1, dump.size(), file);
|
||||
fclose(file);
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#include "common.hpp"
|
||||
#include "fileBrowse.hpp"
|
||||
#include "meta.hpp"
|
||||
#include <unistd.h>
|
||||
|
||||
/*
|
||||
Le Constructeur de la Meta.
|
||||
Inclut la création de fichier MetaData, si elle n’existe pas.
|
||||
*/
|
||||
Meta::Meta() {
|
||||
if (access(_META_PATH, F_OK) != 0) {
|
||||
FILE *temp = fopen(_META_PATH, "w");
|
||||
char tmp[2] = { '{', '}' };
|
||||
fwrite(tmp, sizeof(tmp), 1, temp);
|
||||
fclose(temp);
|
||||
}
|
||||
|
||||
FILE *temp = fopen(_META_PATH, "rt");
|
||||
this->metadataJson = nlohmann::json::parse(temp, nullptr, false);
|
||||
fclose(temp);
|
||||
|
||||
if (config->metadata()) this->ImportMetadata();
|
||||
}
|
||||
|
||||
/*
|
||||
Importez les anciennes métadonnées du fichier 'updates.json'.
|
||||
*/
|
||||
void Meta::ImportMetadata() {
|
||||
if (access("sdmc:/3ds/DarkStore/updates.json", F_OK) != 0) {
|
||||
config->metadata(false);
|
||||
return; // Introuvables.
|
||||
}
|
||||
|
||||
Msg::DisplayMsg(Lang::get("FETCHING_METADATA"));
|
||||
FILE *old = fopen("sdmc:/3ds/DarkStore/updates.json", "r");
|
||||
nlohmann::json oldJson = nlohmann::json::parse(old, nullptr, false);
|
||||
fclose(old);
|
||||
|
||||
std::vector<EshopInfo> info = GetEshopInfo(_STORE_PATH); // Va chercher eShop.
|
||||
|
||||
for (int i = 0; i < (int)info.size(); i++) {
|
||||
if (info[i].Title != "" && oldJson.contains(info[i].FileName)) {
|
||||
for(auto it = oldJson[info[i].FileName].begin(); it != oldJson[info[i].FileName].end(); ++it) {
|
||||
this->SetUpdated(info[i].Title, it.key().c_str(), it.value().get<std::string>());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
config->metadata(false);
|
||||
}
|
||||
|
||||
/*
|
||||
Obtenir la dernière mise à jour.
|
||||
const std::string &EshopName : Le nom eShop.
|
||||
const std::string &entry : Le nom de l’entrée.
|
||||
*/
|
||||
std::string Meta::GetUpdated(const std::string &EshopName, const std::string &entry) const {
|
||||
if (!this->metadataJson.contains(EshopName)) return ""; // Le nom de l'eShop n’existe pas.
|
||||
|
||||
if (!this->metadataJson[EshopName].contains(entry)) return ""; // L'entrée n'existe pas.
|
||||
|
||||
if (!this->metadataJson[EshopName][entry].contains("updated")) return ""; // Les mises à jour n'existe pas.
|
||||
|
||||
if (this->metadataJson[EshopName][entry]["updated"].is_string()) return this->metadataJson[EshopName][entry]["updated"];
|
||||
return "";
|
||||
}
|
||||
|
||||
/*
|
||||
Prends les marques.
|
||||
const std::string &EshopName : Le nom eShop.
|
||||
const std::string &entry : Le nom de l’entrée.
|
||||
*/
|
||||
int Meta::GetMarks(const std::string &EshopName, const std::string &entry) const {
|
||||
int temp = 0;
|
||||
|
||||
if (!this->metadataJson.contains(EshopName)) return temp; // Le nom de l'eShop n’existe pas.
|
||||
|
||||
if (!this->metadataJson[EshopName].contains(entry)) return temp; // L'entrée n'existe pas.
|
||||
|
||||
if (!this->metadataJson[EshopName][entry].contains("marks")) return temp; // Les marques n'existe pas.
|
||||
|
||||
if (this->metadataJson[EshopName][entry]["marks"].is_number()) return this->metadataJson[EshopName][entry]["marks"];
|
||||
return temp;
|
||||
}
|
||||
|
||||
/*
|
||||
Retourner, si la mise à jour est disponible.
|
||||
const std::string &EshopName : Le nom eShop.
|
||||
const std::string &entry : Le nom de l’entrée.
|
||||
const std::string &updated : Compare pour la mise à jour.
|
||||
*/
|
||||
bool Meta::UpdateAvailable(const std::string &EshopName, const std::string &entry, const std::string &updated) const {
|
||||
if (this->GetUpdated(EshopName, entry) != "" && updated != "") {
|
||||
return strcasecmp(updated.c_str(), this->GetUpdated(EshopName, entry).c_str()) > 0;
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
/*
|
||||
L’appel de sauvegarde.
|
||||
Ecrire au fichier.. appelé sur destructor.
|
||||
*/
|
||||
void Meta::SaveCall() {
|
||||
FILE *file = fopen(_META_PATH, "wb");
|
||||
const std::string dump = this->metadataJson.dump(1, '\t');
|
||||
fwrite(dump.c_str(), 1, dump.size(), file);
|
||||
fclose(file);
|
||||
}
|
||||
+134
-134
@@ -1,135 +1,135 @@
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#include "queueSystem.hpp"
|
||||
#include "storeUtils.hpp"
|
||||
#include "structs.hpp"
|
||||
#include <curl/curl.h>
|
||||
|
||||
extern u32 extractSize, writeOffset;
|
||||
extern u32 installSize, installOffset;
|
||||
extern u32 copyOffset, copySize;
|
||||
|
||||
extern curl_off_t downloadTotal;
|
||||
extern curl_off_t downloadNow;
|
||||
|
||||
#define QUEUE_ENTRIES 2 // 2 Entries per screen or so.
|
||||
extern bool touching(touchPosition touch, Structs::ButtonPos button);
|
||||
|
||||
/* TODO: Rework positions + sizes.. */
|
||||
static const std::vector<Structs::ButtonPos> QueueBoxes = {
|
||||
{ 46, 32, 266, 80 },
|
||||
{ 46, 132, 266, 80 }
|
||||
};
|
||||
|
||||
extern std::deque<std::unique_ptr<Queue>> queueEntries;
|
||||
|
||||
void DrawStatus(QueueStatus s) {
|
||||
char str[256];
|
||||
|
||||
/* String Handle. */
|
||||
switch(s) {
|
||||
case QueueStatus::None:
|
||||
case QueueStatus::Failed:
|
||||
case QueueStatus::Done:
|
||||
break;
|
||||
|
||||
case QueueStatus::Downloading:
|
||||
if (downloadTotal < 1.0f) downloadTotal = 1.0f;
|
||||
if (downloadTotal < downloadNow) downloadTotal = downloadNow;
|
||||
|
||||
snprintf(str, sizeof(str), "Downloading... %s / %s (%.2f%%)",
|
||||
StringUtils::formatBytes(downloadNow).c_str(),
|
||||
StringUtils::formatBytes(downloadTotal).c_str(),
|
||||
((float)downloadNow/(float)downloadTotal) * 100.0f);
|
||||
break;
|
||||
|
||||
case QueueStatus::Extracting:
|
||||
snprintf(str, sizeof(str), "Extracting... %s / %s (%.2f%%)",
|
||||
StringUtils::formatBytes(writeOffset).c_str(),
|
||||
StringUtils::formatBytes(extractSize).c_str(),
|
||||
((float)writeOffset/(float)extractSize) * 100.0f);
|
||||
break;
|
||||
|
||||
case QueueStatus::Installing:
|
||||
snprintf(str, sizeof(str), "Installing... %s / %s (%.2f%%)",
|
||||
StringUtils::formatBytes(installOffset).c_str(),
|
||||
StringUtils::formatBytes(installSize).c_str(),
|
||||
((float)installOffset/(float)installSize) * 100.0f);
|
||||
break;
|
||||
}
|
||||
|
||||
/* Draw Handle. */
|
||||
switch(s) {
|
||||
case QueueStatus::None:
|
||||
case QueueStatus::Failed:
|
||||
case QueueStatus::Done:
|
||||
break;
|
||||
|
||||
case QueueStatus::Downloading:
|
||||
Gui::DrawString(QueueBoxes[0].x + 10, QueueBoxes[0].y + 5, 0.4f, TEXT_COLOR, str, 250, 0, font);
|
||||
|
||||
Gui::Draw_Rect(QueueBoxes[0].x + 60, QueueBoxes[0].y + 25, 180, 30, BLACK);
|
||||
Gui::Draw_Rect(QueueBoxes[0].x + 60 + 1, QueueBoxes[0].y + 25 + 1, (int)(((float)downloadNow / (float)downloadTotal) * 180.0f), 28, WHITE);
|
||||
break;
|
||||
|
||||
case QueueStatus::Extracting:
|
||||
Gui::DrawString(QueueBoxes[0].x + 10, QueueBoxes[0].y + 5, 0.4f, TEXT_COLOR, str, 250, 0, font);
|
||||
|
||||
Gui::Draw_Rect(QueueBoxes[0].x + 60, QueueBoxes[0].y + 25, 180, 30, BLACK);
|
||||
Gui::Draw_Rect(QueueBoxes[0].x + 60 + 1, QueueBoxes[0].y + 25 + 1, (int)(((float)writeOffset / (float)extractSize) * 180.0f), 28, WHITE);
|
||||
break;
|
||||
|
||||
case QueueStatus::Installing:
|
||||
Gui::DrawString(QueueBoxes[0].x + 10, QueueBoxes[0].y + 5, 0.4f, TEXT_COLOR, str, 250, 0, font);
|
||||
|
||||
Gui::Draw_Rect(QueueBoxes[0].x + 60, QueueBoxes[0].y + 25, 180, 30, BLACK);
|
||||
Gui::Draw_Rect(QueueBoxes[0].x + 60 + 1, QueueBoxes[0].y + 25 + 1, (int)(((float)installOffset / (float)installSize) * 180.0f), 28, WHITE);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
void StoreUtils::DrawQueueMenu(const int queueIndex) {
|
||||
Gui::Draw_Rect(40, 0, 280, 25, ENTRY_BAR_COLOR);
|
||||
Gui::Draw_Rect(40, 25, 280, 1, ENTRY_BAR_OUTL_COLOR);
|
||||
Gui::DrawStringCentered(17, 2, 0.6, TEXT_COLOR, "Queue System", 273, 0, font);
|
||||
|
||||
LightLock_Lock(&QueueSystem::lock);
|
||||
|
||||
if (!queueEntries.empty()) {
|
||||
GFX::DrawBox(QueueBoxes[0].x, QueueBoxes[0].y, QueueBoxes[0].w, QueueBoxes[0].h, false);
|
||||
|
||||
C2D_DrawImageAt(queueEntries[0]->icn, QueueBoxes[0].x + 5, QueueBoxes[0].y + 21, 0.5f);
|
||||
DrawStatus(queueEntries[0]->status);
|
||||
}
|
||||
|
||||
LightLock_Unlock(&QueueSystem::lock);
|
||||
}
|
||||
|
||||
void StoreUtils::QueueMenuHandle(int &queueIndex) {
|
||||
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#include "queueSystem.hpp"
|
||||
#include "storeUtils.hpp"
|
||||
#include "structs.hpp"
|
||||
#include <curl/curl.h>
|
||||
|
||||
extern u32 extractSize, writeOffset;
|
||||
extern u32 installSize, installOffset;
|
||||
extern u32 copyOffset, copySize;
|
||||
|
||||
extern curl_off_t downloadTotal;
|
||||
extern curl_off_t downloadNow;
|
||||
|
||||
#define QUEUE_ENTRIES 2 // 2 Entries per screen or so.
|
||||
extern bool touching(touchPosition touch, Structs::ButtonPos button);
|
||||
|
||||
/* TODO: Rework positions + sizes.. */
|
||||
static const std::vector<Structs::ButtonPos> QueueBoxes = {
|
||||
{ 46, 32, 266, 80 },
|
||||
{ 46, 132, 266, 80 }
|
||||
};
|
||||
|
||||
extern std::deque<std::unique_ptr<Queue>> queueEntries;
|
||||
|
||||
void DrawStatus(QueueStatus s) {
|
||||
char str[256];
|
||||
|
||||
/* String Handle. */
|
||||
switch(s) {
|
||||
case QueueStatus::None:
|
||||
case QueueStatus::Failed:
|
||||
case QueueStatus::Done:
|
||||
break;
|
||||
|
||||
case QueueStatus::Downloading:
|
||||
if (downloadTotal < 1.0f) downloadTotal = 1.0f;
|
||||
if (downloadTotal < downloadNow) downloadTotal = downloadNow;
|
||||
|
||||
snprintf(str, sizeof(str), "Downloading... %s / %s (%.2f%%)",
|
||||
StringUtils::formatBytes(downloadNow).c_str(),
|
||||
StringUtils::formatBytes(downloadTotal).c_str(),
|
||||
((float)downloadNow/(float)downloadTotal) * 100.0f);
|
||||
break;
|
||||
|
||||
case QueueStatus::Extracting:
|
||||
snprintf(str, sizeof(str), "Extracting... %s / %s (%.2f%%)",
|
||||
StringUtils::formatBytes(writeOffset).c_str(),
|
||||
StringUtils::formatBytes(extractSize).c_str(),
|
||||
((float)writeOffset/(float)extractSize) * 100.0f);
|
||||
break;
|
||||
|
||||
case QueueStatus::Installing:
|
||||
snprintf(str, sizeof(str), "Installing... %s / %s (%.2f%%)",
|
||||
StringUtils::formatBytes(installOffset).c_str(),
|
||||
StringUtils::formatBytes(installSize).c_str(),
|
||||
((float)installOffset/(float)installSize) * 100.0f);
|
||||
break;
|
||||
}
|
||||
|
||||
/* Draw Handle. */
|
||||
switch(s) {
|
||||
case QueueStatus::None:
|
||||
case QueueStatus::Failed:
|
||||
case QueueStatus::Done:
|
||||
break;
|
||||
|
||||
case QueueStatus::Downloading:
|
||||
Gui::DrawString(QueueBoxes[0].x + 10, QueueBoxes[0].y + 5, 0.4f, TEXT_COLOR, str, 250, 0, font);
|
||||
|
||||
Gui::Draw_Rect(QueueBoxes[0].x + 60, QueueBoxes[0].y + 25, 180, 30, BLACK);
|
||||
Gui::Draw_Rect(QueueBoxes[0].x + 60 + 1, QueueBoxes[0].y + 25 + 1, (int)(((float)downloadNow / (float)downloadTotal) * 180.0f), 28, WHITE);
|
||||
break;
|
||||
|
||||
case QueueStatus::Extracting:
|
||||
Gui::DrawString(QueueBoxes[0].x + 10, QueueBoxes[0].y + 5, 0.4f, TEXT_COLOR, str, 250, 0, font);
|
||||
|
||||
Gui::Draw_Rect(QueueBoxes[0].x + 60, QueueBoxes[0].y + 25, 180, 30, BLACK);
|
||||
Gui::Draw_Rect(QueueBoxes[0].x + 60 + 1, QueueBoxes[0].y + 25 + 1, (int)(((float)writeOffset / (float)extractSize) * 180.0f), 28, WHITE);
|
||||
break;
|
||||
|
||||
case QueueStatus::Installing:
|
||||
Gui::DrawString(QueueBoxes[0].x + 10, QueueBoxes[0].y + 5, 0.4f, TEXT_COLOR, str, 250, 0, font);
|
||||
|
||||
Gui::Draw_Rect(QueueBoxes[0].x + 60, QueueBoxes[0].y + 25, 180, 30, BLACK);
|
||||
Gui::Draw_Rect(QueueBoxes[0].x + 60 + 1, QueueBoxes[0].y + 25 + 1, (int)(((float)installOffset / (float)installSize) * 180.0f), 28, WHITE);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
void StoreUtils::DrawQueueMenu(const int queueIndex) {
|
||||
Gui::Draw_Rect(40, 0, 280, 25, ENTRY_BAR_COLOR);
|
||||
Gui::Draw_Rect(40, 25, 280, 1, ENTRY_BAR_OUTL_COLOR);
|
||||
Gui::DrawStringCentered(17, 2, 0.6, TEXT_COLOR, "Queue System", 273, 0, font);
|
||||
|
||||
LightLock_Lock(&QueueSystem::lock);
|
||||
|
||||
if (!queueEntries.empty()) {
|
||||
GFX::DrawBox(QueueBoxes[0].x, QueueBoxes[0].y, QueueBoxes[0].w, QueueBoxes[0].h, false);
|
||||
|
||||
C2D_DrawImageAt(queueEntries[0]->icn, QueueBoxes[0].x + 5, QueueBoxes[0].y + 21, 0.5f);
|
||||
DrawStatus(queueEntries[0]->status);
|
||||
}
|
||||
|
||||
LightLock_Unlock(&QueueSystem::lock);
|
||||
}
|
||||
|
||||
void StoreUtils::QueueMenuHandle(int &queueIndex) {
|
||||
|
||||
}
|
||||
+117
-117
@@ -1,118 +1,118 @@
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#include "download.hpp"
|
||||
#include "storeUtils.hpp"
|
||||
|
||||
void StoreUtils::DrawReleaseNotes(const int &scrollIndex, const std::unique_ptr<StoreEntry> &entry, const std::unique_ptr<Store> &store) {
|
||||
if (entry && store) {
|
||||
Gui::ScreenDraw(Top);
|
||||
Gui::Draw_Rect(0, 26, 400, 214, BG_COLOR);
|
||||
Gui::DrawString(5, 25 - scrollIndex, 0.5f, TEXT_COLOR, entry->GetReleaseNotes(), 390, 0, font, C2D_WordWrap);
|
||||
Gui::Draw_Rect(0, 0, 400, 25, BAR_COLOR);
|
||||
Gui::Draw_Rect(0, 25, 400, 1, BAR_OUTL_COLOR);
|
||||
Gui::DrawStringCentered(0, 1, 0.7f, TEXT_COLOR, entry->GetTitle(), 390, 0, font);
|
||||
|
||||
} else {
|
||||
Gui::ScreenDraw(Top);
|
||||
Gui::Draw_Rect(0, 0, 400, 25, BAR_COLOR);
|
||||
Gui::Draw_Rect(0, 25, 400, 1, BAR_OUTL_COLOR);
|
||||
Gui::Draw_Rect(0, 26, 400, 214, BG_COLOR);
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
As the name says: Release notes logic.
|
||||
|
||||
int &scrollIndex: The scroll index for the Release Notes text.
|
||||
int &storeMode: The store mode to properly return back.
|
||||
*/
|
||||
void StoreUtils::ReleaseNotesLogic(int &scrollIndex, int &storeMode) {
|
||||
if (hRepeat & KEY_DOWN) scrollIndex += Gui::GetStringHeight(0.5f, "", font);
|
||||
|
||||
if (hRepeat & KEY_UP) {
|
||||
if (scrollIndex > 0) scrollIndex -= Gui::GetStringHeight(0.5f, "", font);
|
||||
}
|
||||
|
||||
if (hDown & KEY_B) {
|
||||
scrollIndex = 0;
|
||||
storeMode = 0;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
I place it temporarely here for now.
|
||||
|
||||
Display Release changelog for DarkStore.
|
||||
*/
|
||||
void DisplayChangelog() {
|
||||
if (config->changelog()) {
|
||||
config->changelog(false);
|
||||
|
||||
bool confirmed = false;
|
||||
const std::string notes = GetChangelog();
|
||||
if (notes == "") return;
|
||||
int scrollIndex = 0;
|
||||
|
||||
while(!confirmed) {
|
||||
Gui::clearTextBufs();
|
||||
C3D_FrameBegin(C3D_FRAME_SYNCDRAW);
|
||||
C2D_TargetClear(Top, C2D_Color32(0, 0, 0, 0));
|
||||
C2D_TargetClear(Bottom, C2D_Color32(0, 0, 0, 0));
|
||||
|
||||
Gui::ScreenDraw(Top);
|
||||
Gui::Draw_Rect(0, 26, 400, 214, BG_COLOR);
|
||||
Gui::DrawString(5, 25 - scrollIndex, 0.5f, TEXT_COLOR, notes, 390, 0, font, C2D_WordWrap);
|
||||
Gui::Draw_Rect(0, 0, 400, 25, BAR_COLOR);
|
||||
Gui::Draw_Rect(0, 25, 400, 1, BAR_OUTL_COLOR);
|
||||
Gui::DrawStringCentered(0, 1, 0.7f, TEXT_COLOR, "DarkStore", 390, 0, font);
|
||||
Gui::Draw_Rect(0, 215, 400, 25, BAR_COLOR);
|
||||
Gui::Draw_Rect(0, 214, 400, 1, BAR_OUTL_COLOR);
|
||||
Gui::DrawStringCentered(0, 217, 0.7f, TEXT_COLOR, C_V, 390, 0, font);
|
||||
|
||||
GFX::DrawBottom();
|
||||
Gui::Draw_Rect(0, 0, 320, 25, BAR_COLOR);
|
||||
Gui::Draw_Rect(0, 25, 320, 1, BAR_OUTL_COLOR);
|
||||
C3D_FrameEnd(0);
|
||||
|
||||
hidScanInput();
|
||||
touchPosition t;
|
||||
touchRead(&t);
|
||||
u32 repeat = hidKeysDownRepeat();
|
||||
u32 down = hidKeysDown();
|
||||
|
||||
/* Scroll Logic. */
|
||||
if (repeat & KEY_DOWN) scrollIndex += Gui::GetStringHeight(0.5f, "", font);
|
||||
|
||||
if (repeat & KEY_UP) {
|
||||
if (scrollIndex > 0) scrollIndex -= Gui::GetStringHeight(0.5f, "", font);
|
||||
}
|
||||
|
||||
if ((down & KEY_A) || (down & KEY_B) || (down & KEY_START) || (down & KEY_TOUCH)) confirmed = true;
|
||||
}
|
||||
}
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#include "download.hpp"
|
||||
#include "storeUtils.hpp"
|
||||
|
||||
void StoreUtils::DrawReleaseNotes(const int &scrollIndex, const std::unique_ptr<StoreEntry> &entry, const std::unique_ptr<Store> &store) {
|
||||
if (entry && store) {
|
||||
Gui::ScreenDraw(Top);
|
||||
Gui::Draw_Rect(0, 26, 400, 214, BG_COLOR);
|
||||
Gui::DrawString(5, 25 - scrollIndex, 0.5f, TEXT_COLOR, entry->GetReleaseNotes(), 390, 0, font, C2D_WordWrap);
|
||||
Gui::Draw_Rect(0, 0, 400, 25, BAR_COLOR);
|
||||
Gui::Draw_Rect(0, 25, 400, 1, BAR_OUTL_COLOR);
|
||||
Gui::DrawStringCentered(0, 1, 0.7f, TEXT_COLOR, entry->GetTitle(), 390, 0, font);
|
||||
|
||||
} else {
|
||||
Gui::ScreenDraw(Top);
|
||||
Gui::Draw_Rect(0, 0, 400, 25, BAR_COLOR);
|
||||
Gui::Draw_Rect(0, 25, 400, 1, BAR_OUTL_COLOR);
|
||||
Gui::Draw_Rect(0, 26, 400, 214, BG_COLOR);
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
As the name says: Release notes logic.
|
||||
|
||||
int &scrollIndex: The scroll index for the Release Notes text.
|
||||
int &storeMode: The store mode to properly return back.
|
||||
*/
|
||||
void StoreUtils::ReleaseNotesLogic(int &scrollIndex, int &storeMode) {
|
||||
if (hRepeat & KEY_DOWN) scrollIndex += Gui::GetStringHeight(0.5f, "", font);
|
||||
|
||||
if (hRepeat & KEY_UP) {
|
||||
if (scrollIndex > 0) scrollIndex -= Gui::GetStringHeight(0.5f, "", font);
|
||||
}
|
||||
|
||||
if (hDown & KEY_B) {
|
||||
scrollIndex = 0;
|
||||
storeMode = 0;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
I place it temporarely here for now.
|
||||
|
||||
Display Release changelog for DarkStore.
|
||||
*/
|
||||
void DisplayChangelog() {
|
||||
if (config->changelog()) {
|
||||
config->changelog(false);
|
||||
|
||||
bool confirmed = false;
|
||||
const std::string notes = GetChangelog();
|
||||
if (notes == "") return;
|
||||
int scrollIndex = 0;
|
||||
|
||||
while(!confirmed) {
|
||||
Gui::clearTextBufs();
|
||||
C3D_FrameBegin(C3D_FRAME_SYNCDRAW);
|
||||
C2D_TargetClear(Top, C2D_Color32(0, 0, 0, 0));
|
||||
C2D_TargetClear(Bottom, C2D_Color32(0, 0, 0, 0));
|
||||
|
||||
Gui::ScreenDraw(Top);
|
||||
Gui::Draw_Rect(0, 26, 400, 214, BG_COLOR);
|
||||
Gui::DrawString(5, 25 - scrollIndex, 0.5f, TEXT_COLOR, notes, 390, 0, font, C2D_WordWrap);
|
||||
Gui::Draw_Rect(0, 0, 400, 25, BAR_COLOR);
|
||||
Gui::Draw_Rect(0, 25, 400, 1, BAR_OUTL_COLOR);
|
||||
Gui::DrawStringCentered(0, 1, 0.7f, TEXT_COLOR, "DarkStore", 390, 0, font);
|
||||
Gui::Draw_Rect(0, 215, 400, 25, BAR_COLOR);
|
||||
Gui::Draw_Rect(0, 214, 400, 1, BAR_OUTL_COLOR);
|
||||
Gui::DrawStringCentered(0, 217, 0.7f, TEXT_COLOR, C_V, 390, 0, font);
|
||||
|
||||
GFX::DrawBottom();
|
||||
Gui::Draw_Rect(0, 0, 320, 25, BAR_COLOR);
|
||||
Gui::Draw_Rect(0, 25, 320, 1, BAR_OUTL_COLOR);
|
||||
C3D_FrameEnd(0);
|
||||
|
||||
hidScanInput();
|
||||
touchPosition t;
|
||||
touchRead(&t);
|
||||
u32 repeat = hidKeysDownRepeat();
|
||||
u32 down = hidKeysDown();
|
||||
|
||||
/* Scroll Logic. */
|
||||
if (repeat & KEY_DOWN) scrollIndex += Gui::GetStringHeight(0.5f, "", font);
|
||||
|
||||
if (repeat & KEY_UP) {
|
||||
if (scrollIndex > 0) scrollIndex -= Gui::GetStringHeight(0.5f, "", font);
|
||||
}
|
||||
|
||||
if ((down & KEY_A) || (down & KEY_B) || (down & KEY_START) || (down & KEY_TOUCH)) confirmed = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
+150
-150
@@ -1,151 +1,151 @@
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#include "storeUtils.hpp"
|
||||
#include "structs.hpp"
|
||||
|
||||
extern bool touching(touchPosition touch, Structs::ButtonPos button);
|
||||
extern bool checkWifiStatus();
|
||||
|
||||
/*
|
||||
Draw the Screenshot menu.
|
||||
|
||||
const C2D_Image &img: The C2D_Image of the screenshot.
|
||||
const int sIndex: The Screenshot index.
|
||||
const bool sFetch: If fetching screenshots or not.
|
||||
const int screenshotSize: The screenshot amount.
|
||||
const std::string &name: The name of the screenshot.
|
||||
const int zoom: The zoom level, zoom out, 1x scale, or zoom in.
|
||||
const bool canDisplay: If can display, or not.
|
||||
*/
|
||||
void StoreUtils::DrawScreenshotMenu(const C2D_Image &img, const int sIndex, const bool sFetch, const int screenshotSize, const std::string &name, const int zoom, const bool canDisplay) {
|
||||
Gui::ScreenDraw(Top);
|
||||
Gui::Draw_Rect(0, 0, 400, 240, BG_COLOR);
|
||||
|
||||
if (!canDisplay) {
|
||||
GFX::DrawBottom();
|
||||
if (screenshotSize > 0) { // if texture is nullptr AND screenshot size is larger than 0.
|
||||
Gui::DrawStringCentered(0, 2, 0.6f, WHITE, Lang::get("SCREENSHOT_COULD_NOT_LOAD"), 310);
|
||||
|
||||
} else {
|
||||
Gui::DrawStringCentered(0, 2, 0.6f, WHITE, Lang::get("NO_SCREENSHOTS_AVAILABLE"), 310);
|
||||
}
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
if (!sFetch) { // Only, if not fetch. This avoids a small flicker of the old screenshot on entries without screenshots.
|
||||
if (screenshotSize > 0) {
|
||||
float scale = 1.0f;
|
||||
|
||||
if (zoom == 0) {
|
||||
scale = std::min(1.0f, std::min(400.0f / img.subtex->width, 240.0f / img.subtex->height));
|
||||
if (img.tex) C2D_DrawImageAt(img, (400 - img.subtex->width * scale) / 2, (240 - img.subtex->height * scale) / 2, 0.5f, nullptr, scale, scale);
|
||||
|
||||
} else {
|
||||
// Create new C2D_Image with smaller subtex
|
||||
C2D_Image top = img;
|
||||
if (img.subtex->height > 240)
|
||||
top.subtex = new Tex3DS_SubTexture({img.subtex->width, (u16)(img.subtex->height / 2), img.subtex->left, img.subtex->top, img.subtex->right, 1.0f - (img.subtex->height / 2 / 512.0f)});
|
||||
|
||||
// If zoom == 2, then zoom in to fit the screen
|
||||
if (zoom == 2)
|
||||
scale = std::min(400.0f / top.subtex->width, 240.0f / top.subtex->height);
|
||||
|
||||
if (top.tex) C2D_DrawImageAt(top, (400 - top.subtex->width * scale) / 2, (240 - top.subtex->height * scale) / 2, 0.5f, nullptr, scale, scale);
|
||||
|
||||
// Only delete if new
|
||||
if (top.subtex->height > 240)
|
||||
delete top.subtex;
|
||||
}
|
||||
|
||||
GFX::DrawBottom();
|
||||
|
||||
/* Bottom. */
|
||||
if (zoom > 0 && img.subtex->height * scale > 240) {
|
||||
C2D_Image bottom = img;
|
||||
bottom.subtex = new Tex3DS_SubTexture({img.subtex->width, (u16)(img.subtex->height / 2), img.subtex->left, img.subtex->bottom + (img.subtex->height / 2 / 512.0f), img.subtex->right, img.subtex->bottom});
|
||||
if (bottom.tex) C2D_DrawImageAt(bottom, (320 - bottom.subtex->width * scale) / 2, (240 - bottom.subtex->height * scale) / 2, 0.5f, nullptr, scale, scale);
|
||||
delete bottom.subtex;
|
||||
|
||||
} else {
|
||||
Gui::Draw_Rect(0, 215, 320, 25, BAR_COLOR);
|
||||
Gui::Draw_Rect(0, 214, 320, 1, BAR_OUTL_COLOR);
|
||||
Gui::DrawStringCentered(0, 220, 0.5f, TEXT_COLOR, Lang::get("SCREENSHOT_INSTRUCTIONS"), 310, 0, font);
|
||||
|
||||
char screenshots[0x100];
|
||||
snprintf(screenshots, sizeof(screenshots), Lang::get("SCREENSHOT").c_str(), sIndex + 1, screenshotSize);
|
||||
Gui::DrawStringCentered(0, 2, 0.6f, WHITE, screenshots, 310, 0, font);
|
||||
Gui::DrawStringCentered(0, 40, 0.6f, WHITE, name, 310, 0, font);
|
||||
}
|
||||
|
||||
} else {
|
||||
GFX::DrawBottom();
|
||||
Gui::DrawStringCentered(0, 2, 0.6f, WHITE, Lang::get("NO_SCREENSHOTS_AVAILABLE"), 310);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
Screenshot Menu handle.
|
||||
|
||||
C2D_Image &img: The C2D_Image of the screenshot.
|
||||
int &sIndex: The Screenshot index.
|
||||
bool &sFetch: If fetching screenshots or not.
|
||||
const int screenshotSize: The screenshot amount.
|
||||
int &zoom: The zoom level, zoom out, 1x scale, or zoom in.
|
||||
bool &canDisplay: If can display or not.
|
||||
*/
|
||||
void StoreUtils::ScreenshotMenu(C2D_Image &img, int &sIndex, bool &sFetch, int &storeMode, const int screenshotSize, int &zoom, bool &canDisplay) {
|
||||
if (hDown & KEY_B) {
|
||||
canDisplay = false;
|
||||
zoom = 0;
|
||||
sIndex = 0;
|
||||
storeMode = 0; // Go back to EntryInfo.
|
||||
}
|
||||
|
||||
if ((hDown & KEY_RIGHT) || (hDown & KEY_R)) {
|
||||
if (checkWifiStatus()) {
|
||||
if (sIndex < screenshotSize - 1) {
|
||||
sIndex++;
|
||||
sFetch = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (hDown & KEY_DOWN && zoom > 0) zoom--;
|
||||
|
||||
if (hDown & KEY_UP && zoom < 2) zoom++;
|
||||
|
||||
if ((hDown & KEY_LEFT) || (hDown & KEY_L)) {
|
||||
if (checkWifiStatus()) {
|
||||
if (sIndex > 0) {
|
||||
sIndex--;
|
||||
sFetch = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#include "storeUtils.hpp"
|
||||
#include "structs.hpp"
|
||||
|
||||
extern bool touching(touchPosition touch, Structs::ButtonPos button);
|
||||
extern bool checkWifiStatus();
|
||||
|
||||
/*
|
||||
Draw the Screenshot menu.
|
||||
|
||||
const C2D_Image &img: The C2D_Image of the screenshot.
|
||||
const int sIndex: The Screenshot index.
|
||||
const bool sFetch: If fetching screenshots or not.
|
||||
const int screenshotSize: The screenshot amount.
|
||||
const std::string &name: The name of the screenshot.
|
||||
const int zoom: The zoom level, zoom out, 1x scale, or zoom in.
|
||||
const bool canDisplay: If can display, or not.
|
||||
*/
|
||||
void StoreUtils::DrawScreenshotMenu(const C2D_Image &img, const int sIndex, const bool sFetch, const int screenshotSize, const std::string &name, const int zoom, const bool canDisplay) {
|
||||
Gui::ScreenDraw(Top);
|
||||
Gui::Draw_Rect(0, 0, 400, 240, BG_COLOR);
|
||||
|
||||
if (!canDisplay) {
|
||||
GFX::DrawBottom();
|
||||
if (screenshotSize > 0) { // if texture is nullptr AND screenshot size is larger than 0.
|
||||
Gui::DrawStringCentered(0, 2, 0.6f, WHITE, Lang::get("SCREENSHOT_COULD_NOT_LOAD"), 310);
|
||||
|
||||
} else {
|
||||
Gui::DrawStringCentered(0, 2, 0.6f, WHITE, Lang::get("NO_SCREENSHOTS_AVAILABLE"), 310);
|
||||
}
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
if (!sFetch) { // Only, if not fetch. This avoids a small flicker of the old screenshot on entries without screenshots.
|
||||
if (screenshotSize > 0) {
|
||||
float scale = 1.0f;
|
||||
|
||||
if (zoom == 0) {
|
||||
scale = std::min(1.0f, std::min(400.0f / img.subtex->width, 240.0f / img.subtex->height));
|
||||
if (img.tex) C2D_DrawImageAt(img, (400 - img.subtex->width * scale) / 2, (240 - img.subtex->height * scale) / 2, 0.5f, nullptr, scale, scale);
|
||||
|
||||
} else {
|
||||
// Create new C2D_Image with smaller subtex
|
||||
C2D_Image top = img;
|
||||
if (img.subtex->height > 240)
|
||||
top.subtex = new Tex3DS_SubTexture({img.subtex->width, (u16)(img.subtex->height / 2), img.subtex->left, img.subtex->top, img.subtex->right, 1.0f - (img.subtex->height / 2 / 512.0f)});
|
||||
|
||||
// If zoom == 2, then zoom in to fit the screen
|
||||
if (zoom == 2)
|
||||
scale = std::min(400.0f / top.subtex->width, 240.0f / top.subtex->height);
|
||||
|
||||
if (top.tex) C2D_DrawImageAt(top, (400 - top.subtex->width * scale) / 2, (240 - top.subtex->height * scale) / 2, 0.5f, nullptr, scale, scale);
|
||||
|
||||
// Only delete if new
|
||||
if (top.subtex->height > 240)
|
||||
delete top.subtex;
|
||||
}
|
||||
|
||||
GFX::DrawBottom();
|
||||
|
||||
/* Bottom. */
|
||||
if (zoom > 0 && img.subtex->height * scale > 240) {
|
||||
C2D_Image bottom = img;
|
||||
bottom.subtex = new Tex3DS_SubTexture({img.subtex->width, (u16)(img.subtex->height / 2), img.subtex->left, img.subtex->bottom + (img.subtex->height / 2 / 512.0f), img.subtex->right, img.subtex->bottom});
|
||||
if (bottom.tex) C2D_DrawImageAt(bottom, (320 - bottom.subtex->width * scale) / 2, (240 - bottom.subtex->height * scale) / 2, 0.5f, nullptr, scale, scale);
|
||||
delete bottom.subtex;
|
||||
|
||||
} else {
|
||||
Gui::Draw_Rect(0, 215, 320, 25, BAR_COLOR);
|
||||
Gui::Draw_Rect(0, 214, 320, 1, BAR_OUTL_COLOR);
|
||||
Gui::DrawStringCentered(0, 220, 0.5f, TEXT_COLOR, Lang::get("SCREENSHOT_INSTRUCTIONS"), 310, 0, font);
|
||||
|
||||
char screenshots[0x100];
|
||||
snprintf(screenshots, sizeof(screenshots), Lang::get("SCREENSHOT").c_str(), sIndex + 1, screenshotSize);
|
||||
Gui::DrawStringCentered(0, 2, 0.6f, WHITE, screenshots, 310, 0, font);
|
||||
Gui::DrawStringCentered(0, 40, 0.6f, WHITE, name, 310, 0, font);
|
||||
}
|
||||
|
||||
} else {
|
||||
GFX::DrawBottom();
|
||||
Gui::DrawStringCentered(0, 2, 0.6f, WHITE, Lang::get("NO_SCREENSHOTS_AVAILABLE"), 310);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
Screenshot Menu handle.
|
||||
|
||||
C2D_Image &img: The C2D_Image of the screenshot.
|
||||
int &sIndex: The Screenshot index.
|
||||
bool &sFetch: If fetching screenshots or not.
|
||||
const int screenshotSize: The screenshot amount.
|
||||
int &zoom: The zoom level, zoom out, 1x scale, or zoom in.
|
||||
bool &canDisplay: If can display or not.
|
||||
*/
|
||||
void StoreUtils::ScreenshotMenu(C2D_Image &img, int &sIndex, bool &sFetch, int &storeMode, const int screenshotSize, int &zoom, bool &canDisplay) {
|
||||
if (hDown & KEY_B) {
|
||||
canDisplay = false;
|
||||
zoom = 0;
|
||||
sIndex = 0;
|
||||
storeMode = 0; // Go back to EntryInfo.
|
||||
}
|
||||
|
||||
if ((hDown & KEY_RIGHT) || (hDown & KEY_R)) {
|
||||
if (checkWifiStatus()) {
|
||||
if (sIndex < screenshotSize - 1) {
|
||||
sIndex++;
|
||||
sFetch = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (hDown & KEY_DOWN && zoom > 0) zoom--;
|
||||
|
||||
if (hDown & KEY_UP && zoom < 2) zoom++;
|
||||
|
||||
if ((hDown & KEY_LEFT) || (hDown & KEY_L)) {
|
||||
if (checkWifiStatus()) {
|
||||
if (sIndex > 0) {
|
||||
sIndex--;
|
||||
sFetch = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
+203
-203
@@ -1,204 +1,204 @@
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#include "keyboard.hpp"
|
||||
#include "storeUtils.hpp"
|
||||
#include "structs.hpp"
|
||||
|
||||
extern bool touching(touchPosition touch, Structs::ButtonPos button);
|
||||
static const std::vector<Structs::ButtonPos> SearchMenu = {
|
||||
{ 51, 45, 262, 30 }, // Search bar.
|
||||
|
||||
/* Inclure. */
|
||||
{ 85, 109, 50, 10 },
|
||||
{ 85, 125, 50, 10 },
|
||||
{ 167, 109, 50, 10 },
|
||||
{ 167, 125, 50, 10 },
|
||||
|
||||
/* Filtrer. */
|
||||
{ 82, 195, 30, 30 },
|
||||
{ 117, 195, 30, 30 },
|
||||
{ 152, 195, 30, 30 },
|
||||
{ 187, 195, 30, 30 },
|
||||
{ 222, 195, 30, 30 },
|
||||
{ 257, 195, 30, 30 }
|
||||
};
|
||||
|
||||
/*
|
||||
Dessinez le menu Recherche + Filtre.
|
||||
const std::vectorbool> &searchIncludes : Const Référence à la searchIncludes.
|
||||
const std::string &searchResult : Const Référence à searchResult.
|
||||
int marks : Les drapeaux de marque de filtre.
|
||||
bool updateFilter : Le filtre de mise à jour.
|
||||
*/
|
||||
void StoreUtils::DrawSearchMenu(const std::vector<bool> &searchIncludes, const std::string &searchResult, int marks, bool updateFilter) {
|
||||
Gui::Draw_Rect(40, 0, 280, 25, ENTRY_BAR_COLOR);
|
||||
Gui::Draw_Rect(40, 25, 280, 1, ENTRY_BAR_OUTL_COLOR);
|
||||
Gui::DrawStringCentered(21, 2, 0.6, TEXT_COLOR, Lang::get("SEARCH_FILTERS"), 269, 0, font);
|
||||
|
||||
Gui::Draw_Rect(50, 44, 264, SearchMenu[0].h + 2, SEARCH_BAR_OUTL_COLOR);
|
||||
Gui::Draw_Rect(SearchMenu[0].x, SearchMenu[0].y, SearchMenu[0].w, SearchMenu[0].h, SEARCH_BAR_COLOR);
|
||||
|
||||
Gui::DrawStringCentered(24, 50, 0.6, TEXT_COLOR, searchResult, 265, 0, font);
|
||||
|
||||
/* Checkboxes. */
|
||||
for (int i = 0; i < 4; i++) {
|
||||
GFX::DrawCheckbox(SearchMenu[i + 1].x, SearchMenu[i + 1].y, searchIncludes[i]);
|
||||
}
|
||||
|
||||
Gui::DrawString(84, 85, 0.5, TEXT_COLOR, Lang::get("INCLUDE_IN_RESULTS"), 265, 0, font);
|
||||
|
||||
Gui::DrawString(SearchMenu[1].x + 18, SearchMenu[1].y + 1, 0.4, TEXT_COLOR, Lang::get("TITLE"), 90, 0, font);
|
||||
Gui::DrawString(SearchMenu[2].x + 18, SearchMenu[2].y + 1, 0.4, TEXT_COLOR, Lang::get("AUTHOR"), 90, 0, font);
|
||||
|
||||
Gui::DrawString(SearchMenu[3].x + 18, SearchMenu[3].y + 1, 0.4, TEXT_COLOR, Lang::get("CATEGORY"), 90, 0, font);
|
||||
Gui::DrawString(SearchMenu[4].x + 18, SearchMenu[4].y + 1, 0.4, TEXT_COLOR, Lang::get("CONSOLE"), 90, 0, font);
|
||||
|
||||
/* Filtrer. */
|
||||
Gui::DrawString(84, 175, 0.5f, TEXT_COLOR, Lang::get("FILTER_TO"), 265, 0, font);
|
||||
|
||||
Gui::Draw_Rect(SearchMenu[5].x, SearchMenu[5].y, SearchMenu[5].w, SearchMenu[5].h, (marks & favoriteMarks::STAR ?
|
||||
SIDEBAR_UNSELECTED_COLOR : BOX_INSIDE_COLOR));
|
||||
|
||||
Gui::Draw_Rect(SearchMenu[6].x, SearchMenu[6].y, SearchMenu[6].w, SearchMenu[6].h, (marks & favoriteMarks::HEART ?
|
||||
SIDEBAR_UNSELECTED_COLOR : BOX_INSIDE_COLOR));
|
||||
|
||||
Gui::Draw_Rect(SearchMenu[7].x, SearchMenu[7].y, SearchMenu[7].w, SearchMenu[7].h, (marks & favoriteMarks::DIAMOND ?
|
||||
SIDEBAR_UNSELECTED_COLOR : BOX_INSIDE_COLOR));
|
||||
|
||||
Gui::Draw_Rect(SearchMenu[8].x, SearchMenu[8].y, SearchMenu[8].w, SearchMenu[8].h, (marks & favoriteMarks::CLUBS ?
|
||||
SIDEBAR_UNSELECTED_COLOR : BOX_INSIDE_COLOR));
|
||||
|
||||
Gui::Draw_Rect(SearchMenu[9].x, SearchMenu[9].y, SearchMenu[9].w, SearchMenu[9].h, (marks & favoriteMarks::SPADE ?
|
||||
SIDEBAR_UNSELECTED_COLOR : BOX_INSIDE_COLOR));
|
||||
|
||||
Gui::Draw_Rect(SearchMenu[10].x, SearchMenu[10].y, SearchMenu[10].w, SearchMenu[10].h, (updateFilter ?
|
||||
SIDEBAR_UNSELECTED_COLOR : BOX_INSIDE_COLOR));
|
||||
|
||||
Gui::DrawString(SearchMenu[5].x + 9, SearchMenu[5].y + 7, 0.5f, TEXT_COLOR, "★", 0, 0, font);
|
||||
Gui::DrawString(SearchMenu[6].x + 9, SearchMenu[6].y + 7, 0.5f, TEXT_COLOR, "♥", 0, 0, font);
|
||||
Gui::DrawString(SearchMenu[7].x + 9, SearchMenu[7].y + 7, 0.5f, TEXT_COLOR, "♦", 0, 0, font);
|
||||
Gui::DrawString(SearchMenu[8].x + 9, SearchMenu[8].y + 7, 0.5f, TEXT_COLOR, "♣", 0, 0, font);
|
||||
Gui::DrawString(SearchMenu[9].x + 9, SearchMenu[9].y + 7, 0.5f, TEXT_COLOR, "♠", 0, 0, font);
|
||||
GFX::DrawSprite(sprites_update_filter_idx, SearchMenu[10].x + 8, SearchMenu[10].y + 8);
|
||||
}
|
||||
|
||||
/*
|
||||
Rechercher + Filter Handle.
|
||||
Ici vous pouvez..
|
||||
- Filtrez les marques dans vos applications.
|
||||
- Rechercher dans eShop.
|
||||
- Inclure des éléments dans la recherche.
|
||||
std::unique_ptrStore> &store : Référence à la classe Store.
|
||||
std::vectorstd::unique_ptrStoreEntry>> &entries : Référence aux entrées du magasin.
|
||||
std::vectorbool> &searchIncludes : Référence aux InclusionsRecherche.
|
||||
std::unique_ptrMeta> &meta : Référence à la classe Meta.
|
||||
std::string &searchResult : Référence à searchResult.
|
||||
int &marks : Référence aux drapeaux de marque.
|
||||
bool &updateFilter : référence au filtre de mise à jour.
|
||||
*/
|
||||
void StoreUtils::SearchHandle(std::unique_ptr<Store> &store, std::vector<std::unique_ptr<StoreEntry>> &entries, std::vector<bool> &searchIncludes, std::unique_ptr<Meta> &meta, std::string &searchResult, int &marks, bool &updateFilter, bool ascending, SortType sorttype) {
|
||||
/* Checkboxes. */
|
||||
if (hDown & KEY_TOUCH) {
|
||||
bool didTouch = false;
|
||||
|
||||
/* Inclures. */
|
||||
for (int i = 0; i < 4; i++) {
|
||||
if (touching(touch, SearchMenu[i + 1])) {
|
||||
searchIncludes[i] = !searchIncludes[i];
|
||||
didTouch = true;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
/* Barres de Recherche. */
|
||||
if (!didTouch) {
|
||||
if (touching(touch, SearchMenu[0])) {
|
||||
if (store) {
|
||||
searchResult = Input::setkbdString(20, Lang::get("ENTER_SEARCH"), {});
|
||||
didTouch = true;
|
||||
|
||||
} else {
|
||||
searchResult = Input::setkbdString(20, Lang::get("ENTER_SEARCH"), {});
|
||||
didTouch = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/* Filtrer. */
|
||||
if (!didTouch) {
|
||||
if (touching(touch, SearchMenu[5])) {
|
||||
marks = marks ^ favoriteMarks::STAR;
|
||||
didTouch = true;
|
||||
|
||||
} else if (touching(touch, SearchMenu[6])) {
|
||||
marks = marks ^ favoriteMarks::HEART;
|
||||
didTouch = true;
|
||||
|
||||
} else if (touching(touch, SearchMenu[7])) {
|
||||
marks = marks ^ favoriteMarks::DIAMOND;
|
||||
didTouch = true;
|
||||
|
||||
} else if (touching(touch, SearchMenu[8])) {
|
||||
marks = marks ^ favoriteMarks::CLUBS;
|
||||
didTouch = true;
|
||||
|
||||
} else if (touching(touch, SearchMenu[9])) {
|
||||
marks = marks ^ favoriteMarks::SPADE;
|
||||
didTouch = true;
|
||||
|
||||
} else if (touching(touch, SearchMenu[10])) {
|
||||
updateFilter = !updateFilter;
|
||||
didTouch = true;
|
||||
}
|
||||
}
|
||||
|
||||
if (didTouch) {
|
||||
if (store && store->GetValid()) { // Ne cherchez que si c’est valide.
|
||||
StoreUtils::ResetAll(store, meta, entries);
|
||||
StoreUtils::search(entries, searchResult, searchIncludes[0], searchIncludes[1], searchIncludes[2], searchIncludes[3], marks, updateFilter);
|
||||
store->SetScreenIndx(0);
|
||||
store->SetEntry(0);
|
||||
store->SetBox(0);
|
||||
|
||||
StoreUtils::SortEntries(ascending, sorttype, entries);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/* Réinitialiser tout. */
|
||||
if (hDown & KEY_X) {
|
||||
marks = 0;
|
||||
updateFilter = false;
|
||||
for(uint i = 0; i < searchIncludes.size(); i++) searchIncludes[i] = false;
|
||||
searchResult = "";
|
||||
|
||||
if (store && store->GetValid()) {
|
||||
StoreUtils::ResetAll(store, meta, entries);
|
||||
StoreUtils::SortEntries(ascending, sorttype, entries);
|
||||
}
|
||||
}
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#include "keyboard.hpp"
|
||||
#include "storeUtils.hpp"
|
||||
#include "structs.hpp"
|
||||
|
||||
extern bool touching(touchPosition touch, Structs::ButtonPos button);
|
||||
static const std::vector<Structs::ButtonPos> SearchMenu = {
|
||||
{ 51, 45, 262, 30 }, // Search bar.
|
||||
|
||||
/* Inclure. */
|
||||
{ 85, 109, 50, 10 },
|
||||
{ 85, 125, 50, 10 },
|
||||
{ 167, 109, 50, 10 },
|
||||
{ 167, 125, 50, 10 },
|
||||
|
||||
/* Filtrer. */
|
||||
{ 82, 195, 30, 30 },
|
||||
{ 117, 195, 30, 30 },
|
||||
{ 152, 195, 30, 30 },
|
||||
{ 187, 195, 30, 30 },
|
||||
{ 222, 195, 30, 30 },
|
||||
{ 257, 195, 30, 30 }
|
||||
};
|
||||
|
||||
/*
|
||||
Dessinez le menu Recherche + Filtre.
|
||||
const std::vectorbool> &searchIncludes : Const Référence à la searchIncludes.
|
||||
const std::string &searchResult : Const Référence à searchResult.
|
||||
int marks : Les drapeaux de marque de filtre.
|
||||
bool updateFilter : Le filtre de mise à jour.
|
||||
*/
|
||||
void StoreUtils::DrawSearchMenu(const std::vector<bool> &searchIncludes, const std::string &searchResult, int marks, bool updateFilter) {
|
||||
Gui::Draw_Rect(40, 0, 280, 25, ENTRY_BAR_COLOR);
|
||||
Gui::Draw_Rect(40, 25, 280, 1, ENTRY_BAR_OUTL_COLOR);
|
||||
Gui::DrawStringCentered(21, 2, 0.6, TEXT_COLOR, Lang::get("SEARCH_FILTERS"), 269, 0, font);
|
||||
|
||||
Gui::Draw_Rect(50, 44, 264, SearchMenu[0].h + 2, SEARCH_BAR_OUTL_COLOR);
|
||||
Gui::Draw_Rect(SearchMenu[0].x, SearchMenu[0].y, SearchMenu[0].w, SearchMenu[0].h, SEARCH_BAR_COLOR);
|
||||
|
||||
Gui::DrawStringCentered(24, 50, 0.6, TEXT_COLOR, searchResult, 265, 0, font);
|
||||
|
||||
/* Checkboxes. */
|
||||
for (int i = 0; i < 4; i++) {
|
||||
GFX::DrawCheckbox(SearchMenu[i + 1].x, SearchMenu[i + 1].y, searchIncludes[i]);
|
||||
}
|
||||
|
||||
Gui::DrawString(84, 85, 0.5, TEXT_COLOR, Lang::get("INCLUDE_IN_RESULTS"), 265, 0, font);
|
||||
|
||||
Gui::DrawString(SearchMenu[1].x + 18, SearchMenu[1].y + 1, 0.4, TEXT_COLOR, Lang::get("TITLE"), 90, 0, font);
|
||||
Gui::DrawString(SearchMenu[2].x + 18, SearchMenu[2].y + 1, 0.4, TEXT_COLOR, Lang::get("AUTHOR"), 90, 0, font);
|
||||
|
||||
Gui::DrawString(SearchMenu[3].x + 18, SearchMenu[3].y + 1, 0.4, TEXT_COLOR, Lang::get("CATEGORY"), 90, 0, font);
|
||||
Gui::DrawString(SearchMenu[4].x + 18, SearchMenu[4].y + 1, 0.4, TEXT_COLOR, Lang::get("CONSOLE"), 90, 0, font);
|
||||
|
||||
/* Filtrer. */
|
||||
Gui::DrawString(84, 175, 0.5f, TEXT_COLOR, Lang::get("FILTER_TO"), 265, 0, font);
|
||||
|
||||
Gui::Draw_Rect(SearchMenu[5].x, SearchMenu[5].y, SearchMenu[5].w, SearchMenu[5].h, (marks & favoriteMarks::STAR ?
|
||||
SIDEBAR_UNSELECTED_COLOR : BOX_INSIDE_COLOR));
|
||||
|
||||
Gui::Draw_Rect(SearchMenu[6].x, SearchMenu[6].y, SearchMenu[6].w, SearchMenu[6].h, (marks & favoriteMarks::HEART ?
|
||||
SIDEBAR_UNSELECTED_COLOR : BOX_INSIDE_COLOR));
|
||||
|
||||
Gui::Draw_Rect(SearchMenu[7].x, SearchMenu[7].y, SearchMenu[7].w, SearchMenu[7].h, (marks & favoriteMarks::DIAMOND ?
|
||||
SIDEBAR_UNSELECTED_COLOR : BOX_INSIDE_COLOR));
|
||||
|
||||
Gui::Draw_Rect(SearchMenu[8].x, SearchMenu[8].y, SearchMenu[8].w, SearchMenu[8].h, (marks & favoriteMarks::CLUBS ?
|
||||
SIDEBAR_UNSELECTED_COLOR : BOX_INSIDE_COLOR));
|
||||
|
||||
Gui::Draw_Rect(SearchMenu[9].x, SearchMenu[9].y, SearchMenu[9].w, SearchMenu[9].h, (marks & favoriteMarks::SPADE ?
|
||||
SIDEBAR_UNSELECTED_COLOR : BOX_INSIDE_COLOR));
|
||||
|
||||
Gui::Draw_Rect(SearchMenu[10].x, SearchMenu[10].y, SearchMenu[10].w, SearchMenu[10].h, (updateFilter ?
|
||||
SIDEBAR_UNSELECTED_COLOR : BOX_INSIDE_COLOR));
|
||||
|
||||
Gui::DrawString(SearchMenu[5].x + 9, SearchMenu[5].y + 7, 0.5f, TEXT_COLOR, "★", 0, 0, font);
|
||||
Gui::DrawString(SearchMenu[6].x + 9, SearchMenu[6].y + 7, 0.5f, TEXT_COLOR, "♥", 0, 0, font);
|
||||
Gui::DrawString(SearchMenu[7].x + 9, SearchMenu[7].y + 7, 0.5f, TEXT_COLOR, "♦", 0, 0, font);
|
||||
Gui::DrawString(SearchMenu[8].x + 9, SearchMenu[8].y + 7, 0.5f, TEXT_COLOR, "♣", 0, 0, font);
|
||||
Gui::DrawString(SearchMenu[9].x + 9, SearchMenu[9].y + 7, 0.5f, TEXT_COLOR, "♠", 0, 0, font);
|
||||
GFX::DrawSprite(sprites_update_filter_idx, SearchMenu[10].x + 8, SearchMenu[10].y + 8);
|
||||
}
|
||||
|
||||
/*
|
||||
Rechercher + Filter Handle.
|
||||
Ici vous pouvez..
|
||||
- Filtrez les marques dans vos applications.
|
||||
- Rechercher dans eShop.
|
||||
- Inclure des éléments dans la recherche.
|
||||
std::unique_ptrStore> &store : Référence à la classe Store.
|
||||
std::vectorstd::unique_ptrStoreEntry>> &entries : Référence aux entrées du magasin.
|
||||
std::vectorbool> &searchIncludes : Référence aux InclusionsRecherche.
|
||||
std::unique_ptrMeta> &meta : Référence à la classe Meta.
|
||||
std::string &searchResult : Référence à searchResult.
|
||||
int &marks : Référence aux drapeaux de marque.
|
||||
bool &updateFilter : référence au filtre de mise à jour.
|
||||
*/
|
||||
void StoreUtils::SearchHandle(std::unique_ptr<Store> &store, std::vector<std::unique_ptr<StoreEntry>> &entries, std::vector<bool> &searchIncludes, std::unique_ptr<Meta> &meta, std::string &searchResult, int &marks, bool &updateFilter, bool ascending, SortType sorttype) {
|
||||
/* Checkboxes. */
|
||||
if (hDown & KEY_TOUCH) {
|
||||
bool didTouch = false;
|
||||
|
||||
/* Inclures. */
|
||||
for (int i = 0; i < 4; i++) {
|
||||
if (touching(touch, SearchMenu[i + 1])) {
|
||||
searchIncludes[i] = !searchIncludes[i];
|
||||
didTouch = true;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
/* Barres de Recherche. */
|
||||
if (!didTouch) {
|
||||
if (touching(touch, SearchMenu[0])) {
|
||||
if (store) {
|
||||
searchResult = Input::setkbdString(20, Lang::get("ENTER_SEARCH"), {});
|
||||
didTouch = true;
|
||||
|
||||
} else {
|
||||
searchResult = Input::setkbdString(20, Lang::get("ENTER_SEARCH"), {});
|
||||
didTouch = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/* Filtrer. */
|
||||
if (!didTouch) {
|
||||
if (touching(touch, SearchMenu[5])) {
|
||||
marks = marks ^ favoriteMarks::STAR;
|
||||
didTouch = true;
|
||||
|
||||
} else if (touching(touch, SearchMenu[6])) {
|
||||
marks = marks ^ favoriteMarks::HEART;
|
||||
didTouch = true;
|
||||
|
||||
} else if (touching(touch, SearchMenu[7])) {
|
||||
marks = marks ^ favoriteMarks::DIAMOND;
|
||||
didTouch = true;
|
||||
|
||||
} else if (touching(touch, SearchMenu[8])) {
|
||||
marks = marks ^ favoriteMarks::CLUBS;
|
||||
didTouch = true;
|
||||
|
||||
} else if (touching(touch, SearchMenu[9])) {
|
||||
marks = marks ^ favoriteMarks::SPADE;
|
||||
didTouch = true;
|
||||
|
||||
} else if (touching(touch, SearchMenu[10])) {
|
||||
updateFilter = !updateFilter;
|
||||
didTouch = true;
|
||||
}
|
||||
}
|
||||
|
||||
if (didTouch) {
|
||||
if (store && store->GetValid()) { // Ne cherchez que si c’est valide.
|
||||
StoreUtils::ResetAll(store, meta, entries);
|
||||
StoreUtils::search(entries, searchResult, searchIncludes[0], searchIncludes[1], searchIncludes[2], searchIncludes[3], marks, updateFilter);
|
||||
store->SetScreenIndx(0);
|
||||
store->SetEntry(0);
|
||||
store->SetBox(0);
|
||||
|
||||
StoreUtils::SortEntries(ascending, sorttype, entries);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/* Réinitialiser tout. */
|
||||
if (hDown & KEY_X) {
|
||||
marks = 0;
|
||||
updateFilter = false;
|
||||
for(uint i = 0; i < searchIncludes.size(); i++) searchIncludes[i] = false;
|
||||
searchResult = "";
|
||||
|
||||
if (store && store->GetValid()) {
|
||||
StoreUtils::ResetAll(store, meta, entries);
|
||||
StoreUtils::SortEntries(ascending, sorttype, entries);
|
||||
}
|
||||
}
|
||||
}
|
||||
+611
-611
File diff suppressed because it is too large
Load Diff
+101
-101
@@ -1,102 +1,102 @@
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#include "animation.hpp"
|
||||
#include "storeUtils.hpp"
|
||||
#include "structs.hpp"
|
||||
|
||||
extern bool touching(touchPosition touch, Structs::ButtonPos button);
|
||||
static const std::vector<Structs::ButtonPos> sidePos = {
|
||||
{ 0, 0, 40, 40 },
|
||||
{ 0, 40, 40, 40 },
|
||||
{ 0, 80, 40, 40 },
|
||||
{ 0, 120, 40, 40 },
|
||||
{ 0, 160, 40, 40 },
|
||||
{ 0, 200, 40, 40 }
|
||||
};
|
||||
|
||||
/*
|
||||
Dessinez la partie Menu latéral.
|
||||
int currentMenu : Le Mode Store / Menu courant.
|
||||
*/
|
||||
void StoreUtils::DrawSideMenu(int currentMenu) {
|
||||
for (int i = 0; i < 6; i++) {
|
||||
if (i == currentMenu) {
|
||||
Gui::Draw_Rect(sidePos[i].x, sidePos[i].y, sidePos[i].w, sidePos[i].h, SIDEBAR_SELECTED_COLOR);
|
||||
|
||||
} else {
|
||||
Gui::Draw_Rect(sidePos[i].x, sidePos[i].y, sidePos[i].w, sidePos[i].h, SIDEBAR_UNSELECTED_COLOR);
|
||||
}
|
||||
}
|
||||
|
||||
GFX::DrawSprite(sprites_info_idx, sidePos[0].x, sidePos[0].y);
|
||||
GFX::DrawSprite(sprites_download_idx, sidePos[1].x, sidePos[1].y);
|
||||
Animation::DrawQueue(sidePos[2].x, sidePos[2].y);
|
||||
GFX::DrawSprite(sprites_search_idx, sidePos[3].x, sidePos[3].y);
|
||||
GFX::DrawSprite(sprites_sort_idx, sidePos[4].x, sidePos[4].y);
|
||||
GFX::DrawSprite(sprites_settings_idx, sidePos[5].x, sidePos[5].y);
|
||||
|
||||
Gui::Draw_Rect(40, 0, 1, 240, BAR_OUTL_COLOR);
|
||||
}
|
||||
|
||||
/*
|
||||
Poignée de menu latéral.
|
||||
Ici vous pouvez..
|
||||
- Basculer entre les menus à travers la barre latérale.
|
||||
int tMenu : Référence au Mode Store / Menu.
|
||||
bool &fetch : Référence de la variable download fetch.. donc nous savons, si nous avons besoin de récupérer les entrées de téléchargement.
|
||||
int &lastMenu : Référence au dernier menu.
|
||||
*/
|
||||
void StoreUtils::SideMenuHandle(int ¤tMenu, bool &fetch, int &lastMenu) {
|
||||
Animation::QueueAnimHandle();
|
||||
|
||||
if (hDown & KEY_TOUCH) {
|
||||
for (int i = 0; i < 6; i++) {
|
||||
if (touching(touch, sidePos[i])) {
|
||||
lastMenu = currentMenu;
|
||||
if (i == 1) fetch = true; // Récupérez la liste des téléchargements, si 1.
|
||||
currentMenu = i;
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (hRepeat & KEY_R) {
|
||||
if (currentMenu < 5) {
|
||||
lastMenu = currentMenu;
|
||||
if (currentMenu + 1 == 1) fetch = true; // Récupérez la liste des téléchargements, si 1.
|
||||
currentMenu++;
|
||||
}
|
||||
}
|
||||
|
||||
if (hRepeat & KEY_L) {
|
||||
if (currentMenu > 0) {
|
||||
lastMenu = currentMenu;
|
||||
if (currentMenu - 1 == 1) fetch = true; // Récupérez la liste des téléchargements, si 1.
|
||||
currentMenu--;
|
||||
}
|
||||
}
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#include "animation.hpp"
|
||||
#include "storeUtils.hpp"
|
||||
#include "structs.hpp"
|
||||
|
||||
extern bool touching(touchPosition touch, Structs::ButtonPos button);
|
||||
static const std::vector<Structs::ButtonPos> sidePos = {
|
||||
{ 0, 0, 40, 40 },
|
||||
{ 0, 40, 40, 40 },
|
||||
{ 0, 80, 40, 40 },
|
||||
{ 0, 120, 40, 40 },
|
||||
{ 0, 160, 40, 40 },
|
||||
{ 0, 200, 40, 40 }
|
||||
};
|
||||
|
||||
/*
|
||||
Dessinez la partie Menu latéral.
|
||||
int currentMenu : Le Mode Store / Menu courant.
|
||||
*/
|
||||
void StoreUtils::DrawSideMenu(int currentMenu) {
|
||||
for (int i = 0; i < 6; i++) {
|
||||
if (i == currentMenu) {
|
||||
Gui::Draw_Rect(sidePos[i].x, sidePos[i].y, sidePos[i].w, sidePos[i].h, SIDEBAR_SELECTED_COLOR);
|
||||
|
||||
} else {
|
||||
Gui::Draw_Rect(sidePos[i].x, sidePos[i].y, sidePos[i].w, sidePos[i].h, SIDEBAR_UNSELECTED_COLOR);
|
||||
}
|
||||
}
|
||||
|
||||
GFX::DrawSprite(sprites_info_idx, sidePos[0].x, sidePos[0].y);
|
||||
GFX::DrawSprite(sprites_download_idx, sidePos[1].x, sidePos[1].y);
|
||||
Animation::DrawQueue(sidePos[2].x, sidePos[2].y);
|
||||
GFX::DrawSprite(sprites_search_idx, sidePos[3].x, sidePos[3].y);
|
||||
GFX::DrawSprite(sprites_sort_idx, sidePos[4].x, sidePos[4].y);
|
||||
GFX::DrawSprite(sprites_settings_idx, sidePos[5].x, sidePos[5].y);
|
||||
|
||||
Gui::Draw_Rect(40, 0, 1, 240, BAR_OUTL_COLOR);
|
||||
}
|
||||
|
||||
/*
|
||||
Poignée de menu latéral.
|
||||
Ici vous pouvez..
|
||||
- Basculer entre les menus à travers la barre latérale.
|
||||
int tMenu : Référence au Mode Store / Menu.
|
||||
bool &fetch : Référence de la variable download fetch.. donc nous savons, si nous avons besoin de récupérer les entrées de téléchargement.
|
||||
int &lastMenu : Référence au dernier menu.
|
||||
*/
|
||||
void StoreUtils::SideMenuHandle(int ¤tMenu, bool &fetch, int &lastMenu) {
|
||||
Animation::QueueAnimHandle();
|
||||
|
||||
if (hDown & KEY_TOUCH) {
|
||||
for (int i = 0; i < 6; i++) {
|
||||
if (touching(touch, sidePos[i])) {
|
||||
lastMenu = currentMenu;
|
||||
if (i == 1) fetch = true; // Récupérez la liste des téléchargements, si 1.
|
||||
currentMenu = i;
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (hRepeat & KEY_R) {
|
||||
if (currentMenu < 5) {
|
||||
lastMenu = currentMenu;
|
||||
if (currentMenu + 1 == 1) fetch = true; // Récupérez la liste des téléchargements, si 1.
|
||||
currentMenu++;
|
||||
}
|
||||
}
|
||||
|
||||
if (hRepeat & KEY_L) {
|
||||
if (currentMenu > 0) {
|
||||
lastMenu = currentMenu;
|
||||
if (currentMenu - 1 == 1) fetch = true; // Récupérez la liste des téléchargements, si 1.
|
||||
currentMenu--;
|
||||
}
|
||||
}
|
||||
}
|
||||
+156
-156
@@ -1,157 +1,157 @@
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#include "keyboard.hpp"
|
||||
#include "storeUtils.hpp"
|
||||
#include "structs.hpp"
|
||||
|
||||
extern bool touching(touchPosition touch, Structs::ButtonPos button);
|
||||
|
||||
static const std::vector<Structs::ButtonPos> buttons = {
|
||||
{ 71, 60, 104, 16 },
|
||||
{ 71, 80, 104, 16 },
|
||||
{ 71, 100, 104, 16 },
|
||||
|
||||
{ 201, 60, 104, 16 },
|
||||
{ 201, 80, 104, 16 },
|
||||
|
||||
{ 71, 170, 104, 16 },
|
||||
{ 71, 190, 104, 16 }
|
||||
};
|
||||
|
||||
static void DrawCheck(int pos, bool v) {
|
||||
GFX::DrawSprite((v ? sprites_sort_checked_idx : sprites_sort_unchecked_idx), buttons[pos].x + 1, buttons[pos].y);
|
||||
}
|
||||
|
||||
/*
|
||||
Return SortType as an uint8_t.
|
||||
SortType st: The SortType variable.
|
||||
*/
|
||||
static const uint8_t GetType(SortType st) {
|
||||
switch(st) {
|
||||
case SortType::TITLE:
|
||||
return 0;
|
||||
|
||||
case SortType::AUTHOR:
|
||||
return 1;
|
||||
|
||||
case SortType::LAST_UPDATED:
|
||||
return 2;
|
||||
}
|
||||
|
||||
return 1;
|
||||
}
|
||||
|
||||
/*
|
||||
Draw the Sort Menu.
|
||||
bool asc: The Ascending variable.
|
||||
SortType st: The SortType variable.
|
||||
*/
|
||||
void StoreUtils::DrawSorting(bool asc, SortType st) {
|
||||
Gui::Draw_Rect(40, 0, 280, 25, ENTRY_BAR_COLOR);
|
||||
Gui::Draw_Rect(40, 25, 280, 1, ENTRY_BAR_OUTL_COLOR);
|
||||
Gui::DrawStringCentered(17, 2, 0.6, TEXT_COLOR, Lang::get("SORTING"), 273, 0, font);
|
||||
|
||||
/* Sort By. */
|
||||
Gui::DrawString(buttons[0].x + 1, buttons[0].y - 20, 0.6f, TEXT_COLOR, Lang::get("SORT_BY"), 90, 0, font);
|
||||
for (int i = 0; i < 3; i++) {
|
||||
DrawCheck(i, i == GetType(st));
|
||||
}
|
||||
|
||||
Gui::DrawString(buttons[0].x + 21, buttons[0].y + 2, 0.4f, TEXT_COLOR, Lang::get("TITLE"), 80, 0, font);
|
||||
Gui::DrawString(buttons[1].x + 21, buttons[1].y + 2, 0.4f, TEXT_COLOR, Lang::get("AUTHOR"), 80, 0, font);
|
||||
Gui::DrawString(buttons[2].x + 21, buttons[2].y + 2, 0.4f, TEXT_COLOR, Lang::get("LAST_UPDATED"), 80, 0, font);
|
||||
|
||||
/* Direction. */
|
||||
Gui::DrawString(buttons[3].x + 1, buttons[3].y - 20, 0.6f, TEXT_COLOR, Lang::get("DIRECTION"), 80, 0, font);
|
||||
DrawCheck(3, asc);
|
||||
DrawCheck(4, !asc);
|
||||
Gui::DrawString(buttons[3].x + 21, buttons[3].y + 2, 0.4f, TEXT_COLOR, Lang::get("ASCENDING"), 80, 0, font);
|
||||
Gui::DrawString(buttons[4].x + 21, buttons[4].y + 2, 0.4f, TEXT_COLOR, Lang::get("DESCENDING"), 80, 0, font);
|
||||
|
||||
/* Top Style. */
|
||||
Gui::DrawString(buttons[5].x + 1, buttons[5].y - 20, 0.6f, TEXT_COLOR, Lang::get("TOP_STYLE"), 90, 0, font);
|
||||
DrawCheck(5, config->list());
|
||||
DrawCheck(6, !config->list());
|
||||
Gui::DrawString(buttons[5].x + 21, buttons[5].y + 2, 0.4f, TEXT_COLOR, Lang::get("LIST"), 90, 0, font);
|
||||
Gui::DrawString(buttons[6].x + 21, buttons[6].y + 2, 0.4f, TEXT_COLOR, Lang::get("GRID"), 90, 0, font);
|
||||
}
|
||||
|
||||
/*
|
||||
Sort Handle.
|
||||
Here you can..
|
||||
- Sort your Entries to..
|
||||
- Title (Ascending / Descending).
|
||||
- Author (Ascending / Descending).
|
||||
- Last Updated Date (Ascending / Descending).
|
||||
- Change the Top Style.
|
||||
std::unique_ptr<Store> &store: Reference to the Store class.
|
||||
std::vector<std::unique_ptr<StoreEntry>> &entries: Reference to the StoreEntries.
|
||||
bool &asc: Reference to the Ascending variable.
|
||||
SortType &st: Reference to the SortType.
|
||||
*/
|
||||
void StoreUtils::SortHandle(std::unique_ptr<Store> &store, std::vector<std::unique_ptr<StoreEntry>> &entries, bool &asc, SortType &st) {
|
||||
if (store && store->GetValid() && entries.size() > 0) { // Ensure, this is valid and more than 0 entries exist.
|
||||
if (hDown & KEY_TOUCH) {
|
||||
/* SortType Part. */
|
||||
if (touching(touch, buttons[0])) {
|
||||
st = SortType::TITLE;
|
||||
StoreUtils::SortEntries(asc, st, entries);
|
||||
|
||||
} else if (touching(touch, buttons[1])) {
|
||||
st = SortType::AUTHOR;
|
||||
StoreUtils::SortEntries(asc, st, entries);
|
||||
|
||||
} else if (touching(touch, buttons[2])) {
|
||||
st = SortType::LAST_UPDATED;
|
||||
StoreUtils::SortEntries(asc, st, entries);
|
||||
|
||||
/* Ascending | Descending Part. */
|
||||
} else if (touching(touch, buttons[3])) {
|
||||
asc = true;
|
||||
StoreUtils::SortEntries(asc, st, entries);
|
||||
|
||||
} else if (touching(touch, buttons[4])) {
|
||||
asc = false;
|
||||
StoreUtils::SortEntries(asc, st, entries);
|
||||
|
||||
} else if (touching(touch, buttons[5])) {
|
||||
if (config->list()) return;
|
||||
config->list(true);
|
||||
store->SetEntry(0);
|
||||
store->SetScreenIndx(0);
|
||||
store->SetBox(0);
|
||||
|
||||
} else if (touching(touch, buttons[6])) {
|
||||
if (!config->list()) return;
|
||||
config->list(false);
|
||||
store->SetEntry(0);
|
||||
store->SetScreenIndx(0);
|
||||
store->SetBox(0);
|
||||
}
|
||||
}
|
||||
}
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#include "keyboard.hpp"
|
||||
#include "storeUtils.hpp"
|
||||
#include "structs.hpp"
|
||||
|
||||
extern bool touching(touchPosition touch, Structs::ButtonPos button);
|
||||
|
||||
static const std::vector<Structs::ButtonPos> buttons = {
|
||||
{ 71, 60, 104, 16 },
|
||||
{ 71, 80, 104, 16 },
|
||||
{ 71, 100, 104, 16 },
|
||||
|
||||
{ 201, 60, 104, 16 },
|
||||
{ 201, 80, 104, 16 },
|
||||
|
||||
{ 71, 170, 104, 16 },
|
||||
{ 71, 190, 104, 16 }
|
||||
};
|
||||
|
||||
static void DrawCheck(int pos, bool v) {
|
||||
GFX::DrawSprite((v ? sprites_sort_checked_idx : sprites_sort_unchecked_idx), buttons[pos].x + 1, buttons[pos].y);
|
||||
}
|
||||
|
||||
/*
|
||||
Return SortType as an uint8_t.
|
||||
SortType st: The SortType variable.
|
||||
*/
|
||||
static const uint8_t GetType(SortType st) {
|
||||
switch(st) {
|
||||
case SortType::TITLE:
|
||||
return 0;
|
||||
|
||||
case SortType::AUTHOR:
|
||||
return 1;
|
||||
|
||||
case SortType::LAST_UPDATED:
|
||||
return 2;
|
||||
}
|
||||
|
||||
return 1;
|
||||
}
|
||||
|
||||
/*
|
||||
Draw the Sort Menu.
|
||||
bool asc: The Ascending variable.
|
||||
SortType st: The SortType variable.
|
||||
*/
|
||||
void StoreUtils::DrawSorting(bool asc, SortType st) {
|
||||
Gui::Draw_Rect(40, 0, 280, 25, ENTRY_BAR_COLOR);
|
||||
Gui::Draw_Rect(40, 25, 280, 1, ENTRY_BAR_OUTL_COLOR);
|
||||
Gui::DrawStringCentered(17, 2, 0.6, TEXT_COLOR, Lang::get("SORTING"), 273, 0, font);
|
||||
|
||||
/* Sort By. */
|
||||
Gui::DrawString(buttons[0].x + 1, buttons[0].y - 20, 0.6f, TEXT_COLOR, Lang::get("SORT_BY"), 90, 0, font);
|
||||
for (int i = 0; i < 3; i++) {
|
||||
DrawCheck(i, i == GetType(st));
|
||||
}
|
||||
|
||||
Gui::DrawString(buttons[0].x + 21, buttons[0].y + 2, 0.4f, TEXT_COLOR, Lang::get("TITLE"), 80, 0, font);
|
||||
Gui::DrawString(buttons[1].x + 21, buttons[1].y + 2, 0.4f, TEXT_COLOR, Lang::get("AUTHOR"), 80, 0, font);
|
||||
Gui::DrawString(buttons[2].x + 21, buttons[2].y + 2, 0.4f, TEXT_COLOR, Lang::get("LAST_UPDATED"), 80, 0, font);
|
||||
|
||||
/* Direction. */
|
||||
Gui::DrawString(buttons[3].x + 1, buttons[3].y - 20, 0.6f, TEXT_COLOR, Lang::get("DIRECTION"), 80, 0, font);
|
||||
DrawCheck(3, asc);
|
||||
DrawCheck(4, !asc);
|
||||
Gui::DrawString(buttons[3].x + 21, buttons[3].y + 2, 0.4f, TEXT_COLOR, Lang::get("ASCENDING"), 80, 0, font);
|
||||
Gui::DrawString(buttons[4].x + 21, buttons[4].y + 2, 0.4f, TEXT_COLOR, Lang::get("DESCENDING"), 80, 0, font);
|
||||
|
||||
/* Top Style. */
|
||||
Gui::DrawString(buttons[5].x + 1, buttons[5].y - 20, 0.6f, TEXT_COLOR, Lang::get("TOP_STYLE"), 90, 0, font);
|
||||
DrawCheck(5, config->list());
|
||||
DrawCheck(6, !config->list());
|
||||
Gui::DrawString(buttons[5].x + 21, buttons[5].y + 2, 0.4f, TEXT_COLOR, Lang::get("LIST"), 90, 0, font);
|
||||
Gui::DrawString(buttons[6].x + 21, buttons[6].y + 2, 0.4f, TEXT_COLOR, Lang::get("GRID"), 90, 0, font);
|
||||
}
|
||||
|
||||
/*
|
||||
Sort Handle.
|
||||
Here you can..
|
||||
- Sort your Entries to..
|
||||
- Title (Ascending / Descending).
|
||||
- Author (Ascending / Descending).
|
||||
- Last Updated Date (Ascending / Descending).
|
||||
- Change the Top Style.
|
||||
std::unique_ptr<Store> &store: Reference to the Store class.
|
||||
std::vector<std::unique_ptr<StoreEntry>> &entries: Reference to the StoreEntries.
|
||||
bool &asc: Reference to the Ascending variable.
|
||||
SortType &st: Reference to the SortType.
|
||||
*/
|
||||
void StoreUtils::SortHandle(std::unique_ptr<Store> &store, std::vector<std::unique_ptr<StoreEntry>> &entries, bool &asc, SortType &st) {
|
||||
if (store && store->GetValid() && entries.size() > 0) { // Ensure, this is valid and more than 0 entries exist.
|
||||
if (hDown & KEY_TOUCH) {
|
||||
/* SortType Part. */
|
||||
if (touching(touch, buttons[0])) {
|
||||
st = SortType::TITLE;
|
||||
StoreUtils::SortEntries(asc, st, entries);
|
||||
|
||||
} else if (touching(touch, buttons[1])) {
|
||||
st = SortType::AUTHOR;
|
||||
StoreUtils::SortEntries(asc, st, entries);
|
||||
|
||||
} else if (touching(touch, buttons[2])) {
|
||||
st = SortType::LAST_UPDATED;
|
||||
StoreUtils::SortEntries(asc, st, entries);
|
||||
|
||||
/* Ascending | Descending Part. */
|
||||
} else if (touching(touch, buttons[3])) {
|
||||
asc = true;
|
||||
StoreUtils::SortEntries(asc, st, entries);
|
||||
|
||||
} else if (touching(touch, buttons[4])) {
|
||||
asc = false;
|
||||
StoreUtils::SortEntries(asc, st, entries);
|
||||
|
||||
} else if (touching(touch, buttons[5])) {
|
||||
if (config->list()) return;
|
||||
config->list(true);
|
||||
store->SetEntry(0);
|
||||
store->SetScreenIndx(0);
|
||||
store->SetBox(0);
|
||||
|
||||
} else if (touching(touch, buttons[6])) {
|
||||
if (!config->list()) return;
|
||||
config->list(false);
|
||||
store->SetEntry(0);
|
||||
store->SetScreenIndx(0);
|
||||
store->SetBox(0);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
+64
-64
@@ -1,65 +1,65 @@
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#include "overlay.hpp"
|
||||
|
||||
/*
|
||||
Montrez les crédits.
|
||||
*/
|
||||
void Overlays::ShowCredits() {
|
||||
bool doOut = false;
|
||||
|
||||
while(!doOut) {
|
||||
Gui::clearTextBufs();
|
||||
C3D_FrameBegin(C3D_FRAME_SYNCDRAW);
|
||||
C2D_TargetClear(Top, TRANSPARENT);
|
||||
C2D_TargetClear(Bottom, TRANSPARENT);
|
||||
|
||||
GFX::DrawTop();
|
||||
GFX::DrawSprite(sprites_DarkStore_idx, 240, 30);
|
||||
Gui::DrawStringCentered(0, 1, 0.7f, TEXT_COLOR, "DarkStore - " + Lang::get("CREDITS"), 395, 0, font);
|
||||
|
||||
Gui::DrawString(10, 30, 0.5f, TEXT_COLOR, "- DarkStore Team", 0, 0, font);
|
||||
Gui::DrawString(10, 50, 0.5f, TEXT_COLOR, "- " + Lang::get("FILES_HOSTING_ANONYKU"), 0, 0, font);
|
||||
Gui::DrawString(10, 70, 0.5f, TEXT_COLOR, "- " + Lang::get("CITRA_BIGN_ICON"), 0, 0, font);
|
||||
Gui::DrawString(10, 90, 0.5f, TEXT_COLOR, "- https://hshop.erista.me/", 0, 0, font);
|
||||
Gui::DrawString(10, 110, 0.5f, TEXT_COLOR, "- https://icons8.com/", 0, 0, font);
|
||||
Gui::DrawString(10, 130, 0.5f, TEXT_COLOR, "- Dhalian. : Images", 0, 0, font);
|
||||
Gui::DrawString(10, 150, 0.5f, TEXT_COLOR, Lang::get("CONTRIBUTOR_TRANSLATORS"), 210, 0, font);
|
||||
Gui::DrawString(10, 197, 0.5f, TEXT_COLOR, Lang::get("WEBSITE"), 390, 0, font);
|
||||
|
||||
Gui::Draw_Rect(0, 215, 400, 25, BAR_COLOR);
|
||||
Gui::Draw_Rect(0, 214, 400, 1, BAR_OUTL_COLOR);
|
||||
Gui::DrawStringCentered(0, 218, 0.6f, TEXT_COLOR, Lang::get("CURRENT_VERSION") + std::string(V_STRING), 390, 0, font);
|
||||
|
||||
GFX::DrawBottom();
|
||||
GFX::DrawSprite(sprites_DarkStore_core_idx, 0, 0);
|
||||
C3D_FrameEnd(0);
|
||||
|
||||
hidScanInput();
|
||||
if ((hidKeysDown() & KEY_START) || (hidKeysDown() & KEY_B) || (hidKeysDown() & KEY_A)) doOut = true;
|
||||
}
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#include "overlay.hpp"
|
||||
|
||||
/*
|
||||
Montrez les crédits.
|
||||
*/
|
||||
void Overlays::ShowCredits() {
|
||||
bool doOut = false;
|
||||
|
||||
while(!doOut) {
|
||||
Gui::clearTextBufs();
|
||||
C3D_FrameBegin(C3D_FRAME_SYNCDRAW);
|
||||
C2D_TargetClear(Top, TRANSPARENT);
|
||||
C2D_TargetClear(Bottom, TRANSPARENT);
|
||||
|
||||
GFX::DrawTop();
|
||||
GFX::DrawSprite(sprites_DarkStore_idx, 240, 30);
|
||||
Gui::DrawStringCentered(0, 1, 0.7f, TEXT_COLOR, "DarkStore - " + Lang::get("CREDITS"), 395, 0, font);
|
||||
|
||||
Gui::DrawString(10, 30, 0.5f, TEXT_COLOR, "- DarkStore Team", 0, 0, font);
|
||||
Gui::DrawString(10, 50, 0.5f, TEXT_COLOR, "- " + Lang::get("FILES_HOSTING_ANONYKU"), 0, 0, font);
|
||||
Gui::DrawString(10, 70, 0.5f, TEXT_COLOR, "- " + Lang::get("CITRA_BIGN_ICON"), 0, 0, font);
|
||||
Gui::DrawString(10, 90, 0.5f, TEXT_COLOR, "- https://hshop.erista.me/", 0, 0, font);
|
||||
Gui::DrawString(10, 110, 0.5f, TEXT_COLOR, "- https://icons8.com/", 0, 0, font);
|
||||
Gui::DrawString(10, 130, 0.5f, TEXT_COLOR, "- Dhalian. : Images", 0, 0, font);
|
||||
Gui::DrawString(10, 150, 0.5f, TEXT_COLOR, Lang::get("CONTRIBUTOR_TRANSLATORS"), 210, 0, font);
|
||||
Gui::DrawString(10, 197, 0.5f, TEXT_COLOR, Lang::get("WEBSITE"), 390, 0, font);
|
||||
|
||||
Gui::Draw_Rect(0, 215, 400, 25, BAR_COLOR);
|
||||
Gui::Draw_Rect(0, 214, 400, 1, BAR_OUTL_COLOR);
|
||||
Gui::DrawStringCentered(0, 218, 0.6f, TEXT_COLOR, Lang::get("CURRENT_VERSION") + std::string(V_STRING), 390, 0, font);
|
||||
|
||||
GFX::DrawBottom();
|
||||
GFX::DrawSprite(sprites_DarkStore_core_idx, 0, 0);
|
||||
C3D_FrameEnd(0);
|
||||
|
||||
hidScanInput();
|
||||
if ((hidKeysDown() & KEY_START) || (hidKeysDown() & KEY_B) || (hidKeysDown() & KEY_A)) doOut = true;
|
||||
}
|
||||
}
|
||||
+197
-197
@@ -1,198 +1,198 @@
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#include "fileBrowse.hpp"
|
||||
#include "overlay.hpp"
|
||||
#include <unistd.h>
|
||||
|
||||
extern bool touching(touchPosition touch, Structs::ButtonPos button);
|
||||
static const std::vector<Structs::ButtonPos> mainButtons = {
|
||||
{ 10, 6, 300, 22 },
|
||||
{ 10, 36, 300, 22 },
|
||||
{ 10, 66, 300, 22 },
|
||||
{ 10, 96, 300, 22 },
|
||||
{ 10, 126, 300, 22 },
|
||||
{ 10, 156, 300, 22 },
|
||||
{ 10, 186, 300, 22 }
|
||||
};
|
||||
|
||||
/*
|
||||
Sélectionnez un répertoire.
|
||||
*/
|
||||
std::string Overlays::SelectDir(const std::string &oldDir, const std::string &msg, const std::unique_ptr<Store> &store) {
|
||||
std::string currentPath = oldDir;
|
||||
bool dirChanged = false;
|
||||
int selection = 0, sPos = 0;
|
||||
|
||||
std::vector<DirEntry> dirContents;
|
||||
dirContents.clear();
|
||||
|
||||
/* Juste pour s'assurer. */
|
||||
if (access((oldDir + std::string("/")).c_str(), F_OK) == 0) {
|
||||
chdir((oldDir + std::string("/")).c_str());
|
||||
|
||||
} else {
|
||||
currentPath = "sdmc:/";
|
||||
chdir("sdmc:/");
|
||||
}
|
||||
|
||||
std::vector<DirEntry> dirContentsTemp;
|
||||
getDirectoryContents(dirContentsTemp, {"/"});
|
||||
|
||||
for(uint i = 0; i < dirContentsTemp.size(); i++) {
|
||||
dirContents.push_back(dirContentsTemp[i]);
|
||||
}
|
||||
|
||||
while(1) {
|
||||
Gui::clearTextBufs();
|
||||
C3D_FrameBegin(C3D_FRAME_SYNCDRAW);
|
||||
C2D_TargetClear(Top, TRANSPARENT);
|
||||
C2D_TargetClear(Bottom, TRANSPARENT);
|
||||
|
||||
if (store && config->usebg() && store->customBG()) {
|
||||
Gui::ScreenDraw(Top);
|
||||
Gui::Draw_Rect(0, 0, 400, 25, BAR_COLOR);
|
||||
Gui::Draw_Rect(0, 25, 400, 1, BAR_OUTL_COLOR);
|
||||
C2D_DrawImageAt(store->GetStoreImg(), 0, 26, 0.5f, nullptr);
|
||||
|
||||
} else {
|
||||
GFX::DrawTop();
|
||||
}
|
||||
|
||||
Gui::DrawStringCentered(0, 1, 0.7f, TEXT_COLOR, msg, 380, 0, font);
|
||||
|
||||
Gui::Draw_Rect(0, 215, 400, 25, BAR_COLOR);
|
||||
Gui::Draw_Rect(0, 214, 400, 1, BAR_OUTL_COLOR);
|
||||
Gui::DrawStringCentered(0, 217, 0.6f, TEXT_COLOR, currentPath, 390, 0, font);
|
||||
|
||||
GFX::DrawBottom();
|
||||
|
||||
Gui::Draw_Rect(0, 215, 320, 25, BAR_COLOR);
|
||||
Gui::Draw_Rect(0, 214, 320, 1, BAR_OUTL_COLOR);
|
||||
Gui::DrawStringCentered(0, 220, 0.5f, TEXT_COLOR, Lang::get("START_SELECT"), 310, 0, font);
|
||||
|
||||
if (dirContents.size() > 0) {
|
||||
for(int i = 0; i < 7 && i < (int)dirContents.size(); i++) {
|
||||
if (sPos + i == selection) GFX::DrawBox(mainButtons[i].x, mainButtons[i].y, mainButtons[i].w, mainButtons[i].h, false);
|
||||
Gui::DrawStringCentered(10 - 160 + (300 / 2), mainButtons[i].y + 4, 0.45f, TEXT_COLOR, dirContents[sPos + i].name, 295, 0, font);
|
||||
}
|
||||
}
|
||||
|
||||
C3D_FrameEnd(0);
|
||||
|
||||
if (dirChanged) {
|
||||
dirChanged = false;
|
||||
|
||||
selection = 0;
|
||||
sPos = 0;
|
||||
dirContents.clear();
|
||||
std::vector<DirEntry> dirContentsTemp;
|
||||
getDirectoryContents(dirContentsTemp, {"/"});
|
||||
|
||||
for(uint i = 0; i < dirContentsTemp.size(); i++) {
|
||||
dirContents.push_back(dirContentsTemp[i]);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
hidScanInput();
|
||||
touchPosition touch;
|
||||
hidTouchRead(&touch);
|
||||
u32 hRepeat = hidKeysDownRepeat();
|
||||
|
||||
if (dirContents.size() > 0) {
|
||||
if (hRepeat & KEY_DOWN) {
|
||||
if (selection < (int)dirContents.size() - 1) selection++;
|
||||
else selection = 0;
|
||||
}
|
||||
|
||||
if (hRepeat & KEY_UP) {
|
||||
if (selection > 0) selection--;
|
||||
else selection = dirContents.size() - 1;
|
||||
}
|
||||
|
||||
if (hRepeat & KEY_RIGHT) {
|
||||
if (selection + 7 < (int)dirContents.size()-1) selection += 7;
|
||||
else selection = dirContents.size()-1;
|
||||
}
|
||||
|
||||
if (hRepeat & KEY_LEFT) {
|
||||
if (selection - 7 > 0) selection -= 7;
|
||||
else selection = 0;
|
||||
}
|
||||
|
||||
if (hidKeysDown() & KEY_A) {
|
||||
if (dirContents[selection].isDirectory) {
|
||||
chdir(dirContents[selection].name.c_str());
|
||||
char path[PATH_MAX];
|
||||
getcwd(path, PATH_MAX);
|
||||
currentPath = path;
|
||||
dirChanged = true;
|
||||
}
|
||||
}
|
||||
|
||||
if (hidKeysDown() & KEY_TOUCH) {
|
||||
for (int i = 0; i < 7; i++) {
|
||||
if (touching(touch, mainButtons[i])) {
|
||||
if (i + sPos < (int)dirContents.size()) {
|
||||
if (dirContents[i + sPos].isDirectory) {
|
||||
chdir(dirContents[i + sPos].name.c_str());
|
||||
|
||||
char path[PATH_MAX];
|
||||
getcwd(path, PATH_MAX);
|
||||
currentPath = path;
|
||||
|
||||
dirChanged = true;
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (selection < sPos) sPos = selection;
|
||||
else if (selection > sPos + 7 - 1) sPos = selection - 7 + 1;
|
||||
}
|
||||
|
||||
if ((hidKeysDown() & KEY_X) || (hidKeysDown() & KEY_START)) {
|
||||
if (currentPath.size() > 0 && currentPath.back() == '/') currentPath.pop_back(); // Pop back le "/".
|
||||
return currentPath;
|
||||
}
|
||||
|
||||
if (hidKeysDown() & KEY_B) {
|
||||
char path[PATH_MAX];
|
||||
getcwd(path, PATH_MAX);
|
||||
|
||||
if (strcmp(path, "sdmc:/") == 0 || strcmp(path, "/") == 0) return "";
|
||||
else {
|
||||
chdir("..");
|
||||
getcwd(path, PATH_MAX);
|
||||
currentPath = path;
|
||||
dirChanged = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#include "fileBrowse.hpp"
|
||||
#include "overlay.hpp"
|
||||
#include <unistd.h>
|
||||
|
||||
extern bool touching(touchPosition touch, Structs::ButtonPos button);
|
||||
static const std::vector<Structs::ButtonPos> mainButtons = {
|
||||
{ 10, 6, 300, 22 },
|
||||
{ 10, 36, 300, 22 },
|
||||
{ 10, 66, 300, 22 },
|
||||
{ 10, 96, 300, 22 },
|
||||
{ 10, 126, 300, 22 },
|
||||
{ 10, 156, 300, 22 },
|
||||
{ 10, 186, 300, 22 }
|
||||
};
|
||||
|
||||
/*
|
||||
Sélectionnez un répertoire.
|
||||
*/
|
||||
std::string Overlays::SelectDir(const std::string &oldDir, const std::string &msg, const std::unique_ptr<Store> &store) {
|
||||
std::string currentPath = oldDir;
|
||||
bool dirChanged = false;
|
||||
int selection = 0, sPos = 0;
|
||||
|
||||
std::vector<DirEntry> dirContents;
|
||||
dirContents.clear();
|
||||
|
||||
/* Juste pour s'assurer. */
|
||||
if (access((oldDir + std::string("/")).c_str(), F_OK) == 0) {
|
||||
chdir((oldDir + std::string("/")).c_str());
|
||||
|
||||
} else {
|
||||
currentPath = "sdmc:/";
|
||||
chdir("sdmc:/");
|
||||
}
|
||||
|
||||
std::vector<DirEntry> dirContentsTemp;
|
||||
getDirectoryContents(dirContentsTemp, {"/"});
|
||||
|
||||
for(uint i = 0; i < dirContentsTemp.size(); i++) {
|
||||
dirContents.push_back(dirContentsTemp[i]);
|
||||
}
|
||||
|
||||
while(1) {
|
||||
Gui::clearTextBufs();
|
||||
C3D_FrameBegin(C3D_FRAME_SYNCDRAW);
|
||||
C2D_TargetClear(Top, TRANSPARENT);
|
||||
C2D_TargetClear(Bottom, TRANSPARENT);
|
||||
|
||||
if (store && config->usebg() && store->customBG()) {
|
||||
Gui::ScreenDraw(Top);
|
||||
Gui::Draw_Rect(0, 0, 400, 25, BAR_COLOR);
|
||||
Gui::Draw_Rect(0, 25, 400, 1, BAR_OUTL_COLOR);
|
||||
C2D_DrawImageAt(store->GetStoreImg(), 0, 26, 0.5f, nullptr);
|
||||
|
||||
} else {
|
||||
GFX::DrawTop();
|
||||
}
|
||||
|
||||
Gui::DrawStringCentered(0, 1, 0.7f, TEXT_COLOR, msg, 380, 0, font);
|
||||
|
||||
Gui::Draw_Rect(0, 215, 400, 25, BAR_COLOR);
|
||||
Gui::Draw_Rect(0, 214, 400, 1, BAR_OUTL_COLOR);
|
||||
Gui::DrawStringCentered(0, 217, 0.6f, TEXT_COLOR, currentPath, 390, 0, font);
|
||||
|
||||
GFX::DrawBottom();
|
||||
|
||||
Gui::Draw_Rect(0, 215, 320, 25, BAR_COLOR);
|
||||
Gui::Draw_Rect(0, 214, 320, 1, BAR_OUTL_COLOR);
|
||||
Gui::DrawStringCentered(0, 220, 0.5f, TEXT_COLOR, Lang::get("START_SELECT"), 310, 0, font);
|
||||
|
||||
if (dirContents.size() > 0) {
|
||||
for(int i = 0; i < 7 && i < (int)dirContents.size(); i++) {
|
||||
if (sPos + i == selection) GFX::DrawBox(mainButtons[i].x, mainButtons[i].y, mainButtons[i].w, mainButtons[i].h, false);
|
||||
Gui::DrawStringCentered(10 - 160 + (300 / 2), mainButtons[i].y + 4, 0.45f, TEXT_COLOR, dirContents[sPos + i].name, 295, 0, font);
|
||||
}
|
||||
}
|
||||
|
||||
C3D_FrameEnd(0);
|
||||
|
||||
if (dirChanged) {
|
||||
dirChanged = false;
|
||||
|
||||
selection = 0;
|
||||
sPos = 0;
|
||||
dirContents.clear();
|
||||
std::vector<DirEntry> dirContentsTemp;
|
||||
getDirectoryContents(dirContentsTemp, {"/"});
|
||||
|
||||
for(uint i = 0; i < dirContentsTemp.size(); i++) {
|
||||
dirContents.push_back(dirContentsTemp[i]);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
hidScanInput();
|
||||
touchPosition touch;
|
||||
hidTouchRead(&touch);
|
||||
u32 hRepeat = hidKeysDownRepeat();
|
||||
|
||||
if (dirContents.size() > 0) {
|
||||
if (hRepeat & KEY_DOWN) {
|
||||
if (selection < (int)dirContents.size() - 1) selection++;
|
||||
else selection = 0;
|
||||
}
|
||||
|
||||
if (hRepeat & KEY_UP) {
|
||||
if (selection > 0) selection--;
|
||||
else selection = dirContents.size() - 1;
|
||||
}
|
||||
|
||||
if (hRepeat & KEY_RIGHT) {
|
||||
if (selection + 7 < (int)dirContents.size()-1) selection += 7;
|
||||
else selection = dirContents.size()-1;
|
||||
}
|
||||
|
||||
if (hRepeat & KEY_LEFT) {
|
||||
if (selection - 7 > 0) selection -= 7;
|
||||
else selection = 0;
|
||||
}
|
||||
|
||||
if (hidKeysDown() & KEY_A) {
|
||||
if (dirContents[selection].isDirectory) {
|
||||
chdir(dirContents[selection].name.c_str());
|
||||
char path[PATH_MAX];
|
||||
getcwd(path, PATH_MAX);
|
||||
currentPath = path;
|
||||
dirChanged = true;
|
||||
}
|
||||
}
|
||||
|
||||
if (hidKeysDown() & KEY_TOUCH) {
|
||||
for (int i = 0; i < 7; i++) {
|
||||
if (touching(touch, mainButtons[i])) {
|
||||
if (i + sPos < (int)dirContents.size()) {
|
||||
if (dirContents[i + sPos].isDirectory) {
|
||||
chdir(dirContents[i + sPos].name.c_str());
|
||||
|
||||
char path[PATH_MAX];
|
||||
getcwd(path, PATH_MAX);
|
||||
currentPath = path;
|
||||
|
||||
dirChanged = true;
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (selection < sPos) sPos = selection;
|
||||
else if (selection > sPos + 7 - 1) sPos = selection - 7 + 1;
|
||||
}
|
||||
|
||||
if ((hidKeysDown() & KEY_X) || (hidKeysDown() & KEY_START)) {
|
||||
if (currentPath.size() > 0 && currentPath.back() == '/') currentPath.pop_back(); // Pop back le "/".
|
||||
return currentPath;
|
||||
}
|
||||
|
||||
if (hidKeysDown() & KEY_B) {
|
||||
char path[PATH_MAX];
|
||||
getcwd(path, PATH_MAX);
|
||||
|
||||
if (strcmp(path, "sdmc:/") == 0 || strcmp(path, "/") == 0) return "";
|
||||
else {
|
||||
chdir("..");
|
||||
getcwd(path, PATH_MAX);
|
||||
currentPath = path;
|
||||
dirChanged = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
+385
-385
@@ -1,386 +1,386 @@
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#include "download.hpp"
|
||||
#include "fileBrowse.hpp"
|
||||
#include "files.hpp"
|
||||
#include "keyboard.hpp"
|
||||
#include "overlay.hpp"
|
||||
#include "qrcode.hpp"
|
||||
#include "scriptUtils.hpp"
|
||||
#include "storeUtils.hpp"
|
||||
#include <unistd.h>
|
||||
|
||||
extern bool checkWifiStatus();
|
||||
extern void notConnectedMsg();
|
||||
extern bool touching(touchPosition touch, Structs::ButtonPos button);
|
||||
static const std::vector<Structs::ButtonPos> mainButtons = {
|
||||
{ 10, 34, 300, 22 },
|
||||
{ 10, 64, 300, 22 },
|
||||
{ 10, 94, 300, 22 },
|
||||
{ 10, 124, 300, 22 },
|
||||
{ 10, 154, 300, 22 },
|
||||
{ 10, 184, 300, 22 },
|
||||
|
||||
{ 112, 215, 16, 16 }, // Delete.
|
||||
{ 154, 215, 16, 16 }, // Update.
|
||||
{ 200, 215, 16, 16 }, // Add.
|
||||
{ 4, 0, 24, 24 } // Back.
|
||||
};
|
||||
|
||||
/*
|
||||
Supprimez un Shop.. y compris les Spritesheets, le cas échéant.
|
||||
const std::string &file : Le fichier de eShop.
|
||||
*/
|
||||
static void DeleteStore(const std::string &file) {
|
||||
FILE *temp = fopen((std::string(_STORE_PATH) + file).c_str(), "rt");
|
||||
nlohmann::json storeJson = nlohmann::json::parse(temp, nullptr, false);
|
||||
fclose(temp);
|
||||
|
||||
/* Vérifiez, si Spritesheet existe sur eShop. */
|
||||
if (storeJson["storeInfo"].contains("sheet") && storeJson["storeInfo"]["sheet"].is_array()) {
|
||||
const std::vector<std::string> sht = storeJson["storeInfo"]["sheet"].get<std::vector<std::string>>();
|
||||
|
||||
/* Parce que c’est un tableau, supprimez tous les Spritesheets qui existent. */
|
||||
for (int i = 0; i < (int)sht.size(); i++) {
|
||||
if (sht[i] != "") {
|
||||
if (!(StringUtils::lower_case(sht[i]).find(StringUtils::lower_case("/")) != std::string::npos)) {
|
||||
if (access((std::string(_STORE_PATH) + sht[i]).c_str(), F_OK) == 0) {
|
||||
deleteFile((std::string(_STORE_PATH) + sht[i]).c_str());
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/* Sinon, si c’est juste une chaîne.. vérifier et supprimer simplement Spritesheet. */
|
||||
} else if (storeJson["storeInfo"].contains("sheet") && storeJson["storeInfo"]["sheet"].is_string()) {
|
||||
const std::string fl = storeJson["storeInfo"]["sheet"];
|
||||
|
||||
if (fl != "") {
|
||||
if (!(StringUtils::lower_case(fl).find(StringUtils::lower_case("/")) != std::string::npos)) {
|
||||
if (access((std::string(_STORE_PATH) + fl).c_str(), F_OK) == 0) {
|
||||
deleteFile((std::string(_STORE_PATH) + fl).c_str());
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
deleteFile((std::string(_STORE_PATH) + file).c_str()); // Supprimez maintenant l'eShop.
|
||||
}
|
||||
|
||||
/*
|
||||
Download a Store.. including the SpriteSheets, if found.
|
||||
*/
|
||||
static bool DownloadStore() {
|
||||
bool doSheet = false;
|
||||
std::string file = "";
|
||||
|
||||
const std::string URL = QR_Scanner::StoreHandle();
|
||||
if (URL != "") doSheet = DownloadEshop(URL, -1, file, true);
|
||||
|
||||
if (doSheet) {
|
||||
FILE *temp = fopen(file.c_str(), "rt");
|
||||
nlohmann::json storeJson = nlohmann::json::parse(temp, nullptr, false);
|
||||
fclose(temp);
|
||||
|
||||
if (doSheet) {
|
||||
if (storeJson["storeInfo"].contains("sheetURL") && storeJson["storeInfo"]["sheetURL"].is_array()) {
|
||||
if (storeJson["storeInfo"].contains("sheet") && storeJson["storeInfo"]["sheet"].is_array()) {
|
||||
const std::vector<std::string> locs = storeJson["storeInfo"]["sheetURL"].get<std::vector<std::string>>();
|
||||
const std::vector<std::string> sht = storeJson["storeInfo"]["sheet"].get<std::vector<std::string>>();
|
||||
|
||||
if (locs.size() == sht.size()) {
|
||||
for (int i = 0; i < (int)sht.size(); i++) {
|
||||
if (!(sht[i].find("/") != std::string::npos)) {
|
||||
char msg[150];
|
||||
snprintf(msg, sizeof(msg), Lang::get("DOWNLOADING_SPRITE_SHEET2").c_str(), i + 1, sht.size());
|
||||
Msg::DisplayMsg(msg);
|
||||
DownloadSpriteSheet(locs[i], sht[i]);
|
||||
|
||||
} else {
|
||||
Msg::waitMsg(Lang::get("SHEET_SLASH"));
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
} else if (storeJson["storeInfo"].contains("sheetURL") && storeJson["storeInfo"]["sheetURL"].is_string()) {
|
||||
if (storeJson["storeInfo"].contains("sheet") && storeJson["storeInfo"]["sheet"].is_string()) {
|
||||
const std::string fl = storeJson["storeInfo"]["sheetURL"];
|
||||
const std::string fl2 = storeJson["storeInfo"]["sheet"];
|
||||
|
||||
if (!(fl2.find("/") != std::string::npos)) {
|
||||
Msg::DisplayMsg(Lang::get("DOWNLOADING_SPRITE_SHEET"));
|
||||
DownloadSpriteSheet(fl, fl2);
|
||||
|
||||
} else {
|
||||
Msg::waitMsg(Lang::get("SHEET_SLASH"));
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
hidScanInput(); // Re-Scan.
|
||||
return doSheet;
|
||||
}
|
||||
|
||||
static bool UpdateStore(const std::string &URL) {
|
||||
bool doSheet = false;
|
||||
std::string file = "";
|
||||
|
||||
if (URL != "") doSheet = DownloadEshop(URL, -1, file, false);
|
||||
|
||||
if (doSheet) {
|
||||
FILE *temp = fopen(file.c_str(), "rt");
|
||||
nlohmann::json storeJson = nlohmann::json::parse(temp, nullptr, false);
|
||||
fclose(temp);
|
||||
|
||||
if (doSheet) {
|
||||
if (storeJson["storeInfo"].contains("sheetURL") && storeJson["storeInfo"]["sheetURL"].is_array()) {
|
||||
if (storeJson["storeInfo"].contains("sheet") && storeJson["storeInfo"]["sheet"].is_array()) {
|
||||
const std::vector<std::string> locs = storeJson["storeInfo"]["sheetURL"].get<std::vector<std::string>>();
|
||||
const std::vector<std::string> sht = storeJson["storeInfo"]["sheet"].get<std::vector<std::string>>();
|
||||
|
||||
if (locs.size() == sht.size()) {
|
||||
for (int i = 0; i < (int)sht.size(); i++) {
|
||||
if (!(sht[i].find("/") != std::string::npos)) {
|
||||
char msg[150];
|
||||
snprintf(msg, sizeof(msg), Lang::get("DOWNLOADING_SPRITE_SHEET2").c_str(), i + 1, sht.size());
|
||||
Msg::DisplayMsg(msg);
|
||||
DownloadSpriteSheet(locs[i], sht[i]);
|
||||
|
||||
} else {
|
||||
Msg::waitMsg(Lang::get("SHEET_SLASH"));
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
} else if (storeJson["storeInfo"].contains("sheetURL") && storeJson["storeInfo"]["sheetURL"].is_string()) {
|
||||
if (storeJson["storeInfo"].contains("sheet") && storeJson["storeInfo"]["sheet"].is_string()) {
|
||||
const std::string fl = storeJson["storeInfo"]["sheetURL"];
|
||||
const std::string fl2 = storeJson["storeInfo"]["sheet"];
|
||||
|
||||
if (!(fl2.find("/") != std::string::npos)) {
|
||||
Msg::DisplayMsg(Lang::get("DOWNLOADING_SPRITE_SHEET"));
|
||||
DownloadSpriteSheet(fl, fl2);
|
||||
|
||||
} else {
|
||||
Msg::waitMsg(Lang::get("SHEET_SLASH"));
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return doSheet;
|
||||
}
|
||||
|
||||
/*
|
||||
This is the eShop Manage Handle.
|
||||
Here you can..
|
||||
- Delete a eShop.
|
||||
- Download / Add a eShop.
|
||||
- Check for Updates for a eShop.
|
||||
- Switch the eShop.
|
||||
std::unique_ptr<Store> &store: Reference to the Store class.
|
||||
std::vector<std::unique_ptr<StoreEntry>> &entries: Reference to the Store Entries.
|
||||
std::unique_ptr<Meta> &meta: Reference to the Meta class.
|
||||
*/
|
||||
void Overlays::SelectStore(std::unique_ptr<Store> &store, std::vector<std::unique_ptr<StoreEntry>> &entries, std::unique_ptr<Meta> &meta) {
|
||||
bool doOut = false;
|
||||
int selection = 0, sPos = 0;
|
||||
|
||||
std::vector<EshopInfo> info = GetEshopInfo(_STORE_PATH);
|
||||
|
||||
while(!doOut) {
|
||||
Gui::clearTextBufs();
|
||||
C3D_FrameBegin(C3D_FRAME_SYNCDRAW);
|
||||
C2D_TargetClear(Top, TRANSPARENT);
|
||||
C2D_TargetClear(Bottom, TRANSPARENT);
|
||||
|
||||
if (store && config->usebg() && store->customBG()) {
|
||||
Gui::ScreenDraw(Top);
|
||||
Gui::Draw_Rect(0, 0, 400, 25, BAR_COLOR);
|
||||
Gui::Draw_Rect(0, 25, 400, 1, BAR_OUTL_COLOR);
|
||||
C2D_DrawImageAt(store->GetStoreImg(), 0, 26, 0.5f, nullptr);
|
||||
|
||||
} else {
|
||||
GFX::DrawTop();
|
||||
}
|
||||
|
||||
if (info.size() > 0) {
|
||||
if (info[selection].StoreSize != -1) {
|
||||
Gui::DrawStringCentered(0, 1, 0.7f, TEXT_COLOR, info[selection].Title, 390, 0, font);
|
||||
Gui::DrawStringCentered(0, 30, 0.6f, TEXT_COLOR, info[selection].Author, 380, 0, font);
|
||||
Gui::DrawStringCentered(0, 70, 0.5f, TEXT_COLOR, info[selection].Description, 380, 130, font, C2D_WordWrap);
|
||||
|
||||
} else {
|
||||
Gui::DrawStringCentered(0, 1, 0.7f, TEXT_COLOR, Lang::get("INVALID_ESHOP"), 390, 0, font);
|
||||
}
|
||||
|
||||
Gui::DrawString(10, 200, 0.4, TEXT_COLOR, "- " + Lang::get("ENTRIES") + ": " + std::to_string(info[selection].StoreSize), 150, 0, font);
|
||||
Gui::DrawString(10, 210, 0.4, TEXT_COLOR, "- " + Lang::get("VERSION") + ": " + std::to_string(info[selection].Version), 150, 0, font);
|
||||
Gui::DrawString(10, 220, 0.4, TEXT_COLOR, "- " + Lang::get("REVISION") + ": " + std::to_string(info[selection].Revision), 150, 0, font);
|
||||
|
||||
GFX::DrawBottom();
|
||||
|
||||
Gui::Draw_Rect(0, 0, 320, 25, ENTRY_BAR_COLOR);
|
||||
Gui::Draw_Rect(0, 25, 320, 1, ENTRY_BAR_OUTL_COLOR);
|
||||
GFX::DrawSprite(sprites_arrow_idx, mainButtons[9].x, mainButtons[9].y);
|
||||
Gui::DrawStringCentered(0, 2, 0.6, TEXT_COLOR, Lang::get("SELECT_ESHOP_2"), 310, 0, font);
|
||||
|
||||
for(int i = 0; i < 6 && i < (int)info.size(); i++) {
|
||||
if (sPos + i == selection) GFX::DrawBox(mainButtons[i].x, mainButtons[i].y, mainButtons[i].w, mainButtons[i].h, false);
|
||||
|
||||
Gui::DrawStringCentered(10 - 160 + (300 / 2), mainButtons[i].y + 4, 0.45f, TEXT_COLOR, info[sPos + i].FileName, 295, 0, font);
|
||||
}
|
||||
}
|
||||
|
||||
if (info.size() <= 0) GFX::DrawBottom(); // Otherwise we'd draw on top.
|
||||
|
||||
GFX::DrawSprite(sprites_delete_idx, mainButtons[6].x, mainButtons[6].y);
|
||||
GFX::DrawSprite(sprites_update_idx, mainButtons[7].x, mainButtons[7].y);
|
||||
GFX::DrawSprite(sprites_add_idx, mainButtons[8].x, mainButtons[8].y);
|
||||
C3D_FrameEnd(0);
|
||||
|
||||
hidScanInput();
|
||||
touchPosition touch;
|
||||
hidTouchRead(&touch);
|
||||
u32 hRepeat = hidKeysDownRepeat();
|
||||
|
||||
if (info.size() > 0) {
|
||||
if (hRepeat & KEY_DOWN) {
|
||||
if (selection < (int)info.size() - 1) selection++;
|
||||
else selection = 0;
|
||||
}
|
||||
|
||||
if (hRepeat & KEY_UP) {
|
||||
if (selection > 0) selection--;
|
||||
else selection = info.size() - 1;
|
||||
}
|
||||
|
||||
if (hRepeat & KEY_RIGHT) {
|
||||
if (selection + 6 < (int)info.size() - 1) selection += 6;
|
||||
else selection = info.size() - 1;
|
||||
}
|
||||
|
||||
if (hRepeat & KEY_LEFT) {
|
||||
if (selection - 6 > 0) selection -= 6;
|
||||
else selection = 0;
|
||||
}
|
||||
|
||||
if (hidKeysDown() & KEY_A) {
|
||||
if (info[selection].File != "") { // Ensure to check for this.
|
||||
if (!(info[selection].File.find("/") != std::string::npos)) {
|
||||
/* Load selected one. */
|
||||
if (info[selection].Version == -1) Msg::waitMsg(Lang::get("ESHOP_INVALID_ERROR"));
|
||||
else if (info[selection].Version < 3) Msg::waitMsg(Lang::get("ESHOP_TOO_OLD"));
|
||||
else if (info[selection].Version > _ESHOP_VERSION) Msg::waitMsg(Lang::get("ESHOP_TOO_NEW"));
|
||||
else {
|
||||
config->lastStore(info[selection].FileName);
|
||||
store = std::make_unique<Store>(_STORE_PATH + info[selection].FileName, info[selection].FileName);
|
||||
StoreUtils::ResetAll(store, meta, entries);
|
||||
StoreUtils::SortEntries(false, SortType::LAST_UPDATED, entries);
|
||||
doOut = true;
|
||||
}
|
||||
|
||||
} else {
|
||||
Msg::waitMsg(Lang::get("FILE_SLASH"));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (hidKeysDown() & KEY_TOUCH) {
|
||||
for (int i = 0; i < 6; i++) {
|
||||
if (touching(touch, mainButtons[i])) {
|
||||
if (i + sPos < (int)info.size() && info[i + sPos].File != "") { // Ensure to check for this.
|
||||
if (!(info[i + sPos].File.find("/") != std::string::npos)) {
|
||||
if (info[i + sPos].Version == -1) Msg::waitMsg(Lang::get("ESHOP_INVALID_ERROR"));
|
||||
else if (info[i + sPos].Version < 3) Msg::waitMsg(Lang::get("ESHOP_TOO_OLD"));
|
||||
else if (info[i + sPos].Version > _ESHOP_VERSION) Msg::waitMsg(Lang::get("ESHOP_TOO_NEW"));
|
||||
else {
|
||||
config->lastStore(info[i + sPos].FileName);
|
||||
store = std::make_unique<Store>(_STORE_PATH + info[i + sPos].FileName, info[i + sPos].FileName);
|
||||
StoreUtils::ResetAll(store, meta, entries);
|
||||
StoreUtils::SortEntries(false, SortType::LAST_UPDATED, entries);
|
||||
doOut = true;
|
||||
}
|
||||
|
||||
} else {
|
||||
Msg::waitMsg(Lang::get("FILE_SLASH"));
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/* Supprimer l'eShop */
|
||||
if ((hidKeysDown() & KEY_X) || (hidKeysDown() & KEY_TOUCH && touching(touch, mainButtons[6]))) {
|
||||
if (info[selection].FileName != "") {
|
||||
DeleteStore(info[selection].FileName);
|
||||
selection = 0;
|
||||
info = GetEshopInfo(_STORE_PATH);
|
||||
}
|
||||
}
|
||||
|
||||
/* Télécharger le dernier eShop */
|
||||
if ((hidKeysDown() & KEY_START) || (hidKeysDown() & KEY_TOUCH && touching(touch, mainButtons[7]))) {
|
||||
if (checkWifiStatus()) {
|
||||
if (info[selection].URL != "") {
|
||||
if (UpdateStore(info[selection].URL)) {
|
||||
selection = 0;
|
||||
info = GetEshopInfo(_STORE_PATH);
|
||||
}
|
||||
}
|
||||
|
||||
} else {
|
||||
notConnectedMsg();
|
||||
}
|
||||
}
|
||||
|
||||
if (selection < sPos) sPos = selection;
|
||||
else if (selection > sPos + 6 - 1) sPos = selection - 6 + 1;
|
||||
}
|
||||
|
||||
/* Téléchargement de l'eShop depuis URL. */
|
||||
if ((hidKeysDown() & KEY_Y) || (hidKeysDown() & KEY_TOUCH && touching(touch, mainButtons[8]))) {
|
||||
if (checkWifiStatus()) {
|
||||
if (DownloadStore()) {
|
||||
selection = 0;
|
||||
info = GetEshopInfo(_STORE_PATH);
|
||||
}
|
||||
|
||||
} else {
|
||||
notConnectedMsg();
|
||||
}
|
||||
}
|
||||
|
||||
/* Go out of the menu. */
|
||||
if ((hidKeysDown() & KEY_B) || (hidKeysDown() & KEY_TOUCH && touching(touch, mainButtons[9]))) doOut = true;
|
||||
}
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#include "download.hpp"
|
||||
#include "fileBrowse.hpp"
|
||||
#include "files.hpp"
|
||||
#include "keyboard.hpp"
|
||||
#include "overlay.hpp"
|
||||
#include "qrcode.hpp"
|
||||
#include "scriptUtils.hpp"
|
||||
#include "storeUtils.hpp"
|
||||
#include <unistd.h>
|
||||
|
||||
extern bool checkWifiStatus();
|
||||
extern void notConnectedMsg();
|
||||
extern bool touching(touchPosition touch, Structs::ButtonPos button);
|
||||
static const std::vector<Structs::ButtonPos> mainButtons = {
|
||||
{ 10, 34, 300, 22 },
|
||||
{ 10, 64, 300, 22 },
|
||||
{ 10, 94, 300, 22 },
|
||||
{ 10, 124, 300, 22 },
|
||||
{ 10, 154, 300, 22 },
|
||||
{ 10, 184, 300, 22 },
|
||||
|
||||
{ 112, 215, 16, 16 }, // Delete.
|
||||
{ 154, 215, 16, 16 }, // Update.
|
||||
{ 200, 215, 16, 16 }, // Add.
|
||||
{ 4, 0, 24, 24 } // Back.
|
||||
};
|
||||
|
||||
/*
|
||||
Supprimez un Shop.. y compris les Spritesheets, le cas échéant.
|
||||
const std::string &file : Le fichier de eShop.
|
||||
*/
|
||||
static void DeleteStore(const std::string &file) {
|
||||
FILE *temp = fopen((std::string(_STORE_PATH) + file).c_str(), "rt");
|
||||
nlohmann::json storeJson = nlohmann::json::parse(temp, nullptr, false);
|
||||
fclose(temp);
|
||||
|
||||
/* Vérifiez, si Spritesheet existe sur eShop. */
|
||||
if (storeJson["storeInfo"].contains("sheet") && storeJson["storeInfo"]["sheet"].is_array()) {
|
||||
const std::vector<std::string> sht = storeJson["storeInfo"]["sheet"].get<std::vector<std::string>>();
|
||||
|
||||
/* Parce que c’est un tableau, supprimez tous les Spritesheets qui existent. */
|
||||
for (int i = 0; i < (int)sht.size(); i++) {
|
||||
if (sht[i] != "") {
|
||||
if (!(StringUtils::lower_case(sht[i]).find(StringUtils::lower_case("/")) != std::string::npos)) {
|
||||
if (access((std::string(_STORE_PATH) + sht[i]).c_str(), F_OK) == 0) {
|
||||
deleteFile((std::string(_STORE_PATH) + sht[i]).c_str());
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/* Sinon, si c’est juste une chaîne.. vérifier et supprimer simplement Spritesheet. */
|
||||
} else if (storeJson["storeInfo"].contains("sheet") && storeJson["storeInfo"]["sheet"].is_string()) {
|
||||
const std::string fl = storeJson["storeInfo"]["sheet"];
|
||||
|
||||
if (fl != "") {
|
||||
if (!(StringUtils::lower_case(fl).find(StringUtils::lower_case("/")) != std::string::npos)) {
|
||||
if (access((std::string(_STORE_PATH) + fl).c_str(), F_OK) == 0) {
|
||||
deleteFile((std::string(_STORE_PATH) + fl).c_str());
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
deleteFile((std::string(_STORE_PATH) + file).c_str()); // Supprimez maintenant l'eShop.
|
||||
}
|
||||
|
||||
/*
|
||||
Download a Store.. including the SpriteSheets, if found.
|
||||
*/
|
||||
static bool DownloadStore() {
|
||||
bool doSheet = false;
|
||||
std::string file = "";
|
||||
|
||||
const std::string URL = QR_Scanner::StoreHandle();
|
||||
if (URL != "") doSheet = DownloadEshop(URL, -1, file, true);
|
||||
|
||||
if (doSheet) {
|
||||
FILE *temp = fopen(file.c_str(), "rt");
|
||||
nlohmann::json storeJson = nlohmann::json::parse(temp, nullptr, false);
|
||||
fclose(temp);
|
||||
|
||||
if (doSheet) {
|
||||
if (storeJson["storeInfo"].contains("sheetURL") && storeJson["storeInfo"]["sheetURL"].is_array()) {
|
||||
if (storeJson["storeInfo"].contains("sheet") && storeJson["storeInfo"]["sheet"].is_array()) {
|
||||
const std::vector<std::string> locs = storeJson["storeInfo"]["sheetURL"].get<std::vector<std::string>>();
|
||||
const std::vector<std::string> sht = storeJson["storeInfo"]["sheet"].get<std::vector<std::string>>();
|
||||
|
||||
if (locs.size() == sht.size()) {
|
||||
for (int i = 0; i < (int)sht.size(); i++) {
|
||||
if (!(sht[i].find("/") != std::string::npos)) {
|
||||
char msg[150];
|
||||
snprintf(msg, sizeof(msg), Lang::get("DOWNLOADING_SPRITE_SHEET2").c_str(), i + 1, sht.size());
|
||||
Msg::DisplayMsg(msg);
|
||||
DownloadSpriteSheet(locs[i], sht[i]);
|
||||
|
||||
} else {
|
||||
Msg::waitMsg(Lang::get("SHEET_SLASH"));
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
} else if (storeJson["storeInfo"].contains("sheetURL") && storeJson["storeInfo"]["sheetURL"].is_string()) {
|
||||
if (storeJson["storeInfo"].contains("sheet") && storeJson["storeInfo"]["sheet"].is_string()) {
|
||||
const std::string fl = storeJson["storeInfo"]["sheetURL"];
|
||||
const std::string fl2 = storeJson["storeInfo"]["sheet"];
|
||||
|
||||
if (!(fl2.find("/") != std::string::npos)) {
|
||||
Msg::DisplayMsg(Lang::get("DOWNLOADING_SPRITE_SHEET"));
|
||||
DownloadSpriteSheet(fl, fl2);
|
||||
|
||||
} else {
|
||||
Msg::waitMsg(Lang::get("SHEET_SLASH"));
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
hidScanInput(); // Re-Scan.
|
||||
return doSheet;
|
||||
}
|
||||
|
||||
static bool UpdateStore(const std::string &URL) {
|
||||
bool doSheet = false;
|
||||
std::string file = "";
|
||||
|
||||
if (URL != "") doSheet = DownloadEshop(URL, -1, file, false);
|
||||
|
||||
if (doSheet) {
|
||||
FILE *temp = fopen(file.c_str(), "rt");
|
||||
nlohmann::json storeJson = nlohmann::json::parse(temp, nullptr, false);
|
||||
fclose(temp);
|
||||
|
||||
if (doSheet) {
|
||||
if (storeJson["storeInfo"].contains("sheetURL") && storeJson["storeInfo"]["sheetURL"].is_array()) {
|
||||
if (storeJson["storeInfo"].contains("sheet") && storeJson["storeInfo"]["sheet"].is_array()) {
|
||||
const std::vector<std::string> locs = storeJson["storeInfo"]["sheetURL"].get<std::vector<std::string>>();
|
||||
const std::vector<std::string> sht = storeJson["storeInfo"]["sheet"].get<std::vector<std::string>>();
|
||||
|
||||
if (locs.size() == sht.size()) {
|
||||
for (int i = 0; i < (int)sht.size(); i++) {
|
||||
if (!(sht[i].find("/") != std::string::npos)) {
|
||||
char msg[150];
|
||||
snprintf(msg, sizeof(msg), Lang::get("DOWNLOADING_SPRITE_SHEET2").c_str(), i + 1, sht.size());
|
||||
Msg::DisplayMsg(msg);
|
||||
DownloadSpriteSheet(locs[i], sht[i]);
|
||||
|
||||
} else {
|
||||
Msg::waitMsg(Lang::get("SHEET_SLASH"));
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
} else if (storeJson["storeInfo"].contains("sheetURL") && storeJson["storeInfo"]["sheetURL"].is_string()) {
|
||||
if (storeJson["storeInfo"].contains("sheet") && storeJson["storeInfo"]["sheet"].is_string()) {
|
||||
const std::string fl = storeJson["storeInfo"]["sheetURL"];
|
||||
const std::string fl2 = storeJson["storeInfo"]["sheet"];
|
||||
|
||||
if (!(fl2.find("/") != std::string::npos)) {
|
||||
Msg::DisplayMsg(Lang::get("DOWNLOADING_SPRITE_SHEET"));
|
||||
DownloadSpriteSheet(fl, fl2);
|
||||
|
||||
} else {
|
||||
Msg::waitMsg(Lang::get("SHEET_SLASH"));
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return doSheet;
|
||||
}
|
||||
|
||||
/*
|
||||
This is the eShop Manage Handle.
|
||||
Here you can..
|
||||
- Delete a eShop.
|
||||
- Download / Add a eShop.
|
||||
- Check for Updates for a eShop.
|
||||
- Switch the eShop.
|
||||
std::unique_ptr<Store> &store: Reference to the Store class.
|
||||
std::vector<std::unique_ptr<StoreEntry>> &entries: Reference to the Store Entries.
|
||||
std::unique_ptr<Meta> &meta: Reference to the Meta class.
|
||||
*/
|
||||
void Overlays::SelectStore(std::unique_ptr<Store> &store, std::vector<std::unique_ptr<StoreEntry>> &entries, std::unique_ptr<Meta> &meta) {
|
||||
bool doOut = false;
|
||||
int selection = 0, sPos = 0;
|
||||
|
||||
std::vector<EshopInfo> info = GetEshopInfo(_STORE_PATH);
|
||||
|
||||
while(!doOut) {
|
||||
Gui::clearTextBufs();
|
||||
C3D_FrameBegin(C3D_FRAME_SYNCDRAW);
|
||||
C2D_TargetClear(Top, TRANSPARENT);
|
||||
C2D_TargetClear(Bottom, TRANSPARENT);
|
||||
|
||||
if (store && config->usebg() && store->customBG()) {
|
||||
Gui::ScreenDraw(Top);
|
||||
Gui::Draw_Rect(0, 0, 400, 25, BAR_COLOR);
|
||||
Gui::Draw_Rect(0, 25, 400, 1, BAR_OUTL_COLOR);
|
||||
C2D_DrawImageAt(store->GetStoreImg(), 0, 26, 0.5f, nullptr);
|
||||
|
||||
} else {
|
||||
GFX::DrawTop();
|
||||
}
|
||||
|
||||
if (info.size() > 0) {
|
||||
if (info[selection].StoreSize != -1) {
|
||||
Gui::DrawStringCentered(0, 1, 0.7f, TEXT_COLOR, info[selection].Title, 390, 0, font);
|
||||
Gui::DrawStringCentered(0, 30, 0.6f, TEXT_COLOR, info[selection].Author, 380, 0, font);
|
||||
Gui::DrawStringCentered(0, 70, 0.5f, TEXT_COLOR, info[selection].Description, 380, 130, font, C2D_WordWrap);
|
||||
|
||||
} else {
|
||||
Gui::DrawStringCentered(0, 1, 0.7f, TEXT_COLOR, Lang::get("INVALID_ESHOP"), 390, 0, font);
|
||||
}
|
||||
|
||||
Gui::DrawString(10, 200, 0.4, TEXT_COLOR, "- " + Lang::get("ENTRIES") + ": " + std::to_string(info[selection].StoreSize), 150, 0, font);
|
||||
Gui::DrawString(10, 210, 0.4, TEXT_COLOR, "- " + Lang::get("VERSION") + ": " + std::to_string(info[selection].Version), 150, 0, font);
|
||||
Gui::DrawString(10, 220, 0.4, TEXT_COLOR, "- " + Lang::get("REVISION") + ": " + std::to_string(info[selection].Revision), 150, 0, font);
|
||||
|
||||
GFX::DrawBottom();
|
||||
|
||||
Gui::Draw_Rect(0, 0, 320, 25, ENTRY_BAR_COLOR);
|
||||
Gui::Draw_Rect(0, 25, 320, 1, ENTRY_BAR_OUTL_COLOR);
|
||||
GFX::DrawSprite(sprites_arrow_idx, mainButtons[9].x, mainButtons[9].y);
|
||||
Gui::DrawStringCentered(0, 2, 0.6, TEXT_COLOR, Lang::get("SELECT_ESHOP_2"), 310, 0, font);
|
||||
|
||||
for(int i = 0; i < 6 && i < (int)info.size(); i++) {
|
||||
if (sPos + i == selection) GFX::DrawBox(mainButtons[i].x, mainButtons[i].y, mainButtons[i].w, mainButtons[i].h, false);
|
||||
|
||||
Gui::DrawStringCentered(10 - 160 + (300 / 2), mainButtons[i].y + 4, 0.45f, TEXT_COLOR, info[sPos + i].FileName, 295, 0, font);
|
||||
}
|
||||
}
|
||||
|
||||
if (info.size() <= 0) GFX::DrawBottom(); // Otherwise we'd draw on top.
|
||||
|
||||
GFX::DrawSprite(sprites_delete_idx, mainButtons[6].x, mainButtons[6].y);
|
||||
GFX::DrawSprite(sprites_update_idx, mainButtons[7].x, mainButtons[7].y);
|
||||
GFX::DrawSprite(sprites_add_idx, mainButtons[8].x, mainButtons[8].y);
|
||||
C3D_FrameEnd(0);
|
||||
|
||||
hidScanInput();
|
||||
touchPosition touch;
|
||||
hidTouchRead(&touch);
|
||||
u32 hRepeat = hidKeysDownRepeat();
|
||||
|
||||
if (info.size() > 0) {
|
||||
if (hRepeat & KEY_DOWN) {
|
||||
if (selection < (int)info.size() - 1) selection++;
|
||||
else selection = 0;
|
||||
}
|
||||
|
||||
if (hRepeat & KEY_UP) {
|
||||
if (selection > 0) selection--;
|
||||
else selection = info.size() - 1;
|
||||
}
|
||||
|
||||
if (hRepeat & KEY_RIGHT) {
|
||||
if (selection + 6 < (int)info.size() - 1) selection += 6;
|
||||
else selection = info.size() - 1;
|
||||
}
|
||||
|
||||
if (hRepeat & KEY_LEFT) {
|
||||
if (selection - 6 > 0) selection -= 6;
|
||||
else selection = 0;
|
||||
}
|
||||
|
||||
if (hidKeysDown() & KEY_A) {
|
||||
if (info[selection].File != "") { // Ensure to check for this.
|
||||
if (!(info[selection].File.find("/") != std::string::npos)) {
|
||||
/* Load selected one. */
|
||||
if (info[selection].Version == -1) Msg::waitMsg(Lang::get("ESHOP_INVALID_ERROR"));
|
||||
else if (info[selection].Version < 3) Msg::waitMsg(Lang::get("ESHOP_TOO_OLD"));
|
||||
else if (info[selection].Version > _ESHOP_VERSION) Msg::waitMsg(Lang::get("ESHOP_TOO_NEW"));
|
||||
else {
|
||||
config->lastStore(info[selection].FileName);
|
||||
store = std::make_unique<Store>(_STORE_PATH + info[selection].FileName, info[selection].FileName);
|
||||
StoreUtils::ResetAll(store, meta, entries);
|
||||
StoreUtils::SortEntries(false, SortType::LAST_UPDATED, entries);
|
||||
doOut = true;
|
||||
}
|
||||
|
||||
} else {
|
||||
Msg::waitMsg(Lang::get("FILE_SLASH"));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (hidKeysDown() & KEY_TOUCH) {
|
||||
for (int i = 0; i < 6; i++) {
|
||||
if (touching(touch, mainButtons[i])) {
|
||||
if (i + sPos < (int)info.size() && info[i + sPos].File != "") { // Ensure to check for this.
|
||||
if (!(info[i + sPos].File.find("/") != std::string::npos)) {
|
||||
if (info[i + sPos].Version == -1) Msg::waitMsg(Lang::get("ESHOP_INVALID_ERROR"));
|
||||
else if (info[i + sPos].Version < 3) Msg::waitMsg(Lang::get("ESHOP_TOO_OLD"));
|
||||
else if (info[i + sPos].Version > _ESHOP_VERSION) Msg::waitMsg(Lang::get("ESHOP_TOO_NEW"));
|
||||
else {
|
||||
config->lastStore(info[i + sPos].FileName);
|
||||
store = std::make_unique<Store>(_STORE_PATH + info[i + sPos].FileName, info[i + sPos].FileName);
|
||||
StoreUtils::ResetAll(store, meta, entries);
|
||||
StoreUtils::SortEntries(false, SortType::LAST_UPDATED, entries);
|
||||
doOut = true;
|
||||
}
|
||||
|
||||
} else {
|
||||
Msg::waitMsg(Lang::get("FILE_SLASH"));
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/* Supprimer l'eShop */
|
||||
if ((hidKeysDown() & KEY_X) || (hidKeysDown() & KEY_TOUCH && touching(touch, mainButtons[6]))) {
|
||||
if (info[selection].FileName != "") {
|
||||
DeleteStore(info[selection].FileName);
|
||||
selection = 0;
|
||||
info = GetEshopInfo(_STORE_PATH);
|
||||
}
|
||||
}
|
||||
|
||||
/* Télécharger le dernier eShop */
|
||||
if ((hidKeysDown() & KEY_START) || (hidKeysDown() & KEY_TOUCH && touching(touch, mainButtons[7]))) {
|
||||
if (checkWifiStatus()) {
|
||||
if (info[selection].URL != "") {
|
||||
if (UpdateStore(info[selection].URL)) {
|
||||
selection = 0;
|
||||
info = GetEshopInfo(_STORE_PATH);
|
||||
}
|
||||
}
|
||||
|
||||
} else {
|
||||
notConnectedMsg();
|
||||
}
|
||||
}
|
||||
|
||||
if (selection < sPos) sPos = selection;
|
||||
else if (selection > sPos + 6 - 1) sPos = selection - 6 + 1;
|
||||
}
|
||||
|
||||
/* Téléchargement de l'eShop depuis URL. */
|
||||
if ((hidKeysDown() & KEY_Y) || (hidKeysDown() & KEY_TOUCH && touching(touch, mainButtons[8]))) {
|
||||
if (checkWifiStatus()) {
|
||||
if (DownloadStore()) {
|
||||
selection = 0;
|
||||
info = GetEshopInfo(_STORE_PATH);
|
||||
}
|
||||
|
||||
} else {
|
||||
notConnectedMsg();
|
||||
}
|
||||
}
|
||||
|
||||
/* Go out of the menu. */
|
||||
if ((hidKeysDown() & KEY_B) || (hidKeysDown() & KEY_TOUCH && touching(touch, mainButtons[9]))) doOut = true;
|
||||
}
|
||||
}
|
||||
+942
-942
File diff suppressed because it is too large
Load Diff
+1292
-1292
File diff suppressed because it is too large
Load Diff
+450
-450
@@ -1,451 +1,451 @@
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
/*
|
||||
* This file is part of PKSM
|
||||
* Copyright (C) 2016-2020 Bernardo Giordano, Admiral Fish, piepie62
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#include "common.hpp"
|
||||
#include "download.hpp"
|
||||
#include "keyboard.hpp"
|
||||
#include "qrcode.hpp"
|
||||
#include <cstring>
|
||||
|
||||
static const std::vector<Structs::ButtonPos> mainButtons = {
|
||||
{ 10, 34, 300, 22 },
|
||||
{ 10, 64, 300, 22 },
|
||||
{ 10, 94, 300, 22 },
|
||||
{ 10, 124, 300, 22 },
|
||||
{ 10, 154, 300, 22 },
|
||||
{ 10, 184, 300, 22 },
|
||||
|
||||
{ 5, 215, 24, 24 }, // QR Code / List.
|
||||
{ 35, 215, 24, 24 }, // Keyboard.
|
||||
{ 4, 0, 24, 24 } // Back.
|
||||
};
|
||||
extern bool touching(touchPosition touch, Structs::ButtonPos button);
|
||||
|
||||
/*
|
||||
Initialize everything needed for the camera.
|
||||
*/
|
||||
QRCode::QRCode() {
|
||||
this->image.tex = new C3D_Tex;
|
||||
this->image.subtex = &this->subtex;
|
||||
this->qrData = quirc_new();
|
||||
std::fill(this->cameraBuffer.begin(), this->cameraBuffer.end(), 0);
|
||||
C3D_TexInit(this->image.tex, 512, 256, GPU_RGB565);
|
||||
C3D_TexSetFilter(this->image.tex, GPU_LINEAR, GPU_LINEAR);
|
||||
this->image.tex->border = 0xFFFFFFFF;
|
||||
C3D_TexSetWrap(this->image.tex, GPU_CLAMP_TO_BORDER, GPU_CLAMP_TO_BORDER);
|
||||
LightLock_Init(&this->bufferLock);
|
||||
LightLock_Init(&this->imageLock);
|
||||
svcCreateEvent(&this->exitEvent, RESET_STICKY);
|
||||
quirc_resize(this->qrData, 400, 240);
|
||||
|
||||
if (checkWifiStatus()) this->stores = FetchStores(); // Fetching Stores here.
|
||||
|
||||
if (this->stores.size() > 0) this->displayList = true;
|
||||
}
|
||||
|
||||
/*
|
||||
Destroy everything.
|
||||
*/
|
||||
QRCode::~QRCode() {
|
||||
C3D_TexDelete(this->image.tex);
|
||||
delete this->image.tex;
|
||||
quirc_destroy(this->qrData);
|
||||
svcCloseHandle(this->exitEvent);
|
||||
}
|
||||
|
||||
/*
|
||||
mem copy the captured Image to the buffer, used for drawing.
|
||||
*/
|
||||
void QRCode::buffToImage() {
|
||||
LightLock_Lock(&this->bufferLock);
|
||||
|
||||
for (u32 x = 0; x < 400; x++) {
|
||||
for (u32 y = 0; y < 240; y++) {
|
||||
const u32 dstPos = ((((y >> 3) * (512 >> 3) + (x >> 3)) << 6) +
|
||||
((x & 1) | ((y & 1) << 1) | ((x & 2) << 1) | ((y & 2) << 2) | ((x & 4) << 2) | ((y & 4) << 3))) * 2;
|
||||
|
||||
const u32 srcPos = (y * 400 + x) * 2;
|
||||
memcpy(((u8 *)this->image.tex->data) + dstPos, ((u8 *)this->cameraBuffer.data()) + srcPos, 2);
|
||||
}
|
||||
}
|
||||
|
||||
LightLock_Unlock(&this->bufferLock);
|
||||
}
|
||||
|
||||
/*
|
||||
Finish and unlock everything.
|
||||
*/
|
||||
void QRCode::finish() {
|
||||
svcSignalEvent(this->exitEvent);
|
||||
while (!this->done()) svcSleepThread(1000000);
|
||||
LightLock_Lock(&this->bufferLock);
|
||||
LightLock_Unlock(&this->bufferLock);
|
||||
LightLock_Lock(&this->imageLock);
|
||||
LightLock_Unlock(&this->imageLock);
|
||||
}
|
||||
|
||||
/*
|
||||
The Draw Thread of the Camera.
|
||||
*/
|
||||
void QRCode::drawThread() {
|
||||
LightLock_Lock(&this->imageLock);
|
||||
|
||||
/* If we aren't done.. do the draw to scan. */
|
||||
while (!this->done()) {
|
||||
Gui::clearTextBufs();
|
||||
C3D_FrameBegin(C3D_FRAME_SYNCDRAW);
|
||||
C2D_TargetClear(Top, TRANSPARENT);
|
||||
C2D_TargetClear(Bottom, TRANSPARENT);
|
||||
|
||||
if (!this->displayList) {
|
||||
this->buffToImage(); // Fetch image.
|
||||
Gui::ScreenDraw(Top);
|
||||
C2D_DrawImageAt(this->image, 0, 0, 0.5, nullptr, 1.0f, 1.0f);
|
||||
|
||||
GFX::DrawBottom();
|
||||
Gui::Draw_Rect(0, 0, 320, 25, ENTRY_BAR_COLOR);
|
||||
Gui::Draw_Rect(0, 25, 320, 1, ENTRY_BAR_OUTL_COLOR);
|
||||
|
||||
} else {
|
||||
GFX::DrawTop();
|
||||
Gui::DrawStringCentered(0, 1, 0.7, TEXT_COLOR, Lang::get("STORE_INFO"), 390, 0, font);
|
||||
|
||||
if (this->stores.size() > 0) {
|
||||
Gui::DrawStringCentered(0, 30, 0.7f, TEXT_COLOR, this->stores[this->selectedStore].Title, 390, 0, font);
|
||||
Gui::DrawStringCentered(0, 50, 0.6f, TEXT_COLOR, this->stores[this->selectedStore].Author, 380, 0, font);
|
||||
Gui::DrawStringCentered(0, 90, 0.5f, TEXT_COLOR, this->stores[this->selectedStore].Description, 380, 130, font, C2D_WordWrap);
|
||||
}
|
||||
|
||||
GFX::DrawBottom();
|
||||
Gui::Draw_Rect(0, 0, 320, 25, ENTRY_BAR_COLOR);
|
||||
Gui::Draw_Rect(0, 25, 320, 1, ENTRY_BAR_OUTL_COLOR);
|
||||
Gui::DrawStringCentered(0, 2, 0.6, TEXT_COLOR, Lang::get("RECOMMENDED_ESHOP"), 310, 0, font);
|
||||
|
||||
for(int i = 0; i < 6 && i < (int)this->stores.size(); i++) {
|
||||
if (this->sPos + i == this->selectedStore) GFX::DrawBox(mainButtons[i].x, mainButtons[i].y, mainButtons[i].w, mainButtons[i].h, false);
|
||||
|
||||
Gui::DrawStringCentered(10 - 160 + (300 / 2), mainButtons[i].y + 4, 0.45f, TEXT_COLOR, this->stores[this->sPos + i].Title, 295, 0, font);
|
||||
}
|
||||
}
|
||||
|
||||
GFX::DrawSprite((this->displayList ? sprites_qr_code_idx : sprites_list_idx), mainButtons[6].x, mainButtons[6].y);
|
||||
if (this->displayList) GFX::DrawSprite(sprites_keyboard_idx, mainButtons[7].x, mainButtons[7].y);
|
||||
GFX::DrawSprite(sprites_arrow_idx, mainButtons[8].x, mainButtons[8].y);
|
||||
C3D_FrameEnd(0);
|
||||
}
|
||||
|
||||
LightLock_Unlock(&this->imageLock);
|
||||
}
|
||||
|
||||
/*
|
||||
The Capture Thread of the camera.
|
||||
*/
|
||||
void QRCode::captureThread() {
|
||||
Handle events[3] = { 0 };
|
||||
events[0] = exitEvent;
|
||||
u32 transferUnit;
|
||||
|
||||
u16 *buffer = new u16[400 * 240];
|
||||
camInit();
|
||||
CAMU_SetSize(SELECT_OUT1, SIZE_CTR_TOP_LCD, CONTEXT_A);
|
||||
CAMU_SetOutputFormat(SELECT_OUT1, OUTPUT_RGB_565, CONTEXT_A);
|
||||
CAMU_SetFrameRate(SELECT_OUT1, FRAME_RATE_30);
|
||||
|
||||
CAMU_SetNoiseFilter(SELECT_OUT1, true);
|
||||
CAMU_SetAutoExposure(SELECT_OUT1, true);
|
||||
CAMU_SetAutoWhiteBalance(SELECT_OUT1, true);
|
||||
CAMU_SetPhotoMode(SELECT_OUT1, PHOTO_MODE_LETTER);
|
||||
|
||||
/* No clue if this is actually effective or if it's just a placebo effect, but it seems to help? */
|
||||
CAMU_SetSharpness(SELECT_OUT1, 127);
|
||||
CAMU_Activate(SELECT_OUT1);
|
||||
CAMU_GetBufferErrorInterruptEvent(&events[2], PORT_CAM1);
|
||||
CAMU_SetTrimming(PORT_CAM1, false);
|
||||
CAMU_GetMaxBytes(&transferUnit, 400, 240);
|
||||
CAMU_SetTransferBytes(PORT_CAM1, transferUnit, 400, 240);
|
||||
CAMU_ClearBuffer(PORT_CAM1);
|
||||
CAMU_SetReceiving(&events[1], buffer, PORT_CAM1, 400 * 240 * sizeof(u16), (s16)transferUnit);
|
||||
CAMU_StartCapture(PORT_CAM1);
|
||||
|
||||
bool cancel = false;
|
||||
while (!cancel) {
|
||||
s32 index = 0;
|
||||
svcWaitSynchronizationN(&index, events, 3, false, U64_MAX);
|
||||
|
||||
switch (index) {
|
||||
case 0:
|
||||
cancel = true;
|
||||
break;
|
||||
|
||||
case 1:
|
||||
svcCloseHandle(events[1]);
|
||||
events[1] = 0;
|
||||
LightLock_Lock(&this->bufferLock);
|
||||
memcpy(this->cameraBuffer.data(), buffer, 400 * 240 * sizeof(u16));
|
||||
GSPGPU_FlushDataCache(this->cameraBuffer.data(), 400 * 240 * sizeof(u16));
|
||||
LightLock_Unlock(&this->bufferLock);
|
||||
CAMU_SetReceiving(&events[1], buffer, PORT_CAM1, 400 * 240 * sizeof(u16), transferUnit);
|
||||
break;
|
||||
|
||||
case 2:
|
||||
svcCloseHandle(events[1]);
|
||||
events[1] = 0;
|
||||
CAMU_ClearBuffer(PORT_CAM1);
|
||||
CAMU_SetReceiving(&events[1], buffer, PORT_CAM1, 400 * 240 * sizeof(u16), transferUnit);
|
||||
CAMU_StartCapture(PORT_CAM1);
|
||||
break;
|
||||
|
||||
default:
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
CAMU_StopCapture(PORT_CAM1);
|
||||
|
||||
bool busy = false;
|
||||
while (R_SUCCEEDED(CAMU_IsBusy(&busy, PORT_CAM1)) && busy) svcSleepThread(1000000);
|
||||
|
||||
CAMU_ClearBuffer(PORT_CAM1);
|
||||
CAMU_Activate(SELECT_NONE);
|
||||
camExit();
|
||||
delete[] buffer;
|
||||
|
||||
for (int i = 1; i < 3; i++) {
|
||||
if (events[i] != 0) {
|
||||
svcCloseHandle(events[i]);
|
||||
events[i] = 0;
|
||||
}
|
||||
}
|
||||
|
||||
this->finished = true;
|
||||
}
|
||||
|
||||
/*
|
||||
These are just Helpers.. because Threads.
|
||||
*/
|
||||
void drawHelper(void *arg) {
|
||||
QRCode *qrData = (QRCode *)arg;
|
||||
qrData->drawThread();
|
||||
}
|
||||
void captureHelper(void *arg) {
|
||||
QRCode *qrData = (QRCode *)arg;
|
||||
qrData->captureThread();
|
||||
}
|
||||
|
||||
/*
|
||||
Handle the capture.
|
||||
*/
|
||||
void QRCode::handler(std::string &result) {
|
||||
hidScanInput();
|
||||
touchPosition t;
|
||||
hidTouchRead(&t);
|
||||
u32 keyDown = hidKeysDown();
|
||||
u32 keyRepeat = hidKeysDownRepeat();
|
||||
|
||||
if ((keyDown & KEY_B) || (keyDown & KEY_TOUCH && touching(t, mainButtons[8]))) {
|
||||
result = "";
|
||||
this->finished = true;
|
||||
this->finish();
|
||||
return;
|
||||
}
|
||||
|
||||
/* Keyboard. */
|
||||
if (keyDown & KEY_TOUCH && touching(t, mainButtons[7])) {
|
||||
if (this->displayList) {
|
||||
const std::string temp = Input::setkbdString(150, Lang::get("ENTER_URL"), { });
|
||||
|
||||
if (temp != "") {
|
||||
result = temp;
|
||||
this->finished = true;
|
||||
this->finish();
|
||||
return;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (this->displayList) {
|
||||
gspWaitForVBlank();
|
||||
|
||||
if ((keyDown & KEY_SELECT) || (keyDown & KEY_TOUCH && touching(t, mainButtons[6]))) {
|
||||
keyDown = 0;
|
||||
this->displayList = false;
|
||||
}
|
||||
|
||||
if (this->stores.size() > 0) {
|
||||
if (keyRepeat & KEY_DOWN) {
|
||||
if (this->selectedStore < (int)this->stores.size() - 1) this->selectedStore++;
|
||||
else this->selectedStore = 0;
|
||||
}
|
||||
|
||||
if (keyRepeat & KEY_UP) {
|
||||
if (this->selectedStore > 0) this->selectedStore--;
|
||||
else this->selectedStore = (int)this->stores.size() - 1;
|
||||
}
|
||||
|
||||
if (keyDown & KEY_A) {
|
||||
result = this->stores[this->selectedStore].URL;
|
||||
this->finished = true;
|
||||
this->finish();
|
||||
return;
|
||||
}
|
||||
|
||||
if (keyDown & KEY_TOUCH) {
|
||||
for (int i = 0; i < 6; i++) {
|
||||
if (touching(t, mainButtons[i])) {
|
||||
if (i + this->sPos < (int)this->stores.size()) {
|
||||
result = this->stores[i + this->sPos].URL;
|
||||
this->finished = true;
|
||||
this->finish();
|
||||
return;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
} else {
|
||||
if (this->stores.size() > 0) {
|
||||
if ((keyDown & KEY_SELECT) || (keyDown & KEY_TOUCH && touching(t, mainButtons[6]))) {
|
||||
keyDown = 0;
|
||||
this->displayList = true;
|
||||
}
|
||||
}
|
||||
|
||||
if (!this->capturing) {
|
||||
/* create camera capture thread. */
|
||||
if (threadCreate((ThreadFunc)&captureHelper, this, 0x10000, 0x1A, 1, true) != NULL) this->capturing = true;
|
||||
else {
|
||||
this->finish();
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
if (this->done()) return;
|
||||
|
||||
int w, h;
|
||||
u8 *image = (u8 *)quirc_begin(this->qrData, &w, &h);
|
||||
LightLock_Lock(&bufferLock);
|
||||
|
||||
for (ssize_t x = 0; x < w; x++) {
|
||||
for (ssize_t y = 0; y < h; y++) {
|
||||
u16 px = this->cameraBuffer[y * 400 + x];
|
||||
image[y * w + x] = (u8)(((((px >> 11) & 0x1F) << 3) + (((px >> 5) & 0x3F) << 2) + ((px & 0x1F) << 3)) / 3);
|
||||
}
|
||||
}
|
||||
|
||||
LightLock_Unlock(&this->bufferLock);
|
||||
quirc_end(this->qrData);
|
||||
|
||||
if (quirc_count(this->qrData) > 0) {
|
||||
struct quirc_code code;
|
||||
struct quirc_data scan_data;
|
||||
quirc_extract(this->qrData, 0, &code);
|
||||
|
||||
if (!quirc_decode(&code, &scan_data)) {
|
||||
this->finish();
|
||||
this->out.resize(scan_data.payload_len);
|
||||
std::copy(scan_data.payload, scan_data.payload + scan_data.payload_len, this->out.begin());
|
||||
|
||||
/* From scanned stuff. */
|
||||
if (this->out.empty()) result = "";
|
||||
|
||||
/* If Terminator, do -1. */
|
||||
if (this->out.back() == '\0') result = std::string((char *)this->out.data(), this->out.size() - 1);
|
||||
else result = std::string((char *)this->out.data(), this->out.size());
|
||||
}
|
||||
}
|
||||
|
||||
if (this->selectedStore < this->sPos) this->sPos = this->selectedStore;
|
||||
else if (this->selectedStore > this->sPos + 6 - 1) this->sPos = this->selectedStore - 6 + 1;
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
The Store Add QR Code handle and such.
|
||||
*/
|
||||
std::string QR_Scanner::StoreHandle() {
|
||||
std::string result = "";
|
||||
|
||||
std::unique_ptr<QRCode> qrData = std::make_unique<QRCode>();
|
||||
aptSetHomeAllowed(false); // Block the Home key.
|
||||
threadCreate((ThreadFunc)&drawHelper, qrData.get(), 0x10000, 0x1A, 1, true);
|
||||
while (!qrData->done()) qrData->handler(result); // Handle.
|
||||
aptSetHomeAllowed(true); // Re-Allow it.
|
||||
|
||||
return result;
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
/*
|
||||
* This file is part of PKSM
|
||||
* Copyright (C) 2016-2020 Bernardo Giordano, Admiral Fish, piepie62
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#include "common.hpp"
|
||||
#include "download.hpp"
|
||||
#include "keyboard.hpp"
|
||||
#include "qrcode.hpp"
|
||||
#include <cstring>
|
||||
|
||||
static const std::vector<Structs::ButtonPos> mainButtons = {
|
||||
{ 10, 34, 300, 22 },
|
||||
{ 10, 64, 300, 22 },
|
||||
{ 10, 94, 300, 22 },
|
||||
{ 10, 124, 300, 22 },
|
||||
{ 10, 154, 300, 22 },
|
||||
{ 10, 184, 300, 22 },
|
||||
|
||||
{ 5, 215, 24, 24 }, // QR Code / List.
|
||||
{ 35, 215, 24, 24 }, // Keyboard.
|
||||
{ 4, 0, 24, 24 } // Back.
|
||||
};
|
||||
extern bool touching(touchPosition touch, Structs::ButtonPos button);
|
||||
|
||||
/*
|
||||
Initialize everything needed for the camera.
|
||||
*/
|
||||
QRCode::QRCode() {
|
||||
this->image.tex = new C3D_Tex;
|
||||
this->image.subtex = &this->subtex;
|
||||
this->qrData = quirc_new();
|
||||
std::fill(this->cameraBuffer.begin(), this->cameraBuffer.end(), 0);
|
||||
C3D_TexInit(this->image.tex, 512, 256, GPU_RGB565);
|
||||
C3D_TexSetFilter(this->image.tex, GPU_LINEAR, GPU_LINEAR);
|
||||
this->image.tex->border = 0xFFFFFFFF;
|
||||
C3D_TexSetWrap(this->image.tex, GPU_CLAMP_TO_BORDER, GPU_CLAMP_TO_BORDER);
|
||||
LightLock_Init(&this->bufferLock);
|
||||
LightLock_Init(&this->imageLock);
|
||||
svcCreateEvent(&this->exitEvent, RESET_STICKY);
|
||||
quirc_resize(this->qrData, 400, 240);
|
||||
|
||||
if (checkWifiStatus()) this->stores = FetchStores(); // Fetching Stores here.
|
||||
|
||||
if (this->stores.size() > 0) this->displayList = true;
|
||||
}
|
||||
|
||||
/*
|
||||
Destroy everything.
|
||||
*/
|
||||
QRCode::~QRCode() {
|
||||
C3D_TexDelete(this->image.tex);
|
||||
delete this->image.tex;
|
||||
quirc_destroy(this->qrData);
|
||||
svcCloseHandle(this->exitEvent);
|
||||
}
|
||||
|
||||
/*
|
||||
mem copy the captured Image to the buffer, used for drawing.
|
||||
*/
|
||||
void QRCode::buffToImage() {
|
||||
LightLock_Lock(&this->bufferLock);
|
||||
|
||||
for (u32 x = 0; x < 400; x++) {
|
||||
for (u32 y = 0; y < 240; y++) {
|
||||
const u32 dstPos = ((((y >> 3) * (512 >> 3) + (x >> 3)) << 6) +
|
||||
((x & 1) | ((y & 1) << 1) | ((x & 2) << 1) | ((y & 2) << 2) | ((x & 4) << 2) | ((y & 4) << 3))) * 2;
|
||||
|
||||
const u32 srcPos = (y * 400 + x) * 2;
|
||||
memcpy(((u8 *)this->image.tex->data) + dstPos, ((u8 *)this->cameraBuffer.data()) + srcPos, 2);
|
||||
}
|
||||
}
|
||||
|
||||
LightLock_Unlock(&this->bufferLock);
|
||||
}
|
||||
|
||||
/*
|
||||
Finish and unlock everything.
|
||||
*/
|
||||
void QRCode::finish() {
|
||||
svcSignalEvent(this->exitEvent);
|
||||
while (!this->done()) svcSleepThread(1000000);
|
||||
LightLock_Lock(&this->bufferLock);
|
||||
LightLock_Unlock(&this->bufferLock);
|
||||
LightLock_Lock(&this->imageLock);
|
||||
LightLock_Unlock(&this->imageLock);
|
||||
}
|
||||
|
||||
/*
|
||||
The Draw Thread of the Camera.
|
||||
*/
|
||||
void QRCode::drawThread() {
|
||||
LightLock_Lock(&this->imageLock);
|
||||
|
||||
/* If we aren't done.. do the draw to scan. */
|
||||
while (!this->done()) {
|
||||
Gui::clearTextBufs();
|
||||
C3D_FrameBegin(C3D_FRAME_SYNCDRAW);
|
||||
C2D_TargetClear(Top, TRANSPARENT);
|
||||
C2D_TargetClear(Bottom, TRANSPARENT);
|
||||
|
||||
if (!this->displayList) {
|
||||
this->buffToImage(); // Fetch image.
|
||||
Gui::ScreenDraw(Top);
|
||||
C2D_DrawImageAt(this->image, 0, 0, 0.5, nullptr, 1.0f, 1.0f);
|
||||
|
||||
GFX::DrawBottom();
|
||||
Gui::Draw_Rect(0, 0, 320, 25, ENTRY_BAR_COLOR);
|
||||
Gui::Draw_Rect(0, 25, 320, 1, ENTRY_BAR_OUTL_COLOR);
|
||||
|
||||
} else {
|
||||
GFX::DrawTop();
|
||||
Gui::DrawStringCentered(0, 1, 0.7, TEXT_COLOR, Lang::get("STORE_INFO"), 390, 0, font);
|
||||
|
||||
if (this->stores.size() > 0) {
|
||||
Gui::DrawStringCentered(0, 30, 0.7f, TEXT_COLOR, this->stores[this->selectedStore].Title, 390, 0, font);
|
||||
Gui::DrawStringCentered(0, 50, 0.6f, TEXT_COLOR, this->stores[this->selectedStore].Author, 380, 0, font);
|
||||
Gui::DrawStringCentered(0, 90, 0.5f, TEXT_COLOR, this->stores[this->selectedStore].Description, 380, 130, font, C2D_WordWrap);
|
||||
}
|
||||
|
||||
GFX::DrawBottom();
|
||||
Gui::Draw_Rect(0, 0, 320, 25, ENTRY_BAR_COLOR);
|
||||
Gui::Draw_Rect(0, 25, 320, 1, ENTRY_BAR_OUTL_COLOR);
|
||||
Gui::DrawStringCentered(0, 2, 0.6, TEXT_COLOR, Lang::get("RECOMMENDED_ESHOP"), 310, 0, font);
|
||||
|
||||
for(int i = 0; i < 6 && i < (int)this->stores.size(); i++) {
|
||||
if (this->sPos + i == this->selectedStore) GFX::DrawBox(mainButtons[i].x, mainButtons[i].y, mainButtons[i].w, mainButtons[i].h, false);
|
||||
|
||||
Gui::DrawStringCentered(10 - 160 + (300 / 2), mainButtons[i].y + 4, 0.45f, TEXT_COLOR, this->stores[this->sPos + i].Title, 295, 0, font);
|
||||
}
|
||||
}
|
||||
|
||||
GFX::DrawSprite((this->displayList ? sprites_qr_code_idx : sprites_list_idx), mainButtons[6].x, mainButtons[6].y);
|
||||
if (this->displayList) GFX::DrawSprite(sprites_keyboard_idx, mainButtons[7].x, mainButtons[7].y);
|
||||
GFX::DrawSprite(sprites_arrow_idx, mainButtons[8].x, mainButtons[8].y);
|
||||
C3D_FrameEnd(0);
|
||||
}
|
||||
|
||||
LightLock_Unlock(&this->imageLock);
|
||||
}
|
||||
|
||||
/*
|
||||
The Capture Thread of the camera.
|
||||
*/
|
||||
void QRCode::captureThread() {
|
||||
Handle events[3] = { 0 };
|
||||
events[0] = exitEvent;
|
||||
u32 transferUnit;
|
||||
|
||||
u16 *buffer = new u16[400 * 240];
|
||||
camInit();
|
||||
CAMU_SetSize(SELECT_OUT1, SIZE_CTR_TOP_LCD, CONTEXT_A);
|
||||
CAMU_SetOutputFormat(SELECT_OUT1, OUTPUT_RGB_565, CONTEXT_A);
|
||||
CAMU_SetFrameRate(SELECT_OUT1, FRAME_RATE_30);
|
||||
|
||||
CAMU_SetNoiseFilter(SELECT_OUT1, true);
|
||||
CAMU_SetAutoExposure(SELECT_OUT1, true);
|
||||
CAMU_SetAutoWhiteBalance(SELECT_OUT1, true);
|
||||
CAMU_SetPhotoMode(SELECT_OUT1, PHOTO_MODE_LETTER);
|
||||
|
||||
/* No clue if this is actually effective or if it's just a placebo effect, but it seems to help? */
|
||||
CAMU_SetSharpness(SELECT_OUT1, 127);
|
||||
CAMU_Activate(SELECT_OUT1);
|
||||
CAMU_GetBufferErrorInterruptEvent(&events[2], PORT_CAM1);
|
||||
CAMU_SetTrimming(PORT_CAM1, false);
|
||||
CAMU_GetMaxBytes(&transferUnit, 400, 240);
|
||||
CAMU_SetTransferBytes(PORT_CAM1, transferUnit, 400, 240);
|
||||
CAMU_ClearBuffer(PORT_CAM1);
|
||||
CAMU_SetReceiving(&events[1], buffer, PORT_CAM1, 400 * 240 * sizeof(u16), (s16)transferUnit);
|
||||
CAMU_StartCapture(PORT_CAM1);
|
||||
|
||||
bool cancel = false;
|
||||
while (!cancel) {
|
||||
s32 index = 0;
|
||||
svcWaitSynchronizationN(&index, events, 3, false, U64_MAX);
|
||||
|
||||
switch (index) {
|
||||
case 0:
|
||||
cancel = true;
|
||||
break;
|
||||
|
||||
case 1:
|
||||
svcCloseHandle(events[1]);
|
||||
events[1] = 0;
|
||||
LightLock_Lock(&this->bufferLock);
|
||||
memcpy(this->cameraBuffer.data(), buffer, 400 * 240 * sizeof(u16));
|
||||
GSPGPU_FlushDataCache(this->cameraBuffer.data(), 400 * 240 * sizeof(u16));
|
||||
LightLock_Unlock(&this->bufferLock);
|
||||
CAMU_SetReceiving(&events[1], buffer, PORT_CAM1, 400 * 240 * sizeof(u16), transferUnit);
|
||||
break;
|
||||
|
||||
case 2:
|
||||
svcCloseHandle(events[1]);
|
||||
events[1] = 0;
|
||||
CAMU_ClearBuffer(PORT_CAM1);
|
||||
CAMU_SetReceiving(&events[1], buffer, PORT_CAM1, 400 * 240 * sizeof(u16), transferUnit);
|
||||
CAMU_StartCapture(PORT_CAM1);
|
||||
break;
|
||||
|
||||
default:
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
CAMU_StopCapture(PORT_CAM1);
|
||||
|
||||
bool busy = false;
|
||||
while (R_SUCCEEDED(CAMU_IsBusy(&busy, PORT_CAM1)) && busy) svcSleepThread(1000000);
|
||||
|
||||
CAMU_ClearBuffer(PORT_CAM1);
|
||||
CAMU_Activate(SELECT_NONE);
|
||||
camExit();
|
||||
delete[] buffer;
|
||||
|
||||
for (int i = 1; i < 3; i++) {
|
||||
if (events[i] != 0) {
|
||||
svcCloseHandle(events[i]);
|
||||
events[i] = 0;
|
||||
}
|
||||
}
|
||||
|
||||
this->finished = true;
|
||||
}
|
||||
|
||||
/*
|
||||
These are just Helpers.. because Threads.
|
||||
*/
|
||||
void drawHelper(void *arg) {
|
||||
QRCode *qrData = (QRCode *)arg;
|
||||
qrData->drawThread();
|
||||
}
|
||||
void captureHelper(void *arg) {
|
||||
QRCode *qrData = (QRCode *)arg;
|
||||
qrData->captureThread();
|
||||
}
|
||||
|
||||
/*
|
||||
Handle the capture.
|
||||
*/
|
||||
void QRCode::handler(std::string &result) {
|
||||
hidScanInput();
|
||||
touchPosition t;
|
||||
hidTouchRead(&t);
|
||||
u32 keyDown = hidKeysDown();
|
||||
u32 keyRepeat = hidKeysDownRepeat();
|
||||
|
||||
if ((keyDown & KEY_B) || (keyDown & KEY_TOUCH && touching(t, mainButtons[8]))) {
|
||||
result = "";
|
||||
this->finished = true;
|
||||
this->finish();
|
||||
return;
|
||||
}
|
||||
|
||||
/* Keyboard. */
|
||||
if (keyDown & KEY_TOUCH && touching(t, mainButtons[7])) {
|
||||
if (this->displayList) {
|
||||
const std::string temp = Input::setkbdString(150, Lang::get("ENTER_URL"), { });
|
||||
|
||||
if (temp != "") {
|
||||
result = temp;
|
||||
this->finished = true;
|
||||
this->finish();
|
||||
return;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (this->displayList) {
|
||||
gspWaitForVBlank();
|
||||
|
||||
if ((keyDown & KEY_SELECT) || (keyDown & KEY_TOUCH && touching(t, mainButtons[6]))) {
|
||||
keyDown = 0;
|
||||
this->displayList = false;
|
||||
}
|
||||
|
||||
if (this->stores.size() > 0) {
|
||||
if (keyRepeat & KEY_DOWN) {
|
||||
if (this->selectedStore < (int)this->stores.size() - 1) this->selectedStore++;
|
||||
else this->selectedStore = 0;
|
||||
}
|
||||
|
||||
if (keyRepeat & KEY_UP) {
|
||||
if (this->selectedStore > 0) this->selectedStore--;
|
||||
else this->selectedStore = (int)this->stores.size() - 1;
|
||||
}
|
||||
|
||||
if (keyDown & KEY_A) {
|
||||
result = this->stores[this->selectedStore].URL;
|
||||
this->finished = true;
|
||||
this->finish();
|
||||
return;
|
||||
}
|
||||
|
||||
if (keyDown & KEY_TOUCH) {
|
||||
for (int i = 0; i < 6; i++) {
|
||||
if (touching(t, mainButtons[i])) {
|
||||
if (i + this->sPos < (int)this->stores.size()) {
|
||||
result = this->stores[i + this->sPos].URL;
|
||||
this->finished = true;
|
||||
this->finish();
|
||||
return;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
} else {
|
||||
if (this->stores.size() > 0) {
|
||||
if ((keyDown & KEY_SELECT) || (keyDown & KEY_TOUCH && touching(t, mainButtons[6]))) {
|
||||
keyDown = 0;
|
||||
this->displayList = true;
|
||||
}
|
||||
}
|
||||
|
||||
if (!this->capturing) {
|
||||
/* create camera capture thread. */
|
||||
if (threadCreate((ThreadFunc)&captureHelper, this, 0x10000, 0x1A, 1, true) != NULL) this->capturing = true;
|
||||
else {
|
||||
this->finish();
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
if (this->done()) return;
|
||||
|
||||
int w, h;
|
||||
u8 *image = (u8 *)quirc_begin(this->qrData, &w, &h);
|
||||
LightLock_Lock(&bufferLock);
|
||||
|
||||
for (ssize_t x = 0; x < w; x++) {
|
||||
for (ssize_t y = 0; y < h; y++) {
|
||||
u16 px = this->cameraBuffer[y * 400 + x];
|
||||
image[y * w + x] = (u8)(((((px >> 11) & 0x1F) << 3) + (((px >> 5) & 0x3F) << 2) + ((px & 0x1F) << 3)) / 3);
|
||||
}
|
||||
}
|
||||
|
||||
LightLock_Unlock(&this->bufferLock);
|
||||
quirc_end(this->qrData);
|
||||
|
||||
if (quirc_count(this->qrData) > 0) {
|
||||
struct quirc_code code;
|
||||
struct quirc_data scan_data;
|
||||
quirc_extract(this->qrData, 0, &code);
|
||||
|
||||
if (!quirc_decode(&code, &scan_data)) {
|
||||
this->finish();
|
||||
this->out.resize(scan_data.payload_len);
|
||||
std::copy(scan_data.payload, scan_data.payload + scan_data.payload_len, this->out.begin());
|
||||
|
||||
/* From scanned stuff. */
|
||||
if (this->out.empty()) result = "";
|
||||
|
||||
/* If Terminator, do -1. */
|
||||
if (this->out.back() == '\0') result = std::string((char *)this->out.data(), this->out.size() - 1);
|
||||
else result = std::string((char *)this->out.data(), this->out.size());
|
||||
}
|
||||
}
|
||||
|
||||
if (this->selectedStore < this->sPos) this->sPos = this->selectedStore;
|
||||
else if (this->selectedStore > this->sPos + 6 - 1) this->sPos = this->selectedStore - 6 + 1;
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
The Store Add QR Code handle and such.
|
||||
*/
|
||||
std::string QR_Scanner::StoreHandle() {
|
||||
std::string result = "";
|
||||
|
||||
std::unique_ptr<QRCode> qrData = std::make_unique<QRCode>();
|
||||
aptSetHomeAllowed(false); // Block the Home key.
|
||||
threadCreate((ThreadFunc)&drawHelper, qrData.get(), 0x10000, 0x1A, 1, true);
|
||||
while (!qrData->done()) qrData->handler(result); // Handle.
|
||||
aptSetHomeAllowed(true); // Re-Allow it.
|
||||
|
||||
return result;
|
||||
}
|
||||
+100
-100
@@ -1,101 +1,101 @@
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
/* quirc -- QR-code recognition library
|
||||
* Copyright (C) 2010-2012 Daniel Beer <dlbeer@gmail.com>
|
||||
*
|
||||
* Permission to use, copy, modify, and/or distribute this software for any
|
||||
* purpose with or without fee is hereby granted, provided that the above
|
||||
* copyright notice and this permission notice appear in all copies.
|
||||
*
|
||||
* THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
* WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
* MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
* ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
* WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
* ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
* OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
#include "quirc_internal.hpp"
|
||||
|
||||
const char *quirc_version(void) { return "1.0"; }
|
||||
|
||||
struct quirc *quirc_new(void) {
|
||||
struct quirc *q = (quirc *)malloc(sizeof(*q));
|
||||
|
||||
if (!q) return NULL;
|
||||
|
||||
memset(q, 0, sizeof(*q));
|
||||
return q;
|
||||
}
|
||||
|
||||
void quirc_destroy(struct quirc *q) {
|
||||
if (q->image) free(q->image);
|
||||
if (sizeof(*q->image) != sizeof(*q->pixels)) free(q->pixels);
|
||||
|
||||
free(q);
|
||||
}
|
||||
|
||||
int quirc_resize(struct quirc *q, int w, int h) {
|
||||
uint8_t *new_image = (uint8_t *)realloc(q->image, w * h);
|
||||
|
||||
if (!new_image) return -1;
|
||||
|
||||
if (sizeof(*q->image) != sizeof(*q->pixels)) {
|
||||
size_t new_size = w * h * sizeof(quirc_pixel_t);
|
||||
quirc_pixel_t *new_pixels = (quirc_pixel_t *)realloc(q->pixels, new_size);
|
||||
if (!new_pixels) return -1;
|
||||
q->pixels = new_pixels;
|
||||
}
|
||||
|
||||
q->image = new_image;
|
||||
q->w = w;
|
||||
q->h = h;
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
int quirc_count(const struct quirc *q) { return q->num_grids; }
|
||||
|
||||
static const char *const error_table[] = {
|
||||
[QUIRC_SUCCESS] = "Success",
|
||||
[QUIRC_ERROR_INVALID_GRID_SIZE] = "Invalid grid size",
|
||||
[QUIRC_ERROR_INVALID_VERSION] = "Invalid version",
|
||||
[QUIRC_ERROR_FORMAT_ECC] = "Format data ECC failure",
|
||||
[QUIRC_ERROR_DATA_ECC] = "ECC failure",
|
||||
[QUIRC_ERROR_UNKNOWN_DATA_TYPE] = "Unknown data type",
|
||||
[QUIRC_ERROR_DATA_OVERFLOW] = "Data overflow",
|
||||
[QUIRC_ERROR_DATA_UNDERFLOW] = "Data underflow"
|
||||
};
|
||||
|
||||
const char *quirc_strerror(quirc_decode_error_t err) {
|
||||
if (err < sizeof(error_table) / sizeof(error_table[0])) return error_table[err];
|
||||
|
||||
return "Unknown error";
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
/* quirc -- QR-code recognition library
|
||||
* Copyright (C) 2010-2012 Daniel Beer <dlbeer@gmail.com>
|
||||
*
|
||||
* Permission to use, copy, modify, and/or distribute this software for any
|
||||
* purpose with or without fee is hereby granted, provided that the above
|
||||
* copyright notice and this permission notice appear in all copies.
|
||||
*
|
||||
* THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
* WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
* MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
* ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
* WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
* ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
* OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
#include "quirc_internal.hpp"
|
||||
|
||||
const char *quirc_version(void) { return "1.0"; }
|
||||
|
||||
struct quirc *quirc_new(void) {
|
||||
struct quirc *q = (quirc *)malloc(sizeof(*q));
|
||||
|
||||
if (!q) return NULL;
|
||||
|
||||
memset(q, 0, sizeof(*q));
|
||||
return q;
|
||||
}
|
||||
|
||||
void quirc_destroy(struct quirc *q) {
|
||||
if (q->image) free(q->image);
|
||||
if (sizeof(*q->image) != sizeof(*q->pixels)) free(q->pixels);
|
||||
|
||||
free(q);
|
||||
}
|
||||
|
||||
int quirc_resize(struct quirc *q, int w, int h) {
|
||||
uint8_t *new_image = (uint8_t *)realloc(q->image, w * h);
|
||||
|
||||
if (!new_image) return -1;
|
||||
|
||||
if (sizeof(*q->image) != sizeof(*q->pixels)) {
|
||||
size_t new_size = w * h * sizeof(quirc_pixel_t);
|
||||
quirc_pixel_t *new_pixels = (quirc_pixel_t *)realloc(q->pixels, new_size);
|
||||
if (!new_pixels) return -1;
|
||||
q->pixels = new_pixels;
|
||||
}
|
||||
|
||||
q->image = new_image;
|
||||
q->w = w;
|
||||
q->h = h;
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
int quirc_count(const struct quirc *q) { return q->num_grids; }
|
||||
|
||||
static const char *const error_table[] = {
|
||||
[QUIRC_SUCCESS] = "Success",
|
||||
[QUIRC_ERROR_INVALID_GRID_SIZE] = "Invalid grid size",
|
||||
[QUIRC_ERROR_INVALID_VERSION] = "Invalid version",
|
||||
[QUIRC_ERROR_FORMAT_ECC] = "Format data ECC failure",
|
||||
[QUIRC_ERROR_DATA_ECC] = "ECC failure",
|
||||
[QUIRC_ERROR_UNKNOWN_DATA_TYPE] = "Unknown data type",
|
||||
[QUIRC_ERROR_DATA_OVERFLOW] = "Data overflow",
|
||||
[QUIRC_ERROR_DATA_UNDERFLOW] = "Data underflow"
|
||||
};
|
||||
|
||||
const char *quirc_strerror(quirc_decode_error_t err) {
|
||||
if (err < sizeof(error_table) / sizeof(error_table[0])) return error_table[err];
|
||||
|
||||
return "Unknown error";
|
||||
}
|
||||
+447
-447
@@ -1,447 +1,447 @@
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
/* quirc -- QR-code recognition library
|
||||
* Copyright (C) 2010-2012 Daniel Beer <dlbeer@gmail.com>
|
||||
*
|
||||
* Permission to use, copy, modify, and/or distribute this software for any
|
||||
* purpose with or without fee is hereby granted, provided that the above
|
||||
* copyright notice and this permission notice appear in all copies.
|
||||
*
|
||||
* THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
* WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
* MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
* ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
* WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
* ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
* OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
|
||||
#include "quirc_internal.hpp"
|
||||
|
||||
const struct quirc_version_info quirc_version_db[QUIRC_MAX_VERSION + 1] = {
|
||||
{0},
|
||||
{ /* Version 1 */
|
||||
.data_bytes = 26,
|
||||
.apat = {0},
|
||||
.ecc = {
|
||||
{.bs = 26, .dw = 16, .ce = 4},
|
||||
{.bs = 26, .dw = 19, .ce = 2},
|
||||
{.bs = 26, .dw = 9, .ce = 8},
|
||||
{.bs = 26, .dw = 13, .ce = 6}
|
||||
}
|
||||
},
|
||||
{ /* Version 2 */
|
||||
.data_bytes = 44,
|
||||
.apat = {6, 18, 0},
|
||||
.ecc = {
|
||||
{.bs = 44, .dw = 28, .ce = 8},
|
||||
{.bs = 44, .dw = 34, .ce = 4},
|
||||
{.bs = 44, .dw = 16, .ce = 14},
|
||||
{.bs = 44, .dw = 22, .ce = 11}
|
||||
}
|
||||
},
|
||||
{ /* Version 3 */
|
||||
.data_bytes = 70,
|
||||
.apat = {6, 22, 0},
|
||||
.ecc = {
|
||||
{.bs = 70, .dw = 44, .ce = 13},
|
||||
{.bs = 70, .dw = 55, .ce = 7},
|
||||
{.bs = 35, .dw = 13, .ce = 11},
|
||||
{.bs = 35, .dw = 17, .ce = 9}
|
||||
}
|
||||
},
|
||||
{ /* Version 4 */
|
||||
.data_bytes = 100,
|
||||
.apat = {6, 26, 0},
|
||||
.ecc = {
|
||||
{.bs = 50, .dw = 32, .ce = 9},
|
||||
{.bs = 100, .dw = 80, .ce = 10},
|
||||
{.bs = 25, .dw = 9, .ce = 8},
|
||||
{.bs = 50, .dw = 24, .ce = 13}
|
||||
}
|
||||
},
|
||||
{ /* Version 5 */
|
||||
.data_bytes = 134,
|
||||
.apat = {6, 30, 0},
|
||||
.ecc = {
|
||||
{.bs = 67, .dw = 43, .ce = 12},
|
||||
{.bs = 134, .dw = 108, .ce = 13},
|
||||
{.bs = 33, .dw = 11, .ce = 11},
|
||||
{.bs = 33, .dw = 15, .ce = 9}
|
||||
}
|
||||
},
|
||||
{ /* Version 6 */
|
||||
.data_bytes = 172,
|
||||
.apat = {6, 34, 0},
|
||||
.ecc = {
|
||||
{.bs = 43, .dw = 27, .ce = 8},
|
||||
{.bs = 86, .dw = 68, .ce = 9},
|
||||
{.bs = 43, .dw = 15, .ce = 14},
|
||||
{.bs = 43, .dw = 19, .ce = 12}
|
||||
}
|
||||
},
|
||||
{ /* Version 7 */
|
||||
.data_bytes = 196,
|
||||
.apat = {6, 22, 38, 0},
|
||||
.ecc = {
|
||||
{.bs = 49, .dw = 31, .ce = 9},
|
||||
{.bs = 98, .dw = 78, .ce = 10},
|
||||
{.bs = 39, .dw = 13, .ce = 13},
|
||||
{.bs = 32, .dw = 14, .ce = 9}
|
||||
}
|
||||
},
|
||||
{ /* Version 8 */
|
||||
.data_bytes = 242,
|
||||
.apat = {6, 24, 42, 0},
|
||||
.ecc = {
|
||||
{.bs = 60, .dw = 38, .ce = 11},
|
||||
{.bs = 121, .dw = 97, .ce = 12},
|
||||
{.bs = 40, .dw = 14, .ce = 13},
|
||||
{.bs = 40, .dw = 18, .ce = 11}
|
||||
}
|
||||
},
|
||||
{ /* Version 9 */
|
||||
.data_bytes = 292,
|
||||
.apat = {6, 26, 46, 0},
|
||||
.ecc = {
|
||||
{.bs = 58, .dw = 36, .ce = 11},
|
||||
{.bs = 146, .dw = 116, .ce = 15},
|
||||
{.bs = 36, .dw = 12, .ce = 12},
|
||||
{.bs = 36, .dw = 16, .ce = 10}
|
||||
}
|
||||
},
|
||||
{ /* Version 10 */
|
||||
.data_bytes = 346,
|
||||
.apat = {6, 28, 50, 0},
|
||||
.ecc = {
|
||||
{.bs = 69, .dw = 43, .ce = 13},
|
||||
{.bs = 86, .dw = 68, .ce = 9},
|
||||
{.bs = 43, .dw = 15, .ce = 14},
|
||||
{.bs = 43, .dw = 19, .ce = 12}
|
||||
}
|
||||
},
|
||||
{ /* Version 11 */
|
||||
.data_bytes = 404,
|
||||
.apat = {6, 30, 54, 0},
|
||||
.ecc = {
|
||||
{.bs = 80, .dw = 50, .ce = 15},
|
||||
{.bs = 101, .dw = 81, .ce = 10},
|
||||
{.bs = 36, .dw = 12, .ce = 12},
|
||||
{.bs = 50, .dw = 22, .ce = 14}
|
||||
}
|
||||
},
|
||||
{ /* Version 12 */
|
||||
.data_bytes = 466,
|
||||
.apat = {6, 32, 58, 0},
|
||||
.ecc = {
|
||||
{.bs = 58, .dw = 36, .ce = 11},
|
||||
{.bs = 116, .dw = 92, .ce = 12},
|
||||
{.bs = 42, .dw = 14, .ce = 14},
|
||||
{.bs = 46, .dw = 20, .ce = 14}
|
||||
}
|
||||
},
|
||||
{ /* Version 13 */
|
||||
.data_bytes = 532,
|
||||
.apat = {6, 34, 62, 0},
|
||||
.ecc = {
|
||||
{.bs = 59, .dw = 37, .ce = 11},
|
||||
{.bs = 133, .dw = 107, .ce = 13},
|
||||
{.bs = 33, .dw = 11, .ce = 11},
|
||||
{.bs = 44, .dw = 20, .ce = 12}
|
||||
}
|
||||
},
|
||||
{ /* Version 14 */
|
||||
.data_bytes = 581,
|
||||
.apat = {6, 26, 46, 66, 0},
|
||||
.ecc = {
|
||||
{.bs = 65, .dw = 41, .ce = 12},
|
||||
{.bs = 109, .dw = 87, .ce = 11},
|
||||
{.bs = 36, .dw = 12, .ce = 12},
|
||||
{.bs = 54, .dw = 24, .ce = 15}
|
||||
}
|
||||
},
|
||||
{ /* Version 15 */
|
||||
.data_bytes = 655,
|
||||
.apat = {6, 26, 48, 70, 0},
|
||||
.ecc = {
|
||||
{.bs = 65, .dw = 41, .ce = 12},
|
||||
{.bs = 109, .dw = 87, .ce = 11},
|
||||
{.bs = 36, .dw = 12, .ce = 12},
|
||||
{.bs = 54, .dw = 24, .ce = 15}
|
||||
}
|
||||
},
|
||||
{ /* Version 16 */
|
||||
.data_bytes = 733,
|
||||
.apat = {6, 26, 50, 74, 0},
|
||||
.ecc = {
|
||||
{.bs = 73, .dw = 45, .ce = 14},
|
||||
{.bs = 122, .dw = 98, .ce = 12},
|
||||
{.bs = 45, .dw = 15, .ce = 15},
|
||||
{.bs = 43, .dw = 19, .ce = 12}
|
||||
}
|
||||
},
|
||||
{ /* Version 17 */
|
||||
.data_bytes = 815,
|
||||
.apat = {6, 30, 54, 78, 0},
|
||||
.ecc = {
|
||||
{.bs = 74, .dw = 46, .ce = 14},
|
||||
{.bs = 135, .dw = 107, .ce = 14},
|
||||
{.bs = 42, .dw = 14, .ce = 14},
|
||||
{.bs = 50, .dw = 22, .ce = 14}
|
||||
}
|
||||
},
|
||||
{ /* Version 18 */
|
||||
.data_bytes = 901,
|
||||
.apat = {6, 30, 56, 82, 0},
|
||||
.ecc = {
|
||||
{.bs = 69, .dw = 43, .ce = 13},
|
||||
{.bs = 150, .dw = 120, .ce = 15},
|
||||
{.bs = 42, .dw = 14, .ce = 14},
|
||||
{.bs = 50, .dw = 22, .ce = 14}
|
||||
}
|
||||
},
|
||||
{ /* Version 19 */
|
||||
.data_bytes = 991,
|
||||
.apat = {6, 30, 58, 86, 0},
|
||||
.ecc = {
|
||||
{.bs = 70, .dw = 44, .ce = 13},
|
||||
{.bs = 141, .dw = 113, .ce = 14},
|
||||
{.bs = 39, .dw = 13, .ce = 13},
|
||||
{.bs = 47, .dw = 21, .ce = 13}
|
||||
}
|
||||
},
|
||||
{ /* Version 20 */
|
||||
.data_bytes = 1085,
|
||||
.apat = {6, 34, 62, 90, 0},
|
||||
.ecc = {
|
||||
{.bs = 67, .dw = 41, .ce = 13},
|
||||
{.bs = 135, .dw = 107, .ce = 14},
|
||||
{.bs = 43, .dw = 15, .ce = 14},
|
||||
{.bs = 54, .dw = 24, .ce = 15}
|
||||
}
|
||||
},
|
||||
{ /* Version 21 */
|
||||
.data_bytes = 1156,
|
||||
.apat = {6, 28, 50, 72, 92, 0},
|
||||
.ecc = {
|
||||
{.bs = 68, .dw = 42, .ce = 13},
|
||||
{.bs = 144, .dw = 116, .ce = 14},
|
||||
{.bs = 46, .dw = 16, .ce = 15},
|
||||
{.bs = 50, .dw = 22, .ce = 14}
|
||||
}
|
||||
},
|
||||
{ /* Version 22 */
|
||||
.data_bytes = 1258,
|
||||
.apat = {6, 26, 50, 74, 98, 0},
|
||||
.ecc = {
|
||||
{.bs = 74, .dw = 46, .ce = 14},
|
||||
{.bs = 139, .dw = 111, .ce = 14},
|
||||
{.bs = 37, .dw = 13, .ce = 12},
|
||||
{.bs = 54, .dw = 24, .ce = 15}
|
||||
}
|
||||
},
|
||||
{ /* Version 23 */
|
||||
.data_bytes = 1364,
|
||||
.apat = {6, 30, 54, 78, 102, 0},
|
||||
.ecc = {
|
||||
{.bs = 75, .dw = 47, .ce = 14},
|
||||
{.bs = 151, .dw = 121, .ce = 15},
|
||||
{.bs = 45, .dw = 15, .ce = 15},
|
||||
{.bs = 54, .dw = 24, .ce = 15}
|
||||
}
|
||||
},
|
||||
{ /* Version 24 */
|
||||
.data_bytes = 1474,
|
||||
.apat = {6, 28, 54, 80, 106, 0},
|
||||
.ecc = {
|
||||
{.bs = 73, .dw = 45, .ce = 14},
|
||||
{.bs = 147, .dw = 117, .ce = 15},
|
||||
{.bs = 46, .dw = 16, .ce = 15},
|
||||
{.bs = 54, .dw = 24, .ce = 15}
|
||||
}
|
||||
},
|
||||
{ /* Version 25 */
|
||||
.data_bytes = 1588,
|
||||
.apat = {6, 32, 58, 84, 110, 0},
|
||||
.ecc = {
|
||||
{.bs = 75, .dw = 47, .ce = 14},
|
||||
{.bs = 132, .dw = 106, .ce = 13},
|
||||
{.bs = 45, .dw = 15, .ce = 15},
|
||||
{.bs = 54, .dw = 24, .ce = 15}
|
||||
}
|
||||
},
|
||||
{ /* Version 26 */
|
||||
.data_bytes = 1706,
|
||||
.apat = {6, 30, 58, 86, 114, 0},
|
||||
.ecc = {
|
||||
{.bs = 74, .dw = 46, .ce = 14},
|
||||
{.bs = 142, .dw = 114, .ce = 14},
|
||||
{.bs = 46, .dw = 16, .ce = 15},
|
||||
{.bs = 50, .dw = 22, .ce = 14}
|
||||
}
|
||||
},
|
||||
{ /* Version 27 */
|
||||
.data_bytes = 1828,
|
||||
.apat = {6, 34, 62, 90, 118, 0},
|
||||
.ecc = {
|
||||
{.bs = 73, .dw = 45, .ce = 14},
|
||||
{.bs = 152, .dw = 122, .ce = 15},
|
||||
{.bs = 45, .dw = 15, .ce = 15},
|
||||
{.bs = 53, .dw = 23, .ce = 15}
|
||||
}
|
||||
},
|
||||
{ /* Version 28 */
|
||||
.data_bytes = 1921,
|
||||
.apat = {6, 26, 50, 74, 98, 122, 0},
|
||||
.ecc = {
|
||||
{.bs = 73, .dw = 45, .ce = 14},
|
||||
{.bs = 147, .dw = 117, .ce = 15},
|
||||
{.bs = 45, .dw = 15, .ce = 15},
|
||||
{.bs = 54, .dw = 24, .ce = 15}
|
||||
}
|
||||
},
|
||||
{ /* Version 29 */
|
||||
.data_bytes = 2051,
|
||||
.apat = {6, 30, 54, 78, 102, 126, 0},
|
||||
.ecc = {
|
||||
{.bs = 73, .dw = 45, .ce = 14},
|
||||
{.bs = 146, .dw = 116, .ce = 15},
|
||||
{.bs = 45, .dw = 15, .ce = 15},
|
||||
{.bs = 73, .dw = 45, .ce = 14}
|
||||
}
|
||||
},
|
||||
{ /* Version 30 */
|
||||
.data_bytes = 2185,
|
||||
.apat = {6, 26, 52, 78, 104, 130, 0},
|
||||
.ecc = {
|
||||
{.bs = 75, .dw = 47, .ce = 14},
|
||||
{.bs = 145, .dw = 115, .ce = 15},
|
||||
{.bs = 45, .dw = 15, .ce = 15},
|
||||
{.bs = 54, .dw = 24, .ce = 15}
|
||||
}
|
||||
},
|
||||
{ /* Version 31 */
|
||||
.data_bytes = 2323,
|
||||
.apat = {6, 30, 56, 82, 108, 134, 0},
|
||||
.ecc = {
|
||||
{.bs = 74, .dw = 46, .ce = 14},
|
||||
{.bs = 145, .dw = 115, .ce = 15},
|
||||
{.bs = 45, .dw = 15, .ce = 15},
|
||||
{.bs = 54, .dw = 24, .ce = 15}
|
||||
}
|
||||
},
|
||||
{ /* Version 32 */
|
||||
.data_bytes = 2465,
|
||||
.apat = {6, 34, 60, 86, 112, 138, 0},
|
||||
.ecc = {
|
||||
{.bs = 74, .dw = 46, .ce = 14},
|
||||
{.bs = 145, .dw = 115, .ce = 15},
|
||||
{.bs = 45, .dw = 15, .ce = 15},
|
||||
{.bs = 54, .dw = 24, .ce = 15}
|
||||
}
|
||||
},
|
||||
{ /* Version 33 */
|
||||
.data_bytes = 2611,
|
||||
.apat = {6, 30, 58, 96, 114, 142, 0},
|
||||
.ecc = {
|
||||
{.bs = 74, .dw = 46, .ce = 14},
|
||||
{.bs = 145, .dw = 115, .ce = 15},
|
||||
{.bs = 45, .dw = 15, .ce = 15},
|
||||
{.bs = 54, .dw = 24, .ce = 15}
|
||||
}
|
||||
},
|
||||
{ /* Version 34 */
|
||||
.data_bytes = 2761,
|
||||
.apat = {6, 34, 62, 90, 118, 146, 0},
|
||||
.ecc = {
|
||||
{.bs = 74, .dw = 46, .ce = 14},
|
||||
{.bs = 145, .dw = 115, .ce = 15},
|
||||
{.bs = 46, .dw = 16, .ce = 15},
|
||||
{.bs = 54, .dw = 24, .ce = 15}
|
||||
}
|
||||
},
|
||||
{ /* Version 35 */
|
||||
.data_bytes = 2876,
|
||||
.apat = {6, 30, 54, 78, 102, 126, 150},
|
||||
.ecc = {
|
||||
{.bs = 75, .dw = 47, .ce = 14},
|
||||
{.bs = 151, .dw = 121, .ce = 15},
|
||||
{.bs = 45, .dw = 15, .ce = 15},
|
||||
{.bs = 54, .dw = 24, .ce = 15}
|
||||
}
|
||||
},
|
||||
{ /* Version 36 */
|
||||
.data_bytes = 3034,
|
||||
.apat = {6, 24, 50, 76, 102, 128, 154},
|
||||
.ecc = {
|
||||
{.bs = 75, .dw = 47, .ce = 14},
|
||||
{.bs = 151, .dw = 121, .ce = 15},
|
||||
{.bs = 45, .dw = 15, .ce = 15},
|
||||
{.bs = 54, .dw = 24, .ce = 15}
|
||||
}
|
||||
},
|
||||
{ /* Version 37 */
|
||||
.data_bytes = 3196,
|
||||
.apat = {6, 28, 54, 80, 106, 132, 158},
|
||||
.ecc = {
|
||||
{.bs = 74, .dw = 46, .ce = 14},
|
||||
{.bs = 152, .dw = 122, .ce = 15},
|
||||
{.bs = 45, .dw = 15, .ce = 15},
|
||||
{.bs = 54, .dw = 24, .ce = 15}
|
||||
}
|
||||
},
|
||||
{ /* Version 38 */
|
||||
.data_bytes = 3362,
|
||||
.apat = {6, 32, 58, 84, 110, 136, 162},
|
||||
.ecc = {
|
||||
{.bs = 74, .dw = 46, .ce = 14},
|
||||
{.bs = 152, .dw = 122, .ce = 15},
|
||||
{.bs = 45, .dw = 15, .ce = 15},
|
||||
{.bs = 54, .dw = 24, .ce = 15}
|
||||
}
|
||||
},
|
||||
{ /* Version 39 */
|
||||
.data_bytes = 3532,
|
||||
.apat = {6, 26, 54, 82, 110, 138, 166},
|
||||
.ecc = {
|
||||
{.bs = 75, .dw = 47, .ce = 14},
|
||||
{.bs = 147, .dw = 117, .ce = 15},
|
||||
{.bs = 45, .dw = 15, .ce = 15},
|
||||
{.bs = 54, .dw = 24, .ce = 15}
|
||||
}
|
||||
},
|
||||
{ /* Version 40 */
|
||||
.data_bytes = 3706,
|
||||
.apat = {6, 30, 58, 86, 114, 142, 170},
|
||||
.ecc = {
|
||||
{.bs = 75, .dw = 47, .ce = 14},
|
||||
{.bs = 148, .dw = 118, .ce = 15},
|
||||
{.bs = 45, .dw = 15, .ce = 15},
|
||||
{.bs = 54, .dw = 24, .ce = 15}
|
||||
}
|
||||
}
|
||||
};
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
/* quirc -- QR-code recognition library
|
||||
* Copyright (C) 2010-2012 Daniel Beer <dlbeer@gmail.com>
|
||||
*
|
||||
* Permission to use, copy, modify, and/or distribute this software for any
|
||||
* purpose with or without fee is hereby granted, provided that the above
|
||||
* copyright notice and this permission notice appear in all copies.
|
||||
*
|
||||
* THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
* WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
* MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
* ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
* WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
* ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
* OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
|
||||
#include "quirc_internal.hpp"
|
||||
|
||||
const struct quirc_version_info quirc_version_db[QUIRC_MAX_VERSION + 1] = {
|
||||
{0},
|
||||
{ /* Version 1 */
|
||||
.data_bytes = 26,
|
||||
.apat = {0},
|
||||
.ecc = {
|
||||
{.bs = 26, .dw = 16, .ce = 4},
|
||||
{.bs = 26, .dw = 19, .ce = 2},
|
||||
{.bs = 26, .dw = 9, .ce = 8},
|
||||
{.bs = 26, .dw = 13, .ce = 6}
|
||||
}
|
||||
},
|
||||
{ /* Version 2 */
|
||||
.data_bytes = 44,
|
||||
.apat = {6, 18, 0},
|
||||
.ecc = {
|
||||
{.bs = 44, .dw = 28, .ce = 8},
|
||||
{.bs = 44, .dw = 34, .ce = 4},
|
||||
{.bs = 44, .dw = 16, .ce = 14},
|
||||
{.bs = 44, .dw = 22, .ce = 11}
|
||||
}
|
||||
},
|
||||
{ /* Version 3 */
|
||||
.data_bytes = 70,
|
||||
.apat = {6, 22, 0},
|
||||
.ecc = {
|
||||
{.bs = 70, .dw = 44, .ce = 13},
|
||||
{.bs = 70, .dw = 55, .ce = 7},
|
||||
{.bs = 35, .dw = 13, .ce = 11},
|
||||
{.bs = 35, .dw = 17, .ce = 9}
|
||||
}
|
||||
},
|
||||
{ /* Version 4 */
|
||||
.data_bytes = 100,
|
||||
.apat = {6, 26, 0},
|
||||
.ecc = {
|
||||
{.bs = 50, .dw = 32, .ce = 9},
|
||||
{.bs = 100, .dw = 80, .ce = 10},
|
||||
{.bs = 25, .dw = 9, .ce = 8},
|
||||
{.bs = 50, .dw = 24, .ce = 13}
|
||||
}
|
||||
},
|
||||
{ /* Version 5 */
|
||||
.data_bytes = 134,
|
||||
.apat = {6, 30, 0},
|
||||
.ecc = {
|
||||
{.bs = 67, .dw = 43, .ce = 12},
|
||||
{.bs = 134, .dw = 108, .ce = 13},
|
||||
{.bs = 33, .dw = 11, .ce = 11},
|
||||
{.bs = 33, .dw = 15, .ce = 9}
|
||||
}
|
||||
},
|
||||
{ /* Version 6 */
|
||||
.data_bytes = 172,
|
||||
.apat = {6, 34, 0},
|
||||
.ecc = {
|
||||
{.bs = 43, .dw = 27, .ce = 8},
|
||||
{.bs = 86, .dw = 68, .ce = 9},
|
||||
{.bs = 43, .dw = 15, .ce = 14},
|
||||
{.bs = 43, .dw = 19, .ce = 12}
|
||||
}
|
||||
},
|
||||
{ /* Version 7 */
|
||||
.data_bytes = 196,
|
||||
.apat = {6, 22, 38, 0},
|
||||
.ecc = {
|
||||
{.bs = 49, .dw = 31, .ce = 9},
|
||||
{.bs = 98, .dw = 78, .ce = 10},
|
||||
{.bs = 39, .dw = 13, .ce = 13},
|
||||
{.bs = 32, .dw = 14, .ce = 9}
|
||||
}
|
||||
},
|
||||
{ /* Version 8 */
|
||||
.data_bytes = 242,
|
||||
.apat = {6, 24, 42, 0},
|
||||
.ecc = {
|
||||
{.bs = 60, .dw = 38, .ce = 11},
|
||||
{.bs = 121, .dw = 97, .ce = 12},
|
||||
{.bs = 40, .dw = 14, .ce = 13},
|
||||
{.bs = 40, .dw = 18, .ce = 11}
|
||||
}
|
||||
},
|
||||
{ /* Version 9 */
|
||||
.data_bytes = 292,
|
||||
.apat = {6, 26, 46, 0},
|
||||
.ecc = {
|
||||
{.bs = 58, .dw = 36, .ce = 11},
|
||||
{.bs = 146, .dw = 116, .ce = 15},
|
||||
{.bs = 36, .dw = 12, .ce = 12},
|
||||
{.bs = 36, .dw = 16, .ce = 10}
|
||||
}
|
||||
},
|
||||
{ /* Version 10 */
|
||||
.data_bytes = 346,
|
||||
.apat = {6, 28, 50, 0},
|
||||
.ecc = {
|
||||
{.bs = 69, .dw = 43, .ce = 13},
|
||||
{.bs = 86, .dw = 68, .ce = 9},
|
||||
{.bs = 43, .dw = 15, .ce = 14},
|
||||
{.bs = 43, .dw = 19, .ce = 12}
|
||||
}
|
||||
},
|
||||
{ /* Version 11 */
|
||||
.data_bytes = 404,
|
||||
.apat = {6, 30, 54, 0},
|
||||
.ecc = {
|
||||
{.bs = 80, .dw = 50, .ce = 15},
|
||||
{.bs = 101, .dw = 81, .ce = 10},
|
||||
{.bs = 36, .dw = 12, .ce = 12},
|
||||
{.bs = 50, .dw = 22, .ce = 14}
|
||||
}
|
||||
},
|
||||
{ /* Version 12 */
|
||||
.data_bytes = 466,
|
||||
.apat = {6, 32, 58, 0},
|
||||
.ecc = {
|
||||
{.bs = 58, .dw = 36, .ce = 11},
|
||||
{.bs = 116, .dw = 92, .ce = 12},
|
||||
{.bs = 42, .dw = 14, .ce = 14},
|
||||
{.bs = 46, .dw = 20, .ce = 14}
|
||||
}
|
||||
},
|
||||
{ /* Version 13 */
|
||||
.data_bytes = 532,
|
||||
.apat = {6, 34, 62, 0},
|
||||
.ecc = {
|
||||
{.bs = 59, .dw = 37, .ce = 11},
|
||||
{.bs = 133, .dw = 107, .ce = 13},
|
||||
{.bs = 33, .dw = 11, .ce = 11},
|
||||
{.bs = 44, .dw = 20, .ce = 12}
|
||||
}
|
||||
},
|
||||
{ /* Version 14 */
|
||||
.data_bytes = 581,
|
||||
.apat = {6, 26, 46, 66, 0},
|
||||
.ecc = {
|
||||
{.bs = 65, .dw = 41, .ce = 12},
|
||||
{.bs = 109, .dw = 87, .ce = 11},
|
||||
{.bs = 36, .dw = 12, .ce = 12},
|
||||
{.bs = 54, .dw = 24, .ce = 15}
|
||||
}
|
||||
},
|
||||
{ /* Version 15 */
|
||||
.data_bytes = 655,
|
||||
.apat = {6, 26, 48, 70, 0},
|
||||
.ecc = {
|
||||
{.bs = 65, .dw = 41, .ce = 12},
|
||||
{.bs = 109, .dw = 87, .ce = 11},
|
||||
{.bs = 36, .dw = 12, .ce = 12},
|
||||
{.bs = 54, .dw = 24, .ce = 15}
|
||||
}
|
||||
},
|
||||
{ /* Version 16 */
|
||||
.data_bytes = 733,
|
||||
.apat = {6, 26, 50, 74, 0},
|
||||
.ecc = {
|
||||
{.bs = 73, .dw = 45, .ce = 14},
|
||||
{.bs = 122, .dw = 98, .ce = 12},
|
||||
{.bs = 45, .dw = 15, .ce = 15},
|
||||
{.bs = 43, .dw = 19, .ce = 12}
|
||||
}
|
||||
},
|
||||
{ /* Version 17 */
|
||||
.data_bytes = 815,
|
||||
.apat = {6, 30, 54, 78, 0},
|
||||
.ecc = {
|
||||
{.bs = 74, .dw = 46, .ce = 14},
|
||||
{.bs = 135, .dw = 107, .ce = 14},
|
||||
{.bs = 42, .dw = 14, .ce = 14},
|
||||
{.bs = 50, .dw = 22, .ce = 14}
|
||||
}
|
||||
},
|
||||
{ /* Version 18 */
|
||||
.data_bytes = 901,
|
||||
.apat = {6, 30, 56, 82, 0},
|
||||
.ecc = {
|
||||
{.bs = 69, .dw = 43, .ce = 13},
|
||||
{.bs = 150, .dw = 120, .ce = 15},
|
||||
{.bs = 42, .dw = 14, .ce = 14},
|
||||
{.bs = 50, .dw = 22, .ce = 14}
|
||||
}
|
||||
},
|
||||
{ /* Version 19 */
|
||||
.data_bytes = 991,
|
||||
.apat = {6, 30, 58, 86, 0},
|
||||
.ecc = {
|
||||
{.bs = 70, .dw = 44, .ce = 13},
|
||||
{.bs = 141, .dw = 113, .ce = 14},
|
||||
{.bs = 39, .dw = 13, .ce = 13},
|
||||
{.bs = 47, .dw = 21, .ce = 13}
|
||||
}
|
||||
},
|
||||
{ /* Version 20 */
|
||||
.data_bytes = 1085,
|
||||
.apat = {6, 34, 62, 90, 0},
|
||||
.ecc = {
|
||||
{.bs = 67, .dw = 41, .ce = 13},
|
||||
{.bs = 135, .dw = 107, .ce = 14},
|
||||
{.bs = 43, .dw = 15, .ce = 14},
|
||||
{.bs = 54, .dw = 24, .ce = 15}
|
||||
}
|
||||
},
|
||||
{ /* Version 21 */
|
||||
.data_bytes = 1156,
|
||||
.apat = {6, 28, 50, 72, 92, 0},
|
||||
.ecc = {
|
||||
{.bs = 68, .dw = 42, .ce = 13},
|
||||
{.bs = 144, .dw = 116, .ce = 14},
|
||||
{.bs = 46, .dw = 16, .ce = 15},
|
||||
{.bs = 50, .dw = 22, .ce = 14}
|
||||
}
|
||||
},
|
||||
{ /* Version 22 */
|
||||
.data_bytes = 1258,
|
||||
.apat = {6, 26, 50, 74, 98, 0},
|
||||
.ecc = {
|
||||
{.bs = 74, .dw = 46, .ce = 14},
|
||||
{.bs = 139, .dw = 111, .ce = 14},
|
||||
{.bs = 37, .dw = 13, .ce = 12},
|
||||
{.bs = 54, .dw = 24, .ce = 15}
|
||||
}
|
||||
},
|
||||
{ /* Version 23 */
|
||||
.data_bytes = 1364,
|
||||
.apat = {6, 30, 54, 78, 102, 0},
|
||||
.ecc = {
|
||||
{.bs = 75, .dw = 47, .ce = 14},
|
||||
{.bs = 151, .dw = 121, .ce = 15},
|
||||
{.bs = 45, .dw = 15, .ce = 15},
|
||||
{.bs = 54, .dw = 24, .ce = 15}
|
||||
}
|
||||
},
|
||||
{ /* Version 24 */
|
||||
.data_bytes = 1474,
|
||||
.apat = {6, 28, 54, 80, 106, 0},
|
||||
.ecc = {
|
||||
{.bs = 73, .dw = 45, .ce = 14},
|
||||
{.bs = 147, .dw = 117, .ce = 15},
|
||||
{.bs = 46, .dw = 16, .ce = 15},
|
||||
{.bs = 54, .dw = 24, .ce = 15}
|
||||
}
|
||||
},
|
||||
{ /* Version 25 */
|
||||
.data_bytes = 1588,
|
||||
.apat = {6, 32, 58, 84, 110, 0},
|
||||
.ecc = {
|
||||
{.bs = 75, .dw = 47, .ce = 14},
|
||||
{.bs = 132, .dw = 106, .ce = 13},
|
||||
{.bs = 45, .dw = 15, .ce = 15},
|
||||
{.bs = 54, .dw = 24, .ce = 15}
|
||||
}
|
||||
},
|
||||
{ /* Version 26 */
|
||||
.data_bytes = 1706,
|
||||
.apat = {6, 30, 58, 86, 114, 0},
|
||||
.ecc = {
|
||||
{.bs = 74, .dw = 46, .ce = 14},
|
||||
{.bs = 142, .dw = 114, .ce = 14},
|
||||
{.bs = 46, .dw = 16, .ce = 15},
|
||||
{.bs = 50, .dw = 22, .ce = 14}
|
||||
}
|
||||
},
|
||||
{ /* Version 27 */
|
||||
.data_bytes = 1828,
|
||||
.apat = {6, 34, 62, 90, 118, 0},
|
||||
.ecc = {
|
||||
{.bs = 73, .dw = 45, .ce = 14},
|
||||
{.bs = 152, .dw = 122, .ce = 15},
|
||||
{.bs = 45, .dw = 15, .ce = 15},
|
||||
{.bs = 53, .dw = 23, .ce = 15}
|
||||
}
|
||||
},
|
||||
{ /* Version 28 */
|
||||
.data_bytes = 1921,
|
||||
.apat = {6, 26, 50, 74, 98, 122, 0},
|
||||
.ecc = {
|
||||
{.bs = 73, .dw = 45, .ce = 14},
|
||||
{.bs = 147, .dw = 117, .ce = 15},
|
||||
{.bs = 45, .dw = 15, .ce = 15},
|
||||
{.bs = 54, .dw = 24, .ce = 15}
|
||||
}
|
||||
},
|
||||
{ /* Version 29 */
|
||||
.data_bytes = 2051,
|
||||
.apat = {6, 30, 54, 78, 102, 126, 0},
|
||||
.ecc = {
|
||||
{.bs = 73, .dw = 45, .ce = 14},
|
||||
{.bs = 146, .dw = 116, .ce = 15},
|
||||
{.bs = 45, .dw = 15, .ce = 15},
|
||||
{.bs = 73, .dw = 45, .ce = 14}
|
||||
}
|
||||
},
|
||||
{ /* Version 30 */
|
||||
.data_bytes = 2185,
|
||||
.apat = {6, 26, 52, 78, 104, 130, 0},
|
||||
.ecc = {
|
||||
{.bs = 75, .dw = 47, .ce = 14},
|
||||
{.bs = 145, .dw = 115, .ce = 15},
|
||||
{.bs = 45, .dw = 15, .ce = 15},
|
||||
{.bs = 54, .dw = 24, .ce = 15}
|
||||
}
|
||||
},
|
||||
{ /* Version 31 */
|
||||
.data_bytes = 2323,
|
||||
.apat = {6, 30, 56, 82, 108, 134, 0},
|
||||
.ecc = {
|
||||
{.bs = 74, .dw = 46, .ce = 14},
|
||||
{.bs = 145, .dw = 115, .ce = 15},
|
||||
{.bs = 45, .dw = 15, .ce = 15},
|
||||
{.bs = 54, .dw = 24, .ce = 15}
|
||||
}
|
||||
},
|
||||
{ /* Version 32 */
|
||||
.data_bytes = 2465,
|
||||
.apat = {6, 34, 60, 86, 112, 138, 0},
|
||||
.ecc = {
|
||||
{.bs = 74, .dw = 46, .ce = 14},
|
||||
{.bs = 145, .dw = 115, .ce = 15},
|
||||
{.bs = 45, .dw = 15, .ce = 15},
|
||||
{.bs = 54, .dw = 24, .ce = 15}
|
||||
}
|
||||
},
|
||||
{ /* Version 33 */
|
||||
.data_bytes = 2611,
|
||||
.apat = {6, 30, 58, 96, 114, 142, 0},
|
||||
.ecc = {
|
||||
{.bs = 74, .dw = 46, .ce = 14},
|
||||
{.bs = 145, .dw = 115, .ce = 15},
|
||||
{.bs = 45, .dw = 15, .ce = 15},
|
||||
{.bs = 54, .dw = 24, .ce = 15}
|
||||
}
|
||||
},
|
||||
{ /* Version 34 */
|
||||
.data_bytes = 2761,
|
||||
.apat = {6, 34, 62, 90, 118, 146, 0},
|
||||
.ecc = {
|
||||
{.bs = 74, .dw = 46, .ce = 14},
|
||||
{.bs = 145, .dw = 115, .ce = 15},
|
||||
{.bs = 46, .dw = 16, .ce = 15},
|
||||
{.bs = 54, .dw = 24, .ce = 15}
|
||||
}
|
||||
},
|
||||
{ /* Version 35 */
|
||||
.data_bytes = 2876,
|
||||
.apat = {6, 30, 54, 78, 102, 126, 150},
|
||||
.ecc = {
|
||||
{.bs = 75, .dw = 47, .ce = 14},
|
||||
{.bs = 151, .dw = 121, .ce = 15},
|
||||
{.bs = 45, .dw = 15, .ce = 15},
|
||||
{.bs = 54, .dw = 24, .ce = 15}
|
||||
}
|
||||
},
|
||||
{ /* Version 36 */
|
||||
.data_bytes = 3034,
|
||||
.apat = {6, 24, 50, 76, 102, 128, 154},
|
||||
.ecc = {
|
||||
{.bs = 75, .dw = 47, .ce = 14},
|
||||
{.bs = 151, .dw = 121, .ce = 15},
|
||||
{.bs = 45, .dw = 15, .ce = 15},
|
||||
{.bs = 54, .dw = 24, .ce = 15}
|
||||
}
|
||||
},
|
||||
{ /* Version 37 */
|
||||
.data_bytes = 3196,
|
||||
.apat = {6, 28, 54, 80, 106, 132, 158},
|
||||
.ecc = {
|
||||
{.bs = 74, .dw = 46, .ce = 14},
|
||||
{.bs = 152, .dw = 122, .ce = 15},
|
||||
{.bs = 45, .dw = 15, .ce = 15},
|
||||
{.bs = 54, .dw = 24, .ce = 15}
|
||||
}
|
||||
},
|
||||
{ /* Version 38 */
|
||||
.data_bytes = 3362,
|
||||
.apat = {6, 32, 58, 84, 110, 136, 162},
|
||||
.ecc = {
|
||||
{.bs = 74, .dw = 46, .ce = 14},
|
||||
{.bs = 152, .dw = 122, .ce = 15},
|
||||
{.bs = 45, .dw = 15, .ce = 15},
|
||||
{.bs = 54, .dw = 24, .ce = 15}
|
||||
}
|
||||
},
|
||||
{ /* Version 39 */
|
||||
.data_bytes = 3532,
|
||||
.apat = {6, 26, 54, 82, 110, 138, 166},
|
||||
.ecc = {
|
||||
{.bs = 75, .dw = 47, .ce = 14},
|
||||
{.bs = 147, .dw = 117, .ce = 15},
|
||||
{.bs = 45, .dw = 15, .ce = 15},
|
||||
{.bs = 54, .dw = 24, .ce = 15}
|
||||
}
|
||||
},
|
||||
{ /* Version 40 */
|
||||
.data_bytes = 3706,
|
||||
.apat = {6, 30, 58, 86, 114, 142, 170},
|
||||
.ecc = {
|
||||
{.bs = 75, .dw = 47, .ce = 14},
|
||||
{.bs = 148, .dw = 118, .ce = 15},
|
||||
{.bs = 45, .dw = 15, .ce = 15},
|
||||
{.bs = 54, .dw = 24, .ce = 15}
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
+271
-271
@@ -1,271 +1,271 @@
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#include "download.hpp"
|
||||
#include "fileBrowse.hpp"
|
||||
#include "mainScreen.hpp"
|
||||
#include "screenshot.hpp"
|
||||
#include "storeUtils.hpp"
|
||||
#include <unistd.h>
|
||||
|
||||
extern int fadeAlpha;
|
||||
|
||||
extern EshopInfo GetInfo(const std::string &file, const std::string &fileName);
|
||||
extern void notConnectedMsg();
|
||||
extern void DisplayChangelog();
|
||||
|
||||
/*
|
||||
MainScreen Constructor.
|
||||
Initialized Meta, Store and StoreEntry class and:
|
||||
- Downloads darkstore-homebrew.eshop.. in case nothing exist.
|
||||
*/
|
||||
MainScreen::MainScreen() {
|
||||
this->meta = std::make_unique<Meta>();
|
||||
|
||||
/* Check if lastStore is accessible. */
|
||||
if (config->lastStore() != "darkstore-homebrew.eshop" || config->lastStore() != "") {
|
||||
if (access((std::string(_STORE_PATH) + config->lastStore()).c_str(), F_OK) != 0) {
|
||||
config->lastStore("darkstore-homebrew.eshop");
|
||||
|
||||
} else {
|
||||
/* check version and file here. */
|
||||
const EshopInfo info = GetInfo((std::string(_STORE_PATH) + config->lastStore()), config->lastStore());
|
||||
|
||||
if (info.Version != 3 && info.Version != _ESHOP_VERSION) {
|
||||
config->lastStore("darkstore-homebrew.eshop");
|
||||
}
|
||||
|
||||
if (info.File != "") { // Ensure to check for this.
|
||||
if ((info.File.find("/") != std::string::npos)) {
|
||||
config->lastStore("darkstore-homebrew.eshop"); // It does contain a '/' which is invalid.
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/* If darkstore-homebrew.eshop --> Get! */
|
||||
if (config->lastStore() == "darkstore-homebrew.eshop" || config->lastStore() == "") {
|
||||
if (access("sdmc:/3ds/DarkStore/stores/darkstore-homebrew.eshop", F_OK) != 0) {
|
||||
if (checkWifiStatus()) {
|
||||
std::string tmp = ""; // Juste une intérimaire.
|
||||
DownloadEshop("https://darkstore.ml/assets/darkstore-homebrew.eshop", -1, tmp, true, true);
|
||||
DownloadSpriteSheet("https://darkstore.ml/assets/icon.t3x", "icon.t3x");
|
||||
DownloadSpriteSheet("https://darkstore.ml/assets/icon_1.t3x", "icon_1.t3x");
|
||||
DownloadSpriteSheet("https://darkstore.ml/assets/icon_2.t3x", "icon_2.t3x");
|
||||
|
||||
} else {
|
||||
notConnectedMsg();
|
||||
}
|
||||
|
||||
} else {
|
||||
const EshopInfo info = GetInfo("sdmc:/3ds/DarkStore/stores/darkstore-homebrew.eshop", "darkstore-homebrew.eshop");
|
||||
|
||||
if (info.Version != 3 && info.Version != _ESHOP_VERSION) {
|
||||
Msg::waitMsg("Not passing the check!");
|
||||
if (checkWifiStatus()) {
|
||||
std::string tmp = ""; // Juste une intérimaire.
|
||||
DownloadEshop("https://darkstore.ml/assets/darkstore-homebrew.eshop", -1, tmp, true, true);
|
||||
DownloadSpriteSheet("https://darkstore.ml/assets/icon.t3x", "icon.t3x");
|
||||
DownloadSpriteSheet("https://darkstore.ml/assets/icon_1.t3x", "icon_1.t3x");
|
||||
DownloadSpriteSheet("https://darkstore.ml/assets/icon_2.t3x", "icon_2.t3x");
|
||||
|
||||
} else {
|
||||
notConnectedMsg();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
this->store = std::make_unique<Store>(_STORE_PATH + config->lastStore(), config->lastStore());
|
||||
StoreUtils::ResetAll(this->store, this->meta, this->entries);
|
||||
StoreUtils::SortEntries(false, SortType::LAST_UPDATED, this->entries);
|
||||
DisplayChangelog();
|
||||
};
|
||||
|
||||
/*
|
||||
MainScreen Main Draw.
|
||||
*/
|
||||
void MainScreen::Draw(void) const {
|
||||
if (this->storeMode == 6) {
|
||||
/* Screenshot Menu. */
|
||||
StoreUtils::DrawScreenshotMenu(this->Screenshot, this->screenshotIndex, this->screenshotFetch, this->sSize, this->screenshotName, this->zoom, this->canDisplay);
|
||||
return;
|
||||
}
|
||||
|
||||
if (this->storeMode == 7) {
|
||||
/* Release Notes. */
|
||||
StoreUtils::DrawReleaseNotes(this->scrollIndex, this->entries[this->store->GetEntry()], this->store);
|
||||
GFX::DrawBottom();
|
||||
return;
|
||||
}
|
||||
|
||||
Gui::ScreenDraw(Top);
|
||||
Gui::Draw_Rect(0, 0, 400, 25, BAR_COLOR);
|
||||
Gui::Draw_Rect(0, 25, 400, 1, BAR_OUTL_COLOR);
|
||||
|
||||
if (this->store && this->store->GetValid()) Gui::DrawStringCentered(0, 1, 0.7f, TEXT_COLOR, this->store->GetEshopTitle(), 370, 0, font);
|
||||
else Gui::DrawStringCentered(0, 1, 0.7f, TEXT_COLOR, Lang::get("INVALID_ESHOP"), 370, 0, font);
|
||||
config->list() ? StoreUtils::DrawList(this->store, this->entries) : StoreUtils::DrawGrid(this->store, this->entries);
|
||||
|
||||
/* Download-ception. */
|
||||
if (this->storeMode == 1) {
|
||||
StoreUtils::DrawDownList(this->store, this->dwnldList, this->fetchDown, this->entries[this->store->GetEntry()], this->dwnldSizes);
|
||||
|
||||
} else {
|
||||
if (fadeAlpha > 0) Gui::Draw_Rect(0, 0, 400, 240, C2D_Color32(0, 0, 0, fadeAlpha));
|
||||
GFX::DrawBottom();
|
||||
|
||||
switch(this->storeMode) {
|
||||
case 0:
|
||||
/* Entry Info. */
|
||||
if (this->store && this->store->GetValid() && this->entries.size() > 0) StoreUtils::DrawEntryInfo(this->store, this->entries[this->store->GetEntry()]);
|
||||
break;
|
||||
|
||||
case 2:
|
||||
StoreUtils::DrawQueueMenu(this->queueIndex);
|
||||
break;
|
||||
|
||||
case 3:
|
||||
/* Search + Favorites. */
|
||||
StoreUtils::DrawSearchMenu(this->searchIncludes, this->searchResult, this->marks, this->updateFilter);
|
||||
break;
|
||||
|
||||
case 4:
|
||||
/* Sorting. */
|
||||
StoreUtils::DrawSorting(this->ascending, this->sorttype);
|
||||
break;
|
||||
|
||||
case 5:
|
||||
/* Settings. */
|
||||
StoreUtils::DrawSettings(this->sPage, this->sSelection, this->sPos);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
StoreUtils::DrawSideMenu(this->storeMode);
|
||||
if (this->showMarks && this->store && this->store->GetValid()) StoreUtils::DisplayMarkBox(this->entries[this->store->GetEntry()]->GetMarks());
|
||||
if (fadeAlpha > 0) Gui::Draw_Rect(0, 0, 320, 240, C2D_Color32(0, 0, 0, fadeAlpha));
|
||||
}
|
||||
|
||||
/*
|
||||
MainScreen Logic.
|
||||
*/
|
||||
void MainScreen::Logic(u32 hDown, u32 hHeld, touchPosition touch) {
|
||||
/* Screenshots Menu. */
|
||||
if (this->storeMode == 6) {
|
||||
if (this->screenshotFetch) {
|
||||
/* Delete Texture first. */
|
||||
if (this->Screenshot.tex) {
|
||||
C3D_TexDelete(this->Screenshot.tex);
|
||||
this->Screenshot.tex = nullptr;
|
||||
this->Screenshot.subtex = nullptr;
|
||||
}
|
||||
|
||||
this->screenshotName = "";
|
||||
|
||||
if (this->screenshotIndex < (int)this->entries[this->store->GetEntry()]->GetScreenshotNames().size()) {
|
||||
this->screenshotName = this->entries[this->store->GetEntry()]->GetScreenshotNames()[this->screenshotIndex];
|
||||
}
|
||||
|
||||
this->sSize = 0;
|
||||
this->sSize = this->entries[this->store->GetEntry()]->GetScreenshots().size();
|
||||
|
||||
if (this->screenshotIndex < this->sSize) {
|
||||
if (this->sSize > 0) {
|
||||
this->Screenshot = FetchScreenshot(this->entries[this->store->GetEntry()]->GetScreenshots()[this->screenshotIndex]);
|
||||
if (this->Screenshot.tex) this->canDisplay = true;
|
||||
else this->canDisplay = false;
|
||||
}
|
||||
}
|
||||
|
||||
this->screenshotFetch = false;
|
||||
}
|
||||
|
||||
StoreUtils::ScreenshotMenu(this->Screenshot, this->screenshotIndex, this->screenshotFetch, this->storeMode, this->sSize, this->zoom, this->canDisplay);
|
||||
return;
|
||||
}
|
||||
|
||||
/* Release Notes. */
|
||||
if (this->storeMode == 7) {
|
||||
StoreUtils::ReleaseNotesLogic(this->scrollIndex, this->storeMode);
|
||||
return;
|
||||
}
|
||||
|
||||
/* Mark Menu. */
|
||||
if (this->showMarks) StoreUtils::MarkHandle(this->entries[this->store->GetEntry()], this->store, this->showMarks, this->meta);
|
||||
|
||||
if (!this->showMarks) {
|
||||
if (this->storeMode == 0 || this->storeMode == 3 || this->storeMode == 4) {
|
||||
config->list() ? StoreUtils::ListLogic(this->store, this->entries, this->storeMode, this->lastMode, this->fetchDown, this->smallDelay) : StoreUtils::GridLogic(this->store, this->entries, this->storeMode, this->lastMode, this->fetchDown, this->smallDelay);
|
||||
}
|
||||
|
||||
StoreUtils::SideMenuHandle(this->storeMode, this->fetchDown, this->lastMode);
|
||||
|
||||
/* Fetch Download list. */
|
||||
if (this->fetchDown) {
|
||||
this->dwnldList.clear();
|
||||
this->dwnldSizes.clear();
|
||||
|
||||
if (this->store && this->store->GetValid()) {
|
||||
this->store->SetDownloadIndex(0); // Reset to 0.
|
||||
this->store->SetDownloadSIndex(0);
|
||||
|
||||
if ((int)this->entries.size() > this->store->GetEntry()) {
|
||||
this->dwnldList = this->store->GetDownloadList(this->entries[this->store->GetEntry()]->GetEntryIndex());
|
||||
this->dwnldSizes = this->entries[this->store->GetEntry()]->GetSizes();
|
||||
}
|
||||
}
|
||||
|
||||
this->fetchDown = false;
|
||||
}
|
||||
|
||||
switch(this->storeMode) {
|
||||
case 0:
|
||||
if (this->store && this->store->GetValid() && this->entries.size() > 0) StoreUtils::EntryHandle(this->showMarks, this->fetchDown, this->screenshotFetch, this->storeMode, this->entries[this->store->GetEntry()]);
|
||||
break;
|
||||
|
||||
case 1:
|
||||
if (this->store && this->store->GetValid() && this->entries.size() > 0) StoreUtils::DownloadHandle(this->store, this->entries[this->store->GetEntry()], this->dwnldList, this->storeMode, this->meta, this->lastMode, this->smallDelay);
|
||||
break;
|
||||
|
||||
case 2:
|
||||
StoreUtils::QueueMenuHandle(this->queueIndex);
|
||||
break;
|
||||
|
||||
case 3:
|
||||
StoreUtils::SearchHandle(this->store, this->entries, this->searchIncludes, this->meta, this->searchResult, this->marks, this->updateFilter, this->ascending, this->sorttype);
|
||||
break;
|
||||
|
||||
case 4:
|
||||
StoreUtils::SortHandle(this->store, this->entries, this->ascending, this->sorttype);
|
||||
break;
|
||||
|
||||
case 5:
|
||||
StoreUtils::SettingsHandle(this->sPage, this->showSettings, this->storeMode, this->sSelection, this->store, this->entries, this->meta, this->sPos);
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
/*
|
||||
* This file is part of Universal-Updater
|
||||
* Copyright (C) 2019-2020 Universal-Team
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
* Additional Terms 7.b and 7.c of GPLv3 apply to this file:
|
||||
* * Requiring preservation of specified reasonable legal notices or
|
||||
* author attributions in that material or in the Appropriate Legal
|
||||
* Notices displayed by works containing it.
|
||||
* * Prohibiting misrepresentation of the origin of that material,
|
||||
* or requiring that modified versions of such material be marked in
|
||||
* reasonable ways as different from the original version.
|
||||
*/
|
||||
|
||||
#include "download.hpp"
|
||||
#include "fileBrowse.hpp"
|
||||
#include "mainScreen.hpp"
|
||||
#include "screenshot.hpp"
|
||||
#include "storeUtils.hpp"
|
||||
#include <unistd.h>
|
||||
|
||||
extern int fadeAlpha;
|
||||
|
||||
extern EshopInfo GetInfo(const std::string &file, const std::string &fileName);
|
||||
extern void notConnectedMsg();
|
||||
extern void DisplayChangelog();
|
||||
|
||||
/*
|
||||
MainScreen Constructor.
|
||||
Initialized Meta, Store and StoreEntry class and:
|
||||
- Downloads darkstore-homebrew.eshop.. in case nothing exist.
|
||||
*/
|
||||
MainScreen::MainScreen() {
|
||||
this->meta = std::make_unique<Meta>();
|
||||
|
||||
/* Check if lastStore is accessible. */
|
||||
if (config->lastStore() != "darkstore-homebrew.eshop" || config->lastStore() != "") {
|
||||
if (access((std::string(_STORE_PATH) + config->lastStore()).c_str(), F_OK) != 0) {
|
||||
config->lastStore("darkstore-homebrew.eshop");
|
||||
|
||||
} else {
|
||||
/* check version and file here. */
|
||||
const EshopInfo info = GetInfo((std::string(_STORE_PATH) + config->lastStore()), config->lastStore());
|
||||
|
||||
if (info.Version != 3 && info.Version != _ESHOP_VERSION) {
|
||||
config->lastStore("darkstore-homebrew.eshop");
|
||||
}
|
||||
|
||||
if (info.File != "") { // Ensure to check for this.
|
||||
if ((info.File.find("/") != std::string::npos)) {
|
||||
config->lastStore("darkstore-homebrew.eshop"); // It does contain a '/' which is invalid.
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/* If darkstore-homebrew.eshop --> Get! */
|
||||
if (config->lastStore() == "darkstore-homebrew.eshop" || config->lastStore() == "") {
|
||||
if (access("sdmc:/3ds/DarkStore/stores/darkstore-homebrew.eshop", F_OK) != 0) {
|
||||
if (checkWifiStatus()) {
|
||||
std::string tmp = ""; // Juste une intérimaire.
|
||||
DownloadEshop("https://darkstore.ml/assets/darkstore-homebrew.eshop", -1, tmp, true, true);
|
||||
DownloadSpriteSheet("https://darkstore.ml/assets/icon.t3x", "icon.t3x");
|
||||
DownloadSpriteSheet("https://darkstore.ml/assets/icon_1.t3x", "icon_1.t3x");
|
||||
DownloadSpriteSheet("https://darkstore.ml/assets/icon_2.t3x", "icon_2.t3x");
|
||||
|
||||
} else {
|
||||
notConnectedMsg();
|
||||
}
|
||||
|
||||
} else {
|
||||
const EshopInfo info = GetInfo("sdmc:/3ds/DarkStore/stores/darkstore-homebrew.eshop", "darkstore-homebrew.eshop");
|
||||
|
||||
if (info.Version != 3 && info.Version != _ESHOP_VERSION) {
|
||||
Msg::waitMsg("Not passing the check!");
|
||||
if (checkWifiStatus()) {
|
||||
std::string tmp = ""; // Juste une intérimaire.
|
||||
DownloadEshop("https://darkstore.ml/assets/darkstore-homebrew.eshop", -1, tmp, true, true);
|
||||
DownloadSpriteSheet("https://darkstore.ml/assets/icon.t3x", "icon.t3x");
|
||||
DownloadSpriteSheet("https://darkstore.ml/assets/icon_1.t3x", "icon_1.t3x");
|
||||
DownloadSpriteSheet("https://darkstore.ml/assets/icon_2.t3x", "icon_2.t3x");
|
||||
|
||||
} else {
|
||||
notConnectedMsg();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
this->store = std::make_unique<Store>(_STORE_PATH + config->lastStore(), config->lastStore());
|
||||
StoreUtils::ResetAll(this->store, this->meta, this->entries);
|
||||
StoreUtils::SortEntries(false, SortType::LAST_UPDATED, this->entries);
|
||||
DisplayChangelog();
|
||||
};
|
||||
|
||||
/*
|
||||
MainScreen Main Draw.
|
||||
*/
|
||||
void MainScreen::Draw(void) const {
|
||||
if (this->storeMode == 6) {
|
||||
/* Screenshot Menu. */
|
||||
StoreUtils::DrawScreenshotMenu(this->Screenshot, this->screenshotIndex, this->screenshotFetch, this->sSize, this->screenshotName, this->zoom, this->canDisplay);
|
||||
return;
|
||||
}
|
||||
|
||||
if (this->storeMode == 7) {
|
||||
/* Release Notes. */
|
||||
StoreUtils::DrawReleaseNotes(this->scrollIndex, this->entries[this->store->GetEntry()], this->store);
|
||||
GFX::DrawBottom();
|
||||
return;
|
||||
}
|
||||
|
||||
Gui::ScreenDraw(Top);
|
||||
Gui::Draw_Rect(0, 0, 400, 25, BAR_COLOR);
|
||||
Gui::Draw_Rect(0, 25, 400, 1, BAR_OUTL_COLOR);
|
||||
|
||||
if (this->store && this->store->GetValid()) Gui::DrawStringCentered(0, 1, 0.7f, TEXT_COLOR, this->store->GetEshopTitle(), 370, 0, font);
|
||||
else Gui::DrawStringCentered(0, 1, 0.7f, TEXT_COLOR, Lang::get("INVALID_ESHOP"), 370, 0, font);
|
||||
config->list() ? StoreUtils::DrawList(this->store, this->entries) : StoreUtils::DrawGrid(this->store, this->entries);
|
||||
|
||||
/* Download-ception. */
|
||||
if (this->storeMode == 1) {
|
||||
StoreUtils::DrawDownList(this->store, this->dwnldList, this->fetchDown, this->entries[this->store->GetEntry()], this->dwnldSizes);
|
||||
|
||||
} else {
|
||||
if (fadeAlpha > 0) Gui::Draw_Rect(0, 0, 400, 240, C2D_Color32(0, 0, 0, fadeAlpha));
|
||||
GFX::DrawBottom();
|
||||
|
||||
switch(this->storeMode) {
|
||||
case 0:
|
||||
/* Entry Info. */
|
||||
if (this->store && this->store->GetValid() && this->entries.size() > 0) StoreUtils::DrawEntryInfo(this->store, this->entries[this->store->GetEntry()]);
|
||||
break;
|
||||
|
||||
case 2:
|
||||
StoreUtils::DrawQueueMenu(this->queueIndex);
|
||||
break;
|
||||
|
||||
case 3:
|
||||
/* Search + Favorites. */
|
||||
StoreUtils::DrawSearchMenu(this->searchIncludes, this->searchResult, this->marks, this->updateFilter);
|
||||
break;
|
||||
|
||||
case 4:
|
||||
/* Sorting. */
|
||||
StoreUtils::DrawSorting(this->ascending, this->sorttype);
|
||||
break;
|
||||
|
||||
case 5:
|
||||
/* Settings. */
|
||||
StoreUtils::DrawSettings(this->sPage, this->sSelection, this->sPos);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
StoreUtils::DrawSideMenu(this->storeMode);
|
||||
if (this->showMarks && this->store && this->store->GetValid()) StoreUtils::DisplayMarkBox(this->entries[this->store->GetEntry()]->GetMarks());
|
||||
if (fadeAlpha > 0) Gui::Draw_Rect(0, 0, 320, 240, C2D_Color32(0, 0, 0, fadeAlpha));
|
||||
}
|
||||
|
||||
/*
|
||||
MainScreen Logic.
|
||||
*/
|
||||
void MainScreen::Logic(u32 hDown, u32 hHeld, touchPosition touch) {
|
||||
/* Screenshots Menu. */
|
||||
if (this->storeMode == 6) {
|
||||
if (this->screenshotFetch) {
|
||||
/* Delete Texture first. */
|
||||
if (this->Screenshot.tex) {
|
||||
C3D_TexDelete(this->Screenshot.tex);
|
||||
this->Screenshot.tex = nullptr;
|
||||
this->Screenshot.subtex = nullptr;
|
||||
}
|
||||
|
||||
this->screenshotName = "";
|
||||
|
||||
if (this->screenshotIndex < (int)this->entries[this->store->GetEntry()]->GetScreenshotNames().size()) {
|
||||
this->screenshotName = this->entries[this->store->GetEntry()]->GetScreenshotNames()[this->screenshotIndex];
|
||||
}
|
||||
|
||||
this->sSize = 0;
|
||||
this->sSize = this->entries[this->store->GetEntry()]->GetScreenshots().size();
|
||||
|
||||
if (this->screenshotIndex < this->sSize) {
|
||||
if (this->sSize > 0) {
|
||||
this->Screenshot = FetchScreenshot(this->entries[this->store->GetEntry()]->GetScreenshots()[this->screenshotIndex]);
|
||||
if (this->Screenshot.tex) this->canDisplay = true;
|
||||
else this->canDisplay = false;
|
||||
}
|
||||
}
|
||||
|
||||
this->screenshotFetch = false;
|
||||
}
|
||||
|
||||
StoreUtils::ScreenshotMenu(this->Screenshot, this->screenshotIndex, this->screenshotFetch, this->storeMode, this->sSize, this->zoom, this->canDisplay);
|
||||
return;
|
||||
}
|
||||
|
||||
/* Release Notes. */
|
||||
if (this->storeMode == 7) {
|
||||
StoreUtils::ReleaseNotesLogic(this->scrollIndex, this->storeMode);
|
||||
return;
|
||||
}
|
||||
|
||||
/* Mark Menu. */
|
||||
if (this->showMarks) StoreUtils::MarkHandle(this->entries[this->store->GetEntry()], this->store, this->showMarks, this->meta);
|
||||
|
||||
if (!this->showMarks) {
|
||||
if (this->storeMode == 0 || this->storeMode == 3 || this->storeMode == 4) {
|
||||
config->list() ? StoreUtils::ListLogic(this->store, this->entries, this->storeMode, this->lastMode, this->fetchDown, this->smallDelay) : StoreUtils::GridLogic(this->store, this->entries, this->storeMode, this->lastMode, this->fetchDown, this->smallDelay);
|
||||
}
|
||||
|
||||
StoreUtils::SideMenuHandle(this->storeMode, this->fetchDown, this->lastMode);
|
||||
|
||||
/* Fetch Download list. */
|
||||
if (this->fetchDown) {
|
||||
this->dwnldList.clear();
|
||||
this->dwnldSizes.clear();
|
||||
|
||||
if (this->store && this->store->GetValid()) {
|
||||
this->store->SetDownloadIndex(0); // Reset to 0.
|
||||
this->store->SetDownloadSIndex(0);
|
||||
|
||||
if ((int)this->entries.size() > this->store->GetEntry()) {
|
||||
this->dwnldList = this->store->GetDownloadList(this->entries[this->store->GetEntry()]->GetEntryIndex());
|
||||
this->dwnldSizes = this->entries[this->store->GetEntry()]->GetSizes();
|
||||
}
|
||||
}
|
||||
|
||||
this->fetchDown = false;
|
||||
}
|
||||
|
||||
switch(this->storeMode) {
|
||||
case 0:
|
||||
if (this->store && this->store->GetValid() && this->entries.size() > 0) StoreUtils::EntryHandle(this->showMarks, this->fetchDown, this->screenshotFetch, this->storeMode, this->entries[this->store->GetEntry()]);
|
||||
break;
|
||||
|
||||
case 1:
|
||||
if (this->store && this->store->GetValid() && this->entries.size() > 0) StoreUtils::DownloadHandle(this->store, this->entries[this->store->GetEntry()], this->dwnldList, this->storeMode, this->meta, this->lastMode, this->smallDelay);
|
||||
break;
|
||||
|
||||
case 2:
|
||||
StoreUtils::QueueMenuHandle(this->queueIndex);
|
||||
break;
|
||||
|
||||
case 3:
|
||||
StoreUtils::SearchHandle(this->store, this->entries, this->searchIncludes, this->meta, this->searchResult, this->marks, this->updateFilter, this->ascending, this->sorttype);
|
||||
break;
|
||||
|
||||
case 4:
|
||||
StoreUtils::SortHandle(this->store, this->entries, this->ascending, this->sorttype);
|
||||
break;
|
||||
|
||||
case 5:
|
||||
StoreUtils::SettingsHandle(this->sPage, this->showSettings, this->storeMode, this->sSelection, this->store, this->entries, this->meta, this->sPos);
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
+567
-567
File diff suppressed because it is too large
Load Diff
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user