Better swecast support. Refactorings.