Skip to content

Commit

Permalink
Add splash screen toggle (SoftFever#2568)
Browse files Browse the repository at this point in the history
Add preferences option to toggle splash screen
  • Loading branch information
Ocraftyone authored Nov 1, 2023
1 parent 261393b commit 06f966e
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 2 deletions.
6 changes: 6 additions & 0 deletions src/libslic3r/AppConfig.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -231,6 +231,12 @@ void AppConfig::set_defaults()
if (get("stealth_mode").empty()) {
set_bool("stealth_mode", false);
}

// Orca
if(get("show_splash_screen").empty()) {
set_bool("show_splash_screen", true);
}

if (get("show_model_mesh").empty()) {
set_bool("show_model_mesh", false);
}
Expand Down
3 changes: 1 addition & 2 deletions src/slic3r/GUI/GUI_App.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2427,8 +2427,7 @@ bool GUI_App::on_init_inner()
}

BBLSplashScreen * scrn = nullptr;
const bool show_splash_screen = true;
if (show_splash_screen) {
if (app_config->get("show_splash_screen") == "true") {
// make a bitmap with dark grey banner on the left side
//BBS make BBL splash screen bitmap
wxBitmap bmp = BBLSplashScreen::MakeBitmap();
Expand Down
2 changes: 2 additions & 0 deletions src/slic3r/GUI/Preferences.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -982,6 +982,7 @@ wxWindow* PreferencesDialog::create_general_page()
auto item_mouse_zoom_settings = create_item_checkbox(_L("Zoom to mouse position"), page, _L("Zoom in towards the mouse pointer's position in the 3D view, rather than the 2D window center."), 50, "zoom_to_mouse");
auto item_use_free_camera_settings = create_item_checkbox(_L("Use free camera"), page, _L("If enabled, use free camera. If not enabled, use constrained camera."), 50, "use_free_camera");

auto item_show_splash_screen = create_item_checkbox(_L("Show splash screen"), page, _L("Show the splash screen during startup."), 50, "show_splash_screen");
auto item_hints = create_item_checkbox(_L("Show \"Tip of the day\" notification after start"), page, _L("If enabled, useful hints are displayed at startup."), 50, "show_hints");
auto item_gcode_window = create_item_checkbox(_L("Show g-code window"), page, _L("If enabled, g-code window will be displayed."), 50, "show_gcode_window");

Expand Down Expand Up @@ -1041,6 +1042,7 @@ wxWindow* PreferencesDialog::create_general_page()
sizer_page->Add(item_currency, 0, wxTOP, FromDIP(3));
sizer_page->Add(item_mouse_zoom_settings, 0, wxTOP, FromDIP(3));
sizer_page->Add(item_use_free_camera_settings, 0, wxTOP, FromDIP(3));
sizer_page->Add(item_show_splash_screen, 0, wxTOP, FromDIP(3));
sizer_page->Add(item_hints, 0, wxTOP, FromDIP(3));
sizer_page->Add(item_gcode_window, 0, wxTOP, FromDIP(3));
sizer_page->Add(title_presets, 0, wxTOP | wxEXPAND, FromDIP(20));
Expand Down

0 comments on commit 06f966e

Please sign in to comment.