Skip to content

Commit

Permalink
Set portable when it is needed (#2638)
Browse files Browse the repository at this point in the history
  • Loading branch information
DoumanAsh committed May 4, 2024
1 parent 2dc7dfe commit 5d7d5ff
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
3 changes: 0 additions & 3 deletions src/kvirc/kernel/KviApplication.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -227,9 +227,6 @@ KviApplication::KviApplication(int & argc, char ** argv)
kvi_socket_flushTrafficCounters();
// don't let qt quit the application by itself
setQuitOnLastWindowClosed(false);
#if defined(COMPILE_ON_WINDOWS) || defined(COMPILE_ON_MINGW)
m_bPortable = KviFileUtils::fileExists(QString("%1%2%3").arg(g_pApp->applicationDirPath().arg(KVI_PATH_SEPARATOR_CHAR).arg("portable")));
#endif

//note: the early qApp->style() call leads to a crash on osx
#if !defined(COMPILE_ENABLE_GTKSTYLE) && !defined(COMPILE_ON_MAC)
Expand Down
2 changes: 2 additions & 0 deletions src/kvirc/kernel/KviApplication_setup.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -298,6 +298,8 @@ bool KviApplication::findLocalKvircDirectory()
#endif //COMPILE_KDE_SUPPORT

#if defined(COMPILE_ON_WINDOWS) || defined(COMPILE_ON_MINGW)
const auto portable_file = QString("%1%2%3").arg(g_pApp->applicationDirPath()).arg(KVI_PATH_SEPARATOR_CHAR).arg("portable");
m_bPortable = KviFileUtils::fileExists(portable_file);
if(m_bPortable)
{
m_szLocalKvircDir = QString("%1%2%3").arg(g_pApp->applicationDirPath()).arg(KVI_PATH_SEPARATOR_CHAR).arg("Settings");
Expand Down

0 comments on commit 5d7d5ff

Please sign in to comment.