Skip to content

Commit

Permalink
Changed version to "18.1.0"
Browse files Browse the repository at this point in the history
Updated splashscreen to 2025

Signed-off-by: Eran Ifrah <[email protected]>
  • Loading branch information
eranif committed Jan 9, 2025
1 parent 2273511 commit 1df4ad0
Show file tree
Hide file tree
Showing 14 changed files with 80 additions and 55 deletions.
2 changes: 1 addition & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ elseif(UNIX AND NOT APPLE)
endif()

message(STATUS "CMAKE_INSTALL_PREFIX is set to ${CMAKE_INSTALL_PREFIX}")
set(CODELITE_VERSION "18.01.0")
set(CODELITE_VERSION "18.1.0")

# for now, we keep wxCrafter version to be the same as CodeLite version this allows for better support
set(WXCRAFTER_VERSION ${CODELITE_VERSION})
Expand Down
7 changes: 5 additions & 2 deletions CodeLite/clVersionString.cpp
Original file line number Diff line number Diff line change
@@ -1,14 +1,16 @@
#include "clVersionString.hpp"

#include "file_logger.h"

#include <algorithm>
#include <cmath>
#include <vector>
#include <wx/arrstr.h>
#include <wx/tokenzr.h>

clVersionString::clVersionString(const wxString& version_string)
: m_versionString(version_string)
{
auto parts = ::wxStringTokenize(version_string, ".", wxTOKEN_STRTOK);
auto parts = ::wxStringTokenize(m_versionString, ".", wxTOKEN_STRTOK);
for (const auto& str : parts) {
long n = 0;
str.ToCLong(&n);
Expand All @@ -21,6 +23,7 @@ clVersionString::~clVersionString() {}
int clVersionString::Compare(const wxString& other) const
{
clVersionString ver_other(other);
clDEBUG() << "Comparing:" << other << "against:" << m_versionString << endl;
size_t elements_count = std::max(ver_other.m_numbers.size(), m_numbers.size());
for (size_t i = 0; i < elements_count; ++i) {
if (number_at(i) > ver_other.number_at(i)) {
Expand Down
7 changes: 4 additions & 3 deletions CodeLite/clVersionString.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,9 @@
#include <vector>
#include <wx/string.h>

/// Utility class converting between version string -> number
/// Example: 1.2.3 -> 1*10^2 + 2*10^3 + 3*10^0 -> 123
/// Utility class for comparing between version string in the format of X.Y.Z
class WXDLLIMPEXP_CL clVersionString
{

public:
clVersionString(const wxString& version_string);
~clVersionString();
Expand All @@ -18,7 +16,10 @@ class WXDLLIMPEXP_CL clVersionString
/// Return `0` if they are equal
int Compare(const wxString& other) const;

const wxString& GetVersionString() const { return m_versionString; }

private:
long number_at(size_t index) const;
std::vector<long> m_numbers;
wxString m_versionString;
};
8 changes: 4 additions & 4 deletions LiteEditor/code_parser.rc
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,8 @@ aaaaa ICON "codelite-logo.ico"
///////////////////////////////////////////////////////////////////////////////
// Version information
VS_VERSION_INFO VERSIONINFO
FILEVERSION 18,01,0,0
PRODUCTVERSION 18,01,0,0
FILEVERSION 18,1,0,0
PRODUCTVERSION 18,1,0,0
FILEFLAGSMASK 0x3fL // VS_FFI_FILEFLAGSMASK
FILEFLAGS 0x0L // final version
FILEOS VOS_NT_WINDOWS32
Expand All @@ -31,14 +31,14 @@ FILESUBTYPE VFT2_UNKNOWN { // not used
VALUE "CompanyName", "Eran Ifrah"
VALUE "Developer", "Eran Ifrah"
VALUE "FileDescription", "CodeLite, an Open Source cross platform C, C++, Rust, Python, PHP and Node.js IDE"
VALUE "FileVersion", "18.01.0"
VALUE "FileVersion", "18.1.0"
VALUE "InternalName", "CodeLite"
VALUE "LegalCopyright", "Copyright (C) 2007-2025 Eran Ifrah"
VALUE "LegalTrademarks", "All rights reserved."
VALUE "OriginalFilename", "codelite.exe"
VALUE "PrivateBuild", ""
VALUE "ProductName", "CodeLite"
VALUE "ProductVersion", "18.01.0 (64-BIT)"
VALUE "ProductVersion", "18.1.0 (64-BIT)"
VALUE "SpecialBuild", ""
VALUE "Support", "https://forums.codelite.org"
VALUE "Users", "Unlimited."
Expand Down
2 changes: 1 addition & 1 deletion LiteEditor/frame.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1918,7 +1918,7 @@ void clMainFrame::OnAbout(wxCommandEvent& WXUNUSED(event))
// Misc
info.SetWebSite("https://codelite.org", _("CodeLite Home"));
info.SetVersion(CODELITE_VERSION_STRING);
info.SetCopyright("Eran Ifrah 2007-2024");
info.SetCopyright("Eran Ifrah 2007-2025");

// Load the license file
wxFileName license(clStandardPaths::Get().GetDataDir(), "LICENSE");
Expand Down
32 changes: 17 additions & 15 deletions LiteEditor/webupdatethread.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@

#include "JSON.h"
#include "autoversion.h"
#include "clVersionString.hpp"
#include "file_logger.h"
#include "precompiled_header.h"
#include "procutils.h"
Expand All @@ -48,36 +49,38 @@ struct CodeLiteVersion {
wxString m_codename;
wxString m_arch;
wxString m_url;
int m_version;
wxString m_version;
bool m_isReleaseVersion;
CodeLiteVersion(const JSONItem& json)
: m_version(wxNOT_FOUND)
, m_isReleaseVersion(false)
: m_isReleaseVersion(false)
{
m_os = json.namedObject("os").toString();
m_codename = json.namedObject("codename").toString();
m_arch = json.namedObject("arch").toString();
m_url = json.namedObject("url").toString();
m_version = json.namedObject("version").toInt();
if (json.namedObject("version").isNumber()) {
m_version = "18.0.0"; // the last version supporting number was 18.0.0
} else {
m_version = json.namedObject("version").toString();
}
m_isReleaseVersion = json.namedObject("isRelease").toBool(m_isReleaseVersion);
}

void Print() { clDEBUG() << "--->" << m_os << "," << m_codename << "," << m_arch << "," << m_version << clEndl; }

/**
* @brief return true of this codelite version object is newer than the provided input
* @brief return true of this CodeLite version object is newer than the provided input
*/
bool IsNewer(const wxString& os, const wxString& codename, const wxString& arch) const
{
wxString strVersionNumer = CURRENT_CODELITE_VERSION;
strVersionNumer.Replace(".", "");
long nVersionNumber = -1;
strVersionNumer.ToCLong(&nVersionNumber);
clVersionString this_version{ CURRENT_CODELITE_VERSION };
clVersionString version_from_web{ m_version };

if ((m_os == os) && (m_arch == arch) && (m_codename == codename)) {
bool res = (m_version > nVersionNumber);
bool res = version_from_web.Compare(CURRENT_CODELITE_VERSION) > 0;
if (res) {
clDEBUG() << "Found new version!" << clEndl;
clSYSTEM() << "A newer version of CodeLite is available for download. Current version is:"
<< this_version.GetVersionString() << ", new version:" << m_version << endl;
}
return res;
}
Expand All @@ -89,7 +92,6 @@ struct CodeLiteVersion {
const wxString& GetCodename() const { return m_codename; }
const wxString& GetOs() const { return m_os; }
const wxString& GetUrl() const { return m_url; }
int GetVersion() const { return m_version; }
};

WebUpdateJob::WebUpdateJob(wxEvtHandler* parent, bool userRequest, bool onlyRelease)
Expand Down Expand Up @@ -118,16 +120,16 @@ void WebUpdateJob::ParseFile()
if (!v.IsReleaseVersion() && m_onlyRelease) {
// User wishes to be prompted for new releases only
// skip weekly builds
clDEBUG() << "Found version:" << v.GetVersion()
clDEBUG() << "Found version:" << v.m_version
<< ", a non release version. However, use requested for stable releases only" << endl;
continue;
}

if (v.IsNewer(os, codename, arch)) {
clDEBUG() << "A new version of CodeLite found" << clEndl;
wxCommandEvent event(wxEVT_CMD_NEW_VERSION_AVAILABLE);
event.SetClientData(new WebUpdateJobData("https://codelite.org/support.php", v.GetUrl(),
CURRENT_CODELITE_VERSION, "", false, true));
event.SetClientData(new WebUpdateJobData(
"https://codelite.org/support.php", v.GetUrl(), CURRENT_CODELITE_VERSION, "", false, true));
m_parent->AddPendingEvent(event);
return;
}
Expand Down
62 changes: 39 additions & 23 deletions Plugin/clAboutDialogBase.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -19,12 +19,12 @@ wxBorder get_border_simple_theme_aware_bit()
#else
return wxBORDER_DEFAULT;
#endif
} // DoGetBorderSimpleBit
} // get_border_simple_theme_aware_bit
bool bBitmapLoaded = false;
} // namespace

clAboutDialogBase::clAboutDialogBase(wxWindow* parent, wxWindowID id, const wxString& title, const wxPoint& pos,
const wxSize& size, long style)
clAboutDialogBase::clAboutDialogBase(
wxWindow* parent, wxWindowID id, const wxString& title, const wxPoint& pos, const wxSize& size, long style)
: wxDialog(parent, id, title, pos, size, style)
{
if (!bBitmapLoaded) {
Expand All @@ -49,17 +49,20 @@ clAboutDialogBase::clAboutDialogBase(wxWindow* parent, wxWindowID id, const wxSt
wxBoxSizer* boxSizer16 = new wxBoxSizer(wxVERTICAL);
m_panelAbout->SetSizer(boxSizer16);

m_staticTextTitle = new wxStaticText(m_panelAbout, wxID_ANY,
m_staticTextTitle = new wxStaticText(m_panelAbout,
wxID_ANY,
_("CodeLite, a free, open source, C/C++/Rust/Python/PHP and JavaScript IDE"),
wxDefaultPosition, wxDLG_UNIT(m_panelAbout, wxSize(-1, -1)), 0);
wxDefaultPosition,
wxDLG_UNIT(m_panelAbout, wxSize(-1, -1)),
0);
wxFont m_staticTextTitleFont = wxSystemSettings::GetFont(wxSYS_DEFAULT_GUI_FONT);
m_staticTextTitleFont.SetStyle(wxFONTSTYLE_ITALIC);
m_staticTextTitle->SetFont(m_staticTextTitleFont);

boxSizer16->Add(m_staticTextTitle, 0, wxALL | wxALIGN_CENTER_HORIZONTAL, WXC_FROM_DIP(10));

m_panel22 = new wxPanel(m_panelAbout, wxID_ANY, wxDefaultPosition, wxDLG_UNIT(m_panelAbout, wxSize(-1, -1)),
wxTAB_TRAVERSAL);
m_panel22 = new wxPanel(
m_panelAbout, wxID_ANY, wxDefaultPosition, wxDLG_UNIT(m_panelAbout, wxSize(-1, -1)), wxTAB_TRAVERSAL);

boxSizer16->Add(m_panel22, 1, wxEXPAND, WXC_FROM_DIP(5));

Expand All @@ -72,22 +75,26 @@ clAboutDialogBase::clAboutDialogBase(wxWindow* parent, wxWindowID id, const wxSt

boxSizer26->Add(flexGridSizer32, 1, wxALL | wxEXPAND, WXC_FROM_DIP(5));

m_staticText34 = new wxStaticText(m_panel22, wxID_ANY, _("Author:"), wxDefaultPosition,
wxDLG_UNIT(m_panel22, wxSize(-1, -1)), 0);
m_staticText34 = new wxStaticText(
m_panel22, wxID_ANY, _("Author:"), wxDefaultPosition, wxDLG_UNIT(m_panel22, wxSize(-1, -1)), 0);
wxFont m_staticText34Font = wxSystemSettings::GetFont(wxSYS_DEFAULT_GUI_FONT);
m_staticText34Font.SetStyle(wxFONTSTYLE_ITALIC);
m_staticText34Font.SetWeight(wxFONTWEIGHT_BOLD);
m_staticText34->SetFont(m_staticText34Font);

flexGridSizer32->Add(m_staticText34, 0, wxRIGHT | wxALIGN_RIGHT | wxALIGN_CENTER_VERTICAL, WXC_FROM_DIP(5));

m_staticTextSubtitle = new wxStaticText(m_panel22, wxID_ANY, _("2007 - 2024, by Eran Ifrah"), wxDefaultPosition,
wxDLG_UNIT(m_panel22, wxSize(-1, -1)), 0);
m_staticTextSubtitle = new wxStaticText(m_panel22,
wxID_ANY,
_("2007 - 2025, by Eran Ifrah"),
wxDefaultPosition,
wxDLG_UNIT(m_panel22, wxSize(-1, -1)),
0);

flexGridSizer32->Add(m_staticTextSubtitle, 0, wxLEFT | wxALIGN_LEFT | wxALIGN_CENTER_VERTICAL, WXC_FROM_DIP(5));

m_staticText36 = new wxStaticText(m_panel22, wxID_ANY, _("Version:"), wxDefaultPosition,
wxDLG_UNIT(m_panel22, wxSize(-1, -1)), 0);
m_staticText36 = new wxStaticText(
m_panel22, wxID_ANY, _("Version:"), wxDefaultPosition, wxDLG_UNIT(m_panel22, wxSize(-1, -1)), 0);
wxFont m_staticText36Font = wxSystemSettings::GetFont(wxSYS_DEFAULT_GUI_FONT);
m_staticText36Font.SetStyle(wxFONTSTYLE_ITALIC);
m_staticText36Font.SetWeight(wxFONTWEIGHT_BOLD);
Expand All @@ -100,17 +107,22 @@ clAboutDialogBase::clAboutDialogBase(wxWindow* parent, wxWindowID id, const wxSt

flexGridSizer32->Add(m_staticTextVersion, 0, wxLEFT | wxEXPAND, WXC_FROM_DIP(5));

m_staticText40 = new wxStaticText(m_panel22, wxID_ANY, _("Home Page:"), wxDefaultPosition,
wxDLG_UNIT(m_panel22, wxSize(-1, -1)), 0);
m_staticText40 = new wxStaticText(
m_panel22, wxID_ANY, _("Home Page:"), wxDefaultPosition, wxDLG_UNIT(m_panel22, wxSize(-1, -1)), 0);
wxFont m_staticText40Font = wxSystemSettings::GetFont(wxSYS_DEFAULT_GUI_FONT);
m_staticText40Font.SetStyle(wxFONTSTYLE_ITALIC);
m_staticText40Font.SetWeight(wxFONTWEIGHT_BOLD);
m_staticText40->SetFont(m_staticText40Font);

flexGridSizer32->Add(m_staticText40, 0, wxRIGHT | wxALIGN_RIGHT, WXC_FROM_DIP(5));

m_hyperLink44 = new wxHyperlinkCtrl(m_panel22, wxID_ANY, _("CodeLite IDE"), wxT("https://codelite.org"),
wxDefaultPosition, wxDLG_UNIT(m_panel22, wxSize(-1, -1)), wxHL_DEFAULT_STYLE);
m_hyperLink44 = new wxHyperlinkCtrl(m_panel22,
wxID_ANY,
_("CodeLite IDE"),
wxT("https://codelite.org"),
wxDefaultPosition,
wxDLG_UNIT(m_panel22, wxSize(-1, -1)),
wxHL_DEFAULT_STYLE);

flexGridSizer32->Add(m_hyperLink44, 0, wxLEFT, WXC_FROM_DIP(5));

Expand All @@ -121,9 +133,11 @@ clAboutDialogBase::clAboutDialogBase(wxWindow* parent, wxWindowID id, const wxSt
wxBoxSizer* boxSizer18 = new wxBoxSizer(wxVERTICAL);
m_paneLicense->SetSizer(boxSizer18);

m_stcLicense =
new clThemedSTC(m_paneLicense, wxID_ANY, wxDefaultPosition, wxDLG_UNIT(m_paneLicense, wxSize(300, 200)),
wxBORDER_NONE | get_border_simple_theme_aware_bit());
m_stcLicense = new clThemedSTC(m_paneLicense,
wxID_ANY,
wxDefaultPosition,
wxDLG_UNIT(m_paneLicense, wxSize(300, 200)),
wxBORDER_NONE | get_border_simple_theme_aware_bit());
// Configure the fold margin
m_stcLicense->SetMarginType(4, wxSTC_MARGIN_SYMBOL);
m_stcLicense->SetMarginMask(4, wxSTC_MASK_FOLDERS);
Expand Down Expand Up @@ -168,9 +182,11 @@ clAboutDialogBase::clAboutDialogBase(wxWindow* parent, wxWindowID id, const wxSt
wxBoxSizer* boxSizer20 = new wxBoxSizer(wxVERTICAL);
m_panelCredits->SetSizer(boxSizer20);

m_stcCredits =
new clThemedSTC(m_panelCredits, wxID_ANY, wxDefaultPosition, wxDLG_UNIT(m_panelCredits, wxSize(-1, -1)),
wxBORDER_NONE | get_border_simple_theme_aware_bit());
m_stcCredits = new clThemedSTC(m_panelCredits,
wxID_ANY,
wxDefaultPosition,
wxDLG_UNIT(m_panelCredits, wxSize(-1, -1)),
wxBORDER_NONE | get_border_simple_theme_aware_bit());
// Configure the fold margin
m_stcCredits->SetMarginType(4, wxSTC_MARGIN_SYMBOL);
m_stcCredits->SetMarginMask(4, wxSTC_MASK_FOLDERS);
Expand Down
7 changes: 5 additions & 2 deletions Plugin/clAboutDialogBase.h
Original file line number Diff line number Diff line change
Expand Up @@ -77,8 +77,11 @@ class clAboutDialogBase : public wxDialog
clThemedSTC* GetStcCredits() { return m_stcCredits; }
wxPanel* GetPanelCredits() { return m_panelCredits; }
wxNotebook* GetNotebook8() { return m_notebook8; }
clAboutDialogBase(wxWindow* parent, wxWindowID id = wxID_ANY, const wxString& title = _("About"),
const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxSize(-1, -1),
clAboutDialogBase(wxWindow* parent,
wxWindowID id = wxID_ANY,
const wxString& title = _("About"),
const wxPoint& pos = wxDefaultPosition,
const wxSize& size = wxSize(-1, -1),
long style = wxDEFAULT_DIALOG_STYLE | wxRESIZE_BORDER);
virtual ~clAboutDialogBase();
};
Expand Down
2 changes: 1 addition & 1 deletion Plugin/clAboutDialogBase.wxcp
Original file line number Diff line number Diff line change
Expand Up @@ -698,7 +698,7 @@
}, {
"type": "multi-string",
"m_label": "Label:",
"m_value": "2007 - 2024, by Eran Ifrah"
"m_value": "2007 - 2025, by Eran Ifrah"
}, {
"type": "string",
"m_label": "Wrap:",
Expand Down
6 changes: 3 additions & 3 deletions Runtime/Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
<key>CFBundleExecutable</key>
<string>CodeLite</string>
<key>CFBundleInfoDictionaryVersion</key>
<string>18.01.0</string>
<string>18.1.0</string>
<key>CFBundleName</key>
<string>CodeLite</string>
<key>CFBundleIconFile</key>
Expand All @@ -18,9 +18,9 @@
<key>CFBundleIdentifier</key>
<string>com.eranif.CodeLite</string>
<key>CFBundleVersion</key>
<string>CodeLite IDE version 18.01.0</string>
<string>CodeLite IDE version 18.1.0</string>
<key>CFBundleShortVersionString</key>
<string>CodeLite IDE version 18.01.0</string>
<string>CodeLite IDE version 18.1.0</string>
<key>CSResourcesFileMapped</key>
<true/>
<key>CFBundleDocumentTypes</key>
Expand Down
Binary file modified art/cl-splash.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified art/cl-splash.xcf
Binary file not shown.
Binary file modified art/[email protected]
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified art/[email protected]
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 1df4ad0

Please sign in to comment.