commit ff3775686b1980bbd3ca12abf7c82200f01570bf
Author: leszek <leszek@koltunski.pl>
Date:   Wed Mar 13 15:38:33 2024 +0100

    If an object is re-stickered so that there are less colors on its faces than originally - also do not remember those records locally at all.

diff --git a/src/main/java/org/distorted/external/RubikScores.java b/src/main/java/org/distorted/external/RubikScores.java
index 3c4e3ce3..65b21b37 100644
--- a/src/main/java/org/distorted/external/RubikScores.java
+++ b/src/main/java/org/distorted/external/RubikScores.java
@@ -300,7 +300,7 @@ public class RubikScores
 
     long oldRecord = oldValue.record;
 
-    if( oldRecord>record)
+    if( oldRecord>record )
       {
       MapValue value = new MapValue(record,0);
       mMap.put(key,value);
diff --git a/src/main/java/org/distorted/playui/PlayLibInterface.java b/src/main/java/org/distorted/playui/PlayLibInterface.java
index 67dff473..94e91977 100644
--- a/src/main/java/org/distorted/playui/PlayLibInterface.java
+++ b/src/main/java/org/distorted/playui/PlayLibInterface.java
@@ -276,10 +276,13 @@ public class PlayLibInterface implements ObjectLibInterface
     if( ScreenList.getCurrentScreen()==ScreenList.SOLV )
       {
       PlayActivity act = mAct.get();
+      ObjectControl control = act.getControl();
+      TwistyObject obj = control.getObject();
+      boolean submittable = obj.isSubmittable();
       int objectOrdinal = act.getObjectOrdinal();
       ScreenSolving solving = (ScreenSolving)ScreenList.SOLV.getScreenClass();
       mNewRecord = solving.stopTimerAndGetRecord();
-      mIsNewRecord = solving.setRecord(objectOrdinal);
+      mIsNewRecord = submittable ? solving.setRecord(objectOrdinal) : RECORD_NOT_NEW;
       }
     }
 
@@ -290,7 +293,11 @@ public class PlayLibInterface implements ObjectLibInterface
     if( ScreenList.getCurrentScreen()==ScreenList.SOLV )
       {
       PlayActivity act = mAct.get();
-      reportRecord(act,startTime,endTime,debug,scrambleNum);
+      ObjectControl control = act.getControl();
+      TwistyObject obj = control.getObject();
+      boolean submittable = obj.isSubmittable();
+
+      if( submittable ) reportRecord(act,startTime,endTime,debug,scrambleNum);
 
       RubikScores scores = RubikScores.getInstance();
       int numWins = scores.incrementNumWins();
@@ -304,24 +311,10 @@ public class PlayLibInterface implements ObjectLibInterface
       switch(mIsNewRecord)
         {
         case RECORD_FIRST  :
-        case RECORD_NEW    : ObjectControl control = act.getControl();
-                             TwistyObject obj = control.getObject();
-                             boolean submittable = obj.isSubmittable();
-
-                             Bundle byes = createDialogBundle();
-
-                             if( submittable )
-                               {
-                               RubikDialogNewRecord dyes = new RubikDialogNewRecord();
-                               dyes.setArguments(byes);
-                               dyes.show( act.getSupportFragmentManager(), RubikDialogNewRecord.getDialogTag() );
-                               }
-                             else
-                               {
-                               RubikDialogSolved dno = new RubikDialogSolved();
-                               dno.setArguments(byes);
-                               dno.show( act.getSupportFragmentManager(), RubikDialogSolved.getDialogTag() );
-                               }
+        case RECORD_NEW    : Bundle byes = createDialogBundle();
+                             RubikDialogNewRecord dyes = new RubikDialogNewRecord();
+                             dyes.setArguments(byes);
+                             dyes.show( act.getSupportFragmentManager(), RubikDialogNewRecord.getDialogTag() );
                              break;
         case RECORD_NOT_NEW: Bundle bno = createDialogBundle();
                              RubikDialogSolved dno = new RubikDialogSolved();
