move the freeModule too, couple of style tweaks
authornemo
Mon, 24 Feb 2014 13:41:32 -0500
changeset 10159 5848ed144e0b
parent 10158 cbdd9465a8c5
child 10160 4608f10ae65f
move the freeModule too, couple of style tweaks
QTfrontend/net/hwmap.cpp
QTfrontend/ui/widget/mapContainer.cpp
hedgewars/hwengine.pas
--- a/QTfrontend/net/hwmap.cpp	Sun Feb 23 22:25:52 2014 +0100
+++ b/QTfrontend/net/hwmap.cpp	Mon Feb 24 13:41:32 2014 -0500
@@ -74,7 +74,7 @@
     SendIPC(QString("eseed %1").arg(m_seed).toUtf8());
     SendIPC(QString("e$template_filter %1").arg(templateFilter).toUtf8());
     SendIPC(QString("e$mapgen %1").arg(m_mapgen).toUtf8());
-    if (m_script.length())
+    if (!m_script.isEmpty())
     {
         SendIPC(QString("escript Scripts/Multiplayer/%1.lua").arg(m_script).toUtf8());
     }
--- a/QTfrontend/ui/widget/mapContainer.cpp	Sun Feb 23 22:25:52 2014 +0100
+++ b/QTfrontend/ui/widget/mapContainer.cpp	Mon Feb 24 13:41:32 2014 -0500
@@ -59,7 +59,7 @@
     m_previewEnabled = false;
     m_missionsViewSetup = false;
     m_staticViewSetup = false;
-    m_script = QString("");
+    m_script = QString();
 
     hhSmall.load(":/res/hh_small.png");
     hhLimit = 18;
--- a/hedgewars/hwengine.pas	Sun Feb 23 22:25:52 2014 +0100
+++ b/hedgewars/hwengine.pas	Mon Feb 24 13:41:32 2014 -0500
@@ -504,7 +504,6 @@
         uInputHandler.freeModule;
         uStats.freeModule;          //stub
         uSound.freeModule;
-        uScript.freeModule;
         uMisc.freeModule;
         uLandTexture.freeModule;
         uGears.freeModule;
@@ -516,7 +515,6 @@
 {$IFDEF USE_TOUCH_INTERFACE}uTouch.freeModule;{$ENDIF}  //stub
 {$IFDEF ANDROID}GLUnit.freeModule;{$ENDIF}
         uTextures.freeModule;
-        uPhysFSLayer.freeModule;
         end;
 
     uIO.freeModule;
@@ -527,6 +525,8 @@
     uCommands.freeModule;
     uVariables.freeModule;
     uUtils.freeModule;              // closes debug file
+    uPhysFSLayer.freeModule;
+    uScript.freeModule;
 end;
 
 ///////////////////////////////////////////////////////////////////////////////