1. A patent remains peding in teh USPTO unitl the applcation issues or becomes abandoned. The totoal pendancy period for a patent applcation varies depending on factors such sa patent subject matter, backlog at the PTO etc.
2. During pendancy, the owner of a patent applcation has limited options available to stop someone from "stealing the invention". Once the patent issues ,the patent owner can petition for relief in Federal Court. Until issuance, the courts generally consider the property to speculative to support a legal action, There are some options, however. If the pending applcation has published and the patent issues with claims in substantially the same form as published, the patent owner can sue for damages from teh date the applcation published.
Attorney Glassmeyer is right on the money. I write only to note that many patent applications remain pending for 24 - 36 months.
If you filed the patent application yourself the likelihood of the application maturing into a patent is slim to none -- I note this because your question should have been directed to the patent attorney who filed your application. That attorney, or another one, should be assisting you in dealing with the manufacture of your invention. There should be a written agreement between the two of you dealing with, among other things, the manufacturer's obligation to maintain confidential certain information about the invention and how to make it. Contact your patent attorney or another intellectual property attorney. Good luck.
Until the United States Patent and Trademark Office issues a patent in response to your pending application, you cannot be certain whether you will be able enforce your patent against infringers. However, once the patent issues, you can seek injunctive relief in Federal Court, and you can seek damages retroactively to the date that the patent application was published. Your abiilty to stop someone from "stealing" your invention will depend on whether you are successful in obtaining a patent that covers your invention.
More importatnly, however, your question seems to indicate some confusion about intellectual property and patent rights. In general, our legal system does not allow someone to protect a mere "idea". Patents cover inventions which have been both "conceived" (an idea) AND "reduced to practice" (i.e., developed to the point where you are in possession of a useful invention). Your patent must contain more than a description of an idea--it must contain sufficient information to enable a person of ordinary skill to make or use your invention "without undue experimentaiton." Thus, conception (the idea) alone is not sufficient to obtain a patent. If your "invention" was not yet made into a working example or prototype (or at least if you did not recite in the patent specification a detailed and reasonably accurate description of how someone could make the prototype--sometimes called a "prophetic" example), you may not have been entitled to a patent. The patent examiner will review your application to ascertain whether it contains sufficient information to show that your invention was both "conceived" and "reduced to practice." Our patent system protects real, tangible inventions, not mere ideas. Thus, if you disclosed mere ideas to someone before your patent issued, and and if someone uses those ideas to make a product that us not covered by any patent that you obtain from the United States Patent and Trademark Office, you may not be able to stop them from using your idea, however brilliant it may have been.
If you had disclosed your "ideas" to someone and you had not sought a patent, and if you had taken reasonable steps to protect the confidentiality of your ideas, your ideas might have been protectable in some circumstances as trade secrets. But once a patent application is published that describes your ideas, they can no longer be protected as trade secrets because they are no longer confidential.
Further, even if you successfully obtain a patent, the claims of the patent may not be as broad as you would have liked. If someone uses your ideas but develops a product that fall outside the scope of the patent claims, there is not much that you can do about it. This happens quite frequently---a party applies for a patent hoping to get broad claims, but for many potential reasons the patent that ultimately issues is much more narrow in scope than was originally thought. A patent which is narrow in scope is easily designed around. In such circumtances, a competitor could use your general idea in a way that "designs around" the patent claims.
All of which leads to one simple point. The best way to protect yourself when you want to show your idea to others is to require everyone with whom you discuss your ideas or proposed inventions to enter into a Non Disclosure Agreement pursuant to which they agree to maintain as confidential any information that you disclose. In the event that someone violates this agreement and "steals" your ideas, you than have a contractual right to sue them for damages. This contractual right may prove more valuable to you than any patent rights which you ultimately obtain.
Finally, before any lawyer could give you definitive advice on your precise situation, a lawyer would need substantially more information. Thus, if you are concerned that someone has stolen your invention, you should retain a lawyer.
Do not be discouraged. Document the violations. If the patent does issue, then you can bring suit on the infringement. If it doesn't, then you were first to market and hopefully had time to develop good will.
[This communication is intended as general information and not specific legal advice, and this communication does not create an attorney-client relationship.]