import QtQuick 2.0 import "../com/neusoft/auto/widgets" import "coordinate.js" as CONFIG import "FuncList.js" as Func import "../windowsList.js" as WindowsList import "../layoutList.js" as Layout import Label 2.0 HMIWindow { id:reminder_root // property bool isPageFullScr: reminderCtrl.isMainPageFullScr // property double expantnummain: 1.25 // property bool isEvtListClicked: mEvtManage.isEvtListOfSelDateClicked Component.onCompleted: { console.log("***********************************reminder_root onCompleted***********************************") windowID = WindowsList.RMD_MAIN } onVisibleChanged: { bFullWindow = true bNoSwitchBarVisiable = true calendar.yearlistshow=false calendar.yearlistback=false calendar.monthlistshow=false calendar.monthlistback=false // ScreenManager. hideOverlay (WindowsList.RMD_LIST_MASK) // default state is [full body] state add by wsl 2016.4.5 // ScreenManager.changeForm(Layout.FM_MAXIMIZE,windowID); } onMaxWindow :{ console.log("***********************************onMaxWindow***********************************") reminderCtrl.isMainPageFullScr = bMaxWindow; // bMainWindow = false; } onMinWindow :{ console.log("***********************************onMinWindow***********************************") // reminderCtrl.isMainPageFullScr = bMaxWindow; } MouseArea{ anchors.fill: parent visible:calendar.yearlistshow||calendar.yearlistback||calendar.monthlistshow||calendar.monthlistback propagateComposedEvents:true onPressed: { calendar.yearlistshow = false; calendar.yearlistback = false; calendar.monthlistshow = false; calendar.monthlistback = false; // ScreenManager. hideOverlay (WindowsList.RMD_LIST_MASK) mouse.accepted=false } } HMICalendar{ id: calendar x: 57//(CONFIG.CALENDAR_LAYOUT_XY[0]-CONFIG.HMIWINDOW_LAY_XY[0])*expantnum y: 39//(CONFIG.CALENDAR_LAYOUT_XY[1]-CONFIG.HMIWINDOW_LAY_XY[1])*expantnum anchors.horizontalCenter: parent.horizontalCenter } // EvtListOfSelDate{ // id: evtListOfSelDate // x: (26-CONFIG.HMIWINDOW_LAY_XY[0])*expantnummain // y: (190-CONFIG.HMIWINDOW_LAY_XY[1])*expantnummain // } //4.5 // Item // { // id:toolBoxBg // x: CONFIG.TOOL_BOX_LAY_XY[0]-CONFIG.HMIWINDOW_LAY_XY[0] // y: isPageFullScr?(CONFIG.TOOL_BOX_LAY_XY[2]-CONFIG.HMIWINDOW_LAY_XY[1]):(CONFIG.TOOL_BOX_LAY_XY[1]-CONFIG.HMIWINDOW_LAY_XY[1]) // width: CONFIG.TOOL_BOX_WIDTH // height: CONFIG.TOOL_BOX_HEIGTH // HMIButton // { // id: btnEdit // x:CONFIG.ONE_BTN_LAY_XY[0] // y:CONFIG.ONE_BTN_LAY_XY[1] // enabled: (isPageFullScr&&mEvtManage.isEvtListOfShowingClicked)?true:false // opacity: (isPageFullScr&&mEvtManage.isEvtListOfShowingClicked)?1:0 // btnImg: btnEdit.pressed ? "qrc:MATERIAL/MATERIAL_M8X_FUNCTION_BUTTON_3_P"+ bgImageStyle : "qrc:MATERIAL/MATERIAL_M8X_FUNCTION_BUTTON_3"+ bgImageStyle // HMILabel // { // id: editLable // width: parent.width // height: parent.height // anchors.horizontalCenter: parent.horizontalCenter // anchors.verticalCenter: parent.verticalCenter // font.pixelSize: CONFIG.REMINDER_BTN_FONT_SIZE // text:qsTr("edit") + systemCtrl.emptyString // color:CONFIG.REMINDER_BTN_LABEL_FONT_COLOR // } // onClicked: // { // console.log("[HMIReminder_Main][btnEdit][onClicked]") // if(mEvtManage.GetCntOfEvtListOfSelectedDate() > 0) // { // mEvtManage.is_newEvtQMLOperIsAdd_notEdit = false; // reminderCtrl.setIsNewEvtPageFullScr(true); // ScreenManager.changeForm(Layout.FM_OPEN,WindowsList.RMD_NEW_EVT) // } // } // } // HMIButton // { // id: btnDel // x: CONFIG.TWO_BTN_LAY_XY[0] // y: CONFIG.TWO_BTN_LAY_XY[1] // enabled: (isPageFullScr&&mEvtManage.isEvtListOfShowingClicked)?true:false // opacity: (isPageFullScr&&mEvtManage.isEvtListOfShowingClicked)?1:0 // btnImg: btnDel.pressed ? "qrc:MATERIAL/MATERIAL_M8X_FUNCTION_BUTTON_3_P"+ bgImageStyle : "qrc:MATERIAL/MATERIAL_M8X_FUNCTION_BUTTON_3"+ bgImageStyle // HMILabel // { // id: delLable // width: parent.width // height: parent.height // anchors.horizontalCenter: parent.horizontalCenter // anchors.verticalCenter: parent.verticalCenter // font.pixelSize: CONFIG.REMINDER_BTN_FONT_SIZE // text:qsTr("delete") + systemCtrl.emptyString // color:CONFIG.REMINDER_BTN_LABEL_FONT_COLOR // } // onClicked: // { // console.log("[HMIReminder_Main][btnDel][onClicked]") // if(mEvtManage.GetCntOfEvtListOfSelectedDate() > 0) // { // mEvtManage.delEvtFromDB(mEvtManage.getSelEvtInEvtListOfShowingMonth()) // } // } // } // HMIButton // { // id: btnAddEvt // x:(isPageFullScr&&mEvtManage.isEvtListOfShowingClicked)?CONFIG.ADD_EVT_BTN_LAY_XY[0]:CONFIG.ADD_EVT_BTN_LAY_XY[1] // y:CONFIG.ADD_EVT_BTN_LAY_XY[0] // enabled: isPageFullScr?true:false // opacity: isPageFullScr?1:0 // anchors.verticalCenter: parent.verticalCenter // btnImg: btnAddEvt.pressed ? "qrc:MATERIAL/MATERIAL_M8X_FUNCTION_BUTTON_1_P"+ bgImageStyle : "qrc:MATERIAL/MATERIAL_M8X_FUNCTION_BUTTON_1"+ bgImageStyle // onClicked: // { // console.log("[HMIReminder_Main][btnAddEvt][onClicked]") // mEvtManage.is_newEvtQMLOperIsAdd_notEdit = true; // reminderCtrl.setIsNewEvtPageFullScr(isPageFullScr) // ScreenManager.changeForm(Layout.FM_OPEN,WindowsList.RMD_NEW_EVT) // } // } // Image // { // x:(isPageFullScr&&mEvtManage.isEvtListOfShowingClicked)?CONFIG.ADD_IMG_LAY_XY[0]:CONFIG.ADD_IMG_LAY_XY[1] // y:CONFIG.ADD_IMG_LAY_XY[2] // visible: isPageFullScr?true:false // source: CONFIG.ADD_IMG+bgImageStyle // } // } /*========================================Connections Start===========================================*/ // Connections // { // target: evtListOfSelDate // onCurIndexChanged: // { // console.log("[Reminder_Main][onCurrentIndexChanged]-->") // if(reminderCtrl.isMainPageFullScr){ // if(mEvtManage.GetCntOfEvtListOfSelectedDate() > 0){ // console.log("[Reminder_Main][onCurrentIndexChanged]-->listCurIndex:",evtListOfSelDate.listCurIndex) // //selectedDateLable.text = CONFIG.getFormatDateString(mEvtManage.getEvtStartDateInShowingMonthListBy(evtListOfSelDate.listCurIndex)); // } // } // } // } /*========================================Connections End=============================================*/ /*========================================Function Start==============================================*/ /*========================================Function End================================================*/ }