module CSwingOffPermissionVariables use CVoidEventHandlerCollection implicit none logical :: SwingOffPermission = .false. public type(VoidEventHandlerCollection) :: OnSwingOffPermissionChange private :: SwingOffPermission contains subroutine Set_SwingOffPermission(v) implicit none logical , intent(in) :: v #ifdef ExcludeExtraChanges if(SwingOffPermission == v) return #endif SwingOffPermission = v #ifdef deb print*, 'SwingOffPermission=', SwingOffPermission #endif call OnSwingOffPermissionChange%RunAll() end subroutine logical function Get_SwingOffPermission() implicit none Get_SwingOffPermission = SwingOffPermission end function subroutine Set_SwingOffPermission_WN(v) !DEC$ ATTRIBUTES DLLEXPORT :: Set_SwingOffPermission_WN !DEC$ ATTRIBUTES ALIAS: 'Set_SwingOffPermission_WN' :: Set_SwingOffPermission_WN implicit none logical , intent(in) :: v call Set_SwingOffPermission(v) end subroutine logical function Get_SwingOffPermission_WN() !DEC$ ATTRIBUTES DLLEXPORT :: Get_SwingOffPermission_WN !DEC$ ATTRIBUTES ALIAS: 'Get_SwingOffPermission_WN' :: Get_SwingOffPermission_WN implicit none Get_SwingOffPermission_WN = SwingOffPermission end function end module CSwingOffPermissionVariables