minor fixes
This commit is contained in:
parent
3d7209ee7a
commit
163399816f
4 changed files with 23 additions and 12 deletions
|
|
@ -153,8 +153,7 @@ void FocusController::focusNextListViewItem()
|
||||||
{
|
{
|
||||||
if (m_lvfc->isLastFocusItemInListView() || m_lvfc->isReturnNeeded()) {
|
if (m_lvfc->isLastFocusItemInListView() || m_lvfc->isReturnNeeded()) {
|
||||||
qDebug() << "===>> [Last item in ListView was reached. Going to the NEXT element after ListView]";
|
qDebug() << "===>> [Last item in ListView was reached. Going to the NEXT element after ListView]";
|
||||||
delete m_lvfc;
|
resetListView();
|
||||||
m_lvfc = nullptr;
|
|
||||||
nextItem(Direction::Forward);
|
nextItem(Direction::Forward);
|
||||||
return;
|
return;
|
||||||
} else if (m_lvfc->isLastFocusItemInDelegate()) {
|
} else if (m_lvfc->isLastFocusItemInDelegate()) {
|
||||||
|
|
@ -171,8 +170,7 @@ void FocusController::focusPreviousListViewItem()
|
||||||
{
|
{
|
||||||
if (m_lvfc->isFirstFocusItemInListView() || m_lvfc->isReturnNeeded()) {
|
if (m_lvfc->isFirstFocusItemInListView() || m_lvfc->isReturnNeeded()) {
|
||||||
qDebug() << "===>> [First item in ListView was reached. Going to the PREVIOUS element after ListView]";
|
qDebug() << "===>> [First item in ListView was reached. Going to the PREVIOUS element after ListView]";
|
||||||
delete m_lvfc;
|
resetListView();
|
||||||
m_lvfc = nullptr;
|
|
||||||
nextItem(Direction::Backward);
|
nextItem(Direction::Backward);
|
||||||
return;
|
return;
|
||||||
} else if (m_lvfc->isFirstFocusItemInDelegate()) {
|
} else if (m_lvfc->isFirstFocusItemInDelegate()) {
|
||||||
|
|
@ -279,7 +277,7 @@ void FocusController::pushRootObject(QObject* object)
|
||||||
void FocusController::dropRootObject(QObject* object)
|
void FocusController::dropRootObject(QObject* object)
|
||||||
{
|
{
|
||||||
if (m_rootObjects.empty()) {
|
if (m_rootObjects.empty()) {
|
||||||
qDebug() << "ROOT OBJECT is already NULL";
|
qDebug() << "ROOT OBJECT is already DEFAULT";
|
||||||
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
@ -289,7 +287,7 @@ void FocusController::dropRootObject(QObject* object)
|
||||||
if(m_rootObjects.size()) {
|
if(m_rootObjects.size()) {
|
||||||
qDebug() << "===>> ROOT OBJECT is changed to: " << m_rootObjects.top();
|
qDebug() << "===>> ROOT OBJECT is changed to: " << m_rootObjects.top();
|
||||||
} else {
|
} else {
|
||||||
qDebug() << "===>> ROOT OBJECT is changed to NULL";
|
qDebug() << "===>> ROOT OBJECT is changed to DEFAULT";
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
qWarning() << "===>> TRY TO DROP WRONG ROOT OBJECT: " << m_rootObjects.top() << " SHOULD BE: " << object;
|
qWarning() << "===>> TRY TO DROP WRONG ROOT OBJECT: " << m_rootObjects.top() << " SHOULD BE: " << object;
|
||||||
|
|
|
||||||
|
|
@ -83,6 +83,7 @@ PageType {
|
||||||
|
|
||||||
ListView {
|
ListView {
|
||||||
id: listView
|
id: listView
|
||||||
|
|
||||||
anchors.top: backButton.bottom
|
anchors.top: backButton.bottom
|
||||||
anchors.bottom: parent.bottom
|
anchors.bottom: parent.bottom
|
||||||
anchors.right: parent.right
|
anchors.right: parent.right
|
||||||
|
|
@ -218,6 +219,7 @@ PageType {
|
||||||
|
|
||||||
BasicButtonType {
|
BasicButtonType {
|
||||||
id: checkUpdatesButton
|
id: checkUpdatesButton
|
||||||
|
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
Layout.topMargin: 8
|
Layout.topMargin: 8
|
||||||
Layout.bottomMargin: 16
|
Layout.bottomMargin: 16
|
||||||
|
|
@ -238,6 +240,7 @@ PageType {
|
||||||
|
|
||||||
BasicButtonType {
|
BasicButtonType {
|
||||||
id: privacyPolicyButton
|
id: privacyPolicyButton
|
||||||
|
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
Layout.bottomMargin: 16
|
Layout.bottomMargin: 16
|
||||||
Layout.topMargin: -15
|
Layout.topMargin: -15
|
||||||
|
|
|
||||||
|
|
@ -104,7 +104,7 @@ PageType {
|
||||||
|
|
||||||
shareConnectionDrawer.headerText = qsTr("Accessing ") + serverSelector.text
|
shareConnectionDrawer.headerText = qsTr("Accessing ") + serverSelector.text
|
||||||
shareConnectionDrawer.configContentHeaderText = qsTr("File with accessing settings to ") + serverSelector.text
|
shareConnectionDrawer.configContentHeaderText = qsTr("File with accessing settings to ") + serverSelector.text
|
||||||
serverSelector.close()
|
serverSelector.closeTriggered()
|
||||||
}
|
}
|
||||||
|
|
||||||
Component.onCompleted: {
|
Component.onCompleted: {
|
||||||
|
|
@ -142,7 +142,7 @@ PageType {
|
||||||
shareConnectionDrawer.headerText = qsTr("Connection to ") + serverSelector.text
|
shareConnectionDrawer.headerText = qsTr("Connection to ") + serverSelector.text
|
||||||
shareConnectionDrawer.configContentHeaderText = qsTr("File with connection settings to ") + serverSelector.text
|
shareConnectionDrawer.configContentHeaderText = qsTr("File with connection settings to ") + serverSelector.text
|
||||||
|
|
||||||
shareConnectionDrawer.open()
|
shareConnectionDrawer.openTriggered()
|
||||||
shareConnectionDrawer.contentVisible = true
|
shareConnectionDrawer.contentVisible = true
|
||||||
|
|
||||||
PageController.showBusyIndicator(false)
|
PageController.showBusyIndicator(false)
|
||||||
|
|
|
||||||
|
|
@ -246,12 +246,22 @@ PageType {
|
||||||
}
|
}
|
||||||
|
|
||||||
Keys.onPressed: function(event) {
|
Keys.onPressed: function(event) {
|
||||||
if(event.key === Qt.Key_Tab) {
|
console.debug(">>>> ", event.key, " Event is caught by StartPage")
|
||||||
|
switch (event.key) {
|
||||||
|
case Qt.Key_Tab:
|
||||||
|
case Qt.Key_Down:
|
||||||
|
case Qt.Key_Right:
|
||||||
FocusController.nextKeyTabItem()
|
FocusController.nextKeyTabItem()
|
||||||
|
break
|
||||||
|
case Qt.Key_Backtab:
|
||||||
|
case Qt.Key_Up:
|
||||||
|
case Qt.Key_Left:
|
||||||
|
FocusController.previousKeyTabItem()
|
||||||
|
break
|
||||||
|
default:
|
||||||
|
PageController.keyPressEvent(event.key)
|
||||||
|
event.accepted = true
|
||||||
}
|
}
|
||||||
|
|
||||||
PageController.keyPressEvent(event.key)
|
|
||||||
event.accepted = true
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue