How do you loop through all assets in a folder, selected from EditorUtility.OpenFolderPanel?

Select a folder with EditorUtility.OpenFolderPanel, then get references to all the files therein. How?

Maybe you need this?

foreach (Object o in Selection.GetFiltered(typeof (Object), SelectionMode.DeepAssets))

Actually I’m searching for a another problem which similar to your question, How to get all assets in a path string. But I just find this one.

foreach (var m in AssetDatabase.GetAllAssetPaths()) {
var objs = AssetDatabase.LoadAllAssetsAtPath(m);
}

Intrestingly GetAllAssetPaths is not documented in reference.