mirror of
https://github.com/Corewala/Buran
synced 2024-12-22 15:55:35 +00:00
Fixed bug where the intended page is replaced by homepage when opened with link
This commit is contained in:
parent
f6f7997c69
commit
324d947330
1 changed files with 18 additions and 9 deletions
|
@ -132,15 +132,24 @@ class GemActivity : AppCompatActivity() {
|
||||||
|
|
||||||
binding.gemtextRecycler.adapter = adapter
|
binding.gemtextRecycler.adapter = adapter
|
||||||
|
|
||||||
model.initialise(
|
if(intent.data == null){
|
||||||
home = prefs.getString(
|
model.initialise(
|
||||||
"home_capsule",
|
home = prefs.getString(
|
||||||
Buran.DEFAULT_HOME_CAPSULE
|
"home_capsule",
|
||||||
) ?: Buran.DEFAULT_HOME_CAPSULE,
|
Buran.DEFAULT_HOME_CAPSULE
|
||||||
gemini = Datasource.factory(this, db.history()),
|
) ?: Buran.DEFAULT_HOME_CAPSULE,
|
||||||
db = db,
|
gemini = Datasource.factory(this, db.history()),
|
||||||
onState = this::handleState
|
db = db,
|
||||||
)
|
onState = this::handleState
|
||||||
|
)
|
||||||
|
}else{
|
||||||
|
model.initialise(
|
||||||
|
home = intent.data.toString(),
|
||||||
|
gemini = Datasource.factory(this, db.history()),
|
||||||
|
db = db,
|
||||||
|
onState = this::handleState
|
||||||
|
)
|
||||||
|
}
|
||||||
|
|
||||||
binding.addressEdit.setOnEditorActionListener { _, actionId, _ ->
|
binding.addressEdit.setOnEditorActionListener { _, actionId, _ ->
|
||||||
when (actionId) {
|
when (actionId) {
|
||||||
|
|
Loading…
Reference in a new issue