mirror of
https://github.com/NativeScript/NativeScript.git
synced 2025-11-05 13:26:48 +08:00
Fix loggin mode (#60)
This commit is contained in:
@@ -360,7 +360,7 @@ public class CommonLayoutParams extends FrameLayout.LayoutParams {
|
|||||||
}
|
}
|
||||||
|
|
||||||
static void log(String tag, String message) {
|
static void log(String tag, String message) {
|
||||||
Log.d(tag, message);
|
Log.v(tag, message);
|
||||||
}
|
}
|
||||||
|
|
||||||
static StringBuilder getStringBuilder() {
|
static StringBuilder getStringBuilder() {
|
||||||
|
|||||||
@@ -260,7 +260,7 @@ public class Fetcher extends Resizer {
|
|||||||
}
|
}
|
||||||
return decodeSampledBitmapFromResource(mResources, resId, decodeWidth, decodeHeight, getCache());
|
return decodeSampledBitmapFromResource(mResources, resId, decodeWidth, decodeHeight, getCache());
|
||||||
} else {
|
} else {
|
||||||
Log.v(TAG, "Missing ResourceID: " + stringData);
|
Log.v(TAG, "Missing Image with resourceID: " + stringData);
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
if (useCache) {
|
if (useCache) {
|
||||||
|
|||||||
@@ -97,7 +97,7 @@ public abstract class Worker {
|
|||||||
Bitmap value = null;
|
Bitmap value = null;
|
||||||
String dataString = String.valueOf(data);
|
String dataString = String.valueOf(data);
|
||||||
if (debuggable > 0) {
|
if (debuggable > 0) {
|
||||||
Log.d(TAG, "loadImage on: " + imageView + " to: " + dataString);
|
Log.v(TAG, "loadImage on: " + imageView + " to: " + dataString);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (mCache != null && useCache) {
|
if (mCache != null && useCache) {
|
||||||
@@ -120,12 +120,12 @@ public abstract class Worker {
|
|||||||
if (value != null) {
|
if (value != null) {
|
||||||
// Bitmap found in memory cache
|
// Bitmap found in memory cache
|
||||||
if (debuggable > 0) {
|
if (debuggable > 0) {
|
||||||
Log.d(TAG, "Set ImageBitmap on: " + imageView + " to: " + dataString);
|
Log.v(TAG, "Set ImageBitmap on: " + imageView + " to: " + dataString);
|
||||||
}
|
}
|
||||||
imageView.setImageBitmap(value);
|
imageView.setImageBitmap(value);
|
||||||
if (listener != null) {
|
if (listener != null) {
|
||||||
if (debuggable > 0) {
|
if (debuggable > 0) {
|
||||||
Log.d(TAG, "OnImageLoadedListener on: " + imageView + " to: " + dataString);
|
Log.v(TAG, "OnImageLoadedListener on: " + imageView + " to: " + dataString);
|
||||||
}
|
}
|
||||||
listener.onImageLoaded(true);
|
listener.onImageLoaded(true);
|
||||||
}
|
}
|
||||||
@@ -352,14 +352,14 @@ public abstract class Worker {
|
|||||||
if (value != null && imageView != null) {
|
if (value != null && imageView != null) {
|
||||||
success = true;
|
success = true;
|
||||||
if (debuggable > 0) {
|
if (debuggable > 0) {
|
||||||
Log.d(TAG, "Set ImageDrawable on: " + imageView + " to: " + dataString);
|
Log.v(TAG, "Set ImageDrawable on: " + imageView + " to: " + dataString);
|
||||||
}
|
}
|
||||||
imageView.setImageBitmap(value);
|
imageView.setImageBitmap(value);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (mOnImageLoadedListener != null) {
|
if (mOnImageLoadedListener != null) {
|
||||||
if (debuggable > 0) {
|
if (debuggable > 0) {
|
||||||
Log.d(TAG, "OnImageLoadedListener on: " + imageView + " to: " + dataString);
|
Log.v(TAG, "OnImageLoadedListener on: " + imageView + " to: " + dataString);
|
||||||
}
|
}
|
||||||
mOnImageLoadedListener.onImageLoaded(success);
|
mOnImageLoadedListener.onImageLoaded(success);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user