Project

General

Profile

« Previous | Next » 

Revision e847c553

Added by Leszek Koltunski about 2 years ago

Make 'downloaded' debugs controlled by a single boolean.

View differences:

src/main/java/org/distorted/objects/RubikObjectList.java
31 31

  
32 32
import static org.distorted.objectlib.main.TwistyObject.MESH_NICE;
33 33
import static org.distorted.objectlib.main.ObjectType.NUM_OBJECTS;
34
import static org.distorted.main.RubikActivity.SHOW_DOWNLOADED_DEBUG;
34 35

  
35 36
///////////////////////////////////////////////////////////////////////////////////////////////////
36 37

  
......
104 105
      mObjects.add(obj);
105 106
      mNumObjects++;
106 107

  
107
android.util.Log.e("D", "creating local object "+type.name() );
108
      if( SHOW_DOWNLOADED_DEBUG ) android.util.Log.e("D", "creating local object "+type.name() );
108 109

  
109 110
      if( obj.hasExtras() )
110 111
        {
111
        android.util.Log.e("D", "has extras "+mNumExtras );
112

  
112
        if( SHOW_DOWNLOADED_DEBUG ) android.util.Log.e("D", "has extras "+mNumExtras );
113 113

  
114 114
        obj.setExtrasOrdinal(mNumExtras);
115 115
        mNumExtras++;
116 116
        }
117 117
      else
118 118
        {
119
        android.util.Log.e("D", "no extras");
120

  
119
        if( SHOW_DOWNLOADED_DEBUG ) android.util.Log.e("D", "no extras");
121 120
        }
122 121
      }
123 122
    }
......
138 137
    mObjects.add(obj);
139 138
    mNumObjects++;
140 139

  
141

  
142
android.util.Log.e("D", "creating downloaded object "+obj.getUpperName() );
140
    if( SHOW_DOWNLOADED_DEBUG ) android.util.Log.e("D", "creating downloaded object "+obj.getUpperName() );
143 141

  
144 142
    if( obj.hasExtras() )
145 143
      {
146
      android.util.Log.e("D", "has extras "+mNumExtras );
144
      if( SHOW_DOWNLOADED_DEBUG ) android.util.Log.e("D", "has extras "+mNumExtras );
147 145

  
148 146
      obj.setExtrasOrdinal(mNumExtras);
149 147
      mNumExtras++;
150 148
      }
151 149
    else
152 150
      {
153
      android.util.Log.e("D", "no extras");
151
      if( SHOW_DOWNLOADED_DEBUG ) android.util.Log.e("D", "no extras");
154 152
      }
155 153

  
156 154
    return true;
......
197 195
        obj.object|= object;
198 196
        obj.extras|= extras;
199 197

  
200
        android.util.Log.e("D", "Updating downloaded object "+shortName);
198
        if( SHOW_DOWNLOADED_DEBUG ) android.util.Log.e("D", "Updating downloaded object "+shortName);
201 199

  
202 200
        return;
203 201
        }
......
206 204
    DownloadedObject extra = new DownloadedObject(shortName,numScrambles,objectMinor,extrasMinor,icon,object,extras);
207 205
    if ( internalAddDownloadedObject(extra) )
208 206
      {
209
      android.util.Log.e("D", "Adding new downloaded object "+shortName);
207
      if( SHOW_DOWNLOADED_DEBUG ) android.util.Log.e("D", "Adding new downloaded object "+shortName);
210 208
      mDownloadedObjects.add(extra);
211 209
      }
212 210
    }
......
259 257
        }
260 258

  
261 259
      String objects = downloadedObjects.toString();
262
android.util.Log.e("D", "saving: "+objects);
260
      if( SHOW_DOWNLOADED_DEBUG ) android.util.Log.e("D", "saving: "+objects);
263 261

  
264 262
      editor.putString("rol_downloaded", objects );
265 263
      }
......
287 285
    {
288 286
    String downloaded = preferences.getString("rol_downloaded","");
289 287

  
290
    android.util.Log.e("D", downloaded);
288
    if( SHOW_DOWNLOADED_DEBUG ) android.util.Log.e("D", downloaded);
291 289

  
292 290
    if( !downloaded.equals(""))
293 291
      {

Also available in: Unified diff