Qt利用QDir::drives获取磁盘盘符列表的代码
foreach (QFileInfo my_info, QDir::drives()){
qDebug()<<my_info.absoluteFilePath();
}