+ borrow dialog and some minor changes