In theory yes, the salary is a function of the skills. But in practice those skills have sublevels, so two players who show exactly the same skill levels will have different skill sublevels, and thus slightly different salaries.
And in addition to that, the salary is based on the skill levels at the time of the offseason update, so if one player has been trained and the other has not, and they have identical skills now, the one who has been trained will have had lower skills at the update and will therefore have a lower salary this season.