Trayvon Martin was a free citizen of the United States of America and an invited guest at a residence in that gated community. He was under no obligation to walk or appear to walk in any particular manner toward any location purposefully or casually.
He was a free person and was not obligated to appear as if he was going anywhere. GZ had no right to impose his will onto another free person but he chose to anyway. It seems to be a pattern with that guy.
GZ also can go anywhere he wants to, as he is living in that gated community. He can also ask people questions, there is no law that says he can't.