Implemented preview and handler thread inside desired fragment.