As Qwertyfly...​ mentioned if the Object is Group the Gradient will be applied to each object in the group, if the object is a compound path the gradient will be applied to fill the entire object ( to convert to compound path: object -> compound path-> make : ctrl + 8) below is a screenshot describes Group vs compound path )
... View more