some refactorings to clear dependencies from swing packages