Compare commits
No commits in common. "882cc8989fbdb91f63bdf14da468b2cdeb0d52d2" and "7a6efa41fb15272bd838ec1c3459357c5a6b41fe" have entirely different histories.
882cc8989f
...
7a6efa41fb
|
@ -1,20 +0,0 @@
|
||||||
{
|
|
||||||
"MicroPython.executeButton": [
|
|
||||||
{
|
|
||||||
"text": "▶",
|
|
||||||
"tooltip": "运行",
|
|
||||||
"alignment": "left",
|
|
||||||
"command": "extension.executeFile",
|
|
||||||
"priority": 3.5
|
|
||||||
}
|
|
||||||
],
|
|
||||||
"MicroPython.syncButton": [
|
|
||||||
{
|
|
||||||
"text": "$(sync)",
|
|
||||||
"tooltip": "同步",
|
|
||||||
"alignment": "left",
|
|
||||||
"command": "extension.execute",
|
|
||||||
"priority": 4
|
|
||||||
}
|
|
||||||
]
|
|
||||||
}
|
|
|
@ -49,26 +49,26 @@ FluScrollablePage{
|
||||||
Layout.topMargin: -6
|
Layout.topMargin: -6
|
||||||
code:'FluPivot{
|
code:'FluPivot{
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
FluPivotItem {
|
FluPivotItem:{
|
||||||
title: qsTr("All")
|
text: qsTr("All")
|
||||||
contentItem: FluText{
|
contentItem: FluText{
|
||||||
text: qsTr("All emails go here.")
|
text: qsTr("All emails go here.")
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
FluPivotItem {
|
FluPivotItem:{
|
||||||
title: qsTr("Unread")
|
text: qsTr("Unread")
|
||||||
contentItem: FluText{
|
contentItem: FluText{
|
||||||
text: qsTr("Unread emails go here.")
|
text: qsTr("Unread emails go here.")
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
FluPivotItem {
|
FluPivotItem:{
|
||||||
title: qsTr("Flagged")
|
text: qsTr("Flagged")
|
||||||
contentItem: FluText{
|
contentItem: FluText{
|
||||||
text: qsTr("Flagged emails go here.")
|
text: qsTr("Flagged emails go here.")
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
FluPivotItem {
|
FluPivotItem:{
|
||||||
title: qsTr("Urgent")
|
text: qsTr("Urgent")
|
||||||
contentItem: FluText{
|
contentItem: FluText{
|
||||||
text: qsTr("Urgent emails go here.")
|
text: qsTr("Urgent emails go here.")
|
||||||
}
|
}
|
||||||
|
|
|
@ -24,7 +24,7 @@ Item {
|
||||||
}
|
}
|
||||||
QtObject{
|
QtObject{
|
||||||
id:d
|
id:d
|
||||||
property bool flagXChanged: false
|
property bool flagXChanged: true
|
||||||
property bool isAnimEnable: control.autoPlay && list_view.count>3
|
property bool isAnimEnable: control.autoPlay && list_view.count>3
|
||||||
function setData(data){
|
function setData(data){
|
||||||
if(!data){
|
if(!data){
|
||||||
|
@ -88,17 +88,14 @@ Item {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
onMovementEnded:{
|
onMovementEnded:{
|
||||||
d.flagXChanged = false
|
|
||||||
list_view.highlightMoveDuration = 0
|
|
||||||
currentIndex = list_view.contentX/list_view.width
|
currentIndex = list_view.contentX/list_view.width
|
||||||
if(currentIndex === 0){
|
if(currentIndex === 0){
|
||||||
currentIndex = list_view.count-2
|
currentIndex = list_view.count-2
|
||||||
}else if(currentIndex === list_view.count-1){
|
}else if(currentIndex === list_view.count-1){
|
||||||
currentIndex = 1
|
currentIndex = 1
|
||||||
}
|
}
|
||||||
if(d.isAnimEnable){
|
d.flagXChanged = false
|
||||||
timer_run.restart()
|
timer_run.restart()
|
||||||
}
|
|
||||||
}
|
}
|
||||||
onMovementStarted: {
|
onMovementStarted: {
|
||||||
d.flagXChanged = true
|
d.flagXChanged = true
|
||||||
|
@ -107,12 +104,12 @@ Item {
|
||||||
onContentXChanged: {
|
onContentXChanged: {
|
||||||
if(d.flagXChanged){
|
if(d.flagXChanged){
|
||||||
var maxX = Math.min(list_view.width*(currentIndex+1),list_view.count*list_view.width)
|
var maxX = Math.min(list_view.width*(currentIndex+1),list_view.count*list_view.width)
|
||||||
var minX = Math.max(0,(list_view.width*(currentIndex-1)))
|
var minY = Math.max(0,(list_view.width*(currentIndex-1)))
|
||||||
if(contentX>=maxX){
|
if(contentX>=maxX){
|
||||||
contentX = maxX
|
contentX = maxX
|
||||||
}
|
}
|
||||||
if(contentX<=minX){
|
if(contentX<=minY){
|
||||||
contentX = minX
|
contentX = minY
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -14,6 +14,13 @@ ProgressBar{
|
||||||
id:d
|
id:d
|
||||||
property real _radius: strokeWidth/2
|
property real _radius: strokeWidth/2
|
||||||
}
|
}
|
||||||
|
onIndeterminateChanged:{
|
||||||
|
if(!indeterminate){
|
||||||
|
animator_x.duration = 0
|
||||||
|
rect_progress.x = 0
|
||||||
|
animator_x.duration = control.duration
|
||||||
|
}
|
||||||
|
}
|
||||||
background: Rectangle {
|
background: Rectangle {
|
||||||
implicitWidth: 150
|
implicitWidth: 150
|
||||||
implicitHeight: control.strokeWidth
|
implicitHeight: control.strokeWidth
|
||||||
|
@ -38,11 +45,6 @@ ProgressBar{
|
||||||
id: animator_x
|
id: animator_x
|
||||||
running: control.indeterminate && control.visible
|
running: control.indeterminate && control.visible
|
||||||
loops: Animation.Infinite
|
loops: Animation.Infinite
|
||||||
onRunningChanged: {
|
|
||||||
if(!running){
|
|
||||||
rect_progress.x = 0
|
|
||||||
}
|
|
||||||
}
|
|
||||||
PropertyAnimation {
|
PropertyAnimation {
|
||||||
from: -rect_progress.width
|
from: -rect_progress.width
|
||||||
to: control.width + rect_progress.width
|
to: control.width + rect_progress.width
|
||||||
|
|
|
@ -24,7 +24,7 @@ Item {
|
||||||
}
|
}
|
||||||
QtObject{
|
QtObject{
|
||||||
id:d
|
id:d
|
||||||
property bool flagXChanged: false
|
property bool flagXChanged: true
|
||||||
property bool isAnimEnable: control.autoPlay && list_view.count>3
|
property bool isAnimEnable: control.autoPlay && list_view.count>3
|
||||||
function setData(data){
|
function setData(data){
|
||||||
if(!data){
|
if(!data){
|
||||||
|
@ -88,17 +88,14 @@ Item {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
onMovementEnded:{
|
onMovementEnded:{
|
||||||
d.flagXChanged = false
|
|
||||||
list_view.highlightMoveDuration = 0
|
|
||||||
currentIndex = list_view.contentX/list_view.width
|
currentIndex = list_view.contentX/list_view.width
|
||||||
if(currentIndex === 0){
|
if(currentIndex === 0){
|
||||||
currentIndex = list_view.count-2
|
currentIndex = list_view.count-2
|
||||||
}else if(currentIndex === list_view.count-1){
|
}else if(currentIndex === list_view.count-1){
|
||||||
currentIndex = 1
|
currentIndex = 1
|
||||||
}
|
}
|
||||||
if(d.isAnimEnable){
|
d.flagXChanged = false
|
||||||
timer_run.restart()
|
timer_run.restart()
|
||||||
}
|
|
||||||
}
|
}
|
||||||
onMovementStarted: {
|
onMovementStarted: {
|
||||||
d.flagXChanged = true
|
d.flagXChanged = true
|
||||||
|
@ -107,12 +104,12 @@ Item {
|
||||||
onContentXChanged: {
|
onContentXChanged: {
|
||||||
if(d.flagXChanged){
|
if(d.flagXChanged){
|
||||||
var maxX = Math.min(list_view.width*(currentIndex+1),list_view.count*list_view.width)
|
var maxX = Math.min(list_view.width*(currentIndex+1),list_view.count*list_view.width)
|
||||||
var minX = Math.max(0,(list_view.width*(currentIndex-1)))
|
var minY = Math.max(0,(list_view.width*(currentIndex-1)))
|
||||||
if(contentX>=maxX){
|
if(contentX>=maxX){
|
||||||
contentX = maxX
|
contentX = maxX
|
||||||
}
|
}
|
||||||
if(contentX<=minX){
|
if(contentX<=minY){
|
||||||
contentX = minX
|
contentX = minY
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -15,6 +15,13 @@ ProgressBar{
|
||||||
id:d
|
id:d
|
||||||
property real _radius: strokeWidth/2
|
property real _radius: strokeWidth/2
|
||||||
}
|
}
|
||||||
|
onIndeterminateChanged:{
|
||||||
|
if(!indeterminate){
|
||||||
|
animator_x.duration = 0
|
||||||
|
rect_progress.x = 0
|
||||||
|
animator_x.duration = control.duration
|
||||||
|
}
|
||||||
|
}
|
||||||
background: Rectangle {
|
background: Rectangle {
|
||||||
implicitWidth: 150
|
implicitWidth: 150
|
||||||
implicitHeight: control.strokeWidth
|
implicitHeight: control.strokeWidth
|
||||||
|
@ -39,11 +46,6 @@ ProgressBar{
|
||||||
id: animator_x
|
id: animator_x
|
||||||
running: control.indeterminate && control.visible
|
running: control.indeterminate && control.visible
|
||||||
loops: Animation.Infinite
|
loops: Animation.Infinite
|
||||||
onRunningChanged: {
|
|
||||||
if(!running){
|
|
||||||
rect_progress.x = 0
|
|
||||||
}
|
|
||||||
}
|
|
||||||
PropertyAnimation {
|
PropertyAnimation {
|
||||||
from: -rect_progress.width
|
from: -rect_progress.width
|
||||||
to: control.width + rect_progress.width
|
to: control.width + rect_progress.width
|
||||||
|
|
Loading…
Reference in New Issue