 Bolesław's will divided Poland into several princedoms, with one of his sons in charge of each one.The will declared that henceforth, the king of Poland was to be the oldest of the Piast dynasty, and not necessarily the heir of his firstborn.Władysław II opposed his father's wish, and encouraged by his wife, Agnes of Babenberg, tried to ensure his power as the king would not be weakened.