commit 59cc16aee9b3c9a47f5ca00ba2d82808371ae7ba
Author: Leszek Koltunski <leszek@koltunski.pl>
Date:   Fri Dec 17 19:43:30 2021 +0100

    Crash fix.

diff --git a/src/main/java/org/distorted/screens/RubikScreenPlay.java b/src/main/java/org/distorted/screens/RubikScreenPlay.java
index ae740b59..0599d575 100644
--- a/src/main/java/org/distorted/screens/RubikScreenPlay.java
+++ b/src/main/java/org/distorted/screens/RubikScreenPlay.java
@@ -561,17 +561,20 @@ public class RubikScreenPlay extends RubikScreenBase
 
   public void adjustSolvedIcons()
     {
-    int currObject = RubikObjectList.getCurrObject();
-    int dbLevel = RubikObjectList.getDBLevel(currObject);
-    int numLevel= Math.min(dbLevel, LEVELS_SHOWN);
-    RubikScores scores = RubikScores.getInstance();
-
-    for(int i=0; i<numLevel; i++)
+    if( mPlayLayout!=null )
       {
-      int level = i<numLevel-1 ? i+1 : dbLevel;
-      Button button = (Button)mPlayLayout.getChildAt(i);
-      int icon = scores.isSolved(currObject, level-1) ? R.drawable.ui_solved : R.drawable.ui_notsolved;
-      button.setCompoundDrawablesWithIntrinsicBounds(icon,0,0,0);
+      int currObject = RubikObjectList.getCurrObject();
+      int dbLevel = RubikObjectList.getDBLevel(currObject);
+      int numLevel= Math.min(dbLevel, LEVELS_SHOWN);
+      RubikScores scores = RubikScores.getInstance();
+
+      for(int i=0; i<numLevel; i++)
+        {
+        int level = i<numLevel-1 ? i+1 : dbLevel;
+        Button button = (Button)mPlayLayout.getChildAt(i);
+        int icon = scores.isSolved(currObject, level-1) ? R.drawable.ui_solved : R.drawable.ui_notsolved;
+        button.setCompoundDrawablesWithIntrinsicBounds(icon,0,0,0);
+        }
       }
     }
 
