[mod] Moved main view code into fragment.