Fixed UILIB_1 to use DLI_Base and other misc refactoring.