the purpose of the patent is to prevent secrets from being lost due to the fear of competitors stealing it. Say you have a formula, or a special method of manufacturing a widget. You tell no one, and so stay in business because the widget is useful.
However, in the long run, such behavour is bad for society as a whole. Patents encourage these "secrets" to be revealed, for the price of an enforced monopoly.
If, however, a "secret" method that's being employed is readily and easily discerned by a skilled practistioner in the field, then it deserves no patents. Pinch to zoom is one such "invention" - the mere fact of describing it to somebody means they can implement it.
Amazon's one click buy is also another example.
In other words, if the workings of the invention is easily discernable in such a way that a skilled practictioner could replicate it without knowing what would've been written in the patent, then it deserves no patents.