mirror of
https://github.com/zebrajr/SamRewritten.git
synced 2025-12-06 00:19:47 +01:00
Finishing touches
This commit is contained in:
parent
f07600e620
commit
f96a34be99
3
Makefile
3
Makefile
|
|
@ -15,8 +15,7 @@ all: ${CURDIR}/bin/samrewritten
|
|||
@echo -e "==== Use '\033[1mmake clean\033[0m' to remove object files"
|
||||
@echo -e "==== Nothing left to do."
|
||||
|
||||
dev: CXXFLAGS += -g
|
||||
dev: CXXFLAGS += -DDEBUG_CERR
|
||||
dev: CXXFLAGS += -g -DDEBUG_CERR
|
||||
dev: ${CURDIR}/bin/samrewritten
|
||||
|
||||
clean:
|
||||
|
|
|
|||
|
|
@ -60,7 +60,7 @@ Usage:
|
|||
-a, --app arg Set which AppId you want to use. Same as using positional
|
||||
'AppId'
|
||||
-i, --idle Set your Steam profile as 'ingame'. Ctrl+c to stop.
|
||||
--ls Display stats (TODO) and achievements for selected app.
|
||||
--ls Display achievements and stats for selected app.
|
||||
--sort arg Sort option for --ls. You can leave empty or set to
|
||||
'unlock_rate'
|
||||
--unlock arg Unlock achievements for an AppId. Separate achievement
|
||||
|
|
|
|||
|
|
@ -45,7 +45,7 @@ bool go_cli_mode(int argc, char* argv[]) {
|
|||
("h,help", "Show CLI help.")
|
||||
("a,app", "Set which AppId you want to use. Same as using positional 'AppId'", cxxopts::value<AppId_t>())
|
||||
("i,idle", "Set your Steam profile as 'ingame'. Ctrl+c to stop.")
|
||||
("ls", "Display stats (TODO) and achievements for selected app.")
|
||||
("ls", "Display achievements and stats for selected app.")
|
||||
("sort", "Sort option for --ls. You can leave empty or set to 'unlock_rate'", cxxopts::value<std::string>())
|
||||
("unlock", "Unlock achievements for an AppId. Separate achievement names by a comma.", cxxopts::value<std::vector<std::string>>())
|
||||
("lock", "Lock achievements for an AppId. Separate achievement names by a comma.", cxxopts::value<std::vector<std::string>>())
|
||||
|
|
|
|||
|
|
@ -1096,7 +1096,6 @@ namespace cxxopts
|
|||
return m_count;
|
||||
}
|
||||
|
||||
// TODO: maybe default options should count towards the number of arguments
|
||||
bool
|
||||
has_default() const noexcept
|
||||
{
|
||||
|
|
|
|||
|
|
@ -166,8 +166,7 @@ SteamAppDAO::parse_app_names(const std::string file_path, std::map<AppId_t, std:
|
|||
std::string file_contents;
|
||||
std::ifstream stream(file_path);
|
||||
|
||||
if (!stream.is_open())
|
||||
{
|
||||
if ( !stream.is_open() ) {
|
||||
std::cerr << "SteamAppDAO::parse_app_names: Unable to open file " << file_path << std::endl;
|
||||
zenity();
|
||||
exit(EXIT_FAILURE);
|
||||
|
|
@ -183,6 +182,7 @@ SteamAppDAO::parse_app_names(const std::string file_path, std::map<AppId_t, std:
|
|||
exit(EXIT_FAILURE);
|
||||
}
|
||||
|
||||
// Stream is RAII, but we close it here since we won't use it after
|
||||
stream.close();
|
||||
|
||||
/* we have the whole config file in memory. let's parse it ... */
|
||||
|
|
|
|||
|
|
@ -9,8 +9,9 @@
|
|||
#include <future>
|
||||
#include <glibmm-2.4/glibmm.h>
|
||||
|
||||
// TODO use #ifndef __VALGRIND_H or similar
|
||||
// #include <valgrind/valgrind.h>
|
||||
#ifdef DEBUG_CERR
|
||||
#include <valgrind/valgrind.h>
|
||||
#endif
|
||||
|
||||
AsyncGuiLoader::AsyncGuiLoader(MainPickerWindow* window)
|
||||
: m_window(window)
|
||||
|
|
@ -40,8 +41,6 @@ AsyncGuiLoader::load_achievements_idle()
|
|||
#endif
|
||||
|
||||
// Fire off the schema parsing now.
|
||||
// TODO: figure out if all the icons are already there and skip parsing schema
|
||||
// TODO: We want schema parsing to be done serverside now, and pass the result via IPC
|
||||
m_achievement_idle_data.state = ACH_STATE_LOADING_GUI;
|
||||
}
|
||||
return G_SOURCE_CONTINUE;
|
||||
|
|
@ -84,8 +83,9 @@ AsyncGuiLoader::load_achievements_idle()
|
|||
m_window->show_no_achievements_found_placeholder();
|
||||
m_achievement_refresh_lock.unlock();
|
||||
|
||||
// See top of the file
|
||||
// VALGRIND_MONITOR_COMMAND("detailed_snapshot");
|
||||
#ifdef DEBUG_CERR
|
||||
VALGRIND_MONITOR_COMMAND("detailed_snapshot");
|
||||
#endif
|
||||
|
||||
return G_SOURCE_REMOVE;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user