File tree Expand file tree Collapse file tree 2 files changed +4
-4
lines changed
Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -125,7 +125,7 @@ bool Application::OnInit()
125125 ClientVersion::loadVersions ();
126126
127127#ifdef _USE_PROCESS_COM
128- m_single_instance_checker = newd wxSingleInstanceChecker;
128+ m_single_instance_checker = newd wxSingleInstanceChecker; // Instance checker has to stay alive throughout the applications lifetime
129129 if (g_settings.getInteger (Config::ONLY_ONE_INSTANCE) && m_single_instance_checker->IsAnotherRunning ()) {
130130 RMEProcessClient client;
131131 wxConnectionBase* connection = client.MakeConnection (" localhost" , " rme_host" , " rme_talk" );
@@ -139,7 +139,7 @@ bool Application::OnInit()
139139 wxDELETE (connection);
140140 }
141141 wxDELETE (m_single_instance_checker);
142- return false ;
142+ return false ; // Since we return false - OnExit is never called
143143 }
144144 // We act as server then
145145 m_proc_server = newd RMEProcessServer ();
Original file line number Diff line number Diff line change @@ -40,8 +40,8 @@ RMEProcessServer::~RMEProcessServer()
4040wxConnectionBase* RMEProcessServer::OnAcceptConnection (const wxString& topic)
4141{
4242 if (topic.Lower () == " rme_talk" ) {
43- g_gui.root ->Iconize (false );
44- g_gui.root ->Raise ();
43+ g_gui.root ->Iconize (false ); // Show application if minimized
44+ g_gui.root ->Raise (); // Request the window manager to raise this application to the top of Z-order
4545 return newd RMEProcessConnection ();
4646 }
4747 return nullptr ;
You can’t perform that action at this time.
0 commit comments