|
|
@ -8,6 +8,7 @@ import android.net.Uri;
|
|
|
|
|
|
|
|
|
|
|
|
import com.timsu.astrid.R;
|
|
|
|
import com.timsu.astrid.R;
|
|
|
|
import com.todoroo.andlib.service.ContextManager;
|
|
|
|
import com.todoroo.andlib.service.ContextManager;
|
|
|
|
|
|
|
|
import com.todoroo.andlib.utility.AndroidUtilities;
|
|
|
|
import com.todoroo.astrid.utility.Preferences;
|
|
|
|
import com.todoroo.astrid.utility.Preferences;
|
|
|
|
|
|
|
|
|
|
|
|
@SuppressWarnings("nls")
|
|
|
|
@SuppressWarnings("nls")
|
|
|
@ -37,7 +38,7 @@ public class Calendars {
|
|
|
|
* @param table provider table, something like calendars, events
|
|
|
|
* @param table provider table, something like calendars, events
|
|
|
|
*/
|
|
|
|
*/
|
|
|
|
public static Uri getCalendarContentUri(String table) {
|
|
|
|
public static Uri getCalendarContentUri(String table) {
|
|
|
|
if(android.os.Build.VERSION.SDK_INT >= 8)
|
|
|
|
if(AndroidUtilities.getSdkVersion() >= 8)
|
|
|
|
return Uri.parse("content://com.android.calendar/" + table);
|
|
|
|
return Uri.parse("content://com.android.calendar/" + table);
|
|
|
|
else
|
|
|
|
else
|
|
|
|
return Uri.parse("content://calendar/" + table);
|
|
|
|
return Uri.parse("content://calendar/" + table);
|
|
|
@ -45,7 +46,7 @@ public class Calendars {
|
|
|
|
|
|
|
|
|
|
|
|
/** Return calendar package name */
|
|
|
|
/** Return calendar package name */
|
|
|
|
public static String getCalendarPackage() {
|
|
|
|
public static String getCalendarPackage() {
|
|
|
|
if(android.os.Build.VERSION.SDK_INT >= 8)
|
|
|
|
if(AndroidUtilities.getSdkVersion() >= 8)
|
|
|
|
return "com.google.android.calendar";
|
|
|
|
return "com.google.android.calendar";
|
|
|
|
else
|
|
|
|
else
|
|
|
|
return "com.android.calendar";
|
|
|
|
return "com.android.calendar";
|
|
|
|