Apple and HTC just announced a surprise settlement to their ongoing patent litigation, which spanned multiple lawsuits in courts around the world. The deal will see both companies drop all their charges and sign a 10-year patent cross-licensing agreement, which HTC says will "not have a material adverse impact" on its financials — meaning HTC is paying Apple at least some money.

It's completely unexpected news, especially after Apple won a comprehensive billion-dollar victory against Samsung for infringing many of the same patents. But a little reflection reveals that both parties had much more to gain from ending the dispute than from carrying on:

Apple's victory over Samsung is much less a predictor of future succes than you might think. Apple had essentially a perfect storm of facts in the Samsung case: the large number of Samsung devices that look exactly like Apple devices, the internal Samsung evidence showing the company directly tried to copy Apple, the massive sales of Samsung devices that could be used to calculate huge damages. Apple isn't going to get so lucky again. Especially not against HTC, which has a very different design language and comparatively tiny sales.

HTC is a much smaller target, and struggling to find a path forward in a market dominated by Apple and Samsung. At some point it's not worth it for Apple to fight a battle against an opponent that's falling behind in the marketplace anyway.

On the flip side, HTC probably thinks it's a better use of money to simply pay Apple and move on, rather than paying lawyers indefinitely. Apple has the money to keep this case going forever, but HTC has much bigger priorities.

HTC has also faced injunctions of its products by the ITC — the EVO 4G LTE was held up at Customs for infringing one of Apple's patents, and Apple complained that HTC's workaround was insufficient. HTC has also lost a few decisions internationally. The company could have kept fighting, but this is a much better use of time and money.

Both companies benefit from HTC's ability to use Apple's patented elements like slide-to-unlock, universal search, bounce scrolling, and scroll locking. HTC gets to make better products, and Apple allows one of Samsung's only real challengers in the US market compete with features Samsung isn't allowed to use— the enemy of Apple's enemy is Apple's friend.

Lastly, I am very curious to know how much HTC's new status as the lead partner for Windows Phone played a part in sealing these negotiations, if at all. Apple and Microsoft have a very friendly patent relationship, and if HTC has decided to focus on Windows Phone instead of Android it could have certainly helped wrap things up. That's total and complete speculation on my part, but it's something to consider.

Chances are we won't know the complete list of reasons both parties decided to settle for a long time — the terms of the deal are confidential, and neither company had much to say beyond their terse joint press release. But as it stands, Apple has now settled and reached license agreements with both HTC and Nokia, and only fully litigated the case against Samsung. The only major Apple lawsuit that's left is Motorola, a case that is now against Google directly. We'll see what happens.