sys: Tons of long overdue cleanup

- std::string -> const std::string& where needed
- Added a FileIO abstraction class
- Fixed recent files not updating
- Removed localization file from global include
- Renamed lang to pattern_language/pl
- Renamed EventFileDropped to RequestFileOpen
This commit is contained in:
WerWolv
2021-09-08 15:18:24 +02:00
parent d7707bae62
commit e74c0f5cf5
74 changed files with 549 additions and 494 deletions

View File

@@ -8,6 +8,8 @@
#include "init/splash_window.hpp"
#include "init/tasks.hpp"
#include <hex/helpers/file.hpp>
int main(int argc, char **argv) {
using namespace hex;
@@ -37,7 +39,7 @@ int main(int argc, char **argv) {
if (argc == 1)
; // No arguments provided
else if (argc == 2)
EventManager::post<EventFileDropped>(argv[1]);
EventManager::post<RequestOpenFile>(argv[1]);
else {
hex::log::fatal("Usage: imhex [file_name]");
return EXIT_FAILURE;