Permalink
Browse files

fixed crash on WP8. it happened when we start app second time and more

  • Loading branch information...
1 parent 0280f2b commit d33201ebde41c3f0938b5562d614d63c2b125f3d @rognar rognar committed Mar 18, 2013
Showing with 8 additions and 7 deletions.
  1. +3 −2 platform/wp8/build/wp.rake
  2. +5 −5 platform/wp8/rhodes/common/RhoResourceMap.cs
@@ -205,11 +205,12 @@ namespace "build" do
Dir.glob(File.join("**", '*.*')).each do |f|
if #f.start_with?('db') ||
f.end_with?('.rb') ||
- f.end_with?('.erb') ||
+ f.end_with?('.erb')
+ # ||
#f == "apps/app_manifest.txt" ||
#f == "apps/rhoconfig.txt" ||
#f == "apps/rhoconfig.txt.timestamp" ||
- f == "RhoBundleMap.txt"
+ #f == "RhoBundleMap.txt"
next;
end
@@ -52,7 +52,7 @@ private static void clearMap(String strMap)
{
CRhoFile.deleteFile(strFile);
}
- }
+ }
}
private static void copyMap(String strMap)
@@ -63,7 +63,7 @@ private static void copyMap(String strMap)
{
String[] values = files[i].Split('|');
- String strFile = values[0];
+ String strFile = values[0];
String strDstFile = values[1];
System.Diagnostics.Debugger.Log(0, "", strDstFile + "\n");
@@ -75,7 +75,7 @@ private static void copyMap(String strMap)
CRhoFile.writeStringToFile("RhoBundleMap.txt", strMap);
}
- public static void deployContent()
+ public static void deployContent()
{
String newMap = CRhoFile.readStringFromResourceFile("RhoBundleMap.txt");
String curMap = CRhoFile.readStringFromFile("RhoBundleMap.txt");
@@ -84,10 +84,10 @@ public static void deployContent()
{
copyMap(newMap);
}
- else if (curMap != newMap)
+ else if (curMap != newMap && newMap != "")
{
clearMap(curMap);
- copyMap(newMap);
+ copyMap(newMap);
}
}
}

0 comments on commit d33201e

Please sign in to comment.