|
|
@ -13,6 +13,7 @@ internal object SuggestionsManager { |
|
|
|
@JvmStatic |
|
|
|
@JvmStatic |
|
|
|
@Volatile var isRequestInProgress: Boolean = false |
|
|
|
@Volatile var isRequestInProgress: Boolean = false |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@JvmStatic |
|
|
|
fun createGoogleQueryObservable(query: String, application: Application) = |
|
|
|
fun createGoogleQueryObservable(query: String, application: Application) = |
|
|
|
Single.create(SingleAction<List<HistoryItem>> { subscriber -> |
|
|
|
Single.create(SingleAction<List<HistoryItem>> { subscriber -> |
|
|
|
isRequestInProgress = true |
|
|
|
isRequestInProgress = true |
|
|
@ -22,6 +23,7 @@ internal object SuggestionsManager { |
|
|
|
isRequestInProgress = false |
|
|
|
isRequestInProgress = false |
|
|
|
}) |
|
|
|
}) |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@JvmStatic |
|
|
|
fun createBaiduQueryObservable(query: String, application: Application) = |
|
|
|
fun createBaiduQueryObservable(query: String, application: Application) = |
|
|
|
Single.create(SingleAction<List<HistoryItem>> { subscriber -> |
|
|
|
Single.create(SingleAction<List<HistoryItem>> { subscriber -> |
|
|
|
isRequestInProgress = true |
|
|
|
isRequestInProgress = true |
|
|
@ -31,6 +33,7 @@ internal object SuggestionsManager { |
|
|
|
isRequestInProgress = false |
|
|
|
isRequestInProgress = false |
|
|
|
}) |
|
|
|
}) |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@JvmStatic |
|
|
|
fun createDuckQueryObservable(query: String, application: Application) = |
|
|
|
fun createDuckQueryObservable(query: String, application: Application) = |
|
|
|
Single.create(SingleAction<List<HistoryItem>> { subscriber -> |
|
|
|
Single.create(SingleAction<List<HistoryItem>> { subscriber -> |
|
|
|
isRequestInProgress = true |
|
|
|
isRequestInProgress = true |
|
|
|