import QtQuick 2.0 import Label 2.0 import "../com/neusoft/auto/widgets" import "../windowsList.js" as WindowsList import "../layoutList.js" as Layout //HMIWindow { Item{ id:user_manual y:45//user manual change width: 960 height: 1075//user manual change property int iImageMaxWidth : 960 property int iImageMaxHeight : 970//1050 property int total_num: 0 property int movedirflag:0 //0:no change;1:right;2:left property real movingstartcontentx:0.0 property real scalenum: 1.0 property real scalenum1: 1.0 property int settype: 0 property string bgImageStyle: systemCtrl.style property int moveSatrtIndex: 0 property bool movingflag:false property real allreleasecontentx:0.0 property bool movetoadjflag:false property int movingcompareindex:0 property int movingcurtindex:0 signal setscale() property string searchInfo: "" property int iType : 3 property bool iNum : true property string style: systemCtrl.style property int iLanguage: systemCtrl.iLanguage property string the_one_text:"" property string the_two_text:"" property string the_three_text:"" property bool input_num_flag : false property int currentIndexforDisplay:0 //ADD By qu-shh for auto display off start property bool display_flag:false //ADD By qu-shh for auto display off end //modify by Jiyulong for vr_help start 2018/2/28 property int vr_start_page_num: 0 property int iBackground: settingCtrl.iBackground//add by lium for 342444 20190718 //modify by Jiyulong for vr_help end //modify by lium for 342444 20190718 begin // Rectangle{ // anchors.fill: parent // color:"black" // } Image { anchors.fill: parent source: "qrc:MATERIAL/MATERIAL_BLURBACKGROUND_"+iBackground+"_USER-MANUAL"+bgImageStyle } //modify by lium for 342444 20190718 end Component.onCompleted: { //modify by Jiyulong for #176644 start 2017/5/23 total_num = USBControl1.usbGet_UserManualFileNum() USBControl1.usbsetFileList_user_manual(total_num) //modify by Jiyulong for vr_help start 2018/2/28 vr_start_page_num = USBControl1.usbCtrlGetVrStartPage(); console.log("****user_manual onCompleted**** vr_start_page_num = "+vr_start_page_num) //modify by Jiyulong for vr_help end // console.log("*********user_manual onCompleted**************** total_num ="+total_num) //modify by Jiyulong for #176644 end } onVisibleChanged: { if( true == user_manual.visible) { systemCtrl.menuBarVisibleCtrl(false,1)//user manual change//modify by liuming 20190626 nameSearch_keyBoard.visible = false // button_timer.restart() the_one_text = "" the_two_text = "" the_three_text = "" nameSearchInput.text = "" input_num_flag = false //modify by Jiyulong for vr_help start 2018/2/28 /*if( true == vrCtrl.GetEnterUserManualFromVRFlag() ) { vrCtrl.SetEnterUserManualFromVRFlag(false) if(total_num > 0 && 0 != vr_start_page_num ) { big_Grid_View.cancelFlick() if(scalenum > 1) { scalenum = 1 settype = 2 setscale() } big_Grid_View.currentIndex = (vr_start_page_num - 1) big_Grid_View.contentX = big_Grid_View.currentIndex*big_gridview_Rec.width } }*///del by yx //modify by Jiyulong for vr_help end // console.log("***********************************user_manual visible true ") //ADD By qu-shh for auto display off start if(!display_flag) { systemCtrl.auto_Displayoff_Shield() display_flag = true } ScreenManager.setFormZ(WindowsList.HOME_STATE_BAR,WindowsList.Z_OVERLAY_2) //ADD 2019/06/27 by wyc FOR 340683 } else { //ADD 2019/06/22 by wyc FOR 340683 begin if((ScreenManager.getFormInformation(WindowsList.BTP_HOME) == Layout.SHOW_FULL)||(ScreenManager.getFormInformation(WindowsList.BTP_HOME) == Layout.SHOW_BODYA)||(ScreenManager.getFormInformation(WindowsList.BTP_HOME) == Layout.SHOW_BODYB)) { btCtrl.setTalkingStateBar(false) } else { //do nothing } //ADD 2019/06/22 by wyc FOR 340683 end systemCtrl.menuBarVisibleCtrl(true,1)//user manual change//modify by liuming 20190626 if(display_flag) { systemCtrl.auto_Displayoff_Unshield() display_flag = false } //ADD By qu-shh for auto display off end ScreenManager.setFormZ(WindowsList.HOME_STATE_BAR,WindowsList.Z_OVERLAY_0) //ADD 2019/06/27 by wyc FOR 340683 } } function scale_reset() { if(scalenum > 1) { big_Grid_View.cancelFlick() scalenum = 1 settype = 2 // setscale() } } Component { id: delegate Flickable { id: picFlick width: 960 height: 970//1050 clip:true property real oldwidth: 0 property real oldheight: 0 property real oldx: 0.0 property real oldy: 0.0 property int tempcontentWidth: ungif.width property int tempcontentHeight: ungif.height property bool image_ungif_States: false property bool imageFlag: true property int imagetempindex: 0 property bool pinchstop: false contentWidth: { if((ungif.width > iImageMaxWidth)) { picFlick.tempcontentWidth } else { iImageMaxWidth } } contentHeight: { if((ungif.height > iImageMaxHeight)) { picFlick.tempcontentHeight } else { iImageMaxHeight } } boundsBehavior: Flickable.StopAtBounds Connections { target: user_manual // function setscale() onSetscale: { switch(settype) { case 2://cancle zoom effets { if((index>= (big_Grid_View.currentIndex-1)) && (index<= (big_Grid_View.currentIndex+1))) { ungif.width = picFlick.oldwidth ungif.height = picFlick.oldheight ungif.x = picFlick.oldx ungif.y = picFlick.oldy picFlick.contentY = 0//add by lium for 342446 picFlick.contentX = 0//add by lium for 342446 ungif.rotation = 0 } break } default: break } } } Image { id: ungif // anchors.fill:parent source: col0 == "" ? "":"file://"+col0 sourceSize.width:960 sourceSize.height:970//1050 fillMode:Image.PreserveAspectFit asynchronous:true clip:false smooth:false cache:false property int realwidth:0 property int realheight:0 onStatusChanged: { if(ungif.status == Image.Ready) { picFlick.image_ungif_States = true realwidth = ungif.width//bigimage1.sourceSize.width realheight = ungif.height// bigimage1.sourceSize.height ungifanalyze() // console.log("onStatusChanged Ready ") // defaultpic.visible = false } else if(ungif.status == Image.Error) { picFlick.imageFlag = false picFlick.image_ungif_States = false } } } // Text { // id:text_num // anchors.bottom: parent.bottom // anchors.left: parent.left // text: col1== "" ? 'name is kong':'Name: ' + col1 // font.pixelSize: 30//24 // } PinchArea { id:pinch_area property real p1toC_X property real p1toC_Y property real contentInitX property real contentInitY property real tempscalenum x:ungif.x y:ungif.y width:ungif.width height:ungif.height onPinchStarted: { USBControl1.usbCtrlImageTouchReleaseTimerOff() // USBControl1.usbCtrlImageDisplayTimerOff() picFlick.cancelFlick() // USBControl1.imagePlayStatus = StatusList.USB_PAUSE // USBControl1.usbCtrlImageTimeTimerOff() // softkeyappear() //identify if less than two finger or finger out of picture if(pinch.point1.x<0||pinch.point1.y<0||pinch.startPoint1.x<0||pinch.startPoint1.y<0|| pinch.point2.x<0||pinch.point2.y<0||pinch.startPoint2.x<0||pinch.startPoint2.y<0|| pinch.point1.x>pinch_area.width||pinch.point1.y>pinch_area.height||pinch.startPoint1.x>pinch_area.width||pinch.startPoint1.y>pinch_area.height|| pinch.point2.x>pinch_area.width||pinch.point2.y>pinch_area.height||pinch.startPoint2.x>pinch_area.width||pinch.startPoint2.y>pinch_area.height) { pinch.accepted = false } else { pinch.accepted = true if( (picFlick.imageFlag == true)&&(picFlick.image_ungif_States == true) ) { picFlick.interactive = false big_Grid_View.interactive = false scalenum1 = scalenum pinch_area.tempscalenum = scalenum p1toC_X = pinch.center.x//(pinch.center.x-ungif.x) p1toC_Y = pinch.center.y//(pinch.center.y-ungif.y) contentInitX = picFlick.contentX contentInitY = picFlick.contentY // console.log(" onPinchStarted ``````````````````````````````") } } } onPinchUpdated: { if(pinchstop == true) { //pinch don't update } else if(pinch.point1.x<0||pinch.point1.y<0||pinch.startPoint1.x<0||pinch.startPoint1.y<0|| pinch.point2.x<0||pinch.point2.y<0||pinch.startPoint2.x<0||pinch.startPoint2.y<0|| pinch.point1.x>pinch_area.width||pinch.point1.y>pinch_area.height||pinch.startPoint1.x>pinch_area.width||pinch.startPoint1.y>pinch_area.height|| pinch.point2.x>pinch_area.width||pinch.point2.y>pinch_area.height||pinch.startPoint2.x>pinch_area.width||pinch.startPoint2.y>pinch_area.height|| pinch.pointCount < 2) { pinch.accepted = false pinchstop = true //identify if less than two finger or finger out of picture,pinch don't update,wait pinch finish } else { if( (picFlick.imageFlag == true)&&(picFlick.image_ungif_States == true)) { scalenum = scalenum1*pinch.scale //scalenum1 mini is 1,max is 4,other tiaozheng scalenum wei zhengchangzhi if(((scalenum1 == 1)&&(scalenum < 1))||((scalenum1 == 4)&&(scalenum > 4))) { if(scalenum >= 4.0) { scalenum = 4.0 } if(scalenum < 1.0) { scalenum = 1.0 } } else { //naca no.58152 shuangzhi fangda tupian paofei wei heiping if(scalenum >= 4.0) { scalenum = 4.0 } if(scalenum < 1.0) { scalenum = 1.0 } //shangci he benci chayi guoxiao ze buchuli,fouze tiaozheng tupian if(((scalenum - pinch_area.tempscalenum) >= 0.001)||((pinch_area.tempscalenum - scalenum) >= 0.001)) { // console.log(" onPinchUpdated ``````````````````````````````scalenum="+scalenum) pinch_area.tempscalenum = scalenum ungif.width = picFlick.oldwidth*scalenum ungif.height = picFlick.oldheight*scalenum var contentDriftX = ((1-pinch.scale)*p1toC_X) var contentDriftY = ((1-pinch.scale)*p1toC_Y) picFlick.contentX = contentInitX-contentDriftX picFlick.contentY = contentInitY-contentDriftY if(ungif.width > (picFlick.oldwidth*4)||(ungif.width < picFlick.oldwidth)) { pinch.accepted = false } // console.log(" onPinchUpdated ``````````ungif.width="+ungif.width+"ungif.height"+ungif.height) } else { /*do nothing*/ } } } } } onPinchFinished: { pinchstop = false pinch.accepted = true // softkeyappear() // display_timer.running = true // USBControl1.usbCtrlImageDisplayTimerOn() // twoFingerCtrl = 0 if( (picFlick.imageFlag == true)&&(picFlick.image_ungif_States == true) ) { if(scalenum <= 1.0) { scalenum = 1.0 } if(scalenum >= 4.0) { scalenum = 4.0 } if(ungif.width >= iImageMaxWidth) { picFlick.contentX = picFlick.contentX - ungif.x ungif.x = 0 } else { ungif.x = (iImageMaxWidth - ungif.width)/2 picFlick.contentX = 0 } if(ungif.height >= iImageMaxHeight) { picFlick.contentY = picFlick.contentY - ungif.y ungif.y = 0 } else { ungif.y = (iImageMaxHeight - ungif.height)/2 picFlick.contentY = 0 } if(picFlick.contentX < 0) { picFlick.contentX = 0 } if((ungif.width >= iImageMaxWidth)&&(picFlick.contentX > (ungif.width - iImageMaxWidth))) { picFlick.contentX = ungif.width - iImageMaxWidth } if(picFlick.contentY < 0) { picFlick.contentY = 0 } if((ungif.height >= iImageMaxHeight)&&(picFlick.contentY > (ungif.height - iImageMaxHeight))) { picFlick.contentY = ungif.height - iImageMaxHeight } picFlick.interactive = true big_Grid_View.interactive = true } picFlick.imagetempindex = big_Grid_View.currentIndex big_Grid_View.currentIndex = big_Grid_View.indexAt(big_Grid_View.contentX,0) if(big_Grid_View.currentIndex != picFlick.imagetempindex) { settype = 2 setscale() scalenum = 1.0 } big_Grid_View.positionViewAtIndex(big_Grid_View.currentIndex,big_Grid_View.Beginning) updateIndex()//add by lium for 344450 20190724 // if (playstate == true) // { // bigview_menu.visible = true // big_gridview_Rec.menu_showing_flg = true // playstate = false // imageControl.bFullScreenFlag = false // } } HMIMouseArea { id: dragArea anchors.fill: parent onPressed: { USBControl1.usbCtrlImageTouchReleaseTimerOff() } onReleased: { // if( true == all_button_area.visible && false == nameSearch_keyBoard.visible ) // { // // console.log (" all_button_area.visible = false 2222"); // all_button_area.visible = false // button_timer.stop() // } // else // { // // console.log (" all_button_area.visible = true 2222"); // all_button_area.visible = true // button_timer.restart() // } } } } function ungifanalyze() { // console.log(" onPinchUpdated ``````````ungif.realheight="+ungif.realheight+"ungif.realwidth"+ungif.realwidth) if(ungif.realheight <= iImageMaxHeight) { if(ungif.realwidth <= iImageMaxWidth) { ungif.width = ungif.realwidth ungif.height = ungif.realheight } else { ungif.width = iImageMaxWidth ungif.height = ungif.width*ungif.realheight/ungif.realwidth } } else { if(ungif.realwidth <= iImageMaxWidth) { ungif.height = iImageMaxHeight ungif.width = ungif.height*ungif.realwidth/ungif.realheight } else { if(ungif.realwidth/ungif.realheight >= iImageMaxWidth/iImageMaxHeight) { ungif.width = iImageMaxWidth ungif.height = ungif.width*ungif.realheight/ungif.realwidth } else { ungif.height = iImageMaxHeight ungif.width = ungif.height*ungif.realwidth/ungif.realheight } } } ungif.x = (iImageMaxWidth - ungif.width)/2 ungif.y = (iImageMaxHeight - ungif.height)/2 picFlick.oldwidth = ungif.width picFlick.oldheight = ungif.height // console.log(" onPinchUpdated ``````````picFlick.width="+picFlick.oldwidth+"picFlick.height"+picFlick.oldheight) picFlick.oldx = ungif.x picFlick.oldy = ungif.y // console.log(" picFlick.oldx="+ picFlick.oldx+" picFlick.oldy="+ picFlick.oldy) } } } Item { id:big_gridview_Item x:0 y:105 //MOD Myf correct User_manual display problem width:960 height:970//1050 visible:true Rectangle { // width:768 // height:704 color: "white"//"black" //modify by lium 342445 342437 id:big_gridview_Rec anchors.fill:parent // anchors.verticalCenter: big_gridview_Item.verticalCenter // anchors.horizontalCenter: big_gridview_Item.horizontalCenter // property bool clickedFlag: false /* Image { id: picture_bg anchors.fill:parent source: bMaxWindow == true?"qrc:MATERIAL/MATERIAL_M8X_PICTURE+VIDEO_BG_FULL-SCREEN"+bgImageStyle:"qrc:MATERIAL/MATERIAL_M8X_PICTURE+VIDEO_BG"+bgImageStyle // source: bMaxWindow == true?"qrc:MATERIAL/MATERIAL_M8X_PICTURE_DEFAULT_FULL-SCREEN"+bgImageStyle:"qrc:MATERIAL/MATERIAL_M8X_PICTURE_DEFAULT"+bgImageStyle } */ GridView { id:big_Grid_View anchors.fill: parent cellWidth:big_gridview_Rec.width cellHeight:big_gridview_Rec.height model:USBControl1.manualimagemodel delegate: delegate clip: false //true smooth:false //true flow:GridView.TopToBottom focus: true snapMode : GridView.SnapOneRow boundsBehavior:Flickable.StopAtBounds //FOD review yx 20170208 begin cacheBuffer:50 //960 //960*3//5002*20 //FOD review yx 20170208 end onFlickStarted: { } onFlickEnded: { } onMovementStarted: { input_num_flag = false//add by lium for 340693 20190627 nameSearch_keyBoard.visible = false//add by lium for 340693 20190627 movingflag = true moveSatrtIndex = big_Grid_View.currentIndex USBControl1.usbCtrlImageTouchReleaseTimerOff() movingcompareindex = big_Grid_View.currentIndex moving_timer.running = true if(scalenum > 1) { movetoadjflag = true } // console.log (" onMovementStarted ="+big_Grid_View.currentIndex); } onMovementEnded: { if( true == movingflag ) { USBControl1.usbCtrlImageTouchReleaseTimerOff() movingflag = false movetoadjflag = false moving_timer.running = false big_Grid_View.currentIndex = big_Grid_View.indexAt(big_Grid_View.contentX,big_Grid_View.contentY) // if( (total_num -1) == big_Grid_View.currentIndex ) // { // total_num= total_num +10 // USBControl1.usbsetFileList_user_manual(total_num) // } if( big_Grid_View.currentIndex != moveSatrtIndex) { scale_reset() } // console.log (" onMovementEnded ="+big_Grid_View.currentIndex); } } onCurrentIndexChanged: { // console.log (" big_Grid_View.currentIndex ="+big_Grid_View.currentIndex); currentIndexforDisplay = big_Grid_View.currentIndex } } } } Item { id:all_button_area y:30 //ADD Myf correct User_manual display problem//modify by lium for 342444 20190718 Item//modify by lium for 342444 20190718 { x:0 y:0 width:960 height:78 //color:"black"//del by lium for 342444 20190718 MouseArea{ anchors.fill: parent onClicked: { // console.log(",,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, click ") } } } HMIButton { id:nameSearchBack_button x:0 y:5 width:190//138//modify by lium for 340567 20190620 height:70 visible: true //add by lium for 340567 20190620 begin Image { id:back_btn_image x:5 y:3 width: 50 height:64 anchors.verticalCenter:parent.verticalCenter source:nameSearchBack_button.pressed?"qrc:MATERIAL/MATERIAL_ICON_BACK_P"+bgImageStyle:"qrc:MATERIAL/MATERIAL_ICON_BACK"+bgImageStyle } //add by lium for 340567 20190620 end HMILabel { id:fanhui x: 54//46//40//modify by lium 20190620 y: 1//0 width: 138//90//modify by lium 20190620 height: 70 text:"Back" font.pixelSize: 30 wtitesize:0 anchors.verticalCenter:parent.verticalCenter//add by lium for 340567 20190620 horizontalAlignment: Text.AlignLeft//add by lium for 340567 20190620 } //btnImg:nameSearchBack_button.pressed?"qrc:MATERIAL/MATERIAL_M8X_BACK_BUTTON_P"+bgImageStyle:"qrc:MATERIAL/MATERIAL_M8X_BACK_BUTTON"+bgImageStyle//del by lium for 340567 20190620 Image { x: 20 y: 18 width:20 height:34 source:"qrc:MATERIAL/MATERIAL_M8X_ICON_BACK"+bgImageStyle } onClicked: { // ScreenManager.changeForm(Layout.FM_CLOSE,WindowsList.USER_MANUAL) ScreenManager.hideOverlay(WindowsList.USER_MANUAL) } } Image//modify by lium for 342444 20190718 { id:input_background x: 260//330 y: 5 width:300 height:70 //color: "#101010" //Hexadecimal//del by lium for 342444 20190718 source: "qrc:MATERIAL/MATERIAL_INPUT_70_W300"+bgImageStyle//add by lium for 342444 20190718 MouseArea { anchors.fill: parent onClicked: { input_num_flag = true if(false == nameSearch_keyBoard.visible ) { nameSearch_keyBoard.visible = true } } } } HMILabel { id: indexcurt x:(input_background.x+70)//400//396 y:23 width:80 height:36 text:(0 == total_num)?"0"+systemCtrl.emptyString:currentIndexforDisplay+1 font.pixelSize: 30 horizontalAlignment: Label.AlignRight visible: !input_num_flag wtitesize:1 color: "#656565" } HMILabel { id:of x:(input_background.x+150)//480//476 y:23 width:8 height:36 text:"/" font.pixelSize: 30 visible:!input_num_flag wtitesize:1 color: "#656565" } HMILabel { id: indextotal x:(input_background.x+158)//488//484 y:23 width:80 height:36 text:total_num font.pixelSize: 30 horizontalAlignment: Label.AlignLeft visible:!input_num_flag wtitesize:1 color: "#656565" } TextInput { id: nameSearchInput x: input_background.x anchors.verticalCenter: input_background.verticalCenter width: 300 height: 70 font.pixelSize: 30//24 readOnly: false enabled: true clip: true horizontalAlignment: TextInput.AlignHCenter //Text.AlignLeft verticalAlignment: Text.AlignVCenter text:"" color:"white" //"#130f0f" maximumLength: 3 cursorVisible:true selectedTextColor:"white" //"#676767" selectionColor: "#676767" font.family:"Montserrat" cursorDelegate:mCursorDelegate visible: input_num_flag Component { id:mCursorDelegate Rectangle { id:mCursorRectangle color: "white" height: nameSearchInput.cursorRectangle.height width: nameSearchInput.cursorRectangle.width Timer { running: true repeat: true interval: 800 onTriggered: { mCursorRectangle.visible = ! mCursorRectangle.visible // console.log(",,,,,,,,,,,cursorPosition="+nameSearchInput.cursorPosition) } } } } Label { id:nameSearchLable x:(nameSearchInput.contentWidth>nameSearchInput.width)?0-(nameSearchInput.contentWidth-nameSearchInput.width):0 y:0 height: 70 width: 842 text:nameSearchInput.text font.family:"Montserrat" //add lqy for 325925 color: "white" font.pixelSize: 30 horizontalAlignment: Label.AlignHCenter //Label.AlignLeft AlignHCenter verticalAlignment: Label.AlignVCenter } onCursorPositionChanged: { if(nameSearchInput.text.length == 3) { // keyBoard.maximumState = true } else if(nameSearchInput.text.length < 3) { // keyBoard.maximumState = false } } HMIMouseArea{ anchors.fill: parent onClicked: { systemCtrl.pinyinsreachclear() nameSearchInput.cursorPosition = nameSearchInput.positionAt(mouseX,mouseY) if(false == nameSearch_keyBoard.visible ) { nameSearch_keyBoard.visible = true // bKeyboardVisiable = true } // if(handWrite.visible==true) // bhandwritebar=true // if(keyBoard.visible==true) // bhandwritebar=false // if(handWrite.changecanvas==false) // handWrite.changecanvas=true } onDoubleClicked: { nameSearchInput.selectAll() } } } // Rectangle // { // id:jump_to_button_bg // anchors.fill: jump_to_button // color:"black" // } HMIButton { id:jump_to_button x:562 y:5 width:138 height:70 visible: true HMILabel { id:jump_to text:"Go" width:138 height:70 font.pixelSize: 30 anchors.horizontalCenter: parent.horizontalCenter anchors.verticalCenter: parent.verticalCenter anchors.horizontalCenterOffset:1 anchors.verticalCenterOffset:2 // horizontalAlignment: Label.AlignHCenter // verticalAlignment: Label.AlignVCenter wtitesize:0 // font.family:"方正兰亭黑简体" } btnImg:jump_to_button.pressed?"qrc:MATERIAL/MATERIAL_GOTO_BUTTON_P"+bgImageStyle:"qrc:MATERIAL/MATERIAL_GOTO_BUTTON"+bgImageStyle//user manual change//modify by lium for 342444 20190718 onClicked: { if(nameSearchInput.text > 0 && nameSearchInput.text <= total_num ) { big_Grid_View.cancelFlick() if(scalenum > 1) { scalenum = 1 settype = 2 setscale() } big_Grid_View.currentIndex = (nameSearchInput.text-1) big_Grid_View.contentX = big_Grid_View.currentIndex*big_gridview_Rec.width nameSearchInput.text = "" nameSearch_keyBoard.visible = false input_num_flag = false // button_timer.restart() } else { // console.log("nameSearchInput.text out range ") } } } HMIButton { id:contents_button x:822 y:5 width:138 height:70 visible: true //add by lium for 344451 20190724 begin Image { id: contents_button_image anchors.fill: parent source: contents_button.pressed?"qrc:MATERIAL/MATERIAL_GOTO_BUTTON_P"+bgImageStyle:"qrc:MATERIAL/MATERIAL_GOTO_BUTTON"+bgImageStyle //onSourceChanged: //{ //console.log(" onSourceChanged 11111111111111111") //} } //add by lium for 344451 20190724 end HMILabel { id:contents text:"Index" width:138 height:70 font.pixelSize: 30 anchors.horizontalCenter: parent.horizontalCenter anchors.verticalCenter: parent.verticalCenter anchors.horizontalCenterOffset:1 anchors.verticalCenterOffset:2 wtitesize:0 } //btnImg:contents_button.pressed?"qrc:MATERIAL/MATERIAL_GOTO_BUTTON_P"+bgImageStyle:"qrc:MATERIAL/MATERIAL_GOTO_BUTTON"+bgImageStyle//user manual change//modify by lium for 342444 20190718//del by lium for 344451 20190724 //add by lium for 344451 20190724 begin onPressed: { //console.log("~~~~~~~~~~contents_button,onPressed",Qt.formatDateTime(new Date(),"yyyy-MM-dd hh:mm:ss.zzz")) contents_button_image.source = "qrc:MATERIAL/MATERIAL_GOTO_BUTTON_P"+bgImageStyle } onReleased: { //console.log("~~~~~~~~~~contents_button,onReleased",Qt.formatDateTime(new Date(),"yyyy-MM-dd hh:mm:ss.zzz")) contents_button_image.source = "qrc:MATERIAL/MATERIAL_GOTO_BUTTON"+bgImageStyle } //add by lium for 344451 begin onCanceled: { contents_button_image.source = "qrc:MATERIAL/MATERIAL_GOTO_BUTTON"+bgImageStyle } //add by lium for 344451 end //add by lium for 344451 20190724 end onClicked: { if(total_num > 0) { big_Grid_View.cancelFlick() if(scalenum > 1) { scalenum = 1 settype = 2 setscale() } moving_timer.running = true//add by lium for 342447 20190708 big_Grid_View.currentIndex = 0 big_Grid_View.contentX = big_Grid_View.currentIndex*big_gridview_Rec.width nameSearchInput.text = "" nameSearch_keyBoard.visible = false input_num_flag = false } } } } Item { id:nameSearch_keyBoard y: 677 //MOD Myf correct User_manual display problem visible: true onVisibleChanged: { if (nameSearch_keyBoard.visible == true) { } } Rectangle{ id:keyBoard_bg width: 960 height: 400 color: "black" // anchors.fill: parent } Item{ id: keyBoard width:960 height: 400 MouseArea { anchors.fill: parent } Column{ id: keyboardColumn Item{ id:keyRowItem width: 960 height: 400 Row { id:firstRow anchors{top:parent.top;topMargin:0;horizontalCenter: parent.horizontalCenter} Image { width: 96*9 source:("qrc:MATERIAL/MATERIAL_M8X_CANDIDATE-KEY_BG"+style) } HMIKeyBtn { id:closeKeyboard Image { id: closeKeyboardicon anchors.horizontalCenter: closeKeyboard.horizontalCenter y:28 source: "qrc:MATERIAL/MATERIAL_M8X_ARROW_RETRACT"+style } onClicked: { nameSearch_keyBoard.visible = false // button_timer.restart() } } } Row{ id: secondRow x:1 anchors{top:firstRow.bottom;topMargin:2;horizontalCenter: parent.horizontalCenter} spacing: 2 Repeater{ model: ["1","2","3","4","5","6","7","8","9","0"] HMIKeyBtn{ id:secondRowKey; labelText:qsTr(modelData); labelSize:30 cursize: 1 labelPixelSize:28 onPressed: { if(nameSearchInput.text.length == nameSearchInput.cursorPosition) { if(nameSearchInput.text.length < 3) { if( 0 == nameSearchInput.cursorPosition) { the_one_text = modelData } else if( 1 == nameSearchInput.cursorPosition) { the_two_text = modelData } else if( 2 == nameSearchInput.cursorPosition) { the_three_text = modelData } } nameSearchInput.text =nameSearchInput.text+modelData } else if(nameSearchInput.text.length < 3) { if(0 == nameSearchInput.cursorPosition) { the_three_text = the_two_text the_two_text = the_one_text the_one_text = modelData nameSearchInput.text= modelData+ nameSearchInput.text nameSearchInput.cursorPosition = 1 } else if(1 == nameSearchInput.cursorPosition) { nameSearchInput.text= the_one_text+ modelData + the_two_text the_three_text = the_two_text the_two_text = modelData nameSearchInput.cursorPosition = 2 } } } } } } Row{ id: thirdRow anchors{top:secondRow.bottom;topMargin: 2} x:49 spacing: 2 Repeater{ model: ["-","/",":",";","(",")","!","《","》"] HMIKeyBtn{ id:thirdRowKey; labelSize:30 labelPixelSize:30 cursize: 1 labelText: qsTr(modelData); labelColor:iNum?"#424242":"white" enabled:iNum?false:true onPressed: { } } } } Row{ id:fourRow anchors{top:thirdRow.bottom;topMargin: 2} x:secondRow.x spacing: 2 HMIKeyBtn{ id:shift labelText: iType==3?"#+=":"" labelSize:30 z:1 cursize: 1 labelPixelSize:30 width:142 height:78 labelColor:iNum?"#424242":"white" enabled:iNum?false:true btnImg:shift.pressed?("qrc:MATERIAL/MATERIAL_M8X_KEYBOARD_BUTTON_H142_P"+style):("qrc:MATERIAL/MATERIAL_M8X_KEYBOARD_BUTTON_H142"+style) onClicked: { } } Repeater{ model: ["、","_","•","?",",","\“","\”"] HMIKeyBtn{ id:fourRowKey; cursize: 1 labelSize:30 labelPixelSize:30 labelText: { if(modelData=="、") { "" }else if(modelData=="?") { "" } else{ qsTr(modelData) } } labelColor:iNum?"#424242":"white" enabled:iNum?false:true HMILabel{ id:dian x:43 y:35 anchors.horizontalCenter: parent.horizontalCenter width: iLanguage==0?25:20//FOD #159147 2017/3/21 ld height: iLanguage==0?28:25 visible: modelData=="?" color: iNum?"#424242":"white" enabled:iNum?false:true text:qsTr("?") } HMILabel{ id:dunhao x:43 y:28 width: iLanguage==0?25:20//FOD #159147 2017/3/21 ld height: iLanguage==0?28:25 visible: modelData=="、" color: iNum?"#424242":"white" enabled:iNum?false:true text:qsTr("、") } onPressed: { } } } HMIKeyBtn { id:deleteKey labelSize:28 labelPixelSize:28 width:142 height:78 btnImg:deleteKey.pressed?("qrc:MATERIAL/MATERIAL_M8X_KEYBOARD_BUTTON_H142_P"+style):("qrc:MATERIAL/MATERIAL_M8X_KEYBOARD_BUTTON_H142"+style) Image { id:deleteImage anchors.centerIn: parent source:"qrc:MATERIAL/MATERIAL_M8X_ICON_DELETE"+style } onPressAndHold: { nameSearchInput.text="" the_one_text = "" the_two_text = "" the_three_text = "" } onClicked: { if( "" != nameSearchInput.selectedText) { nameSearchInput.text="" the_one_text = "" the_two_text = "" the_three_text = "" // console.log(" deleteKey onClicked 000") } else if(nameSearchInput.text.length == nameSearchInput.cursorPosition) { if( 3 == nameSearchInput.cursorPosition) { nameSearchInput.text = the_one_text + the_two_text the_three_text = "" } else if( 2 == nameSearchInput.cursorPosition) { nameSearchInput.text = the_one_text the_two_text = "" } else if( 1 == nameSearchInput.cursorPosition) { nameSearchInput.text ="" the_one_text = "" } } else { if(2 == nameSearchInput.cursorPosition) { nameSearchInput.text= the_one_text + the_three_text the_two_text = the_three_text the_three_text = "" nameSearchInput.cursorPosition = 1 } else if(1 == nameSearchInput.cursorPosition) { nameSearchInput.text= the_two_text+ the_three_text the_one_text = the_two_text the_two_text = the_three_text the_three_text = "" nameSearchInput.cursorPosition = 0 } } } } } Row{ id:fiveRow anchors{top:fourRow.bottom;topMargin: 2} x:fourRow.x spacing: 2 HMIKeyBtn{ id:shouxie labelText:(iType==3)?"ABC":"123" labelSize:30 labelPixelSize:30 width:142 height:78 labelColor:iNum?"#424242":"white" enabled:iNum?false:true btnImg:shouxie.pressed?("qrc:MATERIAL/MATERIAL_M8X_KEYBOARD_BUTTON_H142_P"+style):("qrc:MATERIAL/MATERIAL_M8X_KEYBOARD_BUTTON_H142"+style) onClicked: { } } HMIKeyBtn{ id:pinyin labelSize:30 labelPixelSize:30 width:142 height:78 labelColor: iNum?"#424242":"white" enabled:iNum?false:true btnImg:pinyin.pressed?("qrc:MATERIAL/MATERIAL_M8X_KEYBOARD_BUTTON_H142_P"+style):("qrc:MATERIAL/MATERIAL_M8X_KEYBOARD_BUTTON_H142"+style) HMILabel{ id:englishlabel anchors.centerIn: parent width: 180 height:35 wtitesize:1 visible: true color: iNum?"#424242":"white" text:(qsTr("English")+systemCtrl.emptyString) font.pixelSize:30 } onClicked: { } } HMIKeyBtn{ id:ctrlKey; labelBold : false labelPixelSize : 30 enabled:iNum?false:true height:78 btnImg: { ctrlKey.pressed?("qrc:MATERIAL/MATERIAL_M8X_KEYBOARD_SPACE_BUTTON_W526_P"+style):("qrc:MATERIAL/MATERIAL_M8X_KEYBOARD_SPACE_BUTTON_W526"+style) } Image { id: ctrlKeyicon anchors.horizontalCenter: ctrlKey.horizontalCenter y:ctrlKey.y+34 source: iNum?("qrc:MATERIAL/MATERIAL_M8X_ICON_SPACE_D"+style):("qrc:MATERIAL/MATERIAL_M8X_ICON_SPACE"+style)//FOD #150435 2017/2/20 ld } onPressed:str = qsTr(""); onClicked: { } } HMIButton{ id:confirm x:ctrlKey.x+2 width:142 height:78 labelPixelSize:30//FOD design 2017/1/10 ld btnImg:confirm.pressed?("qrc:MATERIAL/MATERIAL_M8X_KEYBOARD_BUTTON_H142_P"+style):("qrc:MATERIAL/MATERIAL_M8X_KEYBOARD_BUTTON_H142"+style) visible: true enabled: true HMILabel { anchors.centerIn: parent width: 180 height:35 wtitesize:1 text:qsTr("OK")+systemCtrl.emptyString font.pixelSize:30 } onClicked:{ if(nameSearchInput.text > 0 && nameSearchInput.text <= total_num) { if(scalenum > 1) { scalenum = 1 settype = 2 setscale() } big_Grid_View.currentIndex = (nameSearchInput.text-1) big_Grid_View.contentX = big_Grid_View.currentIndex*big_gridview_Rec.width nameSearchInput.text = "" nameSearch_keyBoard.visible = false input_num_flag = false // button_timer.restart() } else { ScreenManager.showOverlay(WindowsList.USERMANUAL_ERROR)//add by lium for 340695 20190628 // console.log("nameSearchInput.text out range ") } } } } } } } } Image { id:hlineimg visible: true y:0 // height: 2 //source:"qrc:MATERIAL/MATERIAL_M8X_LINE_SPLIT-SCREEN_H2" + bgImageStyle;//del by lium 20180926 } // Timer{ // id:button_timer // interval: 3000 // running: false // onTriggered: { // if( true == all_button_area.visible) // { // if( false == nameSearch_keyBoard.visible ) // { // all_button_area.visible = false // } // } // } // } //add by lium for 344450 20190724 begin function updateIndex() { //console.log(" updateIndex movetoadjflag ="+movetoadjflag) //console.log(" updateIndex ---- "+big_Grid_View.contentX/big_gridview_Rec.width) //console.log(" updateIndex ---- "+big_Grid_View.contentX) //console.log(" updateIndex ---- "+big_gridview_Rec.width) movingcurtindex = big_Grid_View.contentX/big_gridview_Rec.width //console.log(" updateIndex ---- movingcurtindex ="+movingcurtindex) //console.log(" updateIndex ---- movingcompareindex ="+movingcompareindex) if(movingcurtindex != movingcompareindex) { currentIndexforDisplay = movingcurtindex console.log(" updateIndex ---- currentIndexforDisplay="+currentIndexforDisplay) movingcompareindex = movingcurtindex } } //add by lium for 344450 20190724 end Timer { id:moving_timer interval: 200 running: false repeat: true onTriggered: { movingcurtindex = big_Grid_View.contentX/big_gridview_Rec.width if(movingcurtindex != movingcompareindex) { currentIndexforDisplay = movingcurtindex movingcompareindex = movingcurtindex if(movetoadjflag == true) { scalenum = 1 settype = 2 setscale() movetoadjflag = false } } } } Connections { target:USBControl1 onUsbImageTouchReleaseTimerOut: { // console.log(",,,,,,,,, onUsbImageTouchReleaseTimerOut .......") if(allreleasecontentx == big_Grid_View.contentX) { big_Grid_View.visible = false big_Grid_View.visible = true } } } Connections { target: systemCtrl onTouchRelase: { // console.log(",,,,,,,,,onTouchRelase .......") if(true == movingflag && big_Grid_View.contentX%960 != 0) { allreleasecontentx = big_Grid_View.contentX USBControl1.usbCtrlImageTouchReleaseTimerOn() } //add by liuming for 340569 20190621 begin if(nameSearchBack_button.pressed) { console.log("onTouchRelase ………………………… ^^^^ nameSearchBack_button.pressed") //back_btn_image.source = "qrc:MATERIAL/MATERIAL_ICON_BACK"+bgImageStyle ScreenManager.hideOverlay(WindowsList.USER_MANUAL) } //add by liuming for 340569 20190621 end //add by liuming for 344451 20190723 begin if(contents_button.pressed) { console.log("onTouchRelase ………………………… ^^^^ contents_button.pressed",Qt.formatDateTime(new Date(),"yyyy-MM-dd hh:mm:ss.zzz")) if(total_num > 0) { big_Grid_View.cancelFlick() if(scalenum > 1) { scalenum = 1 settype = 2 setscale() } moving_timer.running = true//add by lium for 342447 20190708 big_Grid_View.currentIndex = 0 big_Grid_View.contentX = big_Grid_View.currentIndex*big_gridview_Rec.width nameSearchInput.text = "" nameSearch_keyBoard.visible = false input_num_flag = false } //console.log("onTouchRelase ………………………… ^^^^ contents_button.pressed 1",Qt.formatDateTime(new Date(),"yyyy-MM-dd hh:mm:ss.zzz")) contents_button_image.source = "qrc:MATERIAL/MATERIAL_GOTO_BUTTON"+bgImageStyle //add by liuming for 344451 20190723 end } } } /*Connections //del by lium 20190704 begin { target:vrCtrl onVrSourceStartSignal: { if(true == ScreenManager.isOverlayShowed(WindowsList.USER_MANUAL)) { // console.log(",,,,,,,,,,,,,,,,,,,,,,,, hideOverlay 666") ScreenManager.hideOverlay(WindowsList.USER_MANUAL) } } }*/ //del by lium 20190704 end }