1
0
mirror of https://github.com/moparisthebest/k-9 synced 2024-12-25 09:08:49 -05:00

find src/com/fsck/ -name \*.java|xargs astyle --style=ansi --mode=java --indent-switches --indent=spaces=4 --convert-tabs --unpad=paren

This commit is contained in:
Jesse Vincent 2010-04-29 04:59:14 +00:00
parent 2775795abe
commit 8af7f4a7b6
48 changed files with 579 additions and 513 deletions

View File

@ -186,7 +186,7 @@ public class Account implements BaseAccount
for (String type : networkTypes) for (String type : networkTypes)
{ {
Boolean useCompression = preferences.getPreferences().getBoolean(mUuid + ".useCompression." + type, Boolean useCompression = preferences.getPreferences().getBoolean(mUuid + ".useCompression." + type,
true); true);
compressionMap.put(type, useCompression); compressionMap.put(type, useCompression);
} }
@ -219,10 +219,10 @@ public class Account implements BaseAccount
Random random = new Random((long)mAccountNumber+4); Random random = new Random((long)mAccountNumber+4);
mChipColor = preferences.getPreferences().getInt(mUuid+".chipColor", mChipColor = preferences.getPreferences().getInt(mUuid+".chipColor",
(random.nextInt(0x70) ) + (random.nextInt(0x70)) +
(random.nextInt(0x70) * 0xff ) + (random.nextInt(0x70) * 0xff) +
(random.nextInt(0x70) * 0xffff ) + (random.nextInt(0x70) * 0xffff) +
0xff000000); 0xff000000);
mVibrate = preferences.getPreferences().getBoolean(mUuid + ".vibrate", false); mVibrate = preferences.getPreferences().getBoolean(mUuid + ".vibrate", false);
mRing = preferences.getPreferences().getBoolean(mUuid + ".ring", true); mRing = preferences.getPreferences().getBoolean(mUuid + ".ring", true);
@ -499,17 +499,19 @@ public class Account implements BaseAccount
long endTime = System.currentTimeMillis(); long endTime = System.currentTimeMillis();
if (K9.DEBUG) if (K9.DEBUG)
Log.d(K9.LOG_TAG, "Account.getStats() on " + getDescription() + " took " + (endTime - startTime) + " ms;" Log.d(K9.LOG_TAG, "Account.getStats() on " + getDescription() + " took " + (endTime - startTime) + " ms;"
+ " loading " + folders.size() + " took " + (folderLoadEnd - folderLoadStart) + " ms;" + " loading " + folders.size() + " took " + (folderLoadEnd - folderLoadStart) + " ms;"
+ " evaluating took " + (folderEvalEnd - folderEvalStart) + " ms"); + " evaluating took " + (folderEvalEnd - folderEvalStart) + " ms");
return stats; return stats;
} }
public void setChipColor(int color) { public void setChipColor(int color)
{
mChipColor = color; mChipColor = color;
} }
public int getChipColor() { public int getChipColor()
{
return mChipColor; return mChipColor;
} }
@ -615,18 +617,18 @@ public class Account implements BaseAccount
/* Have we sent a new mail notification on this account */ /* Have we sent a new mail notification on this account */
public boolean isRingNotified() public boolean isRingNotified()
{ {
return mRingNotified; return mRingNotified;
} }
public void setRingNotified(boolean ringNotified) public void setRingNotified(boolean ringNotified)
{ {
mRingNotified = ringNotified; mRingNotified = ringNotified;
} }
public synchronized String getRingtone() public synchronized String getRingtone()
{ {
return mRingtoneUri; return mRingtoneUri;
} }

View File

@ -25,25 +25,30 @@ import android.view.MotionEvent;
import android.view.View; import android.view.View;
public class ColorPickerDialog extends Dialog { public class ColorPickerDialog extends Dialog
{
public interface OnColorChangedListener { public interface OnColorChangedListener
{
void colorChanged(int color); void colorChanged(int color);
} }
private OnColorChangedListener mListener; private OnColorChangedListener mListener;
private int mInitialColor; private int mInitialColor;
private static class ColorPickerView extends View { private static class ColorPickerView extends View
{
private Paint mPaint; private Paint mPaint;
private Paint mCenterPaint; private Paint mCenterPaint;
private final int[] mColors; private final int[] mColors;
private OnColorChangedListener mListener; private OnColorChangedListener mListener;
ColorPickerView(Context c, OnColorChangedListener l, int color) { ColorPickerView(Context c, OnColorChangedListener l, int color)
{
super(c); super(c);
mListener = l; mListener = l;
mColors = new int[] { mColors = new int[]
{
0xFF800000, 0xFF800080, 0xFF000080, 0xFF008080, 0xFF008000, 0xFF800000, 0xFF800080, 0xFF000080, 0xFF008080, 0xFF008000,
0xFF808000, 0xFF800000 0xFF808000, 0xFF800000
}; };
@ -63,7 +68,8 @@ public class ColorPickerDialog extends Dialog {
private boolean mHighlightCenter; private boolean mHighlightCenter;
@Override @Override
protected void onDraw(Canvas canvas) { protected void onDraw(Canvas canvas)
{
float r = CENTER_X - mPaint.getStrokeWidth()*0.5f; float r = CENTER_X - mPaint.getStrokeWidth()*0.5f;
canvas.translate(CENTER_X, CENTER_X); canvas.translate(CENTER_X, CENTER_X);
@ -71,13 +77,17 @@ public class ColorPickerDialog extends Dialog {
canvas.drawOval(new RectF(-r, -r, r, r), mPaint); canvas.drawOval(new RectF(-r, -r, r, r), mPaint);
canvas.drawCircle(0, 0, CENTER_RADIUS, mCenterPaint); canvas.drawCircle(0, 0, CENTER_RADIUS, mCenterPaint);
if (mTrackingCenter) { if (mTrackingCenter)
{
int c = mCenterPaint.getColor(); int c = mCenterPaint.getColor();
mCenterPaint.setStyle(Paint.Style.STROKE); mCenterPaint.setStyle(Paint.Style.STROKE);
if (mHighlightCenter) { if (mHighlightCenter)
{
mCenterPaint.setAlpha(0xFF); mCenterPaint.setAlpha(0xFF);
} else { }
else
{
mCenterPaint.setAlpha(0x80); mCenterPaint.setAlpha(0x80);
} }
canvas.drawCircle(0, 0, canvas.drawCircle(0, 0,
@ -90,7 +100,8 @@ public class ColorPickerDialog extends Dialog {
} }
@Override @Override
protected void onMeasure(int widthMeasureSpec, int heightMeasureSpec) { protected void onMeasure(int widthMeasureSpec, int heightMeasureSpec)
{
setMeasuredDimension(CENTER_X*2, CENTER_Y*2); setMeasuredDimension(CENTER_X*2, CENTER_Y*2);
} }
@ -98,28 +109,37 @@ public class ColorPickerDialog extends Dialog {
private static final int CENTER_Y = 100; private static final int CENTER_Y = 100;
private static final int CENTER_RADIUS = 32; private static final int CENTER_RADIUS = 32;
private int floatToByte(float x) { private int floatToByte(float x)
{
int n = java.lang.Math.round(x); int n = java.lang.Math.round(x);
return n; return n;
} }
private int pinToByte(int n) { private int pinToByte(int n)
if (n < 0) { {
if (n < 0)
{
n = 0; n = 0;
} else if (n > 255) { }
else if (n > 255)
{
n = 255; n = 255;
} }
return n; return n;
} }
private int ave(int s, int d, float p) { private int ave(int s, int d, float p)
return s + java.lang.Math.round(p * (d - s)); {
return s + java.lang.Math.round(p *(d - s));
} }
private int interpColor(int colors[], float unit) { private int interpColor(int colors[], float unit)
if (unit <= 0) { {
if (unit <= 0)
{
return colors[0]; return colors[0];
} }
if (unit >= 1) { if (unit >= 1)
{
return colors[colors.length - 1]; return colors[colors.length - 1];
} }
@ -138,7 +158,8 @@ public class ColorPickerDialog extends Dialog {
return Color.argb(a, r, g, b); return Color.argb(a, r, g, b);
} }
private int rotateColor(int color, float rad) { private int rotateColor(int color, float rad)
{
float deg = rad * 180 / 3.1415927f; float deg = rad * 180 / 3.1415927f;
int r = Color.red(color); int r = Color.red(color);
int g = Color.green(color); int g = Color.green(color);
@ -166,30 +187,38 @@ public class ColorPickerDialog extends Dialog {
private static final float PI = 3.1415926f; private static final float PI = 3.1415926f;
@Override @Override
public boolean onTouchEvent(MotionEvent event) { public boolean onTouchEvent(MotionEvent event)
{
float x = event.getX() - CENTER_X; float x = event.getX() - CENTER_X;
float y = event.getY() - CENTER_Y; float y = event.getY() - CENTER_Y;
boolean inCenter = java.lang.Math.sqrt(x*x + y*y) <= CENTER_RADIUS; boolean inCenter = java.lang.Math.sqrt(x*x + y*y) <= CENTER_RADIUS;
switch (event.getAction()) { switch (event.getAction())
{
case MotionEvent.ACTION_DOWN: case MotionEvent.ACTION_DOWN:
mTrackingCenter = inCenter; mTrackingCenter = inCenter;
if (inCenter) { if (inCenter)
{
mHighlightCenter = true; mHighlightCenter = true;
invalidate(); invalidate();
break; break;
} }
case MotionEvent.ACTION_MOVE: case MotionEvent.ACTION_MOVE:
if (mTrackingCenter) { if (mTrackingCenter)
if (mHighlightCenter != inCenter) { {
if (mHighlightCenter != inCenter)
{
mHighlightCenter = inCenter; mHighlightCenter = inCenter;
invalidate(); invalidate();
} }
} else { }
else
{
float angle = (float)java.lang.Math.atan2(y, x); float angle = (float)java.lang.Math.atan2(y, x);
// need to turn angle [-PI ... PI] into unit [0....1] // need to turn angle [-PI ... PI] into unit [0....1]
float unit = angle/(2*PI); float unit = angle/(2*PI);
if (unit < 0) { if (unit < 0)
{
unit += 1; unit += 1;
} }
mCenterPaint.setColor(interpColor(mColors, unit)); mCenterPaint.setColor(interpColor(mColors, unit));
@ -197,8 +226,10 @@ public class ColorPickerDialog extends Dialog {
} }
break; break;
case MotionEvent.ACTION_UP: case MotionEvent.ACTION_UP:
if (mTrackingCenter) { if (mTrackingCenter)
if (inCenter) { {
if (inCenter)
{
mListener.colorChanged(mCenterPaint.getColor()); mListener.colorChanged(mCenterPaint.getColor());
} }
mTrackingCenter = false; // so we draw w/o halo mTrackingCenter = false; // so we draw w/o halo
@ -214,7 +245,8 @@ public class ColorPickerDialog extends Dialog {
public ColorPickerDialog(Context context, public ColorPickerDialog(Context context,
OnColorChangedListener listener, OnColorChangedListener listener,
int initialColor) { int initialColor)
{
super(context); super(context);
mListener = listener; mListener = listener;
@ -222,10 +254,13 @@ public class ColorPickerDialog extends Dialog {
} }
@Override @Override
protected void onCreate(Bundle savedInstanceState) { protected void onCreate(Bundle savedInstanceState)
{
super.onCreate(savedInstanceState); super.onCreate(savedInstanceState);
OnColorChangedListener l = new OnColorChangedListener() { OnColorChangedListener l = new OnColorChangedListener()
public void colorChanged(int color) { {
public void colorChanged(int color)
{
mListener.colorChanged(color); mListener.colorChanged(color);
dismiss(); dismiss();
} }

View File

@ -55,7 +55,7 @@ public abstract class EmailAddressAdapter extends ResourceCursorAdapter
try try
{ {
Class<? extends EmailAddressAdapter> clazz = Class<? extends EmailAddressAdapter> clazz =
Class.forName(className).asSubclass(EmailAddressAdapter.class); Class.forName(className).asSubclass(EmailAddressAdapter.class);
sInstance = clazz.newInstance(); sInstance = clazz.newInstance();
} }
catch (Exception e) catch (Exception e)

View File

@ -34,7 +34,8 @@ public class EmailAddressAdapterSdk5 extends EmailAddressAdapter
private static final String SORT_ORDER = Contacts.TIMES_CONTACTED private static final String SORT_ORDER = Contacts.TIMES_CONTACTED
+ " DESC, " + Contacts.DISPLAY_NAME; + " DESC, " + Contacts.DISPLAY_NAME;
private static final String[] PROJECTION = { private static final String[] PROJECTION =
{
Data._ID, // 0 Data._ID, // 0
Contacts.DISPLAY_NAME, // 1 Contacts.DISPLAY_NAME, // 1
Email.DATA // 2 Email.DATA // 2

View File

@ -325,12 +325,17 @@ public class FontSizes
{ {
switch (messageViewContent) switch (messageViewContent)
{ {
case SMALLEST: return 1; case SMALLEST:
case SMALLER: return 2; return 1;
case SMALLER:
return 2;
default: default:
case NORMAL: return 3; case NORMAL:
case LARGER: return 4; return 3;
case LARGEST: return 5; case LARGER:
return 4;
case LARGEST:
return 5;
} }
} }
@ -338,11 +343,21 @@ public class FontSizes
{ {
switch (size) switch (size)
{ {
case 1: messageViewContent = TextSize.SMALLEST; break; case 1:
case 2: messageViewContent = TextSize.SMALLER; break; messageViewContent = TextSize.SMALLEST;
case 3: messageViewContent = TextSize.NORMAL; break; break;
case 4: messageViewContent = TextSize.LARGER; break; case 2:
case 5: messageViewContent = TextSize.LARGEST; break; messageViewContent = TextSize.SMALLER;
break;
case 3:
messageViewContent = TextSize.NORMAL;
break;
case 4:
messageViewContent = TextSize.LARGER;
break;
case 5:
messageViewContent = TextSize.LARGEST;
break;
} }
} }
} }

View File

@ -497,12 +497,12 @@ public class K9 extends Application
catch (NoSuchMethodException e) catch (NoSuchMethodException e)
{ {
Log.i(K9.LOG_TAG, "Can't get method " + Log.i(K9.LOG_TAG, "Can't get method " +
classObject.toString() + "." + methodName); classObject.toString() + "." + methodName);
} }
catch (Exception e) catch (Exception e)
{ {
Log.e(K9.LOG_TAG, "Error while using reflection to get method " + Log.e(K9.LOG_TAG, "Error while using reflection to get method " +
classObject.toString() + "." + methodName, e); classObject.toString() + "." + methodName, e);
} }
return null; return null;
} }

View File

@ -702,7 +702,7 @@ public class MessagingController implements Runnable
public void searchLocalMessages(SearchSpecification searchSpecification, final Message[] messages, final MessagingListener listener) public void searchLocalMessages(SearchSpecification searchSpecification, final Message[] messages, final MessagingListener listener)
{ {
searchLocalMessages(searchSpecification.getAccountUuids(), searchSpecification.getFolderNames(), messages, searchLocalMessages(searchSpecification.getAccountUuids(), searchSpecification.getFolderNames(), messages,
searchSpecification.getQuery(), searchSpecification.isIntegrate(), searchSpecification.getRequiredFlags(), searchSpecification.getForbiddenFlags(), listener); searchSpecification.getQuery(), searchSpecification.isIntegrate(), searchSpecification.getRequiredFlags(), searchSpecification.getForbiddenFlags(), listener);
} }
@ -717,19 +717,19 @@ public class MessagingController implements Runnable
* @throws MessagingException * @throws MessagingException
*/ */
public void searchLocalMessages(final String[] accountUuids, final String[] folderNames, final Message[] messages, final String query, final boolean integrate, public void searchLocalMessages(final String[] accountUuids, final String[] folderNames, final Message[] messages, final String query, final boolean integrate,
final Flag[] requiredFlags, final Flag[] forbiddenFlags, final MessagingListener listener) final Flag[] requiredFlags, final Flag[] forbiddenFlags, final MessagingListener listener)
{ {
if (K9.DEBUG) if (K9.DEBUG)
{ {
Log.i(K9.LOG_TAG, "searchLocalMessages (" Log.i(K9.LOG_TAG, "searchLocalMessages ("
+ "accountUuids=" + Utility.combine(accountUuids, ',') + "accountUuids=" + Utility.combine(accountUuids, ',')
+ ", folderNames = " + Utility.combine(folderNames, ',') + ", folderNames = " + Utility.combine(folderNames, ',')
+ ", messages.size() = " + (messages != null ? messages.length : null) + ", messages.size() = " + (messages != null ? messages.length : null)
+ ", query = " + query + ", query = " + query
+ ", integrate = " + integrate + ", integrate = " + integrate
+ ", requiredFlags = " + Utility.combine(requiredFlags, ',') + ", requiredFlags = " + Utility.combine(requiredFlags, ',')
+ ", forbiddenFlags = " + Utility.combine(forbiddenFlags, ',') + ", forbiddenFlags = " + Utility.combine(forbiddenFlags, ',')
+ ")"); + ")");
} }
threadPool.execute(new Runnable() threadPool.execute(new Runnable()
@ -743,7 +743,7 @@ public class MessagingController implements Runnable
{ {
for (String accountUuid : accountUuids) for (String accountUuid : accountUuids)
{ {
accountUuidsSet.add(accountUuid); accountUuidsSet.add(accountUuid);
} }
} }
final Preferences prefs = Preferences.getPreferences(mApplication.getApplicationContext()); final Preferences prefs = Preferences.getPreferences(mApplication.getApplicationContext());
@ -818,11 +818,11 @@ public class MessagingController implements Runnable
} }
} }
else if (noSpecialFolders && ( else if (noSpecialFolders && (
localFolderName.equals(account.getTrashFolderName()) || localFolderName.equals(account.getTrashFolderName()) ||
localFolderName.equals(account.getOutboxFolderName()) || localFolderName.equals(account.getOutboxFolderName()) ||
localFolderName.equals(account.getDraftsFolderName()) || localFolderName.equals(account.getDraftsFolderName()) ||
localFolderName.equals(account.getSentFolderName()) || localFolderName.equals(account.getSentFolderName()) ||
localFolderName.equals(account.getErrorFolderName()))) localFolderName.equals(account.getErrorFolderName())))
{ {
include = false; include = false;
} }
@ -2723,7 +2723,7 @@ public class MessagingController implements Runnable
{ {
@Override @Override
public void act(final Account account, final Folder folder, public void act(final Account account, final Folder folder,
final List<Message> messages) final List<Message> messages)
{ {
String[] uids = new String[messages.size()]; String[] uids = new String[messages.size()];
for (int i = 0; i < messages.size(); i++) for (int i = 0; i < messages.size(); i++)
@ -2766,7 +2766,7 @@ public class MessagingController implements Runnable
Message msg = localFolder.getMessage(uid); Message msg = localFolder.getMessage(uid);
if (msg != null) if (msg != null)
{ {
messages.add(msg); messages.add(msg);
} }
} }
@ -3465,7 +3465,7 @@ public class MessagingController implements Runnable
} }
public void getAccountStats(final Context context, final Account account, public void getAccountStats(final Context context, final Account account,
final MessagingListener l) final MessagingListener l)
{ {
Runnable unreadRunnable = new Runnable() Runnable unreadRunnable = new Runnable()
{ {
@ -3562,7 +3562,7 @@ public class MessagingController implements Runnable
} }
} }
public void moveMessages(final Account account, final String srcFolder, final Message[] messages, final String destFolder, public void moveMessages(final Account account, final String srcFolder, final Message[] messages, final String destFolder,
final MessagingListener listener) final MessagingListener listener)
{ {
for (Message message : messages) for (Message message : messages)
{ {
@ -3578,13 +3578,13 @@ public class MessagingController implements Runnable
} }
public void moveMessage(final Account account, final String srcFolder, final Message message, final String destFolder, public void moveMessage(final Account account, final String srcFolder, final Message message, final String destFolder,
final MessagingListener listener) final MessagingListener listener)
{ {
moveMessages(account, srcFolder, new Message[] { message }, destFolder, listener); moveMessages(account, srcFolder, new Message[] { message }, destFolder, listener);
} }
public void copyMessages(final Account account, final String srcFolder, final Message[] messages, final String destFolder, public void copyMessages(final Account account, final String srcFolder, final Message[] messages, final String destFolder,
final MessagingListener listener) final MessagingListener listener)
{ {
putBackground("copyMessages", null, new Runnable() putBackground("copyMessages", null, new Runnable()
{ {
@ -3595,7 +3595,7 @@ public class MessagingController implements Runnable
}); });
} }
public void copyMessage(final Account account, final String srcFolder, final Message message, final String destFolder, public void copyMessage(final Account account, final String srcFolder, final Message message, final String destFolder,
final MessagingListener listener) final MessagingListener listener)
{ {
copyMessages(account, srcFolder, new Message[] { message }, destFolder, listener); copyMessages(account, srcFolder, new Message[] { message }, destFolder, listener);
} }
@ -3722,7 +3722,7 @@ public class MessagingController implements Runnable
@Override @Override
public void act(final Account account, final Folder folder, public void act(final Account account, final Folder folder,
final List<Message> messages) final List<Message> messages)
{ {
for (Message message : messages) for (Message message : messages)
{ {
@ -4234,11 +4234,11 @@ public class MessagingController implements Runnable
public void run() public void run()
{ {
if (K9.DEBUG) if (K9.DEBUG)
Log.v(K9.LOG_TAG, "Clearing notification flag for " + account.getDescription()); Log.v(K9.LOG_TAG, "Clearing notification flag for " + account.getDescription());
account.setRingNotified(false); account.setRingNotified(false);
} }
} }
); );
} }

View File

@ -84,13 +84,13 @@ public class MessagingControllerPushReceiver implements PushReceiver
controller.synchronizeMailbox(account, folder.getName(), new MessagingListener() controller.synchronizeMailbox(account, folder.getName(), new MessagingListener()
{ {
public void synchronizeMailboxFinished(Account account, String folder, public void synchronizeMailboxFinished(Account account, String folder,
int totalMessagesInMailbox, int numNewMessages) int totalMessagesInMailbox, int numNewMessages)
{ {
latch.countDown(); latch.countDown();
} }
public void synchronizeMailboxFailed(Account account, String folder, public void synchronizeMailboxFailed(Account account, String folder,
String message) String message)
{ {
latch.countDown(); latch.countDown();
} }

View File

@ -308,7 +308,7 @@ public class Accounts extends K9ListActivity implements OnItemClickListener, OnC
@Override @Override
public void onCreate(Bundle icicle) public void onCreate(Bundle icicle)
{ {
unreadAccount = new SearchAccount(this, false, null, null ); unreadAccount = new SearchAccount(this, false, null, null);
unreadAccount.setDescription(getString(R.string.search_all_messages_title)); unreadAccount.setDescription(getString(R.string.search_all_messages_title));
unreadAccount.setEmail(getString(R.string.search_all_messages_detail)); unreadAccount.setEmail(getString(R.string.search_all_messages_detail));
@ -843,7 +843,7 @@ public class Accounts extends K9ListActivity implements OnItemClickListener, OnC
toast.show(); toast.show();
} }
} }
); );
} }
else else
@ -918,7 +918,7 @@ public class Accounts extends K9ListActivity implements OnItemClickListener, OnC
final BaseAccount account; final BaseAccount account;
final SearchModifier searchModifier; final SearchModifier searchModifier;
AccountClickListener(BaseAccount nAccount, SearchModifier nSearchModifier ) AccountClickListener(BaseAccount nAccount, SearchModifier nSearchModifier)
{ {
account = nAccount; account = nAccount;
searchModifier = nSearchModifier; searchModifier = nSearchModifier;
@ -932,9 +932,9 @@ public class Accounts extends K9ListActivity implements OnItemClickListener, OnC
SearchAccount searchAccount = (SearchAccount)account; SearchAccount searchAccount = (SearchAccount)account;
MessageList.actionHandle(Accounts.this, MessageList.actionHandle(Accounts.this,
description, "", searchAccount.isIntegrate(), description, "", searchAccount.isIntegrate(),
combine(searchAccount.getRequiredFlags(), searchModifier.requiredFlags), combine(searchAccount.getRequiredFlags(), searchModifier.requiredFlags),
combine(searchAccount.getForbiddenFlags(), searchModifier.forbiddenFlags)); combine(searchAccount.getForbiddenFlags(), searchModifier.forbiddenFlags));
} }
else else
{ {

View File

@ -74,7 +74,8 @@ public class EditIdentity extends K9Activity
mSignatureUse = (CheckBox)findViewById(R.id.signature_use); mSignatureUse = (CheckBox)findViewById(R.id.signature_use);
mSignatureView = (EditText)findViewById(R.id.signature); mSignatureView = (EditText)findViewById(R.id.signature);
mSignatureUse.setChecked(mIdentity.getSignatureUse()); mSignatureUse.setChecked(mIdentity.getSignatureUse());
mSignatureUse.setOnCheckedChangeListener(new CompoundButton.OnCheckedChangeListener() { mSignatureUse.setOnCheckedChangeListener(new CompoundButton.OnCheckedChangeListener()
{
public void onCheckedChanged(CompoundButton buttonView, boolean isChecked) public void onCheckedChanged(CompoundButton buttonView, boolean isChecked)
{ {
if (isChecked) if (isChecked)

View File

@ -79,7 +79,7 @@ public class FolderList extends K9ListActivity
public void run() public void run()
{ {
String dispString = mAdapter.mListener.formatHeader(FolderList.this, String dispString = mAdapter.mListener.formatHeader(FolderList.this,
getString(R.string.folder_list_title, mAccount.getDescription()), mUnreadMessageCount, getTimeFormat()); getString(R.string.folder_list_title, mAccount.getDescription()), mUnreadMessageCount, getTimeFormat());
setTitle(dispString); setTitle(dispString);
@ -1253,7 +1253,7 @@ public class FolderList extends K9ListActivity
if (K9.messageListStars() && folder.flaggedMessageCount > 0) if (K9.messageListStars() && folder.flaggedMessageCount > 0)
{ {
holder.flaggedMessageCount.setText(Integer holder.flaggedMessageCount.setText(Integer
.toString(folder.flaggedMessageCount)); .toString(folder.flaggedMessageCount));
holder.flaggedMessageCount.setOnClickListener(new FolderClickListener(mAccount, folder.name, folder.displayName, SearchModifier.FLAGGED)); holder.flaggedMessageCount.setOnClickListener(new FolderClickListener(mAccount, folder.name, folder.displayName, SearchModifier.FLAGGED));
holder.flaggedMessageCount.setVisibility(View.VISIBLE); holder.flaggedMessageCount.setVisibility(View.VISIBLE);
} }
@ -1269,7 +1269,7 @@ public class FolderList extends K9ListActivity
toast.show(); toast.show();
} }
} }
); );
holder.chip.setBackgroundColor(mAccount.getChipColor()); holder.chip.setBackgroundColor(mAccount.getChipColor());
holder.chip.getBackground().setAlpha(folder.unreadMessageCount == 0 ? 127 : 255); holder.chip.getBackground().setAlpha(folder.unreadMessageCount == 0 ? 127 : 255);
@ -1364,7 +1364,7 @@ public class FolderList extends K9ListActivity
try try
{ {
folder.open(Folder.OpenMode.READ_WRITE); folder.open(Folder.OpenMode.READ_WRITE);
// unreadCount = folder.getUnreadMessageCount(); // unreadCount = folder.getUnreadMessageCount();
} }
catch (MessagingException me) catch (MessagingException me)
{ {
@ -1446,7 +1446,7 @@ public class FolderList extends K9ListActivity
final String folderName; final String folderName;
final String displayName; final String displayName;
final SearchModifier searchModifier; final SearchModifier searchModifier;
FolderClickListener(BaseAccount nAccount, String folderName, String displayName, SearchModifier nSearchModifier ) FolderClickListener(BaseAccount nAccount, String folderName, String displayName, SearchModifier nSearchModifier)
{ {
account = nAccount; account = nAccount;
this.folderName = folderName; this.folderName = folderName;
@ -1457,8 +1457,8 @@ public class FolderList extends K9ListActivity
public void onClick(View v) public void onClick(View v)
{ {
String description = getString(R.string.search_title, String description = getString(R.string.search_title,
getString(R.string.message_list_title, account.getDescription(), displayName), getString(R.string.message_list_title, account.getDescription(), displayName),
getString(searchModifier.resId)); getString(searchModifier.resId));
SearchSpecification searchSpec = new SearchSpecification() SearchSpecification searchSpec = new SearchSpecification()
{ {

View File

@ -980,11 +980,13 @@ public class MessageCompose extends K9Activity implements OnClickListener, OnFoc
File f = new File(uriString.substring("file://".length())); File f = new File(uriString.substring("file://".length()));
attachment.size = f.length(); attachment.size = f.length();
} }
else { else
{
Log.v(K9.LOG_TAG, "Not a file: " + uriString); Log.v(K9.LOG_TAG, "Not a file: " + uriString);
} }
} }
else { else
{
Log.v(K9.LOG_TAG, "old attachment.size: " + attachment.size); Log.v(K9.LOG_TAG, "old attachment.size: " + attachment.size);
} }
Log.v(K9.LOG_TAG, "new attachment.size: " + attachment.size); Log.v(K9.LOG_TAG, "new attachment.size: " + attachment.size);
@ -1591,7 +1593,7 @@ public class MessageCompose extends K9Activity implements OnClickListener, OnFoc
} }
private String decode(String s) private String decode(String s)
throws UnsupportedEncodingException throws UnsupportedEncodingException
{ {
return URLDecoder.decode(s, "UTF-8"); return URLDecoder.decode(s, "UTF-8");
} }
@ -1602,7 +1604,8 @@ public class MessageCompose extends K9Activity implements OnClickListener, OnFoc
* *
* @mailToString the href (which must start with "mailto:"). * @mailToString the href (which must start with "mailto:").
*/ */
private void initializeFromMailTo(String mailToString) { private void initializeFromMailTo(String mailToString)
{
// Chop up everything between mailto: and ? to find recipients // Chop up everything between mailto: and ? to find recipients
int index = mailToString.indexOf("?"); int index = mailToString.indexOf("?");

View File

@ -67,7 +67,7 @@ public class MessageList
private static final String EXTRA_QUERY_FLAGS = "queryFlags"; private static final String EXTRA_QUERY_FLAGS = "queryFlags";
private static final String EXTRA_FORBIDDEN_FLAGS = "forbiddenFlags"; private static final String EXTRA_FORBIDDEN_FLAGS = "forbiddenFlags";
private static final String EXTRA_INTEGRATE = "integrate"; private static final String EXTRA_INTEGRATE = "integrate";
private static final String EXTRA_ACCOUNT_UUIDS = "accountUuids"; private static final String EXTRA_ACCOUNT_UUIDS = "accountUuids";
private static final String EXTRA_FOLDER_NAMES = "folderNames"; private static final String EXTRA_FOLDER_NAMES = "folderNames";
private static final String EXTRA_TITLE = "title"; private static final String EXTRA_TITLE = "title";
@ -498,7 +498,7 @@ public class MessageList
} }
private void initializeLayout () private void initializeLayout()
{ {
requestWindowFeature(Window.FEATURE_INDETERMINATE_PROGRESS); requestWindowFeature(Window.FEATURE_INDETERMINATE_PROGRESS);
requestWindowFeature(Window.FEATURE_PROGRESS); requestWindowFeature(Window.FEATURE_PROGRESS);

View File

@ -26,9 +26,9 @@ public class MessageReference implements Serializable
public String toString() public String toString()
{ {
return "MessageReference{accountUuid = '" + return "MessageReference{accountUuid = '" +
accountUuid accountUuid
+ "', folderName = '" + folderName + "', folderName = '" + folderName
+ "', uid = '" + uid + "', uid = '" + uid
+ "'}"; + "'}";
} }
} }

View File

@ -279,7 +279,7 @@ public class MessageView extends K9Activity implements OnClickListener
mTimeView.setText(time); mTimeView.setText(time);
mToView.setText(to); mToView.setText(to);
mCcContainerView.setVisibility((cc != null && cc.length() > 0 )? View.VISIBLE : View.GONE); mCcContainerView.setVisibility((cc != null && cc.length() > 0)? View.VISIBLE : View.GONE);
mCcView.setText(cc); mCcView.setText(cc);
mAttachmentIcon.setVisibility(hasAttachments ? View.VISIBLE : View.GONE); mAttachmentIcon.setVisibility(hasAttachments ? View.VISIBLE : View.GONE);
@ -1355,7 +1355,7 @@ public class MessageView extends K9Activity implements OnClickListener
MessageView.this.mMessage = message; MessageView.this.mMessage = message;
if (!message.isSet(Flag.X_DOWNLOADED_FULL) if (!message.isSet(Flag.X_DOWNLOADED_FULL)
&& !message.isSet(Flag.X_DOWNLOADED_PARTIAL)) && !message.isSet(Flag.X_DOWNLOADED_PARTIAL))
{ {
mHandler.post(new Runnable() mHandler.post(new Runnable()
{ {
@ -1388,8 +1388,8 @@ public class MessageView extends K9Activity implements OnClickListener
try try
{ {
if (MessageView.this.mMessage!=null if (MessageView.this.mMessage!=null
&& MessageView.this.mMessage.isSet(Flag.X_DOWNLOADED_PARTIAL) && MessageView.this.mMessage.isSet(Flag.X_DOWNLOADED_PARTIAL)
&& message.isSet(Flag.X_DOWNLOADED_FULL)) && message.isSet(Flag.X_DOWNLOADED_FULL))
{ {
setHeaders(account, folder, uid, message); setHeaders(account, folder, uid, message);

View File

@ -8,7 +8,7 @@ import com.fsck.k9.mail.Flag;
enum SearchModifier enum SearchModifier
{ {
FLAGGED(R.string.flagged_modifier, new Flag[] { Flag.FLAGGED}, null), UNREAD(R.string.unread_modifier, null, new Flag[] { Flag.SEEN} ); FLAGGED(R.string.flagged_modifier, new Flag[] { Flag.FLAGGED}, null), UNREAD(R.string.unread_modifier, null, new Flag[] { Flag.SEEN});
final int resId; final int resId;
final Flag[] requiredFlags; final Flag[] requiredFlags;

View File

@ -325,7 +325,8 @@ public class AccountSettings extends K9PreferenceActivity
mAutoExpandFolder.setSummary(translateFolder(mAccount.getAutoExpandFolderName())); mAutoExpandFolder.setSummary(translateFolder(mAccount.getAutoExpandFolderName()));
mAutoExpandFolder.setOnPreferenceClickListener( mAutoExpandFolder.setOnPreferenceClickListener(
new Preference.OnPreferenceClickListener() { new Preference.OnPreferenceClickListener()
{
public boolean onPreferenceClick(Preference preference) public boolean onPreferenceClick(Preference preference)
{ {
onChooseAutoExpandFolder(); onChooseAutoExpandFolder();
@ -338,13 +339,14 @@ public class AccountSettings extends K9PreferenceActivity
mChipColor = (Preference)findPreference(PREFERENCE_CHIP_COLOR); mChipColor = (Preference)findPreference(PREFERENCE_CHIP_COLOR);
mChipColor.setOnPreferenceClickListener( mChipColor.setOnPreferenceClickListener(
new Preference.OnPreferenceClickListener() { new Preference.OnPreferenceClickListener()
{
public boolean onPreferenceClick(Preference preference) public boolean onPreferenceClick(Preference preference)
{ {
onChooseChipColor(); onChooseChipColor();
return false; return false;
} }
} }
); );
@ -509,9 +511,14 @@ public class AccountSettings extends K9PreferenceActivity
public void onChooseChipColor() public void onChooseChipColor()
{ {
new ColorPickerDialog(this, new ColorPickerDialog.OnColorChangedListener () { new ColorPickerDialog(this, new ColorPickerDialog.OnColorChangedListener()
public void colorChanged (int color) { mAccount.setChipColor(color); } }, {
mAccount.getChipColor()).show(); public void colorChanged(int color)
{
mAccount.setChipColor(color);
}
},
mAccount.getChipColor()).show();
} }
public void onChooseAutoExpandFolder() public void onChooseAutoExpandFolder()

View File

@ -69,25 +69,26 @@ public class AccountSetupComposition extends K9Activity
mAccountAlwaysBcc = (EditText)findViewById(R.id.account_always_bcc); mAccountAlwaysBcc = (EditText)findViewById(R.id.account_always_bcc);
mAccountAlwaysBcc.setText(mAccount.getAlwaysBcc()); mAccountAlwaysBcc.setText(mAccount.getAlwaysBcc());
mAccountSignatureLayout = (LinearLayout)findViewById(R.id.account_signature_layout); mAccountSignatureLayout = (LinearLayout)findViewById(R.id.account_signature_layout);
mAccountSignatureUse = (CheckBox)findViewById(R.id.account_signature_use); mAccountSignatureUse = (CheckBox)findViewById(R.id.account_signature_use);
boolean useSignature = mAccount.getSignatureUse(); boolean useSignature = mAccount.getSignatureUse();
mAccountSignatureUse.setChecked(useSignature); mAccountSignatureUse.setChecked(useSignature);
mAccountSignatureUse.setOnCheckedChangeListener(new CompoundButton.OnCheckedChangeListener() { mAccountSignatureUse.setOnCheckedChangeListener(new CompoundButton.OnCheckedChangeListener()
{
public void onCheckedChanged(CompoundButton buttonView, boolean isChecked) public void onCheckedChanged(CompoundButton buttonView, boolean isChecked)
{ {
if (isChecked) if (isChecked)
{ {
mAccountSignatureLayout.setVisibility(View.VISIBLE); mAccountSignatureLayout.setVisibility(View.VISIBLE);
mAccountSignature.setText(mAccount.getSignature()); mAccountSignature.setText(mAccount.getSignature());
boolean isSignatureBeforeQuotedText = mAccount.isSignatureBeforeQuotedText(); boolean isSignatureBeforeQuotedText = mAccount.isSignatureBeforeQuotedText();
mAccountSignatureBeforeLocation.setChecked(isSignatureBeforeQuotedText); mAccountSignatureBeforeLocation.setChecked(isSignatureBeforeQuotedText);
mAccountSignatureAfterLocation.setChecked(!isSignatureBeforeQuotedText); mAccountSignatureAfterLocation.setChecked(!isSignatureBeforeQuotedText);
} }
else else
{ {
mAccountSignatureLayout.setVisibility(View.GONE); mAccountSignatureLayout.setVisibility(View.GONE);
} }
} }
}); });
@ -107,7 +108,7 @@ public class AccountSetupComposition extends K9Activity
} }
else else
{ {
mAccountSignatureLayout.setVisibility(View.GONE); mAccountSignatureLayout.setVisibility(View.GONE);
} }
} }
@ -126,9 +127,9 @@ public class AccountSetupComposition extends K9Activity
mAccount.setSignatureUse(mAccountSignatureUse.isChecked()); mAccount.setSignatureUse(mAccountSignatureUse.isChecked());
if (mAccountSignatureUse.isChecked()) if (mAccountSignatureUse.isChecked())
{ {
mAccount.setSignature(mAccountSignature.getText().toString()); mAccount.setSignature(mAccountSignature.getText().toString());
boolean isSignatureBeforeQuotedText = mAccountSignatureBeforeLocation.isChecked(); boolean isSignatureBeforeQuotedText = mAccountSignatureBeforeLocation.isChecked();
mAccount.setSignatureBeforeQuotedText(isSignatureBeforeQuotedText); mAccount.setSignatureBeforeQuotedText(isSignatureBeforeQuotedText);
} }
mAccount.save(Preferences.getPreferences(this)); mAccount.save(Preferences.getPreferences(this));

View File

@ -82,13 +82,13 @@ public class Prefs extends K9PreferenceActivity
findPreference(PREFERENCE_FONT_SIZE).setOnPreferenceClickListener( findPreference(PREFERENCE_FONT_SIZE).setOnPreferenceClickListener(
new Preference.OnPreferenceClickListener() new Preference.OnPreferenceClickListener()
{
public boolean onPreferenceClick(Preference preference)
{ {
public boolean onPreferenceClick(Preference preference) onFontSizeSettings();
{ return true;
onFontSizeSettings(); }
return true; });
}
});
mDateFormat = (ListPreference) findPreference(PREFERENCE_DATE_FORMAT); mDateFormat = (ListPreference) findPreference(PREFERENCE_DATE_FORMAT);
String[] formats = DateFormatter.getFormats(this); String[] formats = DateFormatter.getFormats(this);

View File

@ -59,24 +59,24 @@ public abstract class Multipart implements Body
this.mParent = parent; this.mParent = parent;
} }
public void setEncoding(String encoding) public void setEncoding(String encoding)
{ {
for (BodyPart part : mParts) for (BodyPart part : mParts)
{ {
try try
{ {
Body body = part.getBody(); Body body = part.getBody();
if (body instanceof TextBody) if (body instanceof TextBody)
{ {
part.setHeader(MimeHeader.HEADER_CONTENT_TRANSFER_ENCODING, encoding); part.setHeader(MimeHeader.HEADER_CONTENT_TRANSFER_ENCODING, encoding);
((TextBody)body).setEncoding(encoding); ((TextBody)body).setEncoding(encoding);
} }
} }
catch (MessagingException e) catch (MessagingException e)
{ {
// Ignore // Ignore
} }
} }
} }
} }

View File

@ -457,11 +457,11 @@ public class MimeMessage extends Message
@Override @Override
public void setEncoding(String encoding) public void setEncoding(String encoding)
{ {
if (mBody instanceof Multipart) if (mBody instanceof Multipart)
{ {
((Multipart)mBody).setEncoding(encoding); ((Multipart)mBody).setEncoding(encoding);
} }
else if (mBody instanceof TextBody) else if (mBody instanceof TextBody)
{ {
setHeader(MimeHeader.HEADER_CONTENT_TRANSFER_ENCODING, encoding); setHeader(MimeHeader.HEADER_CONTENT_TRANSFER_ENCODING, encoding);
((TextBody)mBody).setEncoding(encoding); ((TextBody)mBody).setEncoding(encoding);

View File

@ -71,6 +71,6 @@ public class TextBody implements Body
public void setEncoding(String encoding) public void setEncoding(String encoding)
{ {
mEncoding = encoding; mEncoding = encoding;
} }
} }

View File

@ -1274,7 +1274,7 @@ public class ImapStore extends Store
if (part != null) if (part != null)
{ {
String contentTransferEncoding = part.getHeader( String contentTransferEncoding = part.getHeader(
MimeHeader.HEADER_CONTENT_TRANSFER_ENCODING)[0]; MimeHeader.HEADER_CONTENT_TRANSFER_ENCODING)[0];
part.setBody(MimeUtility.decodeBody(bodyStream, contentTransferEncoding)); part.setBody(MimeUtility.decodeBody(bodyStream, contentTransferEncoding));
} }
else else
@ -2685,7 +2685,7 @@ public class ImapStore extends Store
newUidNext = highestUid + 1; newUidNext = highestUid + 1;
if (K9.DEBUG) if (K9.DEBUG)
Log.i(K9.LOG_TAG, "highest UID = " + highestUid Log.i(K9.LOG_TAG, "highest UID = " + highestUid
+ ", set newUidNext to " + newUidNext); + ", set newUidNext to " + newUidNext);
} }
} }

View File

@ -631,7 +631,7 @@ public class LocalStore extends Store implements Serializable
} }
public Message[] searchForMessages(MessageRetrievalListener listener, String queryString, public Message[] searchForMessages(MessageRetrievalListener listener, String queryString,
List<LocalFolder> folders, Message[] messages, final Flag[] requiredFlags, final Flag[] forbiddenFlags) throws MessagingException List<LocalFolder> folders, Message[] messages, final Flag[] requiredFlags, final Flag[] forbiddenFlags) throws MessagingException
{ {
List<String> args = new LinkedList<String>(); List<String> args = new LinkedList<String>();
@ -1222,7 +1222,7 @@ public class LocalStore extends Store implements Serializable
{ {
String id = getPrefId(); String id = getPrefId();
return FolderClass.valueOf(preferences.getPreferences().getString(id + ".displayMode", return FolderClass.valueOf(preferences.getPreferences().getString(id + ".displayMode",
FolderClass.NO_CLASS.name())); FolderClass.NO_CLASS.name()));
} }
@Override @Override

View File

@ -1628,7 +1628,7 @@ public class WebDavStore extends Store
statusCode > 300) statusCode > 300)
{ {
throw new IOException("Error during with code " + statusCode + " during fetch: " throw new IOException("Error during with code " + statusCode + " during fetch: "
+ response.getStatusLine().toString()); + response.getStatusLine().toString());
} }
if (entity != null) if (entity != null)
@ -1985,7 +1985,7 @@ public class WebDavStore extends Store
} }
open(OpenMode.READ_WRITE); open(OpenMode.READ_WRITE);
EOLConvertingOutputStream msgOut = new EOLConvertingOutputStream( EOLConvertingOutputStream msgOut = new EOLConvertingOutputStream(
new BufferedOutputStream(out, 1024)); new BufferedOutputStream(out, 1024));
message.writeTo(msgOut); message.writeTo(msgOut);
msgOut.flush(); msgOut.flush();
@ -2019,8 +2019,8 @@ public class WebDavStore extends Store
statusCode > 300) statusCode > 300)
{ {
throw new IOException("Error with status code " + statusCode throw new IOException("Error with status code " + statusCode
+ " while sending/appending message. Response = " + " while sending/appending message. Response = "
+ response.getStatusLine().toString() + " for message " + messageURL); + response.getStatusLine().toString() + " for message " + messageURL);
} }
WebDavMessage retMessage = new WebDavMessage(message.getUid(), this); WebDavMessage retMessage = new WebDavMessage(message.getUid(), this);

View File

@ -300,7 +300,7 @@ public class SmtpTransport extends Transport
boolean possibleSend = false; boolean possibleSend = false;
try try
{ {
//TODO: Add BODY=8BITMIME parameter if appropriate? //TODO: Add BODY=8BITMIME parameter if appropriate?
executeSimpleCommand("MAIL FROM: " + "<" + from[0].getAddress() + ">"); executeSimpleCommand("MAIL FROM: " + "<" + from[0].getAddress() + ">");
for (Address address : message.getRecipients(RecipientType.TO)) for (Address address : message.getRecipients(RecipientType.TO))
{ {
@ -318,10 +318,10 @@ public class SmtpTransport extends Transport
executeSimpleCommand("DATA"); executeSimpleCommand("DATA");
EOLConvertingOutputStream msgOut = new EOLConvertingOutputStream( EOLConvertingOutputStream msgOut = new EOLConvertingOutputStream(
new SmtpDataStuffing( new SmtpDataStuffing(
new LineWrapOutputStream( new LineWrapOutputStream(
new BufferedOutputStream(mOut, 1024), new BufferedOutputStream(mOut, 1024),
1000))); 1000)));
message.writeTo(msgOut); message.writeTo(msgOut);

View File

@ -421,13 +421,13 @@ public class Storage implements SharedPreferences
try try
{ {
cursor = mDb.query( cursor = mDb.query(
"preferences_storage", "preferences_storage",
new String[] {"value"}, new String[] {"value"},
"primkey = ?", "primkey = ?",
new String[] {key}, new String[] {key},
null, null,
null, null,
null); null);
if (cursor.moveToNext()) if (cursor.moveToNext())
{ {

View File

@ -157,7 +157,7 @@ public class AttachmentProvider extends ContentProvider
} }
private File getFile(String dbName, String id) private File getFile(String dbName, String id)
throws FileNotFoundException throws FileNotFoundException
{ {
try try
{ {
@ -166,7 +166,8 @@ public class AttachmentProvider extends ContentProvider
if (!file.exists()) if (!file.exists())
{ {
file = new File("/sdcard" + attachmentsDir.getCanonicalPath().substring("/data".length()), id); file = new File("/sdcard" + attachmentsDir.getCanonicalPath().substring("/data".length()), id);
if (!file.exists()) { if (!file.exists())
{
throw new FileNotFoundException(); throw new FileNotFoundException();
} }
} }

View File

@ -137,7 +137,7 @@ public abstract class CoreService extends Service
if (threadPool == null) if (threadPool == null)
{ {
Log.e(K9.LOG_TAG, "CoreService.execute (" + className + ") called with no threadPool available; running Runnable " + runner.hashCode() + " in calling thread", new Throwable()); Log.e(K9.LOG_TAG, "CoreService.execute (" + className + ") called with no threadPool available; running Runnable " + runner.hashCode() + " in calling thread", new Throwable());
synchronized(this) synchronized (this)
{ {
myRunner.run(); myRunner.run();
} }

View File

@ -192,7 +192,7 @@ public class MailService extends CoreService
startIdObj = null; startIdObj = null;
} }
} }
else if (CONNECTIVITY_CHANGE.equals(intent.getAction()) ) else if (CONNECTIVITY_CHANGE.equals(intent.getAction()))
{ {
notifyConnectionStatus(hasConnectivity); notifyConnectionStatus(hasConnectivity);
rescheduleAll(hasConnectivity, doBackground, startIdObj); rescheduleAll(hasConnectivity, doBackground, startIdObj);
@ -328,10 +328,10 @@ public class MailService extends CoreService
long nextTime = base + delay; long nextTime = base + delay;
if (K9.DEBUG) if (K9.DEBUG)
Log.i(K9.LOG_TAG, Log.i(K9.LOG_TAG,
"previousInterval = " + previousInterval "previousInterval = " + previousInterval
+ ", shortestInterval = " + shortestInterval + ", shortestInterval = " + shortestInterval
+ ", lastCheckEnd = " + new Date(lastCheckEnd) + ", lastCheckEnd = " + new Date(lastCheckEnd)
+ ", considerLastCheckEnd = " + considerLastCheckEnd); + ", considerLastCheckEnd = " + considerLastCheckEnd);
nextCheck = nextTime; nextCheck = nextTime;
try try
{ {