// Path: RetroWatch_Android/RetroWatchLE/src/com/hardcopy/retrowatchle/contents/objects/ContentObject.java
// public class ContentObject {
// 	
// 	public static final int CONTENT_TYPE_NOTIFICATION = 1;
// 	public static final int CONTENT_TYPE_MESSAGING = 2;
// 	public static final int CONTENT_TYPE_EMERGENCY = 3;
// 	public static final int CONTENT_TYPE_FEED = 4;
// 	
// 	public static final int MESSAGING_ID_GMAIL = 1;
// 	public static final int MESSAGING_ID_SMS = 2;
// 	
// 	public static final int EMERGENCY_ID_WIFI = 1;
// 	public static final int EMERGENCY_ID_CALL_STATE = 2;
// 	public static final int EMERGENCY_ID_BATT_STATE = 3;
// 	public static final int EMERGENCY_ID_RF_STATE = 4;
// 	
// 	public static final int ICON_TYPE_NORMAL_MESSAGE = 0;
// 	public static final int ICON_TYPE_EMAIL = 28;
// 	public static final int ICON_TYPE_CALL = 10;
// 	public static final int ICON_TYPE_EMERGENCY = 60;
// 	public static final int ICON_TYPE_BATT_FULL = 4;
// 	public static final int ICON_TYPE_BATT_MEDIUM = 5;
// 	public static final int ICON_TYPE_BATT_LOW = 6;
// 	public static final int ICON_TYPE_RF_STATE = 64;
// 	public static final int ICON_TYPE_RSS = 46;
// 	
// 	public static final String SMS_PACKAGE_NAME = "android.telephony.sms";
// 	public static final String GMAIL_PACKAGE_NAME = "com.google.android.gm";
// 	public static final String TELEPHONY_CALL_PACKAGE_NAME = "android.telephony.call";
// 	public static final String TELEPHONY_RF_PACKAGE_NAME = "android.telephony.rfstatus";
// 	public static final String FEED_PACKAGE_NAME = "com.hardcopy.feed";
// 	public static final String WIFI_PACKAGE_NAME = "android.net.wifi";
// 	public static final String BATT_PACKAGE_NAME = "android.os.battery";
// 	
// 	public int mContentType;			// Content type
// 	public int mIconType;				// Icon type
// 	public int mId;						// ID
// 	public boolean mIsEnabled = false;	// Watch shows enabled items only
// 	public String mOriginalString;		// Original string
// 	public String mFilteredString;		// String to be shown on remote device
// 	public String mExtraData = null;	// Extra data defined by each content type
// 	public String mPackageName = null;
// 	
// 	
// 	public ContentObject(int type, int id, String strOrigin, String strFiltered) {
// 		mContentType = type;
// 		mIconType = -1;
// 		mId = id;
// 		mOriginalString = strOrigin;
// 		mFilteredString = strFiltered;
// 	}
// 	
// }
// 
// Path: RetroWatch_Android/RetroWatchLE/src/com/hardcopy/retrowatchle/utils/Logs.java
// public class Logs {
// 	
// 	private static final String TAG = "RetroWatch";
// 	public static boolean mIsEnabled = true;
// 	
// 	
// 	public static void v(String msg) {
// 		if(mIsEnabled) {
// 			Log.v(TAG, msg);
// 		}
// 	}
// 	
// 	public static void v(String tag, String msg) {
// 		if(mIsEnabled) {
// 			Log.v(tag, msg);
// 		}
// 	}
// 	
// 	public static void d(String msg) {
// 		if(mIsEnabled) {
// 			Log.d(TAG, msg);
// 		}
// 	}
// 	
// 	public static void d(String tag, String msg) {
// 		if(mIsEnabled) {
// 			Log.d(tag, msg);
// 		}
// 	}
// 	
// 	public static void e(String msg) {
// 		if(mIsEnabled) {
// 			Log.e(TAG, msg);
// 		}
// 	}
// 	
// 	public static void e(String tag, String msg) {
// 		if(mIsEnabled) {
// 			Log.e(tag, msg);
// 		}
// 	}
// 	
// 	public static void i(String msg) {
// 		if(mIsEnabled) {
// 			Log.e(TAG, msg);
// 		}
// 	}
// 	
// 	public static void i(String tag, String msg) {
// 		if(mIsEnabled) {
// 			Log.e(tag, msg);
// 		}
// 	}
// 	
// }


import java.util.ArrayList;
import com.hardcopy.retrowatchle.contents.objects.ContentObject;
import com.hardcopy.retrowatchle.utils.Logs;
import android.content.Context;
import android.os.Bundle;
import android.support.v4.app.Fragment;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.ListView;
/*
 * Copyright (C) 2014 The Retro Watch - Open source smart watch project
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *      http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */

package com.hardcopy.retrowatchle;




/**
 * This fragment shows messages to be sent to watch.
 */
public class MessageListFragment extends Fragment implements IAdapterListener {

	private static final String TAG = "MessageListFragment";
	
	private Context mContext = null;
	private IFragmentListener mFragmentListener;
	
	private ListView mListMessage = null;
	private MessageListAdapter mMessageListAdapter = null;
	
	public MessageListFragment(Context c, IFragmentListener l) {
		mContext = c;
// Path: RetroWatch_Android/RetroWatchLE/src/com/hardcopy/retrowatchle/contents/objects/ContentObject.java
// public class ContentObject {
// 	
// 	public static final int CONTENT_TYPE_NOTIFICATION = 1;
// 	public static final int CONTENT_TYPE_MESSAGING = 2;
// 	public static final int CONTENT_TYPE_EMERGENCY = 3;
// 	public static final int CONTENT_TYPE_FEED = 4;
// 	
// 	public static final int MESSAGING_ID_GMAIL = 1;
// 	public static final int MESSAGING_ID_SMS = 2;
// 	
// 	public static final int EMERGENCY_ID_WIFI = 1;
// 	public static final int EMERGENCY_ID_CALL_STATE = 2;
// 	public static final int EMERGENCY_ID_BATT_STATE = 3;
// 	public static final int EMERGENCY_ID_RF_STATE = 4;
// 	
// 	public static final int ICON_TYPE_NORMAL_MESSAGE = 0;
// 	public static final int ICON_TYPE_EMAIL = 28;
// 	public static final int ICON_TYPE_CALL = 10;
// 	public static final int ICON_TYPE_EMERGENCY = 60;
// 	public static final int ICON_TYPE_BATT_FULL = 4;
// 	public static final int ICON_TYPE_BATT_MEDIUM = 5;
// 	public static final int ICON_TYPE_BATT_LOW = 6;
// 	public static final int ICON_TYPE_RF_STATE = 64;
// 	public static final int ICON_TYPE_RSS = 46;
// 	
// 	public static final String SMS_PACKAGE_NAME = "android.telephony.sms";
// 	public static final String GMAIL_PACKAGE_NAME = "com.google.android.gm";
// 	public static final String TELEPHONY_CALL_PACKAGE_NAME = "android.telephony.call";
// 	public static final String TELEPHONY_RF_PACKAGE_NAME = "android.telephony.rfstatus";
// 	public static final String FEED_PACKAGE_NAME = "com.hardcopy.feed";
// 	public static final String WIFI_PACKAGE_NAME = "android.net.wifi";
// 	public static final String BATT_PACKAGE_NAME = "android.os.battery";
// 	
// 	public int mContentType;			// Content type
// 	public int mIconType;				// Icon type
// 	public int mId;						// ID
// 	public boolean mIsEnabled = false;	// Watch shows enabled items only
// 	public String mOriginalString;		// Original string
// 	public String mFilteredString;		// String to be shown on remote device
// 	public String mExtraData = null;	// Extra data defined by each content type
// 	public String mPackageName = null;
// 	
// 	
// 	public ContentObject(int type, int id, String strOrigin, String strFiltered) {
// 		mContentType = type;
// 		mIconType = -1;
// 		mId = id;
// 		mOriginalString = strOrigin;
// 		mFilteredString = strFiltered;
// 	}
// 	
// }
// 
// Path: RetroWatch_Android/RetroWatchLE/src/com/hardcopy/retrowatchle/utils/Logs.java
// public class Logs {
// 	
// 	private static final String TAG = "RetroWatch";
// 	public static boolean mIsEnabled = true;
// 	
// 	
// 	public static void v(String msg) {
// 		if(mIsEnabled) {
// 			Log.v(TAG, msg);
// 		}
// 	}
// 	
// 	public static void v(String tag, String msg) {
// 		if(mIsEnabled) {
// 			Log.v(tag, msg);
// 		}
// 	}
// 	
// 	public static void d(String msg) {
// 		if(mIsEnabled) {
// 			Log.d(TAG, msg);
// 		}
// 	}
// 	
// 	public static void d(String tag, String msg) {
// 		if(mIsEnabled) {
// 			Log.d(tag, msg);
// 		}
// 	}
// 	
// 	public static void e(String msg) {
// 		if(mIsEnabled) {
// 			Log.e(TAG, msg);
// 		}
// 	}
// 	
// 	public static void e(String tag, String msg) {
// 		if(mIsEnabled) {
// 			Log.e(tag, msg);
// 		}
// 	}
// 	
// 	public static void i(String msg) {
// 		if(mIsEnabled) {
// 			Log.e(TAG, msg);
// 		}
// 	}
// 	
// 	public static void i(String tag, String msg) {
// 		if(mIsEnabled) {
// 			Log.e(tag, msg);
// 		}
// 	}
// 	
// }


// Path: RetroWatch_Android/RetroWatchLE/src/com/hardcopy/retrowatchle/MessageListFragment.java
import java.util.ArrayList;
import com.hardcopy.retrowatchle.contents.objects.ContentObject;
import com.hardcopy.retrowatchle.utils.Logs;
import android.content.Context;
import android.os.Bundle;
import android.support.v4.app.Fragment;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.ListView;

/*
 * Copyright (C) 2014 The Retro Watch - Open source smart watch project
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *      http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */

package com.hardcopy.retrowatchle;




/**
 * This fragment shows messages to be sent to watch.
 */
public class MessageListFragment extends Fragment implements IAdapterListener {

	private static final String TAG = "MessageListFragment";
	
	private Context mContext = null;
	private IFragmentListener mFragmentListener;
	
	private ListView mListMessage = null;
	private MessageListAdapter mMessageListAdapter = null;
	
	public MessageListFragment(Context c, IFragmentListener l) {
		mContext = c;
		mFragmentListener = l;