mirror of
https://github.com/mozilla/gecko-dev.git
synced 2025-01-01 05:43:46 +00:00
Make NEXT_NO_DUPLICATE and PREV_NO_DUPLICATE behave the same as NEXT and PREV for object store cursors
This commit is contained in:
parent
d1b409e700
commit
468d30fd90
@ -971,12 +971,6 @@ IDBObjectStoreRequest::OpenCursor(nsIIDBKeyRange* aKeyRange,
|
||||
aDirection = nsIIDBCursor::NEXT;
|
||||
}
|
||||
|
||||
if (aDirection == nsIIDBCursor::NEXT_NO_DUPLICATE ||
|
||||
aDirection == nsIIDBCursor::PREV_NO_DUPLICATE) {
|
||||
NS_NOTYETIMPLEMENTED("Implement me!");
|
||||
return NS_ERROR_NOT_IMPLEMENTED;
|
||||
}
|
||||
|
||||
if (aPreload) {
|
||||
NS_NOTYETIMPLEMENTED("Implement me!");
|
||||
return NS_ERROR_NOT_IMPLEMENTED;
|
||||
@ -1641,10 +1635,12 @@ OpenCursorHelper::DoDatabaseWork(mozIStorageConnection* aConnection)
|
||||
|
||||
switch (mDirection) {
|
||||
case nsIIDBCursor::NEXT:
|
||||
case nsIIDBCursor::NEXT_NO_DUPLICATE:
|
||||
query.AppendLiteral(" DESC");
|
||||
break;
|
||||
|
||||
case nsIIDBCursor::PREV:
|
||||
case nsIIDBCursor::PREV_NO_DUPLICATE:
|
||||
query.AppendLiteral(" ASC");
|
||||
break;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user