; ======================================================== ; This file was generated by NSISDialogDesigner 1.1.3.0 ; http://coolsoft.altervista.org/nsisdialogdesigner ; ======================================================== ; handle variables Var hCtl_PABCWorkNETDriveChoose Var hCtl_PABCWorkNETDriveChoose_DirRequest1_Txt Var hCtl_PABCWorkNETDriveChoose_DirRequest1_Btn Var hCtl_PABCWorkNETDriveChoose_Label1 ; dialog create function Function fnc_PABCWorkNETDriveChoose_Create ; === PABCWorkNETDriveChoose (type: Dialog) === nsDialogs::Create 1018 Pop $hCtl_PABCWorkNETDriveChoose ${If} $hCtl_PABCWorkNETDriveChoose == error Abort ${EndIf} !insertmacro MUI_HEADER_TEXT $(DESC_PABCWORK) $(DESC_PABCWORK_CHOOSE) ; === DirRequest1_Txt (type: Text) === ${NSD_CreateText} 8u 45u 110u 11u "" Pop $hCtl_PABCWorkNETDriveChoose_DirRequest1_Txt ${NSD_SetText} $hCtl_PABCWorkNETDriveChoose_DirRequest1_Txt "$PABCWorkNETPath" ${NSD_OnChange} $hCtl_PABCWorkNETDriveChoose_DirRequest1_Txt fnc_hCtl_PABCWorkNETDriveChoose_DirRequest1_Change ; === DirRequest1_Btn (type: Button) === ${NSD_CreateButton} 120u 45u 20u 11u "..." Pop $hCtl_PABCWorkNETDriveChoose_DirRequest1_Btn ${NSD_OnClick} $hCtl_PABCWorkNETDriveChoose_DirRequest1_Btn fnc_hCtl_PABCWorkNETDriveChoose_DirRequest1_Click ; === Label1 (type: Label) === ${NSD_CreateLabel} 8u 30u 158u 13u $(DESC_PABCWORK_Path) Pop $hCtl_PABCWorkNETDriveChoose_Label1 FunctionEnd Function SetPABCWorkNETPath IfFileExists "$INSTDIR\pabcworknet.ini" 0 +5 FileOpen $4 "$INSTDIR\pabcworknet.ini" r FileRead $4 $PABCWorkNETPath FileClose $4 Goto exitpath Push "C:\PABCWork.NET" Pop $PABCWorkNETPath exitpath: FunctionEnd ; dialog show function Function fnc_PABCWorkNETDriveChoose_Show Call SetPABCWorkNETPath Call fnc_PABCWorkNETDriveChoose_Create nsDialogs::Show $hCtl_PABCWorkNETDriveChoose FunctionEnd Function fnc_hCtl_PABCWorkNETDriveChoose_DirRequest1_Change Pop $R0 ${NSD_GetText} $hCtl_PABCWorkNETDriveChoose_DirRequest1_Txt $R0 Push $R0 Call PABCWorkNET_Path_Changed FunctionEnd ; onClick handler for DirRequest Button $hCtl_PABCWorkNETDriveChoose_DirRequest1_Btn Function fnc_hCtl_PABCWorkNETDriveChoose_DirRequest1_Click Pop $R0 ${If} $R0 == $hCtl_PABCWorkNETDriveChoose_DirRequest1_Btn ${NSD_GetText} $hCtl_PABCWorkNETDriveChoose_DirRequest1_Txt $R0 nsDialogs::SelectFolderDialog /NOUNLOAD "" "$R0" Pop $R0 ${If} "$R0" != "error" ${NSD_SetText} $hCtl_PABCWorkNETDriveChoose_DirRequest1_Txt "$R0" ${EndIf} ${EndIf} FunctionEnd