mirror of
https://git.mirrors.martin98.com/https://github.com/bambulab/BambuStudio.git
synced 2025-09-21 07:13:13 +08:00
FIX: show plugin version in about dialog
Change-Id: I8bf5c42fad5131e21d6b3cd0f5636e1e5e40bc14 Jira: none
This commit is contained in:
parent
eb1d7247f7
commit
d7778359ad
@ -242,7 +242,8 @@ AboutDialog::AboutDialog()
|
||||
vesizer->Add(0, FromDIP(165), 1, wxEXPAND, FromDIP(5));
|
||||
auto version_text = GUI_App::format_display_version();
|
||||
#if BBL_INTERNAL_TESTING
|
||||
auto version_string = _L("Internal Version") + " " + std::string(version_text);
|
||||
wxString versionText = BBL_INTERNAL_TESTING == 1 ? _L("Internal Version") : _L("Beta Version");
|
||||
auto version_string = versionText + " " + std::string(version_text);
|
||||
#else
|
||||
auto version_string = _L("Version") + " " + std::string(version_text);
|
||||
#endif
|
||||
@ -259,6 +260,12 @@ AboutDialog::AboutDialog()
|
||||
version->SetBackgroundColour(wxColour("#00AF42"));
|
||||
vesizer->Add(version, 0, wxALL | wxALIGN_CENTER_HORIZONTAL, FromDIP(5));
|
||||
#if BBL_INTERNAL_TESTING
|
||||
wxString plugin_version = wxString::Format("Plugin Version: %s", wxGetApp().getAgent() ? wxGetApp().getAgent()->get_version() : "");
|
||||
wxStaticText *plugin_version_text = new wxStaticText(this, wxID_ANY, plugin_version, wxDefaultPosition, wxDefaultSize);
|
||||
plugin_version_text->SetForegroundColour(wxColour("#FFFFFE"));
|
||||
plugin_version_text->SetBackgroundColour(wxColour("#00AF42"));
|
||||
vesizer->Add(plugin_version_text, 0, wxALL | wxALIGN_CENTER_HORIZONTAL, FromDIP(5));
|
||||
|
||||
wxString build_time = wxString::Format("Build Time: %s", std::string(SLIC3R_BUILD_TIME));
|
||||
wxStaticText* build_time_text = new wxStaticText(this, wxID_ANY, build_time, wxDefaultPosition, wxDefaultSize);
|
||||
build_time_text->SetForegroundColour(wxColour("#FFFFFE"));
|
||||
|
@ -299,7 +299,7 @@ public:
|
||||
memDc.DrawLabel(m_constant_text.version, version_rect, wxALIGN_LEFT | wxALIGN_BOTTOM);
|
||||
|
||||
#if BBL_INTERNAL_TESTING
|
||||
wxString versionText = BBL_INTERNAL_TESTING == 1 ? "Internal Version" : "Beta Version";
|
||||
wxString versionText = BBL_INTERNAL_TESTING == 1 ? _L("Internal Version") : _L("Beta Version");
|
||||
wxSize text_rect = memDc.GetTextExtent(versionText);
|
||||
int start_x = (title_rect.GetLeft() + version_rect.GetRight()) / 2 - text_rect.GetWidth();
|
||||
int start_y = version_rect.GetBottom() + 10;
|
||||
|
Loading…
x
Reference in New Issue
Block a user