mirror of
https://github.com/amyinspace/MagicSetEditor2.git
synced 2026-06-10 04:57:00 -04:00
Fixed some gcc warnings
This commit is contained in:
+2
-3
@@ -48,7 +48,6 @@ target_sources(magicseteditor PRIVATE resource/win32_res.rc)
|
|||||||
|
|
||||||
if(WIN32)
|
if(WIN32)
|
||||||
add_executable(magicseteditor-cli)
|
add_executable(magicseteditor-cli)
|
||||||
#set_target_properties(magicseteditor-cli PROPERTIES OUTPUT_NAME "magicseteditor.com")
|
|
||||||
target_sources(magicseteditor-cli PRIVATE src/cli/win32_cli_wrapper.cpp)
|
target_sources(magicseteditor-cli PRIVATE src/cli/win32_cli_wrapper.cpp)
|
||||||
add_custom_command(TARGET magicseteditor-cli POST_BUILD COMMAND
|
add_custom_command(TARGET magicseteditor-cli POST_BUILD COMMAND
|
||||||
${CMAKE_COMMAND} -E copy "${PROJECT_BINARY_DIR}/magicseteditor-cli.exe" "${PROJECT_BINARY_DIR}/magicseteditor.com"
|
${CMAKE_COMMAND} -E copy "${PROJECT_BINARY_DIR}/magicseteditor-cli.exe" "${PROJECT_BINARY_DIR}/magicseteditor.com"
|
||||||
@@ -59,8 +58,8 @@ endif()
|
|||||||
# warnings
|
# warnings
|
||||||
if(CMAKE_COMPILER_IS_GNUCC OR CMAKE_COMPILER_IS_GNUCXX)
|
if(CMAKE_COMPILER_IS_GNUCC OR CMAKE_COMPILER_IS_GNUCXX)
|
||||||
# Update if necessary
|
# Update if necessary
|
||||||
#set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall -Wno-comment")
|
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall -Wno-comment")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
# visual studio debugger
|
# visual studio debugger
|
||||||
set_property(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR} PROPERTY VS_STARTUP_PROJECT magicseteditor)
|
set_property(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR} PROPERTY VS_STARTUP_PROJECT magicseteditor)
|
||||||
|
|||||||
@@ -57,7 +57,7 @@ void TextIOHandler::init() {
|
|||||||
// Use console mode if one of the cli flags is passed
|
// Use console mode if one of the cli flags is passed
|
||||||
static const Char* redirect_flags[] = {_("-?"),_("--help"),_("-v"),_("--version"),_("--cli"),_("-c"),_("--export"),_("--create-installer")};
|
static const Char* redirect_flags[] = {_("-?"),_("--help"),_("-v"),_("--version"),_("--cli"),_("-c"),_("--export"),_("--create-installer")};
|
||||||
for (int i = 1 ; i < wxTheApp->argc ; ++i) {
|
for (int i = 1 ; i < wxTheApp->argc ; ++i) {
|
||||||
for (int j = 0 ; j < sizeof(redirect_flags)/sizeof(redirect_flags[0]) ; ++j) {
|
for (size_t j = 0 ; j < sizeof(redirect_flags)/sizeof(redirect_flags[0]) ; ++j) {
|
||||||
if (String(wxTheApp->argv[i]) == redirect_flags[j]) {
|
if (String(wxTheApp->argv[i]) == redirect_flags[j]) {
|
||||||
have_console = true;
|
have_console = true;
|
||||||
have_stderr = true;
|
have_stderr = true;
|
||||||
|
|||||||
@@ -51,7 +51,7 @@ NewSetWindow::NewSetWindow(Window* parent)
|
|||||||
game_list->showData<Game>();
|
game_list->showData<Game>();
|
||||||
try {
|
try {
|
||||||
game_list->select(settings.default_game);
|
game_list->select(settings.default_game);
|
||||||
} catch (FileNotFoundError e) {
|
} catch (FileNotFoundError const& e) {
|
||||||
handle_error(e);
|
handle_error(e);
|
||||||
}
|
}
|
||||||
game_list->SetFocus();
|
game_list->SetFocus();
|
||||||
|
|||||||
Reference in New Issue
Block a user