True. In the second sentence "you" is the subject and"what" is the object.

Compare: Who saw you? Who = subject, you = object. Who did you see? Who = object, you = subject.