Everything that has been said so far is true. You can transfer H1B if your new employer is willing to do that which will be valid for 3 years. I am assuming that you are expecting your new employer to file your GC under EB2. In that case, you have to have PERM and I-140 filed again with a new employer regardless of your old I-140 is revoked or not by your previous employer.
This has been discussed before when I asked a similar question. So let me take it a step further by giving you some more details about retention of PD on your old I-140.
The USCIS regulations at 8 CFR 204.5(e) provides for the retention of a previously established priority date under the circumstances described below:
(e) Retention of section 203(b) (1), (2), or (3) priority date.
A petition approved on behalf of an alien under sections 203(b)(1), (2), or (3) of the Act accords the alien the priority date of the approved petition for any subsequently filed petition for any classification under sections 203(b)(1), (2), or (3) of the Act for which the alien may qualify. In the event that the alien is the beneficiary of multiple petitions under sections 203(b)(1), (2), or (3) of the Act, the alien shall be entitled to the earliest priority date. A petition revoked under sections 204(e) or 205 of the Act will not confer a priority date, nor will any priority date be established as a result of a denied petition. A priority date is not transferable to another alien.
Now you may ask that what if your previous employer withdraws the approved I-140 petition and the USCIS then revokes it?
In this case, unless the USCIS revokes the petition for fraud or misrepresentation, you get to keep the priority date even if it is revoked for any other reason.
The USCIS, in the Adjudicator's Field Manual, at Chapter 22.2(b)(5)(A)(5), makes it clear that only a revocation based on a finding of fraud or misrepresentation results in a loss of the priority date:
(A) Determining the Priority Date.
In general, if a petition is supported by an individual labor certification issued by DOL, the priority date is the earliest date upon which the labor certification application was filed with DOL. In those cases where the alien’s priority date is established by the filing of the labor certification,
once the alien’s Form I-140 petition has been approved, the alien beneficiary retains his or her priority date as established by the filing of the labor certification for any future Form I-140 petitions, unless the previously approved Form I-140 petition has been revoked because of fraud or willful misrepresentation. This includes cases where a change of employer has occurred; however, the new employer must obtain a new labor certification if the classification requested requires a labor certification.
Here is the link.
http://www.uscis.gov/ilink/docView/A.../0-0-0-15.html
Look for Chapter 22 and the related provisions that I mentioned here.