Revision 90288e23
Added by Leszek Koltunski almost 3 years ago
src/main/java/org/distorted/objects/RubikObject.java | ||
---|---|---|
32 | 32 |
import org.distorted.dmesh.ObjectMesh; |
33 | 33 |
import org.distorted.external.RubikFiles; |
34 | 34 |
import org.distorted.jsons.ObjectJson; |
35 |
import org.distorted.main.R; |
|
35 | 36 |
import org.distorted.objectlib.json.JsonWriter; |
36 | 37 |
import org.distorted.objectlib.main.ObjectType; |
37 | 38 |
import org.distorted.patterns.RubikPatternList; |
... | ... | |
99 | 100 |
mExtrasOrdinal = -1; |
100 | 101 |
|
101 | 102 |
mMeshID = 0; |
102 |
mIconID = -1; |
|
103 | 103 |
mJsonID = -1; |
104 | 104 |
mExtrasID = -1; |
105 |
|
|
106 |
if( object.icon ) // icon successfully downloaded |
|
107 |
{ |
|
108 |
if( SHOW_DOWNLOADED_DEBUG ) android.util.Log.e("D", object.shortName+" : icon downloaded"); |
|
109 |
mIconID = -1; // i.e. look for the icon in local per-app storage |
|
110 |
} |
|
111 |
else |
|
112 |
{ |
|
113 |
if( SHOW_DOWNLOADED_DEBUG ) android.util.Log.e("D", object.shortName+" : icon failed to download"); |
|
114 |
mIconID = R.drawable.unknown_icon; |
|
115 |
} |
|
105 | 116 |
} |
106 | 117 |
|
107 | 118 |
/////////////////////////////////////////////////////////////////////////////////////////////////// |
Also available in: Unified diff
Make sure we always display some icon in the Popup dialog, even if we fail to download one.