We take our 16 month old out to dinner with us maybe once a week and so far (knock on wood) I've only had to leave a restaurant once mid-meal, and that was almost 8 months ago.
It looks something like this:
1. i bring a snack for him to start on as soon as we sit down. Raisins, grapes, goldfish, etc.
2. Small toys - but I present them one at a time. So, for instance, the small dinosaur only makes an appearance once stuffing a matchbox car full of the appetizer raisins has lost it's appeal.
3. The food arrives! We are lucky in that our tiny person enjoys food so this keeps him busy for quite a while - usually long enough for us to eat.
4. Back to toys. This is borrowed time and we know it.
We are typically good for a solid hour to hour and a half. I would start practicing with the kids, if you have the time and money to do so. Maybe a once a week trip to the local burger place or pizza joint? See if you can build up their dining out stamina!
Note: I do not give him electronics during dinner. They are too expensive to replace when dropped in a glass is water, puddle of catsup, bowl of soup, etc.