mirror of
https://github.com/moparisthebest/open-keychain
synced 2024-11-30 12:32:17 -05:00
drop unified uri in favor of generic /key_rings
this works well in the uri schema, and we get notifications back with no effort. ....also remove a line I committed accidentally oO
This commit is contained in:
parent
9a1ce093bf
commit
be3828c89e
@ -78,7 +78,6 @@ public class KeychainContract {
|
|||||||
|
|
||||||
public static final String PATH_PUBLIC = "public";
|
public static final String PATH_PUBLIC = "public";
|
||||||
public static final String PATH_SECRET = "secret";
|
public static final String PATH_SECRET = "secret";
|
||||||
public static final String PATH_UNIFIED = "unified";
|
|
||||||
|
|
||||||
public static final String PATH_BY_MASTER_KEY_ID = "master_key_id";
|
public static final String PATH_BY_MASTER_KEY_ID = "master_key_id";
|
||||||
public static final String PATH_BY_KEY_ID = "key_id";
|
public static final String PATH_BY_KEY_ID = "key_id";
|
||||||
@ -102,7 +101,7 @@ public class KeychainContract {
|
|||||||
public static final String CONTENT_ITEM_TYPE = "vnd.android.cursor.item/vnd.thialfihar.apg.key_ring";
|
public static final String CONTENT_ITEM_TYPE = "vnd.android.cursor.item/vnd.thialfihar.apg.key_ring";
|
||||||
|
|
||||||
public static Uri buildUnifiedKeyRingsUri() {
|
public static Uri buildUnifiedKeyRingsUri() {
|
||||||
return CONTENT_URI.buildUpon().appendPath(PATH_UNIFIED).build();
|
return CONTENT_URI;
|
||||||
}
|
}
|
||||||
|
|
||||||
public static Uri buildPublicKeyRingsUri() {
|
public static Uri buildPublicKeyRingsUri() {
|
||||||
|
@ -96,6 +96,15 @@ public class KeychainProvider extends ContentProvider {
|
|||||||
|
|
||||||
String authority = KeychainContract.CONTENT_AUTHORITY;
|
String authority = KeychainContract.CONTENT_AUTHORITY;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* unified key rings
|
||||||
|
*
|
||||||
|
* <pre>
|
||||||
|
* key_rings
|
||||||
|
* </pre>
|
||||||
|
*/
|
||||||
|
matcher.addURI(authority, KeychainContract.BASE_KEY_RINGS, UNIFIED_KEY_RING);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* public key rings
|
* public key rings
|
||||||
*
|
*
|
||||||
@ -228,16 +237,6 @@ public class KeychainProvider extends ContentProvider {
|
|||||||
matcher.addURI(authority, KeychainContract.BASE_API_APPS + "/"
|
matcher.addURI(authority, KeychainContract.BASE_API_APPS + "/"
|
||||||
+ KeychainContract.PATH_BY_PACKAGE_NAME + "/*", API_APPS_BY_PACKAGE_NAME);
|
+ KeychainContract.PATH_BY_PACKAGE_NAME + "/*", API_APPS_BY_PACKAGE_NAME);
|
||||||
|
|
||||||
/**
|
|
||||||
* unified key rings
|
|
||||||
* <pre>
|
|
||||||
*
|
|
||||||
* key_rings/unified
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
matcher.addURI(authority, KeychainContract.BASE_KEY_RINGS + "/"
|
|
||||||
+ KeychainContract.PATH_UNIFIED, UNIFIED_KEY_RING);
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* data stream
|
* data stream
|
||||||
*
|
*
|
||||||
@ -813,9 +812,6 @@ public class KeychainProvider extends ContentProvider {
|
|||||||
|
|
||||||
// notify of changes in db
|
// notify of changes in db
|
||||||
getContext().getContentResolver().notifyChange(uri, null);
|
getContext().getContentResolver().notifyChange(uri, null);
|
||||||
getContext().getContentResolver().notifyChange(
|
|
||||||
KeyRings.buildUnifiedKeyRingsUri().buildUpon().appendPath("lulz").build(), null
|
|
||||||
);
|
|
||||||
|
|
||||||
return count;
|
return count;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user