Android Back button like home button #212

已合併
erinn 將 2 次提交從 :androidBack 合併至 master 2019-09-13 23:24:59 +00:00
擁有者

Android back button default behaviour on root pane is to exit that app. That's not ideal so I've captured it and redirected to a home button like behaviour

It might be nice to have it do pane switching when not at root?

Android back button default behaviour on root pane is to exit that app. That's not ideal so I've captured it and redirected to a home button like behaviour It might be nice to have it do pane switching when not at root?
普通成員

Drone Build Status: success

https://build.openprivacy.ca/cwtch.im/ui/318

Drone Build Status: success https://build.openprivacy.ca/cwtch.im/ui/318
普通成員

Drone Build Status: success

https://build.openprivacy.ca/cwtch.im/ui/319

Drone Build Status: success https://build.openprivacy.ca/cwtch.im/ui/319
erinndan 取消指派 2019-09-11 18:03:06 +00:00
erinndan 指派 2019-09-11 18:03:10 +00:00
擁有者

updated back button handling (not very robust but i'm planning a layout manager change that will break this anyway so it's fine for now):
Keys.onPressed: {
if (event.key == Qt.Key_Back) {
event.accepted = true
if (theStack.currentIndex == theStack.emptyPane) {
androidCwtchActivity.rootHomeButtonHandle()
} else if (theStack.currentIndex == theStack.userProfilePane || theStack.currentIndex == theStack.groupProfilePane) {
theStack.currentIndex = theStack.messagePane
} else {
theStack.currentIndex = theStack.emptyPane
}
}
}
'''

updated back button handling (not very robust but i'm planning a layout manager change that will break this anyway so it's fine for now): Keys.onPressed: { if (event.key == Qt.Key_Back) { event.accepted = true if (theStack.currentIndex == theStack.emptyPane) { androidCwtchActivity.rootHomeButtonHandle() } else if (theStack.currentIndex == theStack.userProfilePane || theStack.currentIndex == theStack.groupProfilePane) { theStack.currentIndex = theStack.messagePane } else { theStack.currentIndex = theStack.emptyPane } } } '''
erinn 請求了變更 2019-09-13 23:15:34 +00:00
@ -14,2 +15,4 @@
_ func(string) `slot:"updateAndroidNotification"`
_ func() `signal:"rootHomeButtonHandle,auto""`

remove double-double-quote near eol

remove double-double-quote near eol
作者
擁有者

added

fixed!

thanks

added fixed! thanks
普通成員

Drone Build Status: success

https://build.openprivacy.ca/cwtch.im/ui/333

Drone Build Status: success https://build.openprivacy.ca/cwtch.im/ui/333
普通成員

Drone Build Status: success

https://build.openprivacy.ca/cwtch.im/ui/332

Drone Build Status: success https://build.openprivacy.ca/cwtch.im/ui/332
erinn 核可了這些變更 2019-09-13 23:21:24 +00:00
普通成員

Drone Build Status: success

https://build.openprivacy.ca/cwtch.im/ui/335

Drone Build Status: success https://build.openprivacy.ca/cwtch.im/ui/335
普通成員

Drone Build Status: success

https://build.openprivacy.ca/cwtch.im/ui/334

Drone Build Status: success https://build.openprivacy.ca/cwtch.im/ui/334
erinn 關閉了這個合併請求 2019-09-13 23:24:59 +00:00
此存儲庫已封存,您不能在合併請求上留言。
No description provided.