forked from mirrors/gecko-dev
Bug 920935 - Reading list items opened using keywords are not opened in Reading List. r=lucasr
This commit is contained in:
parent
c90e808628
commit
1777426401
1 changed files with 10 additions and 0 deletions
|
|
@ -37,6 +37,7 @@ import org.json.JSONObject;
|
|||
|
||||
import android.app.Activity;
|
||||
import android.app.AlertDialog;
|
||||
import android.content.ContentResolver;
|
||||
import android.content.DialogInterface;
|
||||
import android.content.Intent;
|
||||
import android.content.SharedPreferences;
|
||||
|
|
@ -1484,6 +1485,15 @@ abstract public class BrowserApp extends GeckoApp
|
|||
return;
|
||||
}
|
||||
|
||||
// If the keywordUrl is in ReadingList, convert the url to an about:reader url and load it.
|
||||
final ContentResolver cr = getContentResolver();
|
||||
final boolean inReadingList = BrowserDB.isReadingListItem(cr, keywordUrl);
|
||||
if (inReadingList) {
|
||||
final String readerUrl = ReaderModeUtils.getAboutReaderForUrl(keywordUrl);
|
||||
Tabs.getInstance().loadUrl(readerUrl, Tabs.LOADURL_USER_ENTERED);
|
||||
return;
|
||||
}
|
||||
|
||||
recordSearch(null, "barkeyword");
|
||||
|
||||
// Otherwise, construct a search query from the bookmark keyword.
|
||||
|
|
|
|||
Loading…
Reference in a new issue