Can not open source input file mbed.h : No such file or directory
This generally means you have somehow deleted the mbed library from your project.
Add it again by clicking on the "Import latest build" button on this page: http://mbed.org/users/mbed_official/code/mbed/builds/
Can not open source input file device.h : No such file or directory
This generally means that the version of the mbed library in your project does not support the selected device in the top right corner of the Online IDE.
Update your mbed library to the latest version by selecting it and clicking on the "Update" button in the right "Build Details" panel.