port endSessionDialog.js to gdbus