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/external/RubikUpdates.java
26 26
import android.graphics.Bitmap;
27 27
import org.distorted.objects.RubikObjectList;
28 28

  
29
import static org.distorted.main.RubikActivity.SHOW_DOWNLOADED_DEBUG;
30

  
29 31
///////////////////////////////////////////////////////////////////////////////////////////////////
30 32

  
31 33
public class RubikUpdates
......
118 120
      int objOrdinal = RubikObjectList.getOrdinal(shortName.toUpperCase());
119 121
      boolean updateO=true, updateE=true;
120 122

  
121
android.util.Log.e("D", "downloaded object "+shortName+" oMinor="+oMinor+" eMinor="+eMinor);
123
      if( SHOW_DOWNLOADED_DEBUG ) android.util.Log.e("D", "downloaded object "+shortName+" oMinor="+oMinor+" eMinor="+eMinor);
122 124

  
123 125
      if( objOrdinal>=0 )
124 126
        {
......
127 129
        updateO = localObjectMinor<oMinor;
128 130
        updateE = localExtrasMinor<eMinor;
129 131

  
130

  
131
android.util.Log.e("D", "object exists locally, localObjectMinor="+localObjectMinor+" localExtrasMinor="+localExtrasMinor);
132

  
132
        if( SHOW_DOWNLOADED_DEBUG ) android.util.Log.e("D", "object exists locally, localObjectMinor="+localObjectMinor+" localExtrasMinor="+localExtrasMinor);
133 133
        }
134 134
      if( updateO || updateE )
135 135
        {
136 136
        UpdateInfo info = new UpdateInfo(shortName,longName,description,oMinor,eMinor,oPercent,oIcon,updateO,updateE);
137 137
        if(oPercent>=100)
138 138
          {
139
android.util.Log.e("D", "object added to completed");
140

  
139
          if( SHOW_DOWNLOADED_DEBUG ) android.util.Log.e("D", "object added to completed");
141 140
          mCompleted.add(info);
142 141
          }
143 142
        else
144 143
          {
145
android.util.Log.e("D", "object added to started");
146

  
144
          if( SHOW_DOWNLOADED_DEBUG ) android.util.Log.e("D", "object added to started");
147 145
          mStarted.add(info);
148 146
          }
149 147
        }
......
154 152

  
155 153
  void parse(String updates)
156 154
    {
157
    android.util.Log.e("D", updates);
155
    if( SHOW_DOWNLOADED_DEBUG ) android.util.Log.e("D", updates);
158 156

  
159 157
    mCompleted.clear();
160 158
    mStarted.clear();

Also available in: Unified diff