Hi All, I am new to Android Dev, and this is my first widget.
What is supposed to happen is when the user clicks the widget, it turns off or on the Master Sync option.
However the widget does not do anything when clicked, and appears to not be clickable.
This is the body of the .java code, if it helps to post any of the other code please let me know.
public class MasterSync extends AppWidgetProvider {
/** Called when the activity is first created. */
@Override
public void onUpdate(Context context, AppWidgetManager appWidgetManager, int[] appWidgetIds) {
final int N = appWidgetIds.length;
// now label the property of the button
boolean sync = ContentResolver.getMasterSyncAutomatically();
if (sync){
ContentResolver.setMasterSyncAutomatically(false);}
else
if (!sync){
ContentResolver.setMasterSyncAutomatically(true);
}
}}