merge branch master

This commit is contained in:
vgmoose 2018-05-31 00:56:30 -04:00
parent dd2d4cc821
commit a5a644ac68
3 changed files with 13 additions and 2 deletions

View File

@ -12,5 +12,9 @@ macos:
gcc -c $(MINIZIP)/*.c
g++ -g -std=gnu++11 *.cpp -lSDL2 -lSDL2main -lSDL_gfx -lSDL2_image -lSDL2_ttf -framework Cocoa ./console/*.cpp ./gui/*.cpp ./libs/get/src/*.cpp $(MINIZIP_O) -I $(RAPIDJSON) -I $(MINIZIP) -I /usr/local/include -lcurl -lz -o appstore.exe -fstack-protector-all -DNOCURL
sdl2:
gcc -c $(MINIZIP)/*.c
g++ -g -std=gnu++11 *.cpp -lSDL2 -lSDL2main -lSDL2_gfx -lSDL2_image -lSDL2_ttf -framework Cocoa ./console/*.cpp ./gui/*.cpp ./libs/get/src/*.cpp $(MINIZIP_O) -I $(RAPIDJSON) -I $(MINIZIP) -I /usr/local/include -lcurl -lz -o appstore.exe -fstack-protector-all -DNOCURL -DSDL2
clean:
rm *.o *.bin

View File

@ -74,7 +74,14 @@ bool MainDisplay::process(SDL_Event* event)
// should be a progress bar
if (this->get->packages.size() != 1)
((ProgressBar*)this->elements[0])->percent = (this->count / ((float)this->get->packages.size()-1));
// no packages, prevent crash TODO: display offline in bottom bar
if (this->get->packages.size() == 0)
{
((ProgressBar*)this->elements[0])->percent = 0;
return false;
}
// get the package whose icon+screen to process
Package* current = this->get->packages[this->count - 1];

@ -1 +1 @@
Subproject commit 695349bb44478287552e7bee684610735d30c40c
Subproject commit 8dc55bdbc6ac67fbacd4202ad249af7a2003f47e