modify some detail alth on function download
add method togglePageState,isUsed,connect on lib_db,no test yet